8865c985467164923df3dd9b87c23a290256dc86
[gnulib.git] / ChangeLog
1 2007-03-21  Bruno Haible  <bruno@clisp.org>
2
3         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
4         lib/isnanl.h.
5         (Include): Update.
6         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
7         * lib/vasnprintf.c: Update.
8         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
9         tests/test-isnanl.h, remove tests/test-isnanl.c.
10         (Makefile.am): Update.
11         * tests/test-isnanl-nolibm.c: New file.
12         * tests/test-isnanl.h: New file.
13         * tests/test-isnanl.c: Remove file.
14
15 2007-03-21  Jim Meyering  <jim@meyering.net>
16
17         When trying to open ".", treat ESTALE like EACCES.
18         * lib/savewd.c (savewd_save): Resort to forking not just upon
19         failure with EACCES, but also when errno is ESTALE.
20
21 2007-03-20  Bruno Haible  <bruno@clisp.org>
22
23         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
24         Needed on AIX 5.1. Reported by Matthew Woehlke.
25
26 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
27
28         Suggestions by Bruno Haible:
29         * lib/acl-internal.h: Include "gettext.h" rather than rolling
30         our own.
31         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
32         * modules/acl (Depends-on): Add gettext.
33
34 2007-03-19  Bruno Haible  <bruno@clisp.org>
35
36         * modules/iconvme: Remove file.
37         * lib/iconvme.h: Remove file.
38         * lib/iconvme.c: Remove file.
39         * m4/iconvme.m4: Remove file.
40
41 2007-03-19  Bruno Haible  <bruno@clisp.org>
42
43         * doc/relocatable-maint.texi: Break long shell script line.
44         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
45
46 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
47
48         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
49         handle file_has_acl.
50         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
51         * lib/acl.c: Move header inclusions and related macro defns into
52         lib/acl-internal.h.
53         (S_ISLNK): Remove defn, since that's now done for us.
54         (file_has_acl): Move to lib/file-has-acl.c.
55         Call acl_trivial if available.  This is the crucial part of the fix.
56         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
57         shared within the library.  Rewrite a bit, partly to make it compatible
58         with the GNU coding style.
59         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
60         Remove unnecessary double-quotes.
61         Don't test for acl_to_text; the build will catch that.
62         Replace acl_entries if it doesn't exist and it is needed.
63         Check for -lsec and acl_trivial (as used on Solaris 10).
64         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
65         lib/file-has-acl.c.
66         (Depends-on): Add sys_stat, for S_ISLNK.
67
68 2007-03-19  Ben Pfaff  <blp@gnu.org>
69
70         * doc/gnulib.texi: Fix typos.
71         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
72
73 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
74
75         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
76         If size is zero here, buf must be zero.
77
78 2007-03-19  Simon Josefsson  <simon@josefsson.org>
79
80         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
81         <bruno@clisp.org>.
82
83 2007-03-18  Bruno Haible  <bruno@clisp.org>
84
85         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
86         Suggested by Eric Blake.
87
88 2007-03-18  Ben Pfaff  <blp@gnu.org>
89
90         * doc/relocatable.texi: Recommend using as prefix a directory
91         that does not exist and will never be created.  Based on
92         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
93         and others.
94
95 2007-03-17  Bruno Haible  <bruno@clisp.org>
96
97         * lib/fchownat.c: Include lchown.h.
98
99 2007-03-17  Bruno Haible  <bruno@clisp.org>
100
101         Fix endless loop when the given allocated size was > INT_MAX.
102         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
103         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
104         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
105         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
106         * lib/sprintf.c (sprintf): Likewise.
107
108 2007-03-17  Bruno Haible  <bruno@clisp.org>
109
110         * tests/test-argp-2.sh (func_compare): Output a context diff.
111
112 2007-03-17  Bruno Haible  <bruno@clisp.org>
113
114         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
115         locale's decimal-point character.
116
117 2007-03-17  Bruno Haible  <bruno@clisp.org>
118
119         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
120         before comparing it. Needed because on some platforms (e.g. x86) a
121         'long double' occupies less bytes than sizeof (long double).
122
123 2007-03-17  Bruno Haible  <bruno@clisp.org>
124
125         * tests/test-crc.c (main): Make printf statements 64-bit clean.
126         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
127         * tests/test-getaddrinfo.c (simple): Likewise.
128         * tests/test-read-file.c (main): Likewise.
129
130 2007-03-17  Bruno Haible  <bruno@clisp.org>
131
132         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
133
134 2007-03-17  Bruno Haible  <bruno@clisp.org>
135
136         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
137         unused variable.
138
139 2007-03-17  Bruno Haible  <bruno@clisp.org>
140
141         * tests/test-c-strcasecmp.c: Include c-strcase.h.
142         * tests/test-c-strncasecmp.c: Likewise.
143
144 2007-03-17  Bruno Haible  <bruno@clisp.org>
145
146         * modules/stdlib (Depends-on): Add unistd.
147         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
148         Needed for MacOS X 10.3.
149
150 2007-03-17  Bruno Haible  <bruno@clisp.org>
151
152         * lib/unistr/u-strdup.h: Include <stdlib.h>.
153
154 2007-03-17  Bruno Haible  <bruno@clisp.org>
155
156         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
157
158 2007-03-17  Bruno Haible  <bruno@clisp.org>
159
160         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
161         to reflect files copied from gnulib (with or without modifications).
162         Suggested by Jim Meyering.
163
164 2007-03-17  Eric Blake  <ebb9@byu.net>
165
166         * NEWS: Document stdlib change from 2007-02-18.
167
168 2007-03-17  Jim Meyering  <jim@meyering.net>
169
170         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
171         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
172         someone uses a name containing shell meta-characters.
173         Reported by Alfred M. Szmidt.
174
175         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
176
177 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
178
179         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
180         and copy gettext configuration files only if configure.ac contains
181         a use of AM_GNU_GETTEXT_VERSION.
182
183 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
184
185         * build-aux/bootstrap (gnulib_name): New variable.
186         (gnulib_tool_options): Use it.
187
188 2007-03-13  Simon Josefsson  <simon@josefsson.org>
189
190         * tests/test-des.c: Use new namespace.
191
192 2007-03-15  Bruno Haible  <bruno@clisp.org>
193
194         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
195         Reported by James Youngman <jay@gnu.org>.
196
197 2007-03-15  Bruno Haible  <bruno@clisp.org>
198
199         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
200         declared prototype. Needed with cc on OSF/1 5.1.
201
202 2007-03-15  Bruno Haible  <bruno@clisp.org>
203
204         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
205         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
206         (struct gl_list_implementation): Add dispose_fn argument to the
207         'create_empty', 'create' methods.
208         (struct gl_list_impl_base): Add field 'dispose_fn'.
209         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
210         argument.
211         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
212         dispose_fn argument.
213         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
214         dispose_fn on the dropped values.
215         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
216         dispose_fn argument.
217         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
218         dropped values.
219         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
220         (gl_tree_remove_node): Call dispose_fn on the dropped value.
221         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
222         (gl_tree_remove_node): Call dispose_fn on the dropped value.
223         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
224         argument.
225         (gl_tree_list_free): Call dispose_fn on the dropped values.
226         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
227         the dropped values.
228         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
229         Add dispose_fn argument.
230         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
231         Call dispose_fn on the dropped values.
232         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
233         Add dispose_fn argument.
234         (gl_sublist_create): Initialize the 'dispose_fn' field.
235         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
236         * tests/test-array_list.c (main): Update.
237         * tests/test-carray_list.c (main): Update.
238         * tests/test-avltree_list.c (main): Update.
239         * tests/test-rbtree_list.c (main): Update.
240         * tests/test-avltreehash_list.c (main): Update.
241         * tests/test-rbtreehash_list.c (main): Update.
242         * tests/test-linked_list.c (main): Update.
243         * tests/test-linkedhash_list.c (main): Update.
244         * tests/test-array_oset.c (main): Update.
245
246 2007-03-15  Bruno Haible  <bruno@clisp.org>
247
248         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
249         (gl_oset_create_empty): Add dispose_fn argument.
250         (struct gl_oset_implementation): Add dispose_fn argument to
251         'create_empty' method.
252         (struct gl_oset_impl_base): Add dispose_fn field.
253         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
254         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
255         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
256         values.
257         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
258         (gl_tree_oset_free): Call dispose_fn on the dropped values.
259         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
260         dropped value.
261         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
262         dropped value.
263         * tests/test-array_oset.c (main): Update.
264         * tests/test-avltree_oset.c (main): Update.
265         * tests/test-rbtree_oset.c (main): Update.
266         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
267
268 2007-03-13  Bruno Haible  <bruno@clisp.org>
269
270         * tests/test-stdbool.c (i): Update after last patch.
271
272 2007-03-12  Bruno Haible  <bruno@clisp.org>
273
274         * lib/quotearg.c: Include <wctype.h> early, before the definition of
275         the iswprint macro. Needed on Solaris 2.5.1.
276
277 2007-03-12  Bruno Haible  <bruno@clisp.org>
278
279         * tests/test-printf-frexp.c (main): Declare x as volatile.
280
281 2007-03-12  Simon Josefsson  <simon@josefsson.org>
282
283         * doc/gnulib.texi (Build robot for gnulib): New section.
284
285 2007-03-12  Jim Meyering  <jim@meyering.net>
286
287         * build-aux/bootstrap: New file.
288         * build-aux/bootstrap.conf: New file, from coreutils.
289
290 2007-03-11  Bruno Haible  <bruno@clisp.org>
291
292         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
293
294 2007-03-12  Simon Josefsson  <simon@josefsson.org>
295
296         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
297         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
298         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
299
300 2007-03-11  Bruno Haible  <bruno@clisp.org>
301
302         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
303         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
304
305 2007-03-11  Bruno Haible  <bruno@clisp.org>
306
307         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
308         formula. Needed for SunPRO C 5.0.
309
310 2007-03-11  Bruno Haible  <bruno@clisp.org>
311
312         * modules/long-options (Depends-on): Add getopt.
313
314 2007-03-11  Bruno Haible  <bruno@clisp.org>
315
316         * modules/modechange (Depends-on): Add stdbool.
317
318 2007-03-11  Bruno Haible  <bruno@clisp.org>
319
320         * modules/i-ring (Depends-on): Add stdbool.
321
322 2007-03-11  Bruno Haible  <bruno@clisp.org>
323
324         * modules/gc-des (Depends-on): Add stdbool.
325
326 2007-03-11  Bruno Haible  <bruno@clisp.org>
327
328         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
329
330 2007-03-11  Bruno Haible  <bruno@clisp.org>
331
332         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
333
334 2007-03-11  Bruno Haible  <bruno@clisp.org>
335
336         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
337
338 2007-03-11  Bruno Haible  <bruno@clisp.org>
339
340         * lib/vasnprintf.c (sprintf): Undefine.
341
342 2007-03-11  Bruno Haible  <bruno@clisp.org>
343
344         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
345         initializers in SunPRO C and Compaq C compilers.
346
347 2007-03-11  Bruno Haible  <bruno@clisp.org>
348
349         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
350         decrementing code ANSI C compliant.
351
352 2007-03-11  Bruno Haible  <bruno@clisp.org>
353
354         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
355         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
356
357 2007-03-11  Bruno Haible  <bruno@clisp.org>
358
359         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
360         <stdbool.h> substitute doesn't pass.
361
362 2007-03-11  Bruno Haible  <bruno@clisp.org>
363
364         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
365
366 2007-03-11  Bruno Haible  <bruno@clisp.org>
367
368         * gnulib-tool (func_create_megatestdir): Create also an autobuild
369         script, for submission to autobuild.josefsson.org.
370
371 2007-03-10  Bruno Haible  <bruno@clisp.org>
372
373         * modules/canonicalize-lgpl-tests: New file.
374         * tests/test-canonicalize-lgpl.sh: New file.
375         * tests/test-canonicalize-lgpl.c: New file.
376
377         * modules/c-strcase-tests: New file.
378         * tests/test-c-strcase.sh: New file.
379         * tests/test-c-strcasecmp.c: New file.
380         * tests/test-c-strncasecmp.c: New file.
381
382         * modules/atexit-tests: New file.
383         * tests/test-atexit.sh: New file.
384         * tests/test-atexit.c: New file.
385
386 2007-03-10  Bruno Haible  <bruno@clisp.org>
387
388         * tests/test-binary-io.sh: Use temporary filenames that are not so
389         likely to clash with those of other tests (in a parallel make).
390         * tests/test-binary-io.c: Likewise.
391
392 2007-03-10  Bruno Haible  <bruno@clisp.org>
393
394         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
395         fallback; use #error instead.
396         Suggested by Simon Josefsson.
397
398 2007-03-10  Bruno Haible  <bruno@clisp.org>
399
400         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
401         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
402         first and the last.
403
404 2007-03-10  Bruno Haible  <bruno@clisp.org>
405
406         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
407
408 2007-03-10  Bruno Haible  <bruno@clisp.org>
409
410         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
411         "make distcheck".
412         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
413         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
414         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
415
416 2007-03-10  Bruno Haible  <bruno@clisp.org>
417
418         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
419         variable.
420         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
421         variable.
422
423 2007-03-09  Eric Blake  <ebb9@byu.net>
424         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
425
426         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
427         types are not being provided by gnulib.
428         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
429         types are supported.
430
431 2007-03-10  Bruno Haible  <bruno@clisp.org>
432
433         * lib/stdio_.h (__attribute__): New macro.
434         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
435         vsprintf): Specify __attribute__ __format__ for GCC.
436         Suggested by Eric Blake.
437
438 2007-03-09  Bruno Haible  <bruno@clisp.org>
439
440         * modules/printf-posix-tests: New file.
441         * tests/test-printf-posix.sh: New file.
442         * tests/test-printf-posix.c: New file.
443
444         * modules/printf-posix: New file.
445         * lib/printf.c: New file.
446         * m4/printf-posix-rpl.m4: New file.
447         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
448         REPLACE_PRINTF.
449         * lib/stdio_.h (printf): New declaration.
450         (format, __format__, ____printf____, ____scanf____, ____strftime____,
451         ____strfmon____): New macros.
452         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
453         REPLACE_PRINTF.
454
455 2007-03-09  Bruno Haible  <bruno@clisp.org>
456
457         * tests/test-vasnprintf-posix2.sh: New file.
458         * tests/test-vasnprintf-posix2.c: New file.
459         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
460         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
461         (Makefile.am): Activate test-vasnprintf-posix2.sh.
462
463         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
464         a locale dependent decimal point, rather than always '.'.
465
466 2007-03-09  Eric Blake  <ebb9@byu.net>
467
468         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
469         spite of platforms like Tandem/NSK that define it to -1.
470
471 2007-03-08  Bruno Haible  <bruno@clisp.org>
472
473         * modules/vprintf-posix-tests: New file.
474         * tests/test-vprintf-posix.sh: New file.
475         * tests/test-vprintf-posix.c: New file.
476         * tests/test-printf-posix.h: New file.
477
478         * modules/vprintf-posix: New file.
479         * lib/vprintf.c: New file.
480         * m4/vprintf-posix.m4: New file.
481         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
482         REPLACE_VPRINTF.
483         * lib/stdio_.h (vprintf): New declaration.
484         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
485         REPLACE_VPRINTF.
486
487 2007-03-08  Bruno Haible  <bruno@clisp.org>
488
489         * modules/fprintf-posix-tests: New file.
490         * tests/test-fprintf-posix.sh: New file.
491         * tests/test-fprintf-posix.c: New file.
492
493         * modules/fprintf-posix: New file.
494         * lib/fprintf.c: New file.
495         * m4/fprintf-posix.m4: New file.
496         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
497         REPLACE_FPRINTF.
498         * lib/stdio_.h (fprintf): New declaration.
499         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
500         REPLACE_FPRINTF.
501
502 2007-03-08  Bruno Haible  <bruno@clisp.org>
503
504         * modules/vfprintf-posix-tests: New file.
505         * tests/test-vfprintf-posix.sh: New file.
506         * tests/test-vfprintf-posix.c: New file.
507         * tests/test-fprintf-posix.h: New file.
508         * tests/test-fprintf-posix.out: New file.
509
510         * modules/vfprintf-posix: New file.
511         * lib/vfprintf.c: New file.
512         * m4/vfprintf-posix.m4: New file.
513         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
514         REPLACE_VFPRINTF.
515         * lib/stdio_.h (vfprintf): New declaration.
516         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
517         REPLACE_VFPRINTF.
518
519 2007-03-08  Bruno Haible  <bruno@clisp.org>
520
521         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
522
523 2007-03-08  Bruno Haible  <bruno@clisp.org>
524
525         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
526         instead of 'expr' invocations.
527         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
528         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
529         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
530         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
531         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
532         Suggested by Paul Eggert.
533
534 2007-03-08  Bruno Haible  <bruno@clisp.org>
535
536         * modules/fseterr-tests: New file.
537         * tests/test-fseterr.c: New file.
538
539         * modules/fseterr: New file.
540         * lib/fseterr.h: New file.
541         * lib/fseterr.c: New file.
542
543 2007-03-08  Bruno Haible  <bruno@clisp.org>
544
545         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
546         * lib/getopt_.h: Likewise.
547         * lib/mbswidth.h: Likewise.
548         * lib/setenv.h: Likewise.
549         * lib/vasnprintf.h: Likewise.
550         * lib/vasprintf.h: Likewise.
551         * lib/verror.h: Likewise.
552         * lib/xsetenv.h: Likewise.
553         * lib/xvasprintf.h: Likewise.
554
555 2007-03-08  Jim Meyering  <jim@meyering.net>
556
557         * users.txt: Add parted.
558
559         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
560
561 2007-03-07  Bruno Haible  <bruno@clisp.org>
562
563         * m4/printf.m4: Make the shell script snippets copy&pastable.
564
565 2007-03-02  Bruno Haible  <bruno@clisp.org>
566
567         * lib/netinet_in_.h: New file.
568         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
569         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
570         * modules/netinet_in (Files): Add lib/netinet_in_.h.
571         (Depends-on): Add absolute-header.
572         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
573         into netinet/in.h.
574
575 2007-03-03  Bruno Haible  <bruno@clisp.org>
576
577         * lib/sys_select_.h: New file.
578         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
579         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
580         * modules/sys_select (Files): Add lib/sys_select_.h.
581         (Depends-on): Add absolute-header.
582         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
583         into sys/select.h.
584
585 2007-03-02  Bruno Haible  <bruno@clisp.org>
586
587         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
588         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
589         values.
590         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
591         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
592         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
593         * modules/sys_socket (Depends-on): Add absolute-header.
594         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
595         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
596         (Include): Remove requirement of inclusion of <sys/types.h>.
597
598 2007-03-02  Bruno Haible  <bruno@clisp.org>
599
600         * lib/byteswap_.h (bswap_32): Fix formula.
601
602 2007-03-06  Bruno Haible  <bruno@clisp.org>
603
604         * modules/sprintf-posix-tests: New file.
605         * tests/test-sprintf-posix.c: New file.
606
607         * modules/sprintf-posix: New file.
608         * lib/sprintf.c: New file.
609         * m4/sprintf-posix.m4: New file.
610         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
611         REPLACE_SPRINTF.
612         * lib/stdio_.h (sprintf): New declaration.
613         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
614         REPLACE_SPRINTF.
615
616 2007-03-06  Bruno Haible  <bruno@clisp.org>
617
618         * modules/vsprintf-posix-tests: New file.
619         * tests/test-vsprintf-posix.c: New file.
620         * tests/test-sprintf-posix.h: New file.
621
622         * modules/vsprintf-posix: New file.
623         * lib/vsprintf.c: New file.
624         * m4/vsprintf-posix.m4: New file.
625         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
626         REPLACE_VSPRINTF.
627         * lib/stdio_.h (vsprintf): New declaration.
628         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
629         REPLACE_VSPRINTF.
630
631 2007-03-06  Bruno Haible  <bruno@clisp.org>
632
633         * modules/vsnprintf (Depend-on): Remove minmax.
634
635 2007-03-06  Bruno Haible  <bruno@clisp.org>
636
637         * modules/snprintf-posix-tests: New file.
638         * tests/test-snprintf-posix.c: New file.
639
640         * modules/snprintf-posix: New file.
641         * m4/snprintf-posix.m4: New file.
642         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
643         gl_FUNC_SNPRINTF.
644         (gl_FUNC_SNPRINTF): Invoke it.
645         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
646         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
647         is set.
648         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
649
650 2007-03-06  Bruno Haible  <bruno@clisp.org>
651
652         * modules/vsnprintf-posix-tests: New file.
653         * tests/test-vsnprintf-posix.c: New file.
654         * tests/test-snprintf-posix.h: New file.
655
656         * modules/vsnprintf-posix: New file.
657         * m4/vsnprintf-posix.m4: New file.
658         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
659         gl_FUNC_VSNPRINTF.
660         (gl_FUNC_VSNPRINTF): Invoke it.
661         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
662         * lib/stdio_.h (vsnprintf): Define as a replacement if
663         REPLACE_VSNPRINTF is set.
664         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
665
666 2007-03-06  Bruno Haible  <bruno@clisp.org>
667
668         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
669         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
670
671 2007-03-06  Bruno Haible  <bruno@clisp.org>
672
673         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
674         (asinl): Declare also if HAVE_DECL_ASINL is set.
675         (atanl): Declare also if HAVE_DECL_ATANL is set.
676         (ceill): Declare also if HAVE_DECL_CEILL is set.
677         (cosl): Declare also if HAVE_DECL_COSL is set.
678         (expl): Declare also if HAVE_DECL_EXPL is set.
679         (floorl): Declare also if HAVE_DECL_FLOORL is set.
680         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
681         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
682         (logl): Declare also if HAVE_DECL_LOGL is set.
683         (sinl): Declare also if HAVE_DECL_SINL is set.
684         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
685         (tanl): Declare also if HAVE_DECL_TANL is set.
686         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
687         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
688         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
689         declaration of frexpl, ldexpl.
690         * modules/printf-frexpl (Depends-on): Add math.
691         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
692
693 2007-03-05  Bruno Haible  <bruno@clisp.org>
694
695         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
696         frexpl and ldexpl are declared.
697         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
698
699 2007-03-05  Bruno Haible  <bruno@clisp.org>
700
701         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
702         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
703
704 2007-03-05  Bruno Haible  <bruno@clisp.org>
705
706         * lib/stdio_.h: Include <stddef.h>.
707
708 2007-03-05  Bruno Haible  <bruno@clisp.org>
709
710         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
711
712 2007-03-05  Bruno Haible  <bruno@clisp.org>
713
714         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
715         NetBSD 4, from Ralf Wildenhues.
716
717 2007-03-04  Bruno Haible  <bruno@clisp.org>
718
719         * lib/vasprintf.h: Update #if logic for the case when the functions
720         exist but are overridden.
721
722 2007-03-04  Bruno Haible  <bruno@clisp.org>
723
724         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
725         implementations: glibc-2.4 and MacOS X 10.3.
726         * tests/test-vasnprintf-posix.c (test_function): Test also the case
727         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
728         * tests/test-vasprintf-posix.c (test_function): Likewise.
729
730 2007-03-04  Bruno Haible  <bruno@clisp.org>
731
732         * modules/vasprintf-posix-tests: New file.
733         * tests/test-vasprintf-posix.c: New file.
734
735         * modules/vasprintf-posix: New file.
736         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
737         defined.
738         * m4/vasprintf-posix.m4: New file.
739         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
740         gl_FUNC_VASPRINTF.
741         (gl_FUNC_VASPRINTF): Invoke it.
742         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
743         here.
744         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
745
746 2007-03-04  Bruno Haible  <bruno@clisp.org>
747
748         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
749         REPLACE_GETTIMEOFDAY.
750         * modules/sys_time (Makefile.am): Likewise.
751         * m4/sys_time_h.m4: Likewise.
752         * m4/gettimeofday.m4: Likewise.
753
754 2007-03-04  Bruno Haible  <bruno@clisp.org>
755
756         * modules/vasnprintf-posix-tests: New file.
757         * tests/test-vasnprintf-posix.c: New file.
758
759         * modules/vasnprintf-posix: New file.
760         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
761         printf-frexpl.h.
762         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
763         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
764         REPLACE_VASNPRINTF is defined.
765         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
766         gl_FUNC_VASNPRINTF.
767         (gl_FUNC_VASNPRINTF): Invoke it.
768         * m4/vasnprintf-posix.m4: New file.
769         * m4/printf.m4: New file.
770
771 2007-03-04  Bruno Haible  <bruno@clisp.org>
772
773         Compile progreloc.c only if --enable-relocatable is specified.
774         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
775         if --enable-relocatable was specified.
776         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
777         lib_SOURCES.
778
779 2007-03-04  Jim Meyering  <jim@meyering.net>
780
781         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
782         Use it consistently, rather than enumerating errno constants.
783
784 2007-03-04  Bruno Haible  <bruno@clisp.org>
785
786         * modules/xvasprintf-tests: New file.
787         * tests/test-xvasprintf.c: New file.
788
789         * modules/vasprintf-tests: New file.
790         * tests/test-vasprintf.c: New file.
791
792         * modules/vasnprintf-tests: New file.
793         * tests/test-vasnprintf.c: New file.
794
795         * modules/vsnprintf-tests: New file.
796         * tests/test-vsnprintf.c: New file.
797
798         * modules/snprintf-tests: New file.
799         * tests/test-snprintf.c: New file.
800
801 2007-03-04  Bruno Haible  <bruno@clisp.org>
802
803         Compile relocatable.c only if --enable-relocatable is specified.
804         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
805         gl_RELOCATABLE_LIBRARY.
806         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
807         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
808         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
809         gl_RELOCATABLE_LIBRARY.
810         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
811         (Makefile.am): Remove lib_SOURCES.
812         * modules/relocatable-lib-lgpl (configure.ac): Invoke
813         gl_RELOCATABLE_LIBRARY.
814         (Makefile.am): Remove lib_SOURCES.
815         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
816         always.
817         * modules/relocatable-prog-wrapper (configure.ac): Invoke
818         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
819
820 2007-03-04  Bruno Haible  <bruno@clisp.org>
821
822         * modules/argmatch-tests: New file.
823         * tests/test-argmatch.c: New file.
824
825         * tests/test-allocsa.c (main): Halve the number of loop runs.
826
827         * modules/alloca-opt-tests: New file.
828         * tests/test-alloca-opt.c: New file.
829
830 2007-03-04  Jim Meyering  <jim@meyering.net>
831
832         Work around difference between Linux ACLs and Solaris 10 ZFS.
833         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
834         for EINVAL.
835
836 2007-03-03  Bruno Haible  <bruno@clisp.org>
837
838         * modules/relocatable-prog (Depends-on): Add back progreloc's
839         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
840
841 2007-03-03  Bruno Haible  <bruno@clisp.org>
842
843         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
844         * modules/relocatable-lib: New file.
845
846 2007-03-03  Bruno Haible  <bruno@clisp.org>
847
848         * modules/relocatable-prog: Renamed from modules/relocatable.
849         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
850
851 2007-03-03  Bruno Haible  <bruno@clisp.org>
852
853         * modules/relocatable-script (Files): Add doc/relocatable.texi,
854         m4/relocatable-lib.m4.
855         (Depends-on): Remove 'relocatable'.
856         (configure.ac): Add gl_RELOCATABLE_NOP.
857
858 2007-03-03  Bruno Haible  <bruno@clisp.org>
859
860         * modules/relocatable-prog-wrapper: New file.
861         * modules/relocatable (Depends-on): Add it. Remove all other
862         dependencies except progname.
863         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
864
865         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
866         (gl_FUNC_STRERROR): Nop.
867         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
868
869         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
870         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
871
872         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
873         (gl_FUNC_READLINK): Update.
874
875         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
876
877 2007-03-03  Bruno Haible  <bruno@clisp.org>
878
879         * lib/xreadlink.c: Include <unistd.h> unconditionally.
880         * modules/xreadlink (Depends-on): Add unistd.
881         * modules/xreadlink-with-size (Depends-on): Likewise.
882
883 2007-03-03  Bruno Haible  <bruno@clisp.org>
884
885         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
886         extracted from gt_FUNC_SETENV.
887         (gt_FUNC_SETENV): Remove macro.
888         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
889         remove gt_FUNC_SETENV.
890
891 2007-03-03  Bruno Haible  <bruno@clisp.org>
892
893         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
894         ENABLE_RELOCATABLE here.
895         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
896
897 2007-03-03  Bruno Haible  <bruno@clisp.org>
898
899         * modules/rbtreehash-list-tests (Depends-on): Add progname.
900         * tests/test-rbtreehash_list.c: Include progname.h.
901         (main): Call set_program_name.
902
903         * modules/rbtree-oset-tests (Depends-on): Add progname.
904         * tests/test-rbtree_oset.c: Include progname.h.
905         (main): Call set_program_name.
906
907         * modules/rbtree-list-tests (Depends-on): Add progname.
908         * tests/test-rbtree_list.c: Include progname.h.
909         (main): Call set_program_name.
910
911         * modules/linked-list-tests (Depends-on): Add progname.
912         * tests/test-linked_list.c: Include progname.h.
913         (main): Call set_program_name.
914
915 2007-03-03  Bruno Haible  <bruno@clisp.org>
916
917         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
918         All uses of __restrict changed to _Restrict_.
919         * lib/glob_.h (__restrict): Remove macro.
920
921 2007-03-02  Bruno Haible  <bruno@clisp.org>
922
923         * modules/gettext (configure.ac): Require gettext infrastructure
924         from version 0.16.1.
925
926 2007-03-02  Bruno Haible  <bruno@clisp.org>
927
928         * modules/linkedhash-list-tests (Depends-on): Add progname.
929         * tests/test-linkedhash_list.c: Include progname.h.
930         (main): Call set_program_name.
931
932         * modules/carray-list-tests (Depends-on): Add progname.
933         * tests/test-carray_list.c: Include progname.h.
934         (main): Call set_program_name.
935
936         * modules/avltreehash-list-tests (Depends-on): Add progname.
937         * tests/test-avltreehash_list.c: Include progname.h.
938         (main): Call set_program_name.
939
940         * modules/avltree-oset-tests (Depends-on): Add progname.
941         * tests/test-avltree_oset.c: Include progname.h.
942         (main): Call set_program_name.
943
944         * modules/avltree-list-tests (Depends-on): Add progname.
945         * tests/test-avltree_list.c: Include progname.h.
946         (main): Call set_program_name.
947
948         * modules/array-oset-tests (Depends-on): Add progname.
949         * tests/test-array_oset.c: Include progname.h.
950         (main): Call set_program_name.
951
952         * modules/array-list-tests (Depends-on): Add progname.
953         * tests/test-array_list.c: Include progname.h.
954         (main): Call set_program_name.
955
956         * modules/argp-tests (Depends-on): Add progname.
957         * tests/test-argp.c: Include argp.h first. Include progname.h.
958         (main): Call set_program_name.
959
960 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
961
962         * doc/gnulib-tool.texi (Initial import): Reword description of
963         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
964         limited effect even if defined after the first system include.
965
966 2007-03-01  Bruno Haible  <bruno@clisp.org>
967
968         * build-aux/config.libpath: Update to libtool-1.5.22.
969         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
970
971 2007-03-01  Bruno Haible  <bruno@clisp.org>
972
973         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
974         foo_CFLAGS.
975         Reported by Ralf Wildenhues.
976
977 2007-03-01  Bruno Haible  <bruno@clisp.org>
978
979         * build-aux/install-reloc: Remove object files left over by some
980         compilers.
981         Reported by Ralf Wildenhues.
982
983 2007-03-01  Bruno Haible  <bruno@clisp.org>
984
985         * build-aux/install-reloc: Break long lines.
986
987 2007-03-01  Bruno Haible  <bruno@clisp.org>
988
989         * doc/relocatable.texi: Document that it may not work on OpenBSD.
990         Reported by Ralf Wildenhues.
991
992 2007-03-01  Bruno Haible  <bruno@clisp.org>
993
994         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
995         include ordering constraints.
996
997 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
998
999         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
1000         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
1001         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
1002         as another example.
1003         * lib/time_.h: Fix misspelling.
1004         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
1005         Require gl_HEADER_TIME_H_DEFAULTS.
1006         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
1007         * m4/time_r.m4 (gl_TIME_R): Likewise.
1008         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
1009
1010 2007-03-01  Bruno Haible  <bruno@clisp.org>
1011
1012         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
1013         * m4/utimens.m4 (gl_UTIMENS): Likewise.
1014
1015 2007-03-01  Jim Meyering  <jim@meyering.net>
1016
1017         * modules/xreadlink (Maintainer): Add my name.
1018         * modules/xreadlink-with-size (Depends-on): Alphabetize.
1019
1020 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
1021             Bruno Haible  <bruno@clisp.org>
1022
1023         * build-aux/install-reloc: Compile also c-ctype.c.
1024         * build-aux/relocatable.sh.in: New file.
1025         * doc/relocatable.texi: New file.
1026         * doc/relocatable-maint.texi: New file.
1027         * doc/gnulib.texi: Include relocatable-maint.texi.
1028         * lib/progreloc.c: Include unistd.h unconditionally.
1029         * lib/relocwrapper.c: Include unistd.h unconditionally.
1030         Include c-ctype.h.
1031         (add_dotbin): Use c_tolower.
1032         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
1033         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
1034         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
1035         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
1036         to m4/relocatable-lib.m4.
1037         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
1038         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
1039         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
1040         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
1041         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
1042         * modules/relocatable: New file.
1043         * modules/relocatable-lib: New file.
1044         * modules/relocatable-script: New file.
1045
1046 2007-02-28  Bruno Haible  <bruno@clisp.org>
1047
1048         Import --enable-relocatable infrastructure.
1049         * build-aux/config.libpath: New file, from GNU gettext.
1050         * build-aux/install-reloc: New file, from GNU gettext.
1051         * build-aux/reloc-ldflags: New file, from GNU gettext.
1052         * lib/relocatable.h: New file, from GNU gettext.
1053         * lib/relocatable.c: New file, from GNU gettext.
1054         * lib/relocwrapper.c: New file, from GNU gettext.
1055         * m4/relocatable.m4: New file, from GNU gettext.
1056
1057 2007-02-28  Bruno Haible  <bruno@clisp.org>
1058
1059         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
1060
1061         * modules/xreadlink: New file, from GNU gettext with modifications.
1062         * lib/xreadlink.c: New file, from GNU gettext.
1063         * lib/xreadlink.h: Add comments.
1064         (xreadlink): New declaration.
1065
1066         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
1067         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
1068         lib/xreadlink-with-size.c.
1069         (configure.ac): Remove gl_XREADLINK invocation.
1070         (Makefile.am): Augment lib_SOURCES.
1071         * m4/xreadlink.m4: Remove file.
1072         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
1073         (xreadlink_with_size): Renamed from xreadink.
1074         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
1075         * modules/canonicalize (Depends-on): Replace xreadlink with
1076         xreadlink-with-size.
1077         * lib/canonicalize.c (canonicalize_filename_mode): Update.
1078
1079 2007-02-25  Jim Meyering  <jim@meyering.net>
1080
1081         * build-aux/announce-gen: When complaining about excess arguments,
1082         list them.
1083
1084 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
1085
1086         * README: Document signed integer overflow situation more
1087         accurately.
1088
1089 2007-02-25  Bruno Haible  <bruno@clisp.org>
1090
1091         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
1092         'a' or 'A' conversion.
1093
1094 2007-02-25  Bruno Haible  <bruno@clisp.org>
1095
1096         * modules/filename: Renamed from modules/pathname.
1097         (Files): Replace lib/pathname.h with lib/filename.h. Replace
1098         lib/concatpath.c with lib/concat-filename.c.
1099         (Makefile.am): Update.
1100         (Include): Replace pathname.h with filename.h.
1101         * lib/filename.h: Renamed from lib/pathname.h.
1102         (concatenated_filename): Renamed from concatenated_pathname.
1103         * lib/concat-filename.c: Renamed from lib/concatpath.c.
1104         (concatenated_filename): Renamed from concatenated_pathname.
1105         * lib/findprog.c: Include filename.h instead of pathname.h.
1106         (find_in_path): Update.
1107         * lib/javacomp.c: Include filename.h instead of pathname.h.
1108         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
1109         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
1110         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
1111         is_oldgcj_14_13_usable, is_javac_usable): Update.
1112         * lib/javaexec.c: Include filename.h instead of pathname.h.
1113         (execute_java_class): Update.
1114         * modules/findprog: Update.
1115         * modules/javacomp: Update.
1116         * modules/javaexec: Update.
1117         * MODULES.html.sh (File system functions): Add 'filename', remove
1118         'pathname'.
1119
1120 2007-02-25  Bruno Haible  <bruno@clisp.org>
1121
1122         * modules/printf-frexpl-tests: New file.
1123         * tests/test-printf-frexpl.c: New file.
1124
1125         * modules/printf-frexpl: New file.
1126         * lib/printf-frexpl.h: New file.
1127         * lib/printf-frexpl.c: New file.
1128         * m4/printf-frexpl.m4: New file.
1129
1130 2007-02-25  Bruno Haible  <bruno@clisp.org>
1131
1132         * modules/printf-frexp-tests: New file.
1133         * tests/test-printf-frexp.c: New file.
1134
1135         * modules/printf-frexp: New file.
1136         * lib/printf-frexp.h: New file.
1137         * lib/printf-frexp.c: New file.
1138         * m4/printf-frexp.m4: New file.
1139
1140 2007-02-25  Bruno Haible  <bruno@clisp.org>
1141
1142         Assume automake >= 1.10 for the tests.
1143         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
1144         * modules/arctwo-tests: Likewise.
1145         * modules/argp-tests: Likewise.
1146         * modules/avltree-list-tests: Likewise.
1147         * modules/avltree-oset-tests: Likewise.
1148         * modules/avltreehash-list-tests: Likewise.
1149         * modules/carray-list-tests: Likewise.
1150         * modules/crc-tests: Likewise.
1151         * modules/des-tests: Likewise.
1152         * modules/gc-arcfour-tests: Likewise.
1153         * modules/gc-arctwo-tests: Likewise.
1154         * modules/gc-des-tests: Likewise.
1155         * modules/gc-hmac-md5-tests: Likewise.
1156         * modules/gc-hmac-sha1-tests: Likewise.
1157         * modules/gc-md2-tests: Likewise.
1158         * modules/gc-md4-tests: Likewise.
1159         * modules/gc-md5-tests: Likewise.
1160         * modules/gc-pbkdf2-sha1-tests: Likewise.
1161         * modules/gc-rijndael-tests: Likewise.
1162         * modules/gc-sha1-tests: Likewise.
1163         * modules/gc-tests: Likewise.
1164         * modules/getaddrinfo-tests: Likewise.
1165         * modules/hmac-md5-tests: Likewise.
1166         * modules/hmac-sha1-tests: Likewise.
1167         * modules/linked-list-tests: Likewise.
1168         * modules/linkedhash-list-tests: Likewise.
1169         * modules/lock-tests: Likewise.
1170         * modules/md2-tests: Likewise.
1171         * modules/md4-tests: Likewise.
1172         * modules/md5-tests: Likewise.
1173         * modules/rbtree-list-tests: Likewise.
1174         * modules/rbtree-oset-tests: Likewise.
1175         * modules/rbtreehash-list-tests: Likewise.
1176         * modules/read-file-tests: Likewise.
1177         * modules/rijndael-tests: Likewise.
1178         * modules/stdint-tests: Likewise.
1179         * modules/tls-tests: Likewise.
1180
1181 2007-02-24  Bruno Haible  <bruno@clisp.org>
1182
1183         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
1184         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
1185         function; instead check whether isnan with a double argument links.
1186         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
1187         function; instead check whether isnan with a 'long double' argument
1188         links.
1189         Reported by Eric Blake <ebb9@byu.net>.
1190
1191 2007-02-24  Bruno Haible  <bruno@clisp.org>
1192
1193         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
1194         defined.
1195         * lib/isnanl.c: Remove all code. Just include isnan.c.
1196         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
1197
1198 2007-02-25  Jim Meyering  <jim@meyering.net>
1199
1200         Avoid conflicting types for 'unsetenv' on FreeBSD.
1201         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
1202         conflicting with FreeBSD's (5.0 and 6.1) function declaration
1203         in stdlib.h.
1204
1205 2007-02-24  Bruno Haible  <bruno@clisp.org>
1206
1207         * modules/isnanl-nolibm-tests: New file.
1208         * tests/test-isnanl.c: New file.
1209
1210         * modules/isnanl-nolibm: New file.
1211         * lib/isnanl.h: New file.
1212         * lib/isnanl.c: New file.
1213         * m4/isnanl.m4: New file.
1214
1215 2007-02-24  Bruno Haible  <bruno@clisp.org>
1216
1217         * modules/isnan-nolibm-tests: New file.
1218         * tests/test-isnan.c: New file.
1219
1220         * modules/isnan-nolibm: New file.
1221         * lib/isnan.h: New file.
1222         * lib/isnan.c: New file.
1223         * m4/isnan.m4: New file.
1224
1225 2007-02-24  Bruno Haible  <bruno@clisp.org>
1226
1227         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
1228         assume that an exponent fits in 20 bits.
1229
1230 2007-02-24  Jim Meyering  <jim@meyering.net>
1231
1232         * m4/regex.m4: Update the description of the configure-time option,
1233         --without-included-regex, to state accurately what the defaults are,
1234         and perhaps to give people an idea why using this option is risky.
1235
1236 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
1237
1238         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
1239         loops on small arguments.  This attempts to avoid the problem
1240         Bruno Haible reported for AIX 4.3.2 in
1241         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
1242
1243 2007-02-23  Bruno Haible  <bruno@clisp.org>
1244
1245         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
1246         Needed for help2man.
1247
1248 2007-02-23  Karl Berry  <karl@gnu.org>
1249
1250         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
1251         exists, foo.h should be cvs-ignored, not committed.
1252
1253 2007-02-23  Eric Blake  <ebb9@byu.net>
1254
1255         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
1256         * lib/stat-time.h (includes): Likewise.
1257         * lib/utimecmp.c (includes): Likewise.
1258         * lib/utimens.h (includes): Likewise.
1259         * lib/getdate.y (includes): Also include "timespec.h" for use
1260         internal to the module.
1261         * modules/utimens (Depends-on): Revert yesterday's patch.
1262         * modules/nanosleep (Depends-on): Add missing dependency.
1263
1264 2007-02-22  Bruno Haible  <bruno@clisp.org>
1265
1266         * lib/glob.c: Don't include getlogin_r.h.
1267
1268 2007-02-22  Jim Meyering  <jim@meyering.net>
1269
1270         * modules/utimens (Depends-on): Add timespec, required for
1271         utimens.h's inclusion of timespec.h.
1272
1273 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
1274
1275         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
1276         long unreadable paths in GNU/Linux.  Problem reported by Andreas
1277         Schwab in
1278         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
1279         I'll try to think of a better way to fix the Solaris problem.
1280
1281         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
1282         like glibc; on Solaris 10, it fails with errno == EINVAL.
1283         POSIX says the behavior is unspecified if the first argument is NULL,
1284         so play it safe and never pass NULL to the system getcwd.
1285
1286 2007-02-21  Jim Meyering  <jim@meyering.net>
1287
1288         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
1289         of gettimeofday.  It would conflict with the one now always
1290         provided via sys_time_.h.  Reported by Matthew Woehlke, as
1291         an IRIX 6.5 build failure.
1292
1293 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
1294
1295         Minor fixups to port to Solaris 10 with Sun C 5.8.
1296         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
1297         * modules/getcwd (Depends-on): Add dirfd.
1298         * lib/putenv.c (putenv): #undef it.
1299         (rpl_putenv): New decl.
1300         (malloc, free): Include <stdlib.h> rather than prototyping separately.
1301
1302 2007-02-20  Bruno Haible  <bruno@clisp.org>
1303
1304         * modules/stdio-tests: New file.
1305         * tests/test-stdio.c: New file.
1306
1307         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
1308         (Depends-on): Add stdio.
1309         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1310         (Include): Use <stdio.h> instead of vsnprintf.h.
1311         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1312         HAVE_DECL_VSNPRINTF.
1313         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
1314
1315         * modules/snprintf (Files): Remove lib/snprintf.h.
1316         (Depends-on): Add stdio.
1317         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1318         (Include): Use <stdio.h> instead of snprintf.h.
1319         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1320         HAVE_DECL_SNPRINTF.
1321         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
1322         * lib/getaddrinfo.c: Likewise.
1323
1324         * modules/stdio: New file.
1325         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
1326         * lib/snprintf.h: Remove file.
1327         * lib/vsnprintf.h: Remove file.
1328         * lib/.cppi-disable: Remove snprintf.h.
1329         * m4/stdio_h.m4: New file.
1330         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
1331
1332 2007-02-20  Jim Meyering  <jim@meyering.net>
1333
1334         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
1335         used by e.g., mingw.  From Bruno Haible.
1336
1337 2007-02-19  Bruno Haible  <bruno@clisp.org>
1338
1339         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
1340         warnings.
1341         Reported by Ben Pfaff <blp@cs.stanford.edu>.
1342
1343 2007-02-19  Bruno Haible  <bruno@clisp.org>
1344
1345         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
1346         from mingw users.
1347
1348 2007-02-19  Bruno Haible  <bruno@clisp.org>
1349
1350         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
1351         warnings.
1352         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
1353
1354 2007-02-19  Jim Meyering  <jim@meyering.net>
1355
1356         Don't use FD after a successful "fdopendir (fd)".
1357         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
1358         Reset it by calling dirfd on the just-obtained DIR*.
1359
1360         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
1361         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
1362
1363 2007-02-18  Bruno Haible  <bruno@clisp.org>
1364
1365         * lib/readlink.c: Include <unistd.h>.
1366         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
1367         HAVE_READLINK.
1368         * modules/readlink (Depends-on): Add unistd.
1369         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1370         (Include): Add <unistd.h>.
1371
1372         * lib/getlogin_r.h: Remove file.
1373         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
1374         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
1375         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
1376         HAVE_DECL_GETLOGIN_R.
1377         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
1378         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1379         (Include): Use <unistd.h> instead of getlogin_r.h.
1380
1381         * lib/getcwd.h: Remove file.
1382         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
1383         * lib/xgetcwd.c: Likewise.
1384         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
1385         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
1386         * modules/getcwd (Files): Remove lib/getcwd.h.
1387         (Depends-on): Add unistd.
1388         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1389         (Include): Use <unistd.h> instad of getcwd.h.
1390
1391         * lib/ftruncate.c: Include <unistd.h> first.
1392         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
1393         Set HAVE_FTRUNCATE.
1394         * modules/ftruncate (Depends-on): Add unistd.
1395         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1396
1397         * lib/fchdir.c: Include <unistd.h> first.
1398         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
1399         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
1400         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
1401         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1402         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
1403
1404         * lib/dup2.c: Include <unistd.h> first.
1405         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
1406         HAVE_DUP2.
1407         * modules/dup2 (Depends-on): Add unistd.
1408         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1409
1410         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
1411         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
1412         REPLACE_CHOWN. Don't define chown as a macro here.
1413         * modules/chown (Depends-on): Add unistd.
1414         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1415
1416         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
1417         Add definition for GL_LINK_WARNING.
1418         (chown, dup2): New declarations.
1419         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
1420         link warning.
1421         (ftruncate): New declaration.
1422         (getcwd): New declaration, taken from old getcwd.h.
1423         (getlogin_r): New declaration, taken from old getlogin_r.h.
1424         (readlink): New declaration.
1425         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
1426         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
1427         (gl_PREREQ_UNISTD): Remove macro.
1428         (gl_UNISTD_MODULE_INDICATOR): New macro.
1429         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
1430         many new variables. Don't set UNISTD_H.
1431         * modules/unistd (Description): Change.
1432         (Depends-on): Add link-warning.
1433         (configure.ac): Update.
1434         (Makefile.am): Create unistd.h always. Substitute many new variables
1435         into it.
1436
1437 2007-02-18  Bruno Haible  <bruno@clisp.org>
1438
1439         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
1440         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
1441         HAVE_GETSUBOPT.
1442         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
1443         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
1444         * lib/getsubopt.h: Remove file.
1445         * modules/getsubopt (Files): Remove lib/getsubopt.h.
1446         (Depends-on): Add stdlib.
1447         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1448         (Includes): Use <stdlib.h> instead of getsubopt.h.
1449         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
1450         Set HAVE_GETSUBOPT.
1451         * lib/getsubopt.c: Don't include getsubopt.h.
1452
1453 2007-02-18  Bruno Haible  <bruno@clisp.org>
1454
1455         * modules/fchdir (Depends-on): Add dup2.
1456
1457 2007-02-18  Bruno Haible  <bruno@clisp.org>
1458
1459         * lib/stdlib_.h: Handle glibc's special invocation convention
1460         specially.
1461
1462 2007-02-18  Bruno Haible  <bruno@clisp.org>
1463
1464         * modules/stdlib-tests: New file.
1465         * tests/test-stdlib.c: New file.
1466
1467         * modules/mkstemp (Files): Remove lib/mkstemp.h.
1468         (Depends-on): Add stdlib.
1469         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1470         (Includes): Use <stdlib.h> instead of mkstemp.h.
1471         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
1472         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
1473         * lib/mkstemp.c: Don't include mkstemp.h.
1474         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
1475         * lib/stdlib--.h: Don't include mkstemp.h.
1476
1477         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
1478         (Depends-on): Add stdlib.
1479         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1480         (Includes): Use <stdlib.h> instead of mkdtemp.h.
1481         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
1482         HAVE_MKDTEMP.
1483         * lib/mkdtemp.c: Don't include mkdtemp.h.
1484         * lib/clean-temp.c: Don't include mkdtemp.h.
1485
1486         * modules/exit (Files): Remove lib/exit.h.
1487         (Depends-on): Add stdlib.
1488         (Makefile.am): Remove lib_SOURCES.
1489         (Include): Use <stdlib.h> instead of exit.h.
1490         * lib/argmatch.c: Don't include exit.h.
1491         * lib/execute.c: Likewise.
1492         * lib/pagealign_alloc.c: Likewise.
1493         * lib/pipe.c: Likewise.
1494         * lib/wait-process.c: Likewise.
1495         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
1496         * lib/exitfail.c: Likewise.
1497         * lib/savewd.c: Likewise.
1498         * lib/xsetenv.c: Likewise.
1499
1500         * modules/stdlib: New file.
1501         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
1502         and extra comments about mkstemp().
1503         * lib/exit.h: Remove file.
1504         * lib/mkdtemp.h: Remove file.
1505         * lib/mkstemp.h: Remove file.
1506         * m4/stdlib_h.m4: New file.
1507         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
1508
1509 2007-02-18  Bruno Haible  <bruno@clisp.org>
1510
1511         * modules/math-tests: New file.
1512         * tests/test-math.c: New file.
1513
1514         * modules/math: New file.
1515         * modules/mathl (Files): Remove lib/mathl.h.
1516         (Depends-on): Add math.
1517         (Makefile.am): Don't mention mathl.h.
1518         (Include): Use <math.h> instead of mathl.h.
1519         * lib/math_.h: New file.
1520         * lib/mathl.h: Remove file.
1521         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
1522         mathl.h.
1523         * lib/asinl.c: Likewise.
1524         * lib/atanl.c: Likewise.
1525         * lib/ceill.c: Likewise.
1526         * lib/cosl.c: Likewise.
1527         * lib/expl.c: Likewise.
1528         * lib/floorl.c: Likewise.
1529         * lib/frexpl.c: Likewise.
1530         * lib/ldexpl.c: Likewise.
1531         * lib/logl.c: Likewise.
1532         * lib/sincosl.c: Likewise.
1533         * lib/sinl.c: Likewise.
1534         * lib/sqrtl.c: Likewise.
1535         * lib/tanl.c: Likewise.
1536         * lib/trigl.c: Likewise.
1537         * m4/math_h.m4: New file.
1538         * MODULES.html.sh (Mathematics): Add math.
1539
1540 2007-02-17  Bruno Haible  <bruno@clisp.org>
1541
1542         * modules/wctype-tests: New file.
1543         * tests/test-wctype.c: New file.
1544
1545         * modules/wchar-tests: New file.
1546         * tests/test-wchar.c: New file.
1547
1548         * modules/unistd-tests: New file.
1549         * tests/test-unistd.c: New file.
1550
1551         * modules/time-tests: New file.
1552         * tests/test-time.c: New file.
1553
1554         * modules/sysexits-tests: New file.
1555         * tests/test-sysexits.c: New file.
1556
1557         * modules/sys_time-tests: New file.
1558         * tests/test-sys_time.c: New file.
1559
1560         * modules/sys_stat-tests: New file.
1561         * tests/test-sys_stat.c: New file.
1562
1563         * modules/sys_socket-tests: New file.
1564         * tests/test-sys_socket.c: New file.
1565
1566         * modules/sys_select-tests: New file.
1567         * tests/test-sys_select.c: New file.
1568
1569         * modules/string-tests: New file.
1570         * tests/test-string.c: New file.
1571
1572         * modules/stdbool-tests: New file.
1573         * tests/test-stdbool.c: New file.
1574
1575         * modules/netinet_in-tests: New file.
1576         * tests/test-netinet_in.c: New file.
1577
1578         * modules/inttypes-tests: New file.
1579         * tests/test-inttypes.c: New file.
1580
1581         * modules/fcntl-tests: New file.
1582         * tests/test-fcntl.c: New file.
1583
1584         * modules/byteswap-tests: New file.
1585         * tests/test-byteswap.c: New file.
1586
1587         * modules/arpa_inet-tests: New file.
1588         * tests/test-arpa_inet.c: New file.
1589
1590 2007-02-17  Bruno Haible  <bruno@clisp.org>
1591
1592         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
1593         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
1594         if the corresponding module is not enabled. Emit link warnings if
1595         the function is used nevertheless.
1596         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
1597         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
1598         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
1599         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
1600         * modules/inttypes (Depends-on): Add link-warning.
1601         (Makefile.am): Copy the contents of build-aux/link-warning.h into
1602         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
1603         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
1604         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
1605         * modules/imaxdiv (configure.ac): Likewise.
1606         * modules/strtoimax (configure.ac): Likewise.
1607         * modules/strtoumax (configure.ac): Likewise.
1608
1609 2007-02-17  Bruno Haible  <bruno@clisp.org>
1610
1611         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
1612         gl_STRING_MODULE_INDICATOR_DEFAULTS.
1613         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
1614         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
1615
1616 2007-02-17  Bruno Haible  <bruno@clisp.org>
1617
1618         * modules/link-warning: New file.
1619         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
1620         * lib/string_.h (GL_LINK_WARNING): Remove definition.
1621         * modules/string (Depends-on): Add link-warning.
1622         (Makefile.am): Copy the contents of build-aux/link-warning.h into
1623         string.h.
1624         * MODULES.html.sh (Support for building libraries and executables): Add
1625         link-warning.
1626
1627 2007-02-17  Bruno Haible  <bruno@clisp.org>
1628
1629         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
1630         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
1631         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
1632         long lines.
1633
1634 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
1635             Bruno Haible  <bruno@clisp.org>
1636
1637         * modules/tmpfile: New file.
1638         * lib/tmpfile.c: New file.
1639         * m4/tmpfile.m4: New file.
1640         * MODULES.html.sh (func_all_modules): New section "Input/output".
1641
1642 2007-02-15  Bruno Haible  <bruno@clisp.org>
1643
1644         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
1645         (supports_delete_on_close): New function.
1646         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
1647
1648 2007-02-14  Bruno Haible  <bruno@clisp.org>
1649
1650         * modules/mbspcasecmp-tests: New file.
1651         * tests/test-mbspcasecmp.sh: New file.
1652         * tests/test-mbspcasecmp.c: New file.
1653
1654         New module mbspcasecmp.
1655         * modules/mbspcasecmp: New file.
1656         * lib/mbspcasecmp.c: New file.
1657         * lib/string_.h (strncasecmp): Change warning message.
1658         (mbspcasecmp): New declaration.
1659         * m4/mbspcasecmp.m4: New file.
1660         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
1661         GNULIB_MBSPCASECMP.
1662         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
1663         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
1664
1665 2007-02-14  Bruno Haible  <bruno@clisp.org>
1666
1667         * modules/mbsncasecmp-tests: New file.
1668         * tests/test-mbsncasecmp.sh: New file.
1669         * tests/test-mbsncasecmp.c: New file.
1670
1671         New module mbsncasecmp.
1672         * modules/mbsncasecmp: New file.
1673         * lib/mbsncasecmp.c: New file.
1674         * lib/string_.h (mbsncasecmp): New declaration.
1675         * m4/mbsncasecmp.m4: New file.
1676         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
1677         GNULIB_MBSNCASECMP.
1678         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
1679         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
1680
1681 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
1682
1683         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
1684         Verify that it doesn't overlap with our flags.
1685         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
1686         do not have the desired effect in multibyte locales; instead, use
1687         mbscasecmp.
1688         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
1689         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
1690         we don't require GNU fnmatch ourselves (if our users require it, they
1691         should do so explicitly).
1692
1693         Fix regex code so it doesn't rely on strcasecmp.
1694         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
1695         Otherwise, include gnulib's langinfo.h.
1696         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
1697         undesirable behavior in non-C locales.  Instead, rely on localecharset.
1698         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
1699         * modules/regex (FILES): Remove m4/codeset.m4.
1700         (Depends-on): Add localcharset.  Remove strcase.
1701
1702 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1703
1704         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
1705         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
1706
1707 2007-02-13  Bruno Haible  <bruno@clisp.org>
1708
1709         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
1710         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
1711
1712 2007-02-12  Bruno Haible  <bruno@clisp.org>
1713
1714         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
1715         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
1716         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
1717         time warning rather than a link error.
1718
1719 2007-02-12  Bruno Haible  <bruno@clisp.org>
1720
1721         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
1722         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
1723         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
1724
1725 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
1726
1727         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
1728         args, not 2.
1729
1730 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
1731
1732         New module 'time', so that apps can include <time.h> as per
1733         POSIX and GNU instead of separate include files like time_r.h
1734         and timegm.h.  This implementation tries out a simpler approach
1735         for replacing decls in standard include files (as compared to
1736         the string module), somewhat as an experiment.
1737
1738         * config/srclist.txt: Comment out mktime.c for now.
1739         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
1740         since it doesn't apply any more.  Use generic wording instead.
1741         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
1742         'time'.
1743         * lib/time_.h, m4/time_h.m4, modules/time: New files.
1744         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
1745         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
1746         Don't include <sys/types.h>; no longer needed since we assume C89.
1747         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
1748         * lib/strftime.c: Likewise.
1749         * lib/time_r.c: Likewise.
1750         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
1751         * lib/nanosleep.c: Include <time.h> first, to check interface.
1752         * lib/strptime.c: Likewise.
1753         * lib/time_r.c: Likewise.
1754         * lib/timegm.c: Likewise.
1755         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
1756         needed.
1757         * lib/timegm.c: Don't include timegm.h; no longer needed.
1758         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
1759         time.h now handles any problems in that area.
1760         (struct timespec, nanosleep): Remove; time.h now arranges for these.
1761         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
1762         that time.h defines struct timespec.
1763         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
1764         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
1765         handles that.
1766         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
1767         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
1768         needed.  Set REPLACE_LOCALTIME.
1769         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
1770         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
1771         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
1772         nanosleep; time_h.m4 now does that.  Don't require
1773         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
1774         module handles this now.
1775         * modules/getdate (Depends-on): Remove timespec.  Add time.
1776         * modules/nanosleep (Depends-on): Likewise.
1777         * modules/stat-time (Depends-on): Likewise.
1778         * modules/nanosleep (Include): Include time.h, not timespec.h.
1779         * modules/strptime (Files): Remove lib/strptime.h.
1780         (Depends-on): Add extensions, time.
1781         (Include): Include time.h, not strptime.h.
1782         * modules/time_r (Files): Remove lib/time_r.h.
1783         (Depends-on): Add time.
1784         (Include): Include time.h, not time_r.h.
1785         * modules/timegm: Likewise.
1786         * modules/timespec (Description): Now does timespec-related decls
1787         of our own, instead of struct timespec itself.
1788         (Depends-on): Add time; remove extensions.
1789         (Maintainer): Add self.
1790         * modules/utimecmp (Depends-on): Add time; remove timespec.
1791         * modules/utimens (Depends-on): Likewise.
1792         * modules/xnanosleep (Depends-on): Likewise.
1793
1794 2007-02-11  Bruno Haible  <bruno@clisp.org>
1795
1796         * lib/c-strstr.c: Include allocsa.h.
1797         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
1798         * lib/c-strcasestr.c: Include allocsa.h.
1799         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
1800         * lib/strcasestr.c: Include allocsa.h.
1801         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
1802         * lib/mbsstr.c: Include allocsa.h.
1803         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
1804         allocsa/freesa instead of malloc/free.
1805         * lib/mbscasestr.c: Include allocsa.h.
1806         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
1807         allocsa/freesa instead of malloc/free.
1808         * modules/c-strstr (Depends-on): Add allocsa.
1809         * modules/c-strcasestr (Depends-on): Likewise.
1810         * modules/strcasestr (Depends-on): Likewise.
1811         * modules/mbsstr (Depends-on): Likewise.
1812         * modules/mbscasestr (Depends-on): Likewise.
1813
1814 2007-02-11  Bruno Haible  <bruno@clisp.org>
1815
1816         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
1817
1818         * modules/mbsspn-tests: New file.
1819         * tests/test-mbsspn.sh: New file.
1820         * tests/test-mbsspn.c: New file.
1821
1822 2007-02-11  Bruno Haible  <bruno@clisp.org>
1823
1824         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
1825
1826         * modules/mbspbrk-tests: New file.
1827         * tests/test-mbspbrk.sh: New file.
1828         * tests/test-mbspbrk.c: New file.
1829
1830 2007-02-11  Bruno Haible  <bruno@clisp.org>
1831
1832         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
1833         unneeded cast.
1834
1835         * modules/mbscspn-tests: New file.
1836         * tests/test-mbscspn.sh: New file.
1837         * tests/test-mbscspn.c: New file.
1838
1839 2007-02-11  Bruno Haible  <bruno@clisp.org>
1840
1841         * modules/mbscasecmp-tests: New file.
1842         * tests/test-mbscasecmp.sh: New file.
1843         * tests/test-mbscasecmp.c: New file.
1844
1845 2007-02-11  Bruno Haible  <bruno@clisp.org>
1846
1847         Ensure O(n) worst-case complexity of mbscasestr.
1848         * lib/mbscasestr.c: Include stdbool.h.
1849         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
1850         functions.
1851         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
1852         the bookkeeping indicates that it's worth it.
1853         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
1854
1855         * modules/mbscasestr-tests: New file.
1856         * tests/test-mbscasestr1.c: New file.
1857         * tests/test-mbscasestr2.sh: New file.
1858         * tests/test-mbscasestr2.c: New file.
1859         * tests/test-mbscasestr3.sh: New file.
1860         * tests/test-mbscasestr3.c: New file.
1861         * tests/test-mbscasestr4.sh: New file.
1862         * tests/test-mbscasestr4.c: New file.
1863         * m4/locale-tr.m4: New file.
1864
1865 2007-02-11  Bruno Haible  <bruno@clisp.org>
1866
1867         Ensure O(n) worst-case complexity of mbsstr.
1868         * lib/mbsstr.c: Include stdbool.h.
1869         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
1870         functions.
1871         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
1872         bookkeeping indicates that it's worth it.
1873         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
1874
1875         * modules/mbsstr-tests: New file.
1876         * tests/test-mbsstr1.c: New file.
1877         * tests/test-mbsstr2.sh: New file.
1878         * tests/test-mbsstr2.c: New file.
1879         * tests/test-mbsstr3.sh: New file.
1880         * tests/test-mbsstr3.c: New file.
1881         * m4/locale-fr.m4: New file.
1882
1883 2007-02-11  Bruno Haible  <bruno@clisp.org>
1884
1885         * lib/mbsrchr.c (mbsrchr): Fix bug.
1886
1887         * modules/mbsrchr-tests: New file.
1888         * tests/test-mbsrchr.sh: New file.
1889         * tests/test-mbsrchr.c: New file.
1890
1891 2007-02-11  Bruno Haible  <bruno@clisp.org>
1892
1893         * lib/mbschr.c (mbschr): Fix bug.
1894
1895         * modules/mbschr-tests: New file.
1896         * tests/test-mbschr.sh: New file.
1897         * tests/test-mbschr.c: New file.
1898         * m4/locale-zh.m4: New file.
1899
1900 2007-02-11  Bruno Haible  <bruno@clisp.org>
1901
1902         Support for copying multibyte string iterators.
1903         * lib/mbiter.h: Include <string.h>.
1904         (mbiter_multi_copy): New function.
1905         (mbi_copy): New macro.
1906         * lib/mbuiter.h: Include <string.h>.
1907         (mbuiter_multi_copy): New function.
1908         (mbui_copy): New macro.
1909
1910 2007-02-11  Bruno Haible  <bruno@clisp.org>
1911
1912         New module mbslen.
1913         * modules/mbslen: New file.
1914         * lib/mbslen.c: New file.
1915         * lib/string_.h (mbslen): New declaration.
1916         * m4/mbslen.m4: New file.
1917         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
1918         GNULIB_MBSLEN.
1919         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
1920         * MODULES.html.sh (Internationalization functions): Add mbslen.
1921
1922 2007-02-11  Bruno Haible  <bruno@clisp.org>
1923
1924         Ensure O(n) worst-case complexity of strcasestr substitute.
1925         * lib/strcasestr.c: Include stdbool.h.
1926         (knuth_morris_pratt): New function.
1927         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
1928         bookkeeping indicates that it's worth it.
1929         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
1930
1931         * modules/strcasestr-tests: New file.
1932         * tests/test-strcasestr.c: New file.
1933
1934 2007-02-11  Bruno Haible  <bruno@clisp.org>
1935
1936         Ensure O(n) worst-case complexity of c_strcasestr.
1937         * lib/c-strcasestr.c: Include stdbool.h, string.h.
1938         (knuth_morris_pratt): New function.
1939         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
1940         the bookkeeping indicates that it's worth it.
1941         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
1942
1943         * modules/c-strcasestr-tests: New file.
1944         * tests/test-c-strcasestr.c: New file.
1945
1946 2007-02-11  Bruno Haible  <bruno@clisp.org>
1947
1948         Ensure O(n) worst-case complexity of c_strstr.
1949         * lib/c-strstr.c: Include stdbool.h, string.h.
1950         (knuth_morris_pratt): New function.
1951         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
1952         bookkeeping indicates that it's worth it.
1953         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
1954
1955         * lib/c-strstr.c: Complete rewrite for maintainability.
1956
1957         * modules/c-strstr-tests: New file.
1958         * tests/test-c-strstr.c: New file.
1959
1960 2007-02-11  Bruno Haible  <bruno@clisp.org>
1961
1962         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
1963         5.2.1 and earlier, whereby \055 was treated just like the range
1964         delimiter '-'.
1965         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
1966
1967 2007-02-08  Bruno Haible  <bruno@clisp.org>
1968
1969         * modules/regex (Depends-on): Add stdbool.
1970         Reported by Dalibor Topic <robilad@kaffe.org>.
1971
1972 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
1973
1974         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
1975         Prefer returning from main to exiting from it.
1976         Remove unnecessary parens after sizeof.
1977
1978 2007-02-05  Bruno Haible  <bruno@clisp.org>
1979
1980         New module mbssep.
1981         * modules/mbssep: New file.
1982         * lib/mbssep.c: New file.
1983         * lib/string_.h (strsep): Add a conditional link warning.
1984         (mbssep): New declaration.
1985         * m4/mbssep.m4: New file.
1986         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
1987         GNULIB_MBSSEP.
1988         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
1989         * MODULES.html.sh (Internationalization functions): Add mbssep.
1990
1991 2007-02-05  Bruno Haible  <bruno@clisp.org>
1992
1993         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
1994         Optimize search in case of 1 delimiter.
1995
1996 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
1997
1998         * lib/acl.h: Include sys/types.h before sys/acl.h.
1999
2000 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
2001
2002         Merge upstream fix for glibc bugzilla #3957:
2003
2004         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
2005
2006         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
2007         bit for RE_HAT_LISTS_NOT_NEWLINE.
2008         (build_charclass_op): Remove bogus comment.
2009
2010 2007-02-05  Simon Josefsson  <simon@josefsson.org>
2011
2012         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
2013
2014 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2015
2016         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
2017         * lib/memmem.c [!defined _LIBC]: Include config.h.
2018
2019 2007-02-04  Bruno Haible  <bruno@clisp.org>
2020
2021         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
2022         warning message.
2023
2024 2007-02-04  Bruno Haible  <bruno@clisp.org>
2025
2026         New module mbstok_r.
2027         * modules/mbstok_r: New file.
2028         * lib/mbstok_r.c: New file.
2029         * lib/string_.h (strtok_r): Change argument names to match the
2030         comments. Add a conditional link warning.
2031         (mbstok_r): New declaration.
2032         * m4/mbstok_r.m4: New file.
2033         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2034         GNULIB_MBSTOK_R.
2035         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
2036         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
2037
2038 2007-02-04  Bruno Haible  <bruno@clisp.org>
2039
2040         New module mbsspn.
2041         * modules/mbsspn: New file.
2042         * lib/mbsspn.c: New file.
2043         * lib/string_.h (strspn): Add a conditional link warning.
2044         (mbsspn): New declaration.
2045         * m4/mbsspn.m4: New file.
2046         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2047         GNULIB_MBSSPN.
2048         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
2049         * MODULES.html.sh (Internationalization functions): Add mbsspn.
2050
2051 2007-02-04  Bruno Haible  <bruno@clisp.org>
2052
2053         New module mbspbrk.
2054         * modules/mbspbrk: New file.
2055         * lib/mbspbrk.c: New file.
2056         * lib/string_.h (strpbrk): Add a conditional link warning.
2057         (mbspbrk): New declaration.
2058         * m4/mbspbrk.m4: New file.
2059         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2060         GNULIB_MBSPBRK.
2061         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
2062         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
2063
2064 2007-02-04  Bruno Haible  <bruno@clisp.org>
2065
2066         New module mbscspn.
2067         * modules/mbscspn: New file.
2068         * lib/mbscspn.c: New file.
2069         * lib/string_.h (strcspn): Add a conditional link warning.
2070         (mbscspn): New declaration.
2071         * m4/mbscspn.m4: New file.
2072         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2073         GNULIB_MBSCSPN.
2074         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
2075         * MODULES.html.sh (Internationalization functions): Add mbscspn.
2076
2077 2007-02-04  Bruno Haible  <bruno@clisp.org>
2078
2079         New module mbscasestr, reduced goal of strcasestr.
2080         * modules/mbscasestr: New file.
2081         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
2082         (mbscasestr): Renamed from strcasestr.
2083         * lib/strcasestr.c: Don't include mbuiter.h.
2084         (strcasestr): Remove support for multibyte locales.
2085         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
2086         Change the conditional link warning.
2087         (mbscasestr): New declaration.
2088         * m4/mbscasestr.m4: New file.
2089         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
2090         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
2091         REPLACE_STRCASESTR.
2092         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
2093         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2094         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2095         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
2096         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
2097         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2098         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
2099         (Depends-on): Remove mbuiter.
2100         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
2101
2102 2007-02-04  Bruno Haible  <bruno@clisp.org>
2103
2104         Simplify handling of strncasecmp.
2105         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
2106         the conditional link warning.
2107         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2108         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
2109         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
2110         * modules/strcase (configure.ac): Don't invoke
2111         gl_STRING_MODULE_INDICATOR.
2112         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
2113
2114 2007-02-04  Bruno Haible  <bruno@clisp.org>
2115
2116         New module mbscasecmp, reduced goal of strcasecmp.
2117         * modules/mbscasecmp: New file.
2118         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
2119         (mbscasecmp): Renamed from strcasecmp.
2120         * lib/strcasecmp.c: Don't include mbuiter.h.
2121         (strcasecmp): Remove support for multibyte locales.
2122         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
2123         Change the conditional link warning.
2124         (mbscasecmp): New declaration.
2125         * m4/mbscasecmp.m4: New file.
2126         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
2127         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
2128         REPLACE_STRCASECMP.
2129         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
2130         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2131         GNULIB_MBSCASECMP.
2132         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
2133         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
2134         * modules/strcase (Files): Remove m4/mbrtowc.m4.
2135         (Depends-on): Remove mbuiter.
2136         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
2137
2138 2007-02-04  Bruno Haible  <bruno@clisp.org>
2139
2140         New module mbsstr. Remove module strstr.
2141         * modules/mbsstr: New file.
2142         * modules/strstr: Remove file.
2143         * lib/mbsstr.c: Renamed from lib/strstr.c.
2144         (mbsstr): Renamed from strstr.
2145         * lib/string_.h (strstr): Remove declaration. Change the conditional
2146         link warning.
2147         (mbsstr): New declaration.
2148         * m4/mbsstr.m4: New file.
2149         * m4/strstr.m4: Remove file.
2150         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
2151         REPLACE_STRSTR.
2152         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
2153         Don't initialize GNULIB_STRSTR.
2154         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
2155         substitute GNULIB_STRSTR and REPLACE_STRSTR.
2156         * MODULES.html.sh (Internationalization functions): Add mbsstr.
2157         (Support for systems lacking ANSI C 89): Remove strstr.
2158
2159 2007-02-04  Bruno Haible  <bruno@clisp.org>
2160
2161         New module mbsrchr.
2162         * modules/mbsrchr: New file.
2163         * lib/mbsrchr.c: New file.
2164         * lib/string_.h (strrchr): Add a conditional link warning.
2165         (mbsrchr): New declaration.
2166         * m4/mbsrchr.m4: New file.
2167         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2168         GNULIB_MBSRCHR.
2169         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
2170         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
2171
2172 2007-02-04  Bruno Haible  <bruno@clisp.org>
2173
2174         New module mbschr.
2175         * modules/mbschr: New file.
2176         * lib/mbschr.c: New file.
2177         * lib/string_.h (strchr): Add a conditional link warning.
2178         (mbschr): New declaration.
2179         * m4/mbschr.m4: New file.
2180         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2181         GNULIB_MBSCHR.
2182         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
2183         * MODULES.html.sh (Internationalization functions): Add mbschr.
2184
2185 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2186
2187         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
2188
2189         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
2190
2191 2007-02-04  Bruno Haible  <bruno@clisp.org>
2192
2193         New module description section 'configure.ac-early'.
2194         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
2195         (func_get_autoconf_early_snippet): New function.
2196         (func_import, func_create_testdir): Use it. Remove special cases for
2197         modules 'extensions' and 'lock'.
2198         * modules/extensions (configure.ac-early): Require
2199         gl_USE_SYSTEM_EXTENSIONS.
2200         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
2201
2202 2007-02-04  Bruno Haible  <bruno@clisp.org>
2203
2204         Make use of gcj-4.3's -fsource and -ftarget option.
2205         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
2206         and if so try the options -fsource and -ftarget.
2207         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
2208         source_version, ftarget_option, target_version arguments.
2209         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
2210         (is_envjavac_oldgcj_14_14_usable): Renamed from
2211         is_envjavac_gcj_14_14_usable.
2212         (is_envjavac_oldgcj_14_13_usable): Renamed from
2213         is_envjavac_gcj_14_13_usable.
2214         (is_gcj_present): Update.
2215         (is_gcj_43, is_gcj43_usable): New functions.
2216         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
2217         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
2218         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
2219         try the options -fsource and -ftarget.
2220
2221 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
2222
2223         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
2224         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
2225         larger value.
2226
2227 2007-02-03  Jim Meyering  <jim@meyering.net>
2228
2229         Give tools a better chance to allocate space for very large buffers.
2230         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
2231
2232         Make pwd and readlink work also when run with an unreadable parent dir
2233         on systems with openat support.
2234         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
2235         provided getcwd function, even when we have openat support.
2236         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
2237
2238 2007-02-02  Bruno Haible  <bruno@clisp.org>
2239
2240         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2241         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
2242         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
2243         portability problems if one of these functions is only used on specific
2244         platforms.
2245         Reported by Paul Eggert.
2246
2247 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
2248
2249         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
2250         is causing more trouble than it's curing.
2251         * lib/regex_internal.h (__mempcpy): Remove.
2252         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
2253         (and make the code a tad smaller to boot).
2254         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
2255
2256 2007-02-02  Jim Meyering  <jim@meyering.net>
2257
2258         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
2259         section, not in the Makefile.am: one.
2260
2261 2007-02-02  Eric Blake  <ebb9@byu.net>
2262
2263         * lib/strchrnul.c: Always include config.h first.
2264
2265         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
2266         gnulib strstr is not necessary here.
2267
2268 2007-02-02  Simon Josefsson  <simon@josefsson.org>
2269
2270         * m4/socklen.m4: Fix typo.
2271
2272 2007-02-02  Eric Blake  <ebb9@byu.net>
2273
2274         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
2275         * modules/netinet_in (Makefile.am): Likewise.
2276
2277 2007-02-01  Bruno Haible  <bruno@clisp.org>
2278
2279         * lib/string_.h (GL_LINK_WARNING): New macro.
2280         (strcasecmp, strstr, strcasestr): If provided by the system,
2281         conditionally define as a macro that leads to a warning instead of to
2282         an error.
2283         (strncasecmp): Conditionally define as a macro that leads to a warning.
2284
2285 2007-02-01  Karl Berry  <karl@gnu.org>
2286
2287         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
2288
2289 2007-02-01  Bruno Haible  <bruno@clisp.org>
2290
2291         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
2292         renamings.
2293
2294 2007-02-01  Eric Blake  <ebb9@byu.net>
2295
2296         * modules/regex (Depends-on): Revert dependence on mempcpy.
2297         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
2298         module's definition of mempcpy.
2299         Reported by Paul Eggert.
2300
2301 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
2302
2303         * lib/string_.h: If the gnulib module XYZ is not present, undefine
2304         the symbol XYZ before redefining it.  This fixes a problem with
2305         programs that don't use XYZ, when compiled on systems that define
2306         XYZ to something else.
2307
2308 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
2309
2310         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
2311         occurs when "mkdir -m foo" creates a setgid directory that is (1)
2312         writeable to group or other and (2) is intended to have a special
2313         mode bit that is set or cleared.  In such a case, the directory
2314         should be neither group- nor other-writeable until the special
2315         mode bits are right.
2316
2317 2007-01-31  Eric Blake  <ebb9@byu.net>
2318
2319         * modules/mountlist (Depends-on): Add strstr.
2320
2321         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
2322         bug.
2323         * modules/string (Makefile.am): Remove redundant replacement.
2324         * modules/regex (Depends-on): Add mempcpy.
2325
2326 2007-01-31  Bruno Haible  <bruno@clisp.org>
2327
2328         New module description field 'Link'.
2329         * gnulib-tool (func_usage): Document --extract-link-directive.
2330         (sed_extract_prog): Recognize 'Link' directive.
2331         (func_get_link_directive): New function.
2332         (func_import): Show summary of link directives.
2333         Handle --extract-link-directive option.
2334         * modules/acl (Link): New section.
2335         * modules/clock-time (Link): New section.
2336         * modules/euidaccess (Link): New section.
2337         * modules/gettext (Link): New section.
2338         * modules/iconv (Link): New section.
2339         * modules/lock (Link): New section.
2340         * modules/nanosleep (Link): New section.
2341         * modules/readline (Link): New section.
2342
2343 2007-01-27  Bruno Haible  <bruno@clisp.org>
2344
2345         Enforce the use of gnulib modules for unportable <string.h> functions.
2346         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
2347         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
2348         (gl_HEADER_STRING_H_BODY): Require it.
2349         * lib/string_.h: If the gnulib module XYZ is not present, redefine
2350         the symbol XYZ to one that gives a link error.
2351         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
2352         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
2353         * modules/mempcpy (configure.ac): Likewise.
2354         * modules/memrchr (configure.ac): Likewise.
2355         * modules/stpcpy (configure.ac): Likewise.
2356         * modules/stpncpy (configure.ac): Likewise.
2357         * modules/strcase (configure.ac): Likewise.
2358         * modules/strcasestr (configure.ac): Likewise.
2359         * modules/strchrnul (configure.ac): Likewise.
2360         * modules/strdup (configure.ac): Likewise.
2361         * modules/strndup (configure.ac): Likewise.
2362         * modules/strnlen (configure.ac): Likewise.
2363         * modules/strpbrk (configure.ac): Likewise.
2364         * modules/strsep (configure.ac): Likewise.
2365         * modules/strstr (configure.ac): Likewise.
2366         * modules/strtok_r (configure.ac): Likewise.
2367
2368 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
2369
2370         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
2371
2372 2007-01-30  Jim Meyering  <jim@meyering.net>
2373
2374         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
2375
2376 2007-01-29  Bruno Haible  <bruno@clisp.org>
2377
2378         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
2379         * lib/execute.c: Likewise.
2380         * lib/pipe.c: Likewise.
2381         * lib/printf-args.h: Likewise.
2382         * lib/printf-args.c: Likewise.
2383         * lib/printf-parse.c: Likewise.
2384         * lib/vasnprintf.c: Likewise.
2385
2386 2007-01-29  Eric Blake  <ebb9@byu.net>
2387
2388         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
2389         declaration.
2390
2391 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
2392
2393         * lib/strptime.h (strptime): Use 'restrict' for args where
2394         POSIX requires this.
2395         * lib/strptime.c (strptime): Likewise.
2396         Change license notice from LGPL to GPL, since gnulib-tool will
2397         change this as needed.
2398         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
2399         defined.
2400         Include "strptime.h" first, to check interface.
2401         Do not #undef _LIBC and _NL_CURRENT.
2402         Do not include <stdlib.h>; no longer needed.
2403         Include "time_r.h" and declare ptime_locale_status
2404         only if _LIBC is not defined.
2405         (__P): Remove unused macro.
2406         (match_string): Bring back glibc version, but use it only if _LIBC
2407         is defined.
2408         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
2409         Remove unnecessary assertion and abort() call.
2410         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
2411         * m4/strptime.m4: Fix serial number comment.
2412         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
2413         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
2414         (Depends-on): Add time_r.
2415
2416 2007-01-29  Bruno Haible  <bruno@clisp.org>
2417
2418         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2419         strptime.
2420         * modules/strptime (Depends-on): Add stdbool.
2421         * lib/strptime.h: Include <time.h> always. Add comments.
2422
2423 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
2424
2425         * modules/strptime: New file.
2426         * lib/strptime.h: New file.
2427         * lib/strptime.c: New file.
2428         * m4/strptime.m4: New file.
2429
2430 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
2431
2432         * MODULES.html.sh: New module mpsort.
2433         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
2434
2435         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
2436         a circularity problem with HP-UX ia64 reported by Bob Proulx in
2437         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
2438         All uses changed.
2439         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
2440         All uses changed.
2441         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
2442         to _Restrict_.
2443         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
2444         the parameter matches the prototype.
2445
2446 2007-01-28  Jim Meyering  <jim@meyering.net>
2447
2448         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
2449         sys/time.h here, reverting that part of the previous patch:
2450         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
2451
2452 2007-01-28  Bruno Haible  <bruno@clisp.org>
2453
2454         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
2455         value of $(SYS_TIME_H).
2456         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
2457         remove it conditionally, too. [added by Jim Meyering]
2458         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
2459         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
2460         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
2461         GETTIMEOFDAY_REPLACEMENT to 1.
2462
2463 2007-01-28  Bruno Haible  <bruno@clisp.org>
2464
2465         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
2466         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
2467         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
2468         Set UNISTD_H instead of UNISTD_H2.
2469         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
2470
2471 2007-01-28  Bruno Haible  <bruno@clisp.org>
2472
2473         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
2474         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
2475
2476 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2477
2478         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
2479         (func_create_testdir): Ensure C locale for `grep' and `tr'
2480         character ranges.
2481         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
2482         ACLOCAL_AMFLAGS parsing state machine.
2483
2484 2007-01-27  Bruno Haible  <bruno@clisp.org>
2485
2486         * modules/unistr/base: Update.
2487
2488 2007-01-27  Bruno Haible  <bruno@clisp.org>
2489
2490         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
2491         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
2492         * modules/unistr/u32-mbtouc-unsafe: Renamed from
2493         modules/unistr/u32-mbtouc.
2494         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
2495         * lib/unistr.h: Update.
2496         * lib/linebreak.c: Update.
2497         * modules/unistr/u32-mbtouc: Renamed from
2498         modules/unistr/u32-mbtouc-safe.
2499         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
2500         * lib/unistr.h: Update.
2501         * lib/unistr/u32-to-u8.c: Update.
2502         * lib/unistr/u32-to-u16.c: Update.
2503
2504 2007-01-27  Bruno Haible  <bruno@clisp.org>
2505
2506         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
2507         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
2508         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
2509         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
2510         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
2511         * modules/unistr/u16-mbtouc-unsafe: Renamed from
2512         modules/unistr/u16-mbtouc.
2513         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
2514         * lib/unistr.h: Update.
2515         * lib/linebreak.c: Update.
2516         * modules/linebreak: Update.
2517         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
2518         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
2519         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
2520         * modules/unistr/u16-mbtouc: Renamed from
2521         modules/unistr/u16-mbtouc-safe.
2522         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
2523         * lib/unistr.h: Update.
2524         * lib/unistr/u16-to-u8.c: Update.
2525         * modules/unistr/u16-to-u8: Update.
2526         * lib/unistr/u16-to-u32.c: Update.
2527         * modules/unistr/u16-to-u32: Update.
2528
2529 2007-01-27  Bruno Haible  <bruno@clisp.org>
2530
2531         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
2532         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
2533         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
2534         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
2535         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
2536         * modules/unistr/u8-mbtouc-unsafe: Renamed from
2537         modules/unistr/u8-mbtouc.
2538         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
2539         * lib/unistr.h: Update.
2540         * lib/striconveh.c: Update.
2541         * modules/striconveh: Update.
2542         * lib/linebreak.c: Update.
2543         * modules/linebreak: Update.
2544         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
2545         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
2546         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
2547         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
2548         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
2549         * lib/unistr.h: Update.
2550         * lib/striconveh.c: Update.
2551         * modules/striconveh: Update.
2552         * lib/unistr/u8-to-u16.c: Update.
2553         * modules/unistr/u8-to-u16: Update.
2554         * lib/unistr/u8-to-u32.c: Update.
2555         * modules/unistr/u8-to-u32: Update.
2556
2557 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2558
2559         Sync from Libtool.
2560         * lib/argz.c: Do not include strings.h nor memory.h, include
2561         string.h unconditionally.  Patch by Simon Josefsson.
2562
2563 2007-01-27  Bruno Haible  <bruno@clisp.org>
2564
2565         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
2566         from gl_HEADER_STRING_H_BODY.
2567         (gl_HEADER_STRING_H_BODY): Require it.
2568         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
2569         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
2570         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
2571         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
2572         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
2573         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
2574         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
2575         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
2576         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
2577         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
2578         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
2579         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
2580         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
2581         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
2582         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2583
2584 2007-01-27  Bruno Haible  <bruno@clisp.org>
2585
2586         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
2587         check_PROGRAMS into noinst_PROGRAMS.
2588         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
2589         check_PROGRAMS in this case.
2590         (func_import): Set for_test to false.
2591         (func_create_testdir): Set for_test to true.
2592
2593 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
2594             Bruno Haible  <bruno@clisp.org>
2595
2596         * modules/strcasestr (Files): Remove lib/strcasestr.h.
2597         (Depends-on): Add string.
2598         (Includes): Use <string.h> instead of strcasestr.h.
2599         * modules/string (Makefile.am): Also substitute the value of
2600         REPLACE_STRCASESTR.
2601         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
2602         assume strcasestr is declared in <string.h> not <strings.h>. Also
2603         set REPLACE_STRCASESTR.
2604         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
2605         REPLACE_STRCASESTR.
2606         * lib/strcasestr.h: Remove file.
2607         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
2608         * lib/string_.h (strcasestr): New declaration.
2609
2610 2007-01-27  Bruno Haible  <bruno@clisp.org>
2611
2612         * lib/string_.h: Use 'extern'.
2613
2614 2007-01-27  Jim Meyering  <jim@meyering.net>
2615
2616         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
2617         of set-but-not-used local, "q".
2618
2619         * lib/mempcpy.c: Include <config.h> before <string.h>.
2620         This fixes a compilation error on HP-UX, due to the system's
2621         "restrict"-using mempcpy prototype.
2622
2623 2007-01-26  Bruno Haible  <bruno@clisp.org>
2624
2625         Small optimization.
2626         * lib/javacomp.c: Include c-strstr.h.
2627          (is_envjavac_gcj): Use c_strstr instead of strstr.
2628         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
2629
2630 2007-01-26  Bruno Haible  <bruno@clisp.org>
2631
2632         * MODULES.html.sh (Unicode string functions): Add the new modules.
2633
2634         * modules/uniconv/u32-strconv-to-locale: New file.
2635         * lib/uniconv/u32-strconv-to-locale.c: New file.
2636
2637         * modules/uniconv/u16-strconv-to-locale: New file.
2638         * lib/uniconv/u16-strconv-to-locale.c: New file.
2639
2640         * modules/uniconv/u8-strconv-to-locale: New file.
2641         * lib/uniconv/u8-strconv-to-locale.c: New file.
2642
2643         * modules/uniconv/u32-strconv-from-locale: New file.
2644         * lib/uniconv/u32-strconv-from-locale.c: New file.
2645
2646         * modules/uniconv/u16-strconv-from-locale: New file.
2647         * lib/uniconv/u16-strconv-from-locale.c: New file.
2648
2649         * modules/uniconv/u8-strconv-from-locale: New file.
2650         * lib/uniconv/u8-strconv-from-locale.c: New file.
2651
2652         * modules/uniconv/u32-strconv-to-enc: New file.
2653         * lib/uniconv/u32-strconv-to-enc.c: New file.
2654         * modules/uniconv/u32-strconv-to-enc-tests: New file.
2655         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
2656
2657         * modules/uniconv/u16-strconv-to-enc: New file.
2658         * lib/uniconv/u16-strconv-to-enc.c: New file.
2659         * lib/uniconv/u-strconv-to-enc.h: New file.
2660         * modules/uniconv/u16-strconv-to-enc-tests: New file.
2661         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
2662
2663         * modules/uniconv/u8-strconv-to-enc: New file.
2664         * lib/uniconv/u8-strconv-to-enc.c: New file.
2665         * modules/uniconv/u8-strconv-to-enc-tests: New file.
2666         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
2667
2668         * modules/uniconv/u32-strconv-from-enc: New file.
2669         * lib/uniconv/u32-strconv-from-enc.c: New file.
2670         * modules/uniconv/u32-strconv-from-enc-tests: New file.
2671         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
2672
2673         * modules/uniconv/u16-strconv-from-enc: New file.
2674         * lib/uniconv/u16-strconv-from-enc.c: New file.
2675         * modules/uniconv/u16-strconv-from-enc-tests: New file.
2676         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
2677
2678         * modules/uniconv/u8-strconv-from-enc: New file.
2679         * lib/uniconv/u8-strconv-from-enc.c: New file.
2680         * lib/uniconv/u-strconv-from-enc.h: New file.
2681         * modules/uniconv/u8-strconv-from-enc-tests: New file.
2682         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
2683
2684         * modules/uniconv/u32-conv-from-enc: New file.
2685         * lib/uniconv/u32-conv-from-enc.c: New file.
2686         * modules/uniconv/u32-conv-from-enc-tests: New file.
2687         * tests/uniconv/test-u32-conv-from-enc.c: New file.
2688
2689         * modules/uniconv/u16-conv-from-enc: New file.
2690         * lib/uniconv/u16-conv-from-enc.c: New file.
2691         * lib/uniconv/u-conv-from-enc.h: New file.
2692         * modules/uniconv/u16-conv-from-enc-tests: New file.
2693         * tests/uniconv/test-u16-conv-from-enc.c: New file.
2694
2695         * modules/uniconv/u8-conv-from-enc: New file.
2696         * lib/uniconv/u8-conv-from-enc.c: New file.
2697         * modules/uniconv/u8-conv-from-enc-tests: New file.
2698         * tests/uniconv/test-u8-conv-from-enc.c: New file.
2699
2700         * modules/uniconv/base: New file.
2701         * lib/uniconv.h: New file.
2702
2703 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
2704
2705         * doc/gnulib-tool.texi (Initial import): Update to match current
2706         behavior with strdup module.
2707         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
2708         * lib/memmem.h: Remove; all uses removed.  This is now done
2709         by <string.h>.
2710         * lib/mempcpy.h: Likewise.
2711         * lib/memrchr.h: Likewise.
2712         * lib/stpcpy.h: Likewise.
2713         * lib/stpncpy.h: Likewise.
2714         * lib/strcase.h: Likewise.
2715         * lib/strchrnul.h: Likewise.
2716         * lib/strdup.h: Likewise.
2717         * lib/strndup.h: Likewise.
2718         * lib/strnlen.h: Likewise.
2719         * lib/strpbrk.h: Likewise.
2720         * lib/strsep.h: Likewise.
2721         * lib/strstr.h: Likewise.
2722         * lib/strtok_r.h: Likewise.
2723         * lib/string_.h: New file.
2724         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
2725         Rely on <string.h> instead.
2726         * lib/canon-host.c: Likewise.
2727         * lib/chdir-long.c: Likewise.
2728         * lib/concatpath.c: Likewise.
2729         * lib/exclude.c: Likewise.
2730         * lib/fchdir.c: Likewise.
2731         * lib/getaddrinfo.c: Likewise.
2732         * lib/getcwd.c: Likewise.
2733         * lib/getsubopt.c: Likewise.
2734         * lib/glob.c: Likewise.
2735         * lib/hard-locale.c: Likewise.
2736         * lib/iconvme.c: Likewise.
2737         * lib/javacomp.c: Likewise.
2738         * lib/mempcpy.c: Likewise.
2739         * lib/memrchr.c: Likewise.
2740         * lib/regex_internal.h: Likewise.
2741         * lib/stpncpy.c: Likewise.
2742         * lib/strcasecmp.c: Likewise.
2743         * lib/strchrnul.c: Likewise.
2744         * lib/strdup.c: Likewise.
2745         * lib/striconv.c: Likewise.
2746         * lib/striconveh.c: Likewise.
2747         * lib/striconveha.c: Likewise.
2748         * lib/strncasecmp.c: Likewise.
2749         * lib/strndup.c: Likewise.
2750         * lib/strnlen.c: Likewise.
2751         * lib/strsep.c: Likewise.
2752         * lib/strstr.c: Likewise.
2753         * lib/strtok_r.c: Likewise.
2754         * lib/userspec.c: Likewise.
2755         * lib/w32spawn.h: Likewise.
2756         * lib/xstrndup.c: Likewise.
2757         * lib/mountlist.c (strstr): Remove decl.
2758         * m4/string_h.m4: New file.
2759         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
2760         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
2761         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
2762         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
2763         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
2764         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
2765         Set REPLACE_STRCASECMP if necessary.
2766         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
2767         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
2768         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
2769         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
2770         HAVE_DECL_STRDUP if necessary.
2771         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
2772         since gl_FUNC_STRNDUP does that now.
2773         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
2774         Check for decl here...
2775         (gl_PREREQ_STRNLEN): ... not here.
2776         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
2777         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
2778         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
2779         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
2780         necessary.
2781         * modules/string: New file.
2782         * modules/memmem (Files): Remove special-purpose include file.
2783         (Depends-on): Add string.
2784         (Include): Include <string.h>, not the removed file.
2785         * modules/mempcpy: Likewise.
2786         * modules/memrchr: Likewise.
2787         * modules/stpcpy: Likewise.
2788         * modules/stpncpy: Likewise.
2789         * modules/strcase: Likewise.
2790         * modules/strchrnul: Likewise.
2791         * modules/strdup: Likewise.
2792         * modules/strndup: Likewise.
2793         * modules/strnlen: Likewise.
2794         * modules/strpbrk: Likewise.
2795         * modules/strsep: Likewise.
2796         * modules/strstr: Likewise.
2797         * modules/strtok_r: Likewise.
2798         * tests/test-dirname.c: Don't include "strdup.h", since
2799         <string.h> now suffices.
2800         * tests/test-memmem.c: Don't include "memmem.h", since
2801         <string.h> now suffices.
2802
2803 2007-01-25  Bruno Haible  <bruno@clisp.org>
2804
2805         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
2806         *resultp is 0.
2807
2808         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
2809         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
2810         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
2811         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
2812
2813         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
2814         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
2815         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
2816         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
2817         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
2818         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
2819
2820 2007-01-24  Bruno Haible  <bruno@clisp.org>
2821
2822         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
2823         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
2824         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
2825         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
2826         gl_FUNC_FTS_CORE.
2827         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
2828         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
2829         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
2830         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
2831         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
2832         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
2833         gl_FUNC_FCHOWNAT.
2834         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
2835         gl_FUNC_STRFTIME.
2836         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
2837         Reported by Ralf Wildenhues.
2838
2839 2007-01-24  Bruno Haible  <bruno@clisp.org>
2840
2841         Drop AC_REQUIRE calls that are redundant with the module dependencies.
2842         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
2843         gl_GETADDRINFO.
2844         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
2845         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
2846         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
2847
2848 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
2849
2850         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
2851         Don't use 'exit'; just return from 'main'.
2852         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
2853
2854         * lib/fnmatch_.h: Readjust white space and comments to match
2855         glibc, to avoid spurious diffs.
2856
2857 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
2858
2859         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
2860         2004-12-01 change by Jakub Jelinek, since this code won't compile
2861         if !LIBC.  Problem reported by Bob Proulx.
2862
2863 2007-01-23  Bruno Haible  <bruno@clisp.org>
2864
2865         * lib/striconveh.c: Include c-strcaseeq.h.
2866         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
2867         * modules/striconveh (Depends-on): Add c-strcaseeq.
2868
2869 2007-01-23  Bruno Haible  <bruno@clisp.org>
2870
2871         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
2872
2873         * modules/c-strcaseeq: New file.
2874         * lib/c-strcaseeq.h: New file.
2875
2876         * modules/streq: New file.
2877         * lib/streq.h: New file.
2878
2879 2007-01-23  Bruno Haible  <bruno@clisp.org>
2880
2881         * modules/striconveha-tests: New file.
2882         * tests/test-striconveha.c: New file.
2883
2884         * lib/striconveha.h: Include <stdbool.h>.
2885         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
2886         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
2887         (mem_iconveha_notranslit): Renamed from mem_iconveha.
2888         (mem_iconveha): New function.
2889         (str_iconveha_notranslit): Renamed from str_iconveha.
2890         (str_iconveha): New function.
2891         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
2892         c-strcase.
2893
2894 2007-01-23  Bruno Haible  <bruno@clisp.org>
2895
2896         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
2897         encodings without forgiving before trying any encoding with handler.
2898         (str_iconveha): Try all encodings without forgiving before trying any
2899         encoding with handler.
2900
2901 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
2902
2903         Import the following changes from libc.
2904
2905         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
2906
2907         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
2908
2909         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
2910
2911         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
2912         normal_bracket label.
2913
2914         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
2915
2916         [BZ #361]
2917         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
2918         to normal_bracket after fetching the next character.
2919
2920 2007-01-22  Bruno Haible  <bruno@clisp.org>
2921
2922         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
2923         argument.
2924         * lib/striconveh.c (iconv_carefully_1): New function.
2925         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
2926         argument.
2927         (str_cd_iconveh): Update.
2928         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
2929         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
2930         * tests/test-striconveh.c (MAGIC): New macro.
2931         (new_offsets): New function.
2932         (main): Test call with and without offsets.
2933
2934 2007-01-22  Bruno Haible  <bruno@clisp.org>
2935
2936         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
2937         * modules/sys_select (Makefile.am): Likewise.
2938         * modules/sys_socket (Makefile.am): Likewise.
2939         * modules/sys_time (Makefile.am): Likewise.
2940
2941 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
2942
2943         * modules/gettimeofday (License): Change from GPL to LGPL, since
2944         gettimeofday is a library function.
2945
2946 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
2947
2948         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
2949
2950 2007-01-21  Bruno Haible  <bruno@clisp.org>
2951
2952         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
2953
2954 2007-01-21  Bruno Haible  <bruno@clisp.org>
2955
2956         * modules/striconveha: New file.
2957         * lib/striconveha.h: New file.
2958         * lib/striconveha.c: New file.
2959         * MODULES.html.sh (Internationalization functions): Add striconveha.
2960         * lib/striconv.c (str_iconv): Optimize the case of an empty input
2961         string.
2962         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
2963
2964 2007-01-21  Bruno Haible  <bruno@clisp.org>
2965
2966         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
2967         * lib/striconveh.c (str_iconveh): Likewise.
2968
2969 2007-01-21  Bruno Haible  <bruno@clisp.org>
2970
2971         * lib/striconveh.h (mem_iconveh): New declaration.
2972         * lib/striconveh.c (mem_iconveh): New function.
2973         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
2974
2975 2007-01-21  Bruno Haible  <bruno@clisp.org>
2976
2977         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
2978
2979         * lib/striconveh.h (mem_cd_iconveh): Change specification.
2980         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
2981         original result buffer.
2982         (str_cd_iconveh): Update.
2983         * tests/test-striconveh.c (main): Update.
2984
2985         * lib/striconv.h (mem_cd_iconv): Change specification.
2986         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
2987         result buffer.
2988         (str_cd_iconv): Update.
2989         * tests/test-striconv.c (main): Update.
2990
2991 2007-01-21  Bruno Haible  <bruno@clisp.org>
2992
2993         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
2994
2995 2007-01-20  Jim Meyering  <jim@meyering.net>
2996
2997         * lib/userspec.c (parse_with_separator): If a user or group string
2998         starts with "+", skip the corresponding name-to-ID look-up, since
2999         such a look-up must fail: user and group names may not include "+".
3000
3001 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
3002
3003         * lib/poll.c: Include sys/time.h and time.h unconditionally,
3004         since we now assume the sys_time module.
3005         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
3006         check for sys/time.h; no longer needed.
3007         * modules/poll (Depends-on): Depend on sys_time.
3008
3009 2007-01-18  Bruno Haible  <bruno@clisp.org>
3010
3011         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
3012         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3013
3014         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
3015         gettimeofday.
3016
3017         * tests/test-gettimeofday.c: Include <time.h>.
3018         (dummy): Remove variable.
3019
3020         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
3021         gl_HEADER_SYS_TIME_H.
3022         (gl_HEADER_SYS_TIME_H): New macro.
3023
3024         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
3025         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3026         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
3027         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
3028         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3029         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
3030         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
3031         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3032         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
3033         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
3034         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3035
3036         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
3037         last change; it caused a compilation error when cross-compiling to
3038         Cygwin.
3039
3040 2007-01-18  Jim Meyering  <jim@meyering.net>
3041
3042         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
3043         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
3044         than the race-prone "test -d sys || mkdir sys".
3045         (configure.ac): Use AC_PROG_MKDIR_P.
3046         * modules/sys_select: Likewise.
3047         * modules/sys_socket: Likewise.
3048         * modules/sys_time: Likewise.
3049
3050 2007-01-18  Eric Blake  <ebb9@byu.net>
3051
3052         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
3053         replace gettimeofday.
3054         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
3055         name, to avoid infinite recursion.
3056
3057 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
3058
3059         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
3060         module sys_time.
3061         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
3062         assume timespec.h defines struct timeval.
3063         * lib/settime.c: Likewise.
3064         * lib/utimens.c: Likewise.
3065         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
3066         since we now assume the gettimeofday module.
3067         * lib/tempname.c (__gen_tempname): Likewise.
3068         * lib/gettimeofday.h: Remove.
3069         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
3070         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
3071         Include <time.h>, for 'time()'.
3072         (localtime_buffer_addr): Also use this workaround if
3073         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
3074         to simplify the uses.  All uses changed.
3075         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
3076         that #undef is inside {}, and 'const' follows type name consistently.
3077         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
3078         (gettimeofday): Do not use the maximum possible value for
3079         tv->tv_usec, since that might break usages other than ls.c.
3080         Instead, we'll leave ls.c alone.  This undoes today's patch
3081         by Bruno.  Add a compile-time warning for 1s-clock resolution;
3082         we've never observed the problem but might as well keep the
3083         canary.
3084         * lib/nanosleep.c: Include timespec.h first, for interface check.
3085         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
3086         now assume the sys_time module.
3087         * lib/tempname.c: Likewise.
3088         * lib/timespec.h: Likewise.
3089         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
3090         needed.
3091         * lib/strftime.c: Likewise.
3092         * lib/timespec.h: Likewise.
3093         * lib/posixtm.c: Include posixtm.h first, for interface check.
3094         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
3095         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
3096         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
3097         * lib/sys_time_.h: New file.
3098         * lib/timespec.h (struct timespec): Use long int, not long.
3099         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3100         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
3101         Remove obsolescent call to AC_HEADER_TIME.
3102         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
3103         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
3104         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3105         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
3106         Likewise.
3107         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
3108         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
3109         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
3110         into the sys_time module.  Check for gettimeofday just once.
3111         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
3112         for gettimeofday signature to just check the signature.  Merely
3113         compile it, since linking doesn't test signature.  Improve test for
3114         whether gettimeofday.o is actually needed.
3115         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
3116         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
3117         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
3118         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3119         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
3120         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
3121         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
3122         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
3123         than worrying about sys/time.h.
3124         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
3125         Don't bother worrying about TIME_WITH_SYS_TIME.
3126         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
3127         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
3128         * m4/sys_time_h.m4: New file.
3129         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
3130         Don't include sys/time.h.  Return from main rather than exiting.
3131         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
3132         all uses changed.
3133         * modules/gethrxtime (Depends-on): Add sys_time.
3134         * modules/gettime (Depends-on): Likewise.
3135         * modules/gettimeofday (Depends-on): Likewise.
3136         * modules/nanosleep (Depends-on): Likewise.
3137         * modules/settime (Depends-on): Likewise.
3138         * modules/tempname (Depends-on): Likewise.
3139         * modules/utimens (Depends-on): Likewise.
3140         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
3141         (Include:) Change back to <sys/time.h>.
3142         (Maintainer:) Add self.
3143         * modules/sys_time: New file.
3144         * modules/tempname (Depends-on): Add gettimeofday.
3145         * tests/test-gettimeofday.c: Include <sys/time.h>
3146         rather than gettimeofday.h.
3147
3148 2007-01-17  Bruno Haible  <bruno@clisp.org>
3149
3150         * gnulib-tool (func_get_license): Revert last patch. Instead, let
3151         the license default to GPL.
3152         (func_create_testdir): Don't complain if a module is LGPL and its
3153         tests module depends on GPLed modules.
3154
3155 2007-01-17  Bruno Haible  <bruno@clisp.org>
3156
3157         * lib/gettimeofday.c (gettimeofday): Add code for the case
3158         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
3159         maximum possible value for tv->tv_usec, rather than the minimum one.
3160
3161 2005-10-08  Martin Lambers  <marlam@marlam.de>
3162 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
3163 2007-01-16  Bruno Haible  <bruno@clisp.org>
3164
3165         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
3166         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
3167         gl_FUNC_GETTIMEOFDAY.
3168         (Include): Add gettimeofday.h.
3169         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
3170         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
3171         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
3172         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
3173         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
3174         * lib/gettimeofday.h: New file.
3175         * lib/gettimeofday.c: Include <sys/timeb.h>.
3176         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
3177         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3178         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
3179         fall back on time().
3180
3181         * tests/test-gettimeofday.c: New file.
3182         * modules/gettimeofday-tests: New file.
3183
3184 2007-01-16  Eric Blake  <ebb9@byu.net>
3185
3186         * modules/fnmatch (Depends-on): Depend on wchar.
3187         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
3188         * m4/fnmatch.m4: Likewise.
3189         * modules/mbchar (Makefile.am): Assume <wchar.h>.
3190         * m4/mbchar.m4: Likewise.
3191         * modules/mbswidth (Depends-on): Depend on wchar.
3192         * lib/mbswidth.c: Assume <wchar.h>.
3193         * m4/mbswidth.m4: Likewise.
3194         * modules/quotearg (Depends-on): Depend on wchar.
3195         * lib/quotearg.c: Assume <wchar.h>.
3196         * m4/quotearg.m4: Likewise.
3197         * modules/regex (Depends-on): Depend on wchar.
3198         * lib/regex_internal.h: Assume <wchar.h>.
3199         * m4/regex.m4: Likewise.
3200         * modules/stdint (Depends-on): Depend on wchar.
3201         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
3202         * m4/stdint.m4: Likewise.
3203         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
3204         * modules/strftime (Depends-on): Depend on wchar.
3205         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
3206         * modules/strtol (Depends-on): Depend on wchar.
3207         * lib/strtol.c: Assume <wchar.h>.
3208         * modules/wcwidth (Depends-on): Depend on wchar.
3209         * lib/wcwidth.h: Assume <wchar.h>.
3210         * m4/wcwidth.m4: Likewise.
3211
3212 2007-01-16  Bruno Haible  <bruno@clisp.org>
3213
3214         * modules/csharpexec-script: New, created from...
3215         * modules/csharpexec: ... this.
3216
3217 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
3218
3219         * modules/javaexec-script: New, created from...
3220         * modules/javaexec: ... this.
3221
3222 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
3223
3224         * modules/poll (Dependencies): Add sys_select.
3225
3226 2007-01-15  Jim Meyering  <jim@meyering.net>
3227
3228         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
3229         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
3230         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
3231         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
3232
3233 2007-01-15  Bruno Haible  <bruno@clisp.org>
3234
3235         * modules/striconveh: New file.
3236         * lib/striconveh.h: New file.
3237         * lib/striconveh.c: New file.
3238         * MODULES.html.sh (Internationalization functions): Add striconveh.
3239
3240         * modules/striconveh-tests: New file.
3241         * tests/test-striconveh.c: New file.
3242
3243 2007-01-15  Bruno Haible  <bruno@clisp.org>
3244
3245         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
3246         not from GNU libiconv or GNU libc.
3247
3248 2007-01-15  Bruno Haible  <bruno@clisp.org>
3249
3250         * doc/gnulib-intro.texi (Copyright): Explain the different license
3251         terms for module descriptions, autoconf macros, tests, documentation.
3252
3253 2007-01-14  Bruno Haible  <bruno@clisp.org>
3254
3255         * modules/striconv-tests: New file.
3256         * tests/test-striconv.c: New file.
3257
3258 2007-01-14  Bruno Haible  <bruno@clisp.org>
3259
3260         * modules/iconv-tests: New file.
3261         * tests/test-iconv.c: New file.
3262
3263 2007-01-14  Bruno Haible  <bruno@clisp.org>
3264
3265         * gnulib-tool (func_get_license): For test modules, use the license of
3266         the main module.
3267
3268 2007-01-14  Bruno Haible  <bruno@clisp.org>
3269
3270         * modules/iconv (Include): Clarify that <iconv.h> can only be included
3271         if iconv is found to exist.
3272
3273 2007-01-14  Bruno Haible  <bruno@clisp.org>
3274
3275         * modules/c-ctype-tests: New file.
3276         * tests/test-c-ctype.c: New file.
3277
3278 2007-01-14  Bruno Haible  <bruno@clisp.org>
3279
3280         * modules/binary-io-tests: New file.
3281         * tests/test-binary-io.sh: New file.
3282         * tests/test-binary-io.c: New file.
3283
3284 2007-01-14  Bruno Haible  <bruno@clisp.org>
3285
3286         * modules/array-oset-tests: New file.
3287         * tests/test-array_oset.c: New file.
3288
3289 2007-01-14  Bruno Haible  <bruno@clisp.org>
3290
3291         * modules/array-list-tests: New file.
3292         * tests/test-array_list.c: New file.
3293
3294 2007-01-14  Bruno Haible  <bruno@clisp.org>
3295
3296         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
3297         and make.
3298         Reported by Simon Josefsson in
3299         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
3300
3301 2007-01-14  Bruno Haible  <bruno@clisp.org>
3302
3303         * modules/allocsa-tests: New file.
3304         * tests/test-allocsa.c: New file.
3305
3306 2007-01-14  Bruno Haible  <bruno@clisp.org>
3307
3308         * modules/fchdir (Depends-on): Add absolute-header.
3309         * modules/unistd (Depends-on): Likewise.
3310
3311 2006-12-30  Bruno Haible  <bruno@clisp.org>
3312
3313         * modules/fchdir: New file.
3314         * modules/unistd (Files): Add lib/unistd_.h.
3315         (Makefile.am): Generate unistd.h from unistd_.h.
3316         * lib/fchdir.c: New file.
3317         * lib/dirent_.h: New file.
3318         * lib/unistd_.h: New file.
3319         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
3320         * m4/fchdir.m4: New file.
3321         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
3322         (gl_HEADER_UNISTD): Invoke it.
3323         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
3324         function.
3325         * lib/backupfile.c (opendir, closedir): Undefine.
3326         * lib/chown.c (open, close): Undefine.
3327         * lib/clean-temp.c (open, close): Undefine.
3328         * lib/copy-file.c (open, close): Undefine.
3329         * lib/execute.c (open, close): Undefine.
3330         * lib/fsusage.c (open, close): Undefine.
3331         * lib/gc-gnulib.c (open, close): Undefine.
3332         * lib/getcwd.c (opendir, closedir): Undefine.
3333         * lib/glob.c (opendir, closedir): Undefine.
3334         * lib/javacomp.c (open, close): Undefine.
3335         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
3336         * lib/openat-proc.c (open, close): Undefine.
3337         * lib/pagealign_alloc.c (open, close): Undefine.
3338         * lib/pipe.c (open, close): Undefine.
3339         * lib/progreloc.c (open, close): Undefine.
3340         * lib/savedir.c (opendir, closedir): Undefine.
3341         * lib/utime.c (open, close): Undefine.
3342         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
3343
3344 2007-01-10  Bruno Haible  <bruno@clisp.org>
3345
3346         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
3347
3348 2007-01-12  Eric Blake  <ebb9@byu.net>
3349
3350         Provide a robust <wchar.h>.  Further simplifications are now
3351         possible in other modules, but not included here.
3352         * modules/wchar: New module.
3353         * m4/wchar.m4: New file.
3354         * lib/wchar_.h: Likewise.
3355         * modules/mbchar (Depends-on): Depend on wchar, as the first use
3356         of the new module.
3357         * MODULES.html.sh (Extended multibyte and wide character utilities):
3358         New section.
3359
3360 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
3361
3362         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
3363         to a reasonable default for memory allocation.
3364         (xreadlink): Don't allocate a huge buffer, to work around a buggy
3365         file system that reports garbage st_size values for symlinks.
3366         Problem reported by Liyang Hu.
3367
3368 2007-01-11  Simon Josefsson  <simon@josefsson.org>
3369
3370         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
3371         Emacs .#* auto-save files).
3372
3373 2007-01-11  Bruno Haible  <bruno@clisp.org>
3374
3375         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
3376         directory.
3377
3378 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
3379
3380         Use @...@ consistently in lib/wctype_.h.
3381         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
3382         on it being set to 1 or 0.
3383         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
3384         go back to AC_SUBSTing it.
3385         * modules/wctype (Makefile.am): Undo previous change.
3386
3387 2007-01-10  Eric Blake  <ebb9@byu.net>
3388
3389         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
3390         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
3391         * modules/wctype (Makefile.am): Likewise.
3392         Reported by Chris McGuire.
3393
3394 2007-01-10  Jim Meyering  <jim@meyering.net>
3395
3396         fts.c: a small readability/maintainability improvement
3397         * lib/fts.c (fts_read): Make this code slightly more readable and
3398         maintainable by hoisting the "sp->fts_cur = p" assignments to
3399         immediately follow the statements that set P.  Derived from
3400         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
3401
3402 2007-01-10  Eric Blake  <ebb9@byu.net>
3403
3404         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
3405         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
3406         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
3407         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
3408         Reported by Chris McGuire.
3409
3410 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3411
3412         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
3413         in sed script.
3414
3415 2007-01-09  Bruno Haible  <bruno@clisp.org>
3416
3417         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
3418         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
3419         variables.
3420         (func_module): Use them.
3421
3422 2007-01-09  Bruno Haible  <bruno@clisp.org>
3423
3424         * modules/unistr/base: New file.
3425         * lib/unistr.h: New file.
3426
3427         * modules/unistr/u8-to-u16: New file.
3428         * lib/unistr/u8-to-u16.c: New file.
3429
3430         * modules/unistr/u8-to-u32: New file.
3431         * lib/unistr/u8-to-u32.c: New file.
3432
3433         * modules/unistr/u16-to-u8: New file.
3434         * lib/unistr/u16-to-u8.c: New file.
3435
3436         * modules/unistr/u16-to-u32: New file.
3437         * lib/unistr/u16-to-u32.c: New file.
3438
3439         * modules/unistr/u32-to-u8: New file.
3440         * lib/unistr/u32-to-u8.c: New file.
3441
3442         * modules/unistr/u32-to-u16: New file.
3443         * lib/unistr/u32-to-u16.c: New file.
3444
3445         * modules/unistr/u8-check: New file.
3446         * modules/unistr/u16-check: New file.
3447         * modules/unistr/u32-check: New file.
3448         * lib/unistr/u8-check.c: New file.
3449         * lib/unistr/u16-check.c: New file.
3450         * lib/unistr/u32-check.c: New file.
3451
3452         * modules/unistr/u8-chr: New file.
3453         * modules/unistr/u16-chr: New file.
3454         * modules/unistr/u32-chr: New file.
3455         * lib/unistr/u8-chr.c: New file.
3456         * lib/unistr/u16-chr.c: New file.
3457         * lib/unistr/u32-chr.c: New file.
3458
3459         * modules/unistr/u8-cmp: New file.
3460         * modules/unistr/u16-cmp: New file.
3461         * modules/unistr/u32-cmp: New file.
3462         * lib/unistr/u8-cmp.c: New file.
3463         * lib/unistr/u16-cmp.c: New file.
3464         * lib/unistr/u32-cmp.c: New file.
3465
3466         * modules/unistr/u8-cpy: New file.
3467         * modules/unistr/u16-cpy: New file.
3468         * modules/unistr/u32-cpy: New file.
3469         * lib/unistr/u8-cpy.c: New file.
3470         * lib/unistr/u16-cpy.c: New file.
3471         * lib/unistr/u32-cpy.c: New file.
3472         * lib/unistr/u-cpy.h: New file.
3473
3474         * modules/unistr/u8-cpy-alloc: New file.
3475         * modules/unistr/u16-cpy-alloc: New file.
3476         * modules/unistr/u32-cpy-alloc: New file.
3477         * lib/unistr/u8-cpy-alloc.c: New file.
3478         * lib/unistr/u16-cpy-alloc.c: New file.
3479         * lib/unistr/u32-cpy-alloc.c: New file.
3480         * lib/unistr/u-cpy-alloc.h: New file.
3481
3482         * modules/unistr/u8-endswith: New file.
3483         * modules/unistr/u16-endswith: New file.
3484         * modules/unistr/u32-endswith: New file.
3485         * lib/unistr/u8-endswith.c: New file.
3486         * lib/unistr/u16-endswith.c: New file.
3487         * lib/unistr/u32-endswith.c: New file.
3488         * lib/unistr/u-endswith.h: New file.
3489
3490         * modules/unistr/u8-mblen: New file.
3491         * modules/unistr/u16-mblen: New file.
3492         * modules/unistr/u32-mblen: New file.
3493         * lib/unistr/u8-mblen.c: New file.
3494         * lib/unistr/u16-mblen.c: New file.
3495         * lib/unistr/u32-mblen.c: New file.
3496
3497         * modules/unistr/u8-mbtouc: New file.
3498         * modules/unistr/u16-mbtouc: New file.
3499         * modules/unistr/u32-mbtouc: New file.
3500         * lib/unistr/u8-mbtouc.c: New file.
3501         * lib/unistr/u16-mbtouc.c: New file.
3502         * lib/unistr/u32-mbtouc.c: New file.
3503
3504         * modules/unistr/u8-mbtouc-safe: New file.
3505         * modules/unistr/u16-mbtouc-safe: New file.
3506         * modules/unistr/u32-mbtouc-safe: New file.
3507         * lib/unistr/u8-mbtouc-safe.c: New file.
3508         * lib/unistr/u16-mbtouc-safe.c: New file.
3509         * lib/unistr/u32-mbtouc-safe.c: New file.
3510
3511         * modules/unistr/u8-move: New file.
3512         * modules/unistr/u16-move: New file.
3513         * modules/unistr/u32-move: New file.
3514         * lib/unistr/u8-move.c: New file.
3515         * lib/unistr/u16-move.c: New file.
3516         * lib/unistr/u32-move.c: New file.
3517         * lib/unistr/u-move.h: New file.
3518
3519         * modules/unistr/u8-next: New file.
3520         * modules/unistr/u16-next: New file.
3521         * modules/unistr/u32-next: New file.
3522         * lib/unistr/u8-next.c: New file.
3523         * lib/unistr/u16-next.c: New file.
3524         * lib/unistr/u32-next.c: New file.
3525
3526         * modules/unistr/u8-prev: New file.
3527         * modules/unistr/u16-prev: New file.
3528         * modules/unistr/u32-prev: New file.
3529         * lib/unistr/u8-prev.c: New file.
3530         * lib/unistr/u16-prev.c: New file.
3531         * lib/unistr/u32-prev.c: New file.
3532
3533         * modules/unistr/u8-set: New file.
3534         * modules/unistr/u16-set: New file.
3535         * modules/unistr/u32-set: New file.
3536         * lib/unistr/u8-set.c: New file.
3537         * lib/unistr/u16-set.c: New file.
3538         * lib/unistr/u32-set.c: New file.
3539         * lib/unistr/u-set.h: New file.
3540
3541         * modules/unistr/u8-startswith: New file.
3542         * modules/unistr/u16-startswith: New file.
3543         * modules/unistr/u32-startswith: New file.
3544         * lib/unistr/u8-startswith.c: New file.
3545         * lib/unistr/u16-startswith.c: New file.
3546         * lib/unistr/u32-startswith.c: New file.
3547         * lib/unistr/u-startswith.h: New file.
3548
3549         * modules/unistr/u8-stpcpy: New file.
3550         * modules/unistr/u16-stpcpy: New file.
3551         * modules/unistr/u32-stpcpy: New file.
3552         * lib/unistr/u8-stpcpy.c: New file.
3553         * lib/unistr/u16-stpcpy.c: New file.
3554         * lib/unistr/u32-stpcpy.c: New file.
3555         * lib/unistr/u-stpcpy.h: New file.
3556
3557         * modules/unistr/u8-stpncpy: New file.
3558         * modules/unistr/u16-stpncpy: New file.
3559         * modules/unistr/u32-stpncpy: New file.
3560         * lib/unistr/u8-stpncpy.c: New file.
3561         * lib/unistr/u16-stpncpy.c: New file.
3562         * lib/unistr/u32-stpncpy.c: New file.
3563         * lib/unistr/u-stpncpy.h: New file.
3564
3565         * modules/unistr/u8-strcat: New file.
3566         * modules/unistr/u16-strcat: New file.
3567         * modules/unistr/u32-strcat: New file.
3568         * lib/unistr/u8-strcat.c: New file.
3569         * lib/unistr/u16-strcat.c: New file.
3570         * lib/unistr/u32-strcat.c: New file.
3571         * lib/unistr/u-strcat.h: New file.
3572
3573         * modules/unistr/u8-strchr: New file.
3574         * modules/unistr/u16-strchr: New file.
3575         * modules/unistr/u32-strchr: New file.
3576         * lib/unistr/u8-strchr.c: New file.
3577         * lib/unistr/u16-strchr.c: New file.
3578         * lib/unistr/u32-strchr.c: New file.
3579
3580         * modules/unistr/u8-strcmp: New file.
3581         * modules/unistr/u16-strcmp: New file.
3582         * modules/unistr/u32-strcmp: New file.
3583         * lib/unistr/u8-strcmp.c: New file.
3584         * lib/unistr/u16-strcmp.c: New file.
3585         * lib/unistr/u32-strcmp.c: New file.
3586
3587         * modules/unistr/u8-strcpy: New file.
3588         * modules/unistr/u16-strcpy: New file.
3589         * modules/unistr/u32-strcpy: New file.
3590         * lib/unistr/u8-strcpy.c: New file.
3591         * lib/unistr/u16-strcpy.c: New file.
3592         * lib/unistr/u32-strcpy.c: New file.
3593         * lib/unistr/u-strcpy.h: New file.
3594
3595         * modules/unistr/u8-strcspn: New file.
3596         * modules/unistr/u16-strcspn: New file.
3597         * modules/unistr/u32-strcspn: New file.
3598         * lib/unistr/u8-strcspn.c: New file.
3599         * lib/unistr/u16-strcspn.c: New file.
3600         * lib/unistr/u32-strcspn.c: New file.
3601         * lib/unistr/u-strcspn.h: New file.
3602
3603         * modules/unistr/u8-strdup: New file.
3604         * modules/unistr/u16-strdup: New file.
3605         * modules/unistr/u32-strdup: New file.
3606         * lib/unistr/u8-strdup.c: New file.
3607         * lib/unistr/u16-strdup.c: New file.
3608         * lib/unistr/u32-strdup.c: New file.
3609         * lib/unistr/u-strdup.h: New file.
3610
3611         * modules/unistr/u8-strlen: New file.
3612         * modules/unistr/u16-strlen: New file.
3613         * modules/unistr/u32-strlen: New file.
3614         * lib/unistr/u8-strlen.c: New file.
3615         * lib/unistr/u16-strlen.c: New file.
3616         * lib/unistr/u32-strlen.c: New file.
3617         * lib/unistr/u-strlen.h: New file.
3618
3619         * modules/unistr/u8-strmblen: New file.
3620         * modules/unistr/u16-strmblen: New file.
3621         * modules/unistr/u32-strmblen: New file.
3622         * lib/unistr/u8-strmblen.c: New file.
3623         * lib/unistr/u16-strmblen.c: New file.
3624         * lib/unistr/u32-strmblen.c: New file.
3625
3626         * modules/unistr/u8-strmbtouc: New file.
3627         * modules/unistr/u16-strmbtouc: New file.
3628         * modules/unistr/u32-strmbtouc: New file.
3629         * lib/unistr/u8-strmbtouc.c: New file.
3630         * lib/unistr/u16-strmbtouc.c: New file.
3631         * lib/unistr/u32-strmbtouc.c: New file.
3632
3633         * modules/unistr/u8-strncat: New file.
3634         * modules/unistr/u16-strncat: New file.
3635         * modules/unistr/u32-strncat: New file.
3636         * lib/unistr/u8-strncat.c: New file.
3637         * lib/unistr/u16-strncat.c: New file.
3638         * lib/unistr/u32-strncat.c: New file.
3639         * lib/unistr/u-strncat.h: New file.
3640
3641         * modules/unistr/u8-strncmp: New file.
3642         * modules/unistr/u16-strncmp: New file.
3643         * modules/unistr/u32-strncmp: New file.
3644         * lib/unistr/u8-strncmp.c: New file.
3645         * lib/unistr/u16-strncmp.c: New file.
3646         * lib/unistr/u32-strncmp.c: New file.
3647
3648         * modules/unistr/u8-strncpy: New file.
3649         * modules/unistr/u16-strncpy: New file.
3650         * modules/unistr/u32-strncpy: New file.
3651         * lib/unistr/u8-strncpy.c: New file.
3652         * lib/unistr/u16-strncpy.c: New file.
3653         * lib/unistr/u32-strncpy.c: New file.
3654         * lib/unistr/u-strncpy.h: New file.
3655
3656         * modules/unistr/u8-strnlen: New file.
3657         * modules/unistr/u16-strnlen: New file.
3658         * modules/unistr/u32-strnlen: New file.
3659         * lib/unistr/u8-strnlen.c: New file.
3660         * lib/unistr/u16-strnlen.c: New file.
3661         * lib/unistr/u32-strnlen.c: New file.
3662         * lib/unistr/u-strnlen.h: New file.
3663
3664         * modules/unistr/u8-strpbrk: New file.
3665         * modules/unistr/u16-strpbrk: New file.
3666         * modules/unistr/u32-strpbrk: New file.
3667         * lib/unistr/u8-strpbrk.c: New file.
3668         * lib/unistr/u16-strpbrk.c: New file.
3669         * lib/unistr/u32-strpbrk.c: New file.
3670         * lib/unistr/u-strpbrk.h: New file.
3671
3672         * modules/unistr/u8-strrchr: New file.
3673         * modules/unistr/u16-strrchr: New file.
3674         * modules/unistr/u32-strrchr: New file.
3675         * lib/unistr/u8-strrchr.c: New file.
3676         * lib/unistr/u16-strrchr.c: New file.
3677         * lib/unistr/u32-strrchr.c: New file.
3678
3679         * modules/unistr/u8-strspn: New file.
3680         * modules/unistr/u16-strspn: New file.
3681         * modules/unistr/u32-strspn: New file.
3682         * lib/unistr/u8-strspn.c: New file.
3683         * lib/unistr/u16-strspn.c: New file.
3684         * lib/unistr/u32-strspn.c: New file.
3685         * lib/unistr/u-strspn.h: New file.
3686
3687         * modules/unistr/u8-strstr: New file.
3688         * modules/unistr/u16-strstr: New file.
3689         * modules/unistr/u32-strstr: New file.
3690         * lib/unistr/u8-strstr.c: New file.
3691         * lib/unistr/u16-strstr.c: New file.
3692         * lib/unistr/u32-strstr.c: New file.
3693         * lib/unistr/u-strstr.h: New file.
3694
3695         * modules/unistr/u8-strtok: New file.
3696         * modules/unistr/u16-strtok: New file.
3697         * modules/unistr/u32-strtok: New file.
3698         * lib/unistr/u8-strtok.c: New file.
3699         * lib/unistr/u16-strtok.c: New file.
3700         * lib/unistr/u32-strtok.c: New file.
3701         * lib/unistr/u-strtok.h: New file.
3702
3703         * modules/unistr/u8-uctomb: New file.
3704         * modules/unistr/u16-uctomb: New file.
3705         * modules/unistr/u32-uctomb: New file.
3706         * lib/unistr/u8-uctomb.c: New file.
3707         * lib/unistr/u16-uctomb.c: New file.
3708         * lib/unistr/u32-uctomb.c: New file.
3709
3710         * MODULES.html.sh (Unicode string functions): Add the new modules.
3711
3712 2007-01-08  Bruno Haible  <bruno@clisp.org>
3713
3714         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
3715         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
3716         subdirectories.
3717
3718 2007-01-08  Karl Berry  <karl@gnu.org>
3719
3720         * doc/error.texi: mention that main() fns must set program_name
3721         when progname is used.
3722
3723 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
3724
3725         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
3726         WCTYPE_H is empty, for the benefit of builds from non-distclean
3727         directories.  Problem reported by Eric Blake in
3728         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
3729
3730 2007-01-08  Bruno Haible  <bruno@clisp.org>
3731
3732         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
3733         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
3734         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
3735         PROVIDE_CANONICALIZE_FILENAME_MODE.
3736         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
3737
3738 2007-01-08  Bruno Haible  <bruno@clisp.org>
3739
3740         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
3741         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
3742         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
3743         * lib/fts.c: Likewise.
3744         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
3745
3746 2006-12-25  Bruno Haible  <bruno@clisp.org>
3747
3748         * modules/utf8-ucs4-safe: New file.
3749         * lib/utf8-ucs4-safe.h: New file.
3750         * lib/unistr/utf8-ucs4-safe.c: New file.
3751
3752         * modules/utf16-ucs4-safe: New file.
3753         * lib/utf16-ucs4-safe.h: New file.
3754         * lib/unistr/utf16-ucs4-safe.c: New file.
3755
3756         * MODULES.html.sh (Unicode string functions): Add the new modules.
3757
3758 2007-01-08  Bruno Haible  <bruno@clisp.org>
3759
3760         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
3761         (Depends-on): Add unitypes.
3762         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
3763         (u8_mbtouc_aux): Move out to separate file.
3764         (u8_mbtouc): Use ucs4_t, uint8_t types.
3765         * lib/unistr/utf8-ucs4.c: New file.
3766
3767         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
3768         (Depends-on): Add unitypes.
3769         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
3770         (u16_mbtouc_aux): Move out to separate file.
3771         (u16_mbtouc): Use ucs4_t, uint16_t types.
3772         * lib/unistr/utf16-ucs4.c: New file.
3773
3774         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
3775         (Depends-on): Add unitypes.
3776         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
3777         (u8_uctomb_aux): Move out to separate file.
3778         (u8_uctomb): Use ucs4_t, uint8_t types.
3779         * lib/unistr/ucs4-utf8.c: New file.
3780
3781         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
3782         (Depends-on): Add unitypes.
3783         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
3784         (u16_uctomb_aux): Move out to separate file.
3785         (u16_uctomb): Use ucs4_t, uint16_t types.
3786         * lib/unistr/ucs4-utf16.c: New file.
3787
3788 2006-12-25  Bruno Haible  <bruno@clisp.org>
3789
3790         * modules/unitypes: New file.
3791         * lib/unitypes.h: New file.
3792         * MODULES.html.sh (func_all_modules): New section "Unicode string
3793         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
3794         this section. Add unitypes.
3795
3796 2007-01-08  Bruno Haible  <bruno@clisp.org>
3797
3798         Avoid variable names that conflict with those from libtool.
3799         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
3800         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
3801         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
3802         library_names_spec to acl_library_names_spec, hardcode_* to
3803         acl_hardcode_*.
3804         Reported by Ralf Wildenhues.
3805
3806 2007-01-08  Bruno Haible  <bruno@clisp.org>
3807
3808         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
3809         definition.
3810         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
3811         definition.
3812         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
3813         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
3814         definition.
3815         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
3816         definition.
3817         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
3818         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
3819         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
3820         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
3821         definition.
3822         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
3823         definition.
3824         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
3825         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
3826         GC_USE_<algorithm>.
3827         * lib/gc-libgcrypt.c: Likewise.
3828         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
3829         * modules/gc-arctwo (configure.ac): Likewise.
3830         * modules/gc-des (configure.ac): Likewise.
3831         * modules/gc-hmac-md5 (configure.ac): Likewise.
3832         * modules/gc-hmac-sha1 (configure.ac): Likewise.
3833         * modules/gc-md2 (configure.ac): Likewise.
3834         * modules/gc-md4 (configure.ac): Likewise.
3835         * modules/gc-md5 (configure.ac): Likewise.
3836         * modules/gc-random (configure.ac): Likewise.
3837         * modules/gc-rijndael (configure.ac): Likewise.
3838         * modules/gc-sha1 (configure.ac): Likewise.
3839
3840 2007-01-08  Bruno Haible  <bruno@clisp.org>
3841
3842         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
3843         macro definition.
3844         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
3845         definition.
3846         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
3847         definition.
3848         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
3849         * modules/fcntl-safer (configure.ac): Likewise.
3850         * modules/fopen-safer (configure.ac): Likewise.
3851         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
3852         GNULIB_FWRITEERROR macro definition.
3853
3854 2007-01-08  Bruno Haible  <bruno@clisp.org>
3855
3856         * m4/gnulib-common.m4: New file.
3857         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
3858         (func_get_filelist): Add m4/gnulib-common.m4.
3859
3860 2007-01-08  Bruno Haible  <bruno@clisp.org>
3861
3862         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
3863         command.
3864
3865 2007-01-08  Jim Meyering  <jim@meyering.net>
3866
3867         Use a more robust test for a "can't happen" condition.
3868         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
3869         narrowed the st_size value.  Presuming the "can't happen" condition
3870         is true, that narrowing could conceivably convert an invalid st_size
3871         value into a valid one.  Instead, use a change based on Matthew
3872         Woehlke's original patch.
3873
3874         Slight readability improvement: use an assert-like macro
3875         in place of literal "abort ()" uses.
3876         * lib/fts.c (fts_assert): Define.
3877         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
3878         Use this macro instead of a bare 'abort'.
3879
3880 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
3881
3882         Don't worry about using IRIX 5.3's wctype.h broken definitions;
3883         simply work around them.
3884         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
3885         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
3886         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
3887         declaring.
3888         Don't bother to define as macros, since the standard doesn't require it.
3889         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
3890         longer worry about IRIX 5.3.
3891         (HAVE_WCTYPE_CTMP_BUG): Remove.
3892
3893 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
3894
3895         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
3896         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
3897         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
3898         Problems reported by Georg Schwarz for IRIX 5.3.
3899
3900         * gnulib-tool (autoconf_minversion): Take the maximum version number
3901         found, not the minimum.  Problem reported by James Youngman.
3902
3903 2007-01-03  Karl Berry  <karl@gnu.org>
3904
3905         * doc/error.texi: new file, explaining interaction with progname.
3906         * doc/gnulib.texi: include it.  Update copyright.
3907
3908 2007-01-03  Simon Josefsson  <simon@josefsson.org>
3909
3910         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
3911         AC_CANONICAL_HOST, to improve autobuild outputs.
3912
3913 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
3914             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
3915
3916         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
3917         sockets, server sockets, and other file descriptors.  Count errors
3918         to compute the return value.  Reorder the code a bit to be easier
3919         to follow.  Don't set event bits that were not requested (except
3920         POLLERR and POLLHUP).
3921
3922 2007-01-01  Bruno Haible  <bruno@clisp.org>
3923
3924         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
3925
3926 2007-01-03  Jim Meyering  <jim@meyering.net>
3927
3928         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
3929
3930 2007-01-02  Bruno Haible  <bruno@clisp.org>
3931
3932         * modules/settime (Include): Require timespec.h.
3933         * modules/nanosleep (Include): Likewise.
3934
3935 2007-01-01  Bruno Haible  <bruno@clisp.org>
3936
3937         * gnulib-tool (func_emit_copyright_notice): Bump year.
3938         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
3939
3940 2007-01-01  Bruno Haible  <bruno@clisp.org>
3941
3942         Improve support for OpenBSD.
3943         * build-aux/config.rpath (libname_spec): Export.
3944         (library_names_spec): New variable. Export.
3945         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
3946         library_names_spec from the config.rpath output. Locate shared library
3947         through the name pattern in library_names_spec.
3948
3949 2007-01-01  Eric Blake  <ebb9@byu.net>
3950
3951         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
3952
3953 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
3954
3955         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
3956         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
3957         assume the C locale, and avoid an "eval" that could cause trouble.
3958         Problem with SORT reported by Bob Proulx.
3959
3960         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
3961         Define.  Trivial patch from Henning Nielsen Lund, originally
3962         sent to bug-grep@gnu.org today.
3963
3964 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
3965
3966         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
3967         struct stat.  Problem reported by Henning Nielsen Lund.
3968         * lib/acl.c: Include acl.h first, to check interface.  Don't
3969         bother to include sys/types.h and sys/stat.h again.
3970
3971 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
3972
3973         Import the following change from libc; problem reported by
3974         Sven Verdoolaege.
3975
3976         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
3977
3978         [BZ #1373]
3979         * lib/argp.h: Remove __NTH for __argp_usage inline function.
3980
3981 2006-12-28  Jim Meyering  <jim@meyering.net>
3982
3983         * build-aux/announce-gen: Do not assume that the package
3984         builds any of tar.gz, tar.bz2, and .xdelta files.
3985         Suggestion from Simon Josefsson.
3986
3987 2006-12-28  Simon Josefsson  <simon@josefsson.org>
3988
3989         * modules/announce-gen: New file.
3990
3991 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
3992
3993         * lib/mbchar.h: Just include <wctype.h>; the wctype module
3994         handles its gotchas now.
3995         * lib/mbswidth.c: Likewise.
3996         * lib/wcwidth.h: Likewise.
3997         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
3998         and iswcntrl; the wctype module does this stuff now.
3999         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
4000         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
4001         * modules/mbchar (Depends-on): Add wctype.
4002         * modules/mbswidth (Depends-on): Likewise.
4003         * modules/wcwidth (Depends-on): Likewise.
4004
4005 2006-12-27  Eric Blake  <ebb9@byu.net>
4006
4007         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
4008         module uses more than what <wctype.h> is required to provide.
4009
4010 2006-12-26  Eric Blake  <ebb9@byu.net>
4011
4012         * gnulib-tool (sed_extract_prog): Avoid space-tab.
4013
4014 2006-12-26  Eric Blake  <ebb9@byu.net>
4015
4016         * modules/absolute-header: New module.
4017         * modules/fcntl (Depends-on): Depend on it.
4018         * modules/inttypes (Depends-on): Likewise.
4019         * modules/stdint (Depends-on): Likewise.
4020         * modules/sys_stat (Depends-on): Likewise.
4021         * modules/wctype (Depends-on): Likewise.
4022         * MODULES.html.sh (Support for building libraries and
4023         executables): Document it.
4024
4025 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
4026
4027         * gnulib-tool (SED): Remove, undoing previous change.
4028         The problem was that it broke coreutils on Solaris, because
4029         "sed --posix" leaked into a makefile.
4030         (sed): New alias, if 'alias' and GNU sed.
4031
4032 2006-12-24  Jim Meyering  <jim@meyering.net>
4033
4034         Work around an fchownat bug in glibc-2.4:
4035         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
4036         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
4037         in spite of the -P option.
4038         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
4039         New macros.
4040         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
4041         * modules/openat (Files): Add lib/fchownat.c.
4042         * lib/openat.c (fchownat): Don't define here.  Move to...
4043         * lib/fchownat.c: ...this new file.
4044
4045 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
4046
4047         Fix bug reported by Bruno Haible in
4048         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
4049         where quotearg.c didn't compile on Mac OS X 10.2 because it
4050         lacks <wchar.h> and wint_t.
4051         * lib/wctype_.h (__wctype_wint_t): New type.
4052         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
4053         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
4054         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
4055         Arg is now of type __wctype_wint_t, not wint_t.
4056         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
4057         substitute HAVE_WINT_T.
4058         * modules/wctype (Files): Add m4/wint_t.m4.
4059         (wctype.h): Substitute HAVE_WINT_T.
4060
4061 2006-12-23  Bruno Haible  <bruno@clisp.org>
4062
4063         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
4064
4065 2006-12-23  Bruno Haible  <bruno@clisp.org>
4066
4067         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
4068         S_ISLNK.
4069         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
4070         mingw.
4071
4072 2006-12-22  Bruno Haible  <bruno@clisp.org>
4073
4074         * lib/copy-file.c: Include acl.h.
4075         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
4076         Close the file descriptors only after being done with copy_acl.
4077         * modules/copy-file (Depends-on): Add acl.
4078
4079 2006-12-22  Bruno Haible  <bruno@clisp.org>
4080
4081         * gnulib-tool (SED): New variable.
4082         Use $SED instead of sed everywhere.
4083
4084 2006-12-22  Bruno Haible  <bruno@clisp.org>
4085
4086         * modules/no-c++: New file.
4087         * m4/no-c++.m4: New file.
4088         * MODULES.html.sh (Support for building libraries and executables):
4089         Add no-c++.
4090
4091 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
4092
4093         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
4094         Include <limits.h>, and use its INT_MAX to rewrite the
4095         j loop so that it does not overflow 'int'.  Problem reported by
4096         Ralf Wildenhues in
4097         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
4098         Play it safe by shifting left by 1 rather than multiplying by 2,
4099         as GCC is less likely to optimize this away when the value
4100         is signed (when it assumes overflow leads to undefined behavior).
4101         Also, don't assume time_t uses two's complement.
4102
4103 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
4104
4105         * MODULES.html.sh: New module wctype.
4106         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
4107         * lib/fnmatch.c: Don't bother to include <wchar.h> before
4108         <wctype.h>, since the new wctype module should fix this.
4109         * lib/quotearg.c: Include <wctype.h> unconditionally, since
4110         the wctype module should arrange for it.
4111         * lib/regex_internal.h: Likewise.
4112         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
4113         since the wctype module should handle this now.
4114         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
4115         * modules/fnmatch (Depends-on): Add wctype.
4116         * modules/quotearg (Depends-on): Likewise.
4117         * modules/regex (Depends-on): Likewise.
4118
4119 2006-12-19  Bruno Haible  <bruno@clisp.org>
4120
4121         * lib/strdup.h [C++]: Wrap definitions in extern "C".
4122         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
4123
4124 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4125
4126         * modules/savewd (Depends-on): Fix dependency on fcntl.
4127
4128 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4129
4130         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
4131         conforms to C99, rather than relying on the user's environment
4132         setting of STDINT_H.
4133
4134 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4135         and Eric Blake  <ebb9@byu.net>
4136
4137         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
4138         This is more consistent with the other defines here.
4139         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
4140         Port to z/OS.  Problem reported by Paul Gilmartin.
4141         Change local vars to use gl_ prefix rather than ac_.
4142         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
4143         with other defines.
4144         * modules/double-slash-root: New module.
4145         * modules/dirname (Files): Remove m4/double-slash-root.m4.
4146         (Depends-on): Add double-slash-root.
4147         * MODULES.html.sh (File system functions): Mention new module.
4148
4149 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
4150
4151         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
4152         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
4153         This is for the benefit of gzip, which doesn't do i18n.
4154
4155 2006-12-12  Jim Meyering  <jim@meyering.net>
4156
4157         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
4158         Reported by Andreas Schwab <schwab@suse.de>.
4159
4160 2006-12-12  Bruno Haible  <bruno@clisp.org>
4161
4162         Merge these changes.
4163         2006-09-05  Bruno Haible  <bruno@clisp.org>
4164         * lib/iconvme.c (iconv_string): No need to save and restore errno when
4165         iconv_alloc succeeded.
4166         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
4167         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
4168         test for " && dest " at the end - dest is always != NULL there. Call
4169         iconv with 4xNULL arguments initially, to reset the state. Call iconv
4170         with 2xNULL arguments, also to flush the state storage. Handle the
4171         IRIX iconv behaviour. Realloc the final result, to throw away unused
4172         memory.
4173
4174 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
4175
4176         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
4177         and fchmodat unconditionally, since glibc 2.4 has them.
4178         Problem reported by Arkadiusz Miskiewicz.
4179
4180 2006-12-10  Bruno Haible  <bruno@clisp.org>
4181
4182         * gnulib-tool (func_import): Show the include files only for those
4183         modules that are copied and specified.
4184         Reported by Karl Berry.
4185
4186 2006-12-08  Jim Meyering  <jim@meyering.net>
4187
4188         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
4189         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
4190
4191         * build-aux/announce-gen: Add two new options, both optional:
4192         --bootstrap-tools=TOOL_LIST
4193               a comma-separated list of tools, e.g.,
4194               autoconf,automake,bison,gnulib
4195         --gnulib-snapshot-date=DATE
4196               if gnulib is in the bootstrap tool list,
4197               then report this as the snapshot date.
4198               If not specified, use the current date/time.
4199               If you specify a date here, be sure it's UTC.
4200
4201 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4202
4203         * tests/test-argp-2.sh: Fix test to match actual output.
4204         (func_compare): Fix sed script to be portable.
4205
4206 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
4207
4208         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
4209         workaround for this case.  It is not autoconfigured now; offhand
4210         it's hard to see how to autoconfigure it.
4211
4212 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
4213
4214         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
4215         a directory that is about to be chowned.  Such a directory's
4216         initial file permissions should permit the owner only and this
4217         should not be changed until after the chown, since the group and
4218         other bits would be incorrect if they granted permission before
4219         the chown.
4220
4221         Fix porting problem for iswctype reported by Georg Schwarz in:
4222         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
4223         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
4224         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
4225         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
4226         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
4227
4228 2006-12-03  Jim Meyering  <jim@meyering.net>
4229
4230         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
4231         p->fts_statp may not yet be defined.
4232         (fts_read): Instead, set it in the caller, once p->fts_statp is
4233         sure to be defined, and corresponds to a top-level directory.
4234         This bug made du -x fail.  Here's the coreutils test case:
4235         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
4236         Reported by Mike Frysinger.
4237
4238 2006-12-01  Jim Meyering  <jim@meyering.net>
4239
4240         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
4241         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
4242         Reported by Simon Josefsson.
4243
4244 2006-11-30  Jim Meyering  <jim@meyering.net>
4245
4246         * m4/warning.m4: Use the all-permissive copyright notice
4247         recommended by RMS (rather than LGPL).
4248         * m4/vararrays.m4: Likewise.
4249         * m4/flexmember.m4: Likewise.
4250
4251 2006-11-29  Bruno Haible  <bruno@clisp.org>
4252
4253         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4254         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
4255         using +=.
4256         Reported by Simon Josefsson <simon@josefsson.org>.
4257
4258 2006-11-28  James Youngman <jay@gnu.org>
4259
4260         * README: Advise users that they might find the bug-gnulib@gnu.org
4261         and autotools-announce@gnu.org mailing lists useful.
4262
4263 2006-11-28  Bruno Haible  <bruno@clisp.org>
4264
4265         * m4/ptrdiff_max.m4: Remove file.
4266
4267 2006-11-21  Bruno Haible  <bruno@clisp.org>
4268
4269         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
4270         _AC_COMPUTE_INT.
4271         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4272         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
4273         _AC_COMPUTE_INT.
4274         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4275         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
4276         _AC_COMPUTE_INT.
4277         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4278
4279 2006-11-28  Jim Meyering  <jim@meyering.net>
4280
4281         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
4282         warning from "gcc -Wshadow" about shadowing the builtin.
4283
4284 2006-11-27  Bruno Haible  <bruno@clisp.org>
4285
4286         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
4287         _AC_COMPUTE_INT.
4288         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4289
4290 2006-11-27  Bruno Haible  <bruno@clisp.org>
4291             Paul Eggert  <eggert@cs.ucla.edu>
4292
4293         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
4294
4295 2006-11-26  Bruno Haible  <bruno@clisp.org>
4296
4297         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4298         noinst_LTLIBRARIES.
4299
4300 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
4301             Bruno Haible  <bruno@clisp.org>
4302
4303         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
4304         if compiling with "gcc -ansi".
4305
4306 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
4307
4308         Fix some incompatibilities with gcc -ansi -pedantic.
4309         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
4310         if compiling pedantically with GCC, unless it's C99 or later.
4311         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
4312         it mishandles gcc -ansi -pedantic as well.
4313         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
4314         if gcc -pedantic.
4315         * lib/regexec.c (check_node_accept_bytes): Don't use auto
4316         initializers for struct if -pedantic, unless it's C99 or later.
4317
4318 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
4319
4320         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
4321         Don't close an fd more than once. Identical atimes indicate
4322         success, not failure.
4323
4324 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
4325
4326         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
4327
4328 2006-11-23  Jim Meyering  <jim@meyering.net>
4329
4330         * build-aux/announce-gen: New file.  From coreutils.
4331
4332 2006-11-22  Jim Meyering  <jim@meyering.net>
4333
4334         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
4335         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
4336         (fts_read): Use a temporary to narrow the overused st_size member
4337         before using it in a switch statement.  Reported by Matthew Woehlke.
4338
4339         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
4340         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
4341
4342 2006-11-20  Bruno Haible  <bruno@clisp.org>
4343
4344         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
4345         changequote instead of pairs of brackets.
4346         Reported by Andreas Schwab <schwab@suse.de>.
4347
4348 2006-11-21  Jim Meyering  <jim@meyering.net>
4349
4350         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
4351         so as to remain compatible with older compilers.
4352         Patch from Michael Deutschmann.
4353
4354 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4355
4356         * MODULES.html.sh (File system functions): Add openat.
4357
4358         * lib/openat.h (rpl_fstatat): New macro, if
4359         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
4360         (fstatat): Define to rpl_fstatat under the same conditions,
4361         unless COMPILING_FSTATAT.
4362         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
4363         seems to have the bug.
4364         * lib/fstatat.c: New file.
4365         * modules/openat (Files): Add it.
4366
4367 2006-11-20  Bruno Haible  <bruno@clisp.org>
4368
4369         * Makefile: New file.
4370
4371 2006-11-20  Jim Meyering  <jim@meyering.net>
4372
4373         The beginnings of syntax-related checks for gnulib.
4374         * lib/Makefile: New file.
4375         * lib/t-idcache: New script.  Ensure that the two halves of
4376         idcache.c stay in sync.
4377
4378         * lib/idcache.c: Adjust comments in user- and group- portions to
4379         be more accurate, and to be consistent with one another.
4380
4381 2006-11-20  Jim Meyering  <jim@meyering.net>
4382
4383         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
4384         continue using the flexible array member (thus, this module performs
4385         half as many malloc calls), with the addition that...
4386         (getgroup, getuser): Consistently record a non-match via an empty
4387         "name" string, and map an empty string match to a NULL return value.
4388         * modules/idcache (Depends-on): Re-add flexmember.
4389
4390         * lib/idcache.c (getuser): Remove all uses of the register keyword.
4391         (getuidbyname, getgroup, getgidbyname): Likewise.
4392
4393         Use cleaner syntax: NULL rather than 0.
4394         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
4395
4396 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4397
4398         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
4399         It mishandled the case where the group was missing.
4400         Problem reported by Greg Schafer.
4401         * modules/idcache: Likewise.
4402
4403 2006-11-18  Jim Meyering  <jim@meyering.net>
4404
4405         * check-module (%exempt_header): Add exception for some
4406         conditionally-included headers.
4407
4408         * modules/i-ring (Depends-on): Add verify.
4409         (License): Change to LGPL.
4410
4411 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
4412
4413         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
4414         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
4415         and inttostr.h.  Use snprintf rather than uinttostr, so that
4416         LGPLed code doesn't depend on GPLed.
4417
4418 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
4419
4420         * modules/inline (License): Change from GPL to LGPL.
4421
4422 2006-11-17  Jim Meyering  <jim@meyering.net>
4423
4424         * modules/d-type (License): Switch to LGPL.
4425
4426 2006-11-15  Bruno Haible  <bruno@clisp.org>
4427
4428         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
4429
4430 2006-11-15  Eric Blake  <ebb9@byu.net>
4431
4432         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
4433         the module dependency.
4434
4435 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4436             Bruno Haible  <bruno@clisp.org>
4437
4438         * gnulib-tool (func_create_testdir): Add license consistency check.
4439
4440 2006-11-15  Eric Blake  <ebb9@byu.net>
4441
4442         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
4443         random "(cached)" in configure output.
4444
4445 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4446
4447         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
4448         test for conforming inttypes.h is both announced and cached.
4449
4450         * MODULES.html.sh (seen_modules, seen_files): New variables.
4451         (func_module): Rewrite to use a few less gnulib-tool and sed
4452         invocations.  Avoid a couple of quadratic algorithms for ...
4453         (missed_modules, missed_files): ... these, with ...
4454         (func_append, func_tmpdir): ... these new functions, from
4455         gnulib-tool.  Analogously, install traps for cleanup.
4456
4457         * tests/test-gc.c (main): Remove unused variables.
4458         * tests/test-read-file.c: Include stdlib.h, for 'free'.
4459
4460 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
4461
4462         * modules/inttostr (License): Change to LGPL.
4463
4464 2006-11-14  Eric Blake  <ebb9@byu.net>
4465
4466         * modules/tempname (License): Change to LGPL.
4467
4468 2006-11-14  Eric Blake  <ebb9@byu.net>
4469
4470         * doc/functions.texi (Function Portability): *printf functions on
4471         Cygwin now understand all POSIX size specifiers.
4472
4473 2006-11-14  Bruno Haible  <bruno@clisp.org>
4474
4475         * modules/c-ctype (License): Change to LGPL.
4476
4477 2006-11-12  Bruno Haible  <bruno@clisp.org>
4478
4479         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
4480         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
4481         for GNOME libraries, for which the include files are installed in
4482         subdirectories of $prefix/include.
4483
4484 2006-11-12  Bruno Haible  <bruno@clisp.org>
4485
4486         * m4/lib-link.m4: Require at least autoconf-2.54.
4487         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
4488         name to underscores for the --with option.
4489
4490 2006-11-13  Bruno Haible  <bruno@clisp.org>
4491
4492         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
4493         the tests directory.
4494         Reported by Ralf Wildenhues.
4495
4496 2006-11-13  Bruno Haible  <bruno@clisp.org>
4497
4498         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
4499         (func_emit_initmacro_end): Undo the override here.
4500         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
4501         Works around the famous automake error in coreutils.
4502
4503 2006-11-13  Eric Blake  <ebb9@byu.net>
4504
4505         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
4506         element, not its node.
4507
4508 2006-11-12  Bruno Haible  <bruno@clisp.org>
4509
4510         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
4511         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
4512
4513 2006-11-12  Bruno Haible  <bruno@clisp.org>
4514
4515         * gnulib-tool: New option --local-symlink.
4516         (func_usage): Document it.
4517         (lsymbolic): New variable.
4518         (func_import, func_create_testdir): If --symlink was not specified,
4519         test whether --local-symlink was specified and the file comes from
4520         the local_gnulib_dir.
4521
4522 2006-11-12  Bruno Haible  <bruno@clisp.org>
4523
4524         * gnulib-tool (func_ln): New function.
4525         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
4526
4527 2006-11-12  Bruno Haible  <bruno@clisp.org>
4528
4529         Finish support for source files in subdirectories.
4530         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
4531         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
4532         AUTOMAKE_OPTIONS.
4533         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
4534
4535 2006-11-12  Bruno Haible  <bruno@clisp.org>
4536
4537         * gnulib-tool (func_get_automake_snippet): Synthesize also an
4538         EXTRA_lib_SOURCES augmentation.
4539         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
4540
4541 2006-11-12  Jim Meyering  <jim@meyering.net>
4542
4543         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
4544         file descriptors.  This also averts a failure on systems with
4545         native openat support when a traversed directory lacks "x" access.
4546         * lib/fts_.h: Include "i-ring.h"
4547         (struct FTS) [fts_fd_ring]: New member.
4548         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
4549         (FCHDIR): Add parentheses.
4550         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
4551         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
4552         When descending, rather than simply closing the previous
4553         fts_cwd_fd value, push that file descriptor onto the ring.
4554         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
4555         (fts_open): Initialize the new fd_ring member.
4556         (fts_close): Clear the ring.
4557         (fts_safe_changedir): When possible, use our new fd_ring to skip
4558         the diropen and fstat and dev/ino comparison that would normally
4559         accompany a virtual `chdir ("..")'.
4560
4561         * modules/fts (Depends-on): Add i-ring.
4562         * modules/i-ring: New module.
4563         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
4564         * m4/i-ring.m4: New file.
4565
4566 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4567
4568         * gnulib-tool (func_create_testdir): Fix replacement of
4569         `build-aux' in configure.ac.  Run autotools in gltests
4570         subdirectory.
4571         (func_create_testdir, func_create_megatestdir, test): There is
4572         no need for '--force' in most autotool invocations in a new
4573         tree.  Actually fail the whole test if any of the tools, or the
4574         configure or make stages fail.
4575
4576         Sync from Automake.
4577         * build-aux/gnupload: Revert last change.  Add pointer to upload
4578         instructions of the GNU Maintenance Instructions.
4579         Suggestion by Karl Berry.
4580
4581 2006-11-10  Jim Meyering  <jim@meyering.net>
4582
4583         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
4584
4585 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
4586
4587         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
4588         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
4589         (bind_textdomain_codeset) [! ENABLE_NLS]:
4590         Evaluate all the arguments.  That way, callers get compatible behavior
4591         if the arguments have side effects.  Also, it avoids some GCC
4592         diagnostics in some cases; Joel E. Denny reported problems when Bison
4593         was configured with --enable-gcc-warnigs.
4594
4595 2006-11-10  Jim Meyering  <jim@meyering.net>
4596
4597         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
4598         relevant options in CFLAGS (like -O, -fno-inline) are taken into
4599         account.
4600
4601 2006-11-10  Jim Meyering  <jim@meyering.net>
4602
4603         * modules/inline: New file/module.
4604         * modules/xalloc (Files): Remove m4/inline.m4.
4605         (Depends-on): Add inline, instead.
4606         * modules/oset: Likewise.
4607         * modules/list: Likewise.
4608
4609 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
4610
4611         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
4612         Problem reported by Matthew Woehlke.
4613
4614 2006-11-09  Bruno Haible  <bruno@clisp.org>
4615
4616         * lib/tempname.c (gen_tempname): Remove variant that invokes
4617         __gen_tempname.
4618         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
4619         __gen_tempname.
4620
4621 2006-11-08  Bruno Haible  <bruno@clisp.org>
4622
4623         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
4624         to 'yes' instead of 'cross-compiling'.
4625
4626 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
4627
4628         * lib/quotearg.h (quotearg_free): New decl.
4629         * lib/quotearg.c (quotearg_free): New function.
4630         (slot0, nslots, slotvec0, slotvec):
4631         Now file-scope so that quotearg_free can get at them.
4632
4633 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4634
4635         Sync from Automake.
4636         * build-aux/gnupload: Add missing 'gnu' to example URL.
4637         Report by Karl Berry.
4638
4639 2006-11-08  Bruno Haible  <bruno@clisp.org>
4640
4641         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
4642         Suggested by Paul Eggert.
4643
4644 2006-11-08  Jim Meyering  <jim@meyering.net>
4645
4646         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
4647         It's already included if !_LIBC.
4648         (fts_safe_changedir): Add a comment.
4649
4650 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
4651
4652         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
4653         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
4654         Matthew Woehlke.
4655
4656         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
4657         definitions up, to avoid colliding with change below.
4658         (static_inline) [HAVE_INLINE]: New macro.
4659         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
4660         Provide extern decls when !HAVE_INLINE.  Do not define unless
4661         static_inline is defined, either by us or by xmalloc.c.  Use
4662         static_inline rather than static inline.
4663         (XCALLOC): Optimize sizeof(T) = 1 case.
4664         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
4665
4666 2006-11-07  Bruno Haible  <bruno@clisp.org>
4667
4668         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
4669         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
4670         AC_C_INLINE.
4671         * modules/xalloc (Files): Add m4/inline.m4.
4672
4673 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4674
4675         * README: Fix typo.
4676         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
4677         (Miscellanous Notes): ...from this.
4678
4679 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
4680
4681         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
4682         Mention that offsetof should be used instead of sizeof.
4683         From Bruno Haible.
4684
4685 2006-11-07  Bruno Haible  <bruno@clisp.org>
4686
4687         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
4688
4689 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
4690
4691         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
4692         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
4693         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
4694         (gl_tree_add_before, gl_tree_add_after):
4695         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
4696         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
4697         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
4698         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
4699         (gl_linked_add_after, gl_linked_add_at): Likewise.
4700         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
4701         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
4702         (gl_tree_add_before, gl_tree_add_after): Likewise.
4703         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
4704         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
4705         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
4706
4707 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4708
4709         * lib/gl_oset.h: Use C comment style, not C++ comment style.
4710
4711 2006-11-06  Bruno Haible  <bruno@clisp.org>
4712
4713         * m4/inline.m4: New file.
4714         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
4715         * modules/list (Files): Add m4/inline.m4.
4716         * modules/oset (Files): Likewise.
4717
4718 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
4719
4720         * lib/idcache.c: Include <stddef.h>, for offsetof.
4721         (struct userid.name): Change from char * to a flexible array member.
4722         All uses changed.
4723         * modules/idcache (Depends-on): Add flexmember.
4724
4725         * MODULES.html.sh (Core language properties): New module flexmember.
4726         * modules/flexmember, m4/flexmember.m4: New files.
4727
4728         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
4729         inline functions that are identical with the old xnmalloc_inline,
4730         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
4731         that we can avoid some unnecessary integer multiplications and
4732         divisions in the common case where the element size is known at
4733         compile time.
4734         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
4735         needed.
4736         (xnboundedmalloc): Remove.
4737         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
4738         arguments, for consistency with rest of this header.
4739         (xcharalloc): Rewrite using XNMALLOC.
4740         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
4741         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
4742         versions have been moved to lib/xalloc.h and renamed to be the
4743         non-*_inline versions.
4744         (xmalloc, xrealloc): Implement without reference to the xnmalloc
4745         and xnrealloc functions, since those functions are now inline and
4746         now call us.
4747         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
4748         renaming described above.
4749         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
4750         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
4751         captures the dependency in AC_C_INLINE.
4752
4753         New module canonicalize-lgpl, proposed by Charles Wilson in
4754         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
4755         with a few small changes afterwards.
4756         * MODULES.html.sh (File system functions): New module
4757         canonicalize-lgpl.
4758         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
4759         and canonicalize_file_name.
4760         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
4761         * modules/canonicalize-lgpl: New files.
4762
4763 2006-11-05  Bruno Haible  <bruno@clisp.org>
4764
4765         * gnulib-tool (func_import, func_create_testdir): Create directories
4766         also for files in subdirectories of lib/.
4767
4768 2006-11-05  Bruno Haible  <bruno@clisp.org>
4769
4770         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
4771         ANSI C compliant.
4772
4773 2006-11-03  Bruno Haible  <bruno@clisp.org>
4774
4775         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
4776         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
4777         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
4778         (xnboundedmalloc): New inline function.
4779         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
4780         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
4781         xmalloc.
4782         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
4783         xmalloc.
4784         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
4785         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
4786         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
4787         xmalloc.
4788         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
4789         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
4790         xmalloc.
4791         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
4792         gl_tree_add_after): Use XMALLOC instead of xmalloc.
4793         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
4794         xmalloc.
4795         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
4796         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
4797         gl_tree_add_after): Use XMALLOC instead of xmalloc.
4798         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
4799         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
4800         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
4801         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
4802
4803 2006-11-03  Bruno Haible  <bruno@clisp.org>
4804
4805         * lib/c-ctype.h [C++]: Define functions without name mangling.
4806         * lib/fwriteerror.h [C++]: Likewise.
4807         * lib/gcd.h [C++]: Likewise.
4808         * lib/linebreak.h [C++]: Likewise.
4809
4810 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
4811
4812         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
4813         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
4814         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
4815         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4816         Check for functions and headers just once.
4817         Check for declaration of canonicalize_file_name.
4818         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
4819
4820 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
4821
4822         * gnulib-tool (func_import): Fix typo in actioncmd.
4823
4824 2006-11-02  Bruno Haible  <bruno@clisp.org>
4825
4826         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
4827         newline sequence in the Makefile.am snippet as a space, like "make"
4828         does.
4829         Reported by Roger Persson <perrog@gmail.com>.
4830
4831 2006-11-01  Bruno Haible  <bruno@clisp.org>
4832
4833         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
4834         already declared in <string.h>.
4835         * lib/strcase.h (strncasecmp): Don't declare it if yes.
4836
4837 2006-11-01  Bruno Haible  <bruno@clisp.org>
4838
4839         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
4840         * lib/strcase.h: Include <string.h>.
4841         (strcasecmp): Define to rpl_strcasecmp here.
4842
4843 2006-11-01  Bruno Haible  <bruno@clisp.org>
4844
4845         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
4846
4847 2006-11-01  Eric Blake  <ebb9@byu.net>
4848
4849         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
4850
4851         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
4852
4853 2006-10-29  Bruno Haible  <bruno@clisp.org>
4854
4855         Make it compile in C++ mode.
4856         * lib/full-write.c (full_rw): Add a cast.
4857
4858 2006-11-01  Bruno Haible  <bruno@clisp.org>
4859
4860         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
4861         be POSIX compliant.
4862         Reported by Roger Persson <perrog@gmail.com>.
4863
4864 2006-11-01  Eric Blake  <ebb9@byu.net>
4865
4866         * lib/getopt_.h: Fix comments.
4867
4868 2006-10-31  Eric Blake  <ebb9@byu.net>
4869
4870         * modules/tmpdir (Depends-on): Add sys_stat.
4871         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
4872         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
4873         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
4874         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
4875         tempname.
4876
4877 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
4878
4879         Avoid some C++ diagnostics reported by Bruno Haible.
4880         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
4881         xmalloc.
4882         (quotearg_alloc): Use xcharalloc rather than xmalloc.
4883         (struct slotvec): Move to top level.
4884         (quotearg_n_options): Rewrite to avoid xmalloc.
4885         * lib/xalloc.h (xcharalloc): New function.
4886         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
4887         [defined __cplusplus]: Add function template that provides result
4888         type propagation.  This part of the change is from Bruno Haible.
4889
4890 2006-10-29  Bruno Haible  <bruno@clisp.org>
4891
4892         Make it compile in C++ mode.
4893         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
4894         * lib/strnlen1.c (strnlen1): Cast memchr result.
4895         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
4896         * lib/clean-temp.c (string_equals, string_hash): Add casts.
4897         (create_temp_dir): Rename local variable 'template'.
4898         (compile_csharp_using_sscli): Add cast.
4899         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
4900         * lib/findprog.c (find_in_path): Likewise.
4901         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
4902         * lib/wait-process.c (register_slave_subprocess): Likewise.
4903
4904 2006-10-22  Bruno Haible  <bruno@clisp.org>
4905
4906         * modules/tsearch: New file.
4907         * lib/tsearch.h: New file.
4908         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
4909         * m4/tsearch.m4: New file.
4910         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
4911
4912 2006-10-29  Eric Blake  <ebb9@byu.net>
4913
4914         * lib/arcfour.c: Assume config.h.
4915         * lib/arctwo.c: Likewise.
4916         * lib/base64.c: Likewise.
4917         * lib/check-version.c: Likewise.
4918         * lib/crc.c: Likewise.
4919         * lib/des.c: Likewise.
4920         * lib/gc-gnulib.c: Likewise.
4921         * lib/gc-libgcrypt.c: Likewise.
4922         * lib/gc-pbkdf2-sha1.c: Likewise.
4923         * lib/getaddrinfo.c: Likewise.
4924         * lib/getdelim.c: Likewise.
4925         * lib/getline.c: Likewise.
4926         * lib/hmac-md5.c: Likewise.
4927         * lib/hmac-sha1.c: Likewise.
4928         * lib/iconvme.c: Likewise.
4929         * lib/md2.c: Likewise.
4930         * lib/md4.c: Likewise.
4931         * lib/memxor.c: Likewise.
4932         * lib/read-file.c: Likewise.
4933         * lib/readline.c: Likewise.
4934         * lib/rijndael-alg-fst.c: Likewise.
4935         * lib/rijndael-api-fst.c: Likewise.
4936         * lib/xgetdomainname.c: Likewise.
4937
4938 2006-10-28  Eric Blake  <ebb9@byu.net>
4939
4940         * lib/xstrndup.c: Assume config.h.
4941
4942 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
4943
4944         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
4945         stat-macros.h is now for our own macros, whereas stat_h is for
4946         macros in the <sys/stat.h> name space.
4947         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
4948         (STAT_MACROS_H): Remove.
4949         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
4950         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
4951         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
4952         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
4953         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
4954         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
4955         Move these macros to ...
4956         * lib/stat_.h: here.  Don't include stat-macros.h.
4957         * lib/canonicalize.c: Don't include stat-macros.h.
4958         * lib/chown.c: Likewise.
4959         * lib/euidaccess.c: Likewise.
4960         * lib/file-type.c: Likewise.
4961         * lib/filemode.c: Likewise.
4962         * lib/glob.c: Likewise.
4963         * lib/isapipe.c: Likewise.
4964         * lib/lchown.c: Likewise.
4965         * lib/lstat.c: Likewise.
4966         * lib/mkdir-p.c: Likewise.
4967         * lib/rmdir.c: Likewise.
4968         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
4969         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
4970         unless mkdir isn't declared, to speed up 'configure'.
4971         Always create sys/stat.h, since it's unlikely any real sys/stat.h
4972         would define all the S_* symbols.
4973         * modules/canonicalize (Depends-on):
4974         Depend on sys_stat, not stat-macros.
4975         * modules/chown: Likewise.
4976         * modules/euidaccess: Likewise.
4977         * modules/filemode: Likewise.
4978         * modules/file-type: Likewise.
4979         * modules/glob: Likewise.
4980         * modules/isapipe: Likewise.
4981         * modules/lchown: Likewise.
4982         * modules/lstat: Likewise.
4983         * modules/mkancesdirs: Likewise.
4984         * modules/rmdir: Likewise.
4985         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
4986         * modules/modechange: Likewise.
4987         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
4988         (configure.ac): Remove gl_STAT_MACROS.
4989         * modules/sys_stat (Depends-on): Remove stat-macros.
4990
4991 2006-10-27  Bruno Haible  <bruno@clisp.org>
4992
4993         * m4/signed.m4: Remove file.
4994         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
4995         invocation.
4996         * modules/vasnprintf (Files): Remove m4/signed.m4.
4997
4998 2006-10-27  Bruno Haible  <bruno@clisp.org>
4999
5000         Update to GNU gettext 0.16.
5001         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
5002         m4/inttypes-h.m4, m4/signed.m4.
5003         * m4/gettext.m4: Update to GNU gettext 0.16.
5004         * m4/intl.m4: New file, from GNU gettext.
5005         * m4/intldir.m4: New file, from GNU gettext.
5006         * config/srclist.txt: Update
5007
5008 2006-10-27  Eric Blake  <ebb9@byu.net>
5009
5010         * MODULES.html.sh: Document tempname.
5011         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
5012         dependencies.
5013         (Files): Move lib/tempname.c...
5014         * modules/tempname: ...to this new module.
5015         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
5016         (gl_PREREQ_TEMPNAME): Move...
5017         * m4/tempname.m4: ...to this new file.
5018         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
5019         * modules/sys_stat (Depends-on): Add stat-macros.
5020         * lib/stat_.h (includes): Pick up stat macros.
5021         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
5022         if stat macros are broken.
5023         * lib/tempname.c (includes): No need to include "stat-macros.h".
5024         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
5025         (direxists, __path_search) [!_LIBC]: Don't compile these in
5026         gnulib; the tmpdir module covers that.
5027         * lib/tempname.h: New file.
5028
5029 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
5030
5031         * COPYING: Explain how gnulib-tool converts licence headers.
5032         Almost all wording by Eric Blake.
5033
5034 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
5035
5036         * lib/mbchar.h (is_basic_table): Make read-only.
5037         * lib/mbchar.c (is_basic_table): Likewise.
5038         Reported by John Darrington.
5039
5040 2006-10-25  Bruno Haible  <bruno@clisp.org>
5041
5042         * lib/progname.h (set_program_name): Undefine before defining.
5043
5044 2006-10-25  Bruno Haible  <bruno@clisp.org>
5045
5046         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
5047         false for non-gcc C++ compilers.
5048         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
5049
5050 2006-10-24  Bruno Haible  <bruno@clisp.org>
5051
5052         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
5053         iconv implementations like Irix iconv.
5054
5055 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5056
5057         * modules/vararrays: New file.
5058         * m4/vararrays.m4: New file, taken from diffutils.
5059         * MODULES.html.sh: New module vararrays.
5060
5061 2006-10-24  Karl Berry  <karl@gnu.org>
5062
5063         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
5064         Don't call GNU Unix.
5065
5066 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5067
5068         * users.txt: Add Libtool.
5069
5070         Sync from Libtool:
5071
5072         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5073
5074         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
5075         to gnulib's policy of including config.h unconditionally.
5076
5077 2006-10-24  Bruno Haible  <bruno@clisp.org>
5078
5079         * modules/wcwidth (Files): Add m4/wint_t.m4.
5080         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
5081         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
5082
5083 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5084
5085         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
5086         to pacify GCC with some -W flags enabled.  Problem reported by
5087         Bruno Haible.
5088
5089 2006-10-24  Jim Meyering  <jim@meyering.net>
5090
5091         * MODULES.html.sh: Remove uinttostr.  It's not a module.
5092         Reported by Karl Berry.
5093
5094 2006-10-23  Bruno Haible  <bruno@clisp.org>
5095
5096         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
5097
5098 2006-10-24  Bruno Haible  <bruno@clisp.org>
5099
5100         * lib/gl_list.h: Use C comment style, not C++ comment style.
5101
5102 2006-10-23  Eric Blake  <ebb9@byu.net>
5103
5104         * lib/getaddrinfo.c (includes): Add missing include.
5105
5106 2006-10-23  Bruno Haible  <bruno@clisp.org>
5107             Paul Eggert  <eggert@cs.ucla.edu>
5108
5109         Ability to rename obstack_free.
5110         * lib/obstack.h (__obstack_free): New macro. Declare instead of
5111         obstack_free.
5112         (obstack_free): Invoke the __obstack_free macro.
5113         * lib/obstack.c (obstack_free): Use __obstack_free macro.
5114
5115 2006-10-23  Bruno Haible  <bruno@clisp.org>
5116             Paul Eggert  <eggert@cs.ucla.edu>
5117
5118         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
5119         __argc, __argv from the declaration. (They are defined as macros on
5120         mingw.)
5121
5122 2006-10-22  Bruno Haible  <bruno@clisp.org>
5123
5124         * doc/gnulib-intro.texi: New file.
5125         * doc/gnulib.texi: Include it.
5126
5127 2006-10-21  Bruno Haible  <bruno@clisp.org>
5128
5129         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
5130         "Introduction", "Miscellanous Notes", "Particular Modules".
5131
5132 2006-10-21  Bruno Haible  <bruno@clisp.org>
5133
5134         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5135         Change mostlyclean-local rule to avoid sh syntax error from bash
5136         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
5137
5138 2006-10-23  Jim Meyering  <jim@meyering.net>
5139
5140         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
5141         in place of snprintf.
5142
5143         * modules/inttostr (Files): Add lib/uinttostr.c.
5144         * lib/uinttostr.c (inttostr): New file/function.
5145         * lib/inttostr.h (uinttostr): Declare.
5146         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
5147         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
5148         Add uinttostr.
5149         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
5150
5151 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5152
5153         * lib/canonicalize.c (ELOOP): Define if not already defined.
5154         Problem reported by Bruno Haible in
5155         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
5156
5157 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5158
5159         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
5160         Problem reported by Perry Smith and Ville Laurikari.
5161
5162         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
5163         uses.
5164
5165 2006-10-19  Bruno Haible  <bruno@clisp.org>
5166
5167         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
5168         for mingw.
5169
5170 2006-10-19  Bruno Haible  <bruno@clisp.org>
5171
5172         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
5173         Needed for mingw.
5174
5175 2006-10-19  Bruno Haible  <bruno@clisp.org>
5176
5177         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
5178
5179 2006-10-19  Bruno Haible  <bruno@clisp.org>
5180
5181         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
5182         it.
5183
5184 2006-10-19  Bruno Haible  <bruno@clisp.org>
5185
5186         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
5187         invocation.
5188
5189 2006-10-19  Bruno Haible  <bruno@clisp.org>
5190
5191         * gnulib-tool (func_create_testdir): Don't include ftruncate and
5192         mountlist by default.
5193
5194 2006-10-16  Bruno Haible  <bruno@clisp.org>
5195
5196         * lib/c-strstr.c: Include c-strstr.h.
5197
5198 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5199
5200         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
5201         in a slash.
5202
5203 2006-10-18  Bruno Haible  <bruno@clisp.org>
5204
5205         * lib/lock.h [C++]: Wrap definitions in extern "C".
5206
5207 2006-10-18  Bruno Haible  <bruno@clisp.org>
5208
5209         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
5210         gl_LIBOBJS list.
5211
5212 2006-10-18  Bruno Haible  <bruno@clisp.org>
5213
5214         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
5215
5216 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
5217
5218         * lib/xstrtol.h: Include gettext.h.
5219         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
5220         Problem reported by Eric Blake.
5221         * modules/xstrtol (Depends-on): Add gettext-h.
5222
5223 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
5224
5225         * lib/strftime.c (advance): New macro.
5226         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
5227         incomplete type, so you can't add 0 to it.  Problem and patch
5228         reported by Eelco Dolstra for dietlibc.
5229
5230 2006-10-18  Jim Meyering  <jim@meyering.net>
5231
5232         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
5233         type for a local, and rename it: s/up/user_proc/.
5234
5235 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
5236
5237         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
5238         READ_UTMP_USER_PROCESS.
5239         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
5240
5241 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
5242
5243         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
5244         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
5245
5246 2006-10-17  Eric Blake  <ebb9@byu.net>
5247
5248         * lib/sigprocmask.c (sigprocmask): Fix typo.
5249
5250         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
5251
5252         * modules/clean-temp (Makefile.am): Don't add to make output...
5253         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
5254         config.h.
5255
5256 2006-10-17  Bruno Haible  <bruno@clisp.org>
5257
5258         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
5259         differently if DEFAULT_TEXT_DOMAIN is set.
5260
5261 2006-10-16  Bruno Haible  <bruno@clisp.org>
5262
5263         * lib/clean-temp.c: Include fwriteerror.h.
5264
5265 2006-10-16  Bruno Haible  <bruno@clisp.org>
5266
5267         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
5268
5269 2006-10-16  Bruno Haible  <bruno@clisp.org>
5270
5271         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
5272         * lib/sigprocmask.h: Include <sys/types.h>.
5273         (sigset_t): Use the system's definition if present.
5274
5275 2006-10-17  Eric Blake  <ebb9@byu.net>
5276
5277         * lib/xvasprintf.c (includes): Assume config.h.
5278         * lib/xasprintf.c (includes): Likewise.
5279
5280 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
5281
5282         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
5283         at least as wide as intmax_t.
5284
5285 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
5286
5287         (Imported from Automake.)
5288         * build-aux/gnupload: Update to version 1.1 of directive file.
5289
5290 2006-10-16  Eric Blake  <ebb9@byu.net>
5291
5292         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
5293         match Automake 1.10a.
5294
5295 2006-10-14  Bruno Haible  <bruno@clisp.org>
5296
5297         * modules/sigprocmask: New file.
5298         * lib/sigprocmask.h: New file.
5299         * lib/sigprocmask.c: New file.
5300         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
5301         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
5302         request sigprocmask.o.
5303         (gl_PREREQ_SIGPROCMASK): New macro.
5304         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
5305         (Depends-on): Add sigprocmask.
5306         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
5307         gt_SIGNALBLOCKING. Test for 'raise' only once.
5308         * lib/fatal-signal.c: Include sigprocmask.h.
5309         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
5310         unblock_fatal_signals): Define always.
5311         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
5312         sigprocmask.
5313
5314 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
5315
5316         Sync from Automake.
5317         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
5318         which incorrectly sets the mode of an existing destination
5319         directory.  In some cases the unpatched install-sh could do the
5320         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
5321         system.  We hope this is rare in practice, but it's clearly worth
5322         fixing.  Problem reported by Alex Unleashed in
5323         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
5324         Also, don't bother to check for -m bugs unless we're using -m;
5325         suggested by Stepan Kasal.
5326
5327 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5328
5329         Sync from Automake.
5330         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
5331         `-c' flag, so they appear at the same position as in %FASTDEP%
5332         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
5333         which ignores unknown options only after the first non-option.
5334         Bug report against M4 by Nelson H. F. Beebe.
5335
5336 2006-10-13  Jim Meyering  <jim@meyering.net>
5337
5338         Fix a bug in yesterday's change.
5339         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
5340         p->fts_statp->st_dev would be used uninitialized.
5341         Ensures that we always call fts_stat on the very first entry.
5342         Miklos Szeredi reported that find -xdev stopped working.
5343
5344 2006-10-12  Bruno Haible  <bruno@clisp.org>
5345
5346         * gnulib-tool (func_get_automake_snippet): Append an automatically
5347         computed EXTRA_DIST augmentation.
5348         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
5349         * modules/alloca-opt (Makefile.am): Likewise.
5350         * modules/allocsa (Makefile.am): Likewise.
5351         * modules/arcfour (Makefile.am): Likewise.
5352         * modules/arctwo (Makefile.am): Likewise.
5353         * modules/argmatch (Makefile.am): Likewise.
5354         * modules/argz (Makefile.am): Likewise.
5355         * modules/atexit (Makefile.am): Likewise.
5356         * modules/backupfile (Makefile.am): Likewise.
5357         * modules/byteswap (Makefile.am): Likewise.
5358         * modules/c-strtod (Makefile.am): Likewise.
5359         * modules/c-strtold (Makefile.am): Likewise.
5360         * modules/calloc (Makefile.am): Likewise.
5361         * modules/canon-host (Makefile.am): Likewise.
5362         * modules/canonicalize (Makefile.am): Likewise.
5363         * modules/chdir-long (Makefile.am): Likewise.
5364         * modules/chdir-safer (Makefile.am): Likewise.
5365         * modules/check-version (Makefile.am): Likewise.
5366         * modules/chown (Makefile.am): Likewise.
5367         * modules/cloexec (Makefile.am): Likewise.
5368         * modules/close-stream (Makefile.am): Likewise.
5369         * modules/closeout (Makefile.am): Likewise.
5370         * modules/crc (Makefile.am): Likewise.
5371         * modules/csharpexec (Makefile.am): Likewise.
5372         * modules/cycle-check (Makefile.am): Likewise.
5373         * modules/des (Makefile.am): Likewise.
5374         * modules/dev-ino (Makefile.am): Likewise.
5375         * modules/dirfd (Makefile.am): Likewise.
5376         * modules/dirname (Makefile.am): Likewise.
5377         * modules/dup2 (Makefile.am): Likewise.
5378         * modules/eealloc (Makefile.am): Likewise.
5379         * modules/error (Makefile.am): Likewise.
5380         * modules/euidaccess (Makefile.am): Likewise.
5381         * modules/exclude (Makefile.am): Likewise.
5382         * modules/exitfail (Makefile.am): Likewise.
5383         * modules/fcntl-safer (Makefile.am): Likewise.
5384         * modules/fcntl (Makefile.am): Likewise.
5385         * modules/file-type (Makefile.am): Likewise.
5386         * modules/fileblocks (Makefile.am): Likewise.
5387         * modules/filemode (Makefile.am): Likewise.
5388         * modules/filenamecat (Makefile.am): Likewise.
5389         * modules/fnmatch (Makefile.am): Likewise.
5390         * modules/fopen-safer (Makefile.am): Likewise.
5391         * modules/fpending (Makefile.am): Likewise.
5392         * modules/fprintftime (Makefile.am): Likewise.
5393         * modules/free (Makefile.am): Likewise.
5394         * modules/fsusage (Makefile.am): Likewise.
5395         * modules/ftruncate (Makefile.am): Likewise.
5396         * modules/fts (Makefile.am): Likewise.
5397         * modules/gc-arcfour (Makefile.am): Likewise.
5398         * modules/gc-des (Makefile.am): Likewise.
5399         * modules/gc-hmac-md5 (Makefile.am): Likewise.
5400         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
5401         * modules/gc-md4 (Makefile.am): Likewise.
5402         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
5403         * modules/gc-sha1 (Makefile.am): Likewise.
5404         * modules/gc (Makefile.am): Likewise.
5405         * modules/getaddrinfo (Makefile.am): Likewise.
5406         * modules/getcwd (Makefile.am): Likewise.
5407         * modules/getdelim (Makefile.am): Likewise.
5408         * modules/getdomainname (Makefile.am): Likewise.
5409         * modules/getgroups (Makefile.am): Likewise.
5410         * modules/gethostname (Makefile.am): Likewise.
5411         * modules/gethrxtime (Makefile.am): Likewise.
5412         * modules/getline (Makefile.am): Likewise.
5413         * modules/getloadavg (Makefile.am): Likewise.
5414         * modules/getlogin_r (Makefile.am): Likewise.
5415         * modules/getndelim2 (Makefile.am): Likewise.
5416         * modules/getopt (Makefile.am): Likewise.
5417         * modules/getpagesize (Makefile.am): Likewise.
5418         * modules/getpass-gnu (Makefile.am): Likewise.
5419         * modules/getpass (Makefile.am): Likewise.
5420         * modules/getsubopt (Makefile.am): Likewise.
5421         * modules/gettime (Makefile.am): Likewise.
5422         * modules/gettimeofday (Makefile.am): Likewise.
5423         * modules/getugroups (Makefile.am): Likewise.
5424         * modules/getusershell (Makefile.am): Likewise.
5425         * modules/glob (Makefile.am): Likewise.
5426         * modules/group-member (Makefile.am): Likewise.
5427         * modules/hard-locale (Makefile.am): Likewise.
5428         * modules/hash (Makefile.am): Likewise.
5429         * modules/hmac-md5 (Makefile.am): Likewise.
5430         * modules/hmac-sha1 (Makefile.am): Likewise.
5431         * modules/human (Makefile.am): Likewise.
5432         * modules/idcache (Makefile.am): Likewise.
5433         * modules/imaxabs (Makefile.am): Likewise.
5434         * modules/imaxdiv (Makefile.am): Likewise.
5435         * modules/inet_ntop (Makefile.am): Likewise.
5436         * modules/inet_pton (Makefile.am): Likewise.
5437         * modules/intprops (Makefile.am): Likewise.
5438         * modules/inttostr (Makefile.am): Likewise.
5439         * modules/inttypes (Makefile.am): Likewise.
5440         * modules/isapipe (Makefile.am): Likewise.
5441         * modules/javaversion (Makefile.am): Likewise.
5442         * modules/lchmod (Makefile.am): Likewise.
5443         * modules/lchown (Makefile.am): Likewise.
5444         * modules/localcharset (Makefile.am): Likewise.
5445         * modules/long-options (Makefile.am): Likewise.
5446         * modules/lstat (Makefile.am): Likewise.
5447         * modules/malloc (Makefile.am): Likewise.
5448         * modules/mathl (Makefile.am): Likewise.
5449         * modules/mbchar (Makefile.am): Likewise.
5450         * modules/md2 (Makefile.am): Likewise.
5451         * modules/md4 (Makefile.am): Likewise.
5452         * modules/md5 (Makefile.am): Likewise.
5453         * modules/memcasecmp (Makefile.am): Likewise.
5454         * modules/memchr (Makefile.am): Likewise.
5455         * modules/memcmp (Makefile.am): Likewise.
5456         * modules/memcoll (Makefile.am): Likewise.
5457         * modules/memcpy (Makefile.am): Likewise.
5458         * modules/memmem (Makefile.am): Likewise.
5459         * modules/memmove (Makefile.am): Likewise.
5460         * modules/mempcpy (Makefile.am): Likewise.
5461         * modules/memrchr (Makefile.am): Likewise.
5462         * modules/memset (Makefile.am): Likewise.
5463         * modules/memxor (Makefile.am): Likewise.
5464         * modules/mkancesdirs (Makefile.am): Likewise.
5465         * modules/mkdir-p (Makefile.am): Likewise.
5466         * modules/mkdir (Makefile.am): Likewise.
5467         * modules/mkdtemp (Makefile.am): Likewise.
5468         * modules/mkstemp (Makefile.am): Likewise.
5469         * modules/mktime (Makefile.am): Likewise.
5470         * modules/modechange (Makefile.am): Likewise.
5471         * modules/mountlist (Makefile.am): Likewise.
5472         * modules/nanosleep (Makefile.am): Likewise.
5473         * modules/obstack (Makefile.am): Likewise.
5474         * modules/openat (Makefile.am): Likewise.
5475         * modules/pagealign_alloc (Makefile.am): Likewise.
5476         * modules/pathmax (Makefile.am): Likewise.
5477         * modules/physmem (Makefile.am): Likewise.
5478         * modules/poll (Makefile.am): Likewise.
5479         * modules/posixtm (Makefile.am): Likewise.
5480         * modules/posixver (Makefile.am): Likewise.
5481         * modules/putenv (Makefile.am): Likewise.
5482         * modules/quote (Makefile.am): Likewise.
5483         * modules/quotearg (Makefile.am): Likewise.
5484         * modules/raise (Makefile.am): Likewise.
5485         * modules/read-file (Makefile.am): Likewise.
5486         * modules/readline (Makefile.am): Likewise.
5487         * modules/readlink (Makefile.am): Likewise.
5488         * modules/readtokens (Makefile.am): Likewise.
5489         * modules/readutmp (Makefile.am): Likewise.
5490         * modules/realloc (Makefile.am): Likewise.
5491         * modules/regex (Makefile.am): Likewise.
5492         * modules/rename-dest-slash (Makefile.am): Likewise.
5493         * modules/rename (Makefile.am): Likewise.
5494         * modules/rijndael (Makefile.am): Likewise.
5495         * modules/rmdir (Makefile.am): Likewise.
5496         * modules/rpmatch (Makefile.am): Likewise.
5497         * modules/safe-read (Makefile.am): Likewise.
5498         * modules/safe-write (Makefile.am): Likewise.
5499         * modules/same-inode (Makefile.am): Likewise.
5500         * modules/same (Makefile.am): Likewise.
5501         * modules/save-cwd (Makefile.am): Likewise.
5502         * modules/savedir (Makefile.am): Likewise.
5503         * modules/setenv (Makefile.am): Likewise.
5504         * modules/settime (Makefile.am): Likewise.
5505         * modules/sha1 (Makefile.am): Likewise.
5506         * modules/sig2str (Makefile.am): Likewise.
5507         * modules/snprintf (Makefile.am): Likewise.
5508         * modules/stat-macros (Makefile.am): Likewise.
5509         * modules/stat-time (Makefile.am): Likewise.
5510         * modules/stdbool (Makefile.am): Likewise.
5511         * modules/stdint (Makefile.am): Likewise.
5512         * modules/stdlib-safer (Makefile.am): Likewise.
5513         * modules/stpcpy (Makefile.am): Likewise.
5514         * modules/stpncpy (Makefile.am): Likewise.
5515         * modules/strcase (Makefile.am): Likewise.
5516         * modules/strcasestr (Makefile.am): Likewise.
5517         * modules/strchrnul (Makefile.am): Likewise.
5518         * modules/strcspn (Makefile.am): Likewise.
5519         * modules/strdup (Makefile.am): Likewise.
5520         * modules/strerror (Makefile.am): Likewise.
5521         * modules/strftime (Makefile.am): Likewise.
5522         * modules/strndup (Makefile.am): Likewise.
5523         * modules/strnlen (Makefile.am): Likewise.
5524         * modules/strpbrk (Makefile.am): Likewise.
5525         * modules/strsep (Makefile.am): Likewise.
5526         * modules/strstr (Makefile.am): Likewise.
5527         * modules/strtod (Makefile.am): Likewise.
5528         * modules/strtoimax (Makefile.am): Likewise.
5529         * modules/strtok_r (Makefile.am): Likewise.
5530         * modules/strtol (Makefile.am): Likewise.
5531         * modules/strtoll (Makefile.am): Likewise.
5532         * modules/strtoul (Makefile.am): Likewise.
5533         * modules/strtoull (Makefile.am): Likewise.
5534         * modules/strtoumax (Makefile.am): Likewise.
5535         * modules/strverscmp (Makefile.am): Likewise.
5536         * modules/sys_socket (Makefile.am): Likewise.
5537         * modules/sys_stat (Makefile.am): Likewise.
5538         * modules/sysexits (Makefile.am): Likewise.
5539         * modules/time_r (Makefile.am): Likewise.
5540         * modules/timegm (Makefile.am): Likewise.
5541         * modules/timespec (Makefile.am): Likewise.
5542         * modules/tmpfile-safer (Makefile.am): Likewise.
5543         * modules/trim (Makefile.am): Likewise.
5544         * modules/unistd-safer (Makefile.am): Likewise.
5545         * modules/unlinkdir (Makefile.am): Likewise.
5546         * modules/unlocked-io (Makefile.am): Likewise.
5547         * modules/userspec (Makefile.am): Likewise.
5548         * modules/utime (Makefile.am): Likewise.
5549         * modules/utimecmp (Makefile.am): Likewise.
5550         * modules/utimens (Makefile.am): Likewise.
5551         * modules/vasnprintf (Makefile.am): Likewise.
5552         * modules/vasprintf (Makefile.am): Likewise.
5553         * modules/vsnprintf (Makefile.am): Likewise.
5554         * modules/xalloc (Makefile.am): Likewise.
5555         * modules/xgetcwd (Makefile.am): Likewise.
5556         * modules/xnanosleep (Makefile.am): Likewise.
5557         * modules/xreadlink (Makefile.am): Likewise.
5558         * modules/xstrtod (Makefile.am): Likewise.
5559         * modules/xstrtol (Makefile.am): Likewise.
5560         * modules/xstrtold (Makefile.am): Likewise.
5561         * modules/yesno (Makefile.am): Likewise.
5562         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
5563
5564 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
5565
5566         * modules/error (Makefile.am): Distribute files through
5567         EXTRA_DIST, not lib_SOURCES.
5568
5569 2006-10-12  Eric Blake  <ebb9@byu.net>
5570
5571         * modules/error (Makefile.am): Distribute files in /lib.
5572         * modules/obstack (Makefile.am): Likewise.
5573
5574 2006-10-12  Bruno Haible  <bruno@clisp.org>
5575
5576         * modules/acl (Makefile.am): Distribute all files in lib/ through
5577         EXTRA_DIST.
5578         * modules/arcfour (Makefile.am): Likewise.
5579         * modules/arctwo (Makefile.am): Likewise.
5580         * modules/argmatch (Makefile.am): Likewise.
5581         * modules/argz (Makefile.am): Likewise.
5582         * modules/atexit (Makefile.am): Likewise.
5583         * modules/backupfile (Makefile.am): Likewise.
5584         * modules/c-strtod (Makefile.am): Likewise.
5585         * modules/c-strtold (Makefile.am): Likewise.
5586         * modules/calloc (Makefile.am): Likewise.
5587         * modules/canon-host (Makefile.am): Likewise.
5588         * modules/canonicalize (Makefile.am): Likewise.
5589         * modules/chdir-long (Makefile.am): Likewise.
5590         * modules/chdir-safer (Makefile.am): Likewise.
5591         * modules/check-version (Makefile.am): Likewise.
5592         * modules/chown (Makefile.am): Likewise.
5593         * modules/cloexec (Makefile.am): Likewise.
5594         * modules/close-stream (Makefile.am): Likewise.
5595         * modules/closeout (Makefile.am): Likewise.
5596         * modules/crc (Makefile.am): Likewise.
5597         * modules/cycle-check (Makefile.am): Likewise.
5598         * modules/des (Makefile.am): Likewise.
5599         * modules/dirfd (Makefile.am): Likewise.
5600         * modules/dirname (Makefile.am): Likewise.
5601         * modules/dup2 (Makefile.am): Likewise.
5602         * modules/euidaccess (Makefile.am): Likewise.
5603         * modules/exclude (Makefile.am): Likewise.
5604         * modules/exitfail (Makefile.am): Likewise.
5605         * modules/fcntl-safer (Makefile.am): Likewise.
5606         * modules/file-type (Makefile.am): Likewise.
5607         * modules/fileblocks (Makefile.am): Likewise.
5608         * modules/filemode (Makefile.am): Likewise.
5609         * modules/filenamecat (Makefile.am): Likewise.
5610         * modules/fnmatch (Makefile.am): Likewise.
5611         * modules/fopen-safer (Makefile.am): Likewise.
5612         * modules/fpending (Makefile.am): Likewise.
5613         * modules/fprintftime (Makefile.am): Likewise.
5614         * modules/free (Makefile.am): Likewise.
5615         * modules/fsusage (Makefile.am): Likewise.
5616         * modules/ftruncate (Makefile.am): Likewise.
5617         * modules/fts (Makefile.am): Likewise.
5618         * modules/gc (Makefile.am): Likewise.
5619         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
5620         * modules/getaddrinfo (Makefile.am): Likewise.
5621         * modules/getcwd (Makefile.am): Likewise.
5622         * modules/getdelim (Makefile.am): Likewise.
5623         * modules/getdomainname (Makefile.am): Likewise.
5624         * modules/getgroups (Makefile.am): Likewise.
5625         * modules/gethostname (Makefile.am): Likewise.
5626         * modules/gethrxtime (Makefile.am): Likewise.
5627         * modules/getline (Makefile.am): Likewise.
5628         * modules/getloadavg (Makefile.am): Likewise.
5629         * modules/getlogin_r (Makefile.am): Likewise.
5630         * modules/getopt (Makefile.am): Likewise.
5631         * modules/getpass (Makefile.am): Likewise.
5632         * modules/getpass-gnu (Makefile.am): Likewise.
5633         * modules/getsubopt (Makefile.am): Likewise.
5634         * modules/gettime (Makefile.am): Likewise.
5635         * modules/gettimeofday (Makefile.am): Likewise.
5636         * modules/getugroups (Makefile.am): Likewise.
5637         * modules/getusershell (Makefile.am): Likewise.
5638         * modules/glob (Makefile.am): Likewise.
5639         * modules/group-member (Makefile.am): Likewise.
5640         * modules/hard-locale (Makefile.am): Likewise.
5641         * modules/hash (Makefile.am): Likewise.
5642         * modules/hmac-md5 (Makefile.am): Likewise.
5643         * modules/hmac-sha1 (Makefile.am): Likewise.
5644         * modules/human (Makefile.am): Likewise.
5645         * modules/idcache (Makefile.am): Likewise.
5646         * modules/imaxabs (Makefile.am): Likewise.
5647         * modules/imaxdiv (Makefile.am): Likewise.
5648         * modules/inet_ntop (Makefile.am): Likewise.
5649         * modules/inet_pton (Makefile.am): Likewise.
5650         * modules/inttostr (Makefile.am): Likewise.
5651         * modules/isapipe (Makefile.am): Likewise.
5652         * modules/lchown (Makefile.am): Likewise.
5653         * modules/long-options (Makefile.am): Likewise.
5654         * modules/lstat (Makefile.am): Likewise.
5655         * modules/malloc (Makefile.am): Likewise.
5656         * modules/mathl (Makefile.am): Likewise.
5657         * modules/mbchar (Makefile.am): Likewise.
5658         * modules/md2 (Makefile.am): Likewise.
5659         * modules/md4 (Makefile.am): Likewise.
5660         * modules/md5 (Makefile.am): Likewise.
5661         * modules/memcasecmp (Makefile.am): Likewise.
5662         * modules/memchr (Makefile.am): Likewise.
5663         * modules/memcmp (Makefile.am): Likewise.
5664         * modules/memcoll (Makefile.am): Likewise.
5665         * modules/memcpy (Makefile.am): Likewise.
5666         * modules/memmem (Makefile.am): Likewise.
5667         * modules/memmove (Makefile.am): Likewise.
5668         * modules/mempcpy (Makefile.am): Likewise.
5669         * modules/memrchr (Makefile.am): Likewise.
5670         * modules/memset (Makefile.am): Likewise.
5671         * modules/memxor (Makefile.am): Likewise.
5672         * modules/mkancesdirs (Makefile.am): Likewise.
5673         * modules/mkdir (Makefile.am): Likewise.
5674         * modules/mkdir-p (Makefile.am): Likewise.
5675         * modules/mkdtemp (Makefile.am): Likewise.
5676         * modules/mkstemp (Makefile.am): Likewise.
5677         * modules/mktime (Makefile.am): Likewise.
5678         * modules/modechange (Makefile.am): Likewise.
5679         * modules/mountlist (Makefile.am): Likewise.
5680         * modules/nanosleep (Makefile.am): Likewise.
5681         * modules/openat (Makefile.am): Likewise.
5682         * modules/pagealign_alloc (Makefile.am): Likewise.
5683         * modules/physmem (Makefile.am): Likewise.
5684         * modules/poll (Makefile.am): Likewise.
5685         * modules/posixtm (Makefile.am): Likewise.
5686         * modules/posixver (Makefile.am): Likewise.
5687         * modules/putenv (Makefile.am): Likewise.
5688         * modules/quote (Makefile.am): Likewise.
5689         * modules/quotearg (Makefile.am): Likewise.
5690         * modules/raise (Makefile.am): Likewise.
5691         * modules/read-file (Makefile.am): Likewise.
5692         * modules/readline (Makefile.am): Likewise.
5693         * modules/readlink (Makefile.am): Likewise.
5694         * modules/readtokens (Makefile.am): Likewise.
5695         * modules/readutmp (Makefile.am): Likewise.
5696         * modules/realloc (Makefile.am): Likewise.
5697         * modules/regex (Makefile.am): Likewise.
5698         * modules/rename (Makefile.am): Likewise.
5699         * modules/rename-dest-slash (Makefile.am): Likewise.
5700         * modules/rijndael (Makefile.am): Likewise.
5701         * modules/rmdir (Makefile.am): Likewise.
5702         * modules/rpmatch (Makefile.am): Likewise.
5703         * modules/safe-read (Makefile.am): Likewise.
5704         * modules/safe-write (Makefile.am): Likewise.
5705         * modules/same (Makefile.am): Likewise.
5706         * modules/save-cwd (Makefile.am): Likewise.
5707         * modules/savedir (Makefile.am): Likewise.
5708         * modules/setenv (Makefile.am): Likewise.
5709         * modules/settime (Makefile.am): Likewise.
5710         * modules/sha1 (Makefile.am): Likewise.
5711         * modules/sig2str (Makefile.am): Likewise.
5712         * modules/snprintf (Makefile.am): Likewise.
5713         * modules/stdlib-safer (Makefile.am): Likewise.
5714         * modules/stpcpy (Makefile.am): Likewise.
5715         * modules/stpncpy (Makefile.am): Likewise.
5716         * modules/strcase (Makefile.am): Likewise.
5717         * modules/strcasestr (Makefile.am): Likewise.
5718         * modules/strchrnul (Makefile.am): Likewise.
5719         * modules/strcspn (Makefile.am): Likewise.
5720         * modules/strdup (Makefile.am): Likewise.
5721         * modules/strerror (Makefile.am): Likewise.
5722         * modules/strftime (Makefile.am): Likewise.
5723         * modules/strndup (Makefile.am): Likewise.
5724         * modules/strnlen (Makefile.am): Likewise.
5725         * modules/strpbrk (Makefile.am): Likewise.
5726         * modules/strsep (Makefile.am): Likewise.
5727         * modules/strstr (Makefile.am): Likewise.
5728         * modules/strtod (Makefile.am): Likewise.
5729         * modules/strtoimax (Makefile.am): Likewise.
5730         * modules/strtok_r (Makefile.am): Likewise.
5731         * modules/strtol (Makefile.am): Likewise.
5732         * modules/strtoll (Makefile.am): Likewise.
5733         * modules/strtoul (Makefile.am): Likewise.
5734         * modules/strtoull (Makefile.am): Likewise.
5735         * modules/strtoumax (Makefile.am): Likewise.
5736         * modules/strverscmp (Makefile.am): Likewise.
5737         * modules/time_r (Makefile.am): Likewise.
5738         * modules/timegm (Makefile.am): Likewise.
5739         * modules/tmpfile-safer (Makefile.am): Likewise.
5740         * modules/unistd-safer (Makefile.am): Likewise.
5741         * modules/unlinkdir (Makefile.am): Likewise.
5742         * modules/userspec (Makefile.am): Likewise.
5743         * modules/utime (Makefile.am): Likewise.
5744         * modules/utimecmp (Makefile.am): Likewise.
5745         * modules/utimens (Makefile.am): Likewise.
5746         * modules/vasnprintf (Makefile.am): Likewise.
5747         * modules/vasprintf (Makefile.am): Likewise.
5748         * modules/vsnprintf (Makefile.am): Likewise.
5749         * modules/xalloc (Makefile.am): Likewise.
5750         * modules/xgetcwd (Makefile.am): Likewise.
5751         * modules/xnanosleep (Makefile.am): Likewise.
5752         * modules/xreadlink (Makefile.am): Likewise.
5753         * modules/xstrtod (Makefile.am): Likewise.
5754         * modules/xstrtol (Makefile.am): Likewise.
5755         * modules/xstrtold (Makefile.am): Likewise.
5756         * modules/yesno (Makefile.am): Likewise.
5757
5758 2006-10-12  Jim Meyering  <jim@meyering.net>
5759
5760         * m4/getloadavg.m4: Revert the change below.
5761
5762         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
5763         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
5764         fail with a symlink, which is what coreutils' ./bootstrap now
5765         creates by default.
5766
5767 2006-10-12  Bruno Haible  <bruno@clisp.org>
5768
5769         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
5770         mingw.
5771         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
5772         MSVC and mingw explicitly.
5773
5774 2006-10-11  Simon Josefsson  <jas@extundo.com>
5775             Bruno Haible  <bruno@clisp.org>
5776
5777         Add support for multiple gnulib-tool invocations in the scope of a
5778         single configure.ac file.
5779         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
5780         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
5781         with the same contents as the _LIBADD variable.
5782         (func_emit_initmacro_start, func_emit_initmacro_end,
5783         func_emit_initmacro_done): New functions.
5784         (func_import, func_create_testdir): Invoke them. Allow the identifiers
5785         gl_LIBOBJS and gl_LTLIBOBJS.
5786
5787 2006-10-11  Bruno Haible  <bruno@clisp.org>
5788
5789         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
5790         (func_create_testdir): Don't create po/Makefile.am, don't invoke
5791         autoreconf. Instead, invoke autopoint explicitly but move back the
5792         *.m4 files from gnulib.
5793
5794 2006-10-11  Bruno Haible  <bruno@clisp.org>
5795
5796         * gnulib-tool (func_usage): Make module names after --create-testdir
5797         optional.
5798         (func_create_testdir): If no module was specified, use nearly all
5799         modules.
5800
5801 2006-10-12  Jim Meyering  <jim@meyering.net>
5802
5803         Big performance improvement for fts-based tools that use FTS_NOSTAT.
5804         Avoid spurious inode-mismatch problems on non-POSIX file systems.
5805         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
5806         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
5807         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
5808         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
5809         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
5810         (fts_set_stat_required): New function.
5811         (fts_open): Defer the calls to fts_stat, if possible or requested.
5812         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
5813         into fts_stat itself.
5814         (fts_read): Perform any required (deferred) fts_stat call.
5815         (fts_build): Likewise, for the directory we're about to open and read.
5816         In the readdir loop, carefully decide whether each entry will require
5817         an eventual call to fts_stat, using dirent.d_type info if available.
5818         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
5819         a command line argument into this function.  Update all callers.
5820         Map a return value of FTS_DOT to FTS_D for a command line argument.
5821         * modules/fts (Depends-on): Add d-type.  Alphabetize.
5822         Thanks to Miklos Szeredi for his tenacity and for the initial
5823         bug report about "find" failing on a FUSE-based file system.
5824
5825         * lib/fts.c (fts_open): Use consistent indentation.
5826
5827 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
5828
5829         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
5830         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
5831         reported by Jim Meyering.  All uses of cache variables renamed
5832         to match Autoconf's.
5833         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
5834         the other one.
5835
5836         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
5837         Fix misspelling in diagnostic.
5838
5839 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
5840
5841         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
5842         defined.  Problem reported by Matthew Woehlke.
5843
5844         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
5845         Add support for Tandem NonStop R series.
5846         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
5847         Use new macro.
5848
5849         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
5850         (has_trailing_slash): Omit size arg; all callers changed.
5851         Omit 'inline', since it doesn't help performance and we'd
5852         need to configure it.
5853         Don't count //, ///, etc. as having a trailing slash.
5854         As a side effect, this removes a C99ism reported by Matthew Woehlke.
5855         (rpl_rename_dest_slash): On failure, use rename's errno rather
5856         than (in some cases) an incorrect or junk errno.
5857         Simplify code by removing need to compute length; this does
5858         cause it to make two passes instead of one over the file name,
5859         but it's worth it.
5860
5861         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
5862         change, since Autoconf's version may no longer be appropriate now
5863         that we are using CVS Autoconf's version.  Add support for Tandem.
5864
5865 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
5866             Bruno Haible  <bruno@clisp.org>
5867
5868         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
5869         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
5870         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
5871         gl_AC_TYPE_LONG_LONG.
5872
5873         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
5874         instead of HAVE_LONG_LONG.
5875         * lib/printf-args.c (printf_fetchargs): Likewise.
5876         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
5877         * lib/vasnprintf.c (VASNPRINTF): Likewise.
5878         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
5879         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
5880         gl_AC_TYPE_LONG_LONG.
5881
5882 2006-10-11  Bruno Haible  <bruno@clisp.org>
5883
5884         * m4/longlong.m4: Add comments.
5885         * m4/ulonglong.m4: Likewise.
5886
5887 2006-10-10  Bruno Haible  <bruno@clisp.org>
5888
5889         Make it possible to #define stpcpy, strdup to aliases.
5890         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
5891         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
5892
5893 2006-10-10  Bruno Haible  <bruno@clisp.org>
5894
5895         Make it possible to #define gcd to an alias.
5896         * lib/gcd.c: Include config.h.
5897
5898 2006-10-10  Bruno Haible  <bruno@clisp.org>
5899
5900         Make it possible to #define c_isascii to an alias.
5901         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
5902         defined. Undefine the macros before defining them, to avoid gcc
5903         warnings.
5904         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
5905         define NO_C_CTYPE_MACROS early.
5906
5907 2006-10-10  Bruno Haible  <bruno@clisp.org>
5908
5909         Make it possible to #define set_program_name to an alias.
5910         * lib/progname.c: Don't undefine set_program_name; instead, undefine
5911         ENABLE_RELOCATABLE early.
5912
5913 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
5914
5915         Port to Tandem NSK OSS, which has 64-bit signed int but at most
5916         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
5917         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
5918         More generally, don't assume that 64-bit signed int is available
5919         if unsigned int is, and vice versa.
5920         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
5921         unsigned symbols, not on their signed counterparts.
5922         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
5923         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
5924         (UINT64_C, UINTMAX_C):
5925         Likewise.
5926         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
5927         unsigned counterparts.
5928         (Have_long_long, Unsigned): New macros.
5929         (Int): Renamed from INT.
5930         (strtoimax): Use the new macros.
5931         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
5932         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
5933         * modules/inttypes (inttypes.h): Substitute
5934         HAVE_UNSIGNED_LONG_LONG_INT.
5935         * modules/stdint (stdint.h): Likewise.
5936         (Files): Add m4/ulonglong.m4.
5937
5938 2006-10-10  Bruno Haible  <bruno@clisp.org>
5939
5940         Fix a gcc -Wshadow warning.
5941         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
5942         to 'bucket'.
5943         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
5944         gl_linked_indexof_from_to): Likewise.
5945         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
5946         Likewise.
5947         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
5948         Likewise.
5949         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
5950         Reported by Eric Blake.
5951
5952 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
5953
5954         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
5955         for NetBSD.  Problem reported by Bruno Haible.
5956
5957 2006-10-09  Jim Meyering  <jim@meyering.net>
5958
5959         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
5960         Patch from Bruno Haible.
5961
5962 2006-10-09  Jim Meyering  <jim@meyering.net>
5963
5964         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
5965         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
5966         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
5967
5968 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
5969
5970         Don't include <config.h> twice; this doesn't work in some cases,
5971         e.g., when config.h has "#define intmax_t long long int" and
5972         we include <config.h>, <inttypes.h>, <config.h> in that order.
5973         Problem reported by Matthew Woehlke in:
5974         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
5975         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
5976         * lib/fts-cycle.c: Don't include config.h.
5977         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
5978         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
5979         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
5980         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
5981         inttypes.h.
5982         * lib/xstrtoumax.c: Likewise.
5983         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
5984         __strtol and the like, so that this module is more like its siblings.
5985         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
5986         Remove; no longer needed now that we assume gnulib inttypes.h.
5987
5988 2006-10-08  Bruno Haible  <bruno@clisp.org>
5989
5990         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
5991         option.
5992
5993 2006-10-07  Jim Meyering  <jim@meyering.net>
5994
5995         * modules/inttypes (inttypes.h): Revert what seems to have been
5996         an inadvertent part of today's change: use "|", not "/" in the
5997         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
5998
5999 2006-10-07  Bruno Haible  <bruno@clisp.org>
6000
6001         * modules/sublist: New file.
6002
6003 2006-10-07  Bruno Haible  <bruno@clisp.org>
6004
6005         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
6006         * modules/argz (argz.h): Likewise.
6007         * modules/arpa_inet (arpa/inet.h): Likewise.
6008         * modules/byteswap (byteswap.h): Likewise.
6009         * modules/configmake (configmake.h): Likewise.
6010         * modules/fcntl (fcntl.h): Likewise.
6011         * modules/fnmatch (fnmatch.h): Likewise.
6012         * modules/getopt (getopt.h): Likewise.
6013         * modules/glob (glob.h): Likewise.
6014         * modules/inttypes (inttypes.h): Likewise.
6015         * modules/netinet_in (netinet/in.h): Likewise.
6016         * modules/poll (poll.h): Likewise.
6017         * modules/stdbool (stdbool.h): Likewise.
6018         * modules/stdint (stdint.h): Likewise.
6019         * modules/sys_select (sys/select.h): Likewise.
6020         * modules/sys_socket (sys/socket.h): Likewise.
6021         * modules/sys_stat (sys/stat.h): Likewise.
6022         * modules/sysexits (sysexits.h): Likewise.
6023         * modules/unistd (unistd.h): Likewise.
6024         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6025         Add a "DO NOT EDIT" comment to the generated file.
6026         (func_import): Likewise for gnulib-comp.m4.
6027
6028 2006-10-07  Bruno Haible  <bruno@clisp.org>
6029
6030         * lib/gl_sublist.h: New file.
6031         * lib/gl_sublist.c: New file.
6032
6033 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
6034
6035         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
6036         name (relative to the original working directory) and the file
6037         name component (relative to the temporary working directory).  All
6038         callers changed.
6039         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
6040         * lib/mkdir-p.c (make_dir_parents): Likewise.
6041         * lib/mkdir-p.h (make_dir_parents): Likewise.
6042
6043 2006-10-06  Eric Blake  <ebb9@byu.net>
6044
6045         Define several macros for use by the clean-temp module.
6046         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
6047         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
6048         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
6049
6050         * lib/clean-temp.h (close_stream_temp): New declaration.
6051         * lib/clean-temp.c (includes): Pull in headers according to what
6052         other modules are in use.
6053         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
6054
6055 2006-10-06  Bruno Haible  <bruno@clisp.org>
6056
6057         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
6058         instead of fopen, fwriteerror.
6059
6060 2006-10-06  Bruno Haible  <bruno@clisp.org>
6061
6062         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
6063         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
6064         int.
6065         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
6066         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
6067         Return an error indicator.
6068         Suggested by Eric Blake.
6069
6070 2006-10-06  Bruno Haible  <bruno@clisp.org>
6071
6072         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
6073         Reported by Eric Blake.
6074
6075 2006-10-06  Bruno Haible  <bruno@clisp.org>
6076
6077         * modules/closeout (Description): Mention stderr too.
6078
6079 2006-10-06  Bruno Haible  <bruno@clisp.org>
6080         and Paul Eggert  <eggert@cs.ucla.edu>
6081
6082         * lib/closeout.c (close_stdout): Also close stderr.
6083         * lib/closeout.h: Update comment.
6084
6085 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
6086
6087         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
6088         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
6089         * lib/dirchownmod.c: Include lchown.h.
6090         * lib/lchown.c: Don't include files that lchown.h now includes.
6091         Don't declare chown, since lchown.h now does that.
6092         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
6093         (lchown): Define to rpl_chown if lchown is declared but
6094         does not exist.  Declare using a prototype if lchown is not
6095         declared.  Add a copyright notice.
6096         * lib/mkstemp.h: Include <unistd.h>.
6097         * lib/openat.c: Include lchown.h.
6098
6099         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
6100         we now test for that separately.
6101         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
6102         rather than O_NOFOLLOW, when testing whether it's possible to
6103         avoid a race condition reliably.
6104         * lib/savewd.c (savewd_chdir): Likewise.
6105
6106         Remove macros that are no longer needed now that stdint.h is
6107         reliable.
6108         * lib/fsusage.c (UINTMAX_MAX): Remove.
6109         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
6110         * lib/utimecmp.c (SIZE_MAX): Remove.
6111
6112         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
6113
6114         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
6115         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
6116         O_NOATIME works.
6117
6118 2006-10-05  Bruno Haible  <bruno@clisp.org>
6119
6120         * lib/gl_list.h (gl_sortedlist_search_from_to,
6121         gl_sortedlist_indexof_from_to): New declarations.
6122         (gl_list_implementation): New fields sortedlist_search_from_to,
6123         sortedlist_indexof_from_to.
6124         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
6125         inline functions.
6126         * lib/gl_list.c (gl_sortedlist_search_from_to,
6127         gl_sortedlist_indexof_from_to): New functions.
6128         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
6129         function.
6130         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
6131         (gl_array_sortedlist_search_from_to): New function.
6132         (gl_array_list_implementation): Update.
6133         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
6134         function.
6135         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
6136         (gl_carray_sortedlist_search_from_to): New function.
6137         (gl_carray_list_implementation): Update.
6138         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
6139         gl_linked_sortedlist_indexof_from_to): New functions.
6140         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6141         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6142         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
6143         gl_tree_sortedlist_indexof_from_to): New functions.
6144         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6145         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6146         Update.
6147         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6148         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
6149         Update.
6150
6151 2006-10-05  Bruno Haible  <bruno@clisp.org>
6152
6153         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
6154         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
6155         (struct gl_list_implementation): Add fields search_from_to,
6156         indexof_from_to. Remove fields search, indexof.
6157         (gl_list_search): Use the search_from_to method.
6158         (gl_list_search_from, gl_list_search_from_to): New functions.
6159         (gl_list_indexof): Use the indexof_from_to method.
6160         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6161         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
6162         (gl_list_search_from, gl_list_search_from_to): New functions.
6163         (gl_list_indexof): Use the indexof_from_to method.
6164         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6165         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
6166         gl_array_indexof. Add start_index, end_index arguments.
6167         (gl_array_search_from_to): Renamed from gl_array_search. Add
6168         start_index, end_index arguments.
6169         (gl_array_remove, gl_array_list_implementation): Update.
6170         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
6171         gl_carray_indexof. Add start_index, end_index arguments.
6172         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
6173         start_index, end_index arguments.
6174         (gl_carray_remove, gl_carray_list_implementation): Update.
6175         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
6176         gl_linked_search. Add start_index, end_index arguments.
6177         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
6178         start_index, end_index arguments.
6179         (gl_linked_remove): Update.
6180         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6181         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6182         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
6183         field to 'size_t'.
6184         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
6185         gl_tree_search. Add start_index, end_index arguments.
6186         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6187         start_index, end_index arguments.
6188         (gl_tree_remove): Update.
6189         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6190         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6191         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
6192         function.
6193         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
6194         gl_tree_search. Add start_index, end_index arguments.
6195         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6196         start_index, end_index arguments.
6197         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6198         Update.
6199         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
6200
6201 2006-10-05  Bruno Haible  <bruno@clisp.org>
6202
6203         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
6204
6205         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
6206         fwriteerror_temp): New declarations.
6207         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
6208         (descriptors): New variable.
6209         (cleanup): First, close the descriptors.
6210         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
6211         fclose_temp, fwriteerror_temp): New functions.
6212
6213 2006-10-04  Jim Meyering  <jim@meyering.net>
6214
6215         * lib/fts.c (fts_open): Tiny comment change.
6216
6217 2006-10-04  Bruno Haible  <bruno@clisp.org>
6218
6219         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
6220         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
6221         gl_LOCK_BODY.
6222         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
6223         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
6224         gl_LOCK_EARLY_BODY.
6225         (gl_LOCK): Require gl_LOCK_BODY.
6226
6227 2006-10-04  Bruno Haible  <bruno@clisp.org>
6228
6229         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
6230         (gl_oset_search_atleast): New declaration.
6231         (struct gl_oset_implementation): Add field 'search_atleast'.
6232         (gl_oset_search_atleast): New inline function.
6233         * lib/gl_oset.c (gl_oset_search_atleast): New function.
6234         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
6235         (gl_array_oset_implementation): Update.
6236         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
6237         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
6238         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
6239
6240 2006-10-04  Bruno Haible  <bruno@clisp.org>
6241
6242         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
6243
6244 2006-10-03  Bruno Haible  <bruno@clisp.org>
6245
6246         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
6247         from gl_avltreehash_list_implementation.
6248
6249 2006-10-03  Bruno Haible  <bruno@clisp.org>
6250
6251         * lib/gl_oset.c (gl_oset_add): Fix return type.
6252
6253 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
6254
6255         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
6256
6257 2006-10-02  Eric Blake  <ebb9@byu.net>
6258
6259         * modules/strnlen (Depends-on): Add extensions.
6260
6261 2006-10-02  Eric Blake  <ebb9@byu.net>
6262
6263         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
6264         definition in 2.60+.
6265
6266 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
6267
6268         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
6269         checks.
6270
6271 2006-10-02  Bruno Haible  <bruno@clisp.org>
6272
6273         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
6274         to the AUTOMAKE_OPTIONS.
6275         Reported by Jim Meyering.
6276
6277 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
6278
6279         Work around bug in Solaris 10 /proc file system:
6280         /proc/self/fd/NNN/.. isn't the parent directory of
6281         the directory whose file descriptor is NNN.  This needs to
6282         be worked around at run time, not compile time, since a
6283         program might be built on Solaris 8, where things work, and
6284         run on Solaris 10.
6285         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
6286         to use the following interface instead:
6287         (OPENAT_BUFFER_SIZE): New macro.
6288         (openat_proc_name): New function.
6289         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
6290         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
6291         Likewise.
6292         * lib/openat-proc.c: New file.
6293         * modules/openat (Files): Add lib/openat-proc.c.
6294         (Depends-on): Add same-inode, stdbool.
6295         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
6296
6297 2006-09-29  Bruno Haible  <bruno@clisp.org>
6298
6299         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
6300         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
6301         argument. Set stdout_closed before testing for ferror, not after.
6302         (fwriteerror, fwriteerror_no_ebadf): New functions.
6303
6304 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6305
6306         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
6307
6308 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
6309
6310         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
6311         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
6312
6313 2006-09-28  Jim Meyering  <jim@meyering.net>
6314
6315         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
6316         Include <unistd.h>.
6317
6318 2006-09-28  Bruno Haible  <bruno@clisp.org>
6319
6320         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
6321         * modules/linkedhash-list (Depends-on): Likewise.
6322         * modules/rbtreehash-list (Depends-on): Likewise.
6323
6324 2006-09-28  Bruno Haible  <bruno@clisp.org>
6325
6326         * lib/strndup.h: Simplify the redefinition of strndup.
6327         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
6328         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
6329
6330 2006-09-28  Bruno Haible  <bruno@clisp.org>
6331
6332         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
6333         * lib/gl_linkedhash_list.c: Likewise.
6334         * lib/gl_rbtreehash_list.c: Likewise.
6335
6336 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
6337
6338         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
6339         getaddrinfo.
6340
6341         * lib/__fpending.h: Don't include <stdio_ext.h> unless
6342         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
6343         it causes <stdio_ext.h> to cause a compile-time error.
6344         Problem reported by Nelson H. F. Beebe.
6345         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
6346         of HAVE_DECL___PENDING.
6347
6348         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
6349         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
6350         declaration.
6351
6352 2006-09-27  Jim Meyering  <jim@meyering.net>
6353
6354         This file could end up with a definition for a function
6355         named __strndup, rather than rpl_strndup on a system with
6356         incomplete weak_alias support.
6357         * lib/strndup.c (strndup): Rename from __strndup.
6358         Remove #defines that used to map __strndup to strndup.
6359         Don't use K&R prototypes.
6360         Remove LIBC-related code, since this file is not sync'd with glibc.
6361         * lib/strndup.h: Revamp, accordingly.
6362         * m4/strndup.m4: Modernize.
6363
6364 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
6365
6366         * modules/savewd (Depends-on): Add 'raise'.
6367         * lib/savewd.c: Include <signal.h>, for 'raise'.
6368
6369 2006-09-26  Jim Meyering  <jim@meyering.net>
6370
6371         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
6372         when we detect Darwin 8.7.0's acl_get_file bug.
6373         Rearrange to perform the new (below) run-test while $LIBS
6374         contains any acl-related library.  Set USE_ACL at the end.
6375         (gl_ACL_GET_FILE): New function.
6376
6377 2006-09-26  Eric Blake  <ebb9@byu.net>
6378
6379         * lib/verror.c: Include <config.h> unconditionally.
6380
6381 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
6382
6383         * modules/clock-time (Maintainer): Add self.
6384         * modules/getlogin_r (Depends-on): Add extensions.
6385
6386 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6387
6388         * modules/clock-time: New module.
6389         * modules/nanosleep (Depends-on): Add clock-time.
6390         * modules/gethrxtime (Depends-on): Likewise.
6391         * modules/gettime (Depends-on): Likewise.
6392         * modules/settime (Depends-on): Likewise.
6393
6394         * modules/fts-lgpl: Depend on openat.
6395         * modules/mkancesdirs: Depend on savewd.
6396         * modules/mkdir-p: Likewise.
6397
6398 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6399
6400         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
6401
6402         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
6403         `gl_have_arbitrary_file_name_length_limit' to
6404         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
6405         actually works between configure runs.
6406
6407 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6408             Bruno Haible  <bruno@clisp.org>
6409
6410         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
6411
6412 2006-09-25  Jim Meyering  <jim@meyering.net>
6413
6414         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
6415         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
6416
6417 2006-09-25  Eric Blake  <ebb9@byu.net>
6418
6419         * gnulib-tool (func_import, func_create_testdir): Fix typos in
6420         exec's in 2006-09-18 patch when shuffling fds.
6421
6422 2006-09-25  Bruno Haible  <bruno@clisp.org>
6423
6424         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
6425         Reported by Jim Meyering.
6426
6427 2006-09-24  Jim Meyering  <jim@meyering.net>
6428
6429         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
6430         compare a pointer against a literal "0".  That caused failures with
6431         at least HP-UX's hpcc.
6432
6433 2006-09-22  Simon Josefsson  <jas@extundo.com>
6434
6435         * modules/gc-sha1:
6436         * modules/gc-md4:
6437         * modules/gc-hmac-sha1:
6438         * modules/gc-hmac-md5:
6439         * modules/gc-des:
6440         * modules/gc-arcfour: Distribute more files.
6441
6442 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6443
6444         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
6445         (gl_linked_iterator_from_to): Initialize struct completely.
6446         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
6447         (gl_tree_iterator_from_to): Likewise
6448         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
6449         * lib/gl_array_list.c [lint] (gl_array_iterator)
6450         (gl_array_iterator_from_to): Likewise.
6451         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
6452         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
6453         (gl_carray_iterator_from_to): Likewise.
6454
6455         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
6456         * lib/md4.c (md4_process_block): Remove unused variable.
6457         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
6458         parentheses for clarity.
6459
6460 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6461
6462         * modules/bison-i18n (Depends-on): Add gettext.
6463
6464 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6465
6466         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
6467         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
6468         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
6469         also add missing comma that caused broken test.
6470         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
6471         stdlib.h, for `abort'.
6472         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
6473         variables.
6474         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
6475         include unistd.h if present, for `rmdir'.
6476         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
6477         variables.
6478         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
6479         in the process include standard headers for prototypes.
6480         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
6481         gets declared on GNU/Linux.
6482         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
6483         unistd.h, for `rmdir'.
6484         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
6485
6486         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
6487         always true.
6488         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
6489
6490         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
6491
6492 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6493
6494         * gnulib-tool (func_version): Create output all at once.  This
6495         may help avoid triggering unnecessary SIGPIPEs, and at any
6496         rate it doesn't hurt.
6497
6498 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6499             Bruno Haible  <bruno@clisp.org>
6500
6501         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
6502         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
6503         * m4/signed.m4 (bh_C_SIGNED): Likewise.
6504
6505         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
6506         (gl_FUNC_VASPRINTF): Invoke it.
6507
6508 2006-09-22  Bruno Haible  <bruno@clisp.org>
6509
6510         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
6511         getloadavg.c as first argument.
6512
6513 2006-09-22  Bruno Haible  <bruno@clisp.org>
6514
6515         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
6516         at the beginning of the gl_INIT macro.
6517         * modules/getloadavg (configure.ac): Pass $gl_source_base to
6518         gl_GETLOADAVG.
6519
6520 2006-09-22  Bruno Haible  <bruno@clisp.org>
6521
6522         * gnulib-tool (func_create_megatestdir): Don't include the config-h
6523         module.
6524         Suggested by Ralf Wildenhues.
6525
6526 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
6527
6528         Import this patch from libc:
6529
6530         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
6531
6532         * lib/regex_internal.c (re_string_reconstruct): Handle
6533         offset < pstr->valid_raw_len && pstr->offsets_needed case.
6534         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
6535         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
6536         re_string_context_at.
6537
6538         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
6539         now requires it.
6540         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
6541         gl_REGEX now does it for us.
6542         (gl_REGEX): Add test taken from
6543         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
6544
6545         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
6546         Check that large offsets work.  Modernize Autoconf usages.
6547         Prefer "yes" to mean a good thing rather than a bad.
6548         Don't put "#define mkstemp" in config.h, as this might interfere
6549         with standard system headers that "#define mkstemp mkstemp64".
6550
6551         * modules/mkstemp (Depends-on): Add extensions, so that
6552         mkstemp is visible on some platforms.
6553         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
6554         (Include): Change to "mkstemp.h" from <stdlib.h>.
6555         (Files): Add mkstemp.h.
6556
6557         * lib/mkstemp.h: New file, since some standard headers
6558         #define mkstemp.
6559         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
6560         Include "mkstemp.h".
6561         Make the _LIBC code resemble glibc original more,
6562         e.g., use K&R style.
6563         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
6564         (mkstemp): Remove, since mkstemp.h does this for us.
6565         * lib/stdlib--.h: Include mkstemp.h.
6566
6567         Import this patch from libc:
6568
6569         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
6570
6571         * lib/tempname.c (__gen_tempname): Change attempts_min
6572         into a macro.  Use preprocessor to decide how to initialize
6573         attempts [Coverity CID 67].
6574
6575 2006-09-20  Bruno Haible  <bruno@clisp.org>
6576
6577         * lib/mkdtemp.c: Import from libc.
6578         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
6579                 * sysdeps/posix/tempname.c (__gen_tempname): Change
6580                 attempts_min into a macro.  Use preprocessor to decide how to
6581                 initialize attempts [Coverity CID 67].
6582         2001-11-27  Paul Eggert  <eggert@twinsun.com>
6583                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
6584                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
6585
6586 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6587
6588         * gnulib-tool (func_exit): New function, to allow to pass the
6589         exit status portably through the trap.  Use everywhere.
6590         (--help, --version): Signal a write error.
6591         (trap): catch SIGPIPE, for write errors.
6592         Exit at the end of the trap, with the correct exit status.
6593
6594 2006-09-19  Karl Berry  <karl@gnu.org>
6595
6596         * doc/gnulib.texi: note about the license texinfo files.
6597
6598 2006-09-19  Eric Blake  <ebb9@byu.net>
6599
6600         * gnulib-tool: Avoid space-tab.
6601
6602 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
6603
6604         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
6605         that prevented coreutils 6.1 from building.  Problem reported
6606         by Petter Reinholdtsen.
6607
6608 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
6609
6610         * gnulib-tool (avoidlist): Fix typo that broke options like
6611         --avoid=lock that are used by coreutils bootstrap.
6612
6613 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
6614
6615         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
6616         more systematically.
6617
6618 2006-09-18  Jim Meyering  <jim@meyering.net>
6619
6620         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
6621
6622 2006-09-18  Bruno Haible  <bruno@clisp.org>
6623
6624         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
6625
6626 2006-09-18  Bruno Haible  <bruno@clisp.org>
6627
6628         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
6629         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
6630         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
6631         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
6632         * m4/gettext.m4: Require autoconf >= 2.52.
6633         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
6634         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
6635         of gl_cv_header_inttypes_h.
6636
6637 2006-09-18  Bruno Haible  <bruno@clisp.org>
6638
6639         * lib/javaversion.c: Include configmake.h.
6640
6641 2006-09-18  Bruno Haible  <bruno@clisp.org>
6642
6643         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
6644         avoid that the while loops be executed in a subshell.
6645
6646 2006-09-18  Bruno Haible  <bruno@clisp.org>
6647
6648         * MODULES.html.sh (func_module): Break long lines.
6649         Suggested by Bruce Korb <bkorb@gnu.org>.
6650
6651 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6652
6653         Speed up by a factor of 1.12.
6654         * gnulib-tool (nl): New variable.
6655         (func_import): Rewrite include directive extraction to only read each
6656         directive once.
6657
6658 2006-09-17  Bruno Haible  <bruno@clisp.org>
6659
6660         * modules/javaversion (Makefile.am): Remove DEFS setting.
6661         (Depends-on): Add configmake, for PKGDATADIR definition.
6662
6663 2006-09-17  Bruno Haible  <bruno@clisp.org>
6664
6665         * gnulib-tool (func_create_testdir): Rewrite all files at once.
6666
6667 2006-09-17  Bruno Haible  <bruno@clisp.org>
6668
6669         * gnulib-tool (func_append): New function, stolen from libtool.m4.
6670         (func_modules_transitive_closure, func_modules_add_dummy,
6671         func_modules_to_filelist, func_import, func_create_testdir,
6672         func_create_megatestdir, ...): Use it wherever possible.
6673         Suggested by Ralf Wildenhues.
6674
6675 2006-09-16  Karl Berry  <karl@gnu.org>
6676
6677         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
6678         to avoid sectioning errors.
6679         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
6680         [ifinfo]: blank line after @center-ed titles.
6681         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
6682         Spell FSF address consistently with others.
6683         (These changes approved by rms.)
6684
6685 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6686
6687         Speed up by a factor of 1.61.
6688         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
6689         already checked module names again.
6690
6691 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6692
6693         Speed up by a factor of 1.13.
6694         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
6695         for new_files, and the input to func_add_or_update.
6696
6697 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6698
6699         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
6700         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
6701
6702 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
6703
6704         * modules/mkancesdirs (Depends-on): Add fcntl.
6705         * modules/savewd: New file.
6706         * MODULES.html.sh (File system functions): Add savewd.
6707
6708         * modules/configmake (Makefile.am): Add support for the
6709         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
6710
6711 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
6712
6713         * m4/savewd.m4: New file.
6714
6715 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
6716
6717         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
6718         (dirchownmod): New arg FD.  All callers changed.
6719         Use FD rather than opening the directory ourself, as opening is
6720         now the caller's responsibility.
6721         * lib/dirchownmod.h: Likewise.
6722         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
6723         hosts that require <sys/types.h> before <sys/stat.h>.  Include
6724         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
6725         (test_dir): Remove.
6726         (mkancesdirs): Return length of prefix of FILE that has already
6727         been made, or -2 if there is a child doing the work.  Redo
6728         algorithm so that it is O(N) rather than O(N**2).  Optimize away
6729         ".", and treat ".." specially since it might stray back into
6730         already-created areas.  Use a subprocess if necessary.  New arg
6731         WD; all users changed.  MAKE_DIR function should now return 1
6732         if it creates a directory that is not readable.  Return -2 if
6733         a child process is spun off.
6734         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
6735         Adjust signature to match code.
6736         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
6737         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
6738         all users changed.
6739         * lib/savewd.c, lib/savewd.h: New files.
6740
6741 2006-09-15  Jim Meyering  <jim@meyering.net>
6742
6743         * modules/rename-dest-slash: New module.
6744         * MODULES.html.sh (posix_compat): Add it here.
6745
6746         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
6747
6748 2006-09-15  Jim Meyering  <jim@meyering.net>
6749
6750         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
6751         file.
6752
6753         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
6754
6755 2006-09-15  Jim Meyering  <jim@meyering.net>
6756
6757         * lib/rename-dest-slash.c (has_trailing_slash): Use
6758         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
6759         (rpl_rename_dest_slash): Perform the cheaper trailing slash
6760         test before testing whether SRC is a directory.
6761         Suggestions from Bruno Haible.
6762
6763         Avoid a warning about an unused variable.
6764         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
6765         into the #ifdef block where it's used.
6766
6767         * lib/rename-dest-slash.c: New file.
6768
6769 2006-09-14  Bruno Haible  <bruno@clisp.org>
6770
6771         * lib/allocsa.c: Include <config.h> unconditionally.
6772         * lib/asnprintf.c: Likewise.
6773         * lib/asprintf.c: Likewise.
6774         * lib/c-strcasecmp.c: Likewise.
6775         * lib/c-strcasestr.c: Likewise.
6776         * lib/c-strncasecmp.c: Likewise.
6777         * lib/c-strstr.c: Likewise.
6778         * lib/classpath.c: Likewise.
6779         * lib/clean-temp.c: Likewise.
6780         * lib/concatpath.c: Likewise.
6781         * lib/copy-file.c: Likewise.
6782         * lib/csharpcomp.c: Likewise.
6783         * lib/csharpexec.c: Likewise.
6784         * lib/execute.c: Likewise.
6785         * lib/fatal-signal.c: Likewise.
6786         * lib/findprog.c: Likewise.
6787         * lib/fwriteerror.c: Likewise.
6788         * lib/gl_array_list.c: Likewise.
6789         * lib/gl_array_oset.c: Likewise.
6790         * lib/gl_avltree_list.c: Likewise.
6791         * lib/gl_avltree_oset.c: Likewise.
6792         * lib/gl_avltreehash_list.c: Likewise.
6793         * lib/gl_carray_list.c: Likewise.
6794         * lib/gl_linked_list.c: Likewise.
6795         * lib/gl_linkedhash_list.c: Likewise.
6796         * lib/gl_list.c: Likewise.
6797         * lib/gl_oset.c: Likewise.
6798         * lib/gl_rbtree_list.c: Likewise.
6799         * lib/gl_rbtree_oset.c: Likewise.
6800         * lib/gl_rbtreehash_list.c: Likewise.
6801         * lib/imaxabs.c: Likewise.
6802         * lib/imaxdiv.c: Likewise.
6803         * lib/javacomp.c: Likewise.
6804         * lib/javaexec.c: Likewise.
6805         * lib/javaversion.c: Likewise.
6806         * lib/linebreak.c: Likewise.
6807         * lib/localcharset.c: Likewise.
6808         * lib/lock.c: Likewise.
6809         * lib/mbchar.c: Likewise.
6810         * lib/mbswidth.c: Likewise.
6811         * lib/mkdtemp.c: Likewise.
6812         * lib/pipe.c: Likewise.
6813         * lib/printf-args.c: Likewise.
6814         * lib/printf-parse.c: Likewise.
6815         * lib/progname.c: Likewise.
6816         * lib/progreloc.c: Likewise.
6817         * lib/readlink.c: Likewise.
6818         * lib/sh-quote.c: Likewise.
6819         * lib/stpcpy.c: Likewise.
6820         * lib/stpncpy.c: Likewise.
6821         * lib/strcasecmp.c: Likewise.
6822         * lib/strcasestr.c: Likewise.
6823         * lib/strcspn.c: Likewise.
6824         * lib/striconv.c: Likewise.
6825         * lib/strncasecmp.c: Likewise.
6826         * lib/strnlen1.c: Likewise.
6827         * lib/strstr.c: Likewise.
6828         * lib/strtok_r.c: Likewise.
6829         * lib/tls.c: Likewise.
6830         * lib/tmpdir.c: Likewise.
6831         * lib/unicodeio.c: Likewise.
6832         * lib/unsetenv.c: Likewise.
6833         * lib/vasnprintf.c: Likewise.
6834         * lib/vasprintf.c: Likewise.
6835         * lib/wait-process.c: Likewise.
6836         * lib/xallocsa.c: Likewise.
6837         * lib/xsetenv.c: Likewise.
6838         * lib/xstriconv.c: Likewise.
6839
6840 2006-09-13  Simon Josefsson  <jas@extundo.com>
6841
6842         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
6843         that internally, suggested by Ralf Wildenhues
6844         <Ralf.Wildenhues@gmx.de>.
6845
6846 2006-09-13  Simon Josefsson  <jas@extundo.com>
6847
6848         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
6849         @LIBOBJS@.
6850         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6851
6852 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
6853
6854         * lib/_fpending.c: Include <config.h> unconditionally, since we no
6855         longer worry about uses that don't define HAVE_CONFIG_H.
6856         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
6857         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
6858         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
6859         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
6860         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
6861         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
6862         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
6863         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
6864         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
6865         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
6866         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
6867         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
6868         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
6869         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
6870         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
6871         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
6872         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
6873         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
6874         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
6875         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
6876         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
6877         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
6878         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
6879         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
6880         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
6881         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
6882         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
6883         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
6884         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
6885         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
6886         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
6887         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
6888         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
6889         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
6890         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
6891         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
6892         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
6893         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
6894         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
6895         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
6896         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
6897         Likewise.
6898
6899 2006-09-13  Eric Blake  <ebb9@byu.net>
6900
6901         * lib/getopt.c: Fix typo in last commit.
6902
6903 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
6904
6905         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
6906         dgettext.
6907
6908 2006-09-12  Jim Meyering  <jim@meyering.net>
6909
6910         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
6911         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
6912         Reported by Nelson H. F. Beebe.
6913
6914 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
6915
6916         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
6917         program_invocation_name and program_invocation_short_name are
6918         initialized.
6919         * lib/argp-namefrob.h: Move declarations of program_invocation_name
6920         and program_invocation_short_name to argp.h, so they are visible
6921         to user programs.
6922         * lib/argp.h: Likewise
6923
6924 2006-09-10  Bruno Haible  <bruno@clisp.org>
6925
6926         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
6927         m4/inttypes_h.m4, m4/uintmax_t.m4.
6928
6929 2006-09-10  Bruno Haible  <bruno@clisp.org>
6930
6931         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
6932         gl_AC_TYPE_UINTMAX_T.
6933
6934 2006-09-10  Bruno Haible  <bruno@clisp.org>
6935
6936         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
6937
6938 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
6939
6940         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
6941         convention.  Text proposed by Bruno Haible.
6942         (struct argp_option): Document the use of N_() wrappers.
6943
6944         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
6945         '\v', and translate the two parts separately, instead of feeding
6946         the whole string to gettext.  This allows to exclude
6947         '\v' from the strings visible to the translator by writing doc
6948         strings as N_("..") "\v" N_("..").
6949
6950 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
6951
6952         * config/srclist.txt: Undo latest change; the bug was fixed.
6953
6954 2006-09-09  Bruno Haible  <bruno@clisp.org>
6955
6956         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
6957         assignments if building a library without libtool.
6958         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
6959         in func_emit_lib_Makefile_am.
6960         (func_import): When building a static library libfoo.a, arrange to
6961         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
6962         (func_create_testdir): Likewise.
6963         * modules/gc (configure.ac, Makefile.am): If building statically,
6964         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
6965         * modules/iconvme (configure.ac, Makefile.am): Likewise.
6966         * modules/striconv (configure.ac, Makefile.am): Likewise.
6967         Based on a suggestion by Ralf Wildenhues.
6968
6969 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
6970
6971         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
6972         Check for unistd.h too, since Autoconf doesn't assume POSIX.
6973         Also:
6974
6975         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
6976         Add year_2050_test to catch glibc bug 2821
6977         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
6978
6979         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
6980         Prefer #ifdef to #if.
6981
6982         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
6983         Return from 'main' instead of calling 'exit'.
6984
6985 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
6986
6987         * lib/mktime.c (guess_time_tm): Fix bug where mktime
6988         returned the maximum time_t value rather than (time_t) -1.
6989         Problem originally reported by William Bardwell
6990         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
6991
6992         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
6993         Moved to here ...
6994         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
6995         ... from here.
6996
6997 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
6998
6999         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
7000         2821 is fixed.
7001
7002 2006-09-08  Jim Meyering  <jim@meyering.net>
7003
7004         Don't make generated files read-only.  That would bother too many
7005         people.  However, do retain the ability to work when targets are
7006         read-only: remove the destination and temporary files before writing
7007         them (when generated via sed or echo), or by using the -f option for
7008         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
7009         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7010         * modules/byteswap, modules/configmake, modules/fcntl:
7011         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7012         * modules/localcharset, modules/netinet_in, modules/poll:
7013         * modules/stdbool, modules/stdint, modules/sys_select:
7014         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7015
7016 2006-09-08  Jim Meyering  <jim@meyering.net>
7017
7018         Avoid new build failure on FreeBSD 6.0.
7019         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
7020         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
7021         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
7022
7023 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7024
7025         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
7026
7027 2006-09-07  Jim Meyering  <jim@meyering.net>
7028
7029         Fix global typo in last change: use chmod u-w, not chmod u-x.
7030         Spotted by Paul Eggert and Bruce Korb.
7031         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7032         * modules/byteswap, modules/configmake, modules/fcntl:
7033         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7034         * modules/localcharset, modules/netinet_in, modules/poll:
7035         * modules/stdbool, modules/stdint, modules/sys_select:
7036         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7037
7038 2006-09-06  Jim Meyering  <jim@meyering.net>
7039
7040         Make generated files be read-only.
7041         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
7042         Ensure that each generated file is now read-only.
7043         * modules/argz: Likewise.
7044         * modules/arpa_inet: Likewise.
7045         * modules/byteswap: Likewise.
7046         * modules/configmake: Likewise.
7047         * modules/fcntl: Likewise.
7048         * modules/fnmatch: Likewise.
7049         * modules/getopt: Likewise.
7050         * modules/glob: Likewise.
7051         * modules/inttypes: Likewise.
7052         * modules/netinet_in: Likewise.
7053         * modules/poll: Likewise.
7054         * modules/stdbool: Likewise.
7055         * modules/stdint: Likewise.
7056         * modules/sys_select: Likewise.
7057         * modules/sys_socket: Likewise.
7058         * modules/sys_stat: Likewise.
7059         * modules/sysexits: Likewise.
7060         * modules/localcharset: Same as above, but continue using temporary
7061         file named "t-$@" (why different?) rather than the "$@-t" used
7062         everywhere else.
7063
7064         * modules/sysexits (Makefile.am): Replace literal occurrences
7065         of "sysexit.h" more readable, and more consistent, "$@".
7066
7067 2006-09-06  Bruno Haible  <bruno@clisp.org>
7068
7069         * modules/striconv: New file.
7070         * modules/xstriconv: New file.
7071         * MODULES.html.sh (Internationalization functions): Add striconv,
7072         xstriconv.
7073
7074 2006-09-06  Bruno Haible  <bruno@clisp.org>
7075
7076         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
7077         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
7078         not using libtool correctly.
7079
7080 2006-09-06  Bruno Haible  <bruno@clisp.org>
7081
7082         * lib/striconv.h: New file.
7083         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
7084         iconvstring.c.
7085         * lib/xstriconv.h: New file.
7086         * lib/xstriconv.c: New file.
7087
7088 2006-09-06  Bruno Haible  <bruno@clisp.org>
7089
7090         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7091         lib_..._LDFLAGS.
7092
7093 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7094
7095         * lib/argz_.h: Sync from Libtool.
7096
7097         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
7098                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
7099
7100         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
7101
7102 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7103
7104         * modules/trim: New file.
7105
7106 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7107
7108         * lib/trim.h: New file.
7109         * lib/trim.c: New file.
7110
7111 2006-09-05  Bruno Haible  <bruno@clisp.org>
7112
7113         * MODULES.html.sh (String handling): Add trim.
7114
7115 2006-09-04  Karl Berry  <karl@gnu.org>
7116
7117         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
7118         until next release.
7119
7120 2006-09-03  Bruno Haible  <bruno@clisp.org>
7121
7122         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
7123         correctly.
7124
7125 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7126
7127         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
7128         not gl_GETLOADAVG.  Omit unneeded semicolons.
7129         Problems reported by Ralf Wildenhues in
7130         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7131         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
7132         at the end, which is the usual gnulib style.
7133
7134         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
7135         of doing all the work ourselves.
7136         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
7137         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
7138
7139 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7140
7141         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
7142         Problem reported by Ralf Wildenhues in
7143         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7144
7145         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
7146         HAVE_STRUCT_STATFS_F_FSTYPENAME.
7147
7148 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7149
7150         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
7151         yesterday's patch by changing test -n to test -z.
7152
7153 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7154
7155         * modules/getloadavg (Files): Add m4/getloadavg.m4.
7156         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
7157         the former is now obsolescent.
7158
7159         * modules/chdir-long (Depends-on): Add fcntl.
7160
7161 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7162
7163         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
7164         obsolescent, and programs should use gnulib instead.
7165         * m4/getloadavg.m4: New file, with contents taken from Autoconf
7166         but with prefixes changed.
7167
7168 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7169
7170         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
7171         or stdbool.h, because they might not exist while configuring.
7172
7173         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
7174         Don't include unistd.h or limits.h; not needed, since chdir-long.h
7175         does that for us.
7176         (O_DIRECTORY): Remove.
7177
7178 2006-08-31  Eric Blake  <ebb9@byu.net>
7179
7180         * gnulib-tool: Don't let emacs change spaces to TAB.
7181
7182 2006-08-31  Bruno Haible  <bruno@clisp.org>
7183
7184         * gnulib-tool: When calling func_import more than once, do it in a
7185         subshell.
7186         Reported by Eric Blake <ebb9@byu.net>.
7187
7188 2006-08-31  Bruno Haible  <bruno@clisp.org>
7189
7190         * gnulib-tool (nl): Remove variable.
7191         (sed_transform_lib_file): Use more robust test for config-h module.
7192         (func_import): Fix typo in 2006-08-25 patch.
7193
7194 2006-08-31  Bruno Haible  <bruno@clisp.org>
7195
7196         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
7197         specified, augment Makefile.am variables instead of assigning them.
7198
7199 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7200
7201         Work around a bug in both the Linux and SunOS 64-bit kernels:
7202         nanosleep mishandles sleeps for longer than 2**31 seconds.
7203         Problem reported by Frank v Waveren in
7204         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7205         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
7206         Check for nanosleep bug.
7207         (LIB_NANOSLEEP): Append clock_gettime library if needed.
7208
7209 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7210
7211         Work around a bug in both the Linux and SunOS 64-bit kernels:
7212         nanosleep mishandles sleeps for longer than 2**31 seconds.
7213         Problem reported by Frank v Waveren in
7214         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7215         * lib/nanosleep.c (BILLION): New constant.
7216         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
7217         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
7218         implementation.
7219
7220 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7221
7222         * modules/nanosleep (Depends-on): Add gettime.
7223
7224 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7225         and Simon Josefsson  <jas@extundo.com>
7226         and Oskar Liljeblad  <oskar@osk.mine.nu>
7227
7228         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
7229         * gnulib-tool (func_import): New license type 'unmodifiable license
7230         text'.
7231         * modules/fdl: Use it.  Longer description.
7232         * module/gpl, module/lgpl: New files.
7233
7234 2006-08-30  Jim Meyering  <jim@meyering.net>
7235
7236         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
7237         shadowing the parameter.
7238
7239 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7240
7241         Sync from Libtool:
7242
7243         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7244
7245         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
7246         sharing with gnulib.  Report by Eric Blake.
7247
7248 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7249
7250         * modules/isapipe: New file.
7251         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
7252
7253 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7254
7255         * modules/configmake (Makefile.am): Add a comment, and omit
7256         the CONFIGMAKE_ prefix from generated macro names.  Suggested
7257         by Bruno Haible.
7258
7259 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7260
7261         * m4/isapipe.m4: New file.
7262
7263 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7264
7265         * lib/isapipe.c, lib/isapipe.h: New files.
7266
7267 2006-08-29  Jim Meyering  <jim@meyering.net>
7268
7269         * modules/configmake (Makefile.am): Make configmake.h depend on
7270         Makefile.  Otherwise, a stale configmake.h could hang around.
7271
7272 2006-08-29  Eric Blake  <ebb9@byu.net>
7273
7274         * lib/error.c (error_at_line, print_errno_message): Match libc, after
7275         resolution of upstream bug 3044.
7276
7277 2006-08-29  Bruno Haible  <bruno@clisp.org>
7278
7279         * modules/localcharset (Depends-on): Add configmake.
7280         (Makefile.am): Remove setting of LIBDIR through DEFS.
7281
7282 2006-08-29  Bruno Haible  <bruno@clisp.org>
7283
7284         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
7285         defined.
7286
7287 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7288
7289         * modules/fcntl: New file.
7290         * modules/chdir-safer (Depends-on): Add fcntl.
7291         * modules/fts: Likewise.
7292         * modules/mkdir-p: Likewise.
7293
7294         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
7295         This undoes the most recent change, since we're now addressing the
7296         problem in a different way.
7297
7298         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
7299         into output, since the output might be called Makefile.am even
7300         if $makefile_name is something different.
7301         (func_import): Use $makefile_am rather than
7302         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
7303         empty.
7304
7305         * modules/inttypes (Files): Add m4/inttypes-h.m4.
7306
7307 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7308
7309         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
7310         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
7311         recent change to stdint.m4, since we're now addressing the problem in a
7312         different way.
7313
7314 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7315
7316         * m4/fcntl_h.m4: New file.
7317
7318 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7319
7320         * lib/fcntl_.h: New file.
7321         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
7322         the fcntl module.
7323         * lib/dirchownmod.c: Likewise.
7324         * lib/fts.c: Likewise.
7325
7326         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
7327         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
7328         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
7329         just before including <inttypes.h>, to avoid circular inclusion.
7330
7331 2006-08-28  Jim Meyering  <jim@meyering.net>
7332
7333         * doc/visibility.texi: Actually read and correct the grammar of the
7334         sentence affected by yesterday's change.
7335
7336 2006-08-28  Eric Blake  <ebb9@byu.net>
7337
7338         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
7339         needs wrapper.
7340
7341 2006-08-28  Eric Blake  <ebb9@byu.net>
7342
7343         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
7344
7345 2006-08-28  Eric Blake  <ebb9@byu.net>
7346
7347         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
7348
7349 2006-08-28  Bruno Haible  <bruno@clisp.org>
7350
7351         * modules/c-strstr: New file, from GNU gettext.
7352         * MODULES.html.sh (String handling): Add c-strstr.
7353
7354 2006-08-28  Bruno Haible  <bruno@clisp.org>
7355
7356         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
7357         macros.
7358         Reported by Eric Blake.
7359
7360 2006-08-28  Bruno Haible  <bruno@clisp.org>
7361
7362         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
7363         (VASNPRINTF): Return a string of length > INT_MAX without failing.
7364         * lib/vasprintf.c: Include errno.h, limits.h.
7365         (EOVERFLOW): New fallback definition.
7366         (vasprintf): Test here whether the string length is > INT_MAX.
7367         * lib/vsnprintf.c: Include errno.h, limits.h.
7368         (EOVERFLOW): New fallback definition.
7369         (vsnprintf): Fix bug when generated string was too long for the buffer.
7370         Test here whether the string length is > INT_MAX.
7371
7372 2006-08-28  Bruno Haible  <bruno@clisp.org>
7373
7374         * lib/inttypes_.h (SCNX*): Remove definitions.
7375         Reported by Eric Blake.
7376
7377 2006-08-28  Bruno Haible  <bruno@clisp.org>
7378
7379         * lib/c-strstr.h: New file, from GNU gettext.
7380         * lib/c-strstr.c: New file, from GNU gettext.
7381
7382 2006-08-28  Bruno Haible  <bruno@clisp.org>
7383
7384         * gnulib-tool: Reorder some statements.
7385
7386 2006-08-28  Bruno Haible  <bruno@clisp.org>
7387
7388         * gnulib-tool: New option --makefile-name.
7389         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
7390         $makefile_name.
7391         (func_import): Write $makefile_name to the cache file, and read it from
7392         there unless explicitly specified. Use $makefile_name as file name
7393         instead of Makefile.am. Adjust the recommendations accordingly.
7394
7395 2006-08-28  Bruno Haible  <bruno@clisp.org>
7396
7397         * gnulib-tool (func_verify_module): Check against misapplying patch.
7398
7399 2006-08-28  Bruno Haible  <bruno@clisp.org>
7400
7401         * gnulib-tool (func_relativize, func_relconcat): New functions.
7402         Give an error if --local-dir is given with --update.
7403         Remove trailing slashes from $local_gnulib_dir.
7404         (func_import): Store the relativized $local_gnulib_dir in
7405         gnulib-cache.m4, and read it from there if not specified explicitly.
7406
7407 2006-08-28  Bruno Haible  <bruno@clisp.org>
7408
7409         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
7410         is the current directory. Respect also $local_gnulib_dir.
7411
7412 2006-08-28  Bruno Haible  <bruno@clisp.org>
7413             Simon Josefsson  <jas@extundo.com>
7414
7415         BeOS portability.
7416         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
7417
7418 2006-08-27  Jim Meyering  <jim@meyering.net>
7419
7420         * doc/visibility.texi: Remove duplicate word: "pointer".
7421
7422 2006-08-26  Bruno Haible  <bruno@clisp.org>
7423
7424         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
7425         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
7426         (Makefile.am): Create inttypes.h from inttypes_.h.
7427         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
7428
7429         * modules/imaxabs: New file.
7430
7431         * modules/imaxdiv: New file.
7432
7433 2006-08-26  Bruno Haible  <bruno@clisp.org>
7434
7435         * m4/inttypes.m4: New file.
7436         * m4/_inttypes_h.m4: Remove file.
7437         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
7438         PRI_MACROS_BROKEN.
7439         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
7440
7441         * m4/imaxabs.m4: New file.
7442
7443         * m4/imaxdiv.m4: New file.
7444
7445 2006-08-26  Bruno Haible  <bruno@clisp.org>
7446
7447         * lib/inttypes_.h: New file.
7448         * lib/inttypes.h: Remove file.
7449         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
7450
7451         * lib/imaxabs.c: New file.
7452
7453         * lib/imaxdiv.c: New file.
7454
7455 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
7456
7457         New config-h module, so that "make" output needn't be cluttered
7458         by -DHAVE_CONFIG_H.
7459         * MODULES.html.sh (Support for building libraries and executables):
7460         Add config-h.
7461         * modules/config-h: New file.
7462         * gnulib-tool (nl, sed_transform_lib_file): New vars.
7463         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
7464         the config-h module is used.
7465
7466         New configmake module, so that "make" output needn't be cluttered
7467         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
7468         * MODULES.html.sh (Support for building libraries and executables):
7469         Add configmake.
7470         * modules/configmake: New file.
7471
7472 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
7473
7474         * m4/config-h.m4: New file.
7475
7476 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
7477
7478         * config/srclist.txt: Add elisp-comp.
7479
7480 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
7481
7482         * MODULES.html.sh (Support for building libraries and executables):
7483         Add elisp-comp.
7484         * build-aux/elisp-comp: New file.
7485         * modules/elisp-comp: New file.
7486
7487 2006-08-24  Bruno Haible  <bruno@clisp.org>
7488
7489         * gnulib-tool (func_create_testdir): Use non-default values of
7490         sourcebase and m4base.
7491
7492 2006-08-24  Bruno Haible  <bruno@clisp.org>
7493
7494         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
7495         HTML structure.
7496
7497 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
7498
7499         * modules/openat (Depends-on): Add lchown.
7500
7501 2006-08-23  Bruno Haible  <bruno@clisp.org>
7502
7503         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
7504         of gl_LOCK_EARLY instead of gl_LOCK.
7505
7506 2006-08-23  Bruno Haible  <bruno@clisp.org>
7507
7508         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
7509         on OSF/1 to no.
7510         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
7511
7512 2006-08-23  Bruno Haible  <bruno@clisp.org>
7513
7514         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
7515         as unusable.
7516
7517         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
7518         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
7519         (gl_LOCK): New macro.
7520
7521 2006-08-22  Simon Josefsson  <jas@extundo.com>
7522
7523         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
7524         to md5 module.
7525
7526 2006-08-22  Simon Josefsson  <jas@extundo.com>
7527
7528         * MODULES.html.sh: Add "Support for maintaining and release
7529         projects".
7530
7531         * build-aux/gnupload: New file, from coreutils.
7532
7533 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
7534
7535         Avoid the need for AC_LIBSOURCES in m4 macros.
7536         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
7537         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
7538         * modules/check-version (EXTRA_DIST): Add check-version.h.
7539         * modules/crc (EXTRA_DIST): Add crc.h.
7540         * modules/des (EXTRA_DIST): Add des.h.
7541         * modules/gc (EXTRA_DIST): Add gc.h.
7542         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
7543         * modules/getline (EXTRA_DIST): Add getline.h.
7544         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
7545         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
7546         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
7547         * modules/md2 (EXTRA_DIST): Add md2.h.
7548         * modules/md4 (EXTRA_DIST): Add md4.h.
7549         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
7550         * modules/read-file (EXTRA_DIST): Add read-file.h.
7551         * modules/readline (EXTRA_DIST): Add readline.h.
7552         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
7553         rijndael-api-fst.h.
7554
7555 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
7556
7557         * m4/rijndael.m4 (gl_ARCFOUR):
7558         * m4/arctwo.m4 (gl_ARCTWO):
7559         * m4/check-version.m4 (gl_CHECK_VERSION):
7560         * m4/crc.m4 (gl_CRC):
7561         * m4/des.m4 (gl_DES):
7562         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
7563         * m4/gc.m4 (gl_GC):
7564         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
7565         * m4/getline.m4 (gl_FUNC_GETLINE):
7566         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
7567         * m4/hmac-md5.m4 (gl_HMAC_MD5):
7568         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
7569         * m4/md2.m4 (gl_MD2):
7570         * m4/md4.m4 (gl_MD4):
7571         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
7572         * m4/read-file.m4 (gl_FUNC_READ_FILE):
7573         * m4/readline.m4 (gl_FUNC_READLINE):
7574         * m4/rijndael.m4 (gl_RIJNDAEL):
7575         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
7576         to get the necessary .h files and whatnot.
7577
7578 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
7579
7580         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
7581         gnulib rather than the other way around.
7582         * config/srclistvars.sh (COREUTILS): Remove.
7583
7584 2006-08-22  Jim Meyering  <jim@meyering.net>
7585
7586         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
7587
7588         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
7589
7590 2006-08-22  Eric Blake  <ebb9@byu.net>
7591
7592         * modules/regexprops-generic: New file.
7593         * MODULES.html.sh (Support for building documentation): List it.
7594
7595 2006-08-22  Eric Blake  <ebb9@byu.net>
7596
7597         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
7598         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
7599         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
7600         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
7601
7602 2006-08-22  Bruno Haible  <bruno@clisp.org>
7603
7604         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
7605         and lib_LTLIBRARIES like the other lib_* variables.
7606
7607 2006-08-22  Bruno Haible  <bruno@clisp.org>
7608
7609         * build-aux/x-to-1.in: New file, from GNU gettext.
7610
7611 2006-08-22  Bruno Haible  <bruno@clisp.org>
7612
7613         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
7614         <utmpx.h> exists.
7615
7616 2006-08-22  Bruno Haible  <bruno@clisp.org>
7617
7618         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
7619         <utmpx.h> exists.
7620
7621 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
7622
7623         BeOS portability.
7624         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
7625         exist.
7626         Problem reported by Bruno Haible.
7627
7628 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
7629
7630         Avoid the need for AC_LIBSOURCES in m4 macros.
7631         * modules/acl (EXTRA_DIST): Add acl.h.
7632         * modules/argmatch (Files): Add m4/argmatch.m4.
7633         (configure.ac): Add gl_ARGMATCH.
7634         (EXTRA_DIST): Renamed from lib_SOURCES, for
7635         consistency with the other modules.  Remove argmatch.c.
7636         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
7637         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
7638         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
7639         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
7640         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
7641         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
7642         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
7643         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
7644         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
7645         * modules/closeout (EXTRA_DIST): Add closeout.h.
7646         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
7647         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
7648         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
7649         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
7650         dirname.h; remove basename.c and stripslash.c.
7651         * modules/exclude (EXTRA_DIST): Add exclude.h.
7652         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
7653         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
7654         * modules/file-type (EXTRA_DIST): Add file-type.h.
7655         * modules/filemode (EXTRA_DIST): Add filemode.h.
7656         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
7657         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
7658         * modules/fpending (EXTRA_DIST): Add __fpending.h.
7659         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
7660         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
7661         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
7662         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
7663         * modules/getdate (EXTRA_DIST): Add getdate.c.
7664         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
7665         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
7666         * modules/getpass (EXTRA_DIST): Add getpass.h.
7667         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
7668         * modules/group-member (EXTRA_DIST): Add group-member.h.
7669         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
7670         * modules/hash (EXTRA_DIST): Add hash.h.
7671         * modules/human (EXTRA_DIST): Add human.h.
7672         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
7673         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
7674         * modules/lchown (EXTRA_DIST): Add lchown.h.
7675         * modules/long-options (EXTRA_DIST): Add long-options.h.
7676         * modules/lstat (EXTRA_DIST): Add lstat.h.
7677         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
7678         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
7679         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
7680         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
7681         * modules/memxor (EXTRA_DIST): Add memxor.h.
7682         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
7683         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
7684         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
7685         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
7686         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
7687         * modules/physmem (EXTRA_DIST): Add physmem.h.
7688         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
7689         * modules/posixver (EXTRA_DIST): Add posixver.h.
7690         * modules/quote (EXTRA_DIST): Add quote.h.
7691         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
7692         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
7693         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
7694         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
7695         regex_internal.h regexec.c.
7696         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
7697         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
7698         * modules/same (EXTRA_DIST): Add same.h.
7699         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
7700         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
7701         * modules/savedir (EXTRA_DIST): Add savedir.h.
7702         * modules/sha1 (EXTRA_DIST): Add sha1.h.
7703         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
7704         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
7705         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
7706         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
7707         * modules/strdup (EXTRA_DIST): Add strdup.h.
7708         * modules/strftime (EXTRA_DIST): Add strftime.h.
7709         * modules/strndup (EXTRA_DIST): Add strndup.h.
7710         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
7711         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
7712         * modules/time_r (EXTRA_DIST): Add time_r.h.
7713         * modules/timespec (EXTRA_DIST): Add timespec.h.
7714         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
7715         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
7716         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
7717         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
7718         * modules/userspec (EXTRA_DIST): Add userspec.h.
7719         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
7720         * modules/utimens (EXTRA_DIST): Add utimens.h.
7721         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
7722         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
7723         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
7724         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
7725         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
7726         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
7727         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
7728         * modules/yesno (EXTRA_DIST): Add yesno.h.
7729
7730 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
7731
7732         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
7733
7734         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
7735         * m4/dev-ino.m4, same-inode.m4: Remove.
7736
7737         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
7738         * m4/acl.m4 (AC_FUNC_ACL):
7739         * m4/backupfile.m4 (gl_BACKUPFILE):
7740         * m4/c-strtod.m4 (gl_C99_STRTOLD):
7741         * m4/canon-host.m4 (gl_CANON_HOST):
7742         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
7743         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
7744         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
7745         * m4/cloexec.m4 (gl_CLOEXEC):
7746         * m4/close-stream.m4 (gl_CLOSE_STREAM):
7747         * m4/closeout.m4 (gl_CLOSEOUT):
7748         * m4/dirfd.m4 (gl_FUNC_DIRFD):
7749         * m4/dirname.m4 (gl_DIRNAME):
7750         * m4/exclude.m4 (gl_EXCLUDE):
7751         * m4/exitfail.m4 (gl_EXITFAIL):
7752         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
7753         * m4/file-type.m4 (gl_FILE_TYPE):
7754         * m4/filemode.m4 (gl_FILEMODE):
7755         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
7756         * m4/fpending.m4 (gl_FUNC_FPENDING):
7757         * m4/fprintftime.m4 (gl_FPRINTFTIME):
7758         * m4/fts.m4 (gl_FUNC_FTS):
7759         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
7760         * m4/getdate.m4 (gl_GETDATE):
7761         * m4/gethrxtime.m4 (gl_GETHRXTIME):
7762         * m4/getpagesize.m4 (gl_GETPAGESIZE):
7763         * m4/getpass.m4 (gl_FUNC_GETPASS):
7764         * m4/gettime.m4 (gl_GETTIME):
7765         * m4/getugroups.m4 (gl_GETUGROUPS):
7766         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
7767         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
7768         * m4/hard-locale.m4 (gl_HARD_LOCALE):
7769         * m4/hash.m4 (gl_HASH):
7770         * m4/idcache.m4 (gl_IDCACHE):
7771         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
7772         * m4/lchown.m4 (gl_FUNC_LCHOWN):
7773         * m4/long-options.m4 (gl_LONG_OPTIONS):
7774         * m4/lstat.m4 (gl_FUNC_LSTAT):
7775         * m4/md5.m4 (gl_MD5):
7776         * m4/memcasecmp.m4 (gl_MEMCASECMP):
7777         * m4/memcoll.m4 (gl_MEMCOLL):
7778         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
7779         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
7780         * m4/memxor.m4 (gl_MEMXOR):
7781         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
7782         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
7783         * m4/modechange.m4 (gl_MODECHANGE):
7784         * m4/mountlist.m4 (gl_MOUNTLIST):
7785         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
7786         * m4/openat.m4 (gl_FUNC_OPENAT):
7787         * m4/pathmax.m4 (gl_PATHMAX):
7788         * m4/physmem.m4 (gl_PHYSMEM):
7789         * m4/posixtm.m4 (gl_POSIXTM):
7790         * m4/posixver.m4 (gl_POSIXVER):
7791         * m4/quote.m4 (gl_QUOTE):
7792         * m4/quotearg.m4 (gl_QUOTEARG):
7793         * m4/readtokens.m4 (gl_READTOKENS):
7794         * m4/readutmp.m4 (gl_READUTMP):
7795         * m4/regex.m4 (gl_REGEX):
7796         * m4/safe-read.m4 (gl_SAFE_READ):
7797         * m4/safe-write.m4 (gl_SAFE_WRITE):
7798         * m4/same.m4 (gl_SAME):
7799         * m4/save-cwd.m4 (gl_SAVE_CWD):
7800         * m4/savedir.m4 (gl_SAVEDIR):
7801         * m4/settime.m4 (gl_SETTIME):
7802         * m4/sha1.m4 (gl_SHA1):
7803         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
7804         * m4/stat-macros.m4 (gl_STAT_MACROS):
7805         * m4/stat-time.m4 (gl_STAT_TIME):
7806         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
7807         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
7808         * m4/strdup.m4 (gl_FUNC_STRDUP):
7809         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
7810         * m4/strndup.m4 (gl_FUNC_STRNDUP):
7811         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
7812         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
7813         * m4/time_r.m4 (gl_TIME_R):
7814         * m4/timespec.m4 (gl_TIMESPEC):
7815         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
7816         * m4/unlinkdir.m4 (gl_UNLINKDIR):
7817         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
7818         * m4/userspec.m4 (gl_USERSPEC):
7819         * m4/utimecmp.m4 (gl_UTIMECMP):
7820         * m4/utimens.m4 (gl_UTIMENS):
7821         * m4/xalloc.m4 (gl_XALLOC):
7822         * m4/xgetcwd.m4 (gl_XGETCWD):
7823         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
7824         * m4/xreadlink.m4 (gl_XREADLINK):
7825         * m4/xstrtod.m4 (gl_XSTRTOD):
7826         * m4/yesno.m4 (gl_YESNO):
7827         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
7828         to get the necessary .h files and whatnot.
7829
7830 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
7831             Bruno Haible  <bruno@clisp.org>
7832
7833         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
7834         /bin/sh understanding of '!' conditional negation.
7835
7836 2006-08-21  Jim Meyering  <jim@meyering.net>
7837
7838         * modules/openat (Depends-on): Really alphabetize.
7839
7840         * modules/acl (Depends-on): Add error and quote.
7841
7842         * check-module (find_included_lib_files): Add at-func.c to the
7843         ok-to-include-more-than-once white list.
7844
7845         * modules/openat (Depends-on): Add lstat.  Alphabetize.
7846
7847 2006-08-21  Bruno Haible  <bruno@clisp.org>
7848
7849         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7850         Emit a pkgdata_DATA variable only if some snippets add contents to it.
7851         Reported by Martin Lambers <marlam@marlam.de>.
7852
7853 2006-08-21  Bruno Haible  <bruno@clisp.org>
7854
7855         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
7856         specify an installation location, don't emit a noinst_LIBRARIES or
7857         noinst_LTLIBRARIES assignment.
7858
7859 2006-08-21  Bruno Haible  <bruno@clisp.org>
7860
7861         BeOS portability.
7862         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
7863         BeOS has mbrtowc() but no <wctype.h>.
7864
7865 2006-08-21  Bruno Haible  <bruno@clisp.org>
7866
7867         BeOS portability.
7868         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
7869         exist.
7870
7871 2006-08-21  Bruno Haible  <bruno@clisp.org>
7872
7873         BeOS portability.
7874         * lib/mbchar.h: Include <wctype.h> only if it exists.
7875
7876 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
7877
7878         Remove files that are no longer needed by their respective modules.
7879         * m4/obstack.m4: Remove.
7880         * m4/strerror_r.m4: Remove.
7881         * m4/uint32_t.m4: Remove.
7882         * m4/uintptr_t.m4: Remove.
7883         * m4/ullong_max.m4: Remove.
7884         * m4/xstrtoimax.m4: Remove.
7885         * m4/xstrtoumax.m4: Remove.
7886
7887         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
7888         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
7889         dependencies now capture this.
7890
7891         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
7892         Do not use AC_LIBSOURCES, since gnulib modules now do this.
7893         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
7894         * m4/human.m4 (gl_HUMAN): Likewise.
7895         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
7896         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
7897
7898         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
7899
7900         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
7901         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
7902         stdint.
7903         * m4/human.m4 (gl_HUMAN): Likewise.
7904         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
7905         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
7906         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
7907         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
7908         * m4/xstrtol (gl_XSTRTOL): Likewise.
7909
7910         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
7911         AC_TYPE_LONG_LONG_INT.
7912         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
7913         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
7914         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
7915         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
7916
7917         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
7918         on stdbool.
7919
7920         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
7921         (gl_PREREQ_XSTRTOUL): Remove.
7922
7923         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
7924
7925         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
7926         mode.
7927
7928 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
7929
7930         Add and change modules to make it easier for coreutils to use
7931         gnulib-tool.
7932         * modules/backupfile (Files): Remove m4/d-ino.m4.
7933         (Depends-on): Add d-ino.
7934         * modules/cycle-check (Depends-on): Add stdint.
7935         (lib_SOURCES): Add cycle-check.h.
7936         * modules/d-ino: New module.
7937         * modules/d-type: New module.
7938         * modules/error (Files): Remove m4/strerror_r.m4.
7939         * modules/filemode (Files): Add m4/st_dm_mode.m4.
7940         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
7941         m4/inttypes_h.m4, m4/uintmax_t.m4.
7942         (Depends-on): Add stdint.
7943         (lib_SOURCES): Add fsusage.h.
7944         * modules/getcwd (Files): Remove d-ino.m4.
7945         (Depends-on): Add d-ino.
7946         * modules/getndelim2 (Depends-on): Add stdint.
7947         * modules/glob (Files): Remove m4/d-type.m4.
7948         (Depends-on): Add d-type.
7949         * modules/host-os: New module.
7950         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
7951         m4/inttypes_h.m4, m4/uintmax_t.m4.
7952         * Depends-on: Add stdint.
7953         (lib_SOURCES): Add human.h.
7954         * modules/inttostr (Files): Remove m4/intmax_t.m4,
7955         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
7956         m4/uintmax_t.m4, m4/ulonglong.m4.
7957         (Depends-on): Add stdint.
7958         (EXTRA_DIST): Add inttostr.h.
7959         * modules/lchmod: New module.
7960         * modules/link-follow: New module.
7961         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
7962         (Depends-on): Add lchmod.
7963         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
7964         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
7965         (Depends-on): Add stdint.
7966         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
7967         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
7968         (Depends-on): Add stdint.
7969         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
7970         * modules/perl: New module.
7971         * modules/regex (Depends-on): Add stdint.
7972         * modules/rmdir-errno: New module.
7973         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
7974         m4/intmax_t.m4.
7975         (Depends-on): Add stdint.
7976         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
7977         m4/uintmax_t.m4.
7978         (Depends-on): Add stdint.
7979         * modules/unlink-busy: New module.
7980         * modules/utimecmp (Depends-on): Add stdint.
7981         * modules/uptime: New module.
7982         * modules/winsz-ioctl: New module.
7983         * modules/winsz-termios: New module.
7984         * modules/xnanosleep (Depends-on): Add nanosleep.
7985         * modules/ullong_max: Remove.
7986         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
7987         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
7988         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
7989         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
7990         (Depends-on): Add inttypes.
7991         (lib_SOURCES): Add xstrtol.h.
7992         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
7993         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
7994         * MODULES.html.sh: Move 'assert' into the assert section.
7995         Move 'dummy' into the linking section.
7996         Remove ullong_max.
7997         Add section for compatibility checks for POSIX:2001 functions,
7998         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
7999         winsz-ioctl, and winsz-termios into it.
8000         Add lchmod.
8001         Add top-level Misc section and put host-os, perl, and uptime
8002         into it.
8003
8004 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8005
8006         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
8007         now assume the stdint module.  Do not include inttypes.h.
8008         * lib/fsusage.h: Likewise.
8009         * lib/getndelim2.c: Likewise.
8010         * lib/human.h: Likewise.
8011         * lib/inttostr.h: Likewise.
8012         * lib/obstack.c: Likewise.
8013         * lib/regex_internal.h: Likewise.
8014         * lib/tempname.c: Likewise.
8015         * lib/utimecmp.c: Likewise.
8016         * lib/xstrtol.h: Likewise.
8017
8018         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
8019
8020         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
8021         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
8022         * lib/xtime.h: Likewise.
8023
8024 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8025
8026         * modules/openat (Files): Add lib/fchmodat.c.
8027         Fixes problem reported by Jay Youngman.
8028
8029 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8030
8031         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
8032         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
8033
8034 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
8035             Bruno Haible  <bruno@clisp.org>
8036
8037         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
8038         and is a script that invokes bison. Tighten the code. Add comments.
8039
8040 2006-08-18  Jim Meyering  <jim@meyering.net>
8041
8042         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
8043         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
8044         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
8045         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
8046
8047 2006-08-18  Bruno Haible  <bruno@clisp.org>
8048
8049         * modules/bison-i18n: New file.
8050         * MODULES.html.sh (Internationalization functions): Add it.
8051
8052 2006-08-18  Bruno Haible  <bruno@clisp.org>
8053
8054         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
8055         sys/statvfs.h. When getmntinfo was found, check its declaration and
8056         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
8057
8058 2006-08-18  Bruno Haible  <bruno@clisp.org>
8059
8060         * m4/bison-i18n.m4: New file, from bison.
8061
8062 2006-08-18  Bruno Haible  <bruno@clisp.org>
8063
8064         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
8065         (ME_DUMMY): Treat "kernfs" as a dummy.
8066         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
8067
8068 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8069
8070         Update from coreutils.
8071
8072         2006-08-15  Jim Meyering  <jim@meyering.net>
8073
8074         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
8075
8076         2006-01-17  Jim Meyering  <jim@meyering.net>
8077
8078         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
8079
8080         2006-01-11  Jim Meyering  <jim@meyering.net>
8081
8082         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
8083         Check for the lchmod function.
8084
8085 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8086
8087         Update from coreutils.
8088
8089         * lib/__fpending.h: Add copyright notice.
8090         * lib/fprintftime.h: Likewise.
8091         * lib/savedir.c: Use (C) in copyright notice.
8092         * lib/savedir.h: Likewise.
8093
8094         2006-08-15  Jim Meyering  <jim@meyering.net>
8095
8096         * lib/at-func.c: New file, with the logic of all emulated at-functions.
8097         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
8098         in support of the EXPECTED_ERRNO macro.
8099         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
8100         definitions.  Instead, define the appropriate symbols and include
8101         "at-func.c".
8102         * lib/mkdirat.c (mkdirat): Likewise.
8103         * lib/fchmodat.c (fchmodat): Likewise.
8104         (ENOSYS): Remove definition.
8105         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
8106         it.  Don't include "unistd--.h" -- it wasn't ever used.
8107
8108         2006-01-17  Jim Meyering  <jim@meyering.net>
8109
8110         Rewrite fts.c not to change the current working directory,
8111         by using openat, fstatat, fdopendir, etc..
8112
8113         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
8114         (HAVE_OPENAT_SUPPORT): Define.
8115         [_LIBC] (fchdir): Don't undef or define; no longer used.
8116         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
8117         Now, this `function' always succeeds, and consumes its file descriptor
8118         parameter -- so callers must not close such FDs.  Update callers.
8119         (diropen_fd, opendirat, cwd_advance_fd): New functions.
8120         (diropen): Add parameter, SP.  Adjust all callers.
8121         Implement using diropen_fd, rather than open.
8122         (fts_open): Initialize new member, fts_cwd_fd.
8123         Remove fts_rft-setting code.
8124         (fts_close): Close fts_cwd_fd, if necessary.
8125         (__opendir2): Define in terms of opendir or opendirat,
8126         depending on whether the FST_NOCHDIR flag is set.
8127         (fts_build): Since fts_safe_changedir consumes its FD, and since
8128         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
8129         and close the dup'd file descriptor upon failure.
8130         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
8131         (fts_safe_changedir): Tweak semantics to reflect that this function
8132         now calls cwd_advance_fd and hence consumes its FD argument.
8133         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
8134         [struct FTS] (fts_rft): Remove now-unused member.
8135         [struct FTS] (fts_cycle.state): Improve comment.
8136
8137         * lib/openat.c (openat_needs_fchdir): New function.
8138         * lib/openat.h (openat_needs_fchdir): Declare it.
8139
8140 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
8141
8142         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
8143         Problem and fix reported by Pádraig Brady in
8144         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
8145
8146 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8147
8148         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
8149
8150 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8151
8152         * lib/memcoll.c (memcoll): Optimize for the common case where the
8153         arguments are bytewise equal.
8154
8155 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8156
8157         * doc/regexprops-generic.texi: Add a copyright notice.
8158
8159 2006-08-15  Bruno Haible  <bruno@clisp.org>
8160
8161         * modules/tmpdir (License): Change to LGPL.
8162
8163 2006-08-15  Bruno Haible  <bruno@clisp.org>
8164
8165         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
8166         module.
8167
8168 2006-08-14  Simon Josefsson  <jas@extundo.com>
8169
8170         * config/srclist.txt: Add gnupload.
8171
8172 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8173
8174         Change copyright notice from LGPL 2 to GPL 2, since that's the
8175         standard form used in the gnulib repository.
8176         * tests/test-lock.c: Likewise.
8177         * tests/test-stdint.c: Likewise.
8178         * tests/test-tls.c: Likewise.
8179
8180         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
8181         prelude-manager.  User shorter URLs for GNU projects, without '?'.
8182         Add copyright notice.
8183
8184         * check-module: Add copyright notice.  Output a copyright
8185         notice if "--version" is specified.
8186         * modules/COPYING: New file.
8187         * tests/test-getaddrinfo.c: Add copyright notice.
8188         * tests/test-verify.c: Likewise.
8189
8190 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8191
8192         Change copyright notice from LGPL 2 to GPL 2, since that's the
8193         standard form used in the gnulib repository.
8194         * lib/lock.c: LGPL -> GPL.
8195         * lib/lock.h: Likewise.
8196         * lib/strnlen1.c: Likewise.
8197         * lib/strnlen1.h: Likewise.
8198         * lib/tls.c: Likewise.
8199         * lib/tls.h: Likewise.
8200         * lib/tmpdir.c: Likewise.
8201
8202         * lib/TODO: Remove; this belongs only in coreutils.
8203
8204 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8205
8206         Add copyright notices to long-enough files that lack them, since
8207         otherwise the files aren't clearly free.  Use the same notice that
8208         getdate.texi already uses.
8209         * doc/alloca-opt.texi: Add copyright notice.
8210         * doc/alloca.texi: Likewise.
8211         * doc/ctime.texi: Likewise.
8212         * doc/functions.texi: Likewise.
8213         * doc/gcd.texi: Likewise.
8214         * doc/gnulib-tool.texi: Likewise.
8215         * doc/inet_ntoa.texi: Likewise.
8216         * doc/visibility.texi: Likewise.
8217
8218         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
8219         * doc/quote.texi: Add copyright notice.
8220
8221         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
8222         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
8223         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
8224         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
8225         is now obsolete, and give a pointer to the Sun list.
8226         Add copyright notice.
8227
8228 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8229
8230         * config/srclistvars.sh: Add copyright notice.
8231
8232 2006-08-14  Eric Blake  <ebb9@byu.net>
8233
8234         Import the following change from libc:
8235
8236         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
8237
8238         Upstream bug 2997.
8239         * lib/misc/error.c: Add space between program name and message if file
8240         name is missing.
8241
8242 2006-08-12  Karl Berry  <karl@gnu.org>
8243
8244         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
8245         remove, these originate in gnulib now.
8246
8247 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8248
8249         * doc/Makefile (standards.info standards.html standards.dvi):
8250         Also depend on make-stds.texi.
8251
8252 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
8253
8254         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
8255         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
8256
8257         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
8258         in wchar_t.  Problem reported by Eric Blake.
8259
8260         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
8261         LEN is smaller than SIZE.  Suggested by Bruno Haible.
8262         Also, help the compiler to keep LEN in a register.
8263
8264 2006-08-11  Eric Blake  <ebb9@byu.net>
8265
8266         * users.txt: Sort.  Add tar.
8267
8268 2006-08-11  Bruno Haible  <bruno@clisp.org>
8269
8270         * users.txt: New file.
8271
8272 2006-08-11  Bruno Haible  <bruno@clisp.org>
8273
8274         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
8275         before <wchar.h>. Needed for OSF/1 and BSD/OS.
8276
8277 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8278
8279         * modules/snprintf (Depends-on): Remove minmax.
8280         (Maintainer): Add self and Bruno.
8281
8282 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8283
8284         * lib/.cppi-disable: Add snprintf.h, socket_.h.
8285         * lib/snprintf.c: Include <errno.h> and <limits.h>.
8286         (EOVERFLOW): Define if the system does not.
8287         Do not include "minmax.h"; it wasn't used.
8288         (snprintf): Don't assume size_t promotes to an unsigned type.
8289         Fix bug when generated string was too long for the buffer: the
8290         buffer's contents are supposed to be the initial prefix of the
8291         output.  Don't assume vasnprintf returns EOVERFLOW if the size
8292         exceeds INT_MAX; do the check ourselves.
8293
8294         Import the following changes from libc:
8295
8296         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
8297
8298         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
8299         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
8300         set wc to the byte which couldn't be converted.
8301         (re_string_reconstruct): Don't clear valid_raw_len before calling
8302         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
8303         tip_context using re_string_context_at.
8304
8305         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
8306
8307         * lib/posix/regex.h: g++ still cannot handled [restrict].
8308
8309         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
8310
8311         * lib/posix/regex.h: Remove special handling for VMS.
8312
8313 2006-08-10  Jim Meyering  <jim@meyering.net>
8314
8315         * modules/same-inode: New module.
8316         * modules/dev-ino: New module.
8317         * modules/cycle-check: Depend on these modules, rather than simply
8318         including their .h files.
8319         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
8320         required via m4/cycle-check.m4.
8321         * modules/same: Depend on new same-inode module, rather than
8322         including same-inode.h.
8323         * modules/chdir-safer: New file.
8324
8325         * modules/chown (Depends-on): Add stat-macros.
8326
8327 2006-08-10  Jim Meyering  <jim@meyering.net>
8328
8329         * m4/cycle-check.m4: New file.
8330         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
8331         * m4/dev-ino.m4, m4/same-inode.m4: New files.
8332
8333 2006-08-10  Eric Blake  <ebb9@byu.net>
8334
8335         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
8336         in from original proposal.
8337
8338 2006-08-10  Eric Blake  <ebb9@byu.net>
8339         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8340
8341         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
8342         namespace.
8343
8344 2006-08-10  Bruno Haible  <bruno@clisp.org>
8345
8346         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
8347         as well.
8348
8349 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8350
8351         Sync from coreutils.
8352
8353         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
8354
8355         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
8356         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
8357
8358 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8359
8360         * modules/restrict: Remove; no longer needed now that we assume
8361         Autoconf 2.59 or later.
8362         * MODULES.html.sh: Remove 'restrict'.
8363         * modules/argp (Depends-on): Remove 'restrict'.
8364         * modules/base64 (Depends-on): Likewise.
8365         * modules/gc (Depends-on): Likewise.
8366         * modules/getaddrinfo (Depends-on): Likewise.
8367         * modules/glob (Depends-on): Likewise.
8368         * modules/inet_ntop (Depends-on): Likewise.
8369         * modules/inet_pton (Depends-on): Likewise.
8370         * modules/memxor (Depends-on): Likewise.
8371         * modules/regex (Depends-on): Likewise.
8372         * modules/strtok_r (Depends-on): Likewise.
8373         * modules/time_r (Depends-on): Likewise.
8374
8375 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8376
8377         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
8378         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
8379         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
8380         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
8381         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
8382         * m4/memxor.m4 (gl_MEMXOR): Likewise.
8383         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
8384         gl_C_RESTRICT replaced by AC_C_RESTRICT.
8385
8386         Merge from coreutils.
8387         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
8388         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
8389         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
8390         * m4/time_r.m4 (gl_TIME_R): Likewise.
8391
8392 2006-08-09  Karl Berry  <karl@gnu.org>
8393
8394         * config/srclist.txt: no more gettext-tools, per Bruno.
8395
8396 2006-08-08  Eric Blake  <ebb9@byu.net>
8397
8398         * modules/verror: New module.
8399         * MODULES.html.sh: Document it.
8400
8401 2006-08-08  Eric Blake  <ebb9@byu.net>
8402
8403         * lib/verror.h, lib/verror.c: New files.
8404
8405 2006-08-08  Eric Blake  <ebb9@byu.net>
8406
8407         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
8408         verror_at_line output complies with GNU Coding Standards even when
8409         file is NULL.
8410
8411 2006-08-07  Bruno Haible  <bruno@clisp.org>
8412
8413         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
8414         versions of AIX.
8415         Reported by Ralf Wildenhues.
8416
8417 2006-08-07  Bruno Haible  <bruno@clisp.org>
8418
8419         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
8420         in an AC_DEFUN. Needed so that the autoconf snippets can use
8421         AC_REQUIRE.
8422
8423 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8424
8425         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8426         Initialize pkgdata_DATA.
8427         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
8428         overriding it.
8429
8430 2006-08-06  Eric Blake  <ebb9@byu.net>
8431
8432         * lib/error.h: Fold in some upstream changes from glibc.
8433         * lib/error.c: Likewise.
8434
8435 2006-08-04  Bruno Haible  <bruno@clisp.org>
8436
8437         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8438         Make the mostlyclean-local rule depend on mostlyclean-generic.
8439         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
8440
8441 2006-07-31  Bruno Haible  <bruno@clisp.org>
8442
8443         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
8444         <stdlib.h>, <string.h>.
8445
8446 2006-07-30  Bruno Haible  <bruno@clisp.org>
8447
8448         * modules/readlink (License): Change to LGPL.
8449
8450 2006-07-30  Bruno Haible  <bruno@clisp.org>
8451
8452         * modules/javaversion (Makefile.am): Distribute javaversion.java and
8453         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
8454         set PKGDATADIR to point to it.
8455
8456 2006-07-30  Bruno Haible  <bruno@clisp.org>
8457
8458         * modules/csharpexec (configure.ac): Comment out macro invocation.
8459         * modules/javaexec (configure.ac): Likewise.
8460         * modules/javacomp-script (configure.ac): Likewise.
8461
8462         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
8463
8464 2006-07-30  Bruno Haible  <bruno@clisp.org>
8465
8466         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
8467         linked-list.
8468
8469 2006-07-30  Bruno Haible  <bruno@clisp.org>
8470
8471         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
8472
8473 2006-07-30  Bruno Haible  <bruno@clisp.org>
8474
8475         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8476         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
8477         get removed.
8478
8479 2006-07-29  Bruno Haible  <bruno@clisp.org>
8480
8481         Make it possible for gnulib-tool to work with locally modified or
8482         augmented gnulib repositories.
8483         * gnulib-tool (func_usage): Document --local-dir option.
8484         (local_gnulib_dir): New variable.
8485         Handle --local-dir option.
8486         (func_lookup_file): New function.
8487         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
8488         (func_get_description, func_get_filelist, func_get_description,
8489         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
8490         func_get_automake_snippet, func_get_include_directive,
8491         func_get_license, func_get_maintainer): Use func_lookup_file.
8492         (func_import, func_create_testdir): Use func_lookup_file.
8493
8494 2006-07-29  Bruno Haible  <bruno@clisp.org>
8495
8496         * modules/setenv (Depends-on): Add unistd.
8497
8498 2006-07-29  Bruno Haible  <bruno@clisp.org>
8499
8500         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
8501
8502 2006-07-29  Bruno Haible  <bruno@clisp.org>
8503
8504         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
8505
8506 2006-07-29  Bruno Haible  <bruno@clisp.org>
8507
8508         * gnulib-tool (import, update): If there is no Makefile.am, look at
8509         aclocal.m4, instead of bailing out.
8510
8511 2006-07-29  Bruno Haible  <bruno@clisp.org>
8512
8513         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
8514         Categorize the options by when they are useful.
8515
8516 2006-07-29  Bruno Haible  <bruno@clisp.org>
8517
8518         * gnulib-tool (func_usage): Document option --no-libtool.
8519         Handle option --no-libtool.
8520         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
8521         for changed semantics of $libtool variable.
8522         (func_import): Likewise. If libtool is not used, show this through
8523         an option --no-libtool.
8524         (func_create_testdir): Update.
8525
8526 2006-07-29  Bruno Haible  <bruno@clisp.org>
8527
8528         * gnulib-tool (func_import): Extend error message about missing
8529         --doc-base.
8530
8531 2006-07-29  Bruno Haible  <bruno@clisp.org>
8532
8533         * gnulib-tool (func_import): Don't create the $docbase directory if
8534         there is no file to store there.
8535
8536 2006-07-29  Bruno Haible  <bruno@clisp.org>
8537
8538         * gnulib-tool (autoconf_minversion): If a --dir option is given and
8539         relevant, look for configure.ac there, not in the current directory.
8540         Also use a simple search for AC_PREREQ, not "autoconf --trace".
8541
8542 2006-07-29  Bruno Haible  <bruno@clisp.org>
8543
8544         * gnulib-tool (SORT): New variable.
8545         (func_usage): Undocument --assume-autoconf option.
8546         Remove --assume-autoconf option handling.
8547         (autoconf_minversion): Determine from the contents of configure.ac.
8548         (func_import): Remove autoconf_minversion handling.
8549         Suggested by Eric Blake.
8550
8551 2006-07-29  Bruno Haible  <bruno@clisp.org>
8552
8553         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
8554
8555 2006-07-29  Bruno Haible  <bruno@clisp.org>
8556
8557         * config/srclist.txt (*setenv.[ch]): Remove rules.
8558
8559 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8560
8561         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
8562
8563 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8564
8565         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
8566         arpa/inet.h.
8567
8568 2006-07-28  Simon Josefsson  <jas@extundo.com>
8569
8570         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
8571         * modules/inet_pton (Depends-on): Likewise.
8572
8573 2006-07-28  Simon Josefsson  <jas@extundo.com>
8574
8575         * m4/netinet_in_h.m4: New file.
8576
8577 2006-07-28  Simon Josefsson  <jas@extundo.com>
8578
8579         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
8580         #include's.
8581
8582 2006-07-28  Simon Josefsson  <jas@extundo.com>
8583
8584         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
8585         #include's.
8586
8587 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
8588
8589         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
8590         setgid on directories only if they set these bits.
8591         * lib/modechange.h: Remove obsolete comment about masks.
8592
8593 2006-07-28  Eric Blake  <ebb9@byu.net>
8594
8595         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
8596         macro expansion.
8597
8598 2006-07-28  Bruno Haible  <bruno@clisp.org>
8599
8600         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
8601
8602 2006-07-28  Bruno Haible  <bruno@clisp.org>
8603
8604         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
8605
8606 2006-07-28  Bruno Haible  <bruno@clisp.org>
8607
8608         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
8609         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
8610         Define fallbacks.
8611         Avoids link error on FreeBSD 4.x.
8612         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
8613
8614         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
8615         encoding.
8616         * lib/mbswidth.c (iswcntrl): Likewise.
8617
8618 2006-07-27  Bruno Haible  <bruno@clisp.org>
8619
8620         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
8621         test.
8622
8623 2006-07-27  Bruno Haible  <bruno@clisp.org>
8624
8625         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
8626         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
8627         defined.
8628
8629 2006-07-26  Eric Blake  <ebb9@byu.net>
8630
8631         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
8632
8633 2006-07-26  Eric Blake  <ebb9@byu.net>
8634
8635         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
8636         like mingw that lack mkstemp.
8637         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
8638         avoid compilation warning on mingw.
8639
8640 2006-07-26  Bruno Haible  <bruno@clisp.org>
8641
8642         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
8643         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
8644         INT_FAST*_MIN, INTPTR_MIN.
8645
8646 2006-07-25  Bruno Haible  <bruno@clisp.org>
8647
8648         * modules/version-etc (Depends-on): Add stdarg.
8649
8650 2006-07-25  Bruno Haible  <bruno@clisp.org>
8651
8652         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
8653         complex commands.
8654
8655 2006-07-25  Bruno Haible  <bruno@clisp.org>
8656
8657         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
8658         defined in <stdarg.h> or config.h.
8659
8660 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
8661
8662         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
8663         (gl_STDIO_SAFER): Remove.
8664
8665 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
8666
8667         * MODULES.html.sh (File stream based Input/Output):
8668         Add fopen-safer, tmpfile-safer; remove stdio-safer.
8669         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
8670         * modules/fopen-safer, modules/tmpfile-safer: New files.
8671         * modules/stdio-safer: Remove.
8672
8673 2006-07-24  Bruno Haible  <bruno@clisp.org>
8674
8675         * modules/tmpdir: New file.
8676         * MODULES.html.sh (File system functions): Add it.
8677
8678 2006-07-24  Bruno Haible  <bruno@clisp.org>
8679
8680         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
8681         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
8682
8683 2006-07-24  Bruno Haible  <bruno@clisp.org>
8684
8685         * modules/clean-temp: New file.
8686
8687 2006-07-24  Bruno Haible  <bruno@clisp.org>
8688
8689         * m4/tmpdir.m4: New file, from GNU gettext.
8690
8691 2006-07-24  Bruno Haible  <bruno@clisp.org>
8692
8693         * lib/tmpdir.h: New file, from GNU gettext.
8694         * lib/tmpdir.c: New file, from GNU gettext.
8695
8696 2006-07-24  Bruno Haible  <bruno@clisp.org>
8697
8698         * lib/clean-temp.h: New file, from GNU gettext.
8699         * lib/clean-temp.c: New file, from GNU gettext.
8700
8701 2006-07-23  Eric Blake  <ebb9@byu.net>
8702
8703         * modules/stdio-safer (Files): Add tmpfile-safer.c.
8704         (Depends-on): Add binary-io.
8705
8706 2006-07-23  Eric Blake  <ebb9@byu.net>
8707
8708         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
8709
8710 2006-07-23  Eric Blake  <ebb9@byu.net>
8711
8712         * lib/tmpfile-safer.c: New file.
8713         * lib/stdio-safer.h (fopen_safer): Add prototype.
8714         * lib/stdio--.h (tmpfile): Make safer.
8715
8716 2006-07-23  Bruno Haible  <bruno@clisp.org>
8717
8718         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
8719         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
8720         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
8721         gl_linked_remove_at): Use it.
8722
8723 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8724         and Simon Josefsson <jas@extundo.com>
8725
8726         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
8727
8728         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
8729
8730 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
8731
8732         * modules/close-stream: New file.
8733         * modules/closeout (Description): Make it clear that it exits
8734         with a diagnostic on error.
8735         (Depends-on): Add close-stream.  Remove fpending, stdbool.
8736         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
8737
8738 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
8739
8740         * m4/close-stream.m4: New file.
8741
8742 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
8743
8744         * lib/close-stream.c, lib/close-stream.h: New files.
8745
8746 2006-07-22  Bruno Haible  <bruno@clisp.org>
8747
8748         Merge from GNU gettext 0.15.
8749
8750         2006-05-01  Bruno Haible  <bruno@clisp.org>
8751
8752                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
8753
8754         2006-07-22  Bruno Haible  <bruno@clisp.org>
8755
8756                 * modules/javaversion: New file.
8757                 * MODULES.html.sh (Java): Add javaversion.
8758
8759         2006-03-12  Bruno Haible  <bruno@clisp.org>
8760
8761                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
8762
8763         2005-12-04  Bruno Haible  <bruno@clisp.org>
8764
8765                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
8766                 (untested).
8767
8768         2006-06-21  Bruno Haible  <bruno@clisp.org>
8769
8770                 Avoid warnings from recent versions of mcs.
8771                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
8772                 -o, -L, -r any more. Use options documented since mcs-1.0
8773                 instead. Similarly for -g.
8774
8775         2005-12-04  Bruno Haible  <bruno@clisp.org>
8776
8777                 * build-aux/csharpcomp.sh.in: Suffix for resources is
8778                 .resources, not .resource.
8779
8780         2005-07-09  Bruno Haible  <bruno@clisp.org>
8781
8782                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
8783                 add a .dll suffix.
8784                 Reported by Mark Junker <mjscod@gmx.de>.
8785
8786         2006-07-22  Bruno Haible  <bruno@clisp.org>
8787
8788                 * modules/gettext: Upgrade to gettext-0.15.
8789                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
8790                 m4/visibility.m4.
8791                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
8792
8793 2006-07-22  Bruno Haible  <bruno@clisp.org>
8794
8795         Merge from GNU gettext 0.15.
8796
8797         2006-03-25  Bruno Haible  <bruno@clisp.org>
8798
8799                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
8800
8801         2006-07-21  Bruno Haible  <bruno@clisp.org>
8802
8803                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
8804                 "1.1".
8805
8806         2006-05-09  Bruno Haible  <bruno@clisp.org>
8807
8808                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
8809                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
8810                 for the conftestver execution.
8811
8812         2006-05-01  Bruno Haible  <bruno@clisp.org>
8813
8814                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
8815                 optional target-version argument. Verify that the compiler
8816                 groks source of the specified source-version, or add -source
8817                 option as necessary. Verify that the compiler produces
8818                 bytecode in the specified target-version, or add -target and
8819                 -source options as necessary. Make the result of the test
8820                 available as variable CONF_JAVAC. Also log error output in
8821                 config.log.
8822
8823         2006-03-11  Bruno Haible  <bruno@clisp.org>
8824
8825                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
8826
8827         2006-05-09  Bruno Haible  <bruno@clisp.org>
8828
8829                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
8830                 CLASSPATH_SEPARATOR to a semicolon.
8831
8832         2006-03-12  Bruno Haible  <bruno@clisp.org>
8833
8834                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
8835                 available as variable CONF_JAVA, for subsequent autoconf
8836                 tests. Also log error output in config.log.
8837
8838         2006-07-19  Bruno Haible  <bruno@clisp.org>
8839
8840                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
8841                 that getline works on glibc2 systems. Needed to avoid trouble
8842                 in relocatable.c.
8843                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
8844
8845         2005-12-04  Bruno Haible  <bruno@clisp.org>
8846
8847                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
8848                 launcher (untested).
8849
8850         2005-12-04  Bruno Haible  <bruno@clisp.org>
8851
8852                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
8853
8854         2006-07-22  Bruno Haible  <bruno@clisp.org>
8855
8856                 * gettext.m4: Update from GNU gettext-0.15.
8857                 * nls.m4: Likewise.
8858                 * po.m4: Likewise.
8859                 * inttypes-pri.m4: Likewise.
8860                 * inttypes-h.m4: Renamed from inttypes.m4.
8861                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
8862
8863 2006-07-22  Bruno Haible  <bruno@clisp.org>
8864
8865         Merge from GNU gettext 0.15.
8866
8867         2005-07-05  Bruno Haible  <bruno@clisp.org>
8868
8869                 * printf-args.c (printf_fetchargs): Work around broken
8870                 definition of wint_t on mingw.
8871
8872         2005-02-12  Bruno Haible  <bruno@clisp.org>
8873
8874                 * xallocsa.h: Add extern "C" for C++.
8875
8876         2006-05-17  Bruno Haible  <bruno@clisp.org>
8877
8878                 Cygwin portability.
8879                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
8880
8881         2006-04-30  Bruno Haible  <bruno@clisp.org>
8882
8883                 * progreloc.c: Include <mach-o/dyld.h> if available.
8884                 (find_executable): Use _NSGetExecutablePath when possible.
8885
8886         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8887
8888                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
8889                 function.
8890
8891         2005-12-29  Bruno Haible  <bruno@clisp.org>
8892
8893                 * progreloc.c (set_program_name_and_installdir): Fix
8894                 compilation error.
8895
8896         2005-12-04  Bruno Haible  <bruno@clisp.org>
8897
8898                 Cygwin portability.
8899                 * progreloc.c: Include <windows.h> also on Cygwin.
8900                 (find_executable): Add support for Cygwin.
8901                 (set_program_name_and_installdir): Handle also platforms with
8902                 nonempty EXEEXT.
8903
8904         2006-07-11  Bruno Haible  <bruno@clisp.org>
8905
8906                 * javacomp.c: Fix a comment.
8907                 Reported by Jim Meyering.
8908
8909         2006-04-30  Bruno Haible  <bruno@clisp.org>
8910
8911                 * javacomp.h (compile_java_class): Add source_version,
8912                 target_version arguments.
8913                 * javacomp.c: Rewritten to choose only a compiler that
8914                 respects the specified source_version and target_version.
8915
8916         2006-06-27  Bruno Haible  <bruno@clisp.org>
8917
8918                 Assume correct S_ISDIR macro.
8919                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
8920
8921         2006-07-22  Bruno Haible  <bruno@clisp.org>
8922
8923                 * javaversion.h: New file, from GNU gettext.
8924                 * javaversion.c: New file, from GNU gettext.
8925                 * javaversion.java: New file, from GNU gettext.
8926                 * javaversion.class: New file, from GNU gettext.
8927
8928         2006-05-17  Bruno Haible  <bruno@clisp.org>
8929
8930                 Cygwin portability.
8931                 * javaexec.c (execute_java_class): Test for jview program
8932                 also on Cygwin.
8933
8934         2006-04-09  Bruno Haible  <bruno@clisp.org>
8935
8936                 * fatal-signal.c: Don't include string.h.
8937                 (at_fatal_signal): Use a copying loop instead of memcpy.
8938
8939         2005-12-04  Bruno Haible  <bruno@clisp.org>
8940
8941                 * csharpexec.c: Add support for 'clix' launcher (untested).
8942                 (execute_csharp_using_sscli): New function.
8943                 (execute_csharp_program): Call it.
8944
8945         2006-06-21  Bruno Haible  <bruno@clisp.org>
8946
8947                 Avoid warnings from recent versions of mcs.
8948                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
8949                 -o, -L, -r any more. Use options documented since mcs-1.0
8950                 instead. Similarly for -g.
8951
8952         2005-07-09  Bruno Haible  <bruno@clisp.org>
8953
8954                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
8955                 add a .dll suffix.
8956                 Reported by Mark Junker <mjscod@gmx.de>.
8957
8958         2006-06-17  Bruno Haible  <bruno@clisp.org>
8959
8960                 * config.charset: Update for NetBSD 3.0.
8961
8962         2006-05-17  Bruno Haible  <bruno@clisp.org>
8963
8964                 Cygwin portability.
8965                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
8966
8967         2006-05-16  Bruno Haible  <bruno@clisp.org>
8968
8969                 * localcharset.c [CYGWIN]: Include <windows.h>.
8970                 (get_charset_aliases): For Cygwin, return the same CPxxx
8971                 aliases list as under WIN32.
8972                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
8973                 the environment variables. Fall back to GetACP().
8974
8975         2006-04-05  Bruno Haible  <bruno@clisp.org>
8976
8977                 * config.charset: Update Juan Manuel Guerrero's address.
8978
8979         2005-02-12  Bruno Haible  <bruno@clisp.org>
8980
8981                 * allocsa.h: Add extern "C" for C++.
8982
8983         2005-02-10  Bruno Haible  <bruno@clisp.org>
8984
8985                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
8986                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
8987
8988         2006-07-22  Bruno Haible  <bruno@clisp.org>
8989
8990                 * gettext.h: Update to GNU gettext-0.15.
8991
8992 2006-07-22  Bruno Haible  <bruno@clisp.org>
8993
8994         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
8995         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
8996         lib-prefix.m4, longdouble.m4, ssize_t.m4.
8997
8998 2006-07-21  Eric Blake  <ebb9@byu.net>
8999
9000         * modules/stdlib-safer: New file.
9001         * MODULES.html.sh (File stream based Input/Output): Add
9002         stdlib-safer.
9003
9004 2006-07-21  Eric Blake  <ebb9@byu.net>
9005
9006         * lib/stdlib-safer.h: New file from coreutils, required by
9007         stdlib--.h.
9008
9009 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
9010
9011         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
9012
9013 2006-07-20  Bruno Haible  <bruno@clisp.org>
9014
9015         * gnulib-tool: Recognize new option --assume-autoconf.
9016         (autoconf_minversion): New variable.
9017         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
9018
9019 2006-07-20  Bruno Haible  <bruno@clisp.org>
9020
9021         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
9022
9023 2006-07-19  Derek R. Price  <derek@ximbiot.com>
9024
9025         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
9026         Reindent and repaginate.
9027
9028 2006-07-19  Derek Price  <derek@ximbiot.com>
9029
9030         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
9031         Correct grammar.
9032
9033 2006-07-17  Bruno Haible  <bruno@clisp.org>
9034
9035         * modules/list: New file.
9036         * modules/array-list: New file.
9037         * modules/carray-list, modules/carray-list-tests: New files.
9038         * modules/linked-list, modules/linked-list-tests: New files.
9039         * modules/avltree-list, modules/avltree-list-tests: New files.
9040         * modules/rbtree-list, modules/rbtree-list-tests: New files.
9041         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
9042         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
9043         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
9044         * modules/oset: New file.
9045         * modules/array-oset: New file.
9046         * modules/avltree-oset, modules/avltree-oset-tests: New files.
9047         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
9048         * tests/test-carray_list.c: New file.
9049         * tests/test-linked_list.c: New file.
9050         * tests/test-avltree_list.c: New file.
9051         * tests/test-rbtree_list.c: New file.
9052         * tests/test-linkedhash_list.c: New file.
9053         * tests/test-avltreehash_list.c: New file.
9054         * tests/test-rbtreehash_list.c: New file.
9055         * tests/test-avltree_oset.c: New file.
9056         * tests/test-rbtree_oset.c: New file.
9057         * MODULES.html.sh (Container data structures): New section.
9058
9059 2006-07-17  Bruno Haible  <bruno@clisp.org>
9060
9061         * m4/gl_list.m4: New file.
9062
9063 2006-07-17  Bruno Haible  <bruno@clisp.org>
9064
9065         * lib/gl_list.h: New file.
9066         * lib/gl_list.c: New file.
9067         * lib/gl_array_list.h: New file.
9068         * lib/gl_array_list.c: New file.
9069         * lib/gl_carray_list.h: New file.
9070         * lib/gl_carray_list.c: New file.
9071         * lib/gl_linked_list.h: New file.
9072         * lib/gl_linked_list.c: New file.
9073         * lib/gl_anylinked_list1.h: New file.
9074         * lib/gl_anylinked_list2.h: New file.
9075         * lib/gl_avltree_list.h: New file.
9076         * lib/gl_avltree_list.c: New file.
9077         * lib/gl_anyavltree_list1.h: New file.
9078         * lib/gl_anyavltree_list2.h: New file.
9079         * lib/gl_rbtree_list.h: New file.
9080         * lib/gl_rbtree_list.c: New file.
9081         * lib/gl_anyrbtree_list1.h: New file.
9082         * lib/gl_anyrbtree_list2.h: New file.
9083         * lib/gl_anytree_list1.h: New file.
9084         * lib/gl_anytree_list2.h: New file.
9085         * lib/gl_linkedhash_list.h: New file.
9086         * lib/gl_linkedhash_list.c: New file.
9087         * lib/gl_anyhash_list1.h: New file.
9088         * lib/gl_anyhash_list2.h: New file.
9089         * lib/gl_avltreehash_list.h: New file.
9090         * lib/gl_avltreehash_list.c: New file.
9091         * lib/gl_rbtreehash_list.h: New file.
9092         * lib/gl_rbtreehash_list.c: New file.
9093         * lib/gl_anytreehash_list1.h: New file.
9094         * lib/gl_anytreehash_list2.h: New file.
9095
9096         * lib/gl_oset.h: New file.
9097         * lib/gl_oset.c: New file.
9098         * lib/gl_array_oset.h: New file.
9099         * lib/gl_array_oset.c: New file.
9100         * lib/gl_avltree_oset.h: New file.
9101         * lib/gl_avltree_oset.c: New file.
9102         * lib/gl_rbtree_oset.h: New file.
9103         * lib/gl_rbtree_oset.c: New file.
9104         * lib/gl_anytree_oset.h: New file.
9105
9106 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9107
9108         * m4/mkancesdirs.m4: New file.
9109         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
9110         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
9111         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
9112         it.
9113
9114 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9115
9116         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
9117         * lib/mkancesdirs.h: New files.
9118         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
9119         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
9120         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
9121         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
9122         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
9123         callers changed.  Revamp internals significantly, by not
9124         attempting to create directories that are temporarily more
9125         permissive than the final results.  Do not attempt to use
9126         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
9127         This removes some race conditions, fixes some bugs, and simplifies
9128         things.  Use new dirchownmod function to do owner and mode changes.
9129         * lib/mkdir-p.h: Likewise.
9130         * lib/modechange.c (octal_to_mode): New function.
9131         (struct mode_change): New member mentioned.
9132         (make_node_op_equals): New arg mentioned.  All callers changed.
9133         (mode_compile): Keep track of which mode bits the user has explicitly
9134         mentioned.
9135         (mode_adjust): New arg DIR, so that we implement the X op correctly.
9136         New arg PMODE_BITS, to keep track of which mode bits the user
9137         mentioned; it treats S_ISUID and S_ISGID speciall.
9138         All callers changed.
9139         * lib/modechange.h: Likewise.
9140
9141 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9142
9143         * MODULES.html.sh: Add mkancestors.
9144         * modules/mkancesdirs: New module.
9145         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
9146         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
9147         The chdir-safer and afs files are now orphans; I'll remove them
9148         unless someone speaks up.
9149         Add lib/dirchownmod.c, lib/dirchownmod.h.
9150         (Depends-on): Remove alloca, chown, save-cwd, dirname.
9151         Add lchown, mkancesdirs.
9152         (Maintainer): Add self.
9153
9154 2006-07-15  Karl Berry  <karl@gnu.org>
9155
9156         * gnulib-tool: help message wording/arrangement.
9157
9158 2006-07-14  Simon Josefsson  <jas@extundo.com>
9159
9160         * doc/gnulib.texi (Libtool and Windows): New section.
9161
9162 2006-07-12  Simon Josefsson  <jas@extundo.com>
9163
9164         * modules/gendocs (License): Fix license, approved by Karl.
9165
9166 2006-07-12  Eric Blake  <ebb9@byu.net>
9167
9168         * MODULES.html.sh: Add gendocs.
9169
9170 2006-07-11  Eric Blake  <ebb9@byu.net>
9171
9172         * modules/fdl: New module, to install doc/fdl.texi.
9173         * MODULES.html.sh: Add new section for documentation modules.
9174         * gnulib-tool: Avoid space-tab.
9175         (--doc-base): New option, to manage files from doc.
9176
9177 2006-07-11  Eric Blake  <ebb9@byu.net>
9178
9179         * m4/absolute-header.m4: Fix comments to match recent change.
9180
9181 2006-07-11  Eric Blake  <ebb9@byu.net>
9182
9183         * gnulib-tool: List --doc-base before --tests-base.
9184
9185 2006-07-11  Derek R. Price  <derek@ximbiot.com>
9186
9187         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
9188
9189 2006-07-11  Bruno Haible  <bruno@clisp.org>
9190
9191         * README: Mention where to put documentation.
9192
9193 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9194
9195         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
9196
9197 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9198
9199         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
9200         to stdint.m4.
9201
9202 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9203
9204         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
9205         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
9206         "no/such/file/stdint.h" when there is no such file, so that
9207         the resulting C code can be parsed by dodgy compilers.
9208         Problems reported by Bob Proulx.
9209
9210 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9211
9212         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
9213         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9214         macros into the GNU _D_EXACT_NAMLEN.
9215         * lib/savedir.c:  Likewise.
9216         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
9217
9218 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9219         and Paul Eggert  <eggert@cs.ucla.edu>
9220
9221         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
9222         * m4/savedir.m4:
9223         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9224         macros into the GNU _D_EXACT_NAMLEN.
9225
9226 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9227
9228         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
9229         around the absolute name, to work around a problem with the HP-UX
9230         11.23 native C compiler, reported by Bob Proulx.
9231
9232 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9233
9234         * doc/maintain.texi, make-stds.texi: Sync from
9235         <http://savannah.gnu.org/projects/gnustandards>.
9236
9237 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9238
9239         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
9240
9241 2006-07-09  Jim Meyering  <jim@meyering.net>
9242
9243         * m4/glob.m4: Remove a doubled word in a comment.
9244
9245 2006-07-09  Jim Meyering  <jim@meyering.net>
9246
9247         * lib/argp-pv.c: Remove a doubled word in a comment.
9248         * lib/check-version.c (check_version): Likewise.
9249         * lib/javacomp.c (compile_java_class): Likewise.
9250
9251 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
9252
9253         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
9254         for the benefit of people using Autoconf 2.60.  If you want to
9255         support older Autoconf versions you can copy m4/onceonly_2_57.m4
9256         (or m4/onceonly.m4, if pre-2.57) manually.
9257
9258 2006-07-08  Jim Meyering  <jim@meyering.net>
9259
9260         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
9261         comment.
9262         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
9263         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
9264         comment.
9265
9266 2006-07-08  Jim Meyering  <jim@meyering.net>
9267
9268         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
9269
9270 2006-07-07  Simon Josefsson  <jas@extundo.com>
9271
9272         * tests/test-crc.c: Change expected crc value, the test vector
9273         were probably computed using the old broken crc.c?
9274
9275 2006-07-06  Simon Josefsson  <jas@extundo.com>
9276
9277         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
9278         now the canonical place for the M4 file).
9279
9280         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
9281         from the sys_socket dependency now.
9282
9283         * modules/inet_pton (Files): Ditto.
9284
9285         * modules/inet_ntop (Files): Ditto.
9286
9287 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
9288
9289         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
9290         not gl_PREREQ_GETUSERSHELL.
9291
9292 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9293
9294         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
9295         with only one argument, for Autoconf 2.60.
9296         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
9297         expand to nothing, so add a shell command to avoid syntax error.
9298         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
9299
9300 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9301
9302         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
9303
9304 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9305
9306         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
9307         no longer needed.  Check for isblank decl.
9308         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
9309         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
9310         of existence.
9311
9312 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9313
9314         * lib/getloadavg.c: Use __VMS, not VMS.
9315         * lib/getopt.c: Likewise.
9316         * lib/getpagesize.h: Likewise.
9317         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
9318         and probably does not work.
9319
9320 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9321
9322         * lib/.cppi-disable: Add wcwidth.
9323         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
9324         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
9325         (ISGRAPH): Remove.  All uses changed to isgraph.
9326         (FOLD) [!defined _LIBC]: Remove special case.
9327         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
9328         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
9329         HAVE_ISBLANK.
9330         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
9331         case.
9332
9333 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
9334
9335         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
9336         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
9337         brackets.  Other minor changes to suppress some compiler
9338         warnings.
9339
9340 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9341         and Paul Eggert  <eggert@cs.ucla.edu>
9342
9343         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
9344         of invoking obsolescent AC_HEADER_DIRENT macro.
9345         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
9346         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
9347         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
9348         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
9349         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
9350         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
9351         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
9352         * m4/readdir.m4: Remove; no longer needed.
9353
9354 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9355         and Paul Eggert  <eggert@cs.ucla.edu>
9356
9357         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
9358         Don't worry about this obsolete case any more.
9359         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
9360         directories.
9361         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
9362         worry about this obsolete case any more.
9363         * lib/fts.c: Likewise.
9364         * lib/getcwd.c: Likewise.
9365         * lib/glob.h: Likewise.
9366         * lib/savedir.c: Likewise.
9367
9368 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9369
9370         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
9371         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
9372         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
9373         needed.
9374         All uses removed.
9375         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9376         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9377         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
9378         needed.
9379         * m4/getdate.m4 (gl_GETDATE): Likewise.
9380         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9381         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9382         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9383         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9384         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9385         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9386         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
9387         needed.
9388
9389 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9390
9391         * lib/memcasecmp.c: Include <limits.h>.
9392         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
9393         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
9394         Don't assume isdigit succeeds only on '0' through '9'.
9395
9396 2006-07-05  Eric Blake  <ebb9@byu.net>
9397
9398         * modules/getaddrinfo (Depends-on): Add snprintf.
9399
9400 2006-07-05  Eric Blake  <ebb9@byu.net>
9401
9402         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
9403         to avoid 'header present but could not be compiled' on cygwin.
9404
9405 2006-07-05  Eric Blake  <ebb9@byu.net>
9406
9407         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
9408         missing from netdb.h.
9409         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
9410
9411 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9412
9413         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
9414         no longer needed.
9415         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
9416         * m4/getdate.m4 (gl_GETDATE): Likewise.
9417         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9418         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9419         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9420         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9421         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9422
9423 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9424
9425         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
9426         All uses of is_space replaced by isspace.
9427         * lib/exit.h: Don't talk about STDC_HEADERS.
9428         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
9429         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
9430         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
9431         replaced by isprint etc.
9432         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
9433         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
9434         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
9435         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
9436         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
9437         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
9438
9439 2006-07-05  Bruno Haible  <bruno@clisp.org>
9440
9441         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
9442         the function exists, before testing against AIX.
9443         Reported by Martin Lambers <marlam@marlam.de>.
9444
9445 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
9446
9447         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
9448         From Mark D. Baushke.
9449
9450 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
9451
9452         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
9453         to the absolute name, not just one, to bypass Sun C 5.8's
9454         "warning: #include of /usr/include/... may be non-portable".
9455
9456 2006-07-04  Eric Blake  <ebb9@byu.net>
9457
9458         * modules/dirname-tests: New test module.
9459         * tests/test-dirname.c: New file, replacing dirname.c
9460         TEST_DIRNAME section that was recently deleted.
9461
9462 2006-07-04  Bruno Haible  <bruno@clisp.org>
9463
9464         Assume ANSI C header files and <ctype.h> functions.
9465         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
9466         (mbsnwidth): Use isprint, iscntrl instead.
9467
9468 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9469
9470         Merge from coreutils.
9471         * MODULES.html.sh: Add xstrtold.
9472         * modules/xstrtold: New file.
9473         * modules/cycle-check (Files): Add lib/same-inode.h.
9474         * modules/dirname (Files): Add m4/double-slash-root.m4.
9475         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
9476         * modules/mkdir-p (Files): Add lib/same-inode.h.
9477         * modules/same (Files): Add lib/same-inode.h.
9478
9479 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9480
9481         * m4/absolute-header.m4: Renamed from full-header-path.m4.
9482         This is to keep the terminology clean; POSIX talks about
9483         "absolute pathnames", not "full pathnames", but the GNU
9484         Coding Standards say to use "path" for something else;
9485         so use "absolute" to keep both sides happy.
9486         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
9487         Set gl_absolute_header, not gl_full_header_path.
9488         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
9489         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
9490         All uses changed.
9491
9492         Merge from coreutils.
9493
9494         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
9495
9496         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
9497         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
9498         want to require the building of c-strtod.o.
9499         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
9500         needs -lm directly.
9501         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
9502
9503         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
9504
9505         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
9506         --as-needed option if available.  Problem reported by Albert Chin in
9507         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
9508         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
9509         cc merely issues a bunch of annoying warnings for --as-needed
9510         (this problem was reported by Bob Proulx).  Also, try linking with
9511         -lm to detect a bug in binutils 2.16 (this problem was reported
9512         by Ralf Wildenhues).
9513
9514         2006-06-18  Jim Meyering  <jim@meyering.net>
9515
9516         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
9517         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
9518         macro.
9519         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
9520         also check for glibc-2.4's abort-inducing bug.
9521
9522         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
9523         Low-probability clean-up should be to use rmdir to get rid of
9524         the just-created directory, not unlink.
9525
9526         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
9527         configure fail, and request a bug report to inform us about it.
9528         Add a comment that, barring reports to the contrary, in 2007 we'll
9529         assume ftruncate is universally available.
9530
9531         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
9532
9533         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
9534
9535         2006-03-12  Jim Meyering  <jim@meyering.net>
9536
9537         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
9538         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
9539         * m4/same.m4 (gl_SAME): Likewise.
9540         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
9541
9542         2006-03-11  Eric Blake  <ebb9@byu.net>
9543
9544         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
9545         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
9546         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
9547         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
9548
9549 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9550
9551         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
9552         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
9553         reported by Mark D. Baushke, one in
9554         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
9555
9556         Merge from coreutils.
9557
9558         * lib/.cppi-disable: Add stdint_.h.
9559         * lib/.cvsignore: Add stdint.h.
9560
9561         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
9562
9563         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
9564         both double and long double versions.
9565         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
9566         * lib/xstrtold.c: New file.
9567         * lib/xstrtod.h (xstrtold): New decl.
9568
9569         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
9570
9571         * lib/filemode.c (setst): Remove.
9572         (strmode): Rewrite to avoid setst.  This makes the code shorter,
9573         (arguably) clearer, and the generated code is a bit smaller on my
9574         Debian GNU/Linux stable x86 host.
9575
9576         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
9577
9578         * lib/filemode.c: Include "filemode.h" first, to test the interface.
9579         Assume that filemode.h includes sys/types.h and sys/stat.h.
9580         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
9581         (ftypelet): Reorder to put common cases first, for efficiency.
9582         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
9583         to do 'M'.
9584         (strmode): Renamed from mode_string, and now stores 12 bytes instead
9585         of 10, for compatibility with FreeBSD.  All callers changed.
9586         (filemodestring): Now stores 12 bytes instead of 10, and sets file
9587         types that can't be deduced solely from st_mode.  First arg is now a
9588         const pointer.
9589         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
9590         (strmode): Renamed from mode_string.
9591         (filemodestring): New decl.
9592         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
9593         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
9594         needed.
9595         (S_ISPORT, S_ISWHT): New macros, if not already defined.
9596
9597         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
9598
9599         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
9600         fsusage.h now does that.  Include fsusage.h first, to test interface.
9601         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
9602         at most one method (the old code could have generated decls that
9603         didn't conform to C89, not that this was ever exercised).
9604         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
9605
9606         2006-03-19  Jim Meyering  <jim@meyering.net>
9607
9608         Work even in a chroot where d_ino values for entries in "/"
9609         don't match the stat.st_ino values for the same names.
9610         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
9611         number, iterate through all entries again, using lstat instead.
9612         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
9613         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
9614
9615         * lib/getcwd.c (__getcwd): Clarify a comment.
9616         Use memcpy in place of a call to strcpy.
9617
9618         2006-03-12  Jim Meyering  <jim@meyering.net>
9619
9620         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
9621         matches that of the current directory (which we're about to chdir ".."
9622         out of), then save the dev-ino of the parent, instead.
9623
9624         * lib/same-inode.h (SAME_INODE): New file/macro.
9625         * lib/chdir-safer.c (SAME_INODE): Remove definition.
9626         Include "same-inode.h", instead.
9627         * lib/same.c: Likewise.
9628         * lib/cycle-check.h: Include "same-inode.h".
9629         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
9630         * lib/cycle-check.c (SAME_INODE): Remove definition.
9631         * lib/root-dev-ino.h: Include "same-inode.h".
9632
9633         2006-03-11  Eric Blake  <ebb9@byu.net>
9634
9635         * lib/same.c (same_name): s/base_name/last_component/
9636         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
9637         * lib/filenamecat.c (file_name_concat): Likewise.
9638
9639         2006-03-11  Eric Blake  <ebb9@byu.net>,
9640                     Paul Eggert  <eggert@cs.ucla.edu>
9641
9642         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
9643         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
9644         drive prefix.
9645         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
9646         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
9647         (last_component): New method.
9648         * lib/dirname.c (dir_len): Determine when drive letters need a
9649         subsequent slash.  Preserve // when it is special.
9650         (dir_name): Don't append dot when drive letter is absolute.
9651         [TEST_DIRNAME]: Move into a full-blown gnulib test.
9652         * lib/basename.c (base_name): New semantics - malloc the result.
9653         Preserve // when it is special.  Preserve relative files that look
9654         like drive letters.
9655         (base_len): Preserve // when it is special.
9656         (last_component): New method, similar to old base_name semantics.
9657         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
9658         base_name.  Strip redundant slashes from ///.
9659
9660 2006-07-03  Jim Meyering  <jim@meyering.net>
9661
9662         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
9663         macro is used before the first cycle_check call.
9664
9665 2006-07-03  Eric Blake  <ebb9@byu.net>
9666
9667         * modules/dirname (Depends-on): Add xstrndup.
9668
9669 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
9670
9671         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
9672         test cases, so that config.log is a bit easier to follow.
9673
9674 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
9675
9676         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
9677         both are 64 bits, since this seems to be the tradition, and this
9678         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
9679         we ever run into a host that prefers long long to long in this
9680         case, we'll need another configure-time test.  Problem reported by
9681         Jim Meyering.
9682
9683 2006-07-02  Eric Blake  <ebb9@byu.net>
9684
9685         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
9686
9687 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
9688
9689         * modules/inttypes (Depends-on): No longer depends on stdint.
9690         * modules/stdint (Description): Say more about assumptions.
9691         Say that the fast types might differ.  Say macros are used.
9692         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
9693         (Makefile.am): Revise list of substituted symbols to match
9694         new stdint.m4.
9695         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
9696         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
9697         * tests/test-stdint.c (verify_same_types)
9698         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
9699         the code conforms to C99/C89.
9700         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
9701         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
9702
9703 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
9704
9705         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
9706         but fix a bug, by requiring at least 64 bits.
9707         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
9708         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
9709         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
9710         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
9711
9712         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
9713         changes.  Make 2.59 a prerequisite.  Check and substitute for
9714         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
9715         inttypes.h.  Do not use special include files; just use the
9716         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
9717         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
9718         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
9719         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
9720         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
9721         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
9722         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
9723         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
9724         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
9725         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
9726         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
9727         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
9728         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
9729         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
9730         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
9731         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
9732         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
9733         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
9734         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
9735         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
9736         WINT_MAX.  Check for C99 conformance more strictly, by detecting
9737         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
9738         not check for things that C99 does not require, e.g., int8_t.  If
9739         a test isn't needed unless <stdint.h> isn't working, and is
9740         unlikely to be needed for any other reason, then don't do it
9741         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
9742         size_t, since we assume C89 freestanding at least.  Do not check
9743         for sig_atomic_t, wchar_t, or wint_t, since the code now does
9744         the right thing even if the types are not defined.  Instead use:
9745         (gl_STDINT_TYPE_PROPERTIES): New macro.
9746         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
9747         testing whether <sys/types.h> clashes, as Autoconf does this for
9748         us now.  All uses removed.
9749         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
9750         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
9751         (gl_CHECK_TYPE_SAME):
9752         Remove; no longer needed.
9753         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
9754         exists, since we'll return 0 anyway in that case.
9755         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
9756
9757 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
9758
9759         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
9760         possible collision with system files.
9761         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
9762         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
9763         WCHAR_MIN and WCHAR_MAX in this case.
9764         (<stddef.h>): Do not include; no longer needed.
9765         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
9766         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
9767         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
9768         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
9769         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
9770         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
9771         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
9772         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
9773         !defined(__c99))]: Include in this case too, since it's harmless
9774         now.
9775         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
9776         dangerous to do so.
9777         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
9778         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
9779         (_STDINT_MIN, _STDINT_MAX): New macros.
9780         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
9781         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
9782         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
9783         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
9784         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
9785         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
9786         macros, not typedefs; this simplifies things quite a bit.
9787         Use long int for all types narrower than int64_t.
9788         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
9789         Define in terms of long long int or int64_t or long int,
9790         not int64_t or int32_t.  This saves some compile-time testing.
9791         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
9792         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
9793         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
9794         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
9795         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
9796         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
9797         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
9798         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
9799         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
9800         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
9801         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
9802         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
9803         undef any previous version and define our own version, for
9804         simplicity and consistency with the new macros for types.
9805         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
9806         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
9807         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
9808         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
9809         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
9810         @WINT_T_SUFFIX@ to keep things simple here.
9811         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
9812         Simplify by assuming typical 8/16/32/64 host, since we're
9813         already doing that elsewhere anyway.
9814         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
9815         and assume long long int is 64 bits if available.  This
9816         speeds up 'configure'.
9817
9818 2006-07-01  Eric Blake  <ebb9@byu.net>
9819
9820         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
9821         Reported by Andreas Buening.
9822
9823 2006-07-01  Eric Blake  <ebb9@byu.net>
9824
9825         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
9826
9827 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
9828
9829         * lib/getaddrinfo.c: fixed typo
9830
9831 2006-06-29  Jim Meyering  <jim@meyering.net>
9832
9833         * modules/strftime (Maintainer): Add my name, since with the
9834         FPRINTFTIME changes strftime.c has forked from glibc.
9835
9836 2006-06-29  Eric Blake  <ebb9@byu.net>
9837
9838         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
9839
9840 2006-06-29  Eric Blake  <ebb9@byu.net>
9841
9842         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
9843
9844 2006-06-29  Eric Blake  <ebb9@byu.net>
9845
9846         * lib/stat_.h: New file.
9847
9848 2006-06-29  Eric Blake  <ebb9@byu.net>
9849
9850         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
9851         unused static function.
9852
9853 2006-06-29  Eric Blake  <ebb9@byu.net>
9854
9855         * doc/functions.texi (Function Portability): Document missing lstat
9856         on mingw.
9857
9858 2006-06-29  Eric Blake  <ebb9@byu.net>
9859
9860         * MODULES.html.sh: Add sys_stat.
9861         * modules/sys_stat: New module.
9862         * modules/mkstemp (Depends-on): Add sys_stat.
9863
9864 2006-06-29  Derek R. Price  <derek@ximbiot.com>
9865
9866         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
9867
9868 2006-06-29  Derek R. Price  <derek@ximbiot.com>
9869
9870         * m4/c-bs-a.m4: Removed.
9871
9872 2006-06-29  Derek R. Price  <derek@ximbiot.com>
9873
9874         * lib/strftime.c: Assume strftime() exists.
9875
9876 2006-06-29  Derek Price  <derek@ximbiot.com>
9877
9878         * modules/c-bs-a: Removed - \a is C89.
9879         * MODULES.html.sh: Remove c-bs-a.
9880
9881 2006-06-29  Bruno Haible  <bruno@clisp.org>
9882
9883         * modules/wcwidth (License): Change to LGPL.
9884
9885 2006-06-28  Simon Josefsson  <jas@extundo.com>
9886
9887         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
9888         on _WIN32.
9889
9890         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
9891         getnameinfo.
9892
9893 2006-06-28  Simon Josefsson  <jas@extundo.com>
9894
9895         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
9896
9897 2006-06-28  Simon Josefsson  <jas@extundo.com>
9898
9899         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
9900         functions there.  It will succeed on Windows XP, but on Windows
9901         2000 and (presumably) earlier, it will fail, and use the internal
9902         re-implementation.
9903         (use_win32_p): New function.
9904         (getaddrinfo): Use strtoul on servname, to support numeric ports.
9905         Support AI_NUMERICSERV to disable getservbyname.
9906         (getnameinfo): New function, only supports
9907         NI_NUMERICHOST|NI_NUMERICSERV for now.
9908
9909         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
9910         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
9911         getnameinfo.
9912
9913 2006-06-28  Eric Blake  <ebb9@byu.net>
9914
9915         * modules/wcwidth: New file.
9916         * modules/mbchar (Depends-on): Add wcwidth.
9917         * modules/mbswidth (Depends-on): Add wcwidth.
9918         * MODULES.html.sh: Add wcwidth.
9919
9920 2006-06-28  Eric Blake  <ebb9@byu.net>
9921
9922         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
9923         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
9924
9925 2006-06-28  Eric Blake  <ebb9@byu.net>
9926
9927         * lib/xvasprintf.h: Fix comments.
9928
9929 2006-06-28  Eric Blake  <ebb9@byu.net>
9930
9931         * lib/mbchar.h (wcwidth): Include wcwidth.h.
9932         * lib/mbswidth.c (wcwidth): Move from here...
9933         * lib/wcwidth.h: ...to this new file.
9934
9935 2006-06-28  Derek R. Price  <derek@ximbiot.com>
9936
9937         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
9938
9939         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
9940         it's obsolete.
9941         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
9942
9943 2006-06-28  Derek R. Price  <derek@ximbiot.com>
9944
9945         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
9946         Autoconf 2.60 says this stuff was obsolete.
9947
9948 2006-06-28  Bruno Haible  <bruno@clisp.org>
9949
9950         * modules/wcwidth (Files): Add m4/wchar_t.m4.
9951
9952 2006-06-28  Bruno Haible  <bruno@clisp.org>
9953
9954         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
9955         gt_TYPE_WCHAR_T.
9956
9957 2006-06-28  Bruno Haible  <bruno@clisp.org>
9958
9959         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
9960         declaration for wcwidth.
9961         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
9962
9963 2006-06-28  Bruno Haible  <bruno@clisp.org>
9964
9965         * lib/mkdtemp.c [MINGW]: Include <io.h>.
9966         (mkdir): Define using _mkdir.
9967
9968 2006-06-28  Bruno Haible  <bruno@clisp.org>
9969
9970         * lib/getaddrinfo.h: Fix POSIX URL.
9971         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
9972         _WIN32.
9973         (use_win32_p): Make static.
9974         (getaddrinfo): Reject service name if it is empty or does not consist
9975         solely of decimal digits, or if its value is > 65535.
9976         (getnameinfo): Remove useless casts.
9977
9978 2006-06-27  Simon Josefsson  <jas@extundo.com>
9979
9980         * modules/sys_select: New file, suggested by Bruno Haible, Paul
9981         Eggert and Martin Lambers.
9982
9983 2006-06-27  Simon Josefsson  <jas@extundo.com>
9984
9985         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
9986         Eggert and Martin Lambers.
9987
9988 2006-06-27  Bruno Haible  <bruno@clisp.org>
9989
9990         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
9991         result to 0, not to empty.
9992         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
9993
9994 2006-06-27  Bruno Haible  <bruno@clisp.org>
9995
9996         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
9997
9998 2006-06-26  Simon Josefsson  <jas@extundo.com>
9999
10000         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
10001         present.
10002
10003 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
10004
10005         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
10006         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
10007         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
10008
10009 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
10010
10011         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
10012
10013 2006-06-26  Bruno Haible  <bruno@clisp.org>
10014
10015         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
10016
10017 2006-06-26  Bruno Haible  <bruno@clisp.org>
10018
10019         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
10020
10021 2006-06-26  Bruno Haible  <bruno@clisp.org>
10022
10023         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
10024         SGI C compiler in pre-C99 mode.
10025         Suggested by Mark D. Baushke and Larry Jones.
10026
10027 2006-06-26  Bruno Haible  <bruno@clisp.org>
10028
10029         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
10030         WCHAR_MAX.
10031         Reported by Mark D. Baushke and Larry Jones.
10032
10033 2006-06-26  Bruno Haible  <bruno@clisp.org>
10034
10035         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
10036         in pre-C99 mode.
10037         Suggested by Mark D. Baushke and Larry Jones.
10038
10039 2006-06-23  Simon Josefsson  <jas@extundo.com>
10040             Bruno Haible  <bruno@clisp.org>
10041
10042         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
10043         Emit mostlyclean-local rule.
10044         (func_emit_tests_Makefile_am): Likewise.
10045         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
10046
10047 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
10048
10049         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
10050
10051 2006-06-23  Bruno Haible  <bruno@clisp.org>
10052
10053         * tests/test-stdint.c: Update to match ISO C 99 Technical
10054         Corrigendum 1.
10055
10056 2006-06-23  Bruno Haible  <bruno@clisp.org>
10057
10058         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
10059
10060 2006-06-23  Bruno Haible  <bruno@clisp.org>
10061
10062         * lib/stdint_.h: Treat IRIX like OpenBSD.
10063
10064 2006-06-23  Bruno Haible  <bruno@clisp.org>
10065
10066         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
10067         ISO C 99 Technical Corrigendum 1.
10068
10069 2006-06-22  Simon Josefsson  <jas@extundo.com>
10070
10071         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
10072         MinGW.
10073
10074 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
10075
10076         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
10077         needed.  Some compiler complained about some of them.  Problem reported
10078         by Larry Jones in
10079         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
10080
10081 2006-06-21  Simon Josefsson  <jas@extundo.com>
10082
10083         * tests/test-getaddrinfo.c: New file.
10084
10085         * modules/getaddrinfo-tests: New file.
10086
10087         * MODULES.html.sh: Add inet_pton.
10088
10089         * modules/inet_pton: New file.
10090
10091 2006-06-21  Simon Josefsson  <jas@extundo.com>
10092
10093         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
10094         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
10095         of using the (limited) gnulib implementation on Windows XP.
10096
10097         * m4/inet_pton.m4: New file.
10098
10099 2006-06-21  Simon Josefsson  <jas@extundo.com>
10100
10101         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
10102         variable.
10103
10104         * lib/socket_.h: Don't define WINVER.
10105
10106         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
10107         slightly modified to work in gnulib.
10108
10109 2006-06-21  Simon Josefsson  <jas@extundo.com>
10110
10111         * doc/gnulib.texi (Windows sockets): Add.
10112
10113 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
10114
10115         * lib/read-file.c (fread_file): Start with buffer allocation of
10116         0 bytes rather than 1 byte; this simplifies the code.
10117         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
10118         code to free buffer and save/restore errno.
10119         (internal_read_file): Remove unused local.
10120
10121 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
10122
10123         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
10124         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
10125         Problem reported by Denis Excoffier in
10126         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
10127
10128 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10129
10130         * modules/sys_socket, modules/socklen: Include sys/types since
10131         FreeBSD 4.x's sys/socket.h needs it.
10132
10133 2006-06-19  Simon Josefsson  <jas@extundo.com>
10134
10135         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
10136
10137 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10138
10139         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
10140
10141 2006-06-19  Bruno Haible  <bruno@clisp.org>
10142
10143         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
10144         and FULL_PATH_INTTYPES_H in angle brackets.
10145         Reported by Mark D. Baushke <mdb@gnu.org>.
10146
10147 2006-06-17  Eric Blake  <ebb9@byu.net>
10148
10149         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
10150         errno.
10151
10152 2006-06-17  Bruno Haible  <bruno@clisp.org>
10153
10154         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
10155         <sys/inttypes.h>.
10156
10157 2006-06-17  Bruno Haible  <bruno@clisp.org>
10158
10159         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
10160         whether errno is declared. Assume <errno.h> declares errno.
10161
10162 2006-06-17  Bruno Haible  <bruno@clisp.org>
10163
10164         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
10165
10166 2006-06-17  Bruno Haible  <bruno@clisp.org>
10167
10168         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
10169         problem on Solaris 2.5.1.
10170
10171 2006-06-16  Eric Blake  <ebb9@byu.net>
10172
10173         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
10174         * lib/unicodeio.c [!defined errno]: Likewise.
10175         * lib/strtol.c [!defined errno]: Likewise.
10176         * lib/strtod.c [!defined errno]: Likewise.
10177
10178 2006-06-15  Eric Blake  <ebb9@byu.net>
10179
10180         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
10181
10182 2006-06-15  Eric Blake  <ebb9@byu.net>
10183
10184         * config/srclist.txt (ssize_t.m4): Lose sync.
10185
10186 2006-06-15  Bruno Haible  <bruno@clisp.org>
10187
10188         * modules/stdint (Files): Include m4/full-header-path.m4,
10189         m4/size_max.m4, m4/wchar_t.m4.
10190         (Makefile.am): Many more substitutions.
10191         * modules/stdint-tests: New file.
10192         * tests/test-stdint.c: New file.
10193
10194 2006-06-15  Bruno Haible  <bruno@clisp.org>
10195
10196         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
10197         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
10198         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
10199         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
10200         gl_CHECK_TYPE_SAME): New macros.
10201
10202 2006-06-15  Bruno Haible  <bruno@clisp.org>
10203
10204         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
10205
10206 2006-06-15  Bruno Haible  <bruno@clisp.org>
10207
10208         * lib/stdint_.h: Rewritten to be fully auto-configured.
10209         Fixes bug on HP-UX/IA64.
10210
10211 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
10212
10213         * lib/getdate.y (__attribute__): Don't define if already defined.
10214         Problem reported by Larry Jones.
10215         * lib/utimens.c (__attribute__): Likewise.
10216
10217 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
10218
10219         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
10220         reported by Andreas Schwab.
10221
10222 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10223             Bruno Haible  <bruno@clisp.org>
10224
10225         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
10226         check for the declaration of strnlen and a run test that exposes the
10227         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
10228         rpl_strndup.
10229
10230 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10231             Bruno Haible  <bruno@clisp.org>
10232
10233         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
10234
10235 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10236
10237         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
10238         compile test, for Tru64 4.0D.
10239
10240 2006-05-28  Karl Berry  <karl@gnu.org>
10241
10242         * config/srclist.txt (printf-args.c): lose sync.
10243
10244 2006-05-26  Martin Lambers  <marlam@marlam.de>
10245
10246         * lib/getpass.c: Updates the test for the native W32 API, and adds
10247         missing includes, thus fixing compilation warnings.
10248
10249 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
10250
10251         * lib/exclude.c (exclude_fnmatch): New function.
10252         (excluded_file_name): Call exclude_fnmatch.
10253         * lib/exclude.h (excluded_file_name): New prototype
10254
10255 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
10256
10257         * lib/tempname.c (small_open, large_open): New macros.
10258         (__open, __open64) [!_LIBC]: Remove.
10259         (__gen_tempname): Use small_open and large_open instead of __open
10260         and __open64.  This fixes a portability bug on HP-UX 11.11i
10261         reported by Simon Wing-Tang in
10262         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
10263
10264 2006-05-24  Bruno Haible  <bruno@clisp.org>
10265
10266         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
10267         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
10268         Reported by Thorsten Maerz <torte@netztorte.de> via
10269         Aaron Stone <aaron@serendipity.cx>.
10270
10271 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10272
10273         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
10274         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
10275         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
10276         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
10277         not really conditional on the cache.
10278         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
10279
10280 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10281
10282         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
10283         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
10284         (my_usleep): Don't mishandle maximum value.
10285
10286 2006-05-19  Jim Meyering  <jim@meyering.net>
10287
10288         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
10289
10290 2006-05-17  Bruno Haible  <bruno@clisp.org>
10291
10292         Cygwin portability.
10293         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
10294
10295 2006-05-17  Bruno Haible  <bruno@clisp.org>
10296
10297         * lib/stdint_.h: Fix recognition of Cygwin.
10298
10299 2006-05-15  Bruno Haible  <bruno@clisp.org>
10300
10301         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
10302         on libtool patch by Ralf Wildenhues.
10303
10304 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
10305
10306         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
10307         test for C99 conformance; (bool) 0.5 is an integer constant
10308         expression, but (bool) -0.5 is not.  Problem reported by Fedor
10309         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
10310
10311 2006-05-11  Simon Josefsson  <jas@extundo.com>
10312
10313         * m4/xvasprintf.m4: Fix obvious typo.
10314
10315 2006-05-11  Jim Meyering  <jim@meyering.net>
10316
10317         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
10318         James Lemley.
10319
10320 2006-05-10  Simon Josefsson  <jas@extundo.com>
10321
10322         * lib/md4.c: Typo fix, update copyright years.
10323         (K1, K2): Don't use L because it turn computations into 64-bit on
10324         64-bit platforms.
10325
10326 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
10327
10328         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
10329         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
10330         unwanted sign propagation, e.g., on hosts with 64-bit int.
10331         There still are some problems with reeelly weird theoretical hosts
10332         (e.g., 33-bit int) but it's not worth worrying about now.
10333         * lib/sha1.c (rol): Likewise.
10334         (K1, K2, K3, K4): Remove unnecessary L suffix.
10335
10336 2006-05-10  Bruno Haible  <bruno@clisp.org>
10337
10338         * lib/des.c: Cast to avoid warnings.
10339
10340 2006-05-09  Bruno Haible  <bruno@clisp.org>
10341
10342         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
10343         (Depends-on): Depend also on xsize, stdarg.
10344         (configure.ac): Add gl_XVASPRINTF.
10345
10346 2006-05-09  Bruno Haible  <bruno@clisp.org>
10347
10348         * m4/xvasprintf.m4: New file.
10349
10350 2006-05-09  Bruno Haible  <bruno@clisp.org>
10351
10352         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
10353         (EOVERFLOW): Define fallback value.
10354         (xstrcat): New function.
10355         (xvasprintf): Recognize the special case of a string concatenation.
10356
10357 2006-05-08  Eric Blake  <ebb9@byu.net>
10358
10359         * gnulib-tool (func_version): Base copyright year on CVS date.
10360         (func_emit_copyright_notice): New function.
10361         (func_emit_lib_Makefile_am): Use it.
10362         (func_emit_tests_Makefile_am): Likewise.
10363         (func_import): Likewise.
10364
10365 2006-05-08  Bruno Haible  <bruno@clisp.org>
10366
10367         * modules/stdarg: New file.
10368         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
10369
10370 2006-05-08  Bruno Haible  <bruno@clisp.org>
10371
10372         * m4/stdarg.m4: New file, from GNU gettext.
10373
10374 2006-05-08  Bruno Haible  <bruno@clisp.org>
10375
10376         * config/srclist.txt (build-aux/config.rpath): different from latest
10377         release.
10378
10379 2006-05-08  Bruno Haible  <bruno@clisp.org>
10380
10381         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
10382
10383 2006-05-05  Jim Meyering  <jim@meyering.net>
10384
10385         * m4/warning.m4: New file, derived from bison's file by the same name.
10386
10387 2006-05-03  Bruno Haible  <bruno@clisp.org>
10388
10389         * lib/stdint_.h: Shorter URL.
10390         * lib/inttypes.h: Likewise.
10391
10392 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10393
10394         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
10395
10396 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10397
10398         * lib/verify.h: Document the internals better.  Most of this change
10399         was written by Bruno Haible.
10400
10401 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10402
10403         * doc/verify.texi: New file, partly based on a proposal by
10404         Bruno Haible.
10405
10406 2006-05-02  Bruno Haible  <bruno@clisp.org>
10407
10408         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
10409         test from here...
10410         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
10411
10412 2006-04-29  Bruno Haible  <bruno@clisp.org>
10413
10414         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
10415         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
10416
10417 2006-04-29  Bruno Haible  <bruno@clisp.org>
10418
10419         * gnulib-tool: Make --update option actually work.
10420
10421 2006-04-29  Bruno Haible  <bruno@clisp.org>
10422
10423         * doc/gcd.texi: New file.
10424         * doc/gnulib.texi: Include it.
10425
10426 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
10427
10428         * lib/getdate.y (get_date): When adding relative date, start with the
10429         initial time, not with the result of the first mktime call.
10430
10431 2006-04-25  Bruno Haible  <bruno@clisp.org>
10432
10433         * gnulib-tool (func_import): Output the include directives in three
10434         blocks, sorted separately.
10435         Reported by Ben Pfaff <blp@cs.stanford.edu>.
10436
10437 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
10438
10439         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
10440         to define main with arguments, for C++.  Reported by Eric Blake.
10441         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
10442         Prefer 'int main ()' to 'int main (void)', for C++.
10443         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
10444         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
10445         for 'main', for C99 and C++.
10446
10447 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
10448
10449         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
10450         Don't assume that exit status -1 is valid.
10451         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
10452         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
10453         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
10454         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
10455         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
10456         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
10457         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
10458         functions can be used without declaring them, or that you can
10459         exit with status -1.
10460         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
10461
10462 2006-04-24  Karl Berry  <karl@gnu.org>
10463
10464         * config/srclist.txt (longdouble.m4): sync lost.
10465
10466 2006-04-24  Eric Blake  <ebb9@byu.net>
10467
10468         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
10469
10470 2006-04-24  Bruno Haible  <bruno@clisp.org>
10471
10472         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
10473         poll() implementation in AIX.
10474         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10475
10476 2006-04-24  Bruno Haible  <bruno@clisp.org>
10477
10478         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
10479         assigned exactly once.
10480
10481 2006-04-23  Claudio Fontana  <claudio@gnu.org>
10482             Bruno Haible  <bruno@clisp.org>
10483
10484         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
10485         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
10486         for AM_CPPFLAGS.
10487
10488 2006-04-23  Bruno Haible  <bruno@clisp.org>
10489
10490         * modules/copy-file: Depend on unistd.
10491         * modules/execute: Likewise.
10492         * modules/fatal-signal: Likewise.
10493         * modules/findprog: Likewise.
10494         * modules/mkdtemp : Likewise.
10495         * modules/pipe: Likewise.
10496         * modules/wait-process: Likewise.
10497
10498 2006-04-23  Bruno Haible  <bruno@clisp.org>
10499
10500         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
10501         condition was already detected.
10502         Reported by Ben Pfaff <blp@cs.stanford.edu>.
10503
10504 2006-04-23  Bruno Haible  <bruno@clisp.org>
10505
10506         * lib/copy-file.c: Include <unistd.h> unconditionally.
10507         * lib/execute.c: Likewise.
10508         * lib/fatal-signal.c: Likewise.
10509         * lib/findprog.c: Likewise.
10510         * lib/mkdtemp.c: Likewise.
10511         * lib/pipe.h: Likewise.
10512         * lib/pipe.c: Likewise.
10513         * lib/wait-process.h: Likewise.
10514
10515 2006-04-23  Bruno Haible  <bruno@clisp.org>
10516
10517         * gnulib-tool (func_usage): Fix --import description. Document
10518         --update.
10519         (func_import): Create temporary file in a temporary directory, if
10520         --dry-run is specified. Silence errors from 'grep' when there are no
10521         m4 files in $m4dir.
10522         (func_create_testdir): Silence errors from 'grep' when there are no
10523         m4 files in $m4dir.
10524         Reported by Karl Berry <karl@freefriends.org>.
10525
10526 2006-04-20  Bruno Haible  <bruno@clisp.org>
10527
10528         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
10529         one argument, so that the code will be portable to Autoconf 2.60.
10530         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
10531         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
10532         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
10533
10534 2006-04-19  Derek Price  <derek@ximbiot.com>
10535             Eric Blake  <ebb9@byu.net>
10536
10537         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
10538         rather than "/full/path.h".  Update comment to match.  Shorten &
10539         generalize m4_translit call via AS_TR_CPP.
10540
10541 2006-04-19  Derek Price  <derek@ximbiot.com>
10542             Eric Blake  <ebb9@byu.net>
10543
10544         * lib/inttypes.h: Correct grammar in comment.
10545
10546 2006-04-18  Derek Price  <derek@ximbiot.com>
10547             Paul Eggert  <eggert@cs.ucla.edu>
10548
10549         * modules/inttypes: New file.
10550         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
10551
10552 2006-04-18  Derek Price  <derek@ximbiot.com>
10553             Paul Eggert  <eggert@cs.ucla.edu>
10554
10555         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
10556         New files.
10557
10558 2006-04-18  Derek Price  <derek@ximbiot.com>
10559             Paul Eggert  <eggert@cs.ucla.edu>
10560
10561         * lib/inttypes.h: New file.
10562         * lib/strtoimax.c: Assume <inttypes.h>.
10563
10564 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
10565
10566         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
10567         isn't mounted.  Problem reported by Kir Kolyshkin.
10568
10569 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
10570
10571         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
10572         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
10573         Derek R. Price.
10574         * lib/regex.h (RE_DUP_MAX): Update comment to match current
10575         implementation.
10576
10577 2006-04-12  Eric Blake  <ebb9@byu.net>
10578
10579         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
10580         is now done automatically by the corresponding Autoconf macro.
10581
10582 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
10583
10584         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
10585         time_r.h.
10586
10587 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
10588
10589         Merge regex changes from libc, removing some of our
10590         POSIX-conformance changes that were rejected and redoing them in a
10591         less-intrusive way.
10592
10593         * lib/regcomp.c (re_compile_internal, init_dfa):
10594         Length arg is now size_t, not Idx.  All uses changed.
10595         (peek_token): Forward decl now says internal_function.
10596         (__re_error_msgid, __re_error_msgid_idx):
10597         Now static rather than extern with attribute_hidden.
10598         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
10599         For some reason libc prefers K&R style defns for external functions.
10600         (regerror) [!defined _LIBC]: Likewise.
10601         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
10602         (seek_collating_symbol_entry, lookup_collation_sequence_value):
10603         (build_range_exp, build_collating_symbol):
10604         Use K&R-style defn.
10605         (re_compile_fastmap): Use '\0' to memset, not 0.
10606         (utf8_sb_map): Make the calculations more obvious.
10607         (init_dfa, parse_bracket_exp, build_charclass_op):
10608         Call calloc and cast result, as glibc does.
10609         (init_word_char, fetch_token, peek_token, peek_token_bracket):
10610         (build_range_exp, build_collating_symbol):
10611         Now internal functions.
10612
10613         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
10614
10615         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
10616         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
10617         Don't depend on VMS; depend on __VMS instead, for POSIX
10618         namespace cleanness.
10619         (regoff_t): Define to ssize_t, not long int.
10620
10621         Remove the REG_ macros named below.  Instead, make the old names
10622         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
10623         __USE_GNU_REGEX.
10624         (REG_BACKSLASH_ESCAPE_IN_LISTS):
10625         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
10626         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
10627         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
10628         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
10629         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
10630         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
10631         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
10632         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
10633         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
10634         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
10635         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
10636         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
10637         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
10638         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
10639         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
10640         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
10641         (REG_NREGS):
10642         Remove.  All uses replaced by the old RE_* names.
10643         (RE_BACKSLASH_ESCAPE_IN_LISTS):
10644         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
10645         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
10646         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
10647         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
10648         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
10649         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
10650         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
10651         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
10652         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
10653         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
10654         Don't bother having these macros be independent of each others'
10655         values, since they no longer exist in the POSIX name space.
10656
10657         Rename the following member names back to their old names,
10658         unless !__USE_GNU_REGEX.  All uses changed back.
10659         (buffer): Renamed from re_buffer.
10660         (allocated): Renamed from re_allocated.
10661         (used): Renamed from re_used.
10662         (syntax): Renamed from re_syntax.
10663         (fastmap): Renamed from re_fastmap.
10664         (translate): Renamed from re_translate.
10665         (can_be_null): Renamed from re_can_be_null.
10666         (regs_allocated): Renamed from re_regs_allocated.
10667         (fastmap_accurate): Renamed from re_fastmap_accurate.
10668         (no_sub): Renamed from re_no_sub.
10669         (not_bol): Renamed from re_not_bol.
10670         (not_eol): Renamed from re_not_eol.
10671         (newline_anchor): Renamed from re_newline_anchor.
10672         (num_regs): Renamed from rm_num_regs.
10673         (start): Renamed from rm_start.
10674         (end): Renamed from rm_end.
10675
10676         (free_state): Move up a bit.
10677
10678         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
10679         #define to be empty.
10680         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
10681         when that is what is intended.
10682         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
10683         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
10684         (MAX): New macro.
10685         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
10686         All uses changed back to re_malloc, etc.  It's now the caller's
10687         responsibility to check for overflow; all callers changed.
10688         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
10689         (re_x2nrealloc): Remove.
10690         (free_state): Remove decl.
10691
10692         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
10693         (re_set_registers, re_exec):
10694         Use K&R-style defn.
10695
10696         2006-01-31  Roland McGrath  <roland@redhat.com>
10697
10698         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
10699         Reported by Mike Frysinger <vapier@gentoo.org>.
10700
10701         2006-01-15  Andreas Jaeger  <aj@suse.de>
10702
10703         [BZ #1950]
10704         * lib/regex_internal.c (re_string_reconstruct): Adjust for
10705         build_wcs_upper_buffer change.
10706         (build_wcs_upper_buffer): Change return type.
10707
10708         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
10709
10710         * lib/regex_internal.h: Include <stdint.h> if available.
10711
10712         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
10713
10714         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
10715
10716         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
10717
10718         * lib/regcomp.c: Adjust for changed secondary hash function.
10719
10720         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
10721
10722         * lib/regex.h: Pretty printing.
10723         Clean up namespace a bit.
10724
10725         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
10726
10727         * lib/regexec.c (update_cur_sifted_state, check_arrival,
10728         check_arrival_add_next_nodes): Avoid using uninitialized variable.
10729
10730         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10731                     Ulrich Drepper  <drepper@redhat.com>
10732
10733         [BZ #1302]
10734         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
10735         changed.
10736         (bitset_word_t): Renamed from bitset_word.  All uses changed.
10737
10738         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
10739
10740         [BZ #281]
10741         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
10742         * lib/regcomp.c: Remove unnecessary uses of
10743         unsigned RE_TRANSLATE_TYPE.
10744         * lib/regex_internal.h: Likewise.
10745         * lib/regex_internal.c: Likewise.
10746         * lib/regexec.c: Likewise.
10747         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
10748
10749         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
10750
10751         * lib/regexec.c (find_recover_state): Remove unnecessary
10752         initialization.
10753         (transit_state_bkref): Make DFA a const pointer.
10754         (get_subexp): Likewise.
10755         (check_arrival): Likewise.
10756         (update_cur_sifted_state): Likewise.
10757         (re_search_internal): Likewise.
10758         (prune_impossible_nodes): Likewise.
10759         (acquire_init_state_context): Likewise.
10760         (proceed_next_node): Likewise.
10761         (set_regs): Likewise.
10762         (free_fail_stack_return): Likewise.
10763         (check_arrival_expand_ecl): Mark DFA parameter as const.
10764         (check_arrival_expand_ecl_sub): Likewise.
10765         (check_subexp_limits): Likewise.
10766         (sub_epsilon_src_nodes):  Likewise.
10767         (add_epsilon_src_nodes):  Likewise.
10768         (merge_state_array): Likewise.
10769         (update_regs): Likewise.
10770         (build_trtable): Likewise.
10771         (sift_states_backward): Mark MCTX parameter as const.
10772         (build_sifted_states): Likewise.
10773         (update_cur_sifted_state): Likewise.
10774         (sift_states_mkref): Likewise.
10775         (check_arrival_expand_ecl): Mark eclosure as const.
10776         (check_dst_limits_calc_pos_1): Likewise.
10777         * lib/regex_internal.h (re_match_context_t): Make dfa a const
10778         pointer.
10779
10780         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
10781
10782         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
10783         (transit_state_sb): Likewise.
10784         (transit_state_mb): Likewise.
10785         (sift_states_iter_mb): Likewise.
10786         (check_arrival_add_next_nodes): Likewise.
10787         (check_node_accept_bytes): Change first parameter to pointer-to-const.
10788         [_LIBC] (re_search_2_stub): Use mempcpy.
10789
10790         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
10791         mbrtowc for very simple UTF-8 case.
10792
10793         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
10794         a pointer-to-const.
10795         (re_acquire_state_context): Likewise.
10796         * lib/regex_internal.h: Adjust prototypes.
10797
10798         * lib/regex.c: Prevent using C++ compilers.
10799
10800         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
10801         (re_acquire_state_context): Likewise.
10802
10803 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
10804
10805         * modules/regex (Depends-on): Add ssize_t.
10806
10807 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
10808
10809         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
10810         translation table.
10811
10812 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
10813
10814         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
10815
10816 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
10817             Bruno Haible  <bruno@clisp.org>
10818
10819         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
10820         <sys/types.h> and <inttypes.h>.
10821
10822 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10823
10824         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
10825         `__error_t_defined', so argp.h will not typedef the former.
10826
10827 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
10828
10829         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
10830         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
10831         glibc names.  Even if glibc is changed to conform to POSIX, the
10832         traditional names will be available anyway, since regex depends on
10833         the extensions module.  Also, fix a longstanding typo in the
10834         implementation of Spencer ERE test #75 from grep 2.3.  Problems
10835         reported by Emanuele Giaquinta.  Also, change sense of cached
10836         variable, so that the message makes sense.
10837
10838 2006-03-24  Simon Josefsson  <jas@extundo.com>
10839
10840         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
10841         including some doc fixes.
10842         (base64_encode_alloc): Fix +1 bug on allocation failures.
10843
10844 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10845
10846         * lib/base64.c (base64_encode): Do not read past end of array with
10847         unsanitized input on systems with CHAR_BIT > 8.
10848
10849 2006-03-24  Eric Blake  <ebb9@byu.net>
10850
10851         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
10852
10853 2006-03-22  Karl Berry  <karl@gnu.org>
10854
10855         * config/srclist.txt (*setenv.[ch]): get from coreutils.
10856         * config/srclistvars.sh (COREUTILS): new var.
10857
10858 2006-03-17  Jim Meyering  <jim@meyering.net>
10859
10860         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
10861         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
10862
10863 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
10864
10865         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
10866         no longer needs it.  Instead, check that regoff_t is as least
10867         as wide as ptrdiff_t.
10868
10869         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
10870         so that our regex.h stays compatible with the installed regex.
10871         This is helpful for installers who configure --without-included-regex.
10872         Problem reported by Emanuele Giaquinta.
10873
10874 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
10875
10876         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
10877         Typedef to long int, not to off_, as POSIX will likely change
10878         in that direction.
10879
10880 2006-03-15  Eric Blake  <ebb9@byu.net>
10881
10882         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
10883
10884 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
10885
10886         * lib/argp-help.c (validate_uparams): Fix typo
10887         * lib/argp-parse.c (argp_default_options): Consistently begin help
10888         messages with a lowercase letter.
10889
10890 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
10891
10892         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
10893         overrun buffers and shouldn't be used (much as gets shouldn't be
10894         used).
10895         * lib/time_r.c (asctime_r, ctime_r): Likewise.
10896
10897 2006-03-08  Simon Josefsson  <jas@extundo.com>
10898
10899         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
10900         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10901
10902 2006-03-08  Simon Josefsson  <jas@extundo.com>
10903
10904         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
10905         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10906
10907 2006-03-08  Simon Josefsson  <jas@extundo.com>
10908
10909         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
10910         signal that configure disabled the device.
10911
10912 2006-03-08  Simon Josefsson  <jas@extundo.com>
10913
10914         * build-aux/maint.mk: Fix refresh-po, to handle no translated
10915         languages.
10916
10917 2006-03-07  Simon Josefsson  <jas@extundo.com>
10918
10919         * modules/getopt (Depends-on): Add unistd.
10920
10921         * modules/unistd: New file.
10922
10923 2006-03-07  Simon Josefsson  <jas@extundo.com>
10924
10925         * modules/gc-random: New file.
10926
10927 2006-03-07  Simon Josefsson  <jas@extundo.com>
10928
10929         * m4/unistd_h.m4: New file.
10930
10931 2006-03-07  Simon Josefsson  <jas@extundo.com>
10932
10933         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
10934         test to be side-effect free by storing the result in the cache
10935         variable gl_cv_lib_readline, and moving the assignment of
10936         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
10937         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10938
10939 2006-03-07  Simon Josefsson  <jas@extundo.com>
10940
10941         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
10942         error on missing devices (the functions will return an error).
10943
10944         * m4/gc.m4: Move random stuff to gc-random.m4
10945
10946 2006-03-07  Simon Josefsson  <jas@extundo.com>
10947
10948         * lib/unistd_.h: New file.
10949
10950 2006-03-07  Simon Josefsson  <jas@extundo.com>
10951
10952         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
10953
10954 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
10955
10956         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
10957         Problem reported by Juan Manuel Guerrero.
10958
10959 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
10960
10961         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
10962         the unistd module.
10963         * lib/getlogin_r.c: Likewise.
10964         * lib/getlogin_r.h: Likewise.
10965         * lib/glob.c: Likewise.
10966         * lib/pagealign_alloc.c: Likewise.
10967         * lib/unistd_.h: Remove; no longer needed.
10968
10969 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
10970
10971         * MODULES.html.sh (Support for systems lacking POSIX:2001):
10972         Add unistd.
10973         * modules/c-stack (Depends-on): Add unistd.
10974         * modules/getlogin_r: Likewise.
10975         * modules/glob: Likewise.
10976         * modules/pagealign_alloc: Likewise.
10977         * modules/unistd (Files): Remove lib/unistd_.h.
10978         (EXTRA_DIST): Remove.
10979         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
10980         need unistd_.h.
10981         (MOSTLYCLEANFILES): Remove unistd.h-t.
10982
10983 2006-03-03  Simon Josefsson  <jas@extundo.com>
10984
10985         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
10986
10987 2006-03-03  Simon Josefsson  <jas@extundo.com>
10988
10989         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
10990         libidn and bison.
10991
10992 2006-03-03  Simon Josefsson  <jas@extundo.com>
10993
10994         * build-aux/maint.mk: Add indent target.
10995
10996 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
10997
10998         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
10999         our replacement poll.h in any case, to avoid a differing
11000         declaration from a system header.  Seen on AIX.
11001
11002 2006-03-01  Simon Josefsson  <jas@extundo.com>
11003
11004         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
11005         <kasal@ucw.cz>.
11006
11007 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11008
11009         * modules/gettime (Depends-on): Add extensions module.
11010         * modules/nanosleep (Depends-on): Likewise.
11011         * modules/settime (Depends-on): Likewise.
11012
11013 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11014
11015         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
11016         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
11017         pedantically.
11018         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11019         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
11020
11021         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
11022         not "==".  Reported by Ralf Wildenhues.
11023
11024 2006-03-01  Karl Berry  <karl@gnu.org>
11025
11026         * doc/Copyright/request-*: new files, synced from gnuorg.
11027
11028 2006-03-01  Karl Berry  <karl@gnu.org>
11029
11030         * config/srclist.txt (Copyright/*): new entries.
11031
11032 2006-02-28  Simon Josefsson  <jas@extundo.com>
11033
11034         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
11035
11036 2006-02-27  Simon Josefsson  <jas@extundo.com>
11037
11038         * lib/base64.h: Indent #define's.  From Jim Meyering
11039         <jim@meyering.net>.
11040
11041 2006-02-27  Jim Meyering  <jim@meyering.net>
11042
11043         Revert the change of 2006-02-24, so these files can continue
11044         to be sync'd from gettext.
11045         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
11046         of `config.h'.
11047
11048 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
11049
11050         * modules/intprops: New file.
11051         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
11052         Add intprops.
11053         * modules/getloadavg (Files): Remove lib/intprops.h.
11054         (Depends-on): Add intprops.
11055         * modules/human: Likewise.
11056         * modules/inttostr: Likewise.
11057         * modules/openat: Likewise.
11058         * modules/sig2str: Likewise.
11059         * modules/userspec: Likewise.
11060         * modules/utimecmp: Likewise.
11061         * modules/xnanosleep: Likewise.
11062         * modules/xstrtol: Likewise.
11063
11064 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
11065
11066         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
11067         * modules/lock-tests (TESTS): Use $(EXEEXT).
11068         * modules/tls-tests: Likewise.
11069         * modules/argp-tests: Likewise.
11070         (check_PROGRAMS): New var, replacing...
11071         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
11072
11073 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11074
11075         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
11076         `config.h'.
11077
11078 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
11079
11080         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
11081
11082 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11083
11084         Sync from coreutils.
11085         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
11086         gl_CHDIR_SAFER.
11087
11088 2006-02-22  Jim Meyering  <jim@meyering.net>
11089
11090         Sync from coreutils.
11091         * m4/chdir-safer.m4: New file.
11092
11093 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
11094
11095         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
11096         AT_FDCWD exceeds INT_MAX.
11097         * lib/openat.h (AT_FDCWD): Likewise.
11098
11099 2006-02-17  Eric Blake  <address@hidden>
11100
11101         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
11102
11103 2006-02-16  Simon Josefsson  <jas@extundo.com>
11104
11105         * modules/getaddrinfo (Depends-on): Add sys_socket.
11106
11107 2006-02-15  Simon Josefsson  <jas@extundo.com>
11108
11109         * build-aux/maint.mk: Add dsyntax-check rule.
11110
11111 2006-02-15  Eric Blake  <ebb9@byu.net>
11112
11113         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
11114         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
11115         'present but cannot compile' warnings on cygwin.
11116         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
11117         use ws2tcpip.h if sys/socket.h works.
11118         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
11119         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
11120
11121 2006-02-14  Simon Josefsson  <jas@extundo.com>
11122
11123         * modules/maintainer-makefile (Files): Rename.
11124
11125         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
11126         and (the local) Makefile.cfg to maint-cfg.mk.
11127
11128         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
11129         to the latter.
11130
11131         * modules/maintainer-makefile: New module.
11132
11133         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
11134         severaly stripped to make it possible to build it up from scratch
11135         with reliable tests.
11136
11137         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
11138         fixes to permit overriding the default actions when configure and
11139         makefile are not available.
11140
11141 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
11142
11143         Sync from coreutils.
11144         * modules/lstat (Depends-on): Don't depend on xalloc.
11145         (License): Change from GPL to LGPL, since this is now simply a
11146         replacement for a libc function.
11147
11148 2006-02-14  Jim Meyering  <jim@meyering.net>
11149
11150         Sync from coreutils.
11151
11152         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
11153         failure on deficient systems, and simplify gnulib lgpl dependencies.
11154         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
11155         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
11156
11157         * lib/xalloc-die.c: Remove unused definition of N_.
11158
11159 2006-02-14  Jim Meyering  <jim@meyering.net>
11160
11161         Sync from coreutils.
11162         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
11163         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
11164         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
11165         double-quote uses of that variable, to accommodate the rare case in
11166         which getmntent is available in none of the libraries checked.  This
11167         happens at least on FreeBSD 5.0.
11168
11169 2006-02-13  Simon Josefsson  <jas@extundo.com>
11170
11171         * gnulib-tool (Usage): Fix --import, from
11172         karl@freefriends.org (Karl Berry).
11173
11174 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
11175
11176         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
11177
11178 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
11179
11180         * lib/argp-namefrob.h: Restore changes accidentally lost during the
11181         "autoupdate" on 2005-12-12.
11182
11183 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11184
11185         * modules/closeout (Depends-on): Remove atexit.
11186
11187 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11188
11189         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
11190         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
11191
11192 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
11193
11194         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
11195         __EXTENSIONS__ if this causes compilation to fail.  Problem
11196         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
11197         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
11198
11199 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
11200
11201         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
11202         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
11203         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
11204         All uses changed.
11205
11206 2006-01-26  Simon Josefsson  <jas@extundo.com>
11207
11208         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
11209         prototype is visible on mingw32.
11210
11211         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
11212         for mingw32.
11213
11214         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
11215         mingw32).
11216
11217 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
11218
11219         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
11220         attempt to open for write; this always fails, at least on POSIX
11221         hosts.  This reinstates the 2006-01-09 change, which was
11222         inadvertently removed.
11223
11224 2006-01-26  Bruno Haible  <bruno@clisp.org>
11225
11226         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
11227         Reported by Paul Eggert.
11228
11229 2006-01-26  Bruno Haible  <bruno@clisp.org>
11230             Paul Eggert  <eggert@cs.ucla.edu>
11231
11232         * lib/stdbool_.h (_Bool)
11233         [(! (defined __cplusplus || defined __BEOS__)
11234           && !defined __GNUC__
11235           && !(defined __HP_cc || defined __xlc__
11236                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
11237                || defined __sgi))]:
11238         #define to signed char in these cases too; this simplifies
11239         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
11240         etc., separately) and makes it more conservative.
11241
11242 2006-01-25  Simon Josefsson  <jas@extundo.com>
11243
11244         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
11245         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
11246         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
11247
11248 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
11249
11250         * lib/argp-namefrob.h: Bugfix. Remove stray #
11251
11252 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
11253
11254         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
11255         so that we test the test.
11256         Check for yet another HP-UX cc bug involving *bool |= bool.
11257
11258 2006-01-25  Karl Berry  <karl@gnu.org>
11259
11260         * config/srclist.txt (vasnprintf.c): sync lost.
11261
11262 2006-01-25  Jim Meyering  <jim@meyering.net>
11263
11264         Sync from the stable (b5) branch of coreutils:
11265
11266         * lib/fts.c (fts_children): Don't let close() clobber errno from
11267         failed fchdir().
11268
11269         * lib/fts.c (fts_stat): When following a symlink-to-directory,
11270         don't necessarily interpret stat-fails+lstat-succeeds as indicating
11271         a dangling symlink.  That can also happen at least for ELOOP.
11272         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
11273         FYI, this bug predates the inclusion of fts.c in coreutils.
11274
11275         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
11276         in their own block, so pre-c99 compilers don't object.
11277
11278         Avoid the double-free (first in fts_read, second in fts_close) that
11279         would occur when an `active' directory is made inaccessible (e.g.,
11280         via chmod a-x) during a traversal.
11281         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
11282         before returning.  Reproduce this failure by
11283         mkdir -p a/b; cd a; chmod a-x . b
11284         Reported by Stavros Passas.
11285
11286 2006-01-25  Jim Meyering  <jim@meyering.net>
11287
11288         * lib/fileblocks.c: Remove more useless parentheses.
11289         * lib/readutmp.h: Likewise.
11290
11291 2006-01-25  Bruno Haible  <bruno@clisp.org>
11292
11293         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
11294         warnings.
11295         Reported by Paul Eggert.
11296
11297 2006-01-25  Bruno Haible  <bruno@clisp.org>
11298
11299         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
11300         rid of a trap command. For Solaris sh.
11301         Reported by Mark D. Baushke <mdb@gnu.org>.
11302
11303 2006-01-24  Simon Josefsson  <jas@extundo.com>
11304
11305         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
11306         Bruno.
11307
11308 2006-01-24  Karl Berry  <karl@gnu.org>
11309
11310         * config/srclist.txt (argp-namefrob.h): sync lost.
11311
11312 2006-01-24  Jim Meyering  <jim@meyering.net>
11313
11314         * modules/openat (Files): Add lib/intprops.h.
11315         From Mark D. Baushke.
11316
11317 2006-01-24  Jim Meyering  <jim@meyering.net>
11318
11319         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
11320         Reported by Mark D. Baushke.
11321
11322 2006-01-24  Jim Meyering  <jim@meyering.net>
11323
11324         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
11325
11326 2006-01-24  Bruno Haible  <bruno@clisp.org>
11327
11328         * modules/strnlen (Maintainer): Change from glibc to all.
11329
11330 2006-01-24  Bruno Haible  <bruno@clisp.org>
11331
11332         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
11333         Patch by Paul Eggert.
11334
11335 2006-01-24  Bruno Haible  <bruno@clisp.org>
11336
11337         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
11338         already has it.
11339         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
11340         2005-11-26.
11341
11342         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
11343         'signed char' to avoid problems with the built-in _Bool type.
11344         Reported by Paul Eggert on 2005-11-26.
11345
11346 2006-01-24  Bruno Haible  <bruno@clisp.org>
11347
11348         * gnulib-tool (func_import): Avoid constructing complicated sed
11349         expressions inside backquote.
11350         Report and solution by Mark D. Baushke <mdb@gnu.org>.
11351
11352 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
11353
11354         These changes imported from libc.
11355         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
11356         test and two separate function calls.
11357         * lib/strndup.c (__strndup): Add libc_hidden_def.
11358
11359 2006-01-23  Simon Josefsson  <jas@extundo.com>
11360
11361         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
11362         Remove the test_*_SOURCES variable: automake infers it by default.
11363         * modules/tls-tests: Likewise.
11364
11365 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11366
11367         Work around porting bugs reported by Dieter in
11368         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
11369         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
11370         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
11371         Include "getopt.h" first, to check interface.
11372         (getenv): Declare only if defined HAVE_DECL_GETENV &&
11373         !HAVE_DECL_GETENV.
11374         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
11375         (__strndup): Revert to K&R-style function dfns, the glibc style.
11376         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
11377         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
11378         Include strnlen.h first, to get prototype properly.
11379         (strnlen): Renamed from __strnlen.
11380         Remove weak alias.
11381
11382 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11383
11384         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
11385
11386 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11387
11388         * config/srclist.txt: Adjust to reflect glibc reorganization.
11389         This affects only comments.
11390
11391 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11392
11393          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
11394          Reported by Bruce Korb <bkorb@gnu.org>.
11395
11396 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
11397
11398         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
11399         to pacify gcc -Wswitch-default.
11400
11401 2006-01-22  Bruno Haible  <bruno@clisp.org>
11402
11403         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
11404         temporary buffer for sprintf, take into account the precision also
11405         for 'd', 'i', 'u', 'o', 'x', 'X'.
11406
11407 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11408
11409         * modules/argp-tests: New module
11410         * tests/test-argp.c: New file
11411         * tests/test-argp-2.sh: New file
11412
11413 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11414
11415         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
11416         (__argp_base_name): Removed
11417         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
11418         typo.
11419         (__argp_base_name): Provide macro definition or extern declaration
11420         depending on the configuration
11421
11422 2006-01-20  Simon Josefsson  <jas@extundo.com>
11423
11424         * modules/inet_ntop (Depends-on): Depend on sys_socket.
11425
11426 2006-01-20  Simon Josefsson  <jas@extundo.com>
11427
11428         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
11429
11430 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
11431
11432         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
11433         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
11434         Suggested by Bruno Haible.
11435
11436 2006-01-20  Karl Berry  <karl@gnu.org>
11437
11438         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
11439         until changes propagate, I guess.
11440
11441 2006-01-19  Simon Josefsson  <jas@extundo.com>
11442
11443         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
11444
11445 2006-01-19  Simon Josefsson  <jas@extundo.com>
11446
11447         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
11448
11449 2006-01-19  Simon Josefsson  <jas@extundo.com>
11450
11451         * gnulib-tool: Set check_PROGRAMS.
11452
11453         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
11454         modules/des-tests, modules/gc-arcfour-tests,
11455         modules/gc-arctwo-tests, modules/gc-des-tests,
11456         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
11457         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
11458         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
11459         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
11460         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
11461         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
11462         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
11463         test_*_SOURCES.
11464
11465 2006-01-18  Simon Josefsson  <jas@extundo.com>
11466
11467         * modules/socklen (Depends-on): Depend on sys_socket.
11468
11469 2006-01-18  Simon Josefsson  <jas@extundo.com>
11470
11471         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
11472         modules/des-tests, modules/gc-arcfour-tests,
11473         modules/gc-arctwo-tests, modules/gc-des-tests,
11474         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
11475         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
11476         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
11477         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
11478         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
11479         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
11480         $(EXEEXT) to automake TESTS variable, for mingw32.
11481
11482 2006-01-17  Simon Josefsson  <jas@extundo.com>
11483
11484         * modules/socklen (Include): Need sys/socket.h.
11485
11486 2006-01-17  Bruno Haible  <bruno@clisp.org>
11487
11488         * modules/ssize_t (Include): Add <sys/types.h>.
11489
11490 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
11491
11492         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
11493         it's not portable and it doesn't work with cross-compiles.
11494         Problem reported by Bruno Haible.  Fix missing-$ typo in
11495         'test "gl_cv_ignore_unused_libraries" ...' that prevented
11496         -zignore from being used with Sun's C compiler.
11497
11498 2006-01-12  Simon Josefsson  <jas@extundo.com>
11499
11500         * lib/base64.c: Fix warning, reported by Bruno Haible
11501         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
11502
11503 2006-01-12  Bruno Haible  <bruno@clisp.org>
11504
11505         * modules/ldd: New file.
11506         * build-aux/ldd.sh.in: New file.
11507         * MODULES.html.sh (Support for building libraries and executables): Add
11508         ldd.
11509
11510 2006-01-12  Bruno Haible  <bruno@clisp.org>
11511
11512         * m4/ldd.m4: New file.
11513
11514 2006-01-12  Bruno Haible  <bruno@clisp.org>
11515
11516         * gnulib-tool (func_import, func_create_testdir): Don't go into an
11517         endless loop while replacing $auxdir with build-aux.
11518
11519 2006-01-11  Simon Josefsson  <jas@extundo.com>
11520
11521         * lib/stdint_.h (SIZE_MAX): Add missing (.
11522
11523 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
11524
11525         Sync from coreutils.
11526         * lib/md5.c: Fix commentary typos.
11527         (alignof, UNALIGNED_P): No need for a GCC-specific version.
11528         * lib/md5.h (__attribute__): Remove; unused.
11529         * lib/sha1.c: Fix commentary to match md5 better.
11530         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
11531         so that we don't need to worry about alignment.  All uses changed.
11532         This merges the 2005-10-28 md5 change into sha1.
11533
11534 2006-01-11  Jim Meyering  <jim@meyering.net>
11535
11536         Sync from coreutils.
11537         * lib/md5.c (OP): Fix spacing.
11538
11539 2006-01-11  Bruno Haible  <bruno@clisp.org>
11540
11541         Ensure automatic ordering between gl_LOCK and gl_ARGP.
11542         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
11543         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
11544
11545 2006-01-11  Bruno Haible  <bruno@clisp.org>
11546
11547         Ensure automatic ordering between gl_LOCK and gl_ARGP.
11548         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
11549         the "early" section as well.
11550
11551 2006-01-11  Bruno Haible  <bruno@clisp.org>
11552
11553         Avoid "ar: no archive members specified" error on MacOS X.
11554         * gnulib-tool (func_modules_add_dummy): New function.
11555         (func_import, func_create_testdir): Invoke it.
11556
11557 2006-01-11  Bruno Haible  <bruno@clisp.org>
11558
11559         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
11560         with $auxdir in AC_CONFIG_FILES statements.
11561
11562 2006-01-11  Bruno Haible  <bruno@clisp.org>
11563
11564         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
11565         Initialize also noinst_HEADERS to empty.
11566
11567 2006-01-11  Bruno Haible  <bruno@clisp.org>
11568
11569         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
11570         variables.
11571         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
11572         autoreconf.
11573
11574 2006-01-11  Bruno Haible  <bruno@clisp.org>
11575
11576         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
11577         overridable by the user.
11578         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11579
11580 2006-01-10  Simon Josefsson  <jas@extundo.com>
11581
11582         * modules/sys_socket: New file.
11583
11584 2006-01-10  Simon Josefsson  <jas@extundo.com>
11585
11586         * m4/sys_socket_h.m4: New file.
11587
11588 2006-01-10  Simon Josefsson  <jas@extundo.com>
11589
11590         * lib/socket_.h: New file.
11591
11592 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
11593
11594         * modules/readutmp (Maintainer): Add myself.
11595
11596 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
11597
11598         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
11599         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
11600         People who are still concerned with buggy memcmp implementations
11601         can invoke gl_FUNC_MEMCMP themselves.
11602
11603 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
11604
11605         * lib/regex_internal.h (BITSET_WORD_BITS):
11606         Work around a bug in 64-bit PGC (before version 6.1-2), where the
11607         preprocessor mishandles large unsigned values as if they were signed.
11608         Problem reported by Claudio Fontana in
11609         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
11610
11611 2006-01-10  Jim Meyering  <jim@meyering.net>
11612
11613         Avoid the double-free (first in fts_read, second in fts_close) that
11614         would occur when an `active' directory is made inaccessible (e.g.,
11615         via chmod a-x) during a traversal.
11616         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
11617         before returning.  Reproduce this failure by
11618         mkdir -p a/b; cd a; chmod a-x . b
11619         Reported by Stavros Passas.
11620
11621         Sync from coreutils.
11622         * lib/sha1.c: Tweak grammar in a comment.
11623
11624 2006-01-10  Jim Meyering  <jim@meyering.net>
11625
11626         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
11627         Patch by Joerg Sonnenberger.
11628
11629 2006-01-10  Bruno Haible  <bruno@clisp.org>
11630
11631         * modules/readutmp: Depend on module free.
11632         * modules/strtok_r: Depend on module restrict.
11633
11634 2006-01-10  Bruno Haible  <bruno@clisp.org>
11635
11636         * modules/gettext (configure.ac): Add an invocation of
11637         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
11638
11639 2006-01-10  Bruno Haible  <bruno@clisp.org>
11640
11641         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
11642         Reported by Werner Lemberg <wl@gnu.org>.
11643
11644 2006-01-10  Bruno Haible  <bruno@clisp.org>
11645
11646         * lib/localcharset.c: Update from GNU gettext.
11647
11648 2006-01-10  Bruno Haible  <bruno@clisp.org>
11649
11650         * lib/argp.h (__const): Remove macro. Use const instead.
11651         * lib/argp-fmtstream.h (__const): Likewise.
11652         * lib/glob_.h (__const): Remove macro.
11653         * lib/glob-libc.h: Use const instead of __const.
11654
11655 2006-01-10  Bruno Haible  <bruno@clisp.org>
11656
11657         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
11658         variable.
11659         Needed to avoid an automake error regarding the 'gettext' module.
11660
11661 2006-01-09  Simon Josefsson  <jas@extundo.com>
11662
11663         * modules/inet_ntop (Depends-on): Add restrict.
11664
11665 2006-01-09  Simon Josefsson  <jas@extundo.com>
11666
11667         * modules/gc-rijndael-tests (License): Put under LGPL.
11668
11669         * modules/gc-des-tests (License): Likewise.
11670
11671         * modules/gc-arcfour-tests (License): Likewise.
11672
11673         * modules/gc-arctwo-tests (License): Likewise.
11674
11675         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
11676
11677         * modules/gc-hmac-sha1-tests (Files): Likewise.
11678
11679         * modules/gc-hmac-md5-tests (License): Likewise.
11680
11681         * modules/gc-sha1-tests (License): Likewise.
11682
11683         * modules/gc-md5-tests (License): Likewise.
11684
11685         * modules/gc-md4-tests (License): Likewise.
11686
11687         * modules/gc-md2-tests (License): Likewise.
11688
11689         * modules/gc-tests (License): Likewise.
11690
11691         * modules/des-tests (License): Likewise.
11692
11693         * modules/md4-tests (License): Likewise.
11694
11695         * modules/md2-tests (License): Likewise.
11696
11697 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
11698
11699         Sync from coreutils:
11700
11701         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
11702         * modules/lib-ignore: New file.
11703         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
11704         chdir-safer.m4, lchmod.m4.
11705         * modules/openat: Add mkdirat.c, openat-priv.h.
11706
11707 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
11708
11709         Sync from coreutils.
11710         * m4/lib-ignore.m4: New file.
11711         * m4/lchmod.m4: New file.
11712
11713 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
11714
11715         Sync from coreutils.
11716         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
11717         for write access: POSIX says that must fail.
11718         * lib/fts.c (diropen): Likewise.
11719         * lib/save-cwd.c (save_cwd): Likewise.
11720         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
11721         well, for minor improvements on hosts that lack O_DIRECTORY.
11722         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
11723         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
11724         Fall back on chown if open failed with EACCES.
11725
11726         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
11727         Report an error at compile-time if only a 1-second nominal clock
11728         resolution is found.
11729
11730         * lib/lchmod.h: New file.
11731         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
11732         (make_dir_parents): Use lchown rather than chown, and
11733         lchmod rather than chmod.
11734
11735         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
11736         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
11737         "proc" reported by n0dalus.
11738
11739         * lib/mountlist.c: Include <limits.h>.
11740         (dev_from_mount_options)
11741         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
11742         New function.  It no longer assumes "dev=" has the System V meaning
11743         on Linux (since it doesn't).  It also parses "dev=" more carefully.
11744         (read_file_system_list)
11745         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
11746         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
11747         dev= in that case.
11748
11749         * lib/posixtm.h (PDS_PRE_2000): New macro.
11750         * lib/posixtm.c (year): Arg is now syntax_bits rather than
11751         allow_century.  All usages changed.  Reject dates outside the range
11752         1969-1999 if PDS_PRE_2000 is used.
11753
11754 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
11755
11756         Sync from coreutils.
11757         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
11758         (Time of day items): Mention the possibility of leap seconds.
11759         Problem reported by Dr. David Alan Gilbert.
11760
11761 2006-01-09  Jim Meyering  <jim@meyering.net>
11762
11763         Sync from coreutils.
11764
11765         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
11766
11767         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
11768
11769         * lib/modechange.c (mode_compile): Reject an invalid mode string
11770         that starts with an octal digit.  From Andreas Gruenbacher.
11771
11772         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
11773         and dup to open_safer and dup_safer, respectively.
11774         (openat_permissive): Fix typo in comment.
11775
11776         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
11777         "gettext.h"; either no longer needed or are guaranteed by openat.h.
11778         (_): Remove; no longer needed.
11779         (openat): Renamed from rpl_openat; no need for rpl_openat
11780         since openat.h renames openat for us.
11781         Replace most of the body with a call to openat_permissive,
11782         to avoid duplicate code.
11783         Port to (probably hypothetical) environments were mode_t is
11784         wider than int.
11785         (openat_permissive): Require mode arg, so that we can check
11786         types better.  Put it just after flags.  Change cwd failure
11787         indicator from pointer-to-bool to pointer-to-errno-value.
11788         All callers changed.
11789         Invoke openat_save_fail and/or openat_restore_fail if
11790         cwd_errno is null, so that openat can call us.
11791         (openat_permissive, fdopendir, fstatat, unlinkat):
11792         Simplify errno handling to avoid some duplicate code,
11793         as it's OK to set errno on success.
11794         * lib/openat.h: Revamp code so that function macros depend on
11795         __OPENAT_PREFIX only, not also on AT_FDCWD.
11796         (openat_ro): Remove.  Caller changed to use openat_permissive.
11797         (openat_permissive): Now a macro, if not a function.
11798         (openat_restore_fail, openat_save_fail): Now always functions,
11799         since mkdirat needs them even if __OPENAT_PREFIX is defined.
11800
11801         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
11802         and openat.c.
11803         * lib/mkdirat.c: Include openat-priv.h.
11804         Remove definitions of macros defined therein.
11805         * lib/openat.c: Likewise.
11806
11807         * lib/mkdirat.c (mkdirat): New file and function.
11808         * lib/openat.h (mkdirat): Declare.
11809
11810         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
11811
11812         * lib/openat.h (openat_permissive): Declare.
11813         (openat_ro): Define.
11814
11815         * lib/openat.c (EXPECTED_ERRNO): New macro.
11816         (openat_permissive): New function -- used in remove.c rewrite.
11817         (all functions): Set errno just before returning, only if there
11818         was an actual failure.
11819         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
11820
11821         Emulate openat-family functions using Linux's procfs, if possible.
11822         Idea and some code based on Ulrich Drepper's glibc changes.
11823
11824         * lib/openat.c: (BUILD_PROC_NAME): New macro.
11825         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
11826         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
11827         before falling back on save_cwd and restore_cwd.
11828         (fdopendir, fstatat, unlinkat): Likewise.
11829
11830         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
11831         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
11832
11833         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
11834         as second argument to va_arg.  Otherwise, some versions of gcc
11835         warn that `if this code is reached, the program will abort'.
11836
11837 2006-01-09  Jim Meyering  <jim@meyering.net>
11838
11839         Sync from coreutils.
11840         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
11841         Require openat-priv.h.
11842
11843 2006-01-09  Bruno Haible  <bruno@clisp.org>
11844
11845         * modules/strnlen (Include): Use strnlen.h.
11846
11847 2006-01-09  Bruno Haible  <bruno@clisp.org>
11848
11849         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
11850
11851 2006-01-09  Bruno Haible  <bruno@clisp.org>
11852
11853         * lib/sysexit_.h (EX_OK): New macro.
11854         Suggested by Martin Lambers <marlam@marlam.de>.
11855
11856 2006-01-09  Bruno Haible  <bruno@clisp.org>
11857
11858         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
11859         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
11860
11861 2006-01-09  Bruno Haible  <bruno@clisp.org>
11862
11863         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
11864         numbers.
11865
11866 2006-01-09  Bruno Haible  <bruno@clisp.org>
11867
11868         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
11869         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
11870         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
11871         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
11872
11873 2006-01-09  Bruno Haible  <bruno@clisp.org>
11874
11875         * build-aux/javacomp.sh.in: New file, moved from lib/.
11876         * modules/javacomp-script (Files): Update.
11877         (configure.ac): Add AC_CONFIG_FILES invocation.
11878         (EXTRA_DIST): Remove variable.
11879
11880         * build-aux/javaexec.sh.in: New file, moved from lib/.
11881         * modules/javaexec (Files): Update.
11882         (configure.ac): Add AC_CONFIG_FILES invocation.
11883         (EXTRA_DIST): Remove javaexec.sh.in.
11884
11885         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
11886         * modules/csharpcomp-script (Files): Update.
11887         (configure.ac): Add AC_CONFIG_FILES invocation.
11888         (EXTRA_DIST): Remove variable.
11889
11890         * build-aux/csharpexec.sh.in: New file, moved from lib/.
11891         * modules/csharpexec (Files): Update.
11892         (configure.ac): Add AC_CONFIG_FILES invocation.
11893         (EXTRA_DIST): Remove csharpexec.sh.in.
11894
11895 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
11896
11897         Sync from coreutils.
11898
11899         Add POSIX ACL support
11900         * lib/acl.h (copy_acl, set_acl): Add declarations.
11901         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
11902         systems other than Linux.
11903         (chmod_or_fchmod): New function: use fchmod when possible,
11904         and chmod otherwise.
11905         (file_has_acl): Add a POSIX ACL implementation, with a
11906         Linux-specific subcase.
11907         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
11908         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
11909         acls are unsupported.
11910         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
11911         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
11912         are unsupported.
11913
11914 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
11915
11916         Sync from coreutils.
11917         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
11918
11919 2006-01-07  Bruno Haible  <bruno@clisp.org>
11920
11921         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
11922         gl_EARLY.
11923
11924 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
11925
11926         * lib/strftime.c (tzname): Don't declare if it is already #defined.
11927         Problem reported for Mingw by Mark Junker.
11928
11929 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
11930
11931         * README: Gnulib normally doesn't generate a tarball.
11932
11933 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
11934
11935         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
11936         long int, not int, for nanosecond counts, so that people who are
11937         used to POSIX struct timespec won't be surprised.  Reported by Jim
11938         Meyering.
11939
11940 2005-12-28  Bruno Haible  <bruno@clisp.org>
11941
11942         * build-aux/config.rpath: Update from GNU gettext.
11943
11944 2005-12-16  Jim Meyering  <jim@meyering.net>
11945
11946         * modules/fprintftime: New module.
11947         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
11948
11949 2005-12-16  Jim Meyering  <jim@meyering.net>
11950
11951         * m4/fprintftime.m4: New file.
11952
11953 2005-12-16  Jim Meyering  <jim@meyering.net>
11954
11955         * lib/fprintftime.c, lib/fprintftime.h: New files.
11956
11957 2005-12-15  Simon Josefsson  <jas@extundo.com>
11958
11959         * modules/socklen (configure.ac): Fix M4 macro name, to align with
11960         new m4/socklen.m4.
11961
11962 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
11963
11964         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
11965         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
11966
11967 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
11968
11969         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
11970         * lib/argp-help.c (fill_in_uparams): Check if the constructed
11971         struct uparams is valid. Fall back to the default values if it is
11972         not.
11973
11974 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11975
11976         * modules/argp (Files): Add argp-pin.c
11977         (Depends-on): dirname
11978         (lib_SOURCES): Add argp-pin.c
11979
11980 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11981
11982         * m4/argp.m4:  Check if program_invocation_name and
11983         program_invocation_short_name are declared and define appropriate
11984         macros if they are not.
11985
11986 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11987
11988         * lib/argp-help.c (__argp_base_name): New function
11989         (__argp_short_program_name): Rewrite using __argp_base_name
11990         * lib/argp-namefrob.h: Define program_invocation_name and
11991         program_invocation_short_name if requested
11992         (__argp_base_name): Add prototype
11993         * lib/argp-parse.c (argp_def): Use gettext wrappers
11994         (argp_default_parser): Use __argp_base_name
11995         * lib/argp-pin.c: New file. Defines program_invocation_name and
11996         program_invocation_short_name on systems that lack them.
11997
11998 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
11999
12000         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
12001         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12002         porting problem reported by Georg Schwarz in
12003         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12004
12005 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
12006
12007         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
12008         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12009         porting problem reported by Georg Schwarz in
12010         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12011
12012 2005-12-05  Bruno Haible  <bruno@clisp.org>
12013
12014         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
12015         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
12016         Reported by Mark Junker <mjscod@gmx.de>.
12017
12018 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
12019
12020         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
12021         Use implementation from Albert Chin, with some
12022         comments/corrections by Stepan Kasal and myself.
12023
12024 2005-12-02  Bruno Haible  <bruno@clisp.org>
12025
12026         * gnulib-tool (func_import): Accept GPLed build tool modules when
12027         --lgpl is given.
12028         * modules/csharpcomp-script: New file.
12029         * modules/csharpcomp: Depend on it.
12030         * modules/javacomp-script: New file.
12031         * modules/javacomp: Depend on it.
12032         Suggested by Simon Josefsson.
12033
12034 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
12035
12036         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
12037         statement, to work around an HP-UX 10.20 compiler bug reported by
12038         Peter O'Gorman.
12039
12040 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12041
12042         * modules/savedir (Depends-on): Add openat.
12043
12044 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12045
12046         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
12047         (uintmax_t) [defined uintmax_t]: Do not declare.
12048         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
12049         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
12050         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
12051         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
12052         sake of portability to weird hosts that C allows (though we don't
12053         know of any practical examples).
12054
12055         * lib/savedir.h (fdsavedir): New decl.
12056         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
12057         contains most of the former guts of savedir.
12058         (savedir): Use savedirstream.
12059         Include "openat.h".
12060
12061 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
12062
12063         * modules/obstack (Files): Add m4/ulonglong.m4.
12064         Problem reported by Davide Angelocola.
12065
12066 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
12067
12068         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
12069         coreutils no longer futzes with rounding modes.
12070
12071 2005-11-14  Jim Meyering  <jim@meyering.net>
12072
12073         * lib/mkstemp-safer.c: Include <config.h>, required for possible
12074         replacement of mkstemp.
12075
12076 2005-11-10  Simon Josefsson  <jas@extundo.com>
12077
12078         * lib/readline.c: Remove EOL.
12079
12080 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12081
12082         * modules/gethrxtime (Depends-on): Add gettime.
12083
12084 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12085
12086         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
12087         or gettimeofday; no longer needed.
12088
12089 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12090
12091         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
12092         time business.
12093         (gethrxtime) [! (HAVE_NANOUPTIME
12094         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
12095         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
12096         our own approximation.
12097
12098 2005-11-08  Eric Blake  <ebb9@byu.net>
12099
12100         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12101
12102 2005-11-08  Eric Blake  <ebb9@byu.net>
12103
12104         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12105
12106 2005-11-04  Bruno Haible  <bruno@clisp.org>
12107
12108         * gnulib-tool: Implement --update mode.
12109
12110 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12111
12112         Fix porting problem reported by Theodoros V. Kalamatianos.
12113         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
12114         Don't assume that futimes failing means we must fail.
12115
12116 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12117
12118         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
12119         variables to suggest the intended function of the PATH_MAX check.
12120
12121 2005-10-30  Kean Johnston  <jkj@sco.com>
12122
12123         Trivial changes to support SCO systems.
12124         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
12125         as PATH_MAX.
12126         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
12127         where __ptr is null when no I/O is pending.
12128
12129 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
12130
12131         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
12132         leave errno alone.  Problem reported by Dmitry V. Levin.
12133
12134 2005-10-28  Simon Josefsson  <jas@extundo.com>
12135
12136         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
12137         Test more.
12138
12139         * tests/test-gc-md2.c, tests/test-md2.c: New files.
12140
12141         * modules/md2, modules/md2-tests: New files.
12142
12143 2005-10-28  Simon Josefsson  <jas@extundo.com>
12144
12145         * m4/inet_ntop.m4: More tests.
12146
12147         * m4/gc-md2.m4, md2.m4: New file.
12148
12149 2005-10-28  Simon Josefsson  <jas@extundo.com>
12150
12151         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
12152         "restrict" keywords, as per POSIX.  Protect the function
12153         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
12154         Don't use K&R prototypes.  Check the sprintf return values.
12155         Re-define EAFNOSUPPORT if not present.  Indent.
12156
12157         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
12158         suggested by Bruno Haible <bruno@clisp.org>.
12159
12160         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
12161
12162         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
12163
12164         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
12165         libgcrypt).
12166
12167         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
12168
12169         * lib/md2.h, lib/md2.c: New files.
12170
12171 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
12172
12173         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
12174         errno alone.  Problem reported by Frederic Jolliton.
12175
12176 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
12177
12178         * modules/verify (License): Change from GPL to LGPL.  This is a
12179         tiny module and there are apparently near-equivalents that are
12180         under the BSD license.
12181
12182 2005-10-24  Simon Josefsson  <jas@extundo.com>
12183
12184         * modules/sha1: Relicense to LGPL.
12185
12186 2005-10-24  Simon Josefsson  <jas@extundo.com>
12187
12188         * lib/md4.h: Shrink buffer size, now that we changed the type.
12189
12190 2005-10-23  Simon Josefsson  <jas@extundo.com>
12191
12192         * gnulib-tool (func_import): Fix --tests-base.
12193
12194 2005-10-22  Simon Josefsson  <jas@extundo.com>
12195
12196         * modules/arcfour (Depends-on): Need stdint.
12197
12198 2005-10-22  Simon Josefsson  <jas@extundo.com>
12199
12200         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
12201         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
12202
12203 2005-10-22  Simon Josefsson  <jas@extundo.com>
12204
12205         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
12206         suggested by Bruno Haible <bruno@clisp.org>.
12207
12208 2005-10-22  Simon Josefsson  <jas@extundo.com>
12209
12210         * lib/crc.h: Include stddef.h, for size_t.
12211
12212 2005-10-22  Simon Josefsson  <jas@extundo.com>
12213
12214         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
12215         arcfour_context struct (simplify test vector testing in GNU
12216         Shishi).
12217
12218 2005-10-21  Simon Josefsson  <jas@extundo.com>
12219
12220         * modules/des, modules/des-tests: New files.
12221
12222         * modules/gc-des, modules/gc-des-tests: New files.
12223
12224         * tests/test-des.c, tests/test-gc-des.c: New file.
12225
12226 2005-10-21  Simon Josefsson  <jas@extundo.com>
12227
12228         * modules/arctwo, modules/arctwo-tests: New files.
12229
12230         * tests/test-arctwo.c: New file.
12231
12232         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
12233
12234         * tests/test-gc-arctwo.c: New file.
12235
12236 2005-10-21  Simon Josefsson  <jas@extundo.com>
12237
12238         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
12239         Bruno Haible <bruno@clisp.org>.
12240
12241         * m4/gc-des.m4: New file.
12242
12243 2005-10-21  Simon Josefsson  <jas@extundo.com>
12244
12245         * m4/arctwo.m4: New file.
12246
12247         * m4/gc-arctwo.m4: New file.
12248
12249 2005-10-21  Simon Josefsson  <jas@extundo.com>
12250
12251         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
12252         block.
12253
12254 2005-10-21  Simon Josefsson  <jas@extundo.com>
12255
12256         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
12257         <bruno@clisp.org>.
12258
12259         * lib/hmac-sha1.c (hmac_sha1): Likewise.
12260
12261         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
12262         Bruno Haible <bruno@clisp.org>.
12263
12264         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
12265         <bruno@clisp.org>.
12266
12267 2005-10-21  Simon Josefsson  <jas@extundo.com>
12268
12269         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
12270
12271 2005-10-21  Simon Josefsson  <jas@extundo.com>
12272
12273         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
12274
12275 2005-10-21  Simon Josefsson  <jas@extundo.com>
12276
12277         * lib/des.h, lib/des.c: New files.
12278
12279         * lib/gc-gnulib.c: Support DES.c
12280
12281 2005-10-21  Simon Josefsson  <jas@extundo.com>
12282
12283         * lib/arctwo.h, lib/arctwo.c: New files.
12284
12285         * lib/gc-gnulib.c: Support ARCTWO.
12286
12287 2005-10-21  Simon Josefsson  <jas@extundo.com>
12288
12289         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
12290         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12291
12292 2005-10-21  Simon Josefsson  <jas@extundo.com>
12293
12294         * gnulib-tool (func_import, func_create_testdir): Define automake
12295         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
12296         Makefile.am snippet),
12297         suggested by Bruno Haible <bruno@clisp.org>.
12298
12299         * modules/gc (Makefile.am): Use it.
12300
12301 2005-10-21  Bruno Haible  <bruno@clisp.org>
12302
12303         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
12304         patch.
12305
12306 2005-10-19  Simon Josefsson  <jas@extundo.com>
12307
12308         * tests/test-gc-rijndael.c: New file.
12309
12310         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
12311
12312 2005-10-19  Simon Josefsson  <jas@extundo.com>
12313
12314         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
12315         interface too.
12316
12317 2005-10-19  Simon Josefsson  <jas@extundo.com>
12318
12319         * tests/test-gc-arcfour.c: New file.
12320
12321         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
12322
12323 2005-10-19  Simon Josefsson  <jas@extundo.com>
12324
12325         * modules/gc-md4, modules/gc-md4-tests: New file.
12326
12327         * tests/test-gc-md4.c: New file.
12328
12329 2005-10-19  Simon Josefsson  <jas@extundo.com>
12330
12331         * m4/gc-md4.m4: New file.
12332
12333 2005-10-19  Simon Josefsson  <jas@extundo.com>
12334
12335         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
12336         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
12337         <kasal@ucw.cz>.
12338
12339 2005-10-19  Simon Josefsson  <jas@extundo.com>
12340
12341         * m4/gc-arcfour.m4: New file.
12342
12343         * m4/gc-rijndael.m4: New file.
12344
12345 2005-10-19  Simon Josefsson  <jas@extundo.com>
12346
12347         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
12348
12349 2005-10-19  Simon Josefsson  <jas@extundo.com>
12350
12351         * lib/gc-gnulib.c: Support ARCFOUR.
12352
12353 2005-10-19  Simon Josefsson  <jas@extundo.com>
12354
12355         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
12356         support.
12357
12358         * lib/gc.h: Add ECB enum type.
12359
12360         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
12361
12362 2005-10-18  Simon Josefsson  <jas@extundo.com>
12363
12364         * tests/test-md5.c: New file.
12365
12366         * modules/md5-tests: New file.
12367
12368 2005-10-18  Simon Josefsson  <jas@extundo.com>
12369
12370         * tests/test-md4.c: New file.
12371
12372         * modules/md4, modules/md4-tests: New files.
12373
12374 2005-10-18  Simon Josefsson  <jas@extundo.com>
12375
12376         * m4/md4.m4: New file.
12377
12378 2005-10-18  Simon Josefsson  <jas@extundo.com>
12379
12380         * lib/md4.h, lib/md4.c: New files, based on md5.?.
12381
12382 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
12383
12384         * gnulib-tool (func_create_testdir): Omit the second check whether
12385         BUILT_SOURCES in nonempty.
12386
12387 2005-10-17  Simon Josefsson  <jas@extundo.com>
12388
12389         * tests/test-rijndael.c: New file.
12390
12391 2005-10-17  Simon Josefsson  <jas@extundo.com>
12392
12393         * modules/sha1: Depend on stdint instead of md5.
12394
12395         * modules/md5: Depend on stdint, remove uint32_t.
12396
12397 2005-10-17  Simon Josefsson  <jas@extundo.com>
12398
12399         * modules/gc-sha1-tests: New file.
12400
12401         * tests/test-gc-sha1.c: New file.
12402
12403 2005-10-17  Simon Josefsson  <jas@extundo.com>
12404
12405         * m4/md5.m4: Remove call to uint32_t.m4.
12406
12407 2005-10-17  Simon Josefsson  <jas@extundo.com>
12408
12409         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
12410
12411         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
12412         md5.h.
12413
12414         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
12415
12416         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
12417
12418 2005-10-17  Simon Josefsson  <jas@extundo.com>
12419
12420         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
12421
12422 2005-10-17  Simon Josefsson  <jas@extundo.com>
12423
12424         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
12425
12426 2005-10-17  Simon Josefsson  <jas@extundo.com>
12427
12428         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
12429
12430         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
12431
12432 2005-10-17  Bruno Haible  <bruno@clisp.org>
12433
12434         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
12435         that it can also be used in a test.
12436
12437 2005-10-16  Bruno Haible  <bruno@clisp.org>
12438
12439         * gnulib-tool (func_emit_tests_Makefile_am): Also define
12440         TESTS_ENVIRONMENT, so that individual tests can augment it.
12441
12442         * gnulib-tool (func_create_testdir): Use an intermediate target for
12443         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
12444         macros, like $(ALLOCA_H), which cannot be passed through the command
12445         line.
12446
12447 2005-10-15  Simon Josefsson  <jas@extundo.com>
12448
12449         * modules/rijndael-tests: New file.
12450
12451         * modules/rijndael: New file.
12452
12453 2005-10-15  Simon Josefsson  <jas@extundo.com>
12454
12455         * m4/rijndael.m4: New file.
12456
12457 2005-10-15  Simon Josefsson  <jas@extundo.com>
12458
12459         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
12460
12461         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
12462
12463 2005-10-14  Simon Josefsson  <jas@extundo.com>
12464
12465         * tests/test-arcfour.c: New file.
12466
12467         * modules/arcfour, modules/arcfour-tests: New files.
12468
12469 2005-10-14  Simon Josefsson  <jas@extundo.com>
12470
12471         * m4/arcfour.m4: New file.
12472
12473 2005-10-14  Simon Josefsson  <jas@extundo.com>
12474
12475         * lib/arcfour.h, lib/arcfour.c: New files.
12476
12477 2005-10-14  Roland McGrath  <roland@redhat.com>
12478
12479         Import from libc.  [BZ #1331]
12480         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
12481         macro argument.
12482         Reported by Matej Vela <vela@debian.org>.
12483
12484 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
12485
12486         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
12487         include <wchar.h>; no longer needed.
12488
12489 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
12490
12491         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
12492
12493 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
12494         and  Ulrich Drepper  <drepper@redhat.com>
12495
12496         Import from libc.
12497         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
12498         instead of inline stream orientation test and two separate
12499         function calls.  Pay no attention to USE_IN_LIBIO.
12500
12501 2005-10-13  Simon Josefsson  <jas@extundo.com>
12502
12503         * modules/gc-hmac-md5-tests: New file.
12504
12505         * tests/test-gc-hmac-sha1.c: New file.
12506
12507         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
12508
12509         * modules/gc-hmac-md5-tests: New file.
12510
12511         * tests/test-gc-md5.c: New file.
12512
12513         * modules/gc-md5-tests: New file.
12514
12515 2005-10-13  Simon Josefsson  <jas@extundo.com>
12516
12517         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
12518         Move memory allocation outside of loop.
12519
12520 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
12521
12522         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
12523         intermediate directory is in a read-only file system.  Problem
12524         reported by Eric Blake.
12525
12526 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
12527
12528         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
12529
12530 2005-10-12  Simon Josefsson  <jas@extundo.com>
12531
12532         * tests/test-hmac-sha1.c: New file.
12533
12534         * modules/hmac-sha1-tests: New file.
12535
12536         * modules/hmac-sha1: New file.
12537
12538 2005-10-12  Simon Josefsson  <jas@extundo.com>
12539
12540         * modules/gc-sha1: New file.
12541
12542 2005-10-12  Simon Josefsson  <jas@extundo.com>
12543
12544         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
12545
12546         * tests/test-gc-pbkdf2-sha1.c: New file.
12547
12548 2005-10-12  Simon Josefsson  <jas@extundo.com>
12549
12550         * modules/gc-md5, modules/gc-hmac-md5: New files.
12551
12552         * modules/gc (Files): Remove md5, memxor and hmac files.
12553
12554 2005-10-12  Simon Josefsson  <jas@extundo.com>
12555
12556         * m4/gc-pbkdf2-sha1.m4: New file.
12557
12558         * m4/gc-hmac-sha1.m4: New file.
12559
12560         * m4/gc-sha1: New file.
12561
12562         * m4/hmac-sha1.m4: New file.
12563
12564 2005-10-12  Simon Josefsson  <jas@extundo.com>
12565
12566         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
12567
12568         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
12569
12570 2005-10-12  Simon Josefsson  <jas@extundo.com>
12571
12572         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
12573         suggested by Bruno Haible <bruno@clisp.org>.
12574
12575 2005-10-12  Simon Josefsson  <jas@extundo.com>
12576
12577         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
12578
12579 2005-10-12  Simon Josefsson  <jas@extundo.com>
12580
12581         * lib/gc-pbkdf2-sha1.c: New file.
12582
12583         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
12584
12585 2005-10-12  Simon Josefsson  <jas@extundo.com>
12586
12587         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
12588
12589         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
12590
12591 2005-10-12  Simon Josefsson  <jas@extundo.com>
12592
12593         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
12594         GC_USE_HMAC_MD5, respectively.
12595
12596         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
12597         (gc_md5): Fix typo.
12598
12599         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
12600
12601         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
12602
12603         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
12604
12605 2005-10-12  Bruno Haible  <bruno@clisp.org>
12606
12607         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
12608         Reported by Stepan Kasal <kasal@ucw.cz>.
12609
12610 2005-10-11  Simon Josefsson  <jas@extundo.com>
12611
12612         * tests/test-crc.c: New file.
12613
12614         * modules/crc, modules/crc-tests: New files.
12615
12616 2005-10-11  Simon Josefsson  <jas@extundo.com>
12617
12618         * m4/crc.m4: New file.
12619
12620 2005-10-11  Simon Josefsson  <jas@extundo.com>
12621
12622         * lib/gc.h: Add gc_hash and gc_hash_buffer.
12623
12624         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
12625
12626         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
12627
12628 2005-10-11  Simon Josefsson  <jas@extundo.com>
12629
12630         * lib/crc.h, lib/crc.c: New files.
12631
12632         * lib/gc.h (gc_hash_buffer): Add doc.
12633
12634 2005-10-11  Bruno Haible  <bruno@clisp.org>
12635
12636         * modules/c-strcasestr: New file.
12637         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
12638
12639 2005-10-11  Bruno Haible  <bruno@clisp.org>
12640
12641         * modules/c-strcase: New file.
12642         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
12643
12644 2005-10-11  Bruno Haible  <bruno@clisp.org>
12645
12646         * lib/strcasecmp.c: Include limits.h.
12647         (strcasecmp): Avoid integer overflow on exotic platforms.
12648         * lib/strncasecmp.c: Include limits.h.
12649         (strncasecmp): Avoid integer overflow on exotic platforms.
12650         Reported by Paul Eggert.
12651
12652 2005-10-11  Bruno Haible  <bruno@clisp.org>
12653
12654         * lib/c-strcasestr.h: New file, from GNU gettext.
12655         * lib/c-strcasestr.c: New file, from GNU gettext.
12656
12657 2005-10-11  Bruno Haible  <bruno@clisp.org>
12658
12659         * lib/c-strcase.h: New file, from GNU gettext.
12660         * lib/c-strcasecmp.c: New file, from GNU gettext.
12661         * lib/c-strncasecmp.c: New file, from GNU gettext.
12662
12663 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
12664
12665         * modules/mempcpy (License): GPL -> LGPL.
12666         * modules/strchrnul (License): Likewise.
12667         * modules/sysexits (License): Likewise.
12668
12669 2005-10-08  Simon Josefsson  <jas@extundo.com>
12670
12671         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
12672
12673 2005-10-07  Simon Josefsson  <jas@extundo.com>
12674
12675         * m4/memxor.m4: Remove gl_C_RESTRICT call.
12676
12677 2005-10-06  Simon Josefsson  <jas@extundo.com>
12678
12679         * tests/test-hmac-md5.c: New file.
12680
12681         * modules/hmac-md5-tests: New file.
12682
12683         * modules/hmac-md5: New file.
12684
12685 2005-10-06  Simon Josefsson  <jas@extundo.com>
12686
12687         * m4/hmac-md5.m4: New file.
12688
12689         * m4/memxor.m4: Require gl_C_RESTRICT.
12690
12691 2005-10-06  Simon Josefsson  <jas@extundo.com>
12692
12693         * lib/memxor.c (memxor): Avoid casts and warnings.
12694
12695 2005-10-06  Simon Josefsson  <jas@extundo.com>
12696
12697         * lib/hmac-md5.c: New file.
12698
12699         * lib/hmac.h: New file.
12700
12701 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
12702
12703         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
12704         promotes to int, not unsigned int, to catch the AIX 5.3
12705         compiler bug.
12706
12707 2005-10-05  Simon Josefsson  <jas@extundo.com>
12708
12709         * modules/memxor: New file.
12710
12711         * modules/iconv (Files): Move config.rpath to havelib, it is used
12712         there.
12713
12714         * modules/havelib (Files): Add config.rpath.
12715
12716 2005-10-05  Simon Josefsson  <jas@extundo.com>
12717
12718         * m4/memxor.m4: New file.
12719
12720 2005-10-05  Simon Josefsson  <jas@extundo.com>
12721
12722         * lib/memxor.c (memxor): Fix compiler error.
12723
12724         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
12725         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
12726
12727         * lib/memxor.h, lib/memxor.c: New files.
12728
12729         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
12730         we assume all systems have it, suggested by Jim Meyering
12731         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
12732         any systems lack sys/socket.h; mingw32 is known to lack it, but we
12733         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
12734         same reasons.
12735
12736 2005-10-05  Simon Josefsson  <jas@extundo.com>
12737
12738         * config/srclist.txt: Add glibc bug 1423 for md5.h.
12739
12740 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
12741
12742         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
12743         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
12744         needed, since the source code now assumes these .h files.
12745
12746 2005-10-05  Derek Price  <derek@ximbiot.com>
12747
12748         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
12749
12750 2005-10-05  Bruno Haible  <bruno@clisp.org>
12751
12752         * modules/stdint (License): Change to LGPL.
12753
12754 2005-10-04  Simon Josefsson  <jas@extundo.com>
12755
12756         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
12757         D. Baushke" <mdb@gnu.org>.
12758
12759 2005-10-04  Bruno Haible  <bruno@clisp.org>
12760
12761         * lib/verify.h (verify_true): Provide alternative definition for C++.
12762
12763 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
12764
12765         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
12766         (SSIZE_MAX): New macro, if not already defined.
12767         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
12768         than 2 GiB.
12769
12770 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
12771
12772         Sync from coreutils.
12773         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
12774         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
12775         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
12776         ULLONG_MAX doesn't work with 2.7.2.1.
12777
12778 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
12779
12780         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
12781         From Ben Pfaff.
12782
12783         * modules/exclude (Depends-on): Depend on verify.
12784         * modules/strtoimax (Depends-on): Likewise.
12785         * modules/utimecmp (Depends-on): Likewise.
12786
12787 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
12788
12789         * lib/exclude.c: Include verify.h.
12790         (verify): Remove.  All callers changed to use verify.h's version.
12791         * lib/strtoimax.c: Likewise.
12792         * lib/utimecmp.c: Likewis.e
12793
12794         Sync from coreutils.
12795         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
12796         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
12797         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
12798         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
12799         bother returning ENOSYS if settimeofday or stime fails; just let
12800         them return whatever errno they want to return.
12801         * lib/utimens.c: Include unistd.h, for dup2.
12802         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
12803         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
12804
12805 2005-10-02  Jim Meyering  <jim@meyering.net>
12806
12807         Sync from coreutils.
12808         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
12809         from glibc-2.2.5 that fails for read-only files.
12810
12811 2005-10-02  Jim Meyering  <jim@meyering.net>
12812
12813         Sync from coreutils.
12814         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
12815         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
12816         `#if HAVE_CONFIG_H'.
12817         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
12818         Remove AT_FDCWD test.
12819         Do not consume the fd unless successful.
12820         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
12821         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
12822         block, so that we don't even try to compile it if settimeofday is
12823         available.  This works around a compilation failure on OSF1 V5.1,
12824         due to stime requiring a `long int*' while tv_sec is `int'.
12825
12826 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
12827
12828         Sync from coreutils.
12829         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
12830         against `yes', rather than just testing for nonempty.
12831
12832 2005-10-01  Simon Josefsson  <jas@extundo.com>
12833
12834         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
12835         and Darwin.
12836
12837         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
12838         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
12839         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
12840         freeaddrinfo and gai_strerror are declared by the POSIX headers.
12841         Check if struct addrinfo is declared.
12842
12843 2005-10-01  Simon Josefsson  <jas@extundo.com>
12844
12845         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
12846         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
12847         AI_* and EAI_* definitions.  Protect function declarations.
12848
12849 2005-10-01  Jim Meyering  <jim@meyering.net>
12850
12851         Sync from coreutils.
12852
12853         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
12854         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
12855         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
12856         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
12857         in the inet and nsl libraries.  Required on Solaris 5.7.
12858
12859 2005-10-01  Jim Meyering  <jim@meyering.net>
12860
12861         Sync from coreutils.
12862         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
12863         in the inet and nsl libraries.  Required on Solaris 5.7.
12864
12865 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
12866
12867         * lib/getdelim.c (getdelim): Remove unused variables.
12868
12869 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
12870
12871         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
12872         so that the code works even with ancient cpp.  Portability problem
12873         with GCC 2.7.2.1 reported by Thomas M.Ott.
12874
12875 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
12876
12877         * modules/regex (Depends-on): Add strcase.
12878
12879         * modules/gethostname (Licence): Change from GPL to LGPL, since
12880         gethostname.c is a trivial implementation of a standard library
12881         function.
12882         * modules/poll (License): Change from GPL to LGPL, since it's
12883         derived from LGPL code.
12884
12885 2005-09-27  Jim Meyering  <jim@meyering.net>
12886
12887         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
12888         HAVE_CONFIG_H.
12889
12890         * lib/intprops.h (signed_type_or_expr__): Define.
12891         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
12892         for unsigned types.
12893
12894 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
12895
12896         * lib/verify.h (verify_expr): Remove, replacing with:
12897         (verify_true): New macro that returns true instead of void.
12898         (verify_type__): Remove.
12899         (verify): Use verify_true rather than verify_type__.
12900
12901 2005-09-26  Bruno Haible  <bruno@clisp.org>
12902
12903         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
12904         is necessary.
12905         (lib_SOURCES): Remove mbchar.c.
12906         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
12907         (Files): Add m4/mbrtowc.m4.
12908         * modules/mbiter: Likewise.
12909         * modules/mbuiter: Likewise.
12910
12911 2005-09-26  Bruno Haible  <bruno@clisp.org>
12912
12913         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
12914         compile mbchar.c if they are not both present.
12915         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
12916         * m4/mbiter.m4 (gl_MBITER): Likewise.
12917         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
12918         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
12919         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
12920
12921 2005-09-25  Jim Meyering  <jim@meyering.net>
12922
12923         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
12924         also uses socklen_t.
12925
12926 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
12927
12928         * lib/utimens.c (ENOSYS): Define if not already defined.
12929         (futimens): Support having a null PATH if the file descriptor
12930         is nonnegative.
12931
12932         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
12933         Remove.
12934         (__attribute): Define to empty unless GCC 3.1 or later.
12935         This works around a core dump on OpenBSD 3.4, which has GCC
12936         2.95.3, which dumps core when given __attribute__(()).  It also
12937         simplifies other tests, since we really don't want to bother with
12938         worrying about which ancient version of GCC supported what.
12939         Original problem reported by Yoann Vandoorselaere, with part of
12940         the fix suggested by Derek Price.
12941
12942 2005-09-24  Jim Meyering  <jim@meyering.net>
12943
12944         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
12945         so we can once again use a positive bitfield width of 1 -- now we
12946         don't have to explain why we were using a bitfield width of 2.
12947
12948 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
12949
12950         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
12951         and similarly for the other external symbols.  Problem reported
12952         by James Gallager.
12953
12954         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
12955         bug reported by Jim Meyering.
12956
12957         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
12958         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
12959         not needed, since socklen is a prerequisite module.
12960
12961 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
12962
12963         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
12964         Problem reported by Eric Blake.
12965         (getaddrinfo): Initialize se so that it's not garbage.
12966         Redo internal storage allocation so that it doesn't make unportable
12967         assumptions about alignment.
12968         Fix a memory leak.
12969
12970         * lib/utimens.c (futimens): Use futimesat if available.
12971         Prefer it to futimes since it doesn't have the futimes bug.
12972
12973         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
12974         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
12975         Instead, declare a function that returns a pointer to an array,
12976         and use verify_type__ to declare the size of the array.
12977         Problem and germ of a solution reported by Bruno Haible.
12978         (verify_type__): Use 2, not 1, for bitfield size, to avoid
12979         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
12980
12981 2005-09-23  Jim Meyering  <jim@meyering.net>
12982
12983         Sync from coreutils.
12984         Correct build failure (socklen_t not defined) on at least
12985         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
12986         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
12987
12988 2005-09-23  Jim Meyering  <jim@meyering.net>
12989
12990         * modules/getaddrinfo (Depends-on): Add socklen.
12991
12992 2005-09-23  Bruno Haible  <bruno@clisp.org>
12993
12994         * tests/test-verify.c: New file.
12995
12996 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
12997
12998         Sync from coreutils.
12999
13000         * modules/argmatch (Depends-on): Add verify.
13001         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
13002         unistd-safer.
13003         * modules/save-cwd (Depends-on): Likewise.
13004
13005         * modules/openat (Files): Add lib/openat-die.c.
13006         (Depends-on): Remove error, exitfail.
13007         Add dirname.
13008
13009         * modules/verify: New file.
13010         * MODULES.html.sh (Diagnostics <assert.h>): New section,
13011         with "verify" module.
13012
13013 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13014
13015         Sync from coreutils.
13016
13017         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
13018         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
13019         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
13020         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
13021         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
13022         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
13023         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
13024         Don't bother checking for string.h, stdlib.h, unistd.h.
13025         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
13026         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
13027         module's job.
13028         * m4/jm-macros.m4 (gl_MACROS): Likewise.
13029         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
13030
13031         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
13032         (gl_GETDATE): Use it.
13033
13034         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
13035
13036 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13037
13038         Sync from coreutils.
13039
13040         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
13041         stat-time.h.
13042         * lib/argmatch.h: Include verify.h
13043         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
13044         (ARGMATCH_ASSERT): Remove; unused.
13045         * lib/canonicalize.c: Assume STDC_HEADERS.
13046         * lib/exclude.c: Include "strcase.h".
13047         * lib/regex_internal.h [!defined _LIBC]: Likewise.
13048         * lib/getusershell.c: Include stdio--.h rather than stdio.h
13049         and stdio-safer.h.
13050         (getusershell): Call fopen, not fopen_safer.
13051         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
13052         Do not include unistd-safer.h.
13053         (save_cwd): Don't call fd_safer; no longer needed
13054         now that we include fcntl--.h.
13055
13056         * lib/getdate.y (relative_time): New type.
13057         (RELATIVE_TIME_0): New constant.
13058         (parser_control): Use relative_time instead of doing it ourselves.
13059         (%union): Add new relative_time rel member.
13060         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
13061         Now typeless.
13062         (relunit, relunit_snumber): Now of type rel.
13063         (zone, rel, relunit, get_date): Adjust to above changes.
13064
13065         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
13066         Do not include unistd-safer.h.
13067         (getloadavg): Don't call fd_safer; no longer needed
13068         now that we include fcntl--.h.
13069
13070         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
13071         (make_dir_parents): Treat ENOSYS like EEXIST.
13072
13073         Improve quality of diagnostics on restore_cwd failure.
13074         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
13075         (make_dir_parents): Last arg is now int * (for errno), not bool *.
13076         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
13077         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
13078         each time through the loop.  Do not diagnose restore_cwd failure;
13079         that is the caller's job (and perhaps the caller does not care).
13080
13081         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
13082         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
13083         If the file already exists but is not a directory, don't bother
13084         to try to make its parents.
13085         Close potential file descriptor leak if we can't chdir("/") (!).
13086         Don't always return true if chdir($PWD) fails; return true only
13087         if the requested action was done successfully (except for the
13088         chdir($PWD)).
13089         Don't log final directory unless we actually made it.
13090         Refactor to avoid duplicate code to fix up permissions.
13091         Don't attempt to fix up parent permissions if chdir($PWD) fails.
13092
13093         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
13094         to make it a bit faster and (I hope) clearer.
13095         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
13096         Fix bug in formats like %2N.
13097
13098         * lib/verify.h: New file.
13099
13100 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13101
13102         Sync from coreutils.
13103         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
13104
13105 2005-09-22  Jim Meyering  <jim@meyering.net>
13106
13107         Sync from coreutils.
13108
13109         * m4/lstat.m4 (gl_FUNC_LSTAT):
13110         Use AC_LIBSOURCES to require lstat.c and lstat.h.
13111         Remove obsolete comment.
13112         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
13113         * m4/xstrtod.m4: Likewise.
13114
13115         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
13116
13117 2005-09-22  Jim Meyering  <jim@meyering.net>
13118
13119         Sync from coreutils.
13120
13121         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
13122
13123         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
13124         the .tm_year member, since otherwise gcc-4.0 would now warn about
13125         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
13126
13127         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
13128         order to avoid an unsuppressible warning from gcc on 64-bit systems.
13129
13130         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
13131         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
13132         when run in a time zone for which daylight savings time is in effect
13133         for the starting date.
13134
13135         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
13136         stop us from restricting permissions of just-created absolute-named
13137         directories.
13138         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
13139         to restore initial working directory.
13140         * lib/mkdir-p.c (make_dir_parents): New parameter:
13141         different_working_dir, to tell caller if/when we change the working
13142         directory and are unable to return to the initial one.
13143         * lib/mkdir-p.h (make_dir_parents): Update prototype.
13144         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
13145         `return false'.  This fixes a bug introduced on 2004-07-30.
13146
13147         * lib/openat.c (fdopendir): Be sure to close the supplied
13148         file descriptor before returning.  This makes our replacement
13149         implementation a little closer to Solaris's, where fdopendir
13150         ties the file descriptor to the returned DIR* pointer.
13151         * lib/openat.c (unlinkat): New function.
13152         * lib/openat.h (unlinkat): Add prototype.
13153         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
13154         (openat_restore_fail): Rename from openat_restore_die.
13155         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
13156
13157         Provide an alternative to exiting immediately upon save_cwd or
13158         restore_cwd failure.  Now, an application can arrange e.g.,
13159         to perform a longjump in that case.
13160         * lib/openat.c: Include dirname.h.
13161         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
13162         (rpl_openat, fdopendir, fstatat): Call openat_save_die
13163         and openat_restore_die rather than calling error directly.
13164         Don't include "error.h" or "exitfail.h"; they're no longer needed.
13165
13166         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
13167         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
13168         define.
13169
13170         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
13171         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
13172                             int utc, int nanoseconds);
13173         Background:
13174         date should not have to allocate a megabyte of virtual memory to
13175         handle a format argument like +%1048575T.  When implemented with
13176         strftime, it must allocate such a buffer, use strftime to fill it
13177         in, print it, then free it.
13178         With fprintftime, it simply prints everything and exits.
13179         With no need for memory allocation, that's one fewer way to fail.
13180         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
13181         optional field width, not before, so we accept %9:z, not %:9z.
13182         (my_strftime): Be sure to use L_('x') for literals.
13183
13184         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
13185         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
13186         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
13187         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
13188         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
13189         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
13190         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
13191         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
13192         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
13193         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
13194         * lib/xgethostname.c, lib/xreadlink.c:
13195         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
13196
13197         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
13198         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
13199         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
13200         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
13201         and don't include <sys/file.h>).
13202
13203 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
13204
13205         Sync from coreutils.
13206
13207         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
13208         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
13209         [!LDAV_DONE]: Avoid unused variable warning.
13210
13211 2005-09-21  Bruno Haible  <bruno@clisp.org>
13212
13213         * lib/unicodeio.h (unicode_to_mb): New declaration.
13214
13215 2005-09-20  Derek Price  <derek@ximbiot.com>
13216
13217         * lib/getaddrinfo.c: Don't include <netdb.h> included from
13218         getaddrinfo.h.
13219
13220 2005-09-20  Bruno Haible  <bruno@clisp.org>
13221
13222         * gnulib-tool: Remove trailing slashes from the values specified for
13223         --source-base, --m4-base, --tests-base, --aux-dir.
13224         Suggested by Simon Josefsson <jas@extundo.com>.
13225
13226 2005-09-20  Bruno Haible  <bruno@clisp.org>
13227
13228         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
13229         func_modules_to_filelist, func_import, func_create_testdir): Make all
13230         sorting results locale-independent, so that gnulib-cache.m4 doesn't
13231         change when gnulib-tool is invoked in a different locale.
13232
13233 2005-09-19  Simon Josefsson  <jas@extundo.com>
13234
13235         * m4/socklen.m4: Fix typo.
13236
13237 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13238
13239         Use a consistent style for including <config.h>.
13240         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
13241         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
13242         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
13243         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
13244         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
13245         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
13246         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
13247         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
13248         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
13249         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
13250         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
13251         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
13252         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
13253         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
13254         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
13255         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
13256         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
13257         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
13258         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
13259         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
13260         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
13261         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
13262         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
13263         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
13264         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
13265         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
13266         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
13267         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
13268         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
13269         lib/xstrtoumax.c, lib/yesno.c:
13270         Standardize inclusion of config.h.
13271         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
13272         lib/inttostr.h:  Removed inclusion of config.h from header files.
13273         * lib/inttostr.c:  Adjusted in-tree users.
13274         * lib/timespec.h: Remove superfluous warning to include config.h.
13275         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
13276         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
13277         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
13278         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
13279         config.h with HAVE_CONFIG_H.
13280
13281 2005-09-19  Jim Meyering  <jim@meyering.net>
13282
13283         * modules/pathmax (License): Change to LGPL.
13284
13285 2005-09-19  Derek Price  <derek@ximbiot.com>
13286
13287         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
13288
13289 2005-09-19  Bruno Haible  <bruno@clisp.org>
13290
13291         * gnulib-tool (import): Provide default for --tests-base.
13292
13293 2005-09-19  Bruno Haible  <bruno@clisp.org>
13294
13295         * doc/quote.texi: New file, extracted from gnulib.texi.
13296         * doc/ctime.texi: New file, extracted from gnulib.texi.
13297         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
13298         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
13299         * doc/gnulib.texi: Include them.
13300
13301 2005-09-18  Bruno Haible  <bruno@clisp.org>
13302
13303         Portability fix.
13304         * gnulib-tool (func_readlink): New function.
13305         (func_ln_if_changed): Use it.
13306
13307 2005-09-18  Bruno Haible  <bruno@clisp.org>
13308
13309         * gnulib-tool: Support --with-tests also with --import.
13310         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
13311         (func_import): Use variables $testsbase and $inctests. Emit a
13312         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
13313         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
13314         SUBDIRS += $testsdir.
13315         (func_create_testdir): Update.
13316
13317 2005-09-18  Bruno Haible  <bruno@clisp.org>
13318
13319         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
13320         instead of $dry_run.
13321         (func_cp_if_changed, func_mv_if_changed): Remove functions.
13322         (func_ln_if_changed): Don't handle dry-run here.
13323         (func_import): In dry-run mode, detect more precisely which actions
13324         would be performed, and don't use "...ing" verbs.
13325
13326 2005-09-18  Bruno Haible  <bruno@clisp.org>
13327
13328         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
13329         (func_import): Use join on two temporary files instead of three nested
13330         loops, in order to determine which files are new or old.
13331
13332 2005-09-18  Bruno Haible  <bruno@clisp.org>
13333
13334         * gnulib-tool (func_import): Comment out code that spits out the
13335         new files with --dry-run.
13336
13337 2005-09-18  Bruno Haible  <bruno@clisp.org>
13338
13339         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
13340
13341 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13342
13343         * lib/stat-time.h: New file.
13344         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
13345         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
13346         in a different way.
13347         (timespec_cmp): New function.
13348         * lib/utimecmp.c: Include stat-time.h.
13349         (SYSCALL_RESOLUTION): Depend on whether various struct stat
13350         members exist, not on the obsolescent ST_MTIM_NSEC.
13351         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
13352
13353 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13354
13355         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
13356
13357 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13358
13359         * MODULES.html.sh (File system functions): Add stat-time.
13360         * modules/stat-time: New file.
13361         * modules/timespec (Files): Remove m4/st_mtim.m4; this
13362         is now done in a different way, by the stat-time module.
13363         * modules/utimecmp (Depends-on): Add stat-time.
13364
13365 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
13366
13367         * m4/st_mtim.m4: Remove.  Superseded by...
13368         * m4/stat-time.m4: New file.
13369         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
13370         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
13371
13372 2005-09-15  Derek Price  <derek@ximbiot.com>
13373
13374         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
13375
13376 2005-09-15  Derek Price  <derek@ximbiot.com>
13377
13378         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
13379         * lib/regex_internal.c: Ditto, using this...
13380         (__GNUC_PREREQ): ...new macro.
13381         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
13382         using...
13383         (__GNUC_PREREQ): ...this new macro.
13384
13385         * lib/strstr.h: Include string.h. Define strstr as a macro here.
13386
13387 2005-09-15  Derek Price  <derek@ximbiot.com>
13388             Paul Eggert  <eggert@cs.ucla.edu>
13389
13390         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
13391         changes, consolidating in...
13392         * lib/regex_internal.h: ...this file.
13393
13394 2005-09-13  Jim Meyering  <jim@meyering.net>
13395
13396         * lib/canon-host.c: Filter through gnu indent and reword comments
13397         slightly.
13398         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
13399
13400 2005-09-13  Derek Price  <derek@ximbiot.com>
13401
13402         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
13403         failure.
13404         Reported by Jim Meyering  <jim@meyering.net>.
13405
13406 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13407
13408         * lib/base64.c: Typo.
13409         (base64_encode): Put b64str in initialized data section.
13410
13411 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
13412
13413         Merge glibc and coreutils changes into gnulib, plus a few
13414         extra fixes.
13415         * lib/md5.c: Use #error rather than a string.
13416         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
13417         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
13418         (__attribute__): Define to empty for non recent-GCC.
13419         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
13420         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
13421         Renamed from their non-__ counterparts, with new macros replacing
13422         them if not _LIBC.  Add __THROW attribute.
13423         (rol): Remove.
13424         (struct md5_ctx): Align buffer if using GCC.
13425         * lib/sha1.h (struct sha1_ctx): Likewise.
13426         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
13427         The old name was backwards.
13428         (NOTSWAP): Remove; not used.
13429         (rol): New macro, moved here from md5.h.
13430         (sha1_process_block): Remove a FIXME that doesn't make sense.
13431
13432 2005-09-12  Derek Price  <derek@ximbiot.com>
13433
13434         Return usable errors from canon-host.
13435         * lib/canon-host.h: New file.
13436         * lib/canon-host.c (canon_host): Wrap...
13437         (canon_host_r): ...this new function, which now relies exclusively on
13438         getaddrinfo.
13439         (ch_strerror): New function.
13440         (last_cherror): New global.
13441         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
13442         interface.
13443         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
13444         void *.
13445         (freeaddrinfo): Free ai->ai_canonname when set.
13446
13447 2005-09-12  Derek Price  <derek@ximbiot.com>
13448
13449         Make canon-host require getaddrinfo.
13450         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
13451         AC_LIBSOURCE canon-host.h.  Call...
13452         (gl_PREREQ_CANON_HOST): ...this new function, which requires
13453         gl_GETADDRINFO.
13454         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
13455
13456 2005-09-12  Derek Price  <derek@ximbiot.com>
13457
13458         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
13459         LGPL.
13460         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
13461
13462 2005-09-12  Derek Price  <derek@ximbiot.com>
13463
13464         * lib/gai_strerror.c: Include config.h when available.  Include
13465         getaddrinfo.h before other headers to test interface.
13466         Reported by Larry Jones <lawrence.jones@ugs.com>.
13467
13468 2005-09-12  Derek Price  <derek@ximbiot.com>
13469             Paul Eggert  <eggert@cs.ucla.edu>
13470
13471         * modules/glob (Files): Add glob-libc.h.
13472
13473 2005-09-12  Derek Price  <derek@ximbiot.com>
13474             Paul Eggert  <eggert@cs.ucla.edu>
13475
13476         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
13477         glob_.h, glob-libc.h.
13478         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
13479
13480 2005-09-12  Derek Price  <derek@ximbiot.com>
13481             Paul Eggert  <eggert@cs.ucla.edu>
13482
13483         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
13484         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
13485         protecting things that should be done only in gnulib contexts.
13486         * lib/glob_.h: New file, containing only the glob things needed for
13487         gnulib.
13488         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
13489         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
13490         (glob, globfree, glob_pattern_p): Now defined simply in terms of
13491         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
13492         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
13493         and to respect the namespace rules better.
13494
13495 2005-09-08  Simon Josefsson  <jas@extundo.com>
13496
13497         * modules/socklen: New file.
13498
13499 2005-09-08  Simon Josefsson  <jas@extundo.com>
13500
13501         * m4/socklen.m4: New file.
13502
13503 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
13504
13505         * modules/utimens (Files): Add m4/utimbuf.m4, since
13506         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
13507         Reported by Sergey Poznyakoff.
13508
13509 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
13510
13511         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
13512         definitions, since that's the preferred style in glibc.
13513         Fix a minor spacing issue, and update copyright notice to match
13514         glibc's.
13515
13516 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
13517
13518         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
13519
13520 2005-09-06  Simon Josefsson  <jas@extundo.com>
13521
13522         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
13523         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
13524
13525 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
13526
13527         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
13528         warning.
13529
13530 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
13531
13532         * config/srclist.txt: Add glibc bug 1302.
13533
13534 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
13535
13536         Change bitset word type from unsigned int to unsigned long int,
13537         as this has better performance on typical 64-bit hosts.
13538         Port bitset code to hosts with unusual word sizes.
13539         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
13540         (build_collating_symbol):
13541         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
13542         argument is a bitset.  This is merely a style issue, but it makes
13543         it clearer that an entire array is expected.
13544         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
13545         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
13546         Port to the case where bitset_word is not the same as unsigned int.
13547         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
13548         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
13549         Likewise.
13550         * lib/regexec.c (check_dst_limits_calc_pos_1,
13551         check_subexp_matching_top):
13552         (build_trtable, group_nodes_into_DFAstates):
13553         Likewise.
13554         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
13555         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
13556         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
13557         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
13558         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
13559         * lib/regcomp.c (optimize_subexps, lower_subexp):
13560         Work even if bitset_word has holes in its bitwise representation.
13561         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
13562         * lib/regexec.c (check_dst_limits_calc_pos_1,
13563         check_subexp_matching_top):
13564         Likewise.
13565         * lib/regex_internal.c (re_string_reconstruct):
13566         Don't assume UCHAR_MAX == 255.
13567         * lib/regex_internal.h (bitset_set_all): Likewise.
13568         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
13569         All uses changed.
13570         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
13571         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
13572         All uses changed.
13573         (BITSET_WORD_MAX): New macro.
13574         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
13575         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
13576         (bitset_empty, bitset_copy):
13577         Prefer sizeof (bitset) to multiplying it out ourselves.
13578         (bitset_not_merge): Remove; unused.
13579         (bitset_contain): Return bool, not unsigned int with one bit on.
13580         All callers changed.
13581         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
13582         alignment than re_node_set; do this by defining a new internal
13583         type struct dests_alloc and using it to allocate memory.
13584
13585 2005-09-05  Bruno Haible  <bruno@clisp.org>
13586
13587         * gnulib-tool (func_import): Fix comparison in handling of symbolic
13588         links.
13589
13590 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
13591
13592         * modules/size_max (Makefile.am): Add size_max.h
13593
13594 2005-09-04  Derek Price  <derek@ximbiot.com>
13595
13596         * gnulib-tool (func_import): Fix reversed $symbolic logic.
13597
13598 2005-09-03  Simon Josefsson  <jas@extundo.com>
13599
13600         * gnulib-tool: Fix typo.
13601
13602 2005-09-03  Simon Josefsson  <jas@extundo.com>
13603
13604         * config/srclist.txt: Add glibc bug 1293.
13605
13606 2005-09-03  Derek Price  <derek@ximbiot.com>
13607
13608         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
13609         From Larry Jones <lawrence.jones@ugs.com>.
13610
13611 2005-09-02  Simon Josefsson  <jas@extundo.com>
13612
13613         * modules/socklen: New file.
13614
13615 2005-09-02  Simon Josefsson  <jas@extundo.com>
13616
13617         * modules/havelib: New module.
13618
13619         * modules/gettext, modules/iconv, modules/lock, modules/readline:
13620         Use havelib.
13621
13622 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
13623
13624         Check for arithmetic overflow when calculating sizes, to prevent
13625         some buffer-overflow issues.  These patches are conservative, in the
13626         sense that when I couldn't determine whether an overflow was possible,
13627         I inserted a run-time check.
13628         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
13629         macros.
13630         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
13631         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
13632         (re_xnrealloc, re_x2nrealloc): New inline functions.
13633         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
13634         parse_bracket_exp):
13635         (build_equiv_class, build_charclass): Check for arithmetic overflow
13636         in size expression calculations.
13637         * lib/regex_internal.c (re_string_realloc_buffers):
13638         (build_wcs_upper_buffer, re_node_set_add_intersect):
13639         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
13640         (re_dfa_add_node, register_state): Likewise.
13641         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
13642         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
13643         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
13644         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
13645
13646 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
13647
13648         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
13649         m4/ulonglong.m4.  Problem reported by Martin Lambers.
13650
13651 2005-09-02  Bruno Haible  <bruno@clisp.org>
13652
13653         Support for lib vs. lib64 distinction on biarch platforms.
13654         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
13655         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
13656         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
13657
13658 2005-09-02  Bruno Haible  <bruno@clisp.org>
13659
13660         * gnulib-tool (import): In the other first-use case, provide defaults
13661         as well.
13662
13663 2005-09-02  Bruno Haible  <bruno@clisp.org>
13664
13665         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
13666         patches not yet found in the latest gettext release.
13667
13668 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
13669
13670         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
13671         to avoid a collision with bits/local_lim.h in glibc.
13672         All uses changed.  Problem reported by Dmitry V. Levin in
13673         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
13674
13675         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
13676         bugs in int versus size_t comparisons.
13677         (re_string_context_at): Fix bug where the code assumed that
13678         Idx is signed.
13679
13680         Use bool where appropriate.
13681         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
13682         All callers changed.
13683         (calc_eclosure_iter): Likewise, for ROOT arg.
13684         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
13685         (build_charclass_op): Likewise, for NON_MATCH arg.
13686         * lib/regex_internal.c (re_string_allocate, re_string_construct):
13687         (re_string_construct_common): Likewise, for ICASE arg.
13688         * lib/regexec.c (re_search_2_stub, re_search_stub):
13689         Likewise, for RET_LEN arg.
13690         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
13691         (set_regs): Likewise, for FL_BACKTRACK arg.
13692         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
13693         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
13694         (calc_eclosure_iter, parse_bracket_exp):
13695         Use bool for internal variables that are booleans.
13696         * lib/regexec.c (re_search_internal, check_matching,
13697         proceed_next_node):
13698         (set_regs, build_sifted_states, sift_states_bkref):
13699         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
13700         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
13701         (find_collation_sequence_value):
13702         Likewise.
13703         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
13704         (re_node_set_compare):
13705         Return bool, not int. All callers changed.
13706         * lib/regexec.c (check_halt_node_context, check_dst_limits):
13707         (build_trtable, check_node_accept): Likewise.
13708         * lib/regex_internal.h: Include stdbool.h.
13709
13710         Fix bugs uncovered when converting to bool.
13711         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
13712         failure instead of charging ahead blindly.
13713         * lib/regex_internal.c (register_state): Likewise.
13714         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
13715         for freeing internal storage.
13716         (group_nodes_into_DFA_states): Use unsigned int, not int, for
13717         bitset pieces used as boolean, to avoid undefined behavior
13718         on hosts that do int overflow checking.
13719
13720 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
13721
13722         * config/srclist.txt: Add glibc bugs 1285-1287.
13723
13724 2005-09-01  Jim Meyering  <jim@meyering.net>
13725
13726         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
13727         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
13728         Require gl_STAT_MACROS, too.
13729
13730 2005-09-01  Bruno Haible  <bruno@clisp.org>
13731
13732         * gnulib-tool (import): In the first-use case, provide defaults.
13733
13734 2005-09-01  Bruno Haible  <bruno@clisp.org>
13735
13736         * gnulib-tool (func_import): Remove the .tmp files.
13737
13738 2005-09-01  Bruno Haible  <bruno@clisp.org>
13739
13740         * gnulib-tool (func_import): Fix handling of symbolic links.
13741
13742 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
13743
13744         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
13745         old glibc regex code mishandles strings longer than 2**31 bytes.
13746         This patch fixes this when the regex code is used in gnulib
13747         (i.e., outside glibc).
13748
13749         This patch should not affect the use of the regex code inside
13750         glibc.  No doubt this problem also needs to be handled for glibc
13751         as well, but the result will be an incompatible change to the
13752         glibc ABI, and the old ABI will have to be supported too.  That
13753         can be the the subject for another patch.
13754
13755         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
13756         governing whether the rest of this patch is active.  By default,
13757         the macro is disabled and the patch has no effect.
13758         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
13759         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
13760         (struct re_pattern_buffer, re_search, re_search_2, re_match):
13761         (re_match_2, re_set_registers): Use the new types.
13762         * lib/regex_internal.h (Idx, re_hashval_t): New types.
13763         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
13764         New macros.
13765         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
13766         (re_string_context_at, bin_tree_t, re_dfastate_t):
13767         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
13768         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
13769         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
13770         (re_string_char_size_at, re_string_wchar_at):
13771         (re_string_elem_size_at):
13772         Use the new types and macros to port to 64-bit hosts.
13773         Use unsigned types for internal values, so that the code
13774         mostly works even for arrays larger than SSIZE_MAX.
13775         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
13776         (search_duplicated_node, calc_eclosure_iter, fetch_number):
13777         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
13778         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
13779         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
13780         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
13781         (calc_inveclosure, parse_dup_op, build_range_exp):
13782         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
13783         (fetch_number, create_token_tree, mark_opt_subexp):
13784         Likewise.
13785         * lib/regex_internal.c (re_string_construct_common,
13786         create_ci_newstate):
13787         (create_cd_newstate, re_string_allocate, re_string_construct):
13788         (re_string_realloc_buffers, build_wcs_upper_buffer):
13789         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
13790         (re_string_reconstruct, re_string_peek_byte_case):
13791         (re_string_fetch_byte_case, re_string_context_at):
13792         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
13793         (re_node_set_init_copy, re_node_set_add_intersect):
13794         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
13795         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
13796         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
13797         (re_acquire_state, re_acquire_state_context, register_state):
13798         Likewise.
13799         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
13800         search_cur_bkref_entry):
13801         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
13802         (re_search_internal, re_search_2_stub, re_search_stub)
13803         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
13804         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
13805         (update_cur_sifted_state, check_dst_limits):
13806         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
13807         (check_subexp_limits, sift_states_bkref, merge_state_array):
13808         (check_subexp_matching_top, get_subexp, get_subexp_sub):
13809         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
13810         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
13811         (expand_bkref_cache, check_node_accept_bytes):
13812         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
13813         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
13814         (acquire_init_state_context, check_halt_node_context):
13815         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
13816         (sift_states_backward, clean_state_log_if_needed):
13817         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
13818         (find_recover_state, transit_state_sb, transit_state_mb):
13819         (transit_state_bkref, build_trtable, match_ctx_clean):
13820         Likewise.
13821         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
13822         to work around an assumption that REG_MISSING is negative.
13823
13824         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
13825         (seek_collating_symbol_entry) [defined _LIBC]:
13826         (lookup_collation_sequence_value) [defined _LIBC]:
13827         (build_range_exp, build_collating_symbol) [defined _LIBC]:
13828         Use prototypes rather than old-style function definitions.
13829         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
13830         (transit_state_sb) [0]:
13831         (find_collation_sequence_value) [defined _LIBC]: Likewise.
13832
13833         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
13834         rm_eo.
13835
13836         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
13837         (optimize_subexps, lower_subexp):
13838         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
13839         since the signed shift might overflow.  Use 1u<<31 instead.
13840         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
13841         Likewise.
13842         * lib/regexec.c (check_dst_limits_calc_pos_1,
13843         check_subexp_matching_top): Likewise.
13844
13845         * lib/regcomp.c (optimize_subexps, lower_subexp):
13846         Use CHAR_BIT rather than 8, for clarity.
13847         * lib/regexec.c (check_dst_limits_calc_pos_1):
13848         (check_subexp_matching_top): Likewise.
13849         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
13850         have to worry about portability issues when shifting it left.
13851         Remove no-longer-needed test for table_size > 0.
13852         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
13853         in a word, as the resulting behavior is undefined.
13854         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
13855         in one case, a <= should have been an <, and in another case the
13856         whole test was missing.
13857         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
13858         the standard name CHAR_BIT.
13859         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
13860         this is not true on one's complement and signed-magnitude hosts.
13861
13862         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
13863         next_last_offset.
13864         (struct re_dfa_t): Remove unused member states_alloc.
13865         * lib/regcomp.c (init_dfa): Don't initialize unused members.
13866
13867 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
13868
13869         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
13870         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
13871         and large-file glibc and in 32-bit large-file Solaris.
13872
13873 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
13874
13875         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
13876         lengths fit in regoff_t; this isn't true if regoff_t is the same
13877         width as size_t.
13878         * lib/regex.c (re_search_internal): 5th arg is LAST_START
13879         (= START + RANGE) instead of RANGE.  This avoids overflow
13880         problems when regoff_t is the same width as size_t.
13881         All callers changed.
13882         (re_search_2_stub): Check for overflow when adding the
13883         sizes of the two strings.
13884         (re_search_stub): Check for overflow when adding START
13885         to RANGE; if it occurs, substitute the extreme value.
13886
13887 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
13888
13889         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
13890
13891 2005-08-31  Jim Meyering  <jim@meyering.net>
13892
13893         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
13894         a pointer-to-const.
13895         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
13896         (register_state): Likewise.
13897         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
13898         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
13899         (group_nodes_into_DFAstates): Likewise.
13900
13901 2005-08-31  Jim Meyering  <jim@meyering.net>
13902
13903         * check-module: Add a FIXME comment.
13904
13905 2005-08-31  Eric Blake  <ebb9@byu.net>
13906
13907         * modules/unistd-safer (Files): Add unistd--.h.
13908         * modules/stdio-safer (Files): Add stdio--.h.
13909
13910 2005-08-31  Derek Price  <derek@ximbiot.com>
13911
13912         * lib/getdelim.c (getdelim): Return EOF on EOF.
13913         Reported by Larry Jones <lawrence.jones@ugs.com>.
13914
13915 2005-08-31  Bruno Haible  <bruno@clisp.org>
13916
13917         Avoid unnecessary diffs in the generated lib/Makefile.am.
13918         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
13919         the generated files.
13920         (func_import): Don't set cmd.
13921
13922 2005-08-31  Bruno Haible  <bruno@clisp.org>
13923
13924         * lib/strstr.c: Include <stddef.h>, for NULL.
13925         * lib/strcasestr.c: Likewise.
13926         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
13927
13928 2005-08-31  Bruno Haible  <bruno@clisp.org>
13929
13930         * gnulib-tool: New option --macro-prefix.
13931         (func_import): Use macro_prefix.
13932         (import): Handle option --macro-prefix.
13933
13934 2005-08-31  Bruno Haible  <bruno@clisp.org>
13935
13936         * gnulib-tool (import): Rename most ac_* variables to cached_*.
13937         Also use new variables cached_lgpl, cached_libtool.
13938
13939 2005-08-31  Bruno Haible  <bruno@clisp.org>
13940
13941         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
13942         always instantiating them.
13943
13944 2005-08-31  Bruno Haible  <bruno@clisp.org>
13945
13946         * gnulib-tool (func_import): Read the previous cached settings
13947         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
13948         earlier added by gnulib but are now dropped. Warn when a gnulib file
13949         overwrites a non-gnulib file.
13950
13951 2005-08-31  Bruno Haible  <bruno@clisp.org>
13952
13953         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
13954         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
13955         projects that don't keep autogenerated files in CVS. Put into
13956         actioncmd only the specified modules, not the transitive closure.
13957
13958 2005-08-31  Bruno Haible  <bruno@clisp.org>
13959
13960         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
13961         Create directories that shall be filled.
13962         (import): Don't look for gl_* macros in configure.ac. Recurse across
13963         all directories containing a gnulib-cache.m4 files, if meaningful.
13964
13965 2005-08-31  Bruno Haible  <bruno@clisp.org>
13966
13967         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
13968         (import): Set seen_libtool when we see gl_LIBTOOL.
13969
13970 2005-08-31  Bruno Haible  <bruno@clisp.org>
13971
13972         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
13973         declaration macro definitions from generated gnulib.m4.
13974
13975 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
13976
13977         * lib/iconvme.h: Add prototype for iconv_alloc.
13978
13979 2005-08-29  Simon Josefsson  <jas@extundo.com>
13980
13981         * lib/iconvme.c: Fix errno.
13982
13983 2005-08-29  Bruno Haible  <bruno@clisp.org>
13984
13985         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
13986         that it works when the directory contains spaces.
13987
13988 2005-08-29  Bruno Haible  <bruno@clisp.org>
13989
13990         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
13991
13992 2005-08-29  Bruno Haible  <bruno@clisp.org>
13993
13994         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
13995         Emit more advice.
13996
13997 2005-08-29  Bruno Haible  <bruno@clisp.org>
13998         and Stepan Kasal  <kasal@ucw.cz>
13999
14000         * check-module: If more parameters are given, check each of them
14001         separately; add more exceptions, as noted by Jim Meyering.
14002         (check_module): New procedure.
14003         (%exempt_header): Now contains all exceptions.
14004
14005 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
14006
14007         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
14008
14009 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14010
14011         * lib/iconvme.c: Split iconv_string into iconv_alloc.
14012
14013 2005-08-28  Bruno Haible  <bruno@clisp.org>
14014
14015         * m4/gnulib-tool.m4: New file.
14016
14017 2005-08-27  Jim Meyering  <jim@meyering.net>
14018
14019         * modules/unistd-safer (Files): Add pipe-safer.c.
14020         * modules/fcntl-safer (Files): Add creat-safer.c.
14021
14022 2005-08-27  Jim Meyering  <jim@meyering.net>
14023
14024         * m4/stdlib-safer.m4: New file.  From coreutils.
14025         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
14026         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
14027         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
14028         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
14029         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
14030
14031 2005-08-27  Jim Meyering  <jim@meyering.net>
14032
14033         * lib/fopen-safer.c: Merge minor changes from coreutils.
14034         * lib/dup-safer.c: Likewise.
14035         * lib/fd-safer.c: Likewise.
14036
14037         Merge from coreutils.
14038         * lib/stdio--.h: New file.
14039         * lib/stdlib--.h: New file.
14040         * lib/mkstemp-safer.c: New file.
14041
14042         GNU tar needs these.
14043         * lib/pipe-safer.c: New file.
14044         * lib/creat-safer.c: New file.
14045         * lib/fcntl--.h (creat): Define to creat_safer.
14046         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
14047         * lib/unistd--.h (pipe): Define to pipe_safer.
14048         * lib/unistd-safer.h: Declare pipe_safer.
14049
14050 2005-08-26  Simon Josefsson  <jas@extundo.com>
14051
14052         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
14053         Haible <bruno@clisp.org>.
14054
14055 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
14056
14057         * lib/regex_internal.h: Remove all references to
14058         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
14059         or better.
14060         (bitset_not, bitset_merge, bitset_not_merge):
14061         (bitset_mask, re_string_allocate, re_string_construct):
14062         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
14063         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
14064         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
14065         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
14066         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14067         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14068         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
14069         (re_acquire_state_context):
14070         Remove unnecessary forward decls.
14071         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
14072         Put __attribute at function definition,
14073         now that the function decl has been removed.
14074         * lib/regex_internal.c (re_string_peek_byte_case):
14075         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
14076         Likewise.
14077
14078 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
14079
14080         * m4/regex.m4: Add AC_PREREQ(2.50).
14081         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
14082
14083 2005-08-25  Simon Josefsson  <jas@extundo.com>
14084
14085         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
14086         __fsetlocking.
14087
14088 2005-08-25  Simon Josefsson  <jas@extundo.com>
14089
14090         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
14091         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
14092         GLIBC specific code.
14093
14094 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14095
14096         Make regex safe for g++.  This fixes one real bug (an "err"
14097         that should have been "*err").  g++ problem reported by
14098         Sam Steingold.
14099         * lib/regex_internal.h (re_calloc): New macro, consistent with
14100         re_malloc etc.  All callers of calloc changed to use re_calloc.
14101         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
14102         not int.  All callers changed.
14103         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
14104         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
14105         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
14106         (find_recover_state): Change "err" to "*err"; this fixes what
14107         appears to be a real bug.
14108         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
14109         versus int.
14110
14111 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14112
14113         * modules/regex (Depends-on): Add malloc, since the code
14114         assumes that !malloc(0) means failure.
14115
14116 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14117
14118         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
14119
14120         alloca modernization/simplification for regex.
14121         * lib/regex.c: Remove portability cruft for alloca.  This no longer
14122         needs to be at the start of the file, and can be moved into
14123         regex_internal.h and simplified.
14124         * lib/regex_internal.h: Include <alloca.h>.
14125         (__libc_use_alloca) [!defined _LIBC]: New macro.
14126         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
14127         now works outside glibc.
14128
14129 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14130
14131         * config/srclist.txt: Add glibc bugs 1241, 1245.
14132
14133 2005-08-25  Jim Meyering  <jim@meyering.net>
14134
14135         * lib/open-safer.c: Include <config.h>.
14136         Otherwise, we'd lose LARGEFILE support in any file using
14137         e.g. "fcntl--.h"
14138
14139 2005-08-25  Bruno Haible  <bruno@clisp.org>
14140
14141         * m4/minmax.m4: Require autoconf 2.52.
14142         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
14143         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
14144         alternatives of translit over the alphabet.
14145         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
14146
14147 2005-08-24  Simon Josefsson  <jas@extundo.com>
14148
14149         * tests/test-getpass.c: New file.
14150
14151 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14152
14153         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
14154         for GNU regex features.
14155
14156 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14157
14158         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
14159         * lib/regex.h (regerror): Likewise.
14160
14161         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
14162         requires this.  (The code never needed it.)
14163
14164         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
14165         All uses of recently-renamed identifiers changed to use the new,
14166         POSIX-compliant names.  The code will build and run just fine
14167         without these changes, but it's better to eat our own dog food
14168         and use the standard-conforming names.
14169
14170         * lib/regex.h: Fix a multitude of POSIX name space violations.
14171         These changes have an effect only for programs that define
14172         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
14173         do not change anything for programs compiled in the normal way.
14174         Also, there is no effect on the ABI.
14175
14176         (_REGEX_SOURCE): New macro.
14177         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
14178         defined and _GNU_SOURCE is not; this fixes a name space violation.
14179
14180         Rename the following macros to obey POSIX requirements.
14181         The old names are still visible as macros if _REGEX_SOURCE is defined.
14182         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
14183         RE_BACKSLASH_ESCAPE_IN_LISTS.
14184         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
14185         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
14186         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
14187         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
14188         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
14189         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
14190         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
14191         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
14192         (REG_INTERVALS): renamed from RE_INTERVALS.
14193         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
14194         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
14195         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
14196         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
14197         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
14198         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
14199         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
14200         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
14201         RE_UNMATCHED_RIGHT_PAREN_ORD.
14202         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
14203         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
14204         (REG_DEBUG): renamed from RE_DEBUG.
14205         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
14206         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
14207         unusual, since we can't clash with the POSIX REG_ICASE.
14208         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
14209         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
14210         (REG_NO_SUB): renamed from RE_NO_SUB.
14211         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
14212         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
14213         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
14214         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
14215         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
14216         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
14217         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
14218         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
14219         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
14220         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
14221         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
14222         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
14223         RE_SYNTAX_POSIX_MINIMAL_BASIC.
14224         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
14225         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
14226         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
14227         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
14228         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
14229         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
14230         (REG_FIXED): Renamed from REGS_FIXED.
14231         (REG_NREGS): Renamed from RE_NREGS.
14232
14233         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
14234         of other REG_* macros, since POSIX says the user is allowed to
14235         #undef these macros selectively.
14236
14237         (reg_errcode_t): Update comment stating what other tables need
14238         to be consistent.
14239
14240         Rename the following enum values to obey POSIX requirements.
14241         The old names are still visible as macros.
14242         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
14243         is not defined, since GNU is supposed to be a superset of POSIX as
14244         much as possible, and since we want reg_errcode_t to be a signed
14245         type for implementation consistency.
14246         (_REG_NOERROR): Renamed from REG_NOERROR.
14247         (_REG_NOMATCH): Renamed from REG_NOMATCH.
14248         (_REG_BADPAT): Renamed from REG_BADPAT.
14249         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
14250         (_REG_ECTYPE): Renamed from REG_ECTYPE.
14251         (_REG_EESCAPE): Renamed from REG_EESCAPE.
14252         (_REG_ESUBREG): Renamed from REG_ESUBREG.
14253         (_REG_EBRACK): Renamed from REG_EBRACK.
14254         (_REG_EPAREN): Renamed from REG_EPAREN.
14255         (_REG_EBRACE): Renamed from REG_EBRACE.
14256         (_REG_BADBR): Renamed from REG_BADBR.
14257         (_REG_ERANGE): Renamed from REG_ERANGE.
14258         (_REG_ESPACE): Renamed from REG_ESPACE.
14259         (_REG_BADRPT): Renamed from REG_BADRPT.
14260         (_REG_EEND): Renamed from REG_EEND.
14261         (_REG_ESIZE): Renamed from REG_ESIZE.
14262         (_REG_ERPAREN): Renamed from REG_ERPAREN.
14263         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
14264         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
14265         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
14266         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
14267
14268         (_REG_RE_NAME, _REG_RM_NAME): New macros.
14269         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
14270         changed.  But support the old name if the new one is not defined
14271         and if _REGEX_SOURCE.
14272
14273         Change the following member names in struct re_pattern_buffer.
14274         The old names are still supported if !_REGEX_SOURCE.
14275         The new names are always supported, regardless of _REGEX_SOURCE.
14276         (re_buffer): Renamed from buffer.
14277         (re_allocated): Renamed from allocated.
14278         (re_used): Renamed from used.
14279         (re_syntax): Renamed from syntax.
14280         (re_fastmap): Renamed from fastmap.
14281         (re_translate): Renamed from translate.
14282         (re_can_be_null): Renamed from can_be_null.
14283         (re_regs_allocated): Renamed from regs_allocated.
14284         (re_fastmap_accurate): Renamed from fastmap_accurate.
14285         (re_no_sub): Renamed from no_sub.
14286         (re_not_bol): Renamed from not_bol.
14287         (re_not_eol): Renamed from not_eol.
14288         (re_newline_anchor): Renamed from newline_anchor.
14289
14290         Change the following member names in struct re_registers.
14291         The old names are still supported if !_REGEX_SOURCE.
14292         The new names are always supported, regardless of _REGEX_SOURCE.
14293         (rm_num_regs): Renamed from num_regs.
14294         (rm_start): Renamed from start.
14295         (rm_end): Renamed from end.
14296
14297         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
14298         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
14299         Prepend __ to parameter names.
14300
14301         Undo yesterday's changes.
14302
14303 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14304
14305         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
14306         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
14307         lib/regex.c.
14308
14309 2005-08-24  Jim Meyering  <jim@meyering.net>
14310
14311         Sync from coreutils.
14312         * m4/fcntl-safer.m4: New file.
14313
14314         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
14315         and object files for this module.
14316
14317 2005-08-24  Jim Meyering  <jim@meyering.net>
14318
14319         Sync from coreutils.
14320         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
14321
14322 2005-08-24  Jim Meyering  <jim@meyering.net>
14323
14324         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
14325         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
14326
14327 2005-08-24  Jim Meyering  <jim@meyering.net>
14328
14329         * modules/fcntl-safer: New module.
14330         * modules/fts (Depends-on): Add fcntl-safer.
14331         * MODULES.html.sh (File descriptor based Input/Output):
14332         Add fcntl-safer.
14333
14334 2005-08-24  Bruno Haible  <bruno@clisp.org>
14335
14336         Support for unit test modules.
14337         * modules/README: Mention tests modules.
14338         * modules/TEMPLATE-TESTS: New file.
14339         * gnulib-tool: New options --extract-tests-module, --with-tests and
14340         --tests-base (unused for the moment).
14341         (testsbase, inctests): New variables.
14342         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
14343         (func_verify_module): Exclude TEMPLATE-TESTS.
14344         (func_verify_nontests_module, func_verify_tests_module): New functions.
14345         (func_get_dependencies): Add implicit dependency for tests modules.
14346         (func_get_tests_module): New function.
14347         (func_modules_transitive_closure): When --with-tests was specified,
14348         include the unit tests as well, unless explicitly avoided.
14349         (func_emit_lib_Makefile_am): Ignore the tests modules here.
14350         (func_emit_tests_Makefile_am): New function.
14351         (func_create_testdir): When --with-tests was specified, emit a
14352         tests/ directory.
14353         * MODULES.html.sh (Future developments): Update.
14354
14355 2005-08-24  Bruno Haible  <bruno@clisp.org>
14356
14357         * modules/tls-tests: New file.
14358         * tests/test-tls.c: New file, from GNU gettext.
14359
14360 2005-08-24  Bruno Haible  <bruno@clisp.org>
14361
14362         * modules/lock-tests: New file.
14363         * tests/test-lock.c: New file, from GNU gettext.
14364
14365 2005-08-24  Bruno Haible  <bruno@clisp.org>
14366
14367         * lib/lock.h: Add multiple inclusion guard.
14368         * lib/tls.h: Add multiple inclusion guard.
14369
14370 2005-08-24  Bruno Haible  <bruno@clisp.org>
14371
14372         * gnulib-tool: Add support for the --aux-dir option to
14373         --create-testdir, --create-megatestdir, --test, --megatest.
14374         (func_create_testdir, func_create_megatestdir): Optionally emit a
14375         AC_CONFIG_AUX_DIR directive.
14376         (create-testdir, create-megatestdir, test, megatest): Provide a
14377         default value for $auxdir.
14378
14379 2005-08-24  Bruno Haible  <bruno@clisp.org>
14380
14381         * gnulib-tool (import): Use compound statement instead of subshell
14382         where possible.
14383
14384 2005-08-24  Bruno Haible  <bruno@clisp.org>
14385
14386         * gnulib-tool (import): Change --aux-dir default to "build-aux".
14387
14388 2005-08-24  Bruno Haible  <bruno@clisp.org>
14389
14390         * gnulib-tool (func_version): Update.
14391
14392 2005-08-24  Bruno Haible  <bruno@clisp.org>
14393
14394         * gnulib-tool (func_import, func_create_testdir,
14395         func_create_megatestdir): Quote all autoconf macro arguments.
14396
14397 2005-08-24  Bruno Haible  <bruno@clisp.org>
14398
14399         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
14400         option --force, because --force causes the aclocal.m4 of each
14401         subdirectory to be newer than the corresponding config.h.in.
14402
14403 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14404
14405         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
14406         All contents moved to gl_REGEX.
14407         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
14408         assume that it does.
14409
14410 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14411
14412         * lib/regex.h (REG_NOSYS)
14413         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
14414         Define, since POSIX requires it as of 2001.
14415         (_REG_ENOSYS)
14416         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
14417         New private symbol, used to keep the enum signed in all cases.
14418         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
14419         Youngman in
14420         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
14421
14422         * lib/regex_internal.c (re_string_skip_chars, register_state):
14423         (calc_state_hash):
14424         Remove forward decls; no longer needed now that we use prototypes.
14425         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
14426         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
14427         (clean_state_log_if_needed): Likewise.
14428
14429 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14430
14431         * config/srclist.txt: Add glibc bugs 1231-1233.
14432
14433 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14434
14435         Fix problems reported by Sam Steingold in
14436         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
14437         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
14438         assumed that reg_errcode_t is a signed type, which is not
14439         necessarily true if _XOPEN_SOURCE is not defined.
14440         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
14441         since some compilers warn about it otherwise.
14442
14443 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14444
14445         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
14446         (init_word_char, create_initial_state, duplicate_node_closure):
14447         (fetch_token, peek_token_bracket, build_range_exp):
14448         (build_collating_symbol): Remove forward decls; no longer needed
14449         now that we use prototypes.
14450
14451         * lib/regcomp.c:
14452         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
14453         (re_compile_fastmap_iter, regcomp, regerror, regfree):
14454         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
14455         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
14456         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
14457         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
14458         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
14459         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
14460         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
14461         (build_range_exp, build_collating_symbol, parse_bracket_exp):
14462         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
14463         (build_charclass, build_charclass_op, fetch_number, create_tree):
14464         (create_token_tree, mark_opt_subexp, duplicate_tree):
14465         Use prototypes rather than old-style definitions.
14466
14467         * lib/regex_internal.c:
14468         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
14469         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
14470         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
14471         (re_string_reconstruct, re_string_peek_byte_case):
14472         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
14473         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
14474         (re_node_set_init_copy, re_node_set_add_intersect):
14475         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14476         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14477         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
14478         (re_acquire_state, re_acquire_state_context, register_state):
14479         (create_ci_newstate, create_cd_newstate, free_state):
14480         Likewise.
14481         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
14482         re_search_2):
14483         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
14484         (re_search_internal, prune_impossible_nodes):
14485         (acquire_init_state_context, check_matching, static):
14486         (check_halt_node_context, check_halt_state_context, proceed_next_node):
14487         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
14488         (update_regs, sift_states_backward, build_sifted_states):
14489         (clean_state_log_if_needed, merge_state_array):
14490         (update_cur_sifted_state, add_epsilon_src_nodes):
14491         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
14492         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
14493         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
14494         (find_recover_state, check_subexp_matching_top, transit_state_mb):
14495         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
14496         (check_arrival, check_arrival_add_next_nodes):
14497         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
14498         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14499         (check_node_accept_bytes, check_node_accept, extend_buffers):
14500         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
14501         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
14502         (sift_ctx_init):
14503         Likewise.
14504
14505         * lib/regex_internal.h:
14506         (re_string_allocate, re_string_construct, re_string_reconstruct):
14507         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
14508         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
14509         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
14510         (re_string_context_at, re_string_peek_byte_case):
14511         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
14512         is defined, since we now use prototypes always.
14513
14514         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
14515         C89 or better.  All uses removed.
14516
14517 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14518
14519         * config/srclist.txt: Add glibc bugs 1220-1227.
14520
14521 2005-08-20  Jim Meyering  <jim@meyering.net>
14522
14523         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
14524         of unused local, dfa.
14525
14526 2005-08-20  Bruno Haible  <bruno@clisp.org>
14527
14528         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
14529
14530 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14531
14532         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
14533         (re_node_set_insert_last, re_dfa_add_node):
14534         Rename local variables to avoid GCC shadowing warnings.
14535
14536 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14537
14538         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
14539         [defined lint]: Suppress bogus uninitialized-variable warnings.
14540
14541         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
14542         and let the caller return REG_ESPACE if out of space.  This
14543         removes an uninitialied-variable warning with GCC 4.0.1, and also
14544         avoids taking the address of a local variable.  All callers
14545         changed.
14546
14547 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
14548
14549         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
14550         $LIBCSRC/posix/regexec.c.
14551         Add glibc bug 1217 for regcomp.c.
14552
14553 2005-08-19  Jim Meyering  <jim@meyering.net>
14554
14555         * lib/regexec.c (proceed_next_node): Redo local variables to
14556         avoid GCC shadowing warnings.
14557
14558 2005-08-18  Bruno Haible  <bruno@clisp.org>
14559
14560         * lib/strstr.c (strstr): Fix return value in multibyte case.
14561         * lib/strcasestr.c (strcasestr): Likewise.
14562
14563 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
14564
14565         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
14566
14567 2005-08-17  Jim Meyering  <jim@meyering.net>
14568
14569         Make the %s format (seconds since the epoch) work for a negative
14570         number and when used with a zero-padded field width, e.g. %015s.
14571
14572         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
14573         label so that it precedes the code to set `digits'.  Otherwise,
14574         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
14575         print `00-22'.  Now, it prints `-0022', as it should.
14576
14577 2005-08-17  Bruno Haible  <bruno@clisp.org>
14578
14579         * modules/strstr (Files): Add m4/mbrtowc.m4.
14580         (Depends-on): Add mbuiter.
14581
14582 2005-08-17  Bruno Haible  <bruno@clisp.org>
14583
14584         * modules/strcasestr: New file.
14585         * MODULES.html.sh (String handling, based on ANSI C 89): Add
14586         strcasestr.
14587
14588 2005-08-17  Bruno Haible  <bruno@clisp.org>
14589
14590         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
14591
14592 2005-08-17  Bruno Haible  <bruno@clisp.org>
14593
14594         * modules/mbuiter: New file.
14595         * MODULES.html.sh (Extended multibyte and wide character utilities):
14596         Add mbuiter.
14597
14598 2005-08-17  Bruno Haible  <bruno@clisp.org>
14599
14600         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
14601         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
14602
14603 2005-08-17  Bruno Haible  <bruno@clisp.org>
14604
14605         * m4/strcasestr.m4: New file.
14606
14607 2005-08-17  Bruno Haible  <bruno@clisp.org>
14608
14609         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
14610         * lib/strstr.c: Completely rewritten, with multibyte locale support.
14611
14612 2005-08-17  Bruno Haible  <bruno@clisp.org>
14613
14614         * lib/strcasestr.h: New file.
14615         * lib/strcasestr.c: New file.
14616
14617 2005-08-17  Bruno Haible  <bruno@clisp.org>
14618
14619         * lib/strcasecmp.c: Use mbuiter.h.
14620
14621 2005-08-17  Bruno Haible  <bruno@clisp.org>
14622
14623         * lib/mbuiter.h: New file.
14624
14625 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
14626
14627         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
14628         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
14629         and gl_GETOPT are both invoked via different paths (as happens
14630         with GNU tar CVS because it uses both argp and getopt), the former
14631         wins.
14632
14633 2005-08-16  Bruno Haible  <bruno@clisp.org>
14634
14635         * modules/tls: New file.
14636         * MODULES.html.sh (Multithreading): Add tls.
14637
14638 2005-08-16  Bruno Haible  <bruno@clisp.org>
14639
14640         * modules/strnlen1: New file.
14641         * MODULES.html.sh (String handling): Add strnlen1.
14642
14643 2005-08-16  Bruno Haible  <bruno@clisp.org>
14644
14645         * modules/strcase (Files): Add m4/mbrtowc.m4.
14646         (Depends-on): Add strnlen1, mbchar.
14647
14648 2005-08-16  Bruno Haible  <bruno@clisp.org>
14649
14650         * modules/mbiter: New file.
14651         * MODULES.html.sh (Extended multibyte and wide character utilities):
14652         Add mbiter.
14653
14654 2005-08-16  Bruno Haible  <bruno@clisp.org>
14655
14656         * modules/mbfile: New file.
14657         * MODULES.html.sh (Extended multibyte and wide character utilities):
14658         Add mbfile.
14659
14660 2005-08-16  Bruno Haible  <bruno@clisp.org>
14661
14662         * modules/mbchar: New file.
14663         * MODULES.html.sh (Extended multibyte and wide character utilities):
14664         New section.
14665
14666 2005-08-16  Bruno Haible  <bruno@clisp.org>
14667
14668         * m4/tls.m4: New file, from GNU gettext.
14669
14670 2005-08-16  Bruno Haible  <bruno@clisp.org>
14671
14672         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
14673         always.
14674         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
14675
14676 2005-08-16  Bruno Haible  <bruno@clisp.org>
14677
14678         * m4/mbiter.m4: New file.
14679
14680 2005-08-16  Bruno Haible  <bruno@clisp.org>
14681
14682         * m4/mbfile.m4: New file.
14683
14684 2005-08-16  Bruno Haible  <bruno@clisp.org>
14685
14686         * m4/mbchar.m4: New file.
14687
14688 2005-08-16  Bruno Haible  <bruno@clisp.org>
14689
14690         * lib/tls.h: New file, from GNU gettext.
14691         * lib/tls.c: New file, from GNU gettext.
14692
14693 2005-08-16  Bruno Haible  <bruno@clisp.org>
14694
14695         * lib/strnlen1.h: New file.
14696         * lib/strnlen1.c: New file.
14697
14698 2005-08-16  Bruno Haible  <bruno@clisp.org>
14699
14700         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
14701         (mbi_init): Update.
14702         (mbi_avail, mbi_advance): Let the iteration end before the terminating
14703         NUL byte, not after it.
14704
14705 2005-08-16  Bruno Haible  <bruno@clisp.org>
14706
14707         * lib/strcase.h (strcasecmp): Add note in comments.
14708         * lib/strncasecmp.c: Use code from strcasecmp.c.
14709         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
14710         (strcasecmp): Work correctly in multibyte locales.
14711
14712 2005-08-16  Bruno Haible  <bruno@clisp.org>
14713
14714         * lib/mbiter.h: New file.
14715
14716 2005-08-16  Bruno Haible  <bruno@clisp.org>
14717
14718         * lib/mbfile.h: New file.
14719
14720 2005-08-16  Bruno Haible  <bruno@clisp.org>
14721
14722         * lib/mbchar.h: New file.
14723         * lib/mbchar.c: New file.
14724
14725 2005-08-16  Bruno Haible  <bruno@clisp.org>
14726
14727         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
14728         the valid ones. Makes the comparison operations transitive:
14729         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
14730         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
14731
14732 2005-08-15  Simon Josefsson  <jas@extundo.com>
14733
14734         * modules/ssize_t (License): Change to 'unlimited'.
14735
14736         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
14737
14738 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
14739
14740         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
14741         Add comments for each pending glibc patch.
14742
14743 2005-08-15  Bruno Haible  <bruno@clisp.org>
14744
14745         * lib/regex.h (__restrict_arr): Don't define to __restrict if
14746         __cplusplus is defined.
14747
14748 2005-08-14  Jim Meyering  <jim@meyering.net>
14749
14750         Sync from coreutils.
14751
14752         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
14753         Use the hash-table-based cycle-detection code not just when
14754         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
14755         Reported by James Youngman in
14756         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
14757         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
14758         FTS_TIGHT_CYCLE_CHECK.
14759         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
14760         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
14761         once again.
14762         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
14763         * lib/fts.c (fd_safer): Remove decl.
14764         Include fcntl--.h rather than unistd-safer.h
14765         (fts_safe_changedir): Don't call fd_safer; no longer needed
14766         now that we include fcntl--.h.
14767
14768 2005-08-12  Simon Josefsson  <jas@extundo.com>
14769
14770         * modules/getndelim2: Use ssize_t module.
14771         * modules/getnline: Likewise.
14772         * modules/safe-read: Likewise.
14773         * modules/xreadlink: Likewise.
14774
14775         * modules/ssize_t: New file.
14776
14777 2005-08-12  Simon Josefsson  <jas@extundo.com>
14778
14779         * m4/readline.m4: Look for termcap, curses or ncurses if required.
14780
14781 2005-08-12  Simon Josefsson  <jas@extundo.com>
14782
14783         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14784         ssize_t.
14785
14786 2005-08-12  Simon Josefsson  <jas@extundo.com>
14787
14788         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
14789         readline, getdelim and check_version.
14790         (Support for systems lacking ISO C 99: Sizes of integer types):
14791         Add size_max.
14792
14793 2005-08-12  Bruno Haible  <bruno@clisp.org>
14794
14795         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
14796
14797 2005-08-11  Simon Josefsson  <jas@extundo.com>
14798
14799         * modules/readline: New file.
14800
14801         * modules/strnlen (Files): Add strnlen.h.
14802
14803 2005-08-11  Simon Josefsson  <jas@extundo.com>
14804
14805         * m4/readline.m4: New file.
14806
14807 2005-08-11  Simon Josefsson  <jas@extundo.com>
14808
14809         * lib/readline.h, readline.c: New file.
14810
14811 2005-08-11  Simon Josefsson  <jas@extundo.com>
14812
14813         * doc/gnulib.texi (Initial import, Finishing touches): Mention
14814         gl_AVOID.
14815
14816 2005-08-11  Bruno Haible  <bruno@clisp.org>
14817
14818         * lib/strnlen.h (strnlen): Change parameter name to match comment.
14819
14820 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
14821
14822         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
14823
14824 2005-08-10  Simon Josefsson  <jas@extundo.com>
14825
14826         * tests/test-iconvme.c: New file.
14827
14828 2005-08-10  Simon Josefsson  <jas@extundo.com>
14829
14830         * m4/strnlen.m4: New file.
14831
14832         * m4/strndup.m4: Don't check for strnlen declaration, done in
14833         strnlen.m4.
14834
14835 2005-08-10  Simon Josefsson  <jas@extundo.com>
14836
14837         * lib/strndup.c: Use strnlen.h.
14838
14839         * lib/strnlen.h: New file.
14840
14841 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
14842
14843         * README: Typos.
14844
14845 2005-08-02  Simon Josefsson  <jas@extundo.com>
14846
14847         * modules/readline: New file.
14848
14849 2005-08-02  Simon Josefsson  <jas@extundo.com>
14850
14851         * modules/getdelim: New file.
14852
14853         * modules/getline: Rewrite, don't use getndelim2.
14854
14855 2005-08-02  Simon Josefsson  <jas@extundo.com>
14856
14857         * m4/getline.m4: Separate out getdelim stuff into separate module.
14858
14859         * m4/getdelim.m4: New file.
14860
14861 2005-08-02  Simon Josefsson  <jas@extundo.com>
14862
14863         * lib/getline.h, getline.c: Rewrite.
14864
14865         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
14866
14867 2005-07-31  Bruno Haible  <bruno@clisp.org>
14868
14869         * lib/lock.h (gl_lock_initializer): New macro.
14870         (gl_lock_define_initialized): Use it.
14871         (gl_rwlock_initializer): New macro.
14872         (gl_rwlock_define_initialized): Use it.
14873         (gl_recursive_lock_initializer): New macro.
14874         (gl_recursive_lock_define_initialized): Use it.
14875
14876 2005-07-30  Karl Berry  <karl@gnu.org>
14877
14878         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
14879         Report from Ben Pfaff, regarding getopt.
14880
14881 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
14882
14883         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
14884         normal way.
14885         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
14886         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
14887         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
14888         (gl_GETOPT): Use the new macros.  Most of the implementation
14889         is moved to the new macros.  This is for programs like Emacs
14890         that don't want all the functionality of gl_GETOPT.
14891
14892 2005-07-26  Bruno Haible  <bruno@clisp.org>
14893
14894         * m4/lock.m4: Update from GNU gettext.
14895
14896 2005-07-26  Bruno Haible  <bruno@clisp.org>
14897
14898         * lib/lock.h: Update from GNU gettext.
14899         * lib/lock.c: Update from GNU gettext.
14900
14901 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
14902
14903         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
14904         obsolescent AC_TRY_RUN.  Include the default includes files, for
14905         'exit'.
14906
14907 2005-07-24  Bruno Haible  <bruno@clisp.org>
14908
14909         * modules/visibility: New file.
14910         * MODULES.html.sh (Misc): Add visibility.
14911
14912 2005-07-24  Bruno Haible  <bruno@clisp.org>
14913
14914         * m4/visibility.m4: New file.
14915
14916 2005-07-24  Bruno Haible  <bruno@clisp.org>
14917
14918         * doc/visibility.texi: New file.
14919
14920 2005-07-22  Bruno Haible  <bruno@clisp.org>
14921
14922         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
14923         $(ALLOCA_H), redundant through BUILT_SOURCES.
14924         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
14925         redundant through BUILT_SOURCES.
14926         * modules/byteswap (Makefile.am): Remove explicit dependency on
14927         $(BYTESWAP_H), redundant through BUILT_SOURCES.
14928         * modules/fnmatch (Makefile.am): Remove explicit dependency on
14929         $(FNMATCH_H), redundant through BUILT_SOURCES.
14930         * modules/getopt (Makefile.am): Remove explicit dependency on
14931         $(GETOPT_H), redundant through BUILT_SOURCES.
14932         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
14933         redundant through BUILT_SOURCES.
14934         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
14935         redundant through BUILT_SOURCES.
14936         * modules/stdbool (Makefile.am): Remove explicit dependency on
14937         $(STDBOOL_H), redundant through BUILT_SOURCES.
14938         * modules/stdint (Makefile.am): Remove explicit dependency on
14939         $(STDINT_H), redundant through BUILT_SOURCES.
14940         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
14941         Remove explicit dependency on $(SYSEXITS_H).
14942         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
14943
14944 2005-07-18  Simon Josefsson  <jas@extundo.com>
14945
14946         * lib/check-version.c (check_version): Accept identical versions too.
14947
14948 2005-07-18  Bruno Haible  <bruno@clisp.org>
14949
14950         * modules/lock: New file.
14951         * MODULES.html.sh (Multithreading): New section.
14952
14953 2005-07-18  Bruno Haible  <bruno@clisp.org>
14954
14955         * m4/lock.m4: New file, from GNU gettext.
14956
14957 2005-07-18  Bruno Haible  <bruno@clisp.org>
14958
14959         * lib/lock.h: New file, from GNU gettext.
14960         * lib/lock.c: New file, from GNU gettext.
14961
14962 2005-07-18  Bruno Haible  <bruno@clisp.org>
14963
14964         * lib/lock.h (gl_once_t): New type.
14965         (gl_once_define, gl_once): New macros.
14966         * lib/lock.c (fresh_once): New variable.
14967         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
14968         functions.
14969
14970 2005-07-16  Simon Josefsson  <jas@extundo.com>
14971
14972         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
14973         workaround, suggested by Bruno.
14974
14975 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
14976
14977         * modules/xalloc (Depends-on): Add xalloc-die.
14978         * modules/xvasprintf (Depends-on): Add xalloc-die.
14979
14980 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
14981
14982         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
14983         with a minor change.
14984
14985 2005-07-15  Bruno Haible  <bruno@clisp.org>
14986
14987         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
14988         When using lib/poll.c, define poll as rpl_poll.
14989
14990 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
14991
14992         * modules/argp (Depends-on): Remove unlocked-io.
14993
14994 2005-07-14  Derek Price  <derek@ximbiot.com>
14995
14996         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
14997         for glob symlink bug.
14998
14999 2005-07-14  Bruno Haible  <bruno@clisp.org>
15000
15001         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
15002         Instead, test for *_unlocked function declarations directly.
15003
15004 2005-07-11  Simon Josefsson  <jas@extundo.com>
15005
15006         * modules/size_max: New file.
15007
15008         * modules/xsize: Depend on size_max module for size_max.m4.
15009
15010 2005-07-11  Simon Josefsson  <jas@extundo.com>
15011
15012         * lib/size_max.h: New file.
15013
15014 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
15015
15016         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
15017         copyright symbol and the year.
15018         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
15019         (version_etc_va): Use parameterized copyright notice.
15020         Reword to conform to the current GNU coding standards.
15021
15022 2005-07-11  Karl Berry  <karl@gnu.org>
15023
15024         * doc/gnulib.texi (Quoting): new node.
15025         (Initial import): more info, from Patrice.
15026
15027 2005-07-11  Bruno Haible  <bruno@clisp.org>
15028
15029         * gnulib-tool (func_usage): Document option --avoid.
15030         (Command line options): Handle --avoid.
15031         (func_acceptable): New function.
15032         (func_modules_transitive_closure): Use it.
15033
15034 2005-07-11  Bruno Haible  <bruno@clisp.org>
15035
15036         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
15037         Reported by Jim Meyering.
15038
15039 2005-07-10  Bruno Haible  <bruno@clisp.org>
15040
15041         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
15042         Needed when size_t is smaller than 'unsigned int'.
15043         Reported by Paul Eggert.
15044
15045 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15046
15047         * modules/argp (Depends-on): Add unlocked-io
15048
15049 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15050
15051         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
15052         block of defines.
15053
15054 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
15055
15056         * config/srclist.txt: Comment out regcomp.c, since we have a porting
15057         fix now.
15058
15059 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
15060         and Paul Eggert  <eggert@cs.ucla.edu>
15061
15062         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
15063         in wint_t, not wchar_t.  Remove now-unnecessary cast.
15064
15065 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15066
15067         * modules/regex (Files): Add lib/regex_internal.c,
15068         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
15069         (Depends-on): Add extensions.
15070         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
15071
15072 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15073
15074         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
15075         pathconf.
15076         * m4/same.m4 (gl_SAME): Likewise.
15077         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
15078
15079         * m4/regex.m4: Adjust to new libc regex implementation.
15080         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
15081         all the .c and .h parts of (the new) regex.
15082         Quote the m4 stuff better.
15083         Check for RE_ICASE bug of old gnulib.
15084         Check for REG_STARTEND of recent libc.
15085         Rename local variables from jm_* to gl_*.
15086         Quote operand of "test -f".
15087         Say "recent enough" version of libc, not "version 2".
15088         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
15089         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
15090         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
15091         Remove check for btowc, isascii.
15092         Require AM_LANGINFO_CODESET.
15093
15094 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15095
15096         * lib/regex.c, regex.h: Sync from libc.
15097         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
15098         * lib/regexec.c:
15099         New files, synced from libc, except that regex_internal.h
15100         currently has a small porting fix.
15101
15102 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15103
15104         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
15105         regex_internal.c, regexec.c.
15106         Add regex_internal.h too, but as a comment, since the libc version
15107         is currently broken in gnulib mode.
15108
15109 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
15110
15111         Support programs like Emacs that use gnulib but not gettext.
15112         * MODULES.html.sh (Internationalization functions): Add gettext-h.
15113         * modules/gettext-h: New file.
15114         * modules/gettext (Files): Remove lib/gettext.h.
15115         (Depends-on): Add gettext-h.
15116         (Makefile.am): Remove lib_SOURCES.
15117         * modules/argmatch, modules/c-stack, modules/closeout:
15118         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
15119         * modules/execute, modules/file-type, modules/getaddrinfo:
15120         * modules/getopt, modules/human, modules/javacomp:
15121         * modules/javaexec, modules/mkdir-p, modules/obstack:
15122         * modules/openat, modules/pagealign_alloc, modules/pipe:
15123         * modules/quotearg, modules/regex, modules/rpmatch:
15124         * modules/unicodeio, modules/userspec, modules/version-etc:
15125         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
15126         * modules/xsetenv:
15127         Depend on gettext-h, not gettext.
15128
15129 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
15130
15131         * gnulib-tool (func_import): Add support for 'public domain' license.
15132         * modules/alloca, modules/atexit, modules/memmove:
15133         Now public domain, not GPL.
15134         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
15135         * modules/realloc, modules/strerror, modules/strtod:
15136         Now LGPL, not GPL.
15137
15138 2005-07-05  Bruno Haible  <bruno@clisp.org>
15139
15140         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
15141         autoconf CVS. Needed for mingw.
15142
15143 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15144
15145         Remove the dependency of the strftime module on the tzset module.
15146         * modules/strftime (Depends-on): Remove dependency on tzset.
15147
15148 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15149
15150         Remove the dependency of the strftime module on the tzset module.
15151         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
15152         gl_FUNC_TZSET_CLOBBER.
15153
15154 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15155
15156         Remove the dependency of the strftime module on the tzset module.
15157         * lib/strftime.c (my_strftime)
15158         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
15159         Copy the input structure, to work around some of the bug with
15160         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
15161         Solaris releases, you should also use the tzset module, but we won't
15162         require it as a dependency any more since we don't want LGPLed code
15163         to depend on GPLed code.
15164
15165 2005-07-02  Jim Meyering  <jim@meyering.net>
15166
15167         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
15168         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
15169         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
15170         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
15171
15172 2005-07-02  Jim Meyering  <jim@meyering.net>
15173
15174         * lib/backupfile.c (backup_args): Change a `0' to NULL.
15175
15176 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
15177
15178         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
15179         declares only 'struct timespec;' (!).
15180
15181 2005-07-01  Jim Meyering  <jim@meyering.net>
15182
15183         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
15184         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
15185         * lib/save-cwd.c, tempname.c:
15186         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
15187         and don't include <sys/file.h>).
15188
15189 2005-06-29  Jim Meyering  <jim@meyering.net>
15190
15191         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
15192         type name.  Use the variable name instead.
15193         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
15194         Likewise.
15195
15196 2005-06-28  Simon Josefsson  <jas@extundo.com>
15197
15198         * modules/check-version (Files): Add check-version.m4.
15199
15200 2005-06-28  Simon Josefsson  <jas@extundo.com>
15201
15202         * m4/check-version.m4: New file, suggested by Jim Meyering
15203         <jim@meyering.net>.
15204
15205 2005-06-28  Simon Josefsson  <jas@extundo.com>
15206
15207         * lib/check-version.h, lib/check-version.c: New files.
15208
15209 2005-06-28  Simon Josefsson  <jas@extundo.com>
15210
15211         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
15212         collision with global variable.  Better indentation.  Don't
15213         increment buffer pointer beyond buffer end.  Based on comments
15214         from Paul Eggert <eggert@cs.ucla.edu>.
15215
15216         * lib/base64.h: Indent.
15217
15218 2005-06-28  Simon Josefsson  <jas@extundo.com>
15219
15220         * doc/gnulib.texi (Library version handling): New section.
15221
15222 2005-06-28  Jim Meyering  <jim@meyering.net>
15223
15224         * check-module (find_included_lib_files): Hard-code another
15225         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
15226         but modules/fts-lgpl (correctly) does not list those files.
15227
15228         * modules/canonicalize (Files): Add lib/pathmax.h.
15229
15230 2005-06-25  Simon Josefsson  <jas@extundo.com>
15231
15232         * modules/check-version: New file.
15233
15234 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
15235
15236         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
15237         initializer of struct addrinfo, as an indication that we don't
15238         care how many members the structure has.
15239
15240 2005-06-24  Derek Price  <derek@ximbiot.com>
15241         and Bruno Haible  <bruno@clisp.org>
15242
15243         Remove stat module & update lstat.
15244         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
15245         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
15246         * m4/stat.m4: Remove this file.
15247
15248 2005-06-24  Derek Price  <derek@ximbiot.com>
15249         and Bruno Haible  <bruno@clisp.org>
15250
15251         Remove stat module & update lstat.
15252         * lib/stat.c: Remove this file...
15253         (slash_aware_lstat): ...moving this content and its support...
15254         * lib/lstat.c (rpl_lstat): ...into here.
15255         * lib/lstat.h: New file.
15256
15257 2005-06-24  Derek Price  <derek@ximbiot.com>
15258         and Bruno Haible  <bruno@clisp.org>
15259
15260         Remove stat module & update lstat.
15261         * config/srclist.txt (libc sources): Remove stat.
15262
15263 2005-06-24  Derek Price  <derek@ximbiot.com>
15264         and Bruno Haible  <bruno@clisp.org>
15265
15266         Remove stat module & update lstat.
15267         * MODULES.html.sh (stat): Remove.
15268         * MODULES.html: Regenerated.
15269         * modules/lstat (Description): Correct function name.
15270         (Files): Add "lstat.h".
15271         (Depends-on): Remove stat, add xalloc, stat-macros.
15272         * modules/stat: Remove this file.
15273         (Include): Add "lstat.h", remove <sys/stat.h>.
15274
15275 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
15276
15277         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
15278         (ranged_convert): Don't save conversion in a temporary struct.
15279         This causes a warning with GCC 4.0.0, and anyway in the typical
15280         case it's not worth the extra 100 bytes or so of code.
15281         (ranged_convert, __mktime_internal): When calling a function via a
15282         pointer P, use P () rather than (*P) (), as we now assume C89 or
15283         better.
15284
15285 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15286
15287         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
15288         "who -r" failed to give output.  Problem reported by Tim Waugh.
15289
15290         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
15291         (xcalloc): Use it to avoid needless tests.
15292         Problem reported by Jim Meyering.
15293
15294 2005-06-20  Derek Price  <derek@ximbiot.com>
15295
15296         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
15297         unnecessary for Autoconfs > 2.59c.
15298
15299 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15300
15301         * lib/argp.h (__option_is_short): Check upper limit of
15302         __key. Isprint() requires its argument to have the value
15303         of an unsigned char or EOF.
15304
15305 2005-06-16  Jim Meyering  <jim@meyering.net>
15306
15307         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
15308         when either N or S is zero.
15309
15310 2005-06-16  Derek Price  <derek@ximbiot.com>
15311
15312         * m4/bison.m4: Declare YACC & YFLAGS precious.
15313
15314 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
15315
15316         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
15317         multibyte string or pattern, fall back on unibyte matching.
15318         Problem reported by James Youngman.
15319
15320 2005-06-08  Bruno Haible  <bruno@clisp.org>
15321
15322         * modules/csharpcomp: New file.
15323         * MODULES.html.sh (C#): Add csharpcomp.
15324
15325 2005-06-08  Bruno Haible  <bruno@clisp.org>
15326
15327         * m4/csharpcomp.m4: New file, from GNU gettext.
15328
15329 2005-06-08  Bruno Haible  <bruno@clisp.org>
15330
15331         * lib/csharpcomp.h: New file, from GNU gettext.
15332         * lib/csharpcomp.c: New file, from GNU gettext.
15333         * lib/csharpcomp.sh.in: New file, from GNU gettext.
15334
15335 2005-06-08  Bruno Haible  <bruno@clisp.org>
15336
15337         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
15338         warning on mingw.
15339
15340 2005-06-07  Derek Price  <derek@ximbiot.com>
15341
15342         Sync from CVS.
15343         * lib/glob_.h: Indent nested #ifdef.
15344
15345 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15346
15347         Sync from coreutils.
15348         Use "file name" when talking about file names, instead of "filename"
15349         or "path", as per the GNU coding standards.
15350         * lib/mkdir-p.c: Renamed from makepath.c.
15351         (make_dir_parents): Renamed from make_path.  All callers changed.
15352         * lib/mkdir-p.h: Likewise.  All includers changed.
15353         * lib/filenamecat.c: Renamed from path-concat.c.
15354         (file_name_concat): Renamed from path_concat.  All callers changed.
15355         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
15356         * lib/filenamecat.h: Likewise.  All includers changed.
15357         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
15358         in comments or local variable names.
15359         * lib/basename.c: Likewise.
15360         * lib/canonicalize.c, canonicalize.h: Likewise.
15361         * lib/dirname.c, dirname.h: Likewise.
15362         * lib/euidaccess.c: Likewise.
15363         * lib/exclude.c: Likewise
15364         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
15365         * lib/fsusage.c, fsuage.h: Likewise.
15366         * lib/fts.c, fts_.h: Likewise.
15367         * lib/getcwd.c: Likewise.
15368         * lib/getloadavg.c: Likewise.
15369         * lib/mkstemp.c: Likewise.
15370         * lib/mountlist.c, mountlist.h: Likewise.
15371         * lib/openat.c, openat.h: Likewise.
15372         * lib/readlink-stub.c: Likewise.
15373         * lib/readutmp.c, readutmp.h: Likewise.
15374         * lib/rename.c: Likewise.
15375         * lib/rmdir.c: Likewise.
15376         * lib/same.c: Likewise.
15377         * lib/savedir.c: Likewise.
15378         * lib/stripslash.c: Likewise.
15379         * lib/tempname.c: Likewise.
15380         * lib/xreadlink.c: Likewise.
15381         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
15382         All uses changed.
15383         * lib/exclude.h: Likewise.
15384
15385         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
15386         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15387         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
15388         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15389         * lib/pathmax.h: Include <limits.h> unconditionally, since other
15390         files have been getting away with it for years (MORE/BSD 4.3
15391         is extinct now).
15392         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
15393         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15394
15395         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
15396         Define to 256, not 255, as per modern POSIX.
15397
15398 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15399
15400         Sync from coreutils.
15401         Use "file name" when talking about file names, instead of "filename"
15402         or "path", as per the GNU coding standards.
15403         * MODULES.html.sh: mkdir-p renamed from makepath.
15404         filenamecat renamed from path-concat.
15405         * modules/filenamecat: Renamed from modules/path-concat.
15406         (Files): filenamecat.h and filenamecat.c renamed from
15407         path-concat.h and path-concat.c.
15408         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
15409         (Include): filenamecat.h, not path-concat.h.
15410         * modules/mkdir-p: Renamed from modules/makepath.
15411         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
15412         makepath.c.
15413         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
15414         (Include): mkdir-p.h, not makepath.h.
15415
15416 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15417
15418         Sync from coreutils.
15419         * m4/mkdir-p.m4: Renamed from makepath.m4.
15420         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
15421         Rename files from makepath.c to mkdir-p.c, and from
15422         makepath.h to mkdir-p.h.
15423         * m4/filenamecat.m4: Renamed from path-concat.m4.
15424         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
15425         Rename files from path-concat.c to filenamecat.c,
15426         and from path-concat.h to filenamecat.h.
15427         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
15428         "file name" in local variables or comments.
15429         * m4/rename.m4: Likewise.
15430
15431 2005-06-01  Bruno Haible  <bruno@clisp.org>
15432
15433         * modules/csharpexec: New file.
15434         * MODULES.html.sh (C#): New section.
15435
15436 2005-06-01  Bruno Haible  <bruno@clisp.org>
15437
15438         * m4/csharp.m4: New file, from GNU gettext.
15439         * m4/csharpexec.m4: New file, from GNU gettext.
15440
15441 2005-06-01  Bruno Haible  <bruno@clisp.org>
15442
15443         * lib/csharpexec.h: New file, from GNU gettext.
15444         * lib/csharpexec.c: New file, from GNU gettext.
15445         * lib/csharpexec.sh.in: New file, from GNU gettext.
15446
15447 2005-05-31  Derek Price  <derek@ximbiot.com>
15448             Paul Eggert  <eggert@cs.ucla.edu>
15449
15450         Sync from cvs.
15451         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
15452
15453 2005-05-31  Derek Price  <derek@ximbiot.com>
15454             Paul Eggert  <eggert@cs.ucla.edu>
15455
15456         Sync from cvs.
15457         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
15458
15459 2005-05-29  Derek Price  <derek@ximbiot.com>
15460
15461         * config/srclist.txt (glob_.h, glob.c): Add these files.
15462
15463 2005-05-29  Derek Price  <derek@ximbiot.com>
15464
15465         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
15466         * modules/glob: New file.
15467         * modules/getlogin_r: Add link to POSIX spec in description.
15468
15469 2005-05-29  Derek Price  <derek@ximbiot.com>
15470             Paul Eggert  <eggert@cs.ucla.edu>
15471
15472         * m4/glob.m4: New file.
15473
15474 2005-05-29  Derek Price  <derek@ximbiot.com>
15475             Paul Eggert  <eggert@cs.ucla.edu>
15476
15477         * lib/glob_.h, lib/glob.c: New files.
15478
15479 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15480
15481         * modules/fts (Files): Remove m4/inttypes-pri.m4.
15482         * modules/fts-lgpl (Depends-on): Remove gettext.
15483
15484 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15485
15486         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
15487         and don't require gt_INTTYPES_PRI.
15488
15489 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15490
15491         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
15492
15493         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
15494         the configuration hassle isn't worth it.
15495         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
15496         (LONGEST_MODIFIER, PRIuMAX): Remove.
15497
15498 2005-05-27  Bruno Haible  <bruno@clisp.org>
15499
15500         * lib/getlogin_r.h: Remove second include of <stddef.h>.
15501
15502 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
15503
15504         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
15505         _POSIX_PTHREAD_SEMANTICS for Solaris.
15506
15507 2005-05-25  Derek Price  <derek@ximbiot.com>
15508
15509         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
15510
15511 2005-05-25  Derek Price  <derek@ximbiot.com>
15512             Paul Eggert  <eggert@cs.ucla.edu>
15513
15514         * modules/getlogin_r, m4/getlogin_r.m4: New files.
15515         * lib/getlogin_r.c, getlogin_r.h: New files.
15516
15517 2005-05-25  Bruno Haible  <bruno@clisp.org>
15518             Derek Price  <derek@ximbiot.com>
15519
15520         * lib/getlogin_r.h: Simplify API documentation.
15521
15522 2005-05-23  Derek Price  <derek@ximbiot.com>
15523
15524         * modules/minmax (Files): Add m4/minmax.m4.
15525         (configure.ac): Add gl_MINMAX.
15526
15527 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
15528
15529         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
15530         so that unistd-safer.h (GPL'ed code) need not be included.
15531
15532 2005-05-22  Bruno Haible  <bruno@clisp.org>
15533
15534         * m4/minmax.m4: New file.
15535         Based on a patch by Derek Price <derek@ximbiot.com>.
15536
15537 2005-05-22  Bruno Haible  <bruno@clisp.org>
15538
15539         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
15540         (INT64_MIN): Fix definition.
15541         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
15542
15543         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
15544         NEED_SIGNED_INT_TYPES.
15545
15546         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
15547         HAVE_SYSTEM_INTTYPES.
15548
15549 2005-05-22  Bruno Haible  <bruno@clisp.org>
15550
15551         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
15552         Also include <sys/param.h> if it defines MIN, MAX.
15553         Based on a patch by Derek Price <derek@ximbiot.com>.
15554
15555 2005-05-21  Jim Meyering  <jim@meyering.net>
15556
15557         * modules/fts (Files): Add m4/inttypes-pri.m4.
15558         (Depends-on): Add lstat and remove gettext.  Alphabetize.
15559
15560 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15561
15562         New fts module.
15563         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
15564         (setup_dir, free_dir): New functions.
15565         (enter_dir, leave_dir): Define trivial
15566         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
15567         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
15568         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
15569         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
15570         Move to fts-cycle.c.
15571         (fts_open): Use setup_dir.
15572         (fts_close): Use free_dir.
15573         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
15574         This adds a label and some gotos, but the alternatives were messier.
15575         Check for memory allocation failure when entering a dir.
15576         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
15577         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
15578         (FTS): New member fts_cycle, that is a union that contains the
15579         old active_dir_ht and cycle_state.  All uses changed to mention
15580         fts_cycle.ht and fts_cycle.state.
15581         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
15582         fts.c, with the following changes:
15583         (setup_dir, free_dir): New functions.
15584         (enter_dir): Now returns bool.  Return true if successful, false
15585         if memory exhausted.  All callers changed.
15586         Do not bother partly cleaning up on
15587         memory allocation failure; that is free_dir's job.
15588         However, free ad if hash_insert fails, to avoid memory leak.
15589         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
15590         fts->fts_options to see which union member to use.
15591
15592 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15593
15594         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
15595         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
15596
15597 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15598
15599         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
15600
15601 2005-05-20  Jim Meyering  <jim@meyering.net>
15602
15603         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
15604         Now a macro, to pacify GCC.
15605
15606 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
15607
15608         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
15609         of -1.
15610
15611 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
15612
15613         * lib/chown.c (rpl_chown): Return -1 on failure.
15614
15615 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
15616
15617         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
15618         Don't check for stddef.h.
15619         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
15620         don't use its results.
15621         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
15622         since we include them unconditionally.  Don't require
15623         AM_STDBOOL_H, since stdbool is a prerequisite.
15624         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
15625         since we assume C89 or better.
15626         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
15627         as we don't use their results.
15628         Don't check for fchdir, memmove, memset, strrchr, as we use
15629         them unconditionally.
15630         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
15631         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
15632
15633 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
15634
15635         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
15636         Include <stddef.h> unconditionally, since we assume C89 now.
15637         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
15638         * lib/fts.c: Include fts_.h first, to check interface.
15639         Do not include intprops.h; no longer needed.
15640         Include cycle-check.h and hash.h, since fts_.h no longer does.
15641         Remove unnecessary casts of closedir to void.
15642         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
15643         decide whether to decrement nlinks.
15644         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
15645         (FTS): Use struct hash_table * instead of Hash_table, so that
15646         we no longer need to include hash.h here.
15647
15648 2005-05-18  Jim Meyering  <jim@meyering.net>
15649
15650         * modules/dirfd (License): Change to LGPL.  Most of the code
15651         is already in the public domain.
15652
15653 2005-05-18  Jim Meyering  <jim@meyering.net>
15654
15655         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
15656         Reported by Yoann Vandoorselaere.
15657
15658 2005-05-17  Jim Meyering  <jim@meyering.net>
15659
15660         * m4/fts.m4: New file, from coreutils.
15661
15662 2005-05-17  Jim Meyering  <jim@meyering.net>
15663
15664         * lib/fts.c, lib/fts_.h: New files, from coreutils.
15665
15666 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
15667
15668         Sync from coreutils.
15669         * m4/unlinkdir.m4: New file.
15670
15671 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
15672
15673         Sync from coreutils.
15674         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
15675         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
15676         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
15677         White space changes only.
15678         * lib/makepath.c (make_path): Port to hosts where leading "//" is
15679         special.
15680         * lib/yesno.c: Include getline.h, not ctype.h.
15681         (yesno): Don't remove leading white space; POSIX doesn't allow it.
15682         Use getline to remove arbitrary restriction on response length.
15683
15684 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
15685
15686         * config/srclist-update: Spell out "Street" in FSF postal
15687         mail address; this is the style the FSF seems to prefer.
15688
15689         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
15690         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
15691         this updates FSF postal mail address.
15692
15693         Sync from coreutils.
15694         * modules/unlinkdir: New file.
15695         * modules/yesno (Depends-on): Add getline.
15696         * MODULES.html.sh (File system functions): Add unlinkdir.
15697
15698 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15699
15700         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
15701         lib/strsep.h:
15702         Change the initial comment to refer to GPL, not LGPL.
15703         gnulib-tool will change it to LGPL as needed.
15704
15705         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
15706         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
15707         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
15708         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
15709         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
15710         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
15711         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
15712         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
15713         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
15714         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
15715         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
15716         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
15717         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
15718         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
15719         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
15720         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
15721         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
15722         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
15723         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
15724         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
15725         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
15726         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
15727         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
15728         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
15729         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
15730         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
15731         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
15732         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
15733         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
15734         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
15735         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
15736         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
15737         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
15738         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
15739         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
15740         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
15741         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
15742         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
15743         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
15744         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
15745         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
15746         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
15747         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
15748         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
15749         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
15750         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
15751         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
15752         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
15753         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
15754         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
15755         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15756         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
15757         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
15758         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
15759         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
15760         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
15761         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
15762         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
15763         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
15764         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
15765         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
15766         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
15767         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
15768         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
15769         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
15770         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
15771         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
15772         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
15773         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
15774         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
15775         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
15776         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
15777         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
15778         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
15779         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
15780         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
15781         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
15782         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
15783         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
15784         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
15785         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
15786         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
15787         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
15788         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
15789         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
15790         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
15791         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
15792         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
15793         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
15794         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
15795         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
15796         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
15797         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
15798         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
15799         lib/yesno.c, lib/yesno.h:
15800         Update FSF postal mail address.
15801
15802 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15803
15804         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
15805         tests/test-memmem.c, tests/test-stpncpy.c:
15806         Update FSF postal mail address.
15807
15808 2005-05-13  Bruno Haible  <bruno@clisp.org>
15809
15810         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
15811         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
15812         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
15813         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
15814         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
15815         Add support for 64-bit integers in the MSVC compiler.
15816
15817 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15818
15819         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
15820
15821 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
15822
15823         * gnulib-tool (func_import): Sort and uniquify recommended includes.
15824
15825 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
15826
15827         * doc/getdate.texi (General date syntax): Don't say that date
15828         date --iso-8601=ns generates acceptable dates; it doesn't yet.
15829         Problem reported by Nic Ferrier.
15830
15831 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
15832
15833         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
15834         specified in ai_socktype. Fix invalid ai_protocol
15835         check. ai_protocol is usually set to 0 or depending on
15836         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
15837         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
15838         ai_socktype / ai_protocol in the returned addrinfo structure.
15839
15840 2005-05-10  Simon Josefsson  <jas@extundo.com>
15841
15842         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
15843         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
15844
15845 2005-05-10  Karl Berry  <karl@gnu.org>
15846
15847         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
15848         (from http://www.gnu.org/licenses).
15849         * doc/COPYING.LIB: also rename to COPYING.LESSER.
15850         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
15851         fdl.texi suffices.
15852
15853 2005-05-10  Karl Berry  <karl@gnu.org>
15854
15855         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
15856         (COPYING.DOC): remove.
15857
15858         * config/srclist-update: new FSF address.
15859
15860 2005-05-10  Derek Price  <derek@ximbiot.com>
15861
15862         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
15863         possible.
15864
15865 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
15866             Bruno Haible  <bruno@clisp.org>
15867
15868         * modules/inet_ntop: New file.
15869         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15870         inet_ntop.
15871
15872 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
15873             Bruno Haible  <bruno@clisp.org>
15874
15875         * m4/inet_ntop.m4: New file.
15876
15877 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
15878             Bruno Haible  <bruno@clisp.org>
15879
15880         * lib/inet_ntop.h: New file.
15881         * lib/inet_ntop.c: New file, from glibc with modifications.
15882
15883 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
15884
15885         * modules/time_r (License): Change to LGPL.
15886         * modules/extensions (License): Change to LGPL.  Actually,
15887         the license is more permissive than that, but currently gnulib-tool
15888         doesn't know how to handle more-permissive licenses.
15889
15890         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
15891         Problem reported by Dave Love.
15892
15893 2005-05-08  Jim Meyering  <jim@meyering.net>
15894
15895         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
15896         blank.
15897
15898 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15899
15900         * modules/argmatch (Depends-on): Add stdbool.
15901         * modules/backupfile (Depends-on): Likewise.
15902         * modules/chdir-long (Depends-on): Likewise.
15903         * modules/closeout (Depends-on): Likewise.
15904         * modules/cycle-check (Depends-on): Likewise.
15905         * modules/dirname (Depends-on): Likewise.
15906         * modules/fnmatch (Depends-on): Likewise.
15907         * modules/fsusage (Depends-on): Likewise.
15908         * modules/fwriteerror (Depends-on): Likewise.
15909         * modules/getcwd (Depends-on): Likewise.
15910         * modules/getloadavg (Depends-on): Likewise.
15911         * modules/hard-locale (Depends-on): Likewise.
15912         * modules/makepath (Depends-on): Likewise.
15913         * modules/mountlist (Depends-on): Likewise.
15914         * modules/nanosleep (Depends-on): Likewise.
15915         * modules/posixtm (Depends-on): Likewise.
15916         * modules/quotearg (Depends-on): Likewise.
15917         * modules/readtokens (Depends-on): Likewise.
15918         * modules/readtokens0 (Depends-on): Likewise.
15919         * modules/readutmp (Depends-on): Likewise.
15920         * modules/save-cwd (Depends-on): Likewise.
15921         * modules/strftime (Depends-on): Likewise.
15922         * modules/userspec (Depends-on): Likewise.
15923         * modules/utimecmp (Depends-on): Likewise.
15924         * modules/xgetcwd (Depends-on): Likewise.
15925         * modules/xnanosleep (Depends-on): Likewise.
15926         * modules/xstrtod (Depends-on): Likewise.
15927         * modules/yesno (Depends-on): Likewise.
15928
15929 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
15930
15931         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
15932         needless checks.
15933
15934 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
15935
15936         Merge from coreutils.  Among other things,
15937         add bulletproofing for cases where stdin, stdout, or stderr are closed.
15938         * lib/fd-safer.c: New file.
15939         * lib/fcntl-safer.h, open-safer.c: Remove.
15940         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
15941         * lib/dup-safer.c: Include unistd-safer.h first.
15942         Don't include errno.h.
15943         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
15944         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
15945         * lib/file-type.c: Rely on file-type.h change.
15946         * lib/getloadavg.c: Include unistd-safer.h.
15947         (getloadavg): Use safer open.
15948         * lib/getusershell.c: Include "stdio-safer.h".
15949         (getusershell): Use safer fopen.
15950         * lib/long-options.c (long_options): Use NULL rather than 0.
15951         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
15952         'free'.
15953         * lib/modechange.c: Likewise.
15954         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
15955         (MODE_DONE): New constant.
15956         (struct mode_change): Remove 'next' member.
15957         (make_node_op_equals): New function; like the old one of the
15958         same name, except it allocates an array.
15959         (mode_compile, mode_create_from_ref): Use it.
15960         (mode_compile): Allocate result as an array, not a linked list.
15961         Parse octal string ourself, so that we catch mistakes like "+0".
15962         (mode_adjust): Arg is an array, not a linked list.
15963         * lib/modechange.c: Include stat-macros.h, xalloc.h.
15964         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
15965         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
15966         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
15967         Remove.  This is now stat-macros.h's job.
15968         (talloc): Remove.  All callers replaced by xalloc, so that
15969         our invokers don't have to worry about reporting memory failures.
15970         (make_node_op_equals): Remove.
15971         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
15972         New constants.
15973         (struct mode_change): Moved here from modechange.h.
15974         (mode_append_entry): Remove.
15975         (mode_compile): Remove MASKED_OPS arg, since it encouraged
15976         apps to have incorrect behavior.  Use simpler algorithm for head
15977         and tail.  Don't futz with umask; that's now the job of mode_adjust.
15978         Detect more invalid usages rather than having somewhat-random behavior.
15979         Don't insert an "a=" action, as that leads to incorrect behavior.
15980         (mode_compile, mode_create_from_ref): Return NULL on error instead
15981         of an enum, since now there's only one way to have an error.  All
15982         callers changed.
15983         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
15984         at the correct time.  Simplify calculation of "+u" and its ilk.
15985         Don't mishandle "+X".
15986         (mode_free): Remove "register" and localize decls.
15987         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
15988         (struct mode_change): Move to modechange.c; callers don't
15989         need to see this stuff.
15990         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
15991         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
15992         (mode_change, mode_adjust): Reflect the new signatures noted above.
15993         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
15994         that might redefine system include files.
15995         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
15996         (my_usleep): Use NULL rather than (void *) 0.
15997         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
15998         Use siginterrupt to specify that system calls should be interrupted.
15999         (rpl_nanosleep): Move initialization of suspended closer to call of
16000         my_usleep.
16001         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
16002         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
16003         (desirable_utmp_entry): New function.
16004         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
16005         using x2nrealloc, to simplify logic.
16006         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
16007         size calculation.  Do not assume utmp file is a regular file.
16008         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
16009         (READ_UTMP_CHECK_PIDS): New constant.
16010         * lib/save-cwd.c: Include unistd-safer.h.
16011         (save_cwd): Use fd_safer.
16012         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
16013         [!_LIBC] Include "stat-macros.h" instead.
16014         * lib/unistd-safer.h (fd_safer): New decl.
16015
16016 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16017
16018         * modules/getloadavg (Depends-on): Add unistd-safer.
16019         * modules/getusershell (Depends-on): Add stdio-safer.
16020         * modules/lstat (Depends-on): Remove xalloc.
16021         * modules/mkstemp (Depends-on): Add stat-macros.
16022         * modules/modechange (Depends-on): Remove xstrtol.
16023         Add stat-macros, xalloc.
16024         * modules/save-cwd (Depends-on): Add unistd-safer.
16025         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
16026         * modules/unistd-safer (Files): Add lib/fd-safer.c
16027         (Makefile.am): Remove lib_SOURCES.
16028
16029         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
16030         Remove fcntl-safer; unistd-safer supersedes it.
16031
16032 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16033
16034         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
16035         AC_HEADER_STAT.
16036         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
16037         (gl_PREREQ_CHOWN): Remove.
16038         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
16039         it.  Don't require AC_HEADER_STAT.
16040         (gl_PREREQ_LSTAT): Remove.
16041         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
16042         Don't require AC_HEADER_STAT.
16043         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
16044         (gl_PREREQ_RMDIR): Remove.
16045         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
16046         mention stat-macros.h or AC_HEADER_STAT, since we'll make
16047         the stat-macros module a prerequisite.
16048         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
16049         * m4/filemode.m4 (gl_FILEMODE): Likewise.
16050         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
16051         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
16052         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
16053         variable names.
16054         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
16055         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
16056         variable prefixes.
16057         * m4/fcntl-safer.m4: Remove.
16058         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
16059         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
16060         Invoke gl_PREREQ_FD_SAFER.
16061         (gl_PREREQ_FD_SAFER): New macro.
16062         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
16063         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
16064         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
16065         Remove duplicate call to AC_LIBOBJ(readutmp).
16066         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
16067
16068         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
16069         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
16070
16071 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16072
16073         * MODULES.html.sh (Misc): Add byteswap.
16074
16075 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16076
16077         * modules/getcwd (Depends-on): Add extensions.
16078         * modules/openat (Depends-on): Likewise.
16079
16080 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16081
16082         * modules/byteswap: New file.
16083
16084 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16085
16086         * m4/byteswap.m4: New file.
16087
16088 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16089
16090         * lib/byteswap_.h: New file.
16091
16092 2005-04-25  Karl Berry  <karl@gnu.org>
16093
16094         * m4/gettext.m4: Update from GNU gettext 0.14.4.
16095
16096 2005-04-25  Albert Chin  <china@thewrittenword.com>
16097
16098         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
16099         Toolkit C bug.
16100
16101 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
16102
16103         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
16104         (func_ln_if_changed) Remove forcibly for no error message
16105         in case file does not exist.
16106
16107 2005-04-19  Simon Josefsson  <jas@extundo.com>
16108
16109         * gnulib-tool (Options): Make --symlink mean --symbolic.
16110
16111 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
16112
16113         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
16114
16115 2005-04-16  Simon Josefsson  <jas@extundo.com>
16116
16117         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
16118
16119 2005-04-15  Simon Josefsson  <jas@extundo.com>
16120
16121         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
16122
16123 2005-04-15  Simon Josefsson  <jas@extundo.com>
16124
16125         * gnulib-tool: Rename --symlink to --symbolic.
16126
16127 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
16128
16129         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
16130         symbolic links to files instead of copying/moving.  Add --aux-dir,
16131         specifying directory relative --dir where auxiliary build tools
16132         are placed.
16133
16134 2005-04-14  Bruno Haible  <bruno@clisp.org>
16135
16136         * modules/allocsa (License): Change to LGPL.
16137         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
16138
16139 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
16140
16141         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
16142         that "UTC +1 second" continues to work.  Problem reported
16143         by Dmitry V. Levin.
16144         (relunit_snumber): New rule.
16145         (relunit): Use it.
16146
16147 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
16148
16149         * lib/getdate.y (universal_time_zone_table): New constant.
16150         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
16151         universal_time_zone_table.
16152         (lookup_zone): Prefer universal_time_zone_table to
16153         local_time_zone_table, so that "GMT" time stamps are allowed in
16154         London during the summer.  Problem reported by Ian Abbott.
16155
16156 2005-04-12  Jim Meyering  <jim@meyering.net>
16157
16158         * lib/human.c (humblock): Set *options even when returning due to
16159         xstrtoumax conversion failure.  Thanks to a used-uninitialized
16160         warning from gcc-4.
16161
16162 2005-04-09  Jim Meyering  <jim@meyering.net>
16163
16164         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
16165         -Wuninitialized: initialize tm0.tm_year.
16166
16167 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
16168
16169         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
16170         count, since there's no maximum.  All uses changed.
16171         Add member dsts_seen.
16172         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
16173         not being INT_MAX.
16174         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
16175         Use pc_rels_seen to decide whther a date is absolute.
16176
16177         * lib/getdate.y (number): Don't overwrite year.
16178         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
16179         check.
16180
16181 2005-04-02  Simon Josefsson  <jas@extundo.com>
16182
16183         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
16184         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
16185
16186 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
16187
16188         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
16189         where no absolute path name can be longer than PATH_MAX.
16190
16191 2005-03-27  Jim Meyering  <jim@meyering.net>
16192
16193         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
16194
16195 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
16196
16197         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
16198         "one's complement" -> "ones' complement" in comment, as per Knuth.
16199         "value of type" -> "type or expression" in comment.
16200         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
16201
16202 2005-03-26  Jim Meyering  <jim@meyering.net>
16203
16204         Comment nits.
16205         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
16206         Correct typos: s/or/of/.
16207
16208 2005-03-26  Jim Meyering  <jim@meyering.net>
16209
16210         * modules/check-include-files: Move to ../ and rename to...
16211         * check-module: ...this.
16212
16213 2005-03-25  Jim Meyering  <jim@meyering.net>
16214
16215         * modules/xvasprintf (Files): Add xalloc.h.
16216
16217 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
16218
16219         * modules/gettext (Files): config/config.rpath ->
16220         build-aux/config.rpath
16221         * modules/iconv (Files): Likewise.
16222         Problem reported by Oskar Liljeblad.
16223
16224 2005-03-23  Jim Meyering  <jim@meyering.net>
16225
16226         * modules/check-include-files: New script to check for
16227         missing dependencies, multiple includes, etc.
16228
16229         * modules/c-strtold (Depends-on): Add xalloc.
16230         * modules/c-strtod (Depends-on): Add xalloc.
16231         * modules/hash (Depends-on): Add xalloc.
16232         (Files): Remove lib/xalloc.h.
16233
16234         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
16235         * modules/userspec (Files): Add lib/inttostr.h.
16236
16237 2005-03-23  Jim Meyering  <jim@meyering.net>
16238
16239         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
16240
16241 2005-03-22  Jim Meyering  <jim@meyering.net>
16242
16243         * modules/stat-macros: New module.
16244         * modules/canonicalize, modules/euidaccess, modules/file-type,
16245         * modules/filemode, modules/lchown, modules/makepath,
16246         * modules/rmdir, modules/stat: Depend on new stat-macros module
16247         rather than listing lib/stat-macros.h manually.
16248         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
16249
16250 2005-03-22  Jim Meyering  <jim@meyering.net>
16251
16252         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
16253
16254 2005-03-22  Bruno Haible  <bruno@clisp.org>
16255
16256         * config/srclist.txt: Replace target directory 'config' with
16257         'build-aux'.
16258         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
16259         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
16260         ../build-aux/.
16261
16262 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
16263
16264         * modules/chdir-long (Depends-on): Add mempcpy.
16265
16266         * modules/acl, modules/backupfile, modules/c-strtod,
16267         modules/c-strtold, modules/canon-host, modules/canonicalize,
16268         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
16269         modules/exclude, modules/exitfail, modules/file-type,
16270         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
16271         modules/getdate, modules/getline, modules/getpagesize,
16272         modules/getpass, modules/getugroups, modules/group-member,
16273         modules/hard-locale, modules/hash, modules/human, modules/idcache,
16274         modules/inttostr, modules/long-options, modules/makepath,
16275         modules/md5, modules/memcasecmp, modules/memcoll,
16276         modules/modechange, modules/mountlist, modules/path-concat,
16277         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
16278         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
16279         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
16280         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
16281         modules/strftime, modules/strndup, modules/strverscmp,
16282         modules/timespec, modules/unlocked-io, modules/userspec,
16283         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
16284         modules/yesno:
16285         Remove lib_SOURCES line from Makefile.am section, as this is now
16286         done automatically by the corresponding Autoconf macro.
16287
16288 2005-03-21  Jim Meyering  <jim@meyering.net>
16289
16290         Changes imported from coreutils.
16291
16292         * lib/cycle-check.c: Don't include xalloc.h.
16293
16294         * lib/path-concat.c: Don't include assert.h.
16295         (path_concat): Remove assertion that would have triggered
16296         for ABASE starting with more than one slash.
16297         Reported by Andreas Schwab.
16298
16299         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
16300         properly when ABASE is an absolute file name.
16301         Correct the description of this function.
16302         Include <assert.h>.
16303         Add an assertion and a test driver.
16304         This fixes a bug introduced on 2004-07-02.
16305         Andreas Schwab reported the resulting failure of cp --parents:
16306         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
16307
16308 2005-03-21  Jim Meyering  <jim@meyering.net>
16309
16310         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
16311         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
16312
16313 2005-03-21  Jim Meyering  <jim@meyering.net>
16314         and  Paul Eggert  <eggert@cs.ucla.edu>
16315
16316         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
16317         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
16318         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
16319         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
16320         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
16321         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
16322         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
16323         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
16324         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
16325         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
16326         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
16327         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
16328         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
16329         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
16330         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
16331         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
16332         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
16333         for these modules.
16334
16335 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
16336
16337         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
16338         (which shouldn't happen), generate nothing instead of returning 0
16339         immediately, so that nstrftime (NULL, ...) doesn't return 0.
16340
16341 2005-03-16  Bruno Haible  <bruno@clisp.org>
16342
16343         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
16344         HAVE_LONGLONG_64BIT.
16345
16346 2005-03-16  Bruno Haible  <bruno@clisp.org>
16347
16348         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
16349         HAVE_LONGLONG_64BIT.
16350
16351 2005-03-16  Bruno Haible  <bruno@clisp.org>
16352
16353         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
16354         HAVE_LONGLONG_64BIT.
16355
16356 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16357
16358         * lib/strftime.c (my_strftime): Prepend space to format so that we can
16359         reliably distinguish strftime failure from empty output on POSIX
16360         hosts.
16361
16362 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16363
16364         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
16365         (iconv_string): Don't guess a size-zero buffer, as that might cause
16366         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
16367         result would be 'too large', where 'too large' is (heuristically)
16368         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
16369         overflow concerns.  This will prevent some unwanted malloc failures
16370         when the inputs are very large.
16371
16372 2005-03-15  Karl Berry  <karl@gnu.org>
16373
16374         * config/srclist.txt (config.rpath): from gettext.
16375         * config/config.rpath: update.
16376
16377 2005-03-15  Bruno Haible  <bruno@clisp.org>
16378
16379         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
16380         to 'negate'.
16381
16382         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
16383         variable.
16384
16385         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
16386         results.
16387
16388 2005-03-14  Simon Josefsson  <jas@extundo.com>
16389
16390         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
16391         <fx@gnu.org>.
16392
16393 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
16394
16395         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
16396         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
16397         intprops.h.
16398         * lib/strtol.c: Likewise.
16399
16400 2005-03-14  Jim Meyering  <jim@meyering.net>
16401
16402         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
16403         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
16404         to be nonzero so that we (and caller) can detect the difference
16405         between a valid zero-length expansion and an error return, even
16406         when the underlying strftime fails before writing anything into
16407         that location.
16408
16409 2005-03-14  Bruno Haible  <bruno@clisp.org>
16410
16411         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
16412         Update from GNU gettext 0.14.3.
16413
16414 2005-03-10  Jim Meyering  <jim@meyering.net>
16415
16416         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
16417
16418 2005-03-10  Jim Meyering  <jim@meyering.net>
16419
16420         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
16421         so that this module works on systems without fchdir.
16422
16423 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
16424
16425         Factor int-properties macros into a single file, except for
16426         glibc-related files.
16427         * lib/intprops.h: New file.
16428         * lib/getloadavg.c: Include it instead of limits.h.
16429         (INT_STRLEN_BOUND): Remove.
16430         * lib/human.c: Include intprops.h.
16431         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
16432         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
16433         302/1000.
16434         * lib/inttostr.h: Include intprops.h instead of limits.h.
16435         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
16436         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
16437         for consistency with intprops.h.
16438         (time_t_is_integer, twos_complement_arithmetic): Use them.
16439         * lib/sig2str.h: Include <signal.h>, intprops.h.
16440         (INT_STRLEN_BOUND): Remove.
16441         * lib/strftime.c (TYPE_SIGNED): Remove.
16442         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
16443         * lib/strtol.c: Adjust comments to match intprops.h.
16444         * lib/userspec.c: Include intprops.h.
16445         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
16446         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
16447         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
16448         instead of rolling our own expressions.
16449         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
16450
16451         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
16452         instead of int.
16453         (my_strftime): Do not mishandle years close to INT_MAX, by doing
16454         the right thing even if adding 1900 would overflow.  Similarly
16455         for tm_mon + 1 and tm_yday + 1.
16456         Make %Y always equivalent to %C%y, and similarly for %G and %g.
16457         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
16458         (DO_SIGNED_NUMBER): New macro.
16459         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
16460
16461 2005-03-07  Bruno Haible  <bruno@clisp.org>
16462
16463         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
16464
16465 2005-03-07  Bruno Haible  <bruno@clisp.org>
16466
16467         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
16468
16469 2005-03-04  Derek R. Price  <derek@ximbiot.com>
16470
16471         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
16472         (func_import): Only replace files via --import when they have actually
16473         changed.
16474
16475 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16476
16477         * m4/mmap-anon.m4: New file.
16478         * m4/pagealign_alloc.m4: New file.
16479
16480 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16481             Bruno Haible  <bruno@clisp.org>
16482
16483         * modules/pagealign_alloc: New file.
16484         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
16485
16486 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16487             Bruno Haible  <bruno@clisp.org>
16488
16489         * lib/pagealign_alloc.h: New file.
16490         * lib/pagealign_alloc.c: New file.
16491
16492 2005-03-03  Bruno Haible  <bruno@clisp.org>
16493
16494         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
16495         Use an all-permissive copyright notice, recommended by RMS.
16496
16497 2005-03-02  Bruno Haible  <bruno@clisp.org>
16498
16499         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
16500         of AIX, the replacement has to be done only after <string.h> is
16501         included, therefore not in config.h. stpncpy.h does the replacement,
16502         and stpncpy.c uses it.
16503
16504 2005-03-02  Bruno Haible  <bruno@clisp.org>
16505
16506         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
16507         stpncpy.c uses it.
16508
16509 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
16510
16511         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
16512         The workaround isn't strictly needed for POSIX conformance, and
16513         it's too much of a pain to configure and maintain.  We'll ask
16514         people to fix their kernels instead.
16515         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
16516         (NANOSLEEP_BUG_WORKAROUND): Remove.
16517         (xnanosleep): Remove the workaround.
16518
16519 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
16520
16521         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
16522         Reported by Derek Price.
16523         (Include): Add "timespec.h".
16524
16525         * modules/xnanosleep (Depends-on): Remove gethrxtime.
16526
16527 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
16528
16529         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
16530         to detect nanosleep bug.
16531
16532 2005-03-01  Bruno Haible  <bruno@clisp.org>
16533
16534         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
16535
16536 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
16537
16538         * modules/gethrxtime: New file.
16539         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
16540         (Depends-on): Add gethrxtime.
16541         (configure.ac): Add gl_XNANOSLEEP.
16542         (Makefile.am): Remove lib_SOURCES line.
16543
16544 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
16545
16546         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
16547         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
16548
16549 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
16550
16551         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
16552         * lib/timespec.h (gettime): Return void, since it always
16553         succeeds now.  All uses changed.
16554         * lib/gettime.c (gettime) Likewise.
16555         [HAVE_NANOTIME]: Prefer nanotime.
16556         Assume gettimeofday succeeds, as POSIX requires.
16557         Assime time () succeeds, since other code already does.
16558         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
16559         (timespec_subtract): Remove.
16560         (NANOSLEEP_BUG_WORKAROUND): New constant.
16561         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
16562         things considerably.  Use it only on GNU/Linux hosts, since the
16563         workaround shouldn't be needed elsewhere.
16564
16565 2005-02-24  Bruno Haible  <bruno@clisp.org>
16566
16567         * modules/gettext (Files): Add m4/glibc2.m4.
16568
16569 2005-02-24  Bruno Haible  <bruno@clisp.org>
16570
16571         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
16572         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
16573         * m4/progtest.m4:
16574         Update from GNU gettext 0.14.2.
16575         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
16576
16577 2005-02-24  Bruno Haible  <bruno@clisp.org>
16578
16579         * lib/localcharset.c: Update from GNU gettext 0.14.2.
16580         * lib/config.charset: Update from GNU gettext 0.14.2.
16581
16582 2005-02-24  Bruno Haible  <bruno@clisp.org>
16583
16584         * lib/gettext.h: Update from GNU gettext 0.14.2.
16585
16586 2005-02-23  Simon Josefsson  <jas@extundo.com>
16587
16588         * m4/iconvme.m4: New file.
16589
16590 2005-02-23  Jim Meyering  <jim@meyering.net>
16591
16592         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
16593         change.
16594         Thanks to Bruno Haible for catching it.
16595
16596 2005-02-22  Simon Josefsson  <jas@extundo.com>
16597
16598         * modules/iconvme: New file.
16599
16600         * MODULES.html.sh: Add iconvme.
16601
16602 2005-02-22  Simon Josefsson  <jas@extundo.com>
16603
16604         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
16605
16606 2005-02-22  Simon Josefsson  <jas@extundo.com>
16607
16608         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
16609
16610 2005-02-22  Jim Meyering  <jim@meyering.net>
16611
16612         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
16613         s/ifndef/ifdef/.
16614
16615 2005-02-20  Neil Conway  <neilc@samurai.com>
16616
16617         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
16618         returned by OSX/Darwin if the specified buffer is not large
16619         enough for the hostname.
16620
16621 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16622
16623         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
16624         pass it to _help, otherwise the latter coredumps trying to
16625         dereference state.root_argp.
16626
16627 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
16628
16629         * modules/chdir-long (Depends-on): Add memrchr.
16630         * modules/memrchr (Files): Add lib/memrchr.h.
16631         (Include): "memrchr.h".
16632
16633 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
16634
16635         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
16636
16637 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
16638
16639         * lib/memrchr.h: New file.
16640         * lib/chdir-long.c: Include it.
16641         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
16642         Don't bother including stddef.h.
16643
16644 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
16645
16646         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
16647         inclusion.
16648         Include <sys/types.h>, for dev_t.
16649         (ME_DUMMY, ME_REMOTE): Move from here....
16650         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
16651         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
16652         Dmitry V. Levin.
16653         Include mountlist.h first, to test the interface.
16654
16655 2005-01-29  Bruno Haible  <bruno@clisp.org>
16656
16657         * lib/progname.c (program_name): Initialize.
16658         Needed when linking statically on MacOS X.
16659
16660 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
16661
16662         Sync from coreutils.
16663         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
16664         (Depends-on): Add c-strtod.
16665         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
16666
16667 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
16668
16669         Sync from coreutils.
16670         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
16671
16672         Remove files that are specific to coreutils.
16673         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
16674
16675 2005-01-28  Bruno Haible  <bruno@clisp.org>
16676
16677         * modules/javacomp: New file.
16678         * MODULES.html.sh (Java): Add javacomp.
16679
16680 2005-01-28  Bruno Haible  <bruno@clisp.org>
16681
16682         * m4/javacomp.m4: New file, from GNU gettext.
16683
16684 2005-01-28  Bruno Haible  <bruno@clisp.org>
16685
16686         * lib/javacomp.sh.in: New file, from GNU gettext.
16687         * lib/javacomp.h: New file, from GNU gettext.
16688         * lib/javacomp.c: New file, from GNU gettext.
16689
16690 2005-01-26  Simon Josefsson  <jas@extundo.com>
16691
16692         * lib/gai_strerror.c: Use GPL in header.
16693
16694 2005-01-26  Bruno Haible  <bruno@clisp.org>
16695
16696         * modules/javaexec: New file.
16697         * MODULES.html.sh (Java): Add javaexec.
16698
16699 2005-01-26  Bruno Haible  <bruno@clisp.org>
16700
16701         * m4/javaexec.m4: New file, from GNU gettext.
16702
16703 2005-01-26  Bruno Haible  <bruno@clisp.org>
16704
16705         * lib/javaexec.sh.in: New file, from GNU gettext.
16706         * lib/javaexec.h: New file, from GNU gettext.
16707         * lib/javaexec.c: New file, from GNU gettext.
16708
16709 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16710
16711         * modules/lchown (Depends-on): Remove lchown.h
16712
16713 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16714
16715         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
16716         must be defined if the header file was not found, in order
16717         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
16718
16719 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16720
16721         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
16722         initializers for struct pentry_state.
16723         (__argp_error): Check return value of __asprintf
16724         (__argp_failure): Translate error message
16725
16726         * lib/argp-parse.c: Removed braces around the expansion of N_()
16727
16728 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
16729
16730         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
16731         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
16732         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
16733         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
16734         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
16735         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
16736         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
16737         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
16738         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
16739         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
16740         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
16741         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
16742         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
16743         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
16744         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
16745         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
16746         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
16747         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
16748         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
16749         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
16750         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
16751         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
16752         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
16753         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
16754         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
16755         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
16756         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
16757         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
16758         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
16759         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
16760         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
16761         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
16762         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
16763         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
16764         xstrtol.m4, xstrtoumax.m4, yesno.m4:
16765         Use an all-permissive copyright notice, recommended by RMS.
16766
16767 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
16768
16769         * modules/chdir-long (Depends-on): Remove mempcpy.
16770
16771 2005-01-21  Jim Meyering  <jim@meyering.net>
16772
16773         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
16774         same value as for Solaris 9.
16775
16776         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
16777         component length.  This included changing the parameter to be
16778         of type `char *' rather than `char const *'.
16779         * lib/chdir-long.h (chdir_long): Update prototype.
16780
16781         * lib/openat.c (fdopendir, fstatat): New functions.
16782         * lib/openat.h: Include headers required for use of DIR and struct
16783         stat.
16784         [AT_SYMLINK_NOFOLLOW]: Define.
16785         (fdopendir, fstatat): Add prototypes.
16786
16787 2005-01-21  Bruno Haible  <bruno@clisp.org>
16788
16789         * modules/classpath: New file.
16790         * MODULES.html.sh (Java): Add classpath.
16791
16792 2005-01-21  Bruno Haible  <bruno@clisp.org>
16793
16794         * lib/classpath.h: New file, from GNU gettext.
16795         * lib/classpath.c: New file, from GNU gettext.
16796
16797 2005-01-20  Simon Josefsson  <jas@extundo.com>
16798
16799         * modules/version-etc-fsf: New file.
16800
16801 2005-01-20  Simon Josefsson  <jas@extundo.com>
16802
16803         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
16804         * lib/version-etc.c: Remove version_etc_copyright.
16805         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
16806         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
16807
16808 2005-01-20  Simon Josefsson  <jas@extundo.com>
16809
16810         * lib/base64.h (isbase64): Add.
16811
16812         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
16813         using a unsigned prototype, don't inline.
16814         (base64_decode): Use it.
16815
16816 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
16817
16818         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
16819         it.
16820
16821 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
16822
16823         * lib/save-cwd.c (save_cwd): Remove code to support the case
16824         where fchdir is missing or flaky.
16825
16826 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
16827
16828         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
16829
16830 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
16831
16832         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
16833         AC_LIBSOURCES now does this.
16834         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
16835         with new ullong_max module.
16836
16837 2005-01-19  Bruno Haible  <bruno@clisp.org>
16838
16839         * modules/sh-quote: New file.
16840         * MODULES.html.sh (Executing programs): Add sh-quote.
16841
16842 2005-01-19  Bruno Haible  <bruno@clisp.org>
16843
16844         * lib/sh-quote.h: New file, from GNU gettext.
16845         * lib/sh-quote.c: New file, from GNU gettext.
16846
16847 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
16848
16849         Merge from coreutils.
16850         * m4/ullong_max.m4: New file.
16851         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
16852         (gl_MACROS): Assume localeconv exists.
16853
16854 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
16855
16856         Merge changes from coreutils, as described below in several
16857         changelogs dated today.
16858
16859         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
16860         (O_DIRECTORY): Remove; not needed here, since "." must be
16861         a directory.  All uses removed.
16862         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
16863         universal on Suns, and we also need to test for IRIX.
16864         Revamp code to use 'if' rather than '#if'.
16865         Avoid unnecessary comparison of cwd->desc to 0.
16866
16867         * lib/utimens.c (futimens): Robustify the previous patch, by checking
16868         for known valid error numbers rather than observed invalid ones.
16869
16870 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
16871
16872         * modules/ullong_max: New file.
16873
16874         * modules/chdir-long, modules/openat: New files.
16875         * modules/save-cwd (Depends-on): Depend on chdir-long.
16876         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
16877
16878 2005-01-18  Jim Meyering  <jim@meyering.net>
16879
16880         Merge from coreutils.
16881         * m4/chdir-long.m4, m4/openat.m4: New files.
16882         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
16883         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
16884         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
16885         is sane and DOES follow symlinks.  Besides, testing 20 different
16886         systems found no broken chown implementations.
16887         Prompted by a change in rsync's copy of this macro.
16888         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
16889
16890         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
16891
16892         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
16893         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
16894         NULL-means-set-to-current-time semantics.
16895         Remove temporary file immediately, rather than waiting
16896         for configure's at-exit trap code to do it.
16897
16898 2005-01-18  Jim Meyering  <jim@meyering.net>
16899
16900         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16901
16902         * lib/utimens.c (futimens): Account for the fact that futimes
16903         can also fail with errno == ENOSYS or errno == ENOENT.
16904         Patch from Dmitry V. Levin.
16905
16906         Change the name of the robust chdir function from chdir to chdir_long.
16907         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
16908         (restore_cwd): Use chdir_long, not chdir.
16909         * lib/chdir-long.c: Renamed from chdir.c.
16910         * lib/chdir-long.h: Renamed from chdir.h.
16911         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
16912         Hurd.
16913
16914 2005-01-18  Bruno Haible  <bruno@clisp.org>
16915
16916         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
16917         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
16918         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
16919         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
16920         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
16921         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
16922         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
16923         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
16924         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
16925         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
16926         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
16927         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
16928         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
16929         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
16930         Use an all-permissive copyright notice, recommended by RMS.
16931
16932 2005-01-18  Bob Proulx  <bob@proulx.com>
16933
16934         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
16935         simplify offsetof() macro construct to avoid compile failure with
16936         native HP-UX 11.0 ANSI C compiler.
16937
16938 2005-01-17  Bruno Haible  <bruno@clisp.org>
16939
16940         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
16941         redundant because stpncpy.m4 takes care of it.
16942
16943 2005-01-17  Bruno Haible  <bruno@clisp.org>
16944
16945         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
16946
16947 2005-01-17  Bruno Haible  <bruno@clisp.org>
16948
16949         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
16950         used.
16951
16952 2005-01-17  Bruno Haible  <bruno@clisp.org>
16953
16954         * lib/fwriteerror.h (fwriteerror): Change specification to include
16955         fclose.
16956         * lib/fwriteerror.c: Include <stdbool.h>.
16957         (fwriteerror): At the end, close the file stream. Record whether
16958         stdout was already closed.
16959
16960 2005-01-17  Bruno Haible  <bruno@clisp.org>
16961
16962         * lib/execute.c (environ): Declare if needed.
16963         * lib/pipe.c (environ): Likewise.
16964         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
16965
16966 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16967
16968         * modules/argp: Depend on vsnprintf
16969
16970 2005-01-10  Jim Meyering  <jim@meyering.net>
16971
16972         * modules/closeout (Depends-on): Add atexit.
16973
16974 2005-01-06  Bruno Haible  <bruno@clisp.org>
16975
16976         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
16977
16978 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16979
16980         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
16981         definitions to be after all include files, to avoid collisions.
16982         Problem reported by Bob Proulx.
16983
16984 2005-01-04  Jim Meyering  <jim@meyering.net>
16985
16986         Changes imported from coreutils.
16987         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
16988         as the mkstemp template, use a temporary directory and an
16989         8.3-friendly template to avoid trouble on systems like DJGPP.
16990         Reported by Juan M. Guerrero via Stepan Kasal.
16991         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
16992         close. Remove the temporary directory right away, rather than waiting
16993         for configure's at-exit trap code to do it.
16994         Suggestion from Stepan Kasal.
16995
16996 2005-01-01  Simon Josefsson  <jas@extundo.com>
16997
16998         * gnulib-tool: Print #include directives when --import'ing.
16999
17000 2004-12-28  Simon Josefsson  <jas@extundo.com>
17001
17002         * tests/test-base64.c: Include required header files.  Remove
17003         unused variables.
17004
17005 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17006
17007         * modules/error (Depends-on): Remove gettext.
17008
17009 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17010
17011         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
17012         not needed.  This removes a dependency on the gettext module.
17013         [defined _LIBC]: Do not include <libintl.h>; not needed.
17014
17015 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17016
17017         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
17018         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
17019
17020 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17021
17022         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
17023         HAVE_DECL_STRTOLD.
17024
17025 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17026
17027         * modules/getdate (Depends-on): Remove alloca-opt.
17028
17029 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17030
17031         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
17032
17033 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17034
17035         * lib/argp-parse.c: Include <stddef.h>.
17036         (alignof, alignto): New macros.
17037         (parser_init): Don't assume that void * is aligned sufficiently
17038         for struct option.
17039
17040         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
17041         need to extend the stack.
17042         (YYINITDEPTH): New macro, so that the initial stack isn't overly
17043         large.
17044
17045 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17046
17047         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
17048
17049 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17050
17051         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
17052         (2004-10-24) change.  Apparently this was a false alarm.
17053
17054         * modules/getdate: Depend on alloca-opt, not alloca.
17055
17056 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17057
17058         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
17059         Remove now-obsolete comment about AIX.
17060         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
17061         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
17062         (YYMAXDEPTH): New macro.
17063
17064 2004-12-18  Simon Josefsson  <jas@extundo.com>
17065
17066         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
17067
17068 2004-12-18  Bruno Haible  <bruno@clisp.org>
17069
17070         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
17071
17072 2004-12-18  Bruno Haible  <bruno@clisp.org>
17073
17074         * lib/fatal-signal.c (fatal_signals): Make non-const.
17075         (init_fatal_signals): New function.
17076         (uninstall_handlers, install_handlers): Ignore signals that were set to
17077         SIG_IGN.
17078         (at_fatal_signal): Call init_fatal_signals.
17079         (init_fatal_signal_set): Likewise. Ignore signals that were set to
17080         SIG_IGN.
17081         Reported by Paul Eggert.
17082
17083 2004-12-18  Bruno Haible  <bruno@clisp.org>
17084
17085         * doc/alloca.texi: New file.
17086         * doc/alloca-opt.texi: New file.
17087
17088 2004-12-17  Jim Meyering  <jim@meyering.net>
17089
17090         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
17091         Otherwise, install-sh could exit with improper exit status when
17092         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
17093
17094 2004-12-16  Simon Josefsson  <jas@extundo.com>
17095
17096         * tests/test-base64.c: Add license.
17097
17098 2004-12-15  Stepan Kasal  <address@hidden>
17099
17100         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
17101
17102 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
17103
17104         * modules/getcwd (Files): Add m4/d-ino.m4.
17105         Suggested by Mark D. Baushke.
17106
17107 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17108
17109         * lib/getdate.y (textint): New member "negative".
17110         (time_zone_hhmm): New function.
17111         Expect 14 shift-reduce conflicts, not 13.
17112         (o_colon_minutes): New rule.
17113         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
17114         (yylex): Set the "negative" member of signed numbers.
17115
17116 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17117
17118         * doc/getdate.texi (Time of day items, Time zone items):
17119         Describe new formats +00:00, UTC+00:00.
17120
17121 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
17122
17123         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
17124         spurious "-l"s.  Problem reported by Stepan Kasal.
17125
17126 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
17127
17128         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
17129         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
17130
17131 2004-12-04  Simon Josefsson  <jas@extundo.com>
17132
17133         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
17134         Vandoorselaere <yoann@prelude-ids.org>.
17135
17136 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17137
17138         Changes imported from coreutils.
17139         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
17140         exist.
17141         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
17142
17143 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17144
17145         Changes imported from coreutils.
17146         * lib/hard-locale.c: Assume <locale.h> exists.
17147         Include "strdup.h".
17148         (GLIBC_VERSION): New macro.
17149         (hard_locale): Assume setlocale exists.
17150         Rewrite to avoid #ifdef.
17151         Use strdup rather than malloc + strcpy.
17152         * lib/human.c: Assume <locale.h> exists.
17153         (human_readable): Assume localeconv exists.
17154
17155 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17156
17157         * modules/hard-locale (Depends-on): Add strdup.
17158
17159 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
17160
17161         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
17162         convert T2, not T.  (Imported from libc.)
17163
17164 2004-11-30  Simon Josefsson  <jas@extundo.com>
17165
17166         * modules/restrict (License): Change to LGPL.
17167
17168 2004-11-30  Simon Josefsson  <jas@extundo.com>
17169
17170         * m4/restrict.m4: Add copyright and copying conditions.
17171
17172 2004-11-30  Simon Josefsson  <jas@extundo.com>
17173
17174         * m4/base64.m4: New file.
17175
17176 2004-11-30  Simon Josefsson  <jas@extundo.com>
17177
17178         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
17179         base64.
17180
17181         * tests/test-base64.c: New file.
17182
17183         * modules/base64: New file.
17184
17185 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17186
17187         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
17188         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
17189
17190         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
17191
17192 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17193
17194         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
17195         (__getcwd.c): Don't restore errno; glibc doesn't.
17196         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
17197         first, falling back to our code only if its results look suspicious.
17198         Ensure that the resulting buffer is only as large as necessary.
17199
17200         * lib/readutmp.c: Include readutmp.h first.
17201         Include <errno.h>, since readutmp.h no longer does that.
17202         * lib/readutmp.h: Don't include <errno.h>,
17203         <sys/param.h>, <time.h>; not needed to establish interface.
17204         (errno): Remove decl.
17205         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
17206         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
17207         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
17208
17209 2004-11-28  Simon Josefsson  <jas@extundo.com>
17210
17211         * lib/base64.h, base64.c: New file.
17212
17213 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
17214
17215         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
17216
17217 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
17218
17219         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
17220         (Depends-on): Remove pathmax, same.  Add mempcpy.
17221         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
17222         (Makefile.am): Append getcwd.h to lib_SOURCES.
17223         (Include): Add getcwd.h.
17224         (Maintainer): Change from Jim Meyering to "all, glibc",
17225         since getdate now uses intended-for-glibc code.
17226         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
17227         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
17228
17229 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17230
17231         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
17232         HP's ANSI C compiler.
17233         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
17234         Declaring int functions causes warnings on some modern systems and
17235         shouldn't be needed to compile on ancient ones.
17236         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
17237         defined.
17238
17239         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
17240         with the following changes.
17241         (__set_errno): Parenthesize properly.
17242         Include <stdbool.h>.
17243         (MIN, MAX, MATCHING_INO): New macros.
17244         (__getcwd): Define with prototype, not K&R form.
17245         Use heuristics to allocate default buffer on stack if possible.
17246         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
17247         behavior, and to avoid the PATH_MAX limit when computing
17248         ../../../../...
17249         Use MATCHING_INO to compare inode number to file.
17250         Check for arithmetic overflow in size calculations.
17251         Fix bug in reallocation of dot array that caused getcwd to fail
17252         on directories nested deeper than 75.
17253         Be more careful about saving errno on error.
17254         Do not use realloc; use only free+malloc, as this is a bit
17255         more flexible and avoids a needless copy operation.
17256         Do not inspect st_dev and st_ino for symbolic links; POSIX
17257         doesn't specify the latter.
17258         Check for closedir errors.
17259         Avoid needless casts.
17260         Use "#ifdef weak_alias" around weak_alias, to be like other
17261         glibc code.
17262         The following changes to getcwd.c have effect only when used in
17263         gnulib; they have no effect inside glibc proper.
17264         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
17265         as alloca isn't used.
17266         (alloca, __alloca): Likewise.
17267         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
17268         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17269         unconditionally, as gnulib assumes C89 or better.
17270         Do not include <sys/param.h>.
17271         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
17272         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
17273         better.
17274         (NULL) [!defined NULL]: Remove; we assume C89 or better.
17275         Include <dirent.h> in a way that is compatible with modern Autoconf.
17276         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
17277         New macros, if not already defined.
17278         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
17279         Use "_LIBC", not "defined _LIBC", for consistency.
17280         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
17281         a mempcpy module.
17282         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
17283         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
17284         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
17285         credit only to Jim Meyering and adjust the copyright dates.
17286         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
17287         <stdlib.h>, <unistd.h>, "pathmax.h".
17288         Instead, include "xgetcwd.h" (first) and "getcwd.h".
17289         (INITIAL_BUFFER_SIZE): Remove.
17290         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
17291
17292 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17293
17294         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
17295         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
17296         Use the _ONCE methods, for efficiency.
17297         Check for fcntl.h.  In test program, include <errno.h>
17298         and <fcntl.h> if available.  Remove old K&R cruft from
17299         test program.  Check for common errors in GNU/Linux,
17300         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
17301         don't do AC_LIBOBJ, as that's getcwd.m4's job.
17302         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
17303         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
17304         name accordingly.
17305         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
17306         accommodate new getcwd.c.
17307         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
17308         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
17309         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
17310         that's all we need now.
17311
17312 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17313
17314         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
17315         argp-parse.c depends on getopt internals, that means we should
17316         always use our getopt, to be on the safe side.
17317         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
17318         order not to spoil the result of an eventual previous invocation
17319         of gl_GETOPT_SUBSTITUTE.
17320
17321 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17322
17323         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
17324         redefinition warnings. To avoid them, include the defines
17325         in `#if !defined __need_getopt ... #endif'. The only place
17326         where __getopt_argv_const is used is in definitions
17327         of getopt_long and getopt_long_only below, which are as well
17328         protected by `#ifndef __need_getopt'.
17329         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
17330         __need_getopt after including <stdio.h> and <unistd.h> These
17331         headers might have defined it.
17332
17333 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17334
17335         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
17336
17337 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17338
17339         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
17340         (futimens): New function, which uses futimes if available.
17341         (futimens, utimens): Support timespec==NULL, with same semantics
17342         as utime and utimens.
17343         * lib/utimens.h (futimens): New decl.
17344
17345 2004-11-23  Jim Meyering  <jim@meyering.net>
17346
17347         * lib/getopt_.h: Remove trailing blanks.
17348
17349 2004-11-23  Jim Meyering  <jim@meyering.net>
17350
17351         * lib/__fpending.c: Add comment.
17352
17353 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
17354
17355         * modules/canonicalize (Depends-on): Add xreadlink.
17356         Problem reported by James Youngman.
17357
17358 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
17359
17360         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
17361         New macros.
17362         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
17363         optopt): Use them instead of invoking ## directly; otherwise, the
17364         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
17365
17366 2004-11-19  Bruno Haible  <bruno@clisp.org>
17367
17368         * lib/strtok_r.c: Move comments from here...
17369         * lib/strtok_r.h: ... to here.
17370
17371 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17372
17373         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
17374         implementations that mishandle size_t overflow.
17375
17376 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17377
17378         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
17379         might fail.  Problem reported by Yoann Vandoorselaere.
17380         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
17381         implementations that mishandle size_t overflow.
17382
17383 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17384
17385         * modules/canon-host (Depends-on): Add strdup.
17386
17387 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17388
17389         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
17390
17391 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17392
17393         * lib/canon-host.c: Include "strdup.h".
17394         (canon_host): Use getaddrinfo if available, so that IPv6 works.
17395         Use strdup instead of malloc/strcpy to duplicate strings.
17396
17397         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
17398         (human_space_before_unit): New constant.
17399         * lib/human.c (human_readable): Support it.
17400
17401         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
17402         (xgetcwd): Set errno correctly when failing.
17403         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
17404         the failure is actually due to a PATH_MAX problem.
17405
17406         Further getopt changes to make it more likely that glibc will
17407         buy the changes back.
17408         * lib/getopt.c (POSIXLY_CORRECT): New constant.
17409         (getopt): Use it, so to preserve glibc semantic
17410         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
17411         when compiling for libc.
17412         * lib/getopt_.h (__getopt_argv_const): Bring it back.
17413         (getopt_long, getopt_long_only): Use it.
17414
17415         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
17416         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
17417         (getopt): Argv is now char * const *, as per standard.
17418         (_getopt_internal_r, _getopt_internal): Argv is now char **,
17419         not char *__getopt_argv_const *.
17420         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
17421         _getopt_long_only_r): Likewise.
17422         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
17423         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
17424         _getopt_long_r, _getopt_long_only_r): Likewise.
17425         * lib/getopt_.h (__getopt_argv_const): Remove.
17426         (getopt): Argv is now char * const *, as per standard.
17427
17428         * lib/getdate.y (tORDINAL): New token.
17429         (day, relunit): Allow it for relative times.
17430         (relative_time_table): Use tORDINAL for ordinals.
17431
17432 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17433
17434         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
17435         Document that "second" isn't allowed as an ordinal number.
17436
17437 2004-11-16  Jim Meyering  <jim@meyering.net>
17438
17439         * modules/closeout (Depends-on): Add fpending.
17440
17441 2004-11-15  Jim Meyering  <jim@meyering.net>
17442
17443         * lib/closeout.c: Include "__fpending.h" once again.
17444         Include <stdbool.h>.
17445         (close_stdout): Don't fail just because stdout was closed initially,
17446         since some programs don't write to stdout in the normal course of
17447         operation (other than --version and --help), and we don't want this
17448         function to make e.g. `touch file >&-' fail.
17449         But do fail if it was closed and someone has tried to write to it.
17450         E.g., `printf foo >&-' must fail.
17451
17452 2004-11-13  Jim Meyering  <jim@meyering.net>
17453
17454         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
17455
17456 2004-11-12  Simon Josefsson  <jas@extundo.com>
17457
17458         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
17459         small doc fix is still pending.
17460
17461 2004-11-11  Simon Josefsson  <jas@extundo.com>
17462
17463         * modules/strtok_r: New file.
17464
17465         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17466         strtok_r.
17467
17468 2004-11-11  Simon Josefsson  <jas@extundo.com>
17469
17470         * m4/strtok_r.m4: New file.
17471
17472         * m4/getopt.m4: Replace opterr.
17473
17474 2004-11-11  Simon Josefsson  <jas@extundo.com>
17475
17476         * lib/strtok_r.h, strtok_r.c: New file.
17477
17478 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
17479
17480         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
17481         of replacing opterr, getopt, etc.  This should handle the
17482         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
17483
17484 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
17485
17486         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
17487         we can stop lying to compilers about the constness of argv when we
17488         are compiled outside glibc.
17489         (getopt, getopt_long, getopt_long_only): Use it.
17490         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
17491         _getopt_internal, getopt): Likewise.
17492         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
17493         _getopt_long_only_r): Likewise.
17494         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
17495         _getopt_long_r, _getopt_long_only_r): Likewise.
17496
17497         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
17498         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
17499         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
17500         the other external symbols.
17501         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
17502         declaration, since the above renaming now works around collisions.
17503
17504 2004-11-11  Jim Meyering  <jim@meyering.net>
17505
17506         * lib/linebreak.c: Remove trailing blanks.
17507         * lib/alloca_.h: Likewise.
17508         * lib/acosl.c: Likewise.
17509         * lib/euidaccess.c: Likewise.
17510         * lib/allocsa.h: Likewise.
17511
17512 2004-11-10  Simon Josefsson  <jas@extundo.com>
17513
17514         * m4/getaddrinfo.m4: New file.
17515
17516 2004-11-10  Simon Josefsson  <jas@extundo.com>
17517
17518         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
17519
17520 2004-11-10  Simon Josefsson  <jas@extundo.com>
17521
17522         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17523         getaddrinfo.
17524
17525         * modules/getaddrinfo: New file.
17526
17527 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
17528
17529         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
17530
17531 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
17532
17533         * lib/mktime.c (SHR): New macro, which is a portable
17534         substitute for >> that should work even on Crays.
17535         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
17536         Problem reported by Mark D. Baushke in
17537         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
17538         * lib/getdate.y (SHR): Likewise.
17539         (tm_diff): Use it.
17540         * lib/strftime.c (SHR): Likewise.
17541         (tm_diff): Use it.
17542         * lib/quotearg.c (struct quoting_options): Use unsigned int for
17543         quote_these_too, so that right shifts are well defined.  All uses
17544         changed.
17545
17546 2004-11-10  Jim Meyering  <jim@meyering.net>
17547
17548         Ensure that no close failure goes unreported.
17549         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
17550         return early when it seems there's nothing to flush.
17551         Don't include __fpending.h.
17552
17553 2004-11-10  Jim Meyering  <jim@meyering.net>
17554
17555         * modules/closeout (Depends-on): Remove fpending.
17556
17557 2004-11-10  Jim Meyering  <jim@meyering.net>
17558
17559         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
17560
17561 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
17562
17563         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
17564         gl_FUNC_STRFTIME.
17565         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
17566         and AC_REQUIRE when possible, to avoid duplicate checks.
17567         Check for <wchar.h>.
17568
17569 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
17570
17571         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
17572
17573 2004-11-09  Bruno Haible  <bruno@clisp.org>
17574
17575         * m4/sockpfaf.m4: New file.
17576
17577 2004-11-05  Bruno Haible  <bruno@clisp.org>
17578
17579         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
17580         Reported by Mark D. Baushke <mdb@cvshome.org>.
17581
17582 2004-11-04  Bruno Haible  <bruno@clisp.org>
17583
17584         2004-09-11  Bruno Haible  <bruno@clisp.org>
17585                 * allocsa.valgrind: New file.
17586         2004-02-06  Bruno Haible  <bruno@clisp.org>
17587                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
17588                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
17589                 Reported by Christopher Seip <chris.seip@hp.com>.
17590
17591 2004-11-04  Bruno Haible  <bruno@clisp.org>
17592
17593         * modules/allocsa (Files): Add lib/allocsa.valgrind.
17594         (Makefile.am): Distribute it.
17595
17596 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
17597
17598         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
17599         with errno == ERANGE if the buffer is too small.
17600         Problem reported by Mark D. Baushke.
17601
17602 2004-11-03  Albert Chin  <china@thewrittenword.com>
17603             Paul Eggert  <eggert@cs.ucla.edu>
17604
17605         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
17606         equivalent, substitute $ac_type for equivalent type rather than
17607         blindly using uint32_t *always* which won't work if uint32_t is not
17608         available.  Define _UINT32_T to work around typedef of uint32_t if
17609         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
17610         2.5.1.
17611
17612 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
17613
17614         * m4/jm-macros.m4: Sync from coreutils.
17615         (gl_MACROS): Check for mbrlen, for pathchk.
17616         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
17617
17618 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
17619
17620         * lib/xreadlink.c (MAXSIZE): New macro.
17621         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
17622         size does not exceed MAXSIZE.  Avoid cast.
17623         As suggested by Mark D. Baushke in
17624         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
17625         if readlink fails with buffer size just under MAXSIZE, try again
17626         with MAXSIZE.
17627
17628 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
17629
17630         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
17631
17632 2004-11-02  Derek R. Price  <derek@ximbiot.com>
17633         and  Paul Eggert  <eggert@cs.ucla.edu>
17634
17635         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
17636         (get_date): Overparenthesize to avoid GCC warning.
17637
17638 2004-11-02  Bruno Haible  <bruno@clisp.org>
17639
17640         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
17641         returns void.
17642
17643 2004-11-02  Bruno Haible  <bruno@clisp.org>
17644
17645         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
17646         function returns void.
17647
17648 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
17649
17650         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
17651         fflush_unlocked, flockfile, funlockfile, funlockfile,
17652         fputs_unlocked, putc_unlocked.
17653
17654 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
17655
17656         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
17657         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
17658         already declared.
17659
17660 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
17661
17662         * modules/getdate (Files): Add doc/getdate.texi.
17663         (Depends-on): Add setenv, xalloc.
17664
17665 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
17666
17667         * lib/getdate.y: Add support for TZ="foo" within a date string.
17668         Fix some bugs near time_t boundaries.  Reject dates with
17669         out-of-range components, e.g., "Sept 31".
17670         Include <stdlib.h>, "setenv.h", "xalloc.h".
17671         (ISDIGIT_LOCALE): Remove; unused.
17672         Note that the TZ and time functions used here are not reentrant.
17673         (mktime_ok, get_tz): New functions.
17674         (TZBUFSIZE): New constant.
17675         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
17676         This requires that we sometimes generate our own TZ="XXX..." setting.
17677
17678 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
17679
17680         * doc/getdate.texi: New file, from coreutils with modifications for
17681         the new TZ parsing.
17682
17683 2004-10-27  Derek R. Price  <derek@ximbiot.com>
17684
17685         * lib/mktime.c (not_equal_tm): Remove redundant check.
17686
17687 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
17688
17689         * modules/regex (lib_SOURCES): Add regex.c.
17690         Reported by James Youngman in
17691         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
17692
17693 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
17694
17695         * lib/getdate.y: Use Bison 1.875 features, and some minor
17696         code cleanups.  This change does not affect semantics.
17697         Don't include <stdlib.h>; no longer needed.
17698         Don't include unlocked-io.h; only the "#if TEST" code uses
17699         stdio, and performance isn't crucial there.
17700         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
17701         Bison 1.875 features as described below.
17702         All uses of "PC." replaced by "pc->".
17703         (YYSTYPE): Add a forward declaration.
17704         (yylex, yyerror): Use full prototypes in forward decls.
17705         Use "%pure-parser" rather than obsolescent "%pure_parser".
17706         Use %parse-param and %lex-param instead of obsolescent
17707         YYPARSE_PARAM and YYLEX_PARAM.
17708         (meridian_table, month_and_day_table, time_units_table,
17709         relative_time_table, time_zone_table, military_table,
17710         lookup_zone, lookup_word, get_date):
17711         Use NULL instead of 0 where appropriate.
17712         (to_hour): Avoid abort (), to avoid a dependency on
17713         stdlib.h.
17714         (yyerror, yylex): Now accepts parser_control * arg.
17715         (main) [TEST]: Use '\0' rather than 0 for char.
17716
17717 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
17718
17719         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
17720
17721 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
17722
17723         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
17724         It's now the caller's responsibility to handle the case where
17725         !HAVE_GETPAGESIZE && !defined getpagesize.
17726
17727         * lib/mktime.c (leapyear): Arg is long int, not int.
17728
17729 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
17730
17731         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
17732
17733 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
17734
17735         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
17736         missing.  Problem reported by James Youngman.
17737
17738 2004-10-16  Simon Josefsson  <jas@extundo.com>
17739
17740         * gnulib-tool: Fix comments.  Fix parse problem.
17741         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
17742
17743 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
17744
17745         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
17746         implementation of getopt_long.  Problem reported by Alexander Taler in:
17747         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
17748
17749 2004-10-15  Bruno Haible  <bruno@clisp.org>
17750
17751         * gnulib-tool: Untabify. Initialize supplied_libname.
17752         (func_usage): More homogenous output.
17753         (func_modules_transitive_closure, func_modules_to_filelist,
17754         func_emit_lib_Makefile_am): New functions.
17755         (func_import): New function, extracted from big case statement. Use
17756         func_get_license, func_modules_transitive_closure,
17757         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
17758         opt_lgpl. Don't use test -a, as it's not portable.
17759         (func_create_testdir): Use func_modules_transitive_closure,
17760         func_modules_to_filelist, func_emit_lib_Makefile_am.
17761
17762 2004-10-15  Bruno Haible  <bruno@clisp.org>
17763
17764         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
17765
17766 2004-10-15  Bruno Haible  <bruno@clisp.org>
17767
17768         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
17769         the portions belonging to each module.
17770         Suggested by Derek Robert Price <derek@ximbiot.com>.
17771
17772 2004-10-12  Simon Josefsson  <jas@extundo.com>
17773
17774         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
17775         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
17776         to real functions.
17777
17778 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17779
17780         * modules/vsnprintf: New file.
17781
17782 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17783
17784         * m4/vsnprintf.m4: New file.
17785
17786 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17787
17788         * lib/vsnprintf.h: New file.
17789         * lib/vsnprintf.c: New file.
17790
17791 2004-10-11  Bruno Haible  <bruno@clisp.org>
17792
17793         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
17794         vsnprintf.
17795
17796 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
17797
17798         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
17799
17800 2004-10-07  Bruno Haible  <bruno@clisp.org>
17801
17802         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
17803         fits into the provided buffer.
17804
17805 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
17806
17807         * lib/diacrit.c, diacrit.h: Add GPL notice.
17808
17809         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
17810         notice.
17811         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
17812         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
17813         This avoids a potential constant-folding bug.
17814
17815 2004-10-05  Bruno Haible  <bruno@clisp.org>
17816
17817         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
17818         for the declaration of strsep.
17819
17820 2004-10-05  Bruno Haible  <bruno@clisp.org>
17821
17822         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
17823
17824 2004-10-04  Simon Josefsson  <jas@extundo.com>
17825
17826         * modules/memmem: New file.
17827         * tests/test-memmem.c: New file.
17828         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
17829
17830 2004-10-04  Simon Josefsson  <jas@extundo.com>
17831
17832         * m4/memmem.m4: New file.
17833
17834 2004-10-04  Simon Josefsson  <jas@extundo.com>
17835
17836         * lib/memmem.h: New file.
17837         * lib/memmem.c: New file, taken from glibc.
17838
17839 2004-10-04  Simon Josefsson  <jas@extundo.com>
17840
17841         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
17842         '#ifdef USE_UNLOCKED_IO'.
17843
17844 2004-10-04  Simon Josefsson  <jas@extundo.com>
17845
17846         * config/srclist.txt: Add memmem from glibc.
17847
17848 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
17849
17850         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
17851
17852         * modules/argmatch, modules/argp, modules/closeout, modules/error,
17853         modules/exclude, modules/getdate, modules/getline,
17854         modules/getndelim2, modules/getpass, modules/getpass-gnu,
17855         modules/getusershell, modules/linebuffer, modules/md5,
17856         modules/mountlist, modules/posixtm, modules/readtokens,
17857         modules/readutmp, modules/regex, modules/sha1,
17858         modules/version-etc, modules/yesno:
17859         Remove dependency on unlocked-io.
17860
17861 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
17862
17863         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
17864
17865         * m4/unlocked-io.m4: Add copyright notice.
17866         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
17867
17868 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
17869
17870         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
17871         * lib/xmalloc.c (xmemdup): Likewise.
17872         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
17873         XFREE): Remove these long-obsolescent macros.
17874         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
17875         * lib/xstrdup.c: Remove.
17876
17877         * lib/regex.c (re_comp): Cast gettext return value to char *,
17878         Problem reported by Martin Neitzel via Mark D. Baushke.
17879
17880 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
17881
17882         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
17883         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
17884         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
17885         regex.c, sha1.c, version-etc.c, yesno.c:
17886         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
17887         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
17888         the includer's responsibility.
17889
17890         Sync from coreutils.
17891
17892         * lib/modechange.c (mode_compile): Don't decrement a pointer that
17893         points to the start of a string, as the C Standard says the
17894         resulting behavior is undefined.
17895
17896         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
17897         simple -> simple_backups, numbered_existing ->
17898         numbered_existing_backups, numbered -> numbered_backups
17899         to avoid shadowing problems.  All uses changed.
17900         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
17901         * lib/backupfile.c (check_extension, numbered_backup):
17902         Rename locals to avoid shadowing 'basename'.
17903         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
17904         once.
17905
17906         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
17907         * lib/.cvsignore: Add getopt.h.
17908
17909 2004-10-04  Bruno Haible  <bruno@clisp.org>
17910
17911         * modules/README: New file.
17912         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
17913         not a module.
17914
17915 2004-10-02  Jim Meyering  <jim@meyering.net>
17916
17917         * lib/dirfd.h, getpagesize.h: Add copyright notice.
17918
17919 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17920
17921         * modules/strsep: New file.
17922
17923 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17924
17925         * m4/strsep.m4: New file.
17926
17927 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
17928
17929         * lib/strsep.h: New file.
17930         * lib/strsep.c: New file.
17931
17932 2004-10-01  Simon Josefsson  <jas@extundo.com>
17933
17934         * lib/snprintf.c (snprintf): Handle size==0.
17935
17936 2004-10-01  Simon Josefsson  <jas@extundo.com>
17937             Bruno Haible  <bruno@clisp.org>
17938
17939         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
17940         (snprintf): Declare 'args'.
17941
17942 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
17943
17944         * lib/snprintf.c: Remove comments as to why each header is needed.
17945
17946 2004-10-01  Bruno Haible  <bruno@clisp.org>
17947
17948         * MODULES.html.sh: Add strsep.
17949
17950 2004-09-30  Simon Josefsson  <jas@extundo.com>
17951
17952         * modules/snprintf: New file.
17953
17954 2004-09-30  Simon Josefsson  <jas@extundo.com>
17955
17956         * m4/snprintf.m4: New file.
17957
17958 2004-09-30  Simon Josefsson  <jas@extundo.com>
17959
17960         * lib/snprintf.h, lib/snprintf.c: New files.
17961
17962 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17963
17964         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
17965         (hol_entry_help): Never translate an empty string.
17966         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
17967         * lib/argp.h (OPTION_NO_TRANS): New option.
17968
17969 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
17970
17971         * modules/argp (Maintainer): Replace Simon Josefsson
17972         by Sergey Poznyakoff.
17973
17974 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
17975
17976         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
17977         changes merged back into glibc.
17978
17979 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
17980
17981         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
17982
17983 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
17984
17985         * lib/xvasprintf.c: Include xalloc.h.
17986         (xvasprintf): Use xalloc_die, not xmalloc_die.
17987
17988 2004-09-29  Bruno Haible  <bruno@clisp.org>
17989
17990         * modules/alloca-opt: New file, derived from modules/alloca.
17991         * modules/allocsa: Depend on alloca-opt instead of alloca.
17992         * modules/setenv: Likewise.
17993         * modules/vasnprintf: Likewise.
17994         * MODULES.html.sh: Add alloca-opt.
17995
17996 2004-09-28  Simon Josefsson  <jas@extundo.com>
17997
17998         * gnulib-tool: New parameter --lgpl, to asseert that modules are
17999         LGPL, and to replace license template from GPL to LGPL.
18000
18001 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18002
18003         * modules/dummy: Change license to LGPL.
18004
18005 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18006
18007         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
18008
18009 2004-09-24  Simon Josefsson  <jas@extundo.com>
18010
18011         * modules/minmax (License): Change from GPL to LGPL.
18012
18013 2004-09-23  Simon Josefsson  <jas@extundo.com>
18014
18015         * gnulib-tool (--import): Typo.
18016
18017 2004-09-23  Simon Josefsson  <jas@extundo.com>
18018
18019         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
18020
18021 2004-09-22  Bruno Haible  <bruno@clisp.org>
18022
18023         * modules/*: Add 'License' field.
18024         * gnulib-tool: Accept --extract-license option.
18025         (func_get_license): New function.
18026
18027 2004-09-21  Bruno Haible  <bruno@clisp.org>
18028
18029         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
18030         Reported by Simon Josefsson.
18031
18032 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18033
18034         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
18035         gl_AC_TYPE_LONG_LONG.
18036
18037 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18038
18039         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
18040
18041 2004-09-18  Simon Josefsson  <jas@extundo.com>
18042         and  Paul Eggert  <eggert@cs.ucla.edu>
18043
18044         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
18045         calls with autoreconf.  Define GL_LIB.
18046
18047 2004-09-14  Karl Berry  <karl@gnu.org>
18048
18049         * config/srclist.txt: unsync setenv.c, sigh.
18050
18051 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18052
18053         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
18054         Problem reported by Bruno Haible in:
18055         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
18056
18057 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18058
18059         * config/srclist.txt: Comment out argp-pvh.c.
18060
18061 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
18062
18063         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
18064         in case some system header has #define'd it.  Problem reported by
18065         Soeren D. Schulze in
18066         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
18067
18068 2004-09-09  Karl Berry  <karl@gnu.org>
18069
18070         * regex.[ch]: delete from the root.  These were supposed to be
18071                 synced with emacs cvs, but this has not happened for about
18072                 a year, and anyway nothing else uses emacs regex.[ch].
18073                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
18074                 lib/regex[.ch] is untouched.
18075
18076 2004-09-09  Bruno Haible  <bruno@clisp.org>
18077
18078         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
18079
18080 2004-09-09  Bruno Haible  <bruno@clisp.org>
18081
18082         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
18083         modifications.
18084         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
18085
18086 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18087
18088         * modules/xvasprintf: New file.
18089         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
18090
18091 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18092
18093         * lib/xvasprintf.h: New file.
18094         * lib/xvasprintf.c: New file.
18095         * lib/xasprintf.c: New file.
18096
18097 2004-09-08  Bruno Haible  <bruno@clisp.org>
18098
18099         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
18100
18101 2004-09-08  Bruno Haible  <bruno@clisp.org>
18102
18103         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
18104         length is > INT_MAX.
18105         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
18106         more.
18107
18108 2004-09-08  Bruno Haible  <bruno@clisp.org>
18109
18110         * lib/stdint_.h: New file, taken from GNU clisp.
18111
18112 2004-09-08  Bruno Haible  <bruno@clisp.org>
18113             Oskar Liljeblad  <oskar@osk.mine.nu>
18114
18115         * modules/stdint: New file.
18116         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
18117
18118 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18119
18120         Import from coreutils.
18121         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
18122         strings on unbounded length.  alloca's performance benefits aren't
18123         that important here.
18124         (V_STRDUP): Remove.
18125         (parse_with_separator): New function, with most of the internals
18126         of the old parse_user_spec.  Allow user to omit both user and group,
18127         for compatibility with FreeBSD.
18128         Clone only the user name, not the entire spec.
18129         Do not set *uid, *gid unless entirely successful.
18130         Avoid memory leak in some failing cases.
18131         Fix regression for USER.GROUP reported by Dmitry V. Levin in
18132         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
18133         (parse_user_spec): Rewrite to use parse_with_separator.
18134
18135 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18136
18137         * modules/userspec: Don't depend on alloca.
18138
18139 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18140
18141         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
18142
18143 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18144
18145         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
18146         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
18147         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
18148
18149 2004-08-16  Simon Josefsson  <jas@extundo.com>
18150
18151         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
18152         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
18153         Add --dry-run for --import.
18154         Let user provided command line parameters override configure.ac
18155         settings.
18156
18157 2004-08-12  Simon Josefsson  <jas@extundo.com>
18158
18159         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
18160         as discussed with Paul Eggert in threads rooted at
18161         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
18162         and
18163         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
18164         Before, the test was empty, and relied on ELIDE_CODE in source
18165         code.)
18166         (gl_PREREQ_GETOPT): New macro.
18167         (gl_GETOPT): Use them.
18168
18169 2004-08-12  Simon Josefsson  <jas@extundo.com>
18170
18171         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
18172         * lib/getopt_.h: Renamed from getopt.h.
18173
18174 2004-08-12  Simon Josefsson  <jas@extundo.com>
18175
18176         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
18177         Change default library name from libfoo to libgnu.
18178         Now, if you have a configure.ac that says:
18179                 gl_SOURCE_BASE(gl)
18180                 gl_M4_BASE(gl/m4)
18181                 gl_MODULES(error getopt etcetera)
18182                 gl_INIT
18183         you can import all you need by running:
18184                 ../gnulib/gnulib-tool --import
18185
18186         * modules/getopt (Files): Rename getopt.h to getopt_.h.
18187         (Makefile.am): Rewrite, use logic from argz.
18188         (Include): Use <getopt.h> instead of "getopt.h".
18189
18190 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18191
18192         * modules/argp (Files): Add m4/unlocked-io.m4.
18193         (Depends-on): Add extensions.
18194
18195 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18196
18197         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
18198         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
18199         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
18200         Check for program_invocation_name, program_invocation_short_name,
18201         flockfile, funlockfile, features.h, _getopt_long_only_r.
18202
18203 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18204
18205         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
18206         its complicated substitute.
18207         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
18208         and program_invocation_name.
18209         (__argp_basename) [!_LIBC]: Remove; the only use was
18210         replaced by its body.
18211         (__argp_short_program_name): Change condition from
18212         !defined __argp_short_program_name to
18213         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
18214         to match argp-namefrob.h.
18215         (__argp_failure): Don't assume strerror_r returns char *.
18216         * lib/argp-parse.c (N_): Define unconditionally.
18217         (argp_default_options): Fill out initializers with 0 to avoid
18218         gcc warnings.
18219
18220 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18221
18222         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
18223         getopt1.c.
18224
18225 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18226
18227         Merge from coreutils.
18228
18229         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
18230
18231         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
18232         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
18233
18234 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18235
18236         Merge from coreutils.
18237
18238         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
18239         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
18240         for Reliant Unix 5.43.
18241
18242         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
18243         (union fooround): Use uintmax_t, not long int.
18244         The rest is a merge from libc:
18245         [defined _LIBC]: Include <shlib-compat.h>.
18246         (_obstack) [defined _LIBC]: Remove after 2.3.4.
18247
18248         * lib/settime.c (settime): Recode to avoid warning with
18249         Sun Forte C 6U2.
18250
18251         * lib/strverscmp.c: Convert to UTF-8.
18252
18253 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18254
18255         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
18256         m4/uintmax_t.m4.
18257
18258 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18259
18260         * modules/xalloc-die: New file.
18261         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
18262
18263         * modules/md5 (Files): Add m4/uint32_t.m4.
18264         * modules/sha1: Renamed from modules/sha.
18265         (Files):
18266         Rename lib/sha.h to lib/sha1.h.
18267         Rename lib/sha.c to lib/sha1.c.
18268         Rename m4/sha.m4 to m4/sha1.m4.
18269         (lib_SOURCES): Likewise.
18270         (configure.ac): Rename gl_SHA to gl_SHA1.
18271         (Include): sha.h -> sha1.h.
18272
18273 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18274
18275         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
18276         * m4/sha1.m4: Renamed from sha.m4.
18277         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
18278
18279 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18280
18281         * lib/obstack.h (obstack_empty_p):
18282         Don't assume that chunk->contents is suitably aligned.
18283         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
18284         Likewise. Problem reported by Benno in
18285         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
18286
18287         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
18288         readable.  This could be improved further but it'd take some work.
18289
18290 2004-08-08  Simon Josefsson  <jas@extundo.com>
18291
18292         * modules/xgethostname (Depends-on): Remove exit and error (not
18293         used).
18294
18295         * modules/getpass-gnu: Add getpass.h.
18296         (Depends-on): Add stdbool.
18297         * modules/getpass: Add getpass.h.
18298
18299 2004-08-08  Simon Josefsson  <jas@extundo.com>
18300
18301         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
18302         Check getpass declaration.
18303
18304 2004-08-08  Simon Josefsson  <jas@extundo.com>
18305
18306         * lib/xgethostname.c: Don't include error.h (not used).
18307
18308         * lib/getpass.h: Add.
18309         * lib/getpass.c: Include getpass.h first.
18310
18311 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
18312
18313         * lib/xalloc-die.c: New file.
18314         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
18315         All uses removed.
18316         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
18317         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
18318         xalloc-die.c.
18319         (_, N_, xalloc_die): Move to xalloc-die.c.
18320         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
18321         so that we needn't mess with xalloc_msg_memory_exhausted.
18322
18323         * lib/sha1.h: Renamed from sha.h.
18324         (SHA1_H): Renamed from _SHA_H.
18325         (sha1_ctx): Renamed from sha_ctx.
18326         (sha1_init_ctx): Renamed from sha_init_ctx.
18327         (sha1_process_block): Renamed from sha_process_block.
18328         (sha1_process_bytes): Renamed from sha_process_bytes.
18329         (sha1_finish_ctx): Renamed from sha_finish_ctx.
18330         (sha1_read_ctx): Renamed from sha_read_ctx.
18331         (sha1_stream): Renamed from sha_stream.
18332         (sha1_buffer): Renamed from sha_buffer.
18333         * lib/sha1.c: Likewise; renamed from sha.c.
18334         Do not include <sys/types.h>.
18335         Include <stddef.h> rather than <stdlib.h>.
18336
18337 2004-08-08  Bruno Haible  <bruno@clisp.org>
18338
18339         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
18340         FILESYSTEM_PREFIX_LEN.
18341         * lib/progreloc.c: Likewise.
18342         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
18343
18344 2004-08-06  Simon Josefsson  <jas@extundo.com>
18345
18346         * modules/progname (Depends-on): Don't depend on stdbool.
18347
18348 2004-08-06  Simon Josefsson  <jas@extundo.com>
18349
18350         * modules/getsubopt: New file.
18351         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18352         getsubopt.
18353
18354 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18355
18356         More merge from coreutils.
18357
18358         * m4/utimens.m4, m4/utimecmp.m4: New files.
18359         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
18360         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
18361         prereq.m4, sha.m4: Import changes from coreutils.
18362
18363 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18364
18365         More merge from coreutils.
18366         * modules/raise, modules/readtokens0, modules/utimens:
18367         * modules/utimecmp, module/xnanosleep: New files.
18368         * modules/strftime: Add lib/strftime.h.
18369         Change include from <time.h> to "strftime.h".
18370         * modules/yesno: Add lib/yesno.h.
18371         * modules/backupfile: Remove lib/addext.c.
18372         * modules/euidaccess: Add stat-macros.h.
18373         * modules/canonicalize, modules/euidaccess,
18374         modules/filemode, modules/lchown, modules/makepath,
18375         modules/rmdir, modules/stat: Likewise.
18376
18377 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18378
18379         Merge from tar.
18380         * lib/argp-help.c (make_hol, hol_append): Don't assume that
18381         SIZE_MAX is a valid preprocessor constant.
18382         (__argp_basename): Change from "#ifndef _LIBC"
18383         to "#ifndef __argp_short_program_name", so that
18384         we don't compile these functions for tar.
18385
18386         More merges from coreutils.
18387         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
18388         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
18389         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
18390         * lib/addext.c: Remove; no longer needed.
18391         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
18392         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
18393         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
18394         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
18395         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
18396         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
18397         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
18398         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
18399         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
18400         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
18401         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
18402         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
18403         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
18404         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
18405         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
18406         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
18407         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
18408         Import changes from coreutils.
18409
18410 2004-08-05  Simon Josefsson  <jas@extundo.com>
18411
18412         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
18413
18414 2004-08-05  Simon Josefsson  <jas@extundo.com>
18415
18416         * m4/getsubopt.m4: New file.
18417
18418 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18419
18420         Merge from coreutils.
18421
18422         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
18423         * m4/getcwd-path-max.m4: New files.
18424
18425         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
18426         FILESYSTEM_PREFIX_LEN ->
18427         FILE_SYSTEM_PREFIX_LEN.
18428         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
18429         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
18430         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
18431         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
18432
18433         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
18434         prerequisite modules now handle the DOS stuff.
18435         Don't check for unistd.h.
18436
18437 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18438
18439         Merge from coreutils.
18440
18441         * lib/.gdb-history: Remove; this doesn't belong here.
18442
18443         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
18444         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
18445         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
18446         * lib/getcwd.c: New files.
18447
18448         * lib/dirname.h: Include <stdbool.h>.
18449         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
18450         for consistency with POSIX terminology.  All uses changed.
18451         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
18452         (strip_trailing_slashes): Use bool for booleans.
18453         * lib/stripslash.c (strip_trailing_slashes): Likewise.
18454
18455         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
18456         sometimes returns a positive errno value even when it succeeds.
18457         (print_errno_message) [!LIBC]: Fall back on strerror if
18458         __strerror_r fails.
18459
18460         * lib/path-concat.c (mempcpy): Don't define if a system header defines
18461         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
18462         (longest_relative_suffix): New function.
18463         (path_concat): Use it.  Assume first argument is not NULL.
18464         Port to DOS.  Omit redundant separators.
18465         Report an error instead of returning NULL.
18466         Use mempcpy instead of memcpy.
18467         (xpath_concat): Remove: not declared or used.
18468
18469         * lib/same.h: Include <stdbool.h>
18470         (same_name): Return bool, not int.
18471         * lib/same.c (same_name): Likewise.
18472         (errno): Don't declare; we assume C89 or better now.
18473
18474         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
18475         if not already defined.
18476
18477         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
18478         * lib/dup-safer.c (errno): Likewise.
18479
18480 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18481
18482         Merge from coreutils.
18483         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
18484         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
18485         * modules/path-concat: Don't depend on strdup.
18486
18487 2004-08-03  Simon Josefsson  <jas@extundo.com>
18488
18489         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
18490         * lib/progname.h: Don't include stdbool.h.
18491
18492 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18493
18494         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
18495         * MODULES.html.sh (func_all_modules): Remove fatal.
18496
18497 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18498
18499         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
18500
18501 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18502
18503         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
18504         working.
18505
18506 2004-08-02  Simon Josefsson  <jas@extundo.com>
18507
18508         * lib/getsubopt.h: New file, with comments from Bruno Haible.
18509         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
18510         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
18511
18512 2004-08-01  Simon Josefsson  <jas@extundo.com>
18513
18514         * lib/xgetdomainname.c: Include stdlib.h, for free().
18515
18516 2004-07-19  Bruno Haible  <bruno@clisp.org>
18517
18518         * MODULES.html.sh (func_all_modules): Add dummy.
18519
18520 2004-07-16  Simon Josefsson  <jas@extundo.com>
18521
18522         * modules/dummy: New file.
18523
18524 2004-07-16  Simon Josefsson  <jas@extundo.com>
18525
18526         * lib/dummy.c: New file.
18527
18528 2004-07-16  Bruno Haible  <bruno@clisp.org>
18529
18530         * lib/backupfile.h: Add extern "C" for C++.
18531         * lib/closeout.h: Likewise.
18532         * lib/copy-file.h: Likewise.
18533         * lib/findprog.h: Likewise.
18534         * lib/full-write.h: Likewise.
18535         * lib/pathname.h: Likewise.
18536         * lib/progname.h: Likewise.
18537         * lib/stpcpy.h: Likewise.
18538         * lib/stpncpy.h: Likewise.
18539         * lib/strcase.h: Likewise.
18540         * lib/strstr.h: Likewise.
18541         * lib/xalloc.h: Likewise.
18542
18543         * lib/mbswidth.h: Add extern "C" for C++.
18544         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
18545
18546 2004-07-13  Robert Millan  <robertmh@gnu.org>
18547
18548         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
18549
18550 2004-07-09  Simon Josefsson  <jas@extundo.com>
18551
18552         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
18553         failed without this.)
18554
18555 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
18556
18557         * modules/chown (Files): Add lib/fchown-stub.c, since
18558         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
18559
18560 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
18561
18562         * lib/fchown-stub.c: New file.
18563
18564 2004-06-24  Jim Meyering  <jim@meyering.net>
18565
18566         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
18567
18568 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18569
18570         * modules/argz: Omit "#include".
18571
18572         * MODULES.html.sh (func_all_modules): Add calloc, to match
18573         2004-06-01 addition of calloc module.
18574
18575 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18576
18577         * m4/argz.m4: New file, which is autoupdated from libtool.
18578
18579 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18580
18581         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
18582         libtool.
18583
18584 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18585
18586         * config/srclist-update: Don't insist on "USA." before the
18587         close-comment, as libtool omits the period and puts the */ on a
18588         separate line.
18589         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
18590         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
18591
18592 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
18593
18594         * modules/argz: New file.
18595         * MODULES.html.sh (func_all_modules): Add argz.
18596
18597 2004-06-12  Jim Meyering  <jim@meyering.net>
18598         and  Paul Eggert  <eggert@cs.ucla.edu>
18599
18600         * modules/hash (Files): Add lib/xalloc.h.
18601         * modules/pipe (Depends-on): Add wait-process.
18602         * modules/stat (Depends-on): Add xalloc.
18603         * modules/userspec (Files): Add lib/userspec.h.
18604         * modules/xstrto
18605
18606         Upgrade from gettext-0.13.
18607         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
18608         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
18609         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
18610
18611 2004-06-10  Jim Meyering  <jim@meyering.net>
18612
18613         * lib/calloc.c: New file.
18614
18615 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
18616
18617         * lib/getdate.y (yylex): Allow space between sign and number.
18618         Problem reported by Dan Jacobson.
18619
18620 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
18621
18622         Merge from coreutils CVS.
18623
18624         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
18625         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
18626         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
18627         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
18628         xstrtol.m4: Fix copyright date and/or serial number.
18629
18630         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
18631         See if we need an fchown replacement.
18632         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
18633         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
18634         and use the replacement function if we detect either defect.
18635
18636         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
18637         gl_UTIMECMP.
18638
18639 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
18640         and  Jim Meyering  <jim@meyering.net>
18641
18642         Merge from coreutils CVS.
18643
18644         * lib/stat-macros.h: New file, with contents from file-type.h
18645         and coreutils' system.h.
18646         * lib/file-type.c: Include "stat-macros.h".
18647         * lib/file-type.h (file_type): Move all macro definitions to new file,
18648         stat-macros.h.
18649
18650         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
18651         Wrap old code with this conditional.
18652         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
18653         function that does not dereference symlinks.
18654         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
18655
18656         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
18657         dependency problems.
18658         (xreadlink): Accept new arg SIZE, for efficiency.
18659         All decls and uses changed.
18660         * lib/xreadlink.h: Include <stddef.h>, for size_t.
18661
18662         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
18663         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
18664
18665         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
18666         sysexits.h.
18667
18668 2004-06-01  Jim Meyering  <jim@meyering.net>
18669
18670         * m4/calloc.m4: New file.
18671
18672 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
18673
18674         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
18675         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
18676         Also, fix a typo in a diagnostic.
18677
18678 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
18679
18680         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
18681         or AC_FUNC_REALLOC.
18682
18683 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
18684
18685         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
18686         macros to be defined.
18687         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
18688         the allocator returns NULL because the requested size is zero.
18689
18690 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
18691
18692         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
18693         var.  Add comment explaining why libc still defines it.  This
18694         merges the following patch from glibc:
18695         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
18696
18697 2004-05-20  Andreas Schwab  <schwab@suse.de>
18698
18699         * m4/free.m4: Replace free if it not known to work, not the other
18700         way round.
18701
18702 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
18703
18704         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
18705         present in glibc since revision 1.1 of this file.
18706         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
18707         obstack_alignment_mask, obstack_alloc, obstack_base,
18708         obstack_blank, obstack_blank_fast, obstack_chunk_size,
18709         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
18710         obstack_grow0, obstack_init, obstack_int_grow,
18711         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
18712         obstack_next_free, obstack_object_size, obstack_ptr_grow,
18713         obstack_ptr_grow_fast, obstack_room): Remove declarations of
18714         nonexistent functions.
18715
18716 2004-05-18  Karl Berry  <karl@gnu.org>
18717
18718         * config/srclist.txt: break link for vasnprintf.c.
18719
18720 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
18721
18722         Port obstack to the AS/400, where pointers are 16 bytes wide and
18723         you cannot cast an integer to a valid pointer.  This patch is
18724         currently waiting to be integrated into glibc; see
18725         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
18726
18727         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
18728         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
18729         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
18730         (struct obstack): temp member is now a union of a pointer and
18731         an integer, instead of an integer.  All integer uses changed.
18732         This does not affect the physical layout of struct obstack,
18733         except on hosts (like the AS/400) where the size or alignment of
18734         void * is greater than that of ptrdiff_t.
18735         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
18736         __STDC__)]: Store temporary in pointer member of union, not
18737         integer member.
18738         * lib/obstack.c: Include <stddef.h>, for offsetof.
18739         (struct fooalign): Remove; it doesn't need a name.
18740         (union fooround): Change double to long double, and add void *.
18741         (DEFAULT_ALIGNMENT): Use offsetof to compute.
18742         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
18743         not a macro.  Hence the values are always int; so remove all
18744         casts-to-int in uses.
18745
18746 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
18747
18748         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
18749         we can get this patch merged into glibc.
18750
18751 2004-05-17  Derek R. Price  <derek@ximbiot.com>
18752             Paul Eggert  <eggert@cs.ucla.edu>
18753
18754         * m4/argp: Depend on alloca.
18755
18756 2004-05-17  Derek R. Price  <derek@ximbiot.com>
18757             Paul Eggert  <eggert@cs.ucla.edu>
18758
18759         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
18760         freecoding.
18761
18762 2004-05-17  Bruno Haible  <bruno@clisp.org>
18763
18764         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
18765         precision that consists of a '.' followed by an empty digit string.
18766         Patch by Tor Lillqvist <tml@iki.fi>.
18767
18768 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
18769
18770         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
18771         for backward compatibility with older code.  We need our own
18772         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
18773         it under some other name, and our alloca.h will define it.
18774
18775 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
18776             Derek Price  <derek@ximbiot.com>
18777
18778         * lib/alloca.c: Include <alloca.h>, to get our interface.
18779         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
18780         include <alloca.h> first.  Use C89 prototype for alloca; this
18781         requires including <stddef.h> for size_t.  Use extern "C" if C++.
18782         Use #elif for simplicity, since we can assume C89 now.
18783         Don't try to source the system alloca.h since it will not be found
18784         and to prevent recursively including its replacement.
18785         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
18786         * lib/regex.c: Likewise.
18787
18788 2004-05-16  Derek Price  <derek@ximbiot.com>
18789             Paul Eggert  <eggert@cs.ucla.edu>
18790
18791         getline cleanup.  This changes the getndelim2 API: both order of
18792         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
18793         no delimiter).
18794
18795         * lib/getline.c: Don't include stddef.h or stdio.h, since our
18796         interface does that.
18797         (getline): Always use getdelim, so that we don't have two
18798         copies of this code.
18799         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
18800         if available.
18801         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
18802         (GETNDELIM2_MAXIMUM): New macro.
18803         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
18804         instead of the old practice of delim2==0.  All callers changed.
18805         Return -1 on overflow, instead of returning junk.
18806         Do not set *linesize unless allocation succeeds.
18807         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
18808         that we include sys/types.h.
18809         * lib/getnline.h: Likewise.
18810         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
18811         (getndelim2): Reorder arguments.
18812         * lib/getnline.c (getnline, getndelim):
18813         Don't discard the NMAX argument.
18814         (getnline): Invoke getndelim, to avoid code duplication.
18815         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
18816         of (size_t) -1 by callers of the getnline family.
18817
18818 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
18819
18820         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
18821         Check for gettimeofday.
18822         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
18823         Check for settimeofday, stime.
18824
18825 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
18826
18827         * lib/nanosleep.c (suspended): Change its type from int to
18828         sig_atomic_t volatile.
18829         (first_call): Make it private to rpl_nanosleep, and have it
18830         be zero initially as that's a bit faster.
18831         (my_usleep): Round up fractional times instead of truncating them,
18832         as this is the usual meaning for 'sleep'.
18833
18834         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
18835         doesn't work.
18836         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
18837         (ENOSYS): Define if not defined.
18838         (settime): Fall back on stime if it exists and settimeofday fails.
18839         But don't bother with fallbacks if a method fails with errno == EPERM.
18840
18841 2004-05-11  Jim Meyering  <jim@meyering.net>
18842
18843         Prior to this change, the save_cwd caller required read access to the
18844         current directory on most systems (ones with the fchdir function).
18845
18846         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
18847         fails, try write-only, and finally, resort to using xgetcwd.
18848
18849 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
18850
18851         * lib/obstack.c, obstack.h: Import changes from libc.
18852
18853 2004-04-28  Bruno Haible  <bruno@clisp.org>
18854
18855         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
18856         also implicitly appends .exe to executables.
18857         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
18858         accepts Windows pathnames.
18859         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
18860         Treat Cygwin like Windows, since it now accepts Windows pathnames.
18861         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
18862         Treat Cygwin like Windows, since it now accepts Windows pathnames.
18863         Reported by Derek Robert Price <derek@ximbiot.com>.
18864
18865 2004-04-21  Karl Berry  <karl@gnu.org>
18866
18867         * config/srclist.txt (localcharset.c): break sync.
18868
18869 2004-04-20  Paul Eggert  <eggert@twinsun.com>
18870
18871         * m4/host-os.m4: Add a copyright notice.
18872
18873 2004-04-20  Jim Meyering  <jim@meyering.net>
18874
18875         Change UTILS_ to gl_ in AC_DEFINE'd names.
18876         Change utils_- and jm_-prefixed variables, too.
18877         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
18878         UTILS_FUNC_MKDIR_TRAILING_SLASH.
18879         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
18880
18881         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
18882         Don't emit trailing blanks.
18883         Also rename jm_-prefixed variables to have gl_ prefix.
18884
18885         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
18886         Also rename jm_-prefixed variables to have gl_ prefix.
18887
18888         * m4/jm-macros.m4: Reflect the renamings.
18889         * m4/prereq.m4: Likewise.
18890
18891 2004-04-20  Jim Meyering  <jim@meyering.net>
18892
18893         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
18894         memory.
18895
18896 2004-04-20  Jim Meyering  <jim@meyering.net>
18897             Bruno Haible  <bruno@clisp.org>
18898
18899         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
18900         memory when realloc fails.
18901
18902 2004-04-19  Jim Meyering  <jim@meyering.net>
18903
18904         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
18905         now that readutmp.c may call `free (0)'.
18906
18907 2004-04-19  Bruno Haible  <bruno@clisp.org>
18908
18909         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
18910         * m4/inttypes_h.m4: Likewise.
18911         * m4/stdint_h.m4: Likewise.
18912         * m4/intmax_t.m4: Likewise.
18913         * m4/uintmax_t.m4: Likewise.
18914
18915 2004-04-18  Jim Meyering  <jim@meyering.net>
18916
18917         * m4/prereq.m4: Don't forbid jm_ prefix.
18918
18919         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
18920         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
18921         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
18922         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
18923         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
18924         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
18925         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
18926         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
18927         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
18928         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
18929         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
18930         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
18931         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
18932         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
18933         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
18934         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
18935         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
18936         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
18937         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
18938
18939 2004-04-18  Jim Meyering  <jim@meyering.net>
18940
18941         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
18942         failure, don't leak memory and do call END_UTMP_ENT.
18943
18944 2004-04-16  Jim Meyering  <jim@meyering.net>
18945
18946         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
18947         coreutils' stat program.
18948         (gl_PREREQ): Don't require jm_PREREQ_STAT.
18949
18950 2004-04-11  Paul Eggert  <eggert@twinsun.com>
18951
18952         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
18953         C89.
18954         (CHAR_BIT): Remove, since we assume C89.
18955         Include <stdint.h> if available, as per current Autoconf CVS advice.
18956
18957 2004-03-31  Jim Meyering  <jim@meyering.net>
18958
18959         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
18960         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
18961         * m4/xalloc.m4: Likewise.
18962
18963 2004-03-30  Paul Eggert  <eggert@twinsun.com>
18964
18965         Merge from coreutils.
18966
18967         * m4/inttostr.m4: New file.
18968         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
18969         Require AM_STDBOOL_H and gl_TIMESPEC instead.
18970         Require gl_CLOCK_TIME.
18971         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
18972
18973 2004-03-30  Paul Eggert  <eggert@twinsun.com>
18974
18975         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
18976         not bool, to be more consistent with Unix conventions.
18977         Suggested by Bruno Haible.
18978
18979         Merge from coreutils.
18980
18981         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
18982         * lib/umaxtostr.c: New files.
18983
18984         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
18985         the usual <time.h> dance.
18986         (get_date): Change signature to support fractional time stamps.
18987         All callers changed.
18988         * lib/getdate.y: Include "getdate.h" first, as we can now
18989         assume C89 and don't need to worry about 'const'.
18990         Similarly, include "unlocked-io.h" near start, not in middle.
18991         Include <limits.h>.
18992         (textint.value): Use long int rather than int.
18993         (textint.digits): Use size_t rather than int.
18994         (BILLION, LOG10_BILLION): New constants.
18995         (parser_control): New member rel_ns.  Members day_ordinal,
18996         time_zone, month, day, hour, minutes, rel_year, rel_month,
18997         rel_day, rel_hour, rel_minutes, rel_seconds
18998         are now long int, not int.  Member seconds is now struct timespec,
18999         not int.  New member timespec_seen.  Members dates_seen, days_seen,
19000         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
19001         not int.
19002         (%union.intval): Now long int, not int.
19003         New member timespec.
19004         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
19005         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
19006         (spec): Now is a timespec or an item list.
19007         (timespec, items): New nonterminals.
19008         (time, rel, relunit, number, get_date):
19009         Add support for fractional seconds.
19010         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
19011         (gmtime, localtime, mktime): Remove decls; not needed with C89.
19012         (to_hour): First arg is now long int, not int.
19013         (to_year): Returns long int, not int.
19014         Don't treat year -70 like 70.
19015         (tm_diff): Returns long int, not int.
19016         (lookup_word): Use bool instead of int when appropriate.
19017         (yylex): Use size_t for count, not int.
19018         Detect overflow when parsing large integer constants.
19019         Add support for fractions.
19020         (get_date): Make pointers 'const' if possible.
19021         Use more-portable code to detect integer overflow.
19022         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
19023         Don't use ctime; it's not reliable if the year has >4 digits.
19024
19025         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
19026         This is for compatibility with BSD.
19027
19028         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
19029         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
19030         From coreutils' system.h.
19031
19032         * lib/userspec.c: Don't include "posixver.h".
19033         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
19034         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
19035         compatible extension.  Simplify code by removing a boolean int
19036         that was always nonzero if a string was nonnull.
19037
19038 2004-03-30  Jim Meyering  <jim@meyering.net>
19039
19040         Merge from coreutils.
19041
19042         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
19043         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
19044         on some systems one must include <grp.h> before it.
19045         Reported by Christian Krackowizer.
19046
19047 2004-03-30  Jim Meyering  <jim@meyering.net>
19048
19049         Merge from coreutils.
19050
19051         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
19052
19053         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
19054         an empty input stream.
19055
19056         * lib/readtokens.c: Include <stdbool.h>.
19057         (readtoken): Use `size_t' rather than int/long.
19058         All callers adjusted.
19059         Use `bool' rather than `int' where appropriate.
19060         Use memset rather than an explicit loop.
19061         Use x2nrealloc rather than xrealloc.
19062         Allow the use of `\0' as a delimiter.
19063         (readtokens): Likewise.
19064         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
19065
19066 2004-03-30  Jim Meyering  <jim@meyering.net>
19067
19068         * m4/realloc.m4: Remove file, since now it does no more than
19069         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
19070         the `configure.ac' section of module/realloc.
19071         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
19072
19073 2004-03-30  Bruno Haible  <bruno@clisp.org>
19074
19075         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
19076         nonnull.
19077
19078 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19079
19080         Merge changes to getloadavg.c from coreutils and Emacs.
19081
19082         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
19083         Define to an expression, not to the empty string.
19084         Include cloexec.h and xalloc.h.
19085         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
19086         Use set_cloexec_flag rather than rolling our own.
19087         * lib/cloexec.c, lib/cloexec.h: New files.
19088
19089 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19090
19091         * m4/cloexec.m4: New file.
19092
19093 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19094
19095         * lib/getopt.h: Sync with libc CVS.
19096
19097 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19098             Bruno Haible  <bruno@clisp.org>
19099
19100         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
19101         mbswidth.
19102
19103 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19104             Bruno Haible  <bruno@clisp.org>
19105
19106         * lib/mbswidth.h: Include <wchar.h> only if
19107         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
19108         <wchar.h>.
19109         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
19110
19111 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19112
19113         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
19114         Sync with libc CVS.
19115         * lib/getopt_int.h: New file, also synced from libc.
19116
19117 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19118
19119         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
19120         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
19121         Bring back getopt.c, getopt.h, getopt1.c.
19122
19123 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19124
19125         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
19126         All uses changed.  Check for sa_sigaction member; this fixes
19127         a bug first reported by Jason Andrade in
19128         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19129
19130 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19131
19132         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
19133         '#if' expressions.  Unlike the code it replaces, it does not
19134         depend on (defined _SC_PAGESIZE).  However, it does depend on
19135         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
19136         first reported by Jason Andrade in
19137         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19138
19139 2004-02-25  Simon Josefsson  <jas@extundo.com>
19140
19141         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
19142
19143 2004-02-25  Simon Josefsson  <jas@extundo.com>
19144
19145         * lib/strdup.h: New file.
19146         * lib/strdup.c: Include it.
19147         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
19148         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
19149
19150 2004-02-23  Karl Berry  <karl@gnu.org>
19151
19152         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
19153         (from fencepost.gnu.org:/gd/gnuorg).
19154
19155 2004-02-23  Karl Berry  <karl@gnu.org>
19156
19157         * config/srclistvars.sh (GNUORG) [karl]: redefine.
19158         * config/srclist.txt: add maintain/standards documents.
19159
19160 2004-02-18  Bruno Haible  <bruno@clisp.org>
19161
19162         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
19163         Reported by Derek Robert Price <derek@ximbiot.com>.
19164
19165 2004-02-16  Karl Berry  <karl@gnu.org>
19166
19167         * config/mkinstalldirs, install-sh: update from automake.
19168
19169 2004-02-06  Karl Berry  <karl@gnu.org>
19170
19171         * m4/po.m4: update from gettext 0.14.1.
19172
19173 2004-02-06  Karl Berry  <karl@gnu.org>
19174
19175         * lib/config.charset: update from gettext 0.14.1.
19176
19177 2004-02-05  Paul Eggert  <eggert@twinsun.com>
19178
19179         Add comments and code, prompted by suggestions from Bruno Haible
19180         for sh-quote.
19181         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
19182         describing the enum quoting_style values.
19183         * lib/quotearg.c (quotearg_alloc): New function.
19184         (quotearg_buffer_restyled): Treat lone { and } as special.
19185         Treat = as special.  Work around bug with older shells
19186         that "see" a '\' that is really the 2nd byte of a multibyte char.
19187         Quote empty string with shell_quoting_style.
19188
19189 2004-02-03  Bruno Haible  <bruno@clisp.org>
19190
19191         * m4/pipe.m4: New file, from GNU gettext.
19192
19193 2004-02-03  Bruno Haible  <bruno@clisp.org>
19194
19195         * lib/pipe.h: New file, from GNU gettext.
19196         * lib/pipe.c: New file, from GNU gettext.
19197
19198 2004-01-27  Bruno Haible  <bruno@clisp.org>
19199
19200         * m4/execute.m4: New file, from GNU gettext.
19201
19202 2004-01-27  Bruno Haible  <bruno@clisp.org>
19203
19204         * lib/execute.h: New file, from GNU gettext.
19205         * lib/execute.c: New file, from GNU gettext.
19206         * lib/w32spawn.h: New file, from GNU gettext.
19207
19208 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19209
19210         Merge from diffutils.
19211
19212         * lib/file-type.c (file_type): Add typed memory objects.
19213         * lib/file-type.h (S_TYPEISTMO): New macro.
19214
19215         * lib/c-stack.h (c_stack_action): Remove argv argument.
19216         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
19217         (die): Don't calculate message unless segv_action returns.
19218         (get_stack_location, min_address_from_argv, max_address_from_argv,
19219         volatile stack_base, volatile_stack_size): Remove.
19220         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
19221         that every segmentation violation is a stack overflow.  (Ouch!)
19222         See Debian bug 136249 (still outstanding) for more info about why
19223         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
19224
19225 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19226
19227         Exit-status fix from coreutils.
19228
19229         Use exit_failure consistently in place of EXIT_FAILURE,
19230         so that program exit statuses are consistent on failure.
19231
19232         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
19233         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
19234         * lib/argmatch.h: Comment fix to match the above.
19235         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
19236         Now a macro referring to exit_failure, instead of a separate
19237         variable.  Include "exitfail.h" to get it.
19238         * lib/xstrtol.h: Include "exitfail.h".
19239         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
19240
19241         * lib/long-options.c (parse_long_options): Use prototype
19242         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
19243         for clarity.
19244
19245 2004-01-21  Jim Meyering  <jim@meyering.net>
19246
19247         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
19248         so as not to conflict with a different-sized __mktime_internal
19249         function in GNU libc.
19250         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
19251         Problem building statically-linked `ls' reported by Michael Brunnbauer.
19252
19253 2004-01-20  Karl Berry  <karl@gnu.org>
19254
19255         * config/config.guess: update from config.
19256
19257         * config/srclistvars.sh: GNUWWWLICENSES for karl.
19258
19259 2004-01-20  Bruno Haible  <bruno@clisp.org>
19260
19261         Safer stack allocation.
19262         * lib/setenv.c: Include allocsa.h.
19263         (alloca): Remove fallback definition.
19264         (freea): Remove macro.
19265         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
19266         instead of freea.
19267
19268 2004-01-20  Bruno Haible  <bruno@clisp.org>
19269
19270         * m4/eealloc.m4: New file, from GNU gettext.
19271
19272 2004-01-20  Bruno Haible  <bruno@clisp.org>
19273
19274         * m4/allocsa.m4: New file, from GNU gettext.
19275
19276 2004-01-20  Bruno Haible  <bruno@clisp.org>
19277
19278         * lib/xallocsa.h: New file, from GNU gettext.
19279         * lib/xallocsa.c: New file, from GNU gettext.
19280
19281 2004-01-20  Bruno Haible  <bruno@clisp.org>
19282
19283         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
19284
19285 2004-01-20  Bruno Haible  <bruno@clisp.org>
19286
19287         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
19288         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
19289         specially.
19290
19291 2004-01-20  Bruno Haible  <bruno@clisp.org>
19292
19293         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
19294         patch.
19295
19296 2004-01-20  Bruno Haible  <bruno@clisp.org>
19297
19298         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
19299
19300 2004-01-20  Bruno Haible  <bruno@clisp.org>
19301
19302         * lib/eealloc.h: New file.
19303
19304 2004-01-20  Bruno Haible  <bruno@clisp.org>
19305
19306         * lib/binary-io.h: Avoid warnings on Cygwin.
19307
19308 2004-01-20  Bruno Haible  <bruno@clisp.org>
19309
19310         * lib/allocsa.h: New file, from GNU gettext.
19311         * lib/allocsa.c: New file, from GNU gettext.
19312
19313 2004-01-18  Karl Berry  <karl@gnu.org>
19314
19315         * doc/gpl.texi, doc/lgpl.texi: new files.
19316
19317 2004-01-18  Karl Berry  <karl@gnu.org>
19318
19319         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
19320         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
19321
19322 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19323
19324         Merge from coreutils.
19325
19326         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
19327         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
19328         (gl_DEFAULT_POSIX2_VERSION): Move
19329         the documentation from 'configure' into 'config.hin',
19330         so that 'configure --help' isn't burdened by it and
19331         we don't have to worry about its formatting there.
19332         Reword the documentation so that it's more succinct
19333         and can be run together into a single paragraph.
19334         * m4/same.m4 (gl_SAME): Check for pathconf.
19335
19336 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19337
19338         Merge from coreutils.
19339
19340         * lib/posixver.c: Include posixver.h.
19341
19342         * lib/same.c: Include <stdbool.h>, <limits.h>.
19343         (_POSIX_NAME_MAX): Define if not defined.
19344         (MIN): New macro.
19345         (same_name): If file names are silently truncated, report
19346         that the file names are the same if they are the same after
19347         the silent truncation.
19348
19349         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
19350         conversion function.
19351         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
19352         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
19353         longer needed.
19354
19355 2004-01-15  Jim Meyering  <jim@meyering.net>
19356
19357         Merge from coreutils.
19358
19359         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
19360         if no library is required.
19361         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
19362         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
19363         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
19364         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
19365         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
19366         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
19367         value, $ac_cv_search_crypt, if it's "none required".
19368         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
19369         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
19370         not gl_FUNC_GETLOADAVG.
19371         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
19372         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
19373
19374 2004-01-15  Jim Meyering  <jim@meyering.net>
19375
19376         Merge from coreutils.
19377
19378         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
19379         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
19380         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
19381
19382         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
19383         optional configure-time default.
19384
19385         * lib/version-etc.c (version_etc_copyright): Update copyright date.
19386
19387         * lib/xreadlink.c (xreadlink): Correct outdated comment.
19388
19389 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
19390
19391         Merge from coreutils.
19392
19393         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
19394         value, $ac_cv_search_nanosleep, if it's "none required".
19395
19396 2004-01-14  Paul Eggert  <eggert@twinsun.com>
19397
19398         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
19399         with like-named macro in fnmatch.c.
19400         (EXT): Use an internal constant instead.
19401
19402         Merge fnmatch patches from glibc.
19403         * lib/fnmatch.c (mbsinit): Remove define.
19404         Add libc_hidden_ver (__fnmatch, fnmatch).
19405         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
19406         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
19407
19408 2004-01-14  Karl Berry  <karl@gnu.org>
19409
19410         * config/install-sh: update from automake.
19411
19412 2004-01-13  Karl Berry  <karl@gnu.org>
19413
19414         * config/install-sh: update from automake.
19415
19416 2004-01-09  Karl Berry  <karl@gnu.org>
19417
19418         * config/install-sh: update from automake.
19419
19420 2004-01-05  Karl Berry  <karl@gnu.org>
19421
19422         * config/config.{sub,guess}: update from config.
19423
19424 2003-12-31  Karl Berry  <karl@gnu.org>
19425
19426         * config/depcomp: update from automake.
19427
19428 2003-12-14  Karl Berry  <karl@gnu.org>
19429
19430         * lib/config.charset: update from gettext-runtime.
19431
19432 2003-12-03  Paul Eggert  <eggert@twinsun.com>
19433
19434         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
19435         Bug reported by Alfred M. Szmidt.
19436
19437 2003-12-03  Bruno Haible  <bruno@clisp.org>
19438
19439         * m4/gettext.m4: Upgrade from gettext-0.13.
19440         * m4/po.m4: Upgrade from gettext-0.13.
19441         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
19442         * m4/intmax.m4: New file, from gettext-0.13.
19443         * m4/printf-posix.m4: New file, from gettext-0.13.
19444
19445 2003-11-29  Karl Berry  <karl@gnu.org>
19446
19447         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
19448
19449 2003-11-25  Paul Eggert  <eggert@twinsun.com>
19450             Bruno Haible  <bruno@clisp.org>
19451
19452         * lib/printf-parse.h: Don't include sys/types.h.
19453         (ARG_NONE): New macro.
19454         (char_directive): Change type of *arg_index fields to size_t.
19455         * lib/printf-parse.c: Don't include sys/types.h.
19456         (SSIZE_MAX): Remove macro.
19457         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
19458         Remove unnecessary overflow check.
19459         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
19460         fields.
19461
19462 2003-11-25  Bruno Haible  <bruno@clisp.org>
19463
19464         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
19465
19466 2003-11-25  Bruno Haible  <bruno@clisp.org>
19467
19468         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
19469         gt_TYPE_SSIZE_T.
19470
19471 2003-11-24  Paul Eggert  <eggert@twinsun.com>
19472
19473         * modules/alloca: Remove dependency on xalloc.
19474
19475 2003-11-24  Paul Eggert  <eggert@twinsun.com>
19476
19477         * lib/alloca.c: Remove dependency on xalloc module.
19478         (xalloc_die): Remove.
19479         (memory_full) [!defined emacs]: New macro.
19480         [!defined emacs]: Don't include xalloc.h.
19481         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
19482         address arithmetic overflows.  Change datatypes a bit to avoid
19483         unnecessary casts.
19484
19485 2003-11-22  Jim Meyering  <jim@meyering.net>
19486
19487         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
19488         s/size/size_t/.
19489
19490 2003-11-21  Karl Berry  <karl@gnu.org>
19491
19492         * config/config.{sub,guess}: update from config.
19493
19494 2003-11-18  Karl Berry  <karl@gnu.org>
19495
19496         * config/config.{sub,guess}: update from config.
19497
19498         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
19499
19500 2003-11-17  Paul Eggert  <eggert@twinsun.com>
19501
19502         * README: Mention that S+T cannot overflow if S is the size of
19503         an existing object and T is sufficiently small.
19504
19505 2003-11-17  Jim Meyering  <jim@meyering.net>
19506
19507         On systems without utime and without a utimes function capable of
19508         dealing with a NULL struct utimbuf* argument, this utime replacement
19509         could -- in unusual circumstances -- leak a file descriptor.
19510         * lib/utime.c: Include <unistd.h> and <errno.h>.
19511         (utime_null): Be sure to close `fd' and to preserve errno.
19512         Reported by Geoff Collyer via Arnold Robbins.
19513
19514 2003-11-17  Bruno Haible  <bruno@clisp.org>
19515
19516         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
19517         (Depends-on): Add xsize.
19518
19519 2003-11-17  Bruno Haible  <bruno@clisp.org>
19520
19521         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
19522
19523 2003-11-17  Bruno Haible  <bruno@clisp.org>
19524
19525         * lib/vasnprintf.c (alloca): Remove fallback definition.
19526         (freea): Remove definition.
19527         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
19528         Reported by Paul Eggert.
19529
19530 2003-11-16  Paul Eggert  <eggert@twinsun.com>
19531             Bruno Haible  <bruno@clisp.org>
19532
19533         Protect against address arithmetic overflow.
19534         * lib/printf-args.h: Include stddef.h.
19535         (arguments): Change type of field 'count' to size_t.
19536         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
19537         'unsigned int' where appropriate.
19538         * lib/printf-parse.h: Include sys/types.h.
19539         (char_directive): Change type of *arg_index fields to ssize_t.
19540         (char_directives): Change type of fields 'count', max_*_length to
19541         size_t.
19542         * lib/printf-parse.c: Include sys/types.h and xsize.h.
19543         (SSIZE_MAX): Define fallback value.
19544         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
19545         instead of 'int' where appropriate. Check a_allocated, d_allocated
19546         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
19547         * lib/vasnprintf.c: Include xsize.h.
19548         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
19549         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
19550         overflow. Avoid wraparound when converting a width or precision from
19551         decimal to binary.
19552
19553 2003-11-16  Bruno Haible  <bruno@clisp.org>
19554
19555         Update from GNU gettext.
19556         * lib/printf-parse.c: Generalize to it can be compiled for wide
19557         strings.
19558         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
19559         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
19560         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
19561         SNPRINTF): New macros.
19562         Don't include <alloca.h> if the file is used inside libintl.
19563         (local_wcslen): New function, for Solaris 2.5.1.
19564         (VASNPRINTF): Use it instead of wcslen.
19565
19566 2003-11-16  Bruno Haible  <bruno@clisp.org>
19567
19568         * lib/xsize.h (xmax): New function.
19569         (xsum, xsum3, xsum4): Declare as "pure" functions.
19570
19571 2003-11-12  Paul Eggert  <eggert@twinsun.com>
19572
19573         * modules/xalloc (Files): Undo latest change, since xalloc.h
19574         no longer needs SIZE_MAX or PTRDIFF_MAX.
19575
19576 2003-11-12  Paul Eggert  <eggert@twinsun.com>
19577
19578         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
19579         gl_PTRDIFF_MAX.
19580
19581 2003-11-12  Paul Eggert  <eggert@twinsun.com>
19582
19583         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
19584         "return", to pacify some unknown compiler.  Problem reported
19585         by Joerg Schilling.
19586
19587 2003-11-12  Paul Eggert  <eggert@twinsun.com>
19588
19589         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
19590         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
19591         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
19592         heuristic is just as accurate as far as we know, and it removes a
19593         dependency on size_max.m4 and ptrdiff_max.m4.
19594
19595 2003-11-11  Bruno Haible  <bruno@clisp.org>
19596
19597         * modules/xsize (Files): Add m4/size_max.m4.
19598         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
19599
19600 2003-11-11  Bruno Haible  <bruno@clisp.org>
19601
19602         * m4/size_max.m4: New file.
19603         * m4/ptrdiff_max.m4: New file.
19604         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
19605         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
19606         (gl_XALLOC): Invoke it.
19607
19608 2003-11-11  Bruno Haible  <bruno@clisp.org>
19609
19610         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
19611         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
19612         defined.
19613
19614 2003-11-10  Paul Eggert  <eggert@twinsun.com>
19615
19616         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
19617         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
19618         rejected some allocations of exactly SIZE_MAX - 2 bytes.
19619         From Bruno Haible.
19620         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
19621         not (size_t) -1, since it's defined here.
19622
19623 2003-11-09  Karl Berry  <karl@gnu.org>
19624
19625         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
19626
19627 2003-11-06  Paul Eggert  <eggert@twinsun.com>
19628
19629         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
19630         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
19631         Reject sizes of exactly SIZE_MAX bytes.
19632         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
19633         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
19634
19635 2003-11-05  Bruno Haible  <bruno@clisp.org>
19636
19637         * lib/xsize.h: Include limits.h, to avoid a possible collision with
19638         SIZE_MAX defined in <limits.h> on Solaris.
19639
19640 2003-11-04  Jim Meyering  <jim@meyering.net>
19641
19642         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
19643         variable names, rather than @VAR@.
19644         * modules/poll: Likewise.
19645
19646 2003-11-04  Bruno Haible  <bruno@clisp.org>
19647
19648         * modules/xsize: New file.
19649         * modules/linebreak: Depend on xsize.
19650         * MODULES.html.sh (func_all_modules): Add xsize.
19651
19652 2003-11-04  Bruno Haible  <bruno@clisp.org>
19653
19654         * m4/xsize.m4: New file.
19655
19656 2003-11-04  Bruno Haible  <bruno@clisp.org>
19657
19658         * lib/xsize.h: New file.
19659         * lib/linebreak.c: Include xsize.h.
19660         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
19661         argument for overflow.
19662         Suggested by Paul Eggert.
19663
19664 2003-11-03  Karl Berry  <karl@gnu.org>
19665
19666         * config/config.{guess,sub}: update from config.
19667
19668 2003-11-03  Jim Meyering  <jim@meyering.net>
19669
19670         * modules/userspec (lib_SOURCES): Add userspec.h.
19671         (Include): Add "userspec.h".
19672         Improve description.
19673
19674 2003-11-03  Jim Meyering  <jim@meyering.net>
19675
19676         * lib/userspec.c: Include "userspec.h".
19677         * lib/userspec.h: New file.
19678
19679 2003-11-03  Bruno Haible  <bruno@clisp.org>
19680
19681         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
19682
19683 2003-11-03  Bruno Haible  <bruno@clisp.org>
19684
19685         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
19686         available, to avoid (extremely rare) race condition.
19687         Suggested by Paul Eggert.
19688
19689 2003-11-02  Karl Berry  <karl@gnu.org>
19690
19691         * config/srclist.txt (vasprintf.c): sync broken, sigh.
19692
19693 2003-10-31  Paul Eggert  <eggert@twinsun.com>
19694
19695         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
19696         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
19697         (read_filesystem_list): Set and use me_type_malloced.
19698         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
19699         whatever the type happens to be), for brevity and consistency.
19700         Check for size calculation overflow on Alphas running OSF/1.
19701
19702 2003-10-31  Jim Meyering  <jim@meyering.net>
19703
19704         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
19705
19706         * lib/linebuffer.c: Include <string.h> for declaration of memset.
19707
19708 2003-10-30  Paul Eggert  <eggert@twinsun.com>
19709             Bruno Haible  <bruno@clisp.org>
19710
19711         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
19712         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
19713
19714 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
19715
19716         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
19717         netbsd*-gnu*.  Suggested by Robert Millan.
19718
19719 2003-10-29  Paul Eggert  <eggert@twinsun.com>
19720
19721         * modules/group-member: Depend on stdbool.
19722
19723 2003-10-29  Paul Eggert  <eggert@twinsun.com>
19724
19725         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
19726
19727 2003-10-29  Paul Eggert  <eggert@twinsun.com>
19728
19729         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
19730         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
19731         after the 'gnu' in these cases.  This fixes some bugs in the
19732         previous change, and is based on suggestions by Robert Millan.
19733
19734 2003-10-29  Paul Eggert  <eggert@twinsun.com>
19735
19736         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
19737         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
19738         no longer needed.
19739         * lib/quotearg.c (quotearg_n_options): Use it.
19740         * lib/group-member.c: Include <stdbool.h>.
19741         (free_group_info): Arg is now const *; don't free arg.
19742         (get_group_info): Now returns bool and accepts struct group_info *,
19743         rather than returning a malloc'ed struct group_info *.
19744         All uses changed.  Check for overflow in internal size calculation.
19745
19746         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
19747         rather than xmalloc/xrealloc.
19748         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
19749         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
19750         conformance bug: the old code used a pointer after freeing the
19751         storage that it addressed.
19752         * lib/hash.c (hash_initialize): Simplify the code by using
19753         xalloc_oversized rather than doing it by hand.
19754         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
19755         the buffer preserved.  Use free and xmalloc instead.
19756         * lib/quotearg.c (quotearg_n_options): Likewise.
19757         Use a simpler test for size overflow.  Don't use xalloc_oversized
19758         because unsigned int might be wider than size_t (!); this suggests
19759         that we should switch from unsigned int to size_t for slot numbers.
19760
19761 2003-10-28  Paul Eggert  <eggert@twinsun.com>
19762
19763         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
19764         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
19765         NetBSD kernels.  Requested by Richard Stallman.
19766
19767 2003-10-27  Paul Eggert  <eggert@twinsun.com>
19768
19769         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
19770         to allocate the returned structure.  Do not allocate a subarray,
19771         as x2nrealloc will do that.
19772         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
19773         instead of xnrealloc.
19774         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
19775
19776 2003-10-27  Bruno Haible  <bruno@clisp.org>
19777
19778         * lib/stdbool_.h: Better support for BeOS.
19779
19780 2003-10-26  Paul Eggert  <eggert@twinsun.com>
19781
19782         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
19783         now uses inline.
19784
19785 2003-10-26  Paul Eggert  <eggert@twinsun.com>
19786
19787         * lib/xalloc.h (xalloc_oversized): New static inline function, for
19788         callers that want to do their own size-overflow checking.  Include
19789         <stdbool.h>, since xalloc_oversized returns bool.
19790         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
19791         to use xalloc_oversized.
19792
19793         Add two functions x2realloc, x2nrealloc, for programs that grow
19794         arrays dynamically by doubling their sizes.
19795         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
19796         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
19797         New functions.
19798
19799         Port to C99 semantics for 'inline' of external functions.
19800         Bug reported by Bruno Haible.
19801         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
19802         with the old contents of xnmalloc.
19803         (xnmalloc, xmalloc): Use it.
19804         (xnrealloc_inline): New static inline function,
19805         with the old contents of xnrealloc.
19806         (xnrealloc, xrealloc): Use it.
19807
19808         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
19809         that.
19810
19811 2003-10-26  Karl Berry  <karl@gnu.org>
19812
19813         * config/srclist.txt (COPYING.DOC): no longer available from
19814         /gd/gnuorg; don't know where the ultimate source is.
19815
19816 2003-10-25  Paul Eggert  <eggert@twinsun.com>
19817
19818         Fix several address-calculation bugs in the hash modules,
19819         plus some minor code cleanup.
19820
19821         * lib/hash.h: Include <stdbool.h>, for bool.
19822         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
19823         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
19824         hash_get_n_entries, hash_get_max_bucket_length,
19825         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
19826         hash_rehash): Use size_t rather than unsigned.
19827         * lib/hash.c (struct hash_table, hash_get_n_buckets,
19828         hash_get_n_buckets_used, hash_get_n_entries,
19829         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
19830         hash_get_entries, hash_do_for_each, hash_string, is_prime,
19831         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
19832         Likewise.
19833         (SIZE_MAX): Define if not defined.
19834         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
19835         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
19836         hash_print):
19837         Use const * when possible.
19838         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
19839         (check_tuning): Fix bug: if tuning parameters were very close to
19840         0 or 1, rounding errors could have caused subscript violations.
19841         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
19842         (hash_initialize): Add 'fail:' label
19843         to free table and return NULL, and use it to simplify code.
19844         Use calloc rather than clearing the storage ourself.
19845         (hash_initialize, hash_rehash): Check for arithmetic overflow in
19846         buffer size calculations.
19847         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
19848         Include <stddef.h>, for size_t.
19849         * lib/hash-pjw.c (hash_pjw): Likewise.
19850         Switch to method described by Bruno Haible.
19851         Include <limits.h>, for CHAR_BIT.
19852         (SIZE_BITS): New macro.
19853
19854 2003-10-23  Paul Eggert  <eggert@twinsun.com>
19855
19856         * m4/getline.m4 (AM_FUNC_GETLINE):
19857         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
19858         hosts.  Problem reported by Derek Robert Price in
19859         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
19860         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
19861         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
19862
19863 2003-10-21  Paul Eggert  <eggert@twinsun.com>
19864
19865         * lib/getndelim2.c (getndelim2): When size calculation overflows,
19866         ceiling the allocation at NMAX bytes rather than silently
19867         discarding input bytes before NMAX is reached.  This makes
19868         a difference only if NMAX exceeds SIZE_MAX / 2.
19869
19870         * lib/obstack.c: Merge from glibc.
19871         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
19872         Add libc_hidden_def (_obstack_newchunk).
19873         (_obstack_free) [! defined _LIBC]: Remove.
19874         [defined _LIBC]: Make a strong alias from obstack_free, rather than
19875         a clone of the function body.
19876         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
19877         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
19878
19879         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
19880         glibc.
19881         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
19882         arg to memcpy.
19883
19884         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
19885         (obstack_ptr_grow_fast, obstack_int_grow_fast):
19886         Don't use lvalue casts, as GCC plans to remove support for them
19887         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
19888         was also present in the non-GCC version, indicating that this
19889         code had always been buggy and had never been widely used.
19890         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
19891         Use the fast variant of each macro, rather than copying the
19892         definiens of the fast variant; that way, we'll be more likely to
19893         catch future bugs in the fast variants.
19894
19895 2003-10-20  Bruno Haible  <bruno@clisp.org>
19896
19897         * modules/wait-process: New file.
19898         * MODULES.html.sh (func_all_modules): Add wait-process.
19899
19900 2003-10-20  Bruno Haible  <bruno@clisp.org>
19901
19902         * m4/wait-process.m4: New file.
19903
19904 2003-10-20  Bruno Haible  <bruno@clisp.org>
19905
19906         * lib/wait-process.h: New file, from GNU gettext.
19907         * lib/wait-process.c: New file, from GNU gettext.
19908
19909 2003-10-19  Jim Meyering  <jim@meyering.net>
19910
19911         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
19912         HPUX 10.20.
19913
19914 2003-10-18  Karl Berry  <karl@gnu.org>
19915
19916         * config/config.guess: update from config.
19917
19918 2003-10-16  Paul Eggert  <eggert@twinsun.com>
19919
19920         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
19921         (getgroups): First arg is int, not size_t.
19922         Don't let 'free' mangle errno.
19923
19924 2003-10-16  Paul Eggert  <eggert@twinsun.com>
19925
19926         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
19927
19928 2003-10-16  Karl Berry  <karl@gnu.org>
19929
19930         * config/config.{guess,sub}: update from config.
19931
19932 2003-10-16  Jim Meyering  <jim@meyering.net>
19933
19934         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
19935         memcpy.
19936
19937 2003-10-15  Paul Eggert  <eggert@twinsun.com>
19938
19939         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
19940         (SIZE_MAX): Remove.
19941         (new_exclude, add_exclude_file): Initial size no longer needs to
19942         be a power of 2.
19943         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
19944         our own address arithmetic overflow checking.
19945
19946         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
19947         (fnmatch): Do not alloca more than 2000 wide characters;
19948         instead, use malloc for large buffers.
19949         Check for address arithmetic overflow, and return -1
19950         with errno set to ENOMEM in that case.
19951         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
19952         (NEW_PATTERN): Do not alloca more than 8000 bytes;
19953         instead, return -1.  Check for address arithmetic overflow.
19954
19955 2003-10-14  Paul Eggert  <eggert@twinsun.com>
19956
19957         Handle invalid suffixes and overflow independently, so that
19958         callers can treat them independently as needed.  Fix some bugs in
19959         suffix handling, e.g., "100k@" was not diagnosed as an invalid
19960         suffix for a human-readable blocksize.  The major caller-visible
19961         change is the addition of a new
19962         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
19963         that both overflow and suffix chars were found.
19964
19965         * lib/human.c (humblock): Don't check separately for invalid suffix
19966         char; that is xstrtoumax's job (now that its bug is fixed).
19967         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
19968         INTMAX_MAX]: New macros.
19969         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
19970         TYPE_MAXIMUM): New macros.
19971         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
19972         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
19973         if overflow occurs, as it's what __strtol does and it's more useful
19974         in practice.
19975         (__xstrtol): If __strtol reports some error other than ERANGE,
19976         reflect it to the caller as LONGINT_INVALID.  If it reports
19977         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
19978         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
19979         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
19980         value.
19981         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
19982         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
19983         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
19984         [defined UINTMAX_MAX]: New macros.
19985
19986 2003-10-14  Bruno Haible  <bruno@clisp.org>
19987
19988         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
19989
19990 2003-10-14  Bruno Haible  <bruno@clisp.org>
19991
19992         * m4/sig_atomic_t: New file, from GNU gettext.
19993         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
19994
19995 2003-10-14  Bruno Haible  <bruno@clisp.org>
19996
19997         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
19998         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
19999         Also use volatile where needed.
20000
20001 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20002
20003         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
20004         Change maintainer from Bruno Haible to 'all'.
20005
20006 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20007
20008         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
20009
20010 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20011
20012         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
20013         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
20014         and define in terms of the other primitives.
20015         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
20016         (SIZE_MAX): Define if not already defined.
20017         (array_size_overflow): New function.
20018         (xalloc_die): Abort instead of exiting if 'error' returns.
20019         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
20020         (xmalloc, xrealloc): Use them.
20021         (xcalloc): Check for address arithmetic overflow.
20022         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
20023         a bit faster than strcpy.
20024
20025 2003-10-10  Simon Josefsson  <jas@extundo.com>
20026
20027         * modules/argp (Depends-on): Add restrict and strcase.
20028
20029 2003-10-10  Simon Josefsson  <jas@extundo.com>
20030
20031         * m4/argp.m4: Add AC_C_INLINE.
20032
20033 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20034
20035         Merge getpass from libc, plus a few fixes.
20036
20037         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
20038         Include <stdbool.h>.
20039         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
20040         __fsetlocking to empty.
20041         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
20042         do include <bits/libc-lock.h>.
20043         Do not include <fcntl.h>; not needed.
20044         [_LIBC]: Include <wchar.h>.
20045         (NOTCANCEL_MODE): New macro.
20046         (flockfile, funlockfile) [_LIBC]: New macros.
20047         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
20048         [!_LIBC]: New macros.
20049         (call_fclose): New function.
20050         (getpass): Use it.  Save tty stream separately; this simplifies the
20051         code and makes it more reliable if stdin happens to equal stdout.
20052         Invoke __fsetlocking on tty.
20053         Handle thread cancellation if needed.
20054         Namespace cleanup (use __tcgetattr, __getline).
20055         Use bool for Booleans.
20056         [USE_IN_LIBIO]: Handle wide streams.
20057         [!_LIBC]: Unconditionally do the fseek, since we don't know what
20058         stream might go where.
20059
20060         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
20061         doesn't have to include <stdio.h> before us.
20062         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
20063         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
20064         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
20065         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
20066         if not declared, so that we can use getpass.c code from libc without
20067         rewriting it.
20068         (flockfile, ftrylockfile, funlockfile): New macros.
20069
20070 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20071
20072         * modules/getpass: Depend on stdbool.
20073
20074 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20075
20076         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
20077
20078 2003-10-07  Karl Berry  <karl@gnu.org>
20079
20080         * config/config.{guess,sub}: update from config.
20081
20082 2003-10-06  Jim Meyering  <jim@meyering.net>
20083             Bruno Haible  <bruno@clisp.org>
20084
20085         This lets translators provide better translations for the
20086         "Written by ..." part of --version output.
20087         * lib/version-etc.h: Include stdarg.h.
20088         (version_etc_copyright): Declare as readonly.
20089         (version_etc): Make this function variadic with a NULL-terminated list
20090         of author name strings.
20091         (version_etc_va): New declaration.
20092         * lib/version-etc.c: Include stdarg.h, stdlib.h.
20093         (version_etc_copyright): Declare as readonly.
20094         (version_etc_va): New function. Provide a different translatable string
20095         for each possible number of authors < 10. Abbreviate when there are 10
20096         authors or more.
20097         (version_etc): Make this function variadic. Call version_etc_va.
20098         Suggestion from Gary V. Vaughan.
20099
20100         * lib/long-options.h (parse_long_options): Change prototype: the
20101         authors string is moved to the end and becomes variadic.
20102         * lib/long-options.c: Include stdarg.h.
20103         (parse_long_options): Make this function variadic, too.
20104         Call version_etc_va, not version_etc.
20105
20106 2003-10-06  Bruno Haible  <bruno@clisp.org>
20107
20108         * modules/version-etc-2: Remove file.
20109         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
20110
20111 2003-10-06  Bruno Haible  <bruno@clisp.org>
20112
20113         * modules/fatal-signal: New file.
20114         * MODULES.html.sh (func_all_modules): Add fatal-signal.
20115
20116 2003-10-06  Bruno Haible  <bruno@clisp.org>
20117
20118         * m4/fatal-signal.m4: New file.
20119         * m4/signalblocking.m4: New file, from GNU gettext.
20120
20121 2003-10-06  Bruno Haible  <bruno@clisp.org>
20122
20123         * lib/version-etc-2.h: Remove file.
20124         * lib/version-etc-2.c: Remove file.
20125
20126 2003-10-06  Bruno Haible  <bruno@clisp.org>
20127
20128         * lib/fatal-signal.h: New file, from GNU gettext.
20129         * lib/fatal-signal.c: New file, from GNU gettext.
20130
20131 2003-10-05  Paul Eggert  <eggert@twinsun.com>
20132
20133         * README: Rework advice for preventing empty .o files.
20134         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
20135         not <sys/types.h>.
20136
20137 2003-10-04  Karl Berry  <karl@gnu.org>
20138
20139         * lib/argp*: update from libc.
20140
20141 2003-10-04  Karl Berry  <karl@gnu.org>
20142
20143         * config/config.{guess,sub}: update from config.
20144
20145 2003-10-02  Bruno Haible  <bruno@clisp.org>
20146
20147         * modules/lchown (Include): Add lchown.h.
20148         * modules/time_r (Include): Use "..." syntax.
20149         * modules/xgetdomainname (Include): Add xgetdomainname.h.
20150
20151 2003-10-01  Simon Josefsson  <jas@extundo.com>
20152
20153         * MODULES.html.sh (func_all_modules): Move gethostname from section
20154         'based on' to section 'lacking' POSIX:2001.
20155
20156 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
20157
20158         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
20159         to output mode on the same stream.
20160
20161 2003-09-29  Paul Eggert  <eggert@twinsun.com>
20162
20163         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
20164         Fix arg typo in previous patch.
20165
20166 2003-09-28  Jim Meyering  <jim@meyering.net>
20167
20168         * lib/error.c: Correct cpp indentation.
20169
20170 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20171
20172         * modules/free: New file.
20173
20174 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20175
20176         * m4/free.m4: New file.
20177
20178 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20179
20180         * lib/minmax.h (MIN, MAX)
20181         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
20182         Omit the special code that used __typeof__, since we worry that
20183         it could be more trouble than it's worth.  See:
20184         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
20185         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
20186
20187         * lib/free.c: New file.
20188
20189 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
20190
20191         Trivial fixes to Makefile.am parts of module listings.
20192         * modules/strstr: Append strstr.h to lib_SOURCES.
20193         * modules/strcase: Likewise, for strcase.h.
20194
20195 2003-09-27  Karl Berry  <karl@gnu.org>
20196
20197         * config/mkinstalldirs: update from automake.
20198
20199 2003-09-26  Paul Eggert  <eggert@twinsun.com>
20200
20201         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
20202         (error_tail): Do not loop, reallocating temporary buffer, since
20203         the output cannot contain more wide characters than the input
20204         contains bytes, the size must be big enough already.  This avoids
20205         one potential size overflow calculation.  Check for size overflow
20206         when calculating temporary buffer size.  Free temporary buffer
20207         when done, if it was allocated with malloc; this plugs a memory
20208         leak.  Remove casts from void * to pointers, that are no longer
20209         needed now that we're assuming C89 or better.
20210
20211         Merge error changes from glibc.
20212
20213         * lib/error.c, error.h: Update copyright notice header to match glibc.
20214         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
20215         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
20216         Disable cancellation while printing error.
20217         * lib/error.h: Prepend __ to parameter names.
20218
20219 2003-09-26  Jim Meyering  <jim@meyering.net>
20220
20221         * lib/error.c (error_tail): Move some declarations
20222         into inner scope where the local variables are used.
20223
20224 2003-09-26  Bruno Haible  <bruno@clisp.org>
20225
20226         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
20227         stpncpy().
20228         Don't define stpncpy through config.h; it's now done through stpncpy.h.
20229
20230 2003-09-26  Bruno Haible  <bruno@clisp.org>
20231
20232         * lib/stpncpy.h (gnu_stpncpy): New declaration.
20233         (stpncpy): Define as alias for gnu_stpncpy.
20234         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
20235
20236 2003-09-25  Simon Josefsson  <jas@extundo.com>
20237
20238         * lib/xgetdomainname.h: New file.
20239         * lib/xgetdomainname.c: New file.
20240
20241 2003-09-25  Simon Josefsson  <jas@extundo.com>
20242             Bruno Haible  <bruno@clisp.org>
20243
20244         * modules/getdomainname: New file.
20245         * modules/xgetdomainname: New file.
20246         * MODULES.html.sh (func_all_modules): Add getdomainname,
20247         xgetdomainname.
20248
20249 2003-09-25  Simon Josefsson  <jas@extundo.com>
20250             Bruno Haible  <bruno@clisp.org>
20251
20252         * m4/getdomainname.m4: New file.
20253
20254 2003-09-25  Simon Josefsson  <jas@extundo.com>
20255             Bruno Haible  <bruno@clisp.org>
20256
20257         * lib/getdomainname.h: New file.
20258         * lib/getdomainname.c: New file.
20259
20260 2003-09-25  Karl Berry  <karl@gnu.org>
20261
20262         * lib/argp-fmtstream.c, argp-help.c: update from libc.
20263
20264 2003-09-25  Karl Berry  <karl@gnu.org>
20265
20266         * config/install-sh: update from automake.
20267
20268 2003-09-25  Bruno Haible  <bruno@clisp.org>
20269
20270         * modules/version-etc-2: New file, from modules/version-etc with
20271         modifications.
20272         * MODULES.html.sh (func_all_modules): Add version-etc-2.
20273
20274 2003-09-25  Bruno Haible  <bruno@clisp.org>
20275
20276         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
20277         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
20278
20279 2003-09-24  Simon Josefsson  <jas@extundo.com>
20280
20281         * modules/xgethostname: Add xgethostname.h.
20282
20283 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20284
20285         * lib/linebuffer.c (freebuffer): Don't free the argument, just
20286         the buffer associated with the argument.  Bug reported by
20287         Simon Josefsson.
20288
20289 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20290
20291         * README: Document assumptions that 'int' is at least 32 bits
20292         wide, that integer arithmetic is 2's complement without overflow,
20293         that there are no holes in integer values, that adding sizes of
20294         two nonoverlapping objects can't overflow, and that all-bits-zero
20295         yields scalar zero.  Fix spelling and capitalization typos.
20296
20297 2003-09-19  Karl Berry  <karl@gnu.org>
20298
20299         * lib/argp.h: update from libc.
20300
20301 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20302
20303         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
20304         to avoid spurious warnings like "AC_RUN_IFELSE was called before
20305         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
20306
20307 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20308
20309         * gnulib-tool: Use "test -h", not "test -L", for portability
20310         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
20311         (tags_regexp): Remove, since \| doesn't conform to POSIX.
20312         (sed_extract_prog): Issue s commands one-by-one, rather than
20313         using \| in one s command.
20314
20315 2003-09-16  Paul Eggert  <eggert@twinsun.com>
20316
20317         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
20318         input error, instead of returning NULL the next time we are called
20319         (and therefore losing track of errno).
20320
20321 2003-09-16  Bruno Haible  <bruno@clisp.org>
20322
20323         * gnulib-tool (func_create_testdir): Warn about duplicated
20324         dependencies.
20325
20326 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20327
20328         * modules/argmatch, modules/fatal, modules/obstack,
20329         modules/xalloc, modules/xgethostname: Sort dependencies by
20330         importance, not alphabetically.
20331
20332 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20333
20334         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
20335         fails, so that the caller gets the proper errno.
20336
20337         * lib/readutmp.c (read_utmp): Likewise.
20338         Check for fstat error.  Close stream and free storage
20339         when failing.
20340
20341 2003-09-14  Karl Berry  <karl@gnu.org>
20342
20343         * config/srclist.txt (strdup.c): disable for c89 changes.
20344
20345 2003-09-14  Jim Meyering  <jim@meyering.net>
20346
20347         * lib/getloadavg.c: Correct cpp indentation.
20348         * lib/strdup.c: Likewise.
20349         * lib/vasnprintf.c: Likewise.
20350
20351 2003-09-14  Bruno Haible  <bruno@clisp.org>
20352
20353         * modules/fwriteerror: New file.
20354         * MODULES.html.sh (func_all_modules): Add fwriteerror.
20355
20356 2003-09-14  Bruno Haible  <bruno@clisp.org>
20357
20358         * lib/fwriteerror.h: New file.
20359         * lib/fwriteerror.c: New file.
20360
20361 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20362
20363         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
20364         modules/xgethostname, modules/xalloc: Depend on exit.
20365
20366 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20367
20368         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
20369
20370         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
20371         and AC_MINIX, too, so that their extensions are available.
20372
20373         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
20374         This macro has been superseded by gl_BACKUPFILE.
20375
20376         More patches to assume C89 or better.
20377
20378         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
20379
20380         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
20381         unconditionally.
20382         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
20383         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
20384         Include <string.h>, <stdlib.h> unconditionally.
20385         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
20386         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
20387         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
20388         headers or for string.h.
20389         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
20390         or strtoul.
20391
20392         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
20393         headers.
20394         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
20395         * m4/userspec.m4 (gl_USERSPEC): Likewise.
20396         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
20397         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
20398         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
20399         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
20400         memcpy, memset.
20401         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
20402         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
20403         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
20404         strtol.
20405         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
20406         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
20407         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
20408         strtoul.
20409
20410 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20411
20412         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
20413         * lib/obstack.c [!defined _LIBC]: Likewise.
20414         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
20415         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
20416         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
20417
20418         More changes to assume C89 or better.
20419
20420         * lib/error.c (error_tail): Assume vprintf.
20421
20422         * lib/argmatch.c (getenv): Remove decl.
20423         * lib/progreloc.c (get_full_program_name): Define via prototype.
20424         * lib/setenv.c (clearenv): Likewise.
20425         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
20426         needed.
20427         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
20428         (malloc, memcpy): Remove decls.
20429         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
20430         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
20431         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
20432         (memcpy): Remove macro.
20433         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
20434         (__P): Remove.  All uses removed.
20435         (PTR): Remove.  All uses changed to void *.
20436         (CHAR_BIT, NULL): Remove.
20437         (spaces, zeros, memset_space, memset_zero)
20438         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
20439         Remove.
20440         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
20441         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
20442         Define with prototype.
20443         Remove now-unnecessary prototype decl.
20444         (extra_args_spec): Assume ANSI C.  All uses changed.
20445         (extra_args_spec_iso): Remove.
20446         (my_strftime, emacs_strftimeu): Define via prototype.
20447         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
20448         unconditionally.
20449         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
20450         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
20451         (strtoul, strtol): Remove decls.
20452         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
20453         LONG_MAX): Remove.
20454         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
20455         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
20456         (LOCALE_PARAM_PROTO): New macro.
20457         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
20458         (INTERNAL (strtol), strtol): Define with a prototype.
20459         (PARAMS): Remove.  All uses removed.
20460         * lib/tempname.c: Include <string.h> unconditionally.
20461         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
20462         * lib/xgethostname.c (main): Define with a prototype.
20463         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
20464         Include <stdlib.h> unconditionally.
20465         (calloc, malloc, realloc, free): Remove decls.
20466         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
20467         Include <stdlib.h> unconditionally.  Sort include file names.
20468         (strtod): Remove.
20469         (xstrtod): Define with a prototype.
20470         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
20471         (strtol, strtoul): Remove decls.
20472
20473 2003-09-11  Paul Eggert  <eggert@twinsun.com>
20474
20475         More patches to assume C89 or better.
20476         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
20477         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
20478         string.h, memchr, STDC_HEADERS.
20479
20480 2003-09-11  Paul Eggert  <eggert@twinsun.com>
20481
20482         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
20483         Include <stdlib.h>, <string.h> unconditionally.
20484         Remove now-unnecessary cast to char *.
20485         * lib/strnlen.c: Include <string.h> unconditionally.
20486         * lib/yesno.c (yesno): Define with a prototype.
20487
20488 2003-09-11  Bruno Haible  <bruno@clisp.org>
20489
20490         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
20491
20492 2003-09-10  Jim Meyering  <jim@meyering.net>
20493
20494         * lib/error.c: Correct indentation of cpp directives.
20495
20496 2003-09-10  Bruno Haible  <bruno@clisp.org>
20497
20498         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
20499         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
20500         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
20501         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
20502         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
20503         <stdlib.h> and <string.h> checks.
20504         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
20505         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
20506
20507 2003-09-10  Bruno Haible  <bruno@clisp.org>
20508
20509         * lib/strcspn.c: Include <string.h> unconditionally.
20510         * lib/strpbrk.c: Include <string.h> unconditionally.
20511         * lib/strstr.c: Include <string.h> unconditionally.
20512         * lib/unicodeio.c: Include <string.h> unconditionally.
20513         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
20514         * lib/unsetenv.c: Likewise.
20515         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
20516         * lib/yesno.c: Include <stdlib.h> unconditionally.
20517         (rpmatch): Add prototype.
20518
20519 2003-09-09  Paul Eggert  <eggert@twinsun.com>
20520
20521         More patches to assume C89 or better.
20522         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
20523         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
20524         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
20525         or for string.h.
20526         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
20527         stdlib.h.
20528         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
20529         C headers.
20530         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
20531         string.h.
20532         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
20533         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
20534         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
20535         or for string.h.
20536         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
20537         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
20538         C headers.
20539         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
20540         memcpy.
20541         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
20542         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
20543         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
20544         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
20545         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
20546         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
20547         string.h, free.
20548         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
20549         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
20550         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
20551         C headers, or for string.h.
20552         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
20553         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
20554         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
20555         headers, memory.h, stdlib.h, string.h, strings.h.
20556         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
20557         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
20558         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
20559         strchr.
20560         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
20561         headers, memory.h, string.h.
20562         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
20563         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
20564         free.
20565         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
20566         headers.
20567         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
20568         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
20569         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
20570         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
20571         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
20572
20573 2003-09-09  Paul Eggert  <eggert@twinsun.com>
20574
20575         More K&R removal.
20576
20577         * lib/acosl.c (main): Use a prototype.
20578         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
20579         tanl.c: Likewise.
20580
20581         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
20582
20583         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
20584         (getopt, etopt_long, getopt_long_only, _getopt_internal)
20585         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
20586         with a prototype.
20587         * lib/getopt.c (const): Remove macro.
20588         Include <string.h> unconditionally.
20589         (my_index): Remove; all uses changed to strchr.
20590         (strlen): Remove decl.
20591         (exchange): Remove forward decl; no longer needed.
20592         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
20593         Define with prototype.
20594         * lib/getopt1.c (const): Remove macro.
20595         (getopt_long, getopt_long_only, main): Define with prototype.
20596
20597         * lib/getugroups.c: Include <string.h> unconditionally.
20598
20599         * lib/getusershell.c: Include <stdlib.h> unconditionally.
20600         (getusershell, setusershell, endusershell, readname, main):
20601         Define with prototypes.
20602
20603         * lib/group-member.c: Include group-member.h first.
20604         Include <stdlib.h> unconditionally.
20605
20606         * lib/hard-locale.c: Include hard-locale.h first.
20607         Include <stdlib.h>, <string.h> unconditionally.
20608
20609         * lib/hash.c (free, malloc): Remove decls.
20610         Include <stdlib.h> unconditionally.
20611
20612         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
20613         (getenv): Do not declare.
20614
20615         * lib/idcache.c: Include <string.h> unconditionally.
20616
20617         * lib/long-options.c: Include long-options.h first, to test interface.
20618         Include <stdlib.h> unconditionally.
20619
20620         * lib/makepath.c: Include makepath.h first, to test interface.
20621         Include <stdlib.h> and <string.h> unconditionally.
20622
20623         * lib/linebuffer.c: Include <stdlib.h>.
20624         (free): Remove decl.
20625
20626         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
20627         stddef.h. rpl_malloc returns void *, not char *.
20628         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
20629         prototype.
20630
20631         * lib/md5.h: Include <limits.h> unconditionally.
20632         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
20633         (__P): Remove; all uses removed.
20634         * lib/md5.c: Include "md5.h" first.
20635         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
20636         md5_buffer, md5_process_bytes, md5_process_block):
20637         Define with prototypes.
20638         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
20639         * lib/sha.c: Include "sha.h" first.
20640         Include <stdlib.h>, <string.h> unconditionally.
20641
20642         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
20643         * lib/memcmp.c (__ptr_t): Likewise.
20644         * lib/memrchr.c (__ptr_t): Likewise.
20645         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
20646         Include <string.h> unconditionally.
20647         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
20648         * lib/memchr.c: Include <stdlib.h> unconditionally.
20649         * lib/memchr.c (LONG_MAX): Remove.
20650         * lib/memrchr.c (LONG_MAX): Likewise.
20651         * lib/memchr.c (__memchr): Define via a prototype.
20652         * lib/memrchr.c (__memrchr): Likewise.
20653         * lib/memcmp.c (__P): Remove, and remove all uses.
20654         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
20655         Remove forward decls; no longer needed.
20656         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
20657         Use types required by C89 in prototype.
20658
20659         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
20660         * lib/savedir.c: Likewise.
20661         * lib/mkdir.c (free): Remove decl.
20662         * lib/rmdir.c (rmdir): Define with a prototype.
20663         * lib/savedir.c: Include savedir.h first, to test interface.
20664
20665         * lib/mktime.c (STDC_HEADERS): Remove.
20666         Include <stdlib.h>, <string.h> unconditionally.
20667
20668         * lib/modechange.c: Include <stdlib.h> unconditionally.
20669         (malloc): Remove decl.
20670
20671         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
20672         (free): Remove decl.
20673
20674         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
20675         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
20676         (This type really should be intptr_t, but that's a C99ism.)
20677         (_obstack_memcpy): Remove: all uses changed to memcpy.
20678         Include <string.h> unconditionally.
20679         (struct obstack): Assume __STDC__ for types of members
20680         chunkfun, freefun, extra_arg.
20681         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
20682         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
20683         obstack_begin, obstack_specify_allocation,
20684         obstack_specify_allocation_with_arg, obstack_chunkfun,
20685         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
20686         Remove unprototyped decls and the macros that use them.
20687         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
20688         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
20689         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
20690         (defined __STDC__ && __STDC__)]:
20691         Remove nonprototyped code.
20692         Include <stdlib.h> unconditionally.
20693         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
20694         _obstack_allocated_p, _obstack_free, obstack_free,
20695         _obstack_memory_used, print_and_abort):
20696         Define using prototypes.
20697         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
20698         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
20699         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
20700         obstack_next_free, obstack_object_size, obstack_room) [0]:
20701         Remove unused, unprototyped code.
20702
20703         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
20704
20705         * lib/physmem.c (physmem_total, physmem_available, main): Define
20706         with prototypes.
20707
20708         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
20709         (main): Define with a prototype.
20710
20711         * lib/posixver.c (getenv): Remove decl.
20712
20713         * lib/putenv.c (malloc): Returns void *, not char *.
20714         Include <string.h> unconditionally.
20715         (strchr, memcpy, NULL): Do not define.
20716
20717         * lib/readtokens.c: Include readtokens.h first, to test interface.
20718         Include <stdlib.h>, <string.h> unconditionally.
20719         (init_tokenbuffer): Define with a prototype.
20720
20721         * lib/regex.c (PARAMS): Remove.  All uses removed.
20722         All uses of _RE_ARGS removed, too.
20723         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
20724         unconditionally.
20725         (bzero): Assume memset exists.
20726         (memcmp, memcpy, NULL): Remove.
20727         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
20728         char, or assignments to local vars of type signed char.
20729         (init_syntax_once, PREFIX(extract_number_and_incr),
20730         PREFIX(print_partial_compiled_pattern),
20731         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
20732         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
20733         PREFIX(regex_grow_registers), PREFIX(regex_compile),
20734         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
20735         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
20736         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
20737         wcs_compile_range, byte_compile_range, truncate_wchar,
20738         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
20739         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
20740         count_mbs_length, wcs_re_match_2_internal,
20741         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
20742         PREFIX(alt_match_null_string_p),
20743         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
20744         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
20745         regfree, PREFIX(extract_number)): Define with prototype.  Remove
20746         now-unnecessary declaration, if any.
20747         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
20748         regcomp, regexec):
20749         Remove now-unnecessary casts among pointer types.
20750         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
20751
20752         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
20753         (free): Remove decl.
20754
20755         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
20756
20757         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
20758         (free): Remove decl.
20759
20760         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
20761         * lib/xgetcwd.c: Likewise.
20762
20763         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
20764         (free): Remove decl.
20765
20766         * lib/strchrnul.c (strchrnul): Define with a prototype.
20767         Fix bug: c_in was not converted to char before searching.
20768
20769         The following changes are not K&R related:
20770
20771         * lib/group-member.h: Include <sys/types.h>, so that this file is
20772         self-contained.
20773         * lib/makepath.h: Likewise.
20774
20775         * lib/getusershell.c (readname, default_index, line_size, readname):
20776         Use size_t, not int, for sizes.
20777         (readname): If the size overflows, report an error instead of
20778         looping forever.
20779
20780 2003-09-09  Paul Eggert  <eggert@twinsun.com>
20781
20782         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
20783         libc.
20784
20785 2003-09-09  Paul Eggert  <eggert@twinsun.com>
20786
20787         * README: New section: portability guidelines.
20788
20789 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
20790
20791         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
20792         C89 spec.
20793
20794 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
20795
20796         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
20797
20798 2003-09-08  Paul Eggert  <eggert@twinsun.com>
20799
20800         Assume C89 or better; remove K&R cruft.
20801         A few of these changes were first proposed by Derek Robert Price
20802         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
20803
20804         * lib/addext.c: Include <string.h> unconditionally.
20805         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
20806         Don't declare getenv or malloc.
20807
20808         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
20809         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
20810         (NULL): Remove.
20811         (find_stack_direction, alloca): Use prototypes.
20812
20813         * lib/atexit.c (atexit): Define using a prototype.
20814
20815         * lib/basename.c, dirname.c, stripslash.c:
20816         Include <string.h> unconditionally.
20817
20818         * lib/bcopy.c: Include <stddef.h>.
20819         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
20820
20821         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
20822
20823         * lib/error.h (error, error_at_line, error_print_progname)
20824         [! (defined (__STDC__) && __STDC__)]: Remove decls.
20825         * lib/error.c: Include error.h first, to check interface.
20826         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
20827         (VA_START): Remove; all uses changeed to va_start.
20828         (exit, strerror): Remove decls.
20829         (error_print_progname): Prototype uncondionally.
20830         Don't include <errno.h>; no longer needed.
20831         (private_strerror): Remove.
20832         (error_tail): Always define.
20833         (error, error_at_line): Assume C89 or better; always use prototypes.
20834         * lib/fatal.c: Include "fatal.h" first, to test interface.
20835         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
20836         (VA_START): Remove; all uses changed to va_start.
20837         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
20838         this case.
20839         (exit): Remove decl.
20840         (fatal): Prototype unconditionally.  Assume va_start works.
20841         Abort at end, to pacify gcc.
20842
20843         * lib/euidaccess.c (main): Define with a prototype.
20844
20845         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
20846
20847         * lib/exitfail.c: Include <stdlib.h> unconditionally.
20848
20849         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
20850         prototypes.
20851         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
20852         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
20853         (getenv): Remove decl.
20854         (fnmatch): Define using a prototype.
20855         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
20856         (FCT): Define using a prototype.
20857
20858         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
20859
20860         * lib/gethostname.c: Include <stddef.h>.
20861         (gethostname): Define with prototype.  Length is size_t, not int.
20862
20863 2003-09-08  Paul Eggert  <eggert@twinsun.com>
20864
20865         Assume C89 or better; remove K&R cruft.
20866         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
20867         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
20868         string.h, getenv, malloc.
20869         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
20870         headers.
20871         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
20872         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
20873         do not check for strerror.
20874         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
20875         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
20876         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
20877         do not check for doprnt or vprintf.
20878         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
20879         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
20880
20881 2003-09-08  Paul Eggert  <eggert@twinsun.com>
20882
20883         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
20884         getversion.c should have been removed then, but was accidentally
20885         preserved.
20886
20887         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
20888         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
20889
20890 2003-09-08  Karl Berry  <karl@gnu.org>
20891
20892         * config/config.sub, config.guess, srclistvars.sh: update from savannah
20893                 config, forget about prep.
20894
20895         * config/depcomp, missing: update from automake.
20896
20897 2003-09-07  Paul Eggert  <eggert@twinsun.com>
20898
20899         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
20900         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
20901
20902 2003-09-07  Paul Eggert  <eggert@twinsun.com>
20903
20904         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
20905         copy_tm_result.  Bug reported by Simon Josefsson in
20906         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
20907
20908 2003-09-06  Paul Eggert  <eggert@twinsun.com>
20909
20910         * m4/time_r.m4: New file.
20911         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
20912         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
20913         is. Check for timegm declaration.
20914         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
20915         Do not check for gmtime_r.
20916         Replace mktime if __mktime_internal does not exist and if mktime
20917         hasn't been replaced already.
20918
20919 2003-09-06  Paul Eggert  <eggert@twinsun.com>
20920
20921         * lib/time_r.c, lib/time_r.h: New files.
20922
20923         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
20924         __localtime_r.
20925         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
20926         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
20927
20928         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
20929         __gmtime_r.
20930         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
20931         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
20932         Include <time_r.h>.
20933
20934         * lib/timegm.c: Switch to glibc implementation, with the following
20935         changes:
20936         [defined HAVE_CONFIG_H]: Include <config.h>.
20937         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
20938         (__mktime_internal) [!defined _LIBC]: New decl.
20939         (__gmtime_r) [!defined _LIBC]: New macro and function.
20940         (timegm): Use a prototype, since gnulib assumes C89.
20941         Do not bother declaring tmp to be const, as it's not really usefu.
20942         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
20943         (timegm): Declare only if HAVE_DECL_TIMEGM.
20944
20945 2003-09-06  Paul Eggert  <eggert@twinsun.com>
20946
20947         * MODULES.html.sh (func_all_modules): Add time_r.
20948         * modules/time_r: New file.
20949         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
20950         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
20951
20952 2003-09-03  Paul Eggert  <eggert@twinsun.com>
20953
20954         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
20955         Bug reported by Lute Kamstra in
20956         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
20957
20958         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
20959         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
20960         course with correspondingly smaller numbers for tomorrow and
20961         yesterday.  From Tadayoshi Funaba.  Originally installed into
20962         sh-utils on 1999-08-07, but the patch got lost (I guess during the
20963         coreutils merge?).
20964
20965 2003-08-31  Simon Josefsson  <jas@extundo.com>
20966
20967         * modules/timegm: New file.
20968         * MODULES.html.sh (func_all_modules): Add timegm.
20969
20970 2003-08-31  Simon Josefsson  <jas@extundo.com>
20971
20972         * m4/timegm.m4: New file.
20973
20974 2003-08-31  Simon Josefsson  <jas@extundo.com>
20975
20976         * lib/timegm.h: New file.
20977         * lib/timegm.c: New file.  Based on
20978         wget-1.8.2/src/http.c:mktime_from_utc.
20979
20980 2003-08-31  Karl Berry  <karl@gnu.org>
20981
20982         * lib/argp.h: update from libc.
20983
20984 2003-08-28  Bruno Haible  <bruno@clisp.org>
20985
20986         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
20987         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
20988         followed by '#define fnmatch fnmatch_posix' gives an error.
20989
20990 2003-08-28  Bruno Haible  <bruno@clisp.org>
20991
20992         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
20993         warning on QNX, which defines O_BINARY to 000000.
20994
20995 2003-08-27  Jim Meyering  <jim@meyering.net>
20996
20997         * m4/mkstemp.m4: Require that the system mkstemp be able to create
20998         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
20999         would fail after 32.  Reported by Danny Levinson.  Details here:
21000         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
21001
21002 2003-08-24  Bruno Haible  <bruno@clisp.org>
21003
21004         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
21005         MSVC7 <stdio.h> is included later.
21006
21007 2003-08-22  Simon Josefsson  <jas@extundo.com>
21008
21009         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
21010
21011 2003-08-20  Karl Berry  <karl@gnu.org>
21012
21013         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
21014
21015 2003-08-20  Bruno Haible  <bruno@clisp.org>
21016
21017         * modules/progname: New file.
21018         * MODULES.html.sh (func_all_modules): Add progname.
21019
21020 2003-08-20  Bruno Haible  <bruno@clisp.org>
21021
21022         * lib/progname.h: New file, from GNU gettext.
21023         * lib/progname.c: New file, from GNU gettext.
21024         * lib/progreloc.c: New file, from GNU gettext.
21025
21026 2003-08-19  Jim Meyering  <jim@meyering.net>
21027
21028         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
21029         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
21030
21031 2003-08-19  Bruno Haible  <bruno@clisp.org>
21032
21033         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
21034         more.
21035
21036 2003-08-19  Bruno Haible  <bruno@clisp.org>
21037
21038         * lib/xstrdup.c: Assume <string.h> exists.
21039
21040 2003-08-18  Paul Eggert  <eggert@twinsun.com>
21041
21042         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
21043         in makefile rules.
21044
21045 2003-08-18  Jim Meyering  <jim@meyering.net>
21046
21047         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
21048         * m4/lib-ld.m4: Likewise.
21049
21050 2003-08-18  Jim Meyering  <jim@meyering.net>
21051
21052         * lib/setenv.h: Indent nested cpp directive.
21053         * lib/vasnprintf.c: Remove trailing blanks.
21054
21055 2003-08-17  Simon Josefsson  <jas@extundo.com>
21056
21057         * modules/xstrndup: New file.
21058         * MODULES.html.sh (func_all_modules): Add xstrndup.
21059
21060 2003-08-17  Simon Josefsson  <jas@extundo.com>
21061
21062         * modules/argp: Fix autoconf macro name. Add more dependencies.
21063
21064 2003-08-17  Simon Josefsson  <jas@extundo.com>
21065
21066         * m4/xstrndup.m4: New file.
21067
21068 2003-08-17  Simon Josefsson  <jas@extundo.com>
21069
21070         * m4/argp.m4: New file.
21071
21072 2003-08-17  Simon Josefsson  <jas@extundo.com>
21073             Bruno Haible  <bruno@clisp.org>
21074
21075         * lib/xstrndup.h: New file.
21076         * lib/xstrndup.c: New file.
21077
21078 2003-08-17  Bruno Haible  <bruno@clisp.org>
21079
21080         * modules/strndup (Files, Include): Add lib/strndup.h.
21081
21082 2003-08-17  Bruno Haible  <bruno@clisp.org>
21083
21084         * modules/euidaccess (Files): Add lib/euidaccess.h.
21085
21086 2003-08-17  Bruno Haible  <bruno@clisp.org>
21087
21088         * lib/strndup.h: New file.
21089
21090 2003-08-17  Bruno Haible  <bruno@clisp.org>
21091
21092         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
21093         like AC_GNU_SOURCE.
21094         * modules/extensions (configure.ac): Comment out the invocation of
21095         gl_USE_SYSTEM_EXTENSIONS.
21096
21097 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21098
21099         Merges from coreutils, etc.
21100         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
21101         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
21102         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
21103         fixing a typo.
21104         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
21105         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
21106
21107 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21108
21109         Document merge from coreutils.
21110         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
21111         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
21112         * modules/utime: Add m4/utimes-null.m4.
21113
21114 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21115
21116         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
21117         space, undoing this 2003-08-12 change:
21118         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21119
21120 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21121
21122         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
21123         strtoul.c from libc, undoing this 2003-08-12 change:
21124         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21125
21126 2003-08-16  Jim Meyering  <jim@meyering.net>
21127
21128         Merges from coreutils.
21129         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
21130         prefix.  Adjust cache variables similarly.  Create 500 rather than
21131         just 300 files, to exercise bug on Darwin6.5, too.
21132         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
21133         $missing_dir.
21134         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
21135         AM_SYS_POSIX_TERMIOS.
21136         Reported by mkc@mathdogs.com.
21137         Also change use of $am_cv_sys_posix_termios
21138         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
21139         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
21140         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
21141         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
21142         in /proc/mounts until it finds one with matching device number.  This
21143         is unnecessary when the FILE argument *is* a mount point.  No stat call
21144         is necessary in that case.  So, disable the statvfs-testing code on
21145         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
21146         as RedHat bug# 84846.
21147         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21148         to 1MB, so as not to render systems with no stack size limit (e.g.,
21149         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21150         Include <unistd.h>.  On some systems,
21151         it is required for the definition of _SC_PAGESIZE.
21152
21153 2003-08-16  Jim Meyering  <jim@meyering.net>
21154
21155         Merge from coreutils.
21156         * lib/xstrtoimax.c: #else #if -> #elif.
21157         * lib/xstrtoumax.c: Likewise.
21158
21159 2003-08-16  Jim Meyering  <jim@meyering.net>
21160
21161         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
21162         * m4/utimes.m4: Removed.
21163         * m4/utimes-null.m4: Renamed from utimes.m4.
21164
21165         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21166         to 1MB, so as not to render systems with no stack size limit (e.g.,
21167         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21168         Include <unistd.h>.  On some systems,
21169         it is required for the definition of _SC_PAGESIZE.
21170
21171 2003-08-16  Jim Meyering  <jim@meyering.net>
21172         and Paul Eggert  <eggert@cs.ucla.edu>
21173
21174         Merges from coreutils, etc.
21175
21176         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
21177         using the latest version from cvs.  This avoids problems with #line
21178         directives using a vendor (Sun) compiler.
21179         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
21180         Don't set GETGROUPS_LIB here; now it's
21181         done via getgroups.m4's wrapper function.
21182         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
21183         rather than just in sh-util/configure.in, so that the
21184         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
21185         same.
21186         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
21187         AC_FUNC_GETLOADAVG where to find getloadavg.c.
21188         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
21189         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
21190         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
21191         Remove code that is now done by the newly-required macros.
21192         Append $(EXEEXT) to DF_PROG.
21193         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
21194         Do not invoke or require the following here,
21195         since prereq.m4 or some gnulib .m4 now does this for us:
21196         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
21197         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
21198         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
21199         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
21200         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
21201         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
21202         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
21203         AC_FUNC_OBSTACK.
21204         Do not replace the following functions, as this is now the job
21205         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
21206         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
21207         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
21208         atexit getpass, strdup, getpagesize.
21209         Replace 'raise'.
21210         Do not check for the following functions, as this is now the job
21211         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
21212         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
21213         setregid.
21214         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
21215         Check for sys/sysctl.h.
21216         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
21217         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
21218         of checking for ssize_t ourselves.
21219
21220         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
21221         Require every macro that gnulib/modules/* suggests for us.
21222         (jm_PREREQ_ADDEXT): New macro.
21223         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
21224         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
21225
21226         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
21227         (gl_PHYSMEM): Use it.
21228         Also check for `table' function.
21229         Check for new headers and functions.
21230         Add check for sys/sysmp.h.
21231         With suggestions from Kaveh Ghazi.
21232         Ignore headers that are present but cannot be compiled.  This
21233         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
21234         C 5.4.
21235
21236 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21237
21238         Document merge from coreutils.
21239         * modules/userspec: Depend on posixver.
21240         * modules/strftime: Depend on tzset.
21241
21242 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21243
21244         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
21245         rather than tab, after '#' in shell-script copyright notices.
21246         Suggested by Bruno Haible.
21247
21248 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21249
21250         * config/srclist-update: Use three spaces, rather than tab, after '#'
21251         in shell-script copyright notices.  Suggested by Bruno Haible.
21252         Remove unnecessary parenthesization in regular expression.
21253
21254 2003-08-15  Jim Meyering  <jim@meyering.net>
21255
21256         Merge from coreutils.
21257         * lib/xgethostname.c: Include <stdlib.h>.
21258         (xghostname): Don't exit for anything other than memory-related
21259         failure; just return NULL.
21260         * lib/userspec.c: Include "posixver.h".
21261         (parse_user_spec): Accept `.' as a separator only
21262         in pre-POSIX-200112 mode.
21263         * lib/strtoimax.c: Use #elif rather than #else #if.
21264         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
21265         Remove function, now that we can rely on a working tzset function.
21266         [!_LIBC]: Ensure that the required autoconf test has been run.
21267         [!defined _NL_CURRENT && HAVE_STRFTIME]:
21268         Use underlying_strftime for %r.
21269         * lib/sha.c: Merge in some clean-up and optimization changes from
21270         glibc.
21271         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
21272         Ensure that it is a multiple of 64.
21273         Rearrange loop exit tests so as to avoid performing an
21274         additional fread after encountering an error or EOF.
21275         * lib/realloc.c: Update copyright date.
21276
21277 2003-08-15  Jim Meyering  <jim@meyering.net>
21278         and Paul Eggert  <eggert@twinsun.com>
21279
21280         Merge from coreutils.
21281         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
21282         member but strut utmpx does not.  Needed for AIX 4.3.3.
21283         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
21284
21285 2003-08-15  Jim Meyering  <jim@meyering.net>
21286         and Paul Eggert  <eggert@cs.ucla.edu>
21287
21288         Merges from coreutils, etc.
21289         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
21290         Require gl_FUNC_TZSET_CLOBBER.
21291         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
21292         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
21293         members.
21294
21295 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21296
21297         Help the merge from coreutils.
21298         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
21299         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
21300         * m4/tzset.m4: Use it too.
21301
21302 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21303
21304         * modules/tzset: New file.
21305
21306 2003-08-14  Jim Meyering  <jim@meyering.net>
21307
21308         Merges from coreutils.
21309         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
21310         variable names, rather than @FNMATCH_H@.
21311         * modules/alloca: Likewise for $(ALLOCA_H).
21312
21313         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
21314         the three copies of the literal target, `fnmatch.h'.
21315         * modules/alloca (alloca.h): Likewise.
21316
21317 2003-08-14  Jim Meyering  <jim@meyering.net>
21318
21319         Merge from coreutils.
21320         * m4/tzset.m4: New file.
21321         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
21322         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
21323         otherwise, AIX 5.1 systems would end up using the latter.
21324         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
21325         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
21326         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
21327         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
21328
21329 2003-08-14  Jim Meyering  <jim@meyering.net>
21330
21331         Merge from coreutils.
21332         * lib/obstack.h: Whitespace changes.
21333         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
21334         and xcalloc return values.
21335         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
21336         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
21337         hang on OSF/1 5.1 for DIR on both local and remote file systems.
21338         Reported by (and fix confirmed by) Nelson H. F. Beebe.
21339         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
21340         error from mntctl.
21341         Use mntctl's return value to drive the entry-processing loop, since
21342         we can't rely on the value of the vmt_length member in the last
21343         entry.  On some systems doing so could result in exhausting
21344         virtual memory.  Based in part on a patch from Mike Jetzer.
21345
21346 2003-08-14  Jim Meyering  <jim@meyering.net>
21347         and Paul Eggert  <eggert@twinsun.com>
21348
21349         Merges from coreutils, plus other fixes.
21350         * lib/physmem.c: Merge in portability changes from gcc/libiberty
21351         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
21352         for credits and details.  Thanks to Kaveh Ghazi for helping
21353         to keep these files in sync.
21354         (ARRAY_SIZE): Define it.
21355         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
21356         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
21357         (memcasecmp): Don't assume size_t fits in unsigned int.
21358         Remove casts and duplicate code.
21359         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
21360         (memcpy): Remove definition.
21361         Merge in some clean-up and optimization changes from glibc.
21362         [BLOCKSIZE]: Move definition to top of file.
21363         Ensure that it is a multiple of 64.
21364         Rearrange loop exit tests so as to avoid performing an
21365         additional fread after encountering an error or EOF.
21366         * lib/md5.h (md5_uintptr): Define.
21367         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
21368         return to the initial working directory.  Preserve errno
21369         for caller.
21370         * lib/idcache.c: Include "xalloc.h".
21371         (xmalloc, xrealloc): Remove decls.
21372         (getuser): Remove casts no longer required in C89.
21373         * lib/human.c: Include stdio.h, for sprintf.
21374         * lib/group-member.c: Include "xalloc.h".
21375         (xmalloc, xrealloc): Remove decls.
21376         (get_group_info): Remove casts no longer required in C89.
21377         * lib/getusershell.c (readname): Remove casts no longer required in
21378         C89.
21379         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
21380         * lib/getline.c: Whitespace fix, from coreutils.
21381
21382 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21383
21384         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
21385         Check for isascii.
21386
21387         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21388         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21389         Undo previous (whitespace-only) change.
21390
21391 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21392
21393         * lib/exclude.c: Include <ctype.h>
21394         (IN_CTYPE_DOMAIN): New macro.
21395         (is_space): New fn.
21396         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
21397         and empty lines.
21398
21399         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21400         Undo previous (whitespace-only) change.
21401
21402 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21403
21404         * config/srclist-update: Change update back to the old behavior,
21405         leaving whitespace alone.  Use one 'sed' command rather than a
21406         pipeline.
21407         (fixlicense): Now a variable, not a function.
21408         (remove_trailing_blanks): Remove.
21409         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
21410         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
21411         Undo previous (whitespace-only) change.
21412
21413 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21414
21415         Merge from coreutils.
21416         * modules/euidaccess: Add lib_SOURCES, include for new
21417         file euidaccess.h
21418
21419 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21420
21421         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21422         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21423         Normalize leading white space and remove trailing white space.
21424
21425         Merge from coreutils
21426         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
21427
21428         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
21429         0.12.1.  These files are now being upgraded automatically by
21430         ../config/srclist-update.
21431
21432 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21433
21434         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21435         Normalize leading white space and remove trailing white space.
21436         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
21437         notice, as per ../config/srclist-update.
21438
21439         Merge from coreutils.
21440         * lib/euidaccess.h: New file.
21441         * lib/euidaccess.c: Include it.
21442         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
21443         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
21444         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
21445
21446 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21447
21448         * config/srclist-update: Add copyright notice.
21449         (remove_id_lines, remove_trailing_blanks): New constants.
21450         (fixfile): Use them to normalize spacing a bit in copied files.
21451         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
21452         Normalize leading white space and remove trailing white space.
21453
21454         * config/texinfo.tex: Sync with texinfo.
21455
21456         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
21457         strtoul.c from libc, to merge coreutils whitespace changes.
21458
21459         * config/srclist.txt: Get the following m4 files from gettext:
21460         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
21461         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
21462         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
21463         wint_t.m4.
21464
21465 2003-08-12  Karl Berry  <karl@gnu.org>
21466
21467         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
21468         been made.
21469
21470 2003-08-11  Paul Eggert  <eggert@twinsun.com>
21471
21472         * modules/gnu-source, m4/gnu-source.m4:
21473         Remove; we're assuming Autoconf 2.54 or later now.
21474         Suggested by Bruno Haible.
21475         * MODULES.html.sh (func_all_modules): Remove gnu-source.
21476
21477 2003-08-11  Bruno Haible  <bruno@clisp.org>
21478
21479         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
21480
21481 2003-08-11  Bruno Haible  <bruno@clisp.org>
21482
21483         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
21484         (vasnprintf): Use it instead of wcslen.
21485
21486 2003-08-11  Bruno Haible  <bruno@clisp.org>
21487
21488         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
21489         value to ensure that _Bool promotes to int. Use #define for _Bool when
21490         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
21491
21492 2003-08-10  Karl Berry  <karl@gnu.org>
21493
21494         * lib/regex.h: update from libc (whitespace fix).
21495
21496 2003-08-09  Paul Eggert  <eggert@twinsun.com>
21497
21498         Merge some files from coreutils.  These changes were
21499         originally made by Jim Meyering.
21500         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
21501         many older Unixes require this.
21502         * lib/alloca.c (alloca): Remove cast to argument of free;
21503         no longer needed in C89.
21504         * lib/alloca_.h, regex.h: Fix white space to match
21505         what GNU indent does.
21506
21507 2003-08-09  Paul Eggert  <eggert@twinsun.com>
21508
21509         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
21510         apparently Emacs's Unicode mode got confused before my 2003-08-05
21511         checkin.
21512
21513 2003-08-08  Paul Eggert  <eggert@twinsun.com>
21514
21515         * m4/extensions.m4: New file.
21516         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
21517         Require gl_USE_SYSTEM_EXTENSIONS.
21518         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
21519         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
21520
21521 2003-08-08  Paul Eggert  <eggert@twinsun.com>
21522
21523         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
21524         * modules/extensions, modules/gnu-source: New files.
21525         * modules/timespec, modules/unlocked-io: Depend on extensions.
21526
21527 2003-08-07  Paul Eggert  <eggert@twinsun.com>
21528
21529         * modules/restrict: New file.
21530         * MODULES.html.sh (func_all_modules): Add restrict.
21531         * modules/regex: Depend on restrict.
21532
21533 2003-08-07  Paul Eggert  <eggert@twinsun.com>
21534
21535         * m4/restrict.m4: New file.
21536         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
21537
21538 2003-08-07  Bruno Haible  <bruno@clisp.org>
21539
21540         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
21541         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
21542
21543 2003-08-07  Bruno Haible  <bruno@clisp.org>
21544
21545         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
21546         makes the module 'getndelim2' compatible with the module 'getline'.
21547
21548 2003-08-05  Paul Eggert  <eggert@twinsun.com>
21549
21550         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
21551         byte with "\201" to avoid glitches when editing that source file
21552         with multi-gnome-terminal.
21553
21554 2003-08-05  Paul Eggert  <eggert@twinsun.com>
21555
21556         * lib/bumpalloc.h: Remove.
21557
21558 2003-08-05  Paul Eggert  <eggert@twinsun.com>
21559
21560         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
21561         * modules/bumpalloc: Remove.
21562
21563 2003-08-04  Paul Eggert  <eggert@twinsun.com>
21564
21565         * lib/getloadavg.c: Change copyright notice and spacing to conform to
21566         GNU coding style.
21567
21568         Merge from coreutils.
21569         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
21570         1. From glibc.
21571         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
21572         from Karl Berry, implemented by Jim Meyering.
21573         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
21574         from Dmitry V. Levin.
21575         Remove anachronistic cast of xrealloc.
21576         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
21577         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
21578         type. Otherwise, it wouldn't compile with at least /bin/cc on
21579         ymp-cray-unicos9.0.2.X.
21580         Combine two mostly-identical uses of alloca into one.
21581         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
21582
21583 2003-08-04  Dave Love  <d.love@dl.ac.uk>
21584
21585         [From Emacs.]
21586
21587         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
21588         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
21589         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
21590         obsolete NLIST_NAME_UNION.
21591         [__GNU__]: Undef BSD and FSCALE.
21592         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
21593
21594 2003-08-03  Paul Eggert  <eggert@twinsun.com>
21595
21596         * lib/stdbool_.h (_Bool): Make it signed char, instead of
21597         an enum type, so that it's guaranteed to promote to int.  See:
21598         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
21599
21600 2003-08-03  Karl Berry  <karl@gnu.org>
21601
21602         * config/depcomp: update from automake.
21603
21604 2003-07-31  Paul Eggert  <eggert@twinsun.com>
21605
21606         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
21607         (strerror): Don't assume that a printable int fits in 14 bytes.
21608
21609 2003-07-31  Bruno Haible  <bruno@clisp.org>
21610
21611         * modules/getpass-gnu: New file.
21612         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
21613
21614 2003-07-31  Bruno Haible  <bruno@clisp.org>
21615
21616         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
21617
21618 2003-07-24  Karl Berry  <karl@gnu.org>
21619
21620         * config/missing: update from automake.
21621
21622 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
21623             Bruno Haible  <bruno@clisp.org>
21624
21625         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
21626         * lib/getline.c (getline, getdelim): Likewise.
21627         Remove _GNU_SOURCE define; now it's defined in config.h through
21628         m4/getline.m4.
21629
21630 2003-07-23  Karl Berry  <karl@gnu.org>
21631
21632         * config/config.sub: update from prep.
21633
21634 2003-07-22  Paul Eggert  <eggert@twinsun.com>
21635
21636         * modules/xalloc (Depends-on): Add exitfail.
21637         * modules/xmemcoll: Likewise.
21638
21639 2003-07-22  Paul Eggert  <eggert@twinsun.com>
21640
21641         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
21642         over-parenthesization in macros.
21643
21644         Sync with coreutils.
21645
21646         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
21647         required by C99.
21648
21649         Use `exit_failure' for xalloc and xmemcoll instead of their own
21650         private exit-failure variables.
21651         * lib/xalloc.h (xalloc_exit_failure): Remove.
21652         * lib/xmalloc.c: Likewise.  Include exitfail.h.
21653         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
21654         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
21655         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
21656         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
21657
21658 2003-07-20  Jim Meyering  <jim@meyering.net>
21659
21660         * modules/closeout (Depends-on): Add exitfail.
21661         Suggestion from Bruno Haible.
21662
21663 2003-07-19  Karl Berry  <karl@gnu.org>
21664
21665         * config/config.sub: update from prep.
21666
21667 2003-07-18  Paul Eggert  <eggert@twinsun.com>
21668
21669         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
21670         Remove.
21671         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
21672         to test that it can stand by itself.  Include "exitfail.h".
21673         Clients should set exit_failure instead.
21674         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
21675
21676 2003-07-18  Bruno Haible  <bruno@clisp.org>
21677
21678         * modules/getndelim2: New file.
21679         * modules/getline: Share files with module getndelim2.
21680         * modules/getnline: Depend on getndelim2 instead of sharing files with
21681         it. Add getnline.c to lib_SOURCES.
21682         * MODULES.html.sh (func_all_modules): Add getndelim2.
21683
21684 2003-07-18  Bruno Haible  <bruno@clisp.org>
21685
21686         * m4/getndelim2.m4: New file.
21687         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
21688         invoke gl_PREREQ_GETNDELIM2.
21689         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
21690         gl_PREREQ_GETNDELIM2.
21691         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
21692         gl_GETNDELIM2.
21693
21694 2003-07-18  Bruno Haible  <bruno@clisp.org>
21695
21696         * lib/getndelim2.h: New file.
21697         * lib/getndelim2.c: Make into a module of its own. Include config.h,
21698         getndelim2.h.
21699         (getndelim2): Make non-static. Change return type to ssize_t.
21700         * lib/getline.h: Change argument names.
21701         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
21702         * lib/getnline.c: Include getndelim2.h.
21703
21704 2003-07-18  Andreas Schwab  <schwab@suse.de>
21705
21706         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
21707
21708 2003-07-17  Karl Berry  <karl@gnu.org>
21709
21710         * config/config.sub: update from prep.
21711
21712 2003-07-17  Bruno Haible  <bruno@clisp.org>
21713
21714         * modules/getnline: New file.
21715         * modules/getline: Add lib/getndelim2.c to source file list.
21716         * MODULES.html.sh (func_all_modules): Add getnline.
21717
21718 2003-07-17  Bruno Haible  <bruno@clisp.org>
21719
21720         * m4/getnline.m4: New file.
21721
21722 2003-07-17  Bruno Haible  <bruno@clisp.org>
21723
21724         * m4/Makefile.am.in: Remove file.
21725         * m4/Makefile.am: Remove file.
21726         * m4/Makefile.in: Remove file.
21727
21728 2003-07-17  Bruno Haible  <bruno@clisp.org>
21729
21730         * lib/getnline.h: New file.
21731         * lib/getnline.c: New file.
21732         * lib/getndelim2.c: New file, extracted from getline.c.
21733         (getndelim2): Renamed from getdelim2, with added nmax argument.
21734         * lib/getline.c: Include getndelim2.c.
21735         (getdelim2): Moved out to getndelim2.c.
21736         (getline, getdelim): Update.
21737
21738 2003-07-17  Bruno Haible  <bruno@clisp.org>
21739
21740         * lib/Makefile.am: Remove file.
21741         * lib/Makefile.in: Remove file.
21742
21743 2003-07-17  Bruno Haible  <bruno@clisp.org>
21744
21745         * configure.in: Remove file.
21746         * Makefile.in: Remove file.
21747
21748 2003-07-17  Bruno Haible  <bruno@clisp.org>
21749
21750         * MODULES.html.sh: Put the </BODY> right before </HTML>.
21751
21752 2003-07-16  Karl Berry  <karl@gnu.org>
21753
21754         * config/srclist-update: was running fixlicense twice, which caused
21755                 texinfo.tex to be nullified for some reason.  Simplify,
21756                 $gplsrc is no longer needed as far as I can see?
21757
21758 2003-07-16  Jim Meyering  <jim@meyering.net>
21759
21760         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
21761
21762 2003-07-15  Paul Eggert  <eggert@twinsun.com>
21763
21764         * config/srclist.txt: Get the following files from gettext-runtime/intl
21765         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
21766         ref-del.sin.  From Bruno Haible.
21767         * config/srclist-update (fixfile): Change grep pattern again, since the
21768         previous fix didn't work (there was another trailing $).  Use
21769         '[$]' to escape the $s.
21770
21771 2003-07-15  Karl Berry  <karl@gnu.org>
21772
21773         * lib/vasnprintf.c: update from gettext.
21774
21775 2003-07-15  Karl Berry  <karl@gnu.org>
21776
21777         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
21778         gets expanded when surrounded by '$'.
21779
21780 2003-07-15  Jim Meyering  <jim@meyering.net>
21781
21782         * modules/save-cwd: Don't depend on error.  From Derek Price.
21783
21784 2003-07-15  Jim Meyering  <jim@meyering.net>
21785
21786         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
21787
21788 2003-07-14  Simon Josefsson  <jas@extundo.com>
21789
21790         * modules/mempcpy: New file.
21791         * MODULES.html.sh (func_all_modules): Add mempcpy.
21792
21793 2003-07-14  Simon Josefsson  <jas@extundo.com>
21794
21795         * m4/mempcpy.m4: New file.
21796
21797 2003-07-14  Simon Josefsson  <jas@extundo.com>
21798
21799         * lib/mempcpy.h: New file.
21800         * lib/mempcpy.c: New file.
21801
21802 2003-07-14  Paul Eggert  <eggert@twinsun.com>
21803
21804         * modules/getdate, modules/posixtm: Depend on mktime.
21805
21806 2003-07-14  Paul Eggert  <eggert@twinsun.com>
21807
21808         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
21809         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
21810         unicodeio.c, unicodeio.h, unlocked-io.h:
21811         Switch from LGPL to GPL.
21812
21813 2003-07-14  Paul Eggert  <eggert@twinsun.com>
21814
21815         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
21816         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
21817         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
21818         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
21819         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
21820         updated automatically by ../config/srclist-update.  This changes
21821         their license from LPGL to GPL.
21822
21823 2003-07-14  Paul Eggert  <eggert@twinsun.com>
21824
21825         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
21826         assumed to refer to the root of the most recent stable gettext version.
21827         * config/srclistvars.sh: Add defaults for eggert.
21828         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
21829         Match "This program" as well as "The program".  This is needed
21830         for gettext.
21831
21832 2003-07-14  Jim Meyering  <jim@meyering.net>
21833
21834         Don't emit diagnostics.  Let callers do that.
21835         * lib/save-cwd.c: Don't include "error.h".
21836         (save_cwd): Don't call error.  Ensure that errno is valid
21837         when returning nonzero.
21838
21839         * lib/save-cwd.h (restore_cwd): Update prototype.
21840         * lib/save-cwd.c (restore_cwd): Remove two parameters.
21841         Simplify.  Don't call error upon failure.  Let callers do that.
21842         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
21843         when auditing is enabled.  But don't bother updating the #if.
21844
21845 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
21846
21847         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
21848         it breaks C++ compilation.
21849         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
21850
21851 2003-07-10  Simon Josefsson  <jas@extundo.com>
21852
21853         * modules/strchrnul (Makefile.am): Add strchrnul.h.
21854
21855 2003-07-10  Jim Meyering  <jim@meyering.net>
21856
21857         * m4/clock_time.m4: Remove trailing blank.
21858         * m4/intmax_t.m4: Likewise.
21859
21860 2003-07-10  Jim Meyering  <jim@meyering.net>
21861
21862         * lib/vasnprintf.c: Remove trailing blanks.
21863         Make cpp indentation consistent.
21864
21865 2003-07-09  Paul Eggert  <eggert@twinsun.com>
21866
21867         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
21868         posixver.c, strftime.c, strnlen.c, strverscmp.c:
21869         Switch from LGPL to GPL.
21870
21871 2003-07-09  Paul Eggert  <eggert@twinsun.com>
21872
21873         * config/srclist.txt: Sort sublists.  Add
21874         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
21875         that differ from gnulib for one reason or another; we'd like this list
21876         to be smaller but for now let's document what we have.
21877
21878 2003-07-08  Paul Eggert  <eggert@twinsun.com>
21879
21880         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
21881         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
21882         and sweeter "eval x=$x".
21883         * config/srclist.txt: Get lib/argp* from glibc.
21884
21885 2003-07-07  Paul Eggert  <eggert@twinsun.com>
21886
21887         * lib/mktime.c: Fix some boundary cases and remove need for floating
21888         point.
21889
21890         Issue a compile-time diagnostic if time_t is floating point, or if
21891         two's complement arithmetic is not in effect, or if arithmetic
21892         right shift does not propagate the sign.  These assumptions were
21893         all in the original code but they weren't checked.
21894
21895         (TIME_T_MIDPOINT, verify): New macros.
21896         (__isleap): Remove; it has integer overflow problems.
21897         (leapyear): New function, without those problems.
21898         (ydhms_tm_diff): Remove; splitting into two parts.
21899         (ydhms_diff): New function, containing the arithmetic part of
21900         the old ydhms_tm_diff function.  Issue a compile-time
21901         diagnostic if we are not using C99 integer division.
21902         Avoid casts when possible.
21903         (guess_time_tm): New function, containing the checking part of
21904         the old ydhms_tm_diff function.  Return the new value, rather than
21905         the difference between it and the old.  Accept a new argument T
21906         so that *T specifies the old value.  Check for overflow in the result.
21907
21908         (__mktime_internal): Use a time_t offset, not a long int offset.
21909         This undoes the 2003-06-04 change, which is no longer needed now
21910         that we have better overflow checking.
21911         (localtime_offset): Likewise.
21912
21913         (__mktime_internal): Avoid harmful overflow on hosts where time_t
21914         and long are 64-bit but int is only 32-bit.
21915         (ydhms_diff): Use long int to store year1 and yday1.
21916         Issue a compile-time diagnostic if long int is not wide enough.
21917
21918         (__mktime_internal): Use long int to store adjusted year and yday.
21919         Use plain C rather than preprocessor commands, if that doesn't
21920         affect efficiency.
21921         Check for overflow (and try to repair) after each probe
21922         rather than checking only at the very end.  This avoids some bugs
21923         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
21924         does not equal GMT offset at maximum time).
21925         Use integer to check for overflow rather than floating point; this
21926         is more portable to non-IEEE hosts, and is a tad faster.
21927         When we detect that we are oscillating between two values,
21928         don't check whether tm_isdst has the requested value, since
21929         we already know the answer.  When tm_isdst has the wrong value,
21930         use a different heuristic to find the right one, based on the
21931         extreme values actually observed in practice in tz2003a,
21932         rather than the (overly optimistic) "previous 3 calendar quarters".
21933
21934         (not_equal_tm, print_tm, check_result): Use "const T" rather than
21935         "T const" to accommodate glibc style.
21936         (check_result): Use less-confusing report format.  "long" -> "long int.
21937         (main): Likewise.
21938         Don't loop if the iteration overflows time_t.
21939         Allow a negative step in the iteration.
21940
21941 2003-07-06  Karl Berry  <karl@gnu.org>
21942
21943         * config/depcomp: update from automake.
21944         * config/config.sub: update from prep.
21945
21946 2003-07-03  Karl Berry  <karl@gnu.org>
21947
21948         * config/config.guess: update from prep.
21949
21950 2003-07-01  Paul Eggert  <eggert@twinsun.com>
21951
21952         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
21953         xreadlink.c now includes it unconditionally.
21954
21955 2003-07-01  Paul Eggert  <eggert@twinsun.com>
21956
21957         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
21958         having it depend on HAVE_SYS_TYPES_H.
21959
21960 2003-07-01  Bruno Haible  <bruno@clisp.org>
21961
21962         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
21963         <sys/types.h> should be sufficient.
21964         Reported by Paul Eggert.
21965
21966 2003-06-26  Karl Berry  <karl@gnu.org>
21967
21968         * config/depcomp: update from automake.
21969
21970 2003-06-26  Bruno Haible  <bruno@clisp.org>
21971
21972         * modules/human: Depend on module stdbool.
21973
21974 2003-06-25  Bruno Haible  <bruno@clisp.org>
21975
21976         * modules/readlink: New file.
21977         * modules/xreadlink: Depend on it.
21978         * MODULES.html.sh (func_all_modules): Add readlink.
21979
21980 2003-06-25  Bruno Haible  <bruno@clisp.org>
21981
21982         * m4/readlink.m4: New file.
21983
21984 2003-06-25  Bruno Haible  <bruno@clisp.org>
21985
21986         * lib/readlink.c: New file.
21987
21988 2003-06-22  Karl Berry  <karl@gnu.org>
21989
21990         * config/srclist.txt: update mkinstalldirs from automake.
21991         * config/mkinstalldirs: update.
21992
21993 2003-06-22  Bruno Haible  <bruno@clisp.org>
21994
21995         Portability to mingw32.
21996         * m4/ssize_t.m4: New file, from GNU gettext.
21997         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
21998         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
21999
22000 2003-06-22  Bruno Haible  <bruno@clisp.org>
22001
22002         * modules/safe-read: Add m4/ssize_t.m4.
22003         * modules/xreadlink: Add m4/ssize_t.m4.
22004
22005 2003-06-20  Bruno Haible  <bruno@clisp.org>
22006
22007         Assume C89, so PARAMS isn't needed.
22008         * lib/unicodeio.h (PARAMS): Remove.
22009         * lib/unicodeio.c: Don't use PARAMS.
22010
22011 2003-06-18  Karl Berry  <karl@gnu.org>
22012
22013         * config/config.{guess,sub}: update from prep.
22014
22015 2003-06-18  Jim Meyering  <jim@meyering.net>
22016
22017         Merge changes from coreutils.
22018         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
22019         Remove explicit declarations of xmalloc and realloc.
22020         Include xalloc.h.
22021         (read_utmp): Remove anachronistic cast of xmalloc.
22022
22023 2003-06-17  Paul Eggert  <eggert@twinsun.com>
22024
22025         Assume C89, so PARAMS isn't needed.
22026         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
22027         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
22028         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
22029         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
22030         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
22031         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
22032         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
22033         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
22034         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
22035         lib/xstrtod.h, lib/xstrtol.h: Likewise.
22036         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
22037         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
22038         no longer needed. Anyway, config.h should always be included before any
22039         other file.
22040
22041 2003-06-11  Simon Josefsson  <jas@extundo.com>
22042
22043         * modules/sysexits: New file.
22044         * MODULES.html.sh (func_all_modules): Add sysexits.
22045
22046 2003-06-11  Simon Josefsson  <jas@extundo.com>
22047
22048         * lib/sysexit_.h: New file.
22049
22050 2003-06-11  Derek Price  <derek@ximbiot.com>
22051
22052         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
22053         necessary.
22054
22055 2003-06-11  Bruno Haible  <bruno@clisp.org>
22056
22057         * m4/sysexits.m4: New file.
22058
22059 2003-06-10  Simon Josefsson  <jas@extundo.com>
22060
22061         * lib/argp.h: New file, from glibc.
22062         * lib/argp-ba.c: New file, from glibc.
22063         * lib/argp-eexst.c: New file, from glibc.
22064         * lib/argp-fmtstream.c: New file, from glibc.
22065         * lib/argp-fmtstream.h: New file, from glibc.
22066         * lib/argp-fs-xinl.c: New file, from glibc.
22067         * lib/argp-help.c: New file, from glibc.
22068         * lib/argp-namefrob.h: New file, from glibc.
22069         * lib/argp-parse.c: New file, from glibc.
22070         * lib/argp-pv.c: New file, from glibc.
22071         * lib/argp-pvh.c: New file, from glibc.
22072         * lib/argp-xinl.c: New file, from glibc.
22073
22074 2003-06-10  Simon Josefsson  <jas@extundo.com>
22075
22076         * modules/strchrnul: New file.
22077
22078 2003-06-10  Simon Josefsson  <jas@extundo.com>
22079
22080         * modules/argp: New file.
22081
22082 2003-06-10  Simon Josefsson  <jas@extundo.com>
22083
22084         * m4/strchrnul.m4: New file.
22085
22086 2003-06-10  Simon Josefsson  <jas@extundo.com>
22087
22088         * lib/strchrnul.h: New file.
22089         * lib/strchrnul.c: New file.
22090
22091 2003-06-10  Bruno Haible  <bruno@clisp.org>
22092
22093         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
22094
22095 2003-06-07  Karl Berry  <karl@gnu.org>
22096
22097         * config/config.{guess,sub}: update from prep.
22098
22099 2003-06-07  Jim Meyering  <jim@meyering.net>
22100
22101         * modules/strtod: Use $(...) notation, not @...@ for
22102         AC_REPLACE'd variables.
22103         * modules/localcharset: Likewise.
22104
22105 2003-06-07  Jim Meyering  <jim@meyering.net>
22106
22107         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
22108         in place of my name in the copyright comment.
22109         Remove definition and uses of __P.
22110
22111         From coreutils.
22112         * lib/stat.c: Don't declare xmalloc explicitly.
22113         Instead, include "xalloc.h".
22114         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
22115         xrealloc, and xcalloc return values.
22116         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
22117         Improve comment.
22118         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
22119
22120 2003-06-07  Bruno Haible  <bruno@clisp.org>
22121
22122         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
22123         avoid AC_CONFIG_LINKS.
22124         * modules/fnmatch (Makefile.am): Use explicit creation rule for
22125         fnmatch.h, to avoid AC_CONFIG_LINKS.
22126         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
22127
22128 2003-06-07  Bruno Haible  <bruno@clisp.org>
22129
22130         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
22131         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
22132         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22133         directory.
22134         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
22135         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22136         directory.
22137
22138 2003-06-06  Jim Meyering  <jim@meyering.net>
22139
22140         Merge from coreutils.
22141         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
22142         Consolidate declarations and initializations of *_base* locals.
22143
22144         Merge from coreutils.
22145         This avoids a core dump on systems without GNU putenv,
22146         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
22147         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
22148         (unsetenv): New static function, from GNU libc.
22149         (rpl_putenv): Use it.
22150
22151         * lib/modechange.c: Remove trailing blanks.
22152
22153         Merge from coreutils.
22154         * lib/fsusage.c: Remove declaration of statfs.
22155         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
22156
22157         * lib/posixtm.c: Include <stdbool.h> unconditionally.
22158
22159 2003-06-06  Jim Meyering  <jim@meyering.net>
22160
22161         * lib/stdbool_.h: Renamed from stdbool.h.in.
22162
22163 2003-06-06  Jim Meyering  <jim@meyering.net>
22164             Bruno Haible  <bruno@clisp.org>
22165
22166         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
22167         Adjust Makefile.am snippet not to redirect directly to target.
22168         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
22169
22170 2003-06-05  Paul Eggert  <eggert@twinsun.com>
22171
22172         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
22173         mismatch, look in future quarters as well as past.  This fixes a
22174         bug when processing fall-backwards gaps immediately after a long
22175         period of daylight-saving time.
22176
22177         * lib/mktime.c: Assume freestanding C89 or better.
22178         (HAVE_LIMITS_H): Remove.  Assume it's 1.
22179         (__P): Remove; not used.
22180         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
22181         (mktime, not_equal_tm, print_tm, check_result,
22182         main): Use prototypes.  Use const * where appropriate.
22183         (main): Fix typo in testing code that uncovered by above changes.
22184         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
22185
22186 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22187
22188         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
22189         locale.h, localeconv.  This merges changes from coreutils.
22190
22191         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
22192         It can be removed after the next Autoconf is released.
22193         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
22194         needed.
22195
22196 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22197
22198         * lib/mktime.c: Fix Debian bug 177940
22199         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
22200         (localtime_offset): Now long int, not time_t, because we want it
22201         to be guaranteed to be signed.  All uses changed.
22202         (__mktime_internal): If overflow would occur when adding offset,
22203         don't add it.
22204
22205         Merge 'human' changes from coreutils.  Rewrite to support
22206         locale-specific notations like thousands separators.
22207         * lib/human.c: Simplify authorship notice.
22208         Include human.h immediately after config.h.
22209         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
22210         <limits.h>: Do not include, since human.h does.
22211         (SIZE_MAX, UINTMAX_MAX): New macros.
22212         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
22213         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
22214         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
22215         (power_letter): Renamed from suffixes.
22216         (generate_suffix_backwards): Remove.
22217         (adjust_value): Now takes int style (because of human.h changes)
22218         and long double value (for greater precision on some platforms).
22219         (group_number): New function.
22220         (human_readable): Use it.  Use integer options, not enum.
22221         Put the options before the sizes in the arg list.
22222         Support all the new options.
22223         The old human_readable function has been removed;
22224         use inttostr.h instead.
22225         (human_readable, default_block_size, humblock):
22226         Use uintmax_t, not int, for block sizes.
22227         (human_readable_inexact, block_size_types): Remove.
22228         (block_size_opts): New constant.
22229         (human_options): Renamed from human_block_size, with new signature
22230         that allows block sizes up to UINTMAX_MAX.  All callers changed.
22231         * lib/human.h: Add copyright and authorship notice.
22232         Include <limits.h> and <stdbool.h> unconditionally.
22233         (PARAMS): Remove.  All uses removed.
22234         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
22235         (enum human_inexact_style): Remove tag; now a nameless enum.
22236         (human_floor, human_ceiling, human_round_to_even): Now have
22237         values 2, 0, 1 rather than -1, 1, 0.
22238         (human_group_digits, human_suppress_point_zero, human_autoscale,
22239         human_base_1024, human_SI, human_B): New constants.
22240         (human_readable_inexact, human_block_size): Remove.
22241         (human_readable): Size args are now uintmax_t, not int.
22242         (human_options): New decl.
22243
22244         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
22245         unnecessary now that we assume C89 or better.  This change
22246         imported from coreutils.
22247
22248         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22249         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
22250         in the 2003-05-30 sync from glibc.
22251
22252         .h files should stand alone, but we shouldn't include <sys/types.h>
22253         if we can get away with just <stddef.h>.
22254
22255         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
22256         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
22257         rather than <sys/types.h>, as we merely need size_t.
22258         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
22259         to get size_t.
22260         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
22261         Include <stdio.h>, to get FILE.
22262         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
22263         memcasecmp.h has included <stddef.h> and all we need is size_t.
22264         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
22265         our interface, instead of including <sys/types.h>
22266
22267 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22268
22269         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
22270         now, as glibc mktime is buggy on non-glibc systems.
22271
22272 2003-06-03  Karl Berry  <karl@gnu.org>
22273
22274         * config/config.sub: update from prep.
22275
22276 2003-06-02  Paul Eggert  <eggert@twinsun.com>
22277
22278         [from coreutils]
22279         Fix some minor time-related bugs with POSIX time arguments.
22280         Some valid time stamps were being rejected (notably -1, and
22281         time stamps before 1900 on 64-bit hosts).  And some invalid
22282         time stamps were being accepted, e.g. September 31.
22283
22284         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
22285         that we can return (time_t) -1 successfully.
22286         * lib/posixtm.c: Likewise.
22287         [HAVE_STDBOOL_H]: Include <stdbool.h>.
22288         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
22289         (t): Remove static var.
22290         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
22291         of static var.  All uses changed.
22292         (year): Do not reject years before 1900; they can occur with
22293         64-bit time_t.
22294         (posix_time_parse): Do not check for out-of-range components;
22295         that is now the caller's responsibility, since our checks were
22296         only approximations.
22297         (posixtime): Use mktime to check for out-of-range components,
22298         since it knows them exactly.
22299         If mktime returns (time_t) -1, check whether an error actually occurred
22300         by invoking localtime on -1.
22301         (main) [TEST_POSIXTIME]: Check for input data errors, and report
22302         posixtime failures better.
22303         Improve the test data (in comments only).
22304
22305 2003-06-02  Karl Berry  <karl@gnu.org>
22306
22307         * config/mkinstalldirs (version): new variable.
22308         (--version): new option.
22309         (usage): improve message.
22310
22311 2003-05-30  Karl Berry  <karl@gnu.org>
22312
22313         * lib/mktime.c: update from libc.
22314
22315 2003-05-30  Bruno Haible  <bruno@clisp.org>
22316
22317         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
22318         * config/config.rpath: Upgrade to gettext-0.12.1.
22319
22320 2003-05-30  Bruno Haible  <bruno@clisp.org>
22321
22322         * m4/gettext.m4: Upgrade to gettext-0.12.1.
22323         * m4/nls.m4: New file, from gettext-0.12.1.
22324         * m4/po.m4: New file, from gettext-0.12.1.
22325         * m4/progtest.m4: Upgrade to gettext-0.12.1.
22326
22327 2003-05-30  Bruno Haible  <bruno@clisp.org>
22328
22329         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
22330         * lib/localcharset.h: Likewise.
22331         * lib/localcharset.c: Likewise.
22332
22333 2003-05-29  Karl Berry  <karl@gnu.org>
22334
22335         * config/config.rpath: update from gettext.
22336
22337 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22338
22339         Assume the headers required for C89 freestanding compilers.
22340         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
22341         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
22342         * m4/human.m4 (gl_HUMAN): Likewise.
22343         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
22344         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
22345         * m4/userspec.m4 (gl_USERSPEC): Likewise.
22346         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
22347         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
22348         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
22349
22350 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22351
22352         Assume the headers required for C89 freestanding compilers.
22353         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
22354         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
22355         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
22356         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
22357         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
22358         define, since <limits.h> is guaranteed to do that.
22359         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
22360         * lib/exclude.c: Include <stdbool.h> unconditionally.
22361         * lib/tempname.c: Include <stddef.h> unconditionally.
22362         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
22363         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
22364         <stddef.h> does that.
22365         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
22366         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
22367         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
22368         needed.
22369         * lib/xstrtol.c: Likewise.
22370         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
22371         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
22372
22373         * lib/addext.c (addext): Use assignment rather than cast, to avoid
22374         warnings on some platforms.
22375
22376         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22377         arbitrarily.
22378
22379 2003-05-26  Jim Meyering  <jim@meyering.net>
22380
22381         Merge in a change from coreutils:
22382         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
22383         that is guaranteed to be `no'.  Use `no_such_member' to indicate
22384         that condition, rather than `-1' which is slightly misleading.
22385         Change the name of the cache variable to have the gl_ prefix.
22386         Prompted by a patch from Richard Dawe for DJGPP.
22387
22388 2003-05-24  Karl Berry  <karl@gnu.org>
22389
22390         * config/config.guess: update from prep.
22391
22392 2003-05-22  Karl Berry  <karl@gnu.org>
22393
22394         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
22395
22396 2003-05-20  Karl Berry  <karl@gnu.org>
22397
22398         * config/config.guess: update from prep.
22399
22400 2003-05-18  Karl Berry  <karl@gnu.org>
22401
22402         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
22403         might actually be set by the user.
22404
22405         * config/depcomp, install-sh, mdate-sh: update from automake.
22406
22407 2003-05-17  Bruno Haible  <bruno@clisp.org>
22408
22409         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
22410         invalid expansion for AC_EGREP_CPP.
22411         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
22412         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
22413         Suggested by Akim Demaille <akim@epita.fr> in
22414         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
22415
22416 2003-05-12  Jim Meyering  <jim@meyering.net>
22417
22418         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
22419         the space-padded-by-default conversion specifiers, %e, %k, %l.
22420
22421 2003-05-12  Bruno Haible  <bruno@clisp.org>
22422
22423         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
22424         the string is longer than 4 KB.
22425
22426 2003-05-11  Karl Berry  <karl@gnu.org>
22427
22428         * config/config.{guess,sub}: update from prep.
22429
22430 2003-05-09  Bruno Haible  <bruno@clisp.org>
22431
22432         * modules/error: Add m4/strerror_r.m4 to file list.
22433
22434 2003-05-03  Bruno Haible  <bruno@clisp.org>
22435
22436         Upgrade to Unicode-4.0.
22437         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
22438         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
22439         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
22440         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
22441         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
22442         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
22443         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
22444         Change width of U+E0100..U+E01EF from 1 to 0.
22445
22446 2003-04-25  Jim Meyering  <jim@meyering.net>
22447
22448         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
22449         of type size_t, not int.
22450
22451 2003-04-25  Bruno Haible  <bruno@clisp.org>
22452
22453         * lib/copy-file.c: Include <stddef.h>, for size_t.
22454
22455 2003-04-21  Paul Eggert  <eggert@twinsun.com>
22456
22457         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
22458         code which expansion is under static control.  Patch imported from
22459         Akim Demaille's patch to Bison; see
22460         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
22461
22462 2003-04-14  Bruno Haible  <bruno@clisp.org>
22463
22464         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
22465
22466 2003-04-11  Jim Meyering  <jim@meyering.net>
22467
22468         Merge changes from Coreutils.
22469
22470         2003-03-22  Jim Meyering  <jim@meyering.net>
22471
22472         * lib/strftime.c (widen): Cast alloca return value to proper type.
22473
22474         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
22475
22476         From GNU libc.
22477         * lib/strftime.c (my_strftime): Handle very large width
22478         specifications for numeric values correctly.  Improve checks for
22479         overflow.
22480
22481         2003-01-19  Jim Meyering  <jim@meyering.net>
22482
22483         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
22484         definitions.
22485         (nl_get_alt_digit) [! defined my_strftime]: Define.
22486         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
22487         _nl_get_alt_digit and _nl_get_walt_digit.
22488
22489         * lib/strftime.c (my_strftime): Merge in locale-related changes from
22490         libc. These changes have no effect outside of _LIBC.
22491
22492 2003-04-10  Bruno Haible  <bruno@clisp.org>
22493
22494         * modules/findprog: New file.
22495         * MODULES.html.sh (func_all_modules): Add it.
22496
22497 2003-04-10  Bruno Haible  <bruno@clisp.org>
22498
22499         * m4/findprog.m4: New file.
22500         * m4/eaccess.m4: New file.
22501
22502 2003-04-10  Bruno Haible  <bruno@clisp.org>
22503
22504         * lib/findprog.h: New file, from GNU gettext.
22505         * lib/findprog.c: New file, from GNU gettext.
22506
22507 2003-04-05  Jim Meyering  <jim@meyering.net>
22508
22509         Merge changes from Coreutils.
22510
22511         * lib/exclude.h (PARAMS): Remove definition and uses.
22512         * lib/exclude.c: Remove uses of `PARAMS'.
22513
22514         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
22515         Add test-cases for DOS filenames. Declare program_name.
22516         (main): Set up program_name.  Patch by Rich Dawe.
22517
22518         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
22519         error from mntctl.
22520         Use mntctl's return value to drive the entry-processing loop, since
22521         we can't rely on the value of the vmt_length member in the last
22522         entry.  On some systems doing so could result in exhausting
22523         virtual memory.  Based in part on a patch from Mike Jetzer.
22524
22525 2003-04-04  Bruno Haible  <bruno@clisp.org>
22526
22527         * modules/linebreak: New file.
22528         * MODULES.html.sh (func_all_modules): Add it.
22529
22530 2003-04-04  Bruno Haible  <bruno@clisp.org>
22531
22532         * m4/linebreak.m4: New file.
22533
22534 2003-04-04  Bruno Haible  <bruno@clisp.org>
22535
22536         * lib/linebreak.h: New file, from GNU gettext.
22537         * lib/linebreak.c: New file, from GNU gettext with slight
22538         modifications.
22539         * lib/lbrkprop.h: New file, from GNU gettext.
22540
22541 2003-04-03  Bruno Haible  <bruno@clisp.org>
22542
22543         * modules/utf8-ucs4: New file.
22544         * modules/utf16-ucs4: New file.
22545         * modules/ucs4-utf8: New file.
22546         * modules/ucs4-utf16: New file.
22547         * MODULES.html.sh (func_all_modules): Add them.
22548
22549 2003-04-03  Bruno Haible  <bruno@clisp.org>
22550
22551         * m4/utf-ucs4.m4: New file.
22552         * m4/ucs4-utf.m4: New file.
22553
22554 2003-04-03  Bruno Haible  <bruno@clisp.org>
22555
22556         * lib/utf8-ucs4.h: New file, from GNU gettext.
22557         * lib/utf16-ucs4.h: New file, from GNU gettext.
22558         * lib/ucs4-utf8.h: New file, from GNU gettext.
22559         * lib/ucs4-utf16.h: New file, from GNU gettext.
22560
22561 2003-04-02  Bruno Haible  <bruno@clisp.org>
22562
22563         * modules/binary-io: New file.
22564         * MODULES.html.sh (func_all_modules): Add it.
22565
22566 2003-04-02  Bruno Haible  <bruno@clisp.org>
22567
22568         * lib/binary-io.h: New file, from GNU gettext.
22569
22570 2003-04-01  Bruno Haible  <bruno@clisp.org>
22571
22572         * modules/pathname: New file.
22573         * MODULES.html.sh (func_all_modules): Add it.
22574
22575 2003-04-01  Bruno Haible  <bruno@clisp.org>
22576
22577         * lib/pathname.h: New file, from GNU gettext.
22578         * lib/concatpath.c: New file, from GNU gettext.
22579
22580 2003-03-30  Bruno Haible  <bruno@clisp.org>
22581
22582         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
22583
22584 2003-03-30  Bruno Haible  <bruno@clisp.org>
22585
22586         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
22587         function chown() doesn't exist.
22588
22589 2003-03-28  Bruno Haible  <bruno@clisp.org>
22590
22591         * modules/copy-file: New file.
22592         * MODULES.html.sh (func_all_modules): Add it.
22593
22594 2003-03-28  Bruno Haible  <bruno@clisp.org>
22595
22596         * m4/copy-file.m4: New file.
22597
22598 2003-03-28  Bruno Haible  <bruno@clisp.org>
22599
22600         * lib/copy-file.h: New file, from GNU gettext.
22601         * lib/copy-file.c: New file, from GNU gettext.
22602
22603 2003-03-18  Jim Meyering  <jim@meyering.net>
22604
22605         * lib/quote.c (quote_n): Fix typo in comment.
22606
22607 2003-03-18  Bruno Haible  <bruno@clisp.org>
22608
22609         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
22610         checking.
22611         * m4/onceonly_2_57.m4: Likewise.
22612
22613 2003-03-17  Bruno Haible  <bruno@clisp.org>
22614
22615         * m4/onceonly.m4: Require autoconf 2.54 or newer.
22616         (m4_quote): Remove macro.
22617         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
22618
22619 2003-03-14  Jim Meyering  <jim@meyering.net>
22620
22621         Merge changes from Coreutils.
22622         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
22623         to be const, in order to avoid warnings.
22624         (obstack_room): Likewise.
22625         (obstack_empty_p): Likewise.
22626
22627 2003-03-14  Bruno Haible  <bruno@clisp.org>
22628
22629         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
22630         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
22631
22632 2003-03-13  Paul Eggert  <eggert@twinsun.com>
22633
22634         Merge changes from Bison.
22635         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
22636         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
22637         when compiling Bison 1.875's `bitset bset = obstack_alloc
22638         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
22639         * lib/hash.c: Include <stdbool.h> unconditionally.
22640
22641 2003-03-13  Paul Eggert  <eggert@twinsun.com>
22642
22643         * m4/onceonly.m4 (m4_quote): New macro.
22644         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
22645         Quote AC_FOREACH variable-expansions properly.
22646
22647 2003-03-13  Paul Eggert  <eggert@twinsun.com>
22648
22649         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
22650
22651 2003-03-09  Paul Eggert  <eggert@twinsun.com>
22652
22653         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
22654         Reported by Bruce Becker; see:
22655         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
22656
22657 2003-03-03  Paul Eggert  <eggert@twinsun.com>
22658             Bruno Haible  <bruno@clisp.org>
22659
22660         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
22661         Reported by John Hughes, see
22662         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
22663
22664 2003-02-20  Bruno Haible  <bruno@clisp.org>
22665
22666         * MODULES.html.sh (func_all_modules): Add poll.
22667
22668 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
22669
22670         * modules/poll: New file.
22671
22672 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
22673
22674         * lib/poll_.h: New file.
22675         * lib/poll.c: New file.
22676
22677 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
22678
22679         * m4/poll.m4: New file.
22680
22681 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
22682
22683         * modules/mathl: New file.
22684
22685 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
22686
22687         * lib/mathl.h: New file.
22688         * lib/acosl.c: New file.
22689         * lib/asinl.c: New file.
22690         * lib/atanl.c: New file.
22691         * lib/ceill.c: New file.
22692         * lib/cosl.c: New file.
22693         * lib/expl.c: New file.
22694         * lib/floorl.c: New file.
22695         * lib/frexpl.c: New file.
22696         * lib/ldexpl.c: New file.
22697         * lib/logl.c: New file.
22698         * lib/sincosl.c: New file.
22699         * lib/sinl.c: New file.
22700         * lib/sqrtl.c: New file.
22701         * lib/tanl.c: New file.
22702         * lib/trigl.c: New file.
22703         * lib/trigl.h: New file.
22704
22705 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
22706
22707         * m4/mathl.m4: New file.
22708
22709 2003-02-18  Bruno Haible  <bruno@clisp.org>
22710
22711         * MODULES.html.sh (func_all_modules): Add mathl.
22712
22713 2003-02-17  Bruno Haible  <bruno@clisp.org>
22714
22715         * modules/mkdtemp: New module.
22716         * MODULES.html.sh (func_all_modules): Add it.
22717
22718 2003-02-17  Bruno Haible  <bruno@clisp.org>
22719
22720         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
22721
22722 2003-02-17  Bruno Haible  <bruno@clisp.org>
22723
22724         * lib/mkdtemp.h: New file, from GNU gettext.
22725         * lib/mkdtemp.c: New file, from GNU gettext.
22726
22727 2003-02-02  Jim Meyering  <jim@meyering.net>
22728
22729         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
22730         e.g. glibc-2.2.93.
22731
22732 2003-01-31  Bruno Haible  <bruno@clisp.org>
22733
22734         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
22735         'rpl_rename'.
22736         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
22737         'rpl_strnlen'.
22738         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
22739         'rpl_strtod'.
22740         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
22741         'rpl_utime'.
22742
22743 2003-01-31  Bruno Haible  <bruno@clisp.org>
22744
22745         * lib/rename.c: #undef rename before defining rpl_rename.
22746         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
22747
22748 2003-01-30  Bruno Haible  <bruno@clisp.org>
22749
22750         * modules/vasnprintf, modules/vasprintf: New modules.
22751         * MODULES.html.sh (func_all_modules): Add them.
22752
22753 2003-01-30  Bruno Haible  <bruno@clisp.org>
22754
22755         * m4/signed.m4: New file, from GNU gettext.
22756         * m4/longdouble.m4: New file, from GNU gettext.
22757         * m4/wchar_t.m4: New file, from GNU gettext.
22758         * m4/wint_t.m4: New file, from GNU gettext.
22759         * m4/vasnprintf.m4: New file.
22760         * m4/vasprintf.m4: New file.
22761
22762 2003-01-30  Bruno Haible  <bruno@clisp.org>
22763
22764         * lib/printf-args.h: New file, from GNU gettext.
22765         * lib/printf-args.c: New file, from GNU gettext.
22766         * lib/printf-parse.h: New file, from GNU gettext.
22767         * lib/printf-parse.c: New file, from GNU gettext.
22768         * lib/vasnprintf.h: New file, from GNU gettext.
22769         * lib/vasnprintf.c: New file, from GNU gettext.
22770         * lib/asnprintf.c: New file, from GNU gettext.
22771         * lib/vasprintf.h: New file, from GNU gettext with modifications.
22772         * lib/vasprintf.c: New file, from GNU gettext.
22773         * lib/asprintf.c: New file, from GNU gettext.
22774
22775 2003-01-29  Bruno Haible  <bruno@clisp.org>
22776
22777         * modules/stpncpy: New module.
22778         * MODULES.html.sh (func_all_modules): Add it.
22779
22780 2003-01-29  Bruno Haible  <bruno@clisp.org>
22781
22782         * m4/stpncpy.m4: New file.
22783
22784 2003-01-29  Bruno Haible  <bruno@clisp.org>
22785
22786         * lib/stpncpy.h: New file, from GNU gettext with modifications.
22787         * lib/stpncpy.c: New file, from GNU gettext with modifications.
22788
22789 2003-01-28  Bruno Haible  <bruno@clisp.org>
22790
22791         * modules/c-ctype: New module.
22792         * MODULES.html.sh (func_all_modules): Add it.
22793
22794 2003-01-28  Bruno Haible  <bruno@clisp.org>
22795
22796         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
22797         Paul Eggert.
22798         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
22799         Paul Eggert.
22800
22801 2003-01-27  Bruno Haible  <bruno@clisp.org>
22802
22803         * modules/xsetenv: New module.
22804         * MODULES.html.sh (func_all_modules): Add it.
22805
22806 2003-01-27  Bruno Haible  <bruno@clisp.org>
22807
22808         * lib/xsetenv.h: New file, from GNU gettext.
22809         * lib/xsetenv.c: New file, from GNU gettext.
22810
22811 2003-01-23  Jim Meyering  <jim@meyering.net>
22812
22813         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
22814         from working on systems without dirfd (at least Irix and OSF1/Tru64).
22815
22816 2003-01-23  Bruno Haible  <bruno@clisp.org>
22817
22818         * modules/minmax: New module.
22819         * MODULES.html.sh (func_all_modules): Add it.
22820
22821 2003-01-23  Bruno Haible  <bruno@clisp.org>
22822
22823         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
22824         Eggert.
22825
22826 2003-01-22  Bruno Haible  <bruno@clisp.org>
22827
22828         * modules/exit: New module.
22829         * MODULES.html.sh (func_all_modules): Add it.
22830
22831 2003-01-22  Bruno Haible  <bruno@clisp.org>
22832
22833         * lib/exit.h: New file, from GNU gettext.
22834
22835 2003-01-19  Bruno Haible  <bruno@clisp.org>
22836
22837         * gnulib-tool: Recognize option --extract-maintainer.
22838         (func_get_maintainer): New function.
22839         * modules/*: Add Maintainer entry.
22840
22841 2003-01-16  Jim Meyering  <jim@meyering.net>
22842
22843         * m4/regex.m4: The `regex' struct is both input and output.
22844         Initialize it before each use.  Patch by Tim Waugh.
22845
22846 2003-01-16  Bruno Haible  <bruno@clisp.org>
22847
22848         * MODULES.html.sh: Add a table of contents. Add the module name as
22849         leftmost column. Add hyperlinks.
22850
22851 2003-01-15  Bruno Haible  <bruno@clisp.org>
22852
22853         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
22854
22855 2003-01-15  Bruno Haible  <bruno@clisp.org>
22856
22857         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
22858         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
22859         suffix.
22860
22861 2003-01-15  Bruno Haible  <bruno@clisp.org>
22862
22863         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
22864
22865 2003-01-15  Bruno Haible  <bruno@clisp.org>
22866
22867         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
22868         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
22869
22870 2003-01-14  Jim Meyering  <jim@meyering.net>
22871
22872         * lib/same.c (same_name): Tweak a comment.
22873
22874 2003-01-14  Bruno Haible  <bruno@clisp.org>
22875
22876         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
22877         when a string comparison is sufficient.
22878
22879 2003-01-14  Bruno Haible  <bruno@clisp.org>
22880
22881         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
22882         'unsigned int'.
22883
22884 2003-01-14  Bruno Haible  <bruno@clisp.org>
22885
22886         * lib/hash-pjw.c: Add comment about low quality of this function.
22887
22888 2003-01-13  Bruno Haible  <bruno@clisp.org>
22889
22890         * modules/stpcpy: Distribute lib/stpcpy.h.
22891         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
22892
22893 2003-01-13  Bruno Haible  <bruno@clisp.org>
22894
22895         * modules/*: Add a description.
22896         * modules/strpbrk: Fix Makefile.am snippet.
22897         * modules/strtoimax: Fix dependencies.
22898         * modules/strtoumax: Likewise.
22899
22900 2003-01-13  Bruno Haible  <bruno@clisp.org>
22901
22902         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
22903         * modules/alloca (Makefile.am): All object files depend on alloca.h.
22904         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
22905
22906 2003-01-13  Bruno Haible  <bruno@clisp.org>
22907
22908         * gnulib-tool (func_create_testdir): Store config/* files in the main
22909         directory.
22910         * config.rpath: Move to ...
22911         * config/config.rpath: ... here.
22912         * modules/gettext: Contains config/config.rpath, not config.rpath.
22913         * modules/iconv: Likewise.
22914
22915 2003-01-12  Paul Eggert  <eggert@twinsun.com>
22916
22917         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
22918         to avoid collisions with libcurses and libreadline.
22919
22920         * m4/getstr.m4: Remove.
22921         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
22922
22923 2003-01-12  Paul Eggert  <eggert@twinsun.com>
22924
22925         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
22926         to avoid collisions with libcurses and libreadline.
22927
22928         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
22929         * lib/getstr.h, getstr.c: Remove.
22930         * lib/getline.c: Include "getline.h", to check interface.
22931         Move body of old getstr.c here: this defines MIN_CHUNK and
22932         declares getdelim2, which is renamed from getstr.
22933         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
22934
22935         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
22936         All uses changed.
22937         * lib/linebuffer.h: Likewise.
22938         (readline): Remove backward-compatibility macro.
22939
22940 2003-01-12  Paul Eggert  <eggert@twinsun.com>
22941
22942         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
22943         to avoid collisions with libcurses and libreadline.
22944         * getstr: Remove.
22945         * MODULES.html.sh: Remove getstr.
22946         * modules/getline: Depend on unlocked-io, not getstr.
22947
22948 2003-01-12  Jim Meyering  <jim@meyering.net>
22949
22950         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
22951
22952 2003-01-10  Bruno Haible  <bruno@clisp.org>
22953
22954         * modules/alloca: Change Makefile.am requirements. Simplify Include
22955         requirements. Add lib/alloca_.h to file list.
22956
22957 2003-01-10  Bruno Haible  <bruno@clisp.org>
22958
22959         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
22960
22961 2003-01-10  Bruno Haible  <bruno@clisp.org>
22962
22963         * lib/alloca_.h: New file.
22964         * lib/getdate.y: Unconditionally include alloca.h.
22965         * lib/makepath.c: Likewise.
22966         * lib/setenv.c: Likewise.
22967         * lib/userspec.c: Likewise.
22968
22969 2003-01-09  Karl Berry  <karl@gnu.org>
22970
22971         * MODULES.html.sh: include `dirname $0` in PATH, to find
22972         gnulib-tool.
22973
22974 2003-01-09  Bruno Haible  <bruno@clisp.org>
22975
22976         * modules/stdbool: Change configure.ac, Makefile.am requirements.
22977         Simplify Include requirements. Add lib/stdbool.h.in to file list.
22978
22979 2003-01-09  Bruno Haible  <bruno@clisp.org>
22980
22981         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
22982
22983 2003-01-09  Bruno Haible  <bruno@clisp.org>
22984
22985         * lib/stdbool.h.in: New file.
22986
22987 2003-01-09  Bruno Haible  <bruno@clisp.org>
22988
22989         * gnulib-tool (func_all_modules): Ignore files ending in ~.
22990         * MODULES.html.sh: Likewise.
22991
22992 2003-01-08  Jim Meyering  <jim@meyering.net>
22993
22994         * lib/full-write.c: Undefine and define-away `const' after inclusion
22995         of errno.h, not before.  Suggestion from Bruno Haible.
22996
22997 2003-01-08  Bruno Haible  <bruno@clisp.org>
22998
22999         * modules/full-read: Depend on full-write.
23000
23001 2003-01-08  Bruno Haible  <bruno@clisp.org>
23002
23003         * lib/safe-read.c: Include specification header first, to ensure its
23004         selfcontainedness.
23005         * lib/full-write.c: Likewise.
23006
23007 2003-01-07  Jim Meyering  <jim@meyering.net>
23008
23009         * lib/full-write.c: Rework so that it may serve to define full_read,
23010         too.
23011         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
23012
23013 2003-01-07  Bruno Haible  <bruno@clisp.org>
23014
23015         * lib/strtoimax.c: Include <stdint.h> as an alternative to
23016         <inttypes.h>.
23017         * lib/xstrtol.h: Likewise.
23018         * lib/xstrtoimax.c: Likewise.
23019         * lib/xstrtoumax.c: Likewise.
23020         * lib/human.h: Likewise.
23021
23022         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
23023         on systems that have <inttypes.h> but not <stdint.h>.
23024
23025 2003-01-07  Bruno Haible  <bruno@clisp.org>
23026
23027         * MODULES.html.sh: Add copyright notice.
23028         (missed_files): Omit CVS directory entries.
23029         (func_module): Make it work with sed-3.02.
23030         * MODULES.txt: Remove file.
23031
23032 2003-01-06  Jim Meyering  <jim@meyering.net>
23033
23034         * lib/version-etc.c: Update year in translatable copyright string.
23035
23036 2003-01-03  Karl Berry  <karl@gnu.org>
23037
23038         * config/config.{guess,sub}: update from prep.
23039
23040 2003-01-02  Karl Berry  <karl@gnu.org>
23041
23042         * doc/COPYING.DOC: belatedly updated to 1.2.
23043
23044 2003-01-01  Karl Berry  <karl@gnu.org>
23045
23046         * gnulib-tool (func_verify_module): report module name $module in
23047         error message, not $1.
23048         * gnulib-tool (create-testdir): don't complain if destdir couldn't
23049         be created, only if it doesn't exist.
23050         * gnulib-tool (last_checkin_date): don't expand the $Date here.
23051
23052 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23053
23054         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
23055
23056 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23057
23058         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
23059         memcmp if strcoll doesn't work.
23060
23061 2002-12-31  Bruno Haible  <bruno@clisp.org>
23062
23063         * lib/utime.c (utime_null): No need to call ftruncate if the file was
23064         nonempty.
23065
23066 2002-12-31  Bruno Haible  <bruno@clisp.org>
23067
23068         * lib/memcoll.c (STRCOLL): New macro.
23069         (memcoll): Use it.
23070
23071 2002-12-31  Bruno Haible  <bruno@clisp.org>
23072
23073         * lib/localcharset.h: New file.
23074         * lib/localcharset.c: Include it.
23075         * lib/unicodeio.c: Likewise.
23076
23077 2002-12-31  Bruno Haible  <bruno@clisp.org>
23078
23079         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
23080         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
23081
23082 2002-12-31  Bruno Haible  <bruno@clisp.org>
23083
23084         * lib/getline.h: Include <stddef.h>, for size_t.
23085
23086         * lib/unicodeio.h: Include <stddef.h>, for size_t.
23087         * lib/unicodeio.c: Don't include <stddef.h>.
23088
23089 2002-12-31  Bruno Haible  <bruno@clisp.org>
23090
23091         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
23092         HAVE_TM_ZONE.
23093
23094 2002-12-24  Karl Berry  <karl@gnu.org>
23095
23096         * config/config.guess: update from prep.
23097
23098 2002-12-24  Bruno Haible  <bruno@clisp.org>
23099
23100         General infrasructure.
23101         * m4/README: Rewritten.
23102         * m4/onceonly.m4: New file.
23103         * m4/onceonly_2_57.m4: New file.
23104
23105         Module atexit.
23106         * m4/atexit.m4: New file.
23107
23108         Module strtod.
23109         * m4/strtod.m4: New file.
23110
23111         Module strtol.
23112         * m4/strtol.m4: New file.
23113
23114         Module strtoul.
23115         * m4/strtoul.m4: New file.
23116
23117         Module memchr.
23118         * m4/memchr.m4: New file.
23119
23120         Module memcmp.
23121         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
23122         (jm_FUNC_MEMCMP): Invoke it.
23123
23124         Module memcpy.
23125         * m4/memcpy.m4: New file.
23126
23127         Module memmove.
23128         * m4/memmove.m4: New file.
23129
23130         Module memset.
23131         * m4/memset.m4: New file.
23132
23133         Module strcspn.
23134         * m4/strcspn.m4: New file.
23135
23136         Module strpbrk.
23137         * m4/strpbrk.m4: New file.
23138
23139         Module strstr.
23140         * m4/strstr.m4: New file.
23141
23142         Module strerror.
23143         * m4/strerror.m4: New file.
23144
23145         Module mktime.
23146         * m4/mktime.m4: Renamed from jm-mktime.m4.
23147         (gl_PREREQ_MKTIME): New macro.
23148         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
23149
23150         Module malloc.
23151         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
23152         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
23153         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
23154
23155         Module realloc.
23156         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
23157         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
23158         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
23159
23160         Module strftime.
23161         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
23162         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
23163         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
23164         gl_TM_GMTOFF.
23165         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
23166
23167         Module xalloc.
23168         * m4/xalloc.m4: New file.
23169
23170         Module alloca.
23171         * m4/alloca.m4: New file.
23172
23173         Module putenv.
23174         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
23175         (jm_FUNC_PUTENV): Invoke it.
23176
23177         Module setenv.
23178         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
23179         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
23180         when invoked twice.
23181         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
23182         gt_FUNC_SETENV.
23183
23184         Module memrchr.
23185         * m4/memrchr.m4: New file.
23186
23187         Module stpcpy.
23188         * m4/stpcpy.m4: New file.
23189
23190         Module strcase.
23191         * m4/strcase.m4: New file.
23192
23193         Module strdup.
23194         * m4/strdup.m4: New file.
23195
23196         Module strnlen.
23197         * m4/strnlen.m4: New file.
23198
23199         Module strndup.
23200         * m4/strndup.m4: New file.
23201
23202         Module xstrtod.
23203         * m4/xstrtod.m4: New file.
23204
23205         Module xstrtol.
23206         * m4/xstrtol.m4: New file.
23207
23208         Module getdate.
23209         * m4/getdate.m4: New file.
23210
23211         Module unlocked-io.
23212         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
23213         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
23214         * m4/jm-glibc-io.m4n: Remove file.
23215
23216         Module long-options.
23217         * m4/long-options.m4: New file.
23218
23219         Module md5.
23220         * m4/md5.m4: New file.
23221
23222         Module sha.
23223         * m4/sha.m4: New file.
23224
23225         Module getstr.
23226         * m4/getstr.m4: New file.
23227
23228         Module getline.
23229         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
23230         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
23231         <sys/types.h>, for size_t. Use the function name gnu_getline, not
23232         simply getline. Infoke gl_PREREQ_GETLINE.
23233
23234         Module obstack.
23235         * m4/obstack.m4: New file.
23236
23237         Module hash.
23238         * m4/hash.m4: New file.
23239
23240         Module readtokens.
23241         * m4/readtokens.m4: New file.
23242
23243         Module strverscmp.
23244         * m4/strverscmp.m4: New file.
23245
23246         Module stdbool.
23247         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
23248         OSF/1.
23249
23250         Module strtoll.
23251         * m4/strtoll.m4: New file.
23252
23253         Module strtoull.
23254         * m4/strtoull.m4: New file.
23255
23256         Module strtoimax.
23257         * m4/strtoimax.m4: New file.
23258
23259         Module strtoumax.
23260         * m4/strtoumax.m4: New file.
23261
23262         Module xstrtoimax.
23263         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
23264         jm_AC_PREREQ_XSTRTOIMAX.
23265         Moved the strtol prerequisites to strtol.m4.
23266         Moved the strtoll prerequisites to strtoll.m4.
23267         Moved the strtoimax prerequisites to strtoimax.m4.
23268
23269         Module xstrtoumax.
23270         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
23271         jm_AC_PREREQ_XSTRTOUMAX.
23272         Moved the strtoul prerequisites to strtoul.m4.
23273         Moved the strtoull prerequisites to strtoull.m4.
23274         Moved the strtoumax prerequisites to strtoumax.m4.
23275
23276         Module chown.
23277         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
23278         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
23279
23280         Module dup2.
23281         * m4/dup2.m4: New file.
23282
23283         Module ftruncate.
23284         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
23285         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
23286
23287         Module getgroups.
23288         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
23289         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
23290
23291         Module gettimeofday.
23292         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
23293         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
23294         gl_PREREQ_GETTIMEOFDAY.
23295
23296         Module mkdir.
23297         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
23298         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
23299
23300         Module mkstemp.
23301         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
23302         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
23303         jm_AC_TYPE_UINTMAX_T.
23304         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
23305
23306         Module stat.
23307         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
23308         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
23309
23310         Module lstat.
23311         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
23312         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
23313
23314         Module timespec.
23315         * m4/timespec.m4 (gl_TIMESPEC): New macro.
23316         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
23317         * m4/st_mtim.m4: Indentation.
23318
23319         Module nanosleep.
23320         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
23321         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
23322         gl_PREREQ_NANOSLEEP.
23323
23324         Module regex.
23325         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
23326         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
23327         (gl_REGEX): New macro.
23328
23329         Module rename.
23330         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
23331         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
23332
23333         Module rmdir.
23334         * m4/rmdir.m4: New file.
23335
23336         Module utime.
23337         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
23338         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
23339         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
23340
23341         Module dirname.
23342         * m4/dirname.m4: New file.
23343
23344         Module getopt.
23345         * m4/getopt.m4: New file.
23346
23347         Module unistd-safer.
23348         * m4/unistd-safer.m4: New file.
23349
23350         Module fnmatch.
23351         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
23352         declaration.
23353         (gl_PREREQ_FNMATCH_EXTRA): New macro.
23354         (gl_FUNC_FNMATCH_POSIX): New macro.
23355         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
23356         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
23357         simply fnmatch.
23358
23359         Module exclude.
23360         * m4/exclude.m4: New file.
23361
23362         Module human.
23363         * m4/human.m4: New file.
23364
23365         Module acl.
23366         * m4/acl.m4: Nop.
23367
23368         Module backupfile.
23369         * m4/backupfile.m4: New file.
23370         * m4/d-ino.m4: Indentation.
23371
23372         Module fsusage.
23373         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
23374         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
23375         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
23376
23377         Module dirfd.
23378         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
23379         requirements.
23380
23381         Module euidaccess.
23382         * m4/euidaccess.m4: New file.
23383
23384         Module file-type.
23385         * m4/file-type.m4: New file.
23386
23387         Module fileblocks.
23388         * m4/fileblocks.m4: New file.
23389
23390         Module filemode.
23391         * m4/filemode.m4: New file.
23392
23393         Module isdir.
23394         * m4/isdir.m4: New file.
23395
23396         Module lchown.
23397         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
23398         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
23399
23400         Module makepath.
23401         * m4/makepath.m4: New file.
23402
23403         Module modechange.
23404         * m4/modechange.m4: New file.
23405
23406         Module mountlist.
23407         * m4/mountlist.m4: New file.
23408         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
23409         Indentation.
23410
23411         Module path-concat.
23412         * m4/path-concat.m4: New file.
23413
23414         Module pathmax.
23415         * m4/pathmax.m4: New file.
23416
23417         Module same.
23418         * m4/same.m4: New file.
23419
23420         Module save-cwd.
23421         * m4/save-cwd.m4: New file.
23422
23423         Module savedir.
23424         * m4/savedir.m4: New file.
23425
23426         Module xgetcwd.
23427         * m4/xgetcwd.m4: New file.
23428         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
23429
23430         Module xreadlink.
23431         * m4/xreadlink.m4: New file.
23432
23433         Module safe-read.
23434         * m4/safe-read.m4: New file.
23435
23436         Module safe-write.
23437         * m4/safe-write.m4: New file.
23438
23439         Module closeout.
23440         * m4/closeout.m4: New file.
23441
23442         Module stdio-safer.
23443         * m4/stdio-safer.m4: New file.
23444
23445         Module getpass.
23446         * m4/getpass.m4: New file.
23447
23448         Module getugroups.
23449         * m4/getugroups.m4: New file.
23450
23451         Module group-member.
23452         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
23453         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
23454
23455         Module idcache.
23456         * m4/idcache.m4: New file.
23457
23458         Module userspec.
23459         * m4/userspec.m4: New file.
23460
23461         Module gettime.
23462         * m4/clock_time.m4: New file.
23463         * m4/gettime.m4: New file.
23464
23465         Module settime.
23466         * m4/settime.m4: New file.
23467
23468         Module posixtm.
23469         * m4/posixtm.m4: New file.
23470
23471         Module gethostname.
23472         * m4/gethostname.m4: New file.
23473
23474         Module canon-host.
23475         * m4/canon-host.m4: New file.
23476
23477         Module gettext.
23478         * m4/codeset.m4: New file, from gettext-0.11.5.
23479         * m4/gettext.m4: New file, from gettext-0.11.5.
23480         * m4/glibc21.m4: New file, from gettext-0.11.5.
23481         * m4/iconv.m4: New file, from gettext-0.11.5.
23482         * m4/intdiv0.m4: New file, from gettext-0.11.5.
23483         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
23484         * m4/inttypes.m4: New file, from gettext-0.11.5.
23485         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
23486         * m4/isc-posix.m4: New file, from gettext-0.11.5.
23487         * m4/lcmessage.m4: New file, from gettext-0.11.5.
23488         * m4/lib-ld.m4: New file, from gettext-0.11.5.
23489         * m4/lib-link.m4: New file, from gettext-0.11.5.
23490         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
23491         * m4/progtest.m4: New file, from gettext-0.11.5.
23492         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
23493         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
23494         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
23495
23496         Module localcharset.
23497         * m4/localcharset.m4: New file.
23498
23499         Module hard-locale.
23500         * m4/hard-locale.m4: New file.
23501
23502         Module mbswidth.
23503         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
23504         onceonly macros.
23505         * m4/mbrtowc.m4: Add comment.
23506
23507         Module memcasecmp.
23508         * m4/memcasecmp.m4: New file.
23509
23510         Module memcoll.
23511         * m4/memcoll.m4: New file.
23512
23513         Module unicodeio.
23514         * m4/unicodeio.m4: New file.
23515
23516         Module rpmatch.
23517         * m4/rpmatch.m4: New file.
23518
23519         Module yesno.
23520         * m4/yesno.m4: New file.
23521
23522         Module exitfail.
23523         * m4/exitfail.m4: New file.
23524
23525         Module c-stack.
23526         * m4/c-stack.m4 (gl_C_STACK): New macro.
23527         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
23528
23529         Module error.
23530         * m4/error.m4 (gl_ERROR): New macro.
23531         (jm_PREREQ_ERROR): Use onceonly macros.
23532
23533         Module fatal.
23534         * m4/fatal.m4: New file.
23535
23536         Module getloadavg.
23537         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
23538         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
23539
23540         Module getpagesize.
23541         * m4/getpagesize.m4: New file.
23542
23543         Module getusershell.
23544         * m4/getusershell.m4: New file.
23545
23546         Module physmem.
23547         * m4/physmem.m4: New file.
23548
23549         Module posixver.
23550         * m4/posixver.m4: New file.
23551
23552         Module quotearg.
23553         * m4/quotearg.m4: New file.
23554
23555         Module quote.
23556         * m4/quote.m4: New file.
23557
23558         Module readutmp.
23559         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
23560
23561         Module sig2str.
23562         * m4/sig2str.m4: New file.
23563
23564         Other.
23565         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
23566         ulonglong.m4.
23567         * m4/intmax_t.m4: New file.
23568         * m4/d-type.m4: Indentation.
23569         * m4/jm-macros.m4: Update.
23570         * m4/prereq.m4 (jm_PREREQ): Update.
23571         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
23572         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
23573         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
23574         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
23575         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
23576         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
23577         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
23578         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
23579         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
23580         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
23581         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
23582         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
23583         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
23584         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
23585         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
23586         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
23587         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
23588         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
23589         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
23590
23591 2002-12-24  Bruno Haible  <bruno@clisp.org>
23592
23593         * MODULES.txt: Update according to m4/ changes.
23594
23595         Module gettext.
23596         * config.rpath: New file, from gettext-0.11.5.
23597
23598         * modules/*: New module descriptions.
23599         * gnulib-tool: New file.
23600         * MODULES.html.sh: New file.
23601
23602 2002-12-21  Karl Berry  <karl@gnu.org>
23603
23604         * doc/fdl.texi: update to version 1.2.
23605
23606 2002-12-19  Karl Berry  <karl@gnu.org>
23607
23608         * config/config.guess: update from prep.
23609
23610 2002-12-18  Bruno Haible  <bruno@clisp.org>
23611
23612         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
23613         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
23614
23615 2002-12-17  Bruno Haible  <bruno@clisp.org>
23616
23617         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
23618         stdlib.h, string.h.
23619
23620 2002-12-17  Bruno Haible  <bruno@clisp.org>
23621
23622         * lib/canon-host.c (strdup): Remove unused declaration.
23623
23624         * lib/fsusage.c: Include full_read.h.
23625         (get_fs_usage): Use full_read instead of safe_read.
23626
23627         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
23628
23629 2002-12-12  Karl Berry  <karl@gnu.org>
23630
23631         * config/config.guess: update from prep.
23632
23633 2002-12-11  Bruno Haible  <bruno@clisp.org>
23634
23635         * m4/setenv.m4: New file, from gettext-0.11.5.
23636
23637 2002-12-11  Bruno Haible  <bruno@clisp.org>
23638
23639         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
23640         not unsetenv().
23641         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
23642         modifications:
23643
23644         2002-12-11  Bruno Haible  <bruno@clisp.org>
23645
23646                 * setenv.c (alloca): Fall back to malloc.
23647                 (freea): New macro.
23648                 (setenv): Use freea() to free memory allocated with alloca().
23649
23650         2002-11-13  Bruno Haible  <bruno@clisp.org>
23651
23652                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
23653                 function declarations.
23654                 * unsetenv.c (unsetenv): Likewise.
23655
23656         2002-03-04  Bruno Haible  <bruno@clisp.org>
23657
23658                 Portability to AIX 4.3.3.
23659                 * unsetenv.c: New file, extracted from setenv.c.
23660                 * setenv.c: Move the unsetenv() function to unsetenv.c.
23661
23662         2001-12-20  Bruno Haible  <bruno@clisp.org>
23663
23664                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
23665                 use malloc instead. For SunOS 4.
23666
23667         2001-12-11  Bruno Haible  <bruno@clisp.org>
23668
23669                 * setenv.c: Declare alloca.
23670                 (compar_fn_t): New typedef.
23671                 (KNOWN_VALUE, STORE_VALUE): Use it.
23672
23673         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
23674         setenv.h.
23675
23676 2002-12-10  Paul Eggert  <eggert@twinsun.com>
23677
23678         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
23679         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
23680         Choose values that are less likely to collide with system fnmatch
23681         options.
23682         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
23683         defined (e.g., a pure POSIX system).
23684         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
23685         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
23686
23687 2002-12-06  Paul Eggert  <eggert@twinsun.com>
23688
23689         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
23690         a pain in practice to deal with generated m4 files.  This change
23691         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
23692
23693         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
23694         and jm-glibc-io.m4, as they are no longer a special case.
23695         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
23696         kludge and the auto-generation stuff.  Check only whether the
23697         functions are declared, not whether they exist, since older hosts
23698         that don't declare the functions can't use the optimization anyway.
23699
23700 2002-12-06  Jim Meyering  <jim@meyering.net>
23701
23702         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
23703
23704         Merge in changes from libc's misc/error.c, in preparation
23705         for the merge of gnulib's changes back into libc.
23706
23707         * lib/error.c (_): Define only if not already defined.
23708         Move definition to follow all #include directives.
23709         Include unlocked-io.h only if !_LIBC.
23710         [_LIBC]: Include <libio/libioP.h>.
23711         [USE_IN_LIBIO]: Include <libio/iolibio.h>
23712         (fflush): Tweak definition to use INTUSE.
23713         (putc): Define.
23714
23715 2002-12-05  Paul Eggert  <eggert@twinsun.com>
23716
23717         * lib/alloca.c [defined emacs]: Include "lisp.h".
23718         (xalloc_die) [defined emacs]: New macro.
23719         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
23720         [! defined emacs]: Include <xalloc.h>.
23721         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
23722         (pointer): Typedef to POINTER_TYPE *.
23723         (malloc): Remove decl; we now always use xmalloc.
23724         (alloca): Use old-style definition, since Emacs needs this.
23725         Check for arithmetic overflow when computing combined size.
23726
23727 2002-12-04  Paul Eggert  <eggert@twinsun.com>
23728
23729         Do not generate unlocked-io.h automatically, since it's easier to
23730         maintain it by hand.
23731
23732         * lib/unlocked-io.h: New file, from GNU diffutils,
23733         but with proper copyright notice and attribution.
23734         * lib/gen-uio: Remove.
23735         * lib/Makefile.am: Add copyright notice.
23736         (libfetish_a_SOURCES): Add unlocked-io.h.
23737         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
23738         (DISTCLEANFILES, io_functions): Remove macros.
23739         (EXTRA_DIST): Remove gen_uio.
23740         (unlocked-io.h): Remove rule.
23741
23742 2002-12-04  Jim Meyering  <jim@meyering.net>
23743
23744         Reflect the fact that stat.c and lstat.c are no longer generated.
23745         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
23746         (DISTCLEANFILES): Likewise.
23747         (EXTRA_DIST): Likewise.
23748         (all_local): Don't depend on stat.c or lstat.c.
23749         (stat.c, lstat.c): Remove rules.
23750         (EXTRA_DIST): Remove xstat.in.
23751
23752         * lib/xstat.in: Remove file.  Contents moved into stat.c.
23753         * lib/stat.c: New file.  Contents mostly from xstat.in.
23754         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
23755         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
23756
23757         * lib/safe-read.c: Rework so that it may serve to define safe_write,
23758         too.
23759         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
23760
23761 2002-12-03  Jim Meyering  <jim@meyering.net>
23762
23763         * lib/safe-read.c, safe-write.c: Change variable names and comments,
23764         but not semantics, to minimize the differences between these two files.
23765         (safe_read): Change comment to mention SAFE_READ_ERROR.
23766
23767         * lib/safe-read.c (IS_EINTR): Define.
23768         (safe_read): Use IS_EINTR in place of in-function cpp directives.
23769
23770 2002-12-02  Jim Meyering  <jim@meyering.net>
23771
23772         * lib/safe-read.c (EINTR): Define.
23773         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23774         (INT_MAX): Provide fallback.
23775         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
23776
23777         * lib/safe-read.h (SAFE_READ_ERROR): Define.
23778
23779 2002-12-02  Bruno Haible  <bruno@clisp.org>
23780
23781         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
23782         Define, taken from safe-read.c.
23783         (INT_MAX): Provide fallback.
23784         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
23785         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
23786
23787         * lib/safe-read.c (EINTR): Remove definition.
23788         (safe_read): Don't use EINTR if it is absent.
23789
23790 2002-12-01  Jim Meyering  <jim@meyering.net>
23791
23792         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
23793         zero.
23794         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
23795
23796 2002-11-27  Paul Eggert  <eggert@twinsun.com>
23797
23798         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
23799         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
23800         with `if (! (value < limit)) abort ();', for readability.
23801
23802 2002-11-26  Karl Berry  <karl@gnu.org>
23803
23804         * lib/strdup.c: copy from libc again, with jim's ok.
23805         * lib/.cppi-disable: re-add strdup.c
23806
23807 2002-11-25  Karl Berry  <karl@gnu.org>
23808
23809         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
23810         instead of "strtol.c".
23811
23812 2002-11-25  Karl Berry  <karl@gnu.org>
23813
23814         * config/install-sh: update from automake for variable quoting, $0 in
23815         error msgs, etc.
23816
23817         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
23818         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
23819         entry.
23820
23821 2002-11-25  Jim Meyering  <jim@meyering.net>
23822
23823         * lib/mktime.c: Sync from libc, now that it has the latest fix.
23824
23825 2002-11-24  Karl Berry  <karl@gnu.org>
23826
23827         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
23828         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
23829
23830 2002-11-24  Jim Meyering  <jim@meyering.net>
23831
23832         Update from coreutils:
23833
23834         * lib/mktime.c: Merge in changes from libc.
23835
23836         Avoid a link-time failure on some Linux systems.
23837         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
23838         (otherwise).
23839         (__mon_yday): Declare with the STATIC attribute.
23840         (__mktime_internal): Likewise.
23841         Based on a report from Greg Schafer.
23842
23843 2002-11-23  Jim Meyering  <jim@meyering.net>
23844
23845         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
23846         Use `unsigned', not `int', as type of index.
23847
23848         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
23849
23850         * lib/fsusage.c: Remove unneeded parentheses around operands of
23851         `defined'.
23852
23853 2002-11-22  Paul Eggert  <eggert@twinsun.com>
23854
23855         * lib/quotearg.h: Allow multiple inclusion by surrounding with
23856         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
23857         so that we can be included first.
23858         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
23859         * lib/quotearg.c: Include quotearg.h immediately after config.h.
23860         No need to include stddef.h or sys/types.h any more.
23861         Surround local include files with "", not "<>".
23862         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
23863         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
23864         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
23865         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
23866         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
23867         (ISPRINT): Remove; no longer needed now that we assume C89.
23868
23869         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
23870         Preserve errno.
23871
23872         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
23873         quotearg_char): Use SIZE_MAX rather than
23874         (size_t) -1 when we are talking about "infinity".
23875
23876         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
23877
23878 2002-11-22  Paul Eggert  <eggert@twinsun.com>
23879
23880         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
23881         hint that one should use `if (! x) abort ();' rather than `assert
23882         (x);', and anyway it's one less thing to worry about configuring.
23883         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
23884         hash_rehash, hash_insert): Use abort rather than assert.
23885
23886 2002-11-22  Bruno Haible  <bruno@clisp.org>
23887
23888         * lib/safe-read.h: Assume C89. Add comments.
23889         (safe_read): Change return type to size_t.
23890         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
23891         byte counts > SSIZE_MAX correctly.
23892         * lib/safe-write.h: New file.
23893         * lib/safe-write.c: New file.
23894         * lib/full-read.h: New file.
23895         * lib/full-read.c: New file.
23896         * lib/full-write.h: Assume C89. Add comments.
23897         * lib/full-write.c: Include safe-write.h.
23898         (full_write): Rewritten to use safe_write.
23899         Suggested by Jim Meyering and Paul Eggert.
23900
23901 2002-11-21  Jim Meyering  <jim@meyering.net>
23902
23903         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
23904
23905         Merge in changes from the coreutils.
23906
23907         2002-09-25  Paul Eggert  <eggert@twinsun.com>
23908         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
23909         <stdint.h>.
23910         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
23911         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
23912         int.  Work more efficiently if X is the same width as uintmax_t.
23913         Do not compare X to -1, to avoid bogus compiler warning.
23914         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
23915         Don't assume that f_frsize and f_bsize are the same type.
23916
23917         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
23918         warning on FreeBSD.
23919
23920         * lib/makepath.c (make_path): Restore umask *before* creating the final
23921         component.
23922         (make_path): Minor reformatting.
23923
23924         * lib/xmalloc.c: Adjust to work with new autoconf macros,
23925         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
23926         HAVE_MALLOC/HAVE_REALLOC.
23927
23928         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
23929         dummy ones.  At least on GNU/Linux systems, `auto' means something
23930         else.
23931         From Michael Stone.
23932
23933 2002-11-21  Bruno Haible  <bruno@clisp.org>
23934
23935         Remove case insensitive option matching.
23936         * lib/argmatch.h (argcasematch): Remove declaration.
23937         (ARGCASEMATCH): Remove macro.
23938         (__xargmatch_internal): Remove case_sensitive argument.
23939         (XARGMATCH): Update.
23940         (XARGCASEMATCH): Remove macro.
23941         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
23942         case_sensitive argument.
23943         (argcasematch): Remove function.
23944         (__xargmatch_internal): Remove case_sensitive argument.
23945         (main): Use XARGMATCH instead of XARGCASEMATCH.
23946
23947         * lib/xmalloc.c: Change compile-time error message. Add comment about
23948         required autoconf version.
23949
23950 2002-11-20  Paul Eggert  <eggert@twinsun.com>
23951
23952         Merge argmatch cleanups from Bison.  Assume C89.
23953
23954         * lib/argmatch.c: Include config.h here, not in argmatch.h.
23955         Include stdlib.h, for EXIT_FAILURE.
23956         Always include <string.h>, since we assume C89.
23957         (EXIT_FAILURE): Remove pre-C89 bug workaround.
23958         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
23959         Include <stddef.h> instead, since it's all we need for size_t.
23960         (PARAMS): Remove.  All uses removed.
23961         (ARRAY_CARDINALITY): Do not bother to #undef.
23962         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
23963         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
23964         Remove unnecessary parentheses.
23965         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
23966         Insert necessary parentheses.
23967         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
23968         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
23969
23970 2002-11-19  Bruno Haible  <bruno@clisp.org>
23971
23972         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
23973         * lib/mbswidth.h: Include <stddef.h>, for size_t.
23974
23975         * lib/mbswidth.h (PARAMS): Remove macro.
23976         (mbswidth, mbsnwidth): Use ANSI C function declarations.
23977         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
23978
23979         * lib/gcd.h (PARAMS): Remove macro.
23980         (gcd): Use ANSI C function declarations.
23981         * lib/gcd.c (gcd): Likewise.
23982
23983 2002-11-15  Bruno Haible  <bruno@clisp.org>
23984
23985         * lib/strcspn.c: Include <stddef.h>.
23986         (strcspn): Use ANSI C function declaration. Change return type to
23987         size_t. Use NULL.
23988         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
23989         (strpbrk): Use NULL.
23990         * lib/strpbrk.h (PARAMS): Remove macro.
23991         (strpbrk): Use ANSI C function declaration.
23992         * lib/strstr.c: Don't include <sys/types.h>.
23993         * lib/strstr.h (PARAMS): Remove macro.
23994         (strstr): Use ANSI C function declarations.
23995
23996 2002-11-14  Karl Berry  <karl@gnu.org>
23997
23998         * config/mkinstalldirs: `do' on separate line, instead of
23999         `for var; do'.
24000
24001 2002-11-06  Bruno Haible  <bruno@clisp.org>
24002
24003         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
24004         * lib/gcd.c (gcd): Likewise.
24005
24006 2002-11-05  Bruno Haible  <bruno@clisp.org>
24007
24008         * lib/gcd.h: New file, from gettext-0.11.5.
24009         * lib/gcd.c: New file, from gettext-0.11.5.
24010
24011 2002-11-05  Bruno Haible  <bruno@clisp.org>
24012
24013         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24014         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24015         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24016         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24017
24018         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
24019         <libintl.h>.
24020         * lib/makepath.c: Include gettext.h instead of <locale.h> and
24021         <libintl.h>.
24022
24023         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
24024         * lib/human.c: Include gettext.h instead of <libintl.h>.
24025         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
24026         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
24027         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
24028         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
24029         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
24030         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
24031         (textdomain): Remove definition.
24032         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
24033
24034         * lib/long-options.c: Remove include of <libintl.h> and definition of
24035         _.
24036         * lib/same.c: Remove include of <libintl.h> and definition of _.
24037
24038 2002-11-04  Owen Taylor  <otaylor@redhat.com>
24039
24040         * lib/config.charset: A few additions for Solaris.
24041
24042 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24043
24044         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
24045         * lib/localcharset.c (locale_charset): Declare as extern "C".
24046
24047 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24048
24049         * lib/config.charset: msdos in uk_UA uses CP1125.
24050
24051 2002-11-04  Bruno Haible  <bruno@clisp.org>
24052
24053         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
24054         * lib/strcase.h: New file, from GNU gettext-0.11.5.
24055         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
24056         * lib/strstr.h: New file, from GNU gettext-0.11.5.
24057         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
24058
24059 2002-11-04  Bruno Haible  <bruno@clisp.org>
24060
24061         * lib/localcharset.c (locale_charset): Don't return an empty string.
24062
24063 2002-11-04  Bruno Haible  <bruno@clisp.org>
24064
24065         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
24066         aliases.
24067
24068 2002-11-04  Bruno Haible  <bruno@clisp.org>
24069
24070         * lib/config.charset: Update for newest glibc. Add canonical names
24071         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
24072
24073 2002-11-04  Bruno Haible  <bruno@clisp.org>
24074
24075         * lib/config.charset: Add support for NetBSD.
24076
24077 2002-11-04  Bruno Haible  <bruno@clisp.org>
24078
24079         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
24080
24081 2002-11-01  Bruno Haible  <bruno@clisp.org>
24082
24083         * configure.in: Add AC_CONFIG_AUX_DIR call.
24084         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
24085         test/Makefile.
24086         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
24087
24088 2002-09-28  Karl Berry  <karl@gnu.org>
24089
24090         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
24091         installed automake until the next release, since changes have been
24092         made.
24093
24094 2002-09-25  Karl Berry  <karl@gnu.org>
24095
24096         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
24097         * lib/getopt*: copy from libc/posix.
24098         * lib/gettext.h: copy from gettext.
24099         * lib/.cppi-disable: add strdup.c, gettext.h.
24100
24101 2002-09-25  Karl Berry  <karl@gnu.org>
24102
24103         * config/srclist.txt: enable gettext.h check.
24104         * config/config.{guess,sub}: update from prep.
24105         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
24106                 from automake 1.6.3.
24107         See srclist*.
24108
24109 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
24110
24111         * regex.c (PATFETCH): Remove the translating fetch.
24112         (PATFETCH_RAW): Rename to PATFETCH.
24113         (set_image_of_range): New fun.
24114         (SET_RANGE_TABLE_WORK_AREA): Use it.
24115         (regex_compile): Don't translate the pattern chars so eagerly.
24116         Only do it when inserting an `exactn' bytecode or when handling
24117         a char-range.
24118         (mutually_exclusive_p): Avoid empty statement.
24119
24120 2002-07-06  Jim Meyering  <meyering@lucent.com>
24121
24122         * m4/README: Don't mention Makefile.am.in.
24123         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
24124
24125 2002-07-01  Jim Meyering  <meyering@lucent.com>
24126
24127         * lib/c-stack.c: Include sys/time.h.
24128         From Volker Borchert.
24129
24130 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24131
24132         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
24133
24134 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24135
24136         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
24137         New macro.  Use it uniformly instead of
24138         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
24139         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
24140         reported by Vin Shelton.
24141
24142 2002-06-22  Paul Eggert  <eggert@twinsun.com>
24143
24144         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
24145         Do not assume SA_SIGINFO behavior.
24146         Bug reported by Jim Meyering on NetBSD 1.5.2.
24147
24148 2002-06-22  Jim Meyering  <meyering@lucent.com>
24149
24150         * m4/c-stack.m4: New file, from diffutils-2.8.2.
24151         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
24152
24153         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
24154         now that configure.ac uses AC_GNU_SOURCE.
24155         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
24156         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
24157
24158         Update to latest tools.  Suggestions from Paul Eggert.
24159         * m4/stdbool.m4: New file, from diffutils-2.8.2.
24160         * m4/gnu-source.m4: Update from diffutils-2.8.2.
24161         * m4/fnmatch.m4: Likewise.
24162         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
24163         to AC_HEADER_STDBOOL
24164
24165 2002-06-22  Jim Meyering  <meyering@lucent.com>
24166
24167         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
24168         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
24169
24170 2002-06-22  Jim Meyering  <meyering@lucent.com>
24171
24172         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
24173
24174         * lib/exitfail.c, exitfail.h: Likewise.
24175         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
24176
24177         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
24178         of fnmatch.h.
24179         (EXTRA_DIST): Add fnmatch_loop.c.
24180         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
24181
24182         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
24183         * lib/fnmatch.c: Update from diffutils-2.8.2.
24184         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
24185         * lib/fnmatch.h: Remove file.
24186
24187 2002-06-21  Jim Meyering  <meyering@lucent.com>
24188
24189         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
24190         * m4/mbrtowc.m4: Likewise.
24191
24192         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
24193         * m4/mbswidth.m4: Reflect name change:
24194         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
24195         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
24196
24197         * m4/lib-link.m4: Update from gettext-0.11.2.
24198         * m4/gettext.m4: Likewise.
24199
24200         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
24201         From Alfred M. Szmidt.
24202
24203 2002-06-18  Paul Eggert  <eggert@twinsun.com>
24204
24205         * lib/file-type.h: Report an error if neither S_ISREG nor
24206         S_IFREG is defined, instead of using a test specific to glibc
24207         2.2.  This should be safe, since POSIX requires S_ISREG and
24208         Unix Version 7 had S_IFREG.  We don't need to check for
24209         <sys/types.h> since we don't use any symbols that it defines.
24210
24211 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
24212
24213         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
24214         $@-t, so that each temporary file name is unique and valid in the first
24215         8 characters, for operation under DOS.
24216
24217 2002-06-15  Paul Eggert  <eggert@twinsun.com>
24218
24219         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
24220
24221 2002-06-15  Jim Meyering  <meyering@lucent.com>
24222
24223         Work even with DJGPP 2.03, which lacks support for symlinks.
24224         From Richard Dawe.
24225         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
24226         is defined.
24227         * lib/lchown.c (S_ISLNK): Likewise.
24228
24229 2002-06-15  Jim Meyering  <meyering@lucent.com>
24230
24231         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
24232         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
24233         have been included before this file.
24234
24235 2002-06-14  Jim Meyering  <meyering@lucent.com>
24236
24237         * lib/file-type.h: Use the version from diffutils-2.8.2.
24238         * lib/file-type.c: Likewise.
24239
24240 2002-06-07  Jim Meyering  <meyering@lucent.com>
24241
24242         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
24243         They're needed at least for NetBSD 1.5.2.
24244         ($statxfs_includes): Include those same headers.
24245         ($statxfs_includes): Include sys/vfs.h if available.
24246         ($statxfs_includes): Likewise for sys/statvfs.h.
24247         Check for the following members in both structs statfs and statvfs:
24248         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
24249
24250 2002-06-01  Jim Meyering  <meyering@lucent.com>
24251
24252         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
24253         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
24254
24255 2002-05-28  Jim Meyering  <meyering@lucent.com>
24256
24257         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
24258         Reported by Volker Borchert.
24259
24260 2002-05-27  Jim Meyering  <meyering@lucent.com>
24261
24262         Fix a problem seen only on nonconforming systems whereby ls.c's
24263         use of localtime, and then of gettimeofday would cause trouble:
24264         the localtime call used to initialize rpl_gettimeofday's save
24265         mechanism would clobber ls's current local time information so
24266         that in any long listing the first file would always be listed
24267         with date 1970-01-01.  Analysis by Volker Borchert.
24268
24269         * lib/gettimeofday.c (localtime): Undefine.
24270         (rpl_localtime): New function.
24271
24272 2002-05-27  Jim Meyering  <meyering@lucent.com>
24273
24274         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
24275         localtime.
24276
24277         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
24278         use the replacement function; it wouldn't resolve at link time.
24279         Reported by Volker Borchert.
24280
24281 2002-05-22  Jim Meyering  <meyering@lucent.com>
24282
24283         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
24284         file-type.h.
24285         * lib/file-type.h: New file.
24286         * lib/file-type.c (file_type): New file/function.  Extracted from
24287         diffutils.
24288
24289 2002-04-30  Jim Meyering  <meyering@lucent.com>
24290
24291         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
24292
24293 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24294
24295         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
24296
24297 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24298
24299         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
24300         Do not check for alloca.h (no longer used) or stdbool.h (was never
24301         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
24302
24303 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24304
24305         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
24306
24307 2002-04-29  Jim Meyering  <meyering@lucent.com>
24308
24309         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
24310         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
24311         Use AC_FUNC_STRNLEN here instead.
24312
24313         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
24314         With autoconf-2.53a, it's part of AC_PROG_CC.
24315
24316 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24317
24318         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
24319         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
24320
24321 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24322
24323         * lib/sig2str.h, lib/sig2str.c: New files.
24324         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
24325
24326 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24327
24328         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
24329         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
24330         of 127, since 64 is the largest conceivable number for ancient
24331         nonstandard hosts.
24332         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
24333
24334 2002-04-28  Jim Meyering  <meyering@lucent.com>
24335
24336         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
24337
24338 2002-04-24  Jim Meyering  <meyering@lucent.com>
24339
24340         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
24341         (jm_PREREQ): Use it.
24342
24343         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
24344         mach/mach.h fcntl.h.
24345         Check for this function: setlocale.
24346
24347 2002-04-24  Jim Meyering  <meyering@lucent.com>
24348
24349         * lib/gettext.h: New file, from Gettext.
24350         * lib/Makefile.am (INCLUDES): Remove -I../intl.
24351         (libfetish_a_SOURCES): Add gettext.h.
24352
24353 2002-04-16  Jim Meyering  <meyering@lucent.com>
24354
24355         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
24356         ut_pid, ut_id, ut_exit.
24357
24358 2002-04-16  Jim Meyering  <meyering@lucent.com>
24359
24360         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
24361         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
24362         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
24363
24364 2002-04-12  Jim Meyering  <meyering@lucent.com>
24365
24366         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
24367         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
24368         existence of the getmntinfo function.  Needed for Darwin 5.3.
24369
24370         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
24371         This is necessary at least on Darwin 5.3.
24372
24373         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
24374         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
24375         strnlen.o in the library, and that makes some versions of ranlib
24376         object.
24377
24378 2002-04-12  Jim Meyering  <meyering@lucent.com>
24379
24380         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
24381
24382 2002-04-09  Jim Meyering  <meyering@lucent.com>
24383
24384         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
24385         to be more precise.  Rather than saying we're checking whether the
24386         function `works', say what we're testing.
24387         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
24388         Reported by Bruno Haible.
24389
24390 2002-03-10  Jim Meyering  <meyering@lucent.com>
24391
24392         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
24393         Suggestion from Santiago Vila.
24394
24395 2002-03-08  Jim Meyering  <meyering@lucent.com>
24396
24397         * lib/rename.c: Mention that this wrapper is needed also on
24398         mips-dec-ultrix4.4 systems.
24399
24400 2002-03-02  Jim Meyering  <meyering@lucent.com>
24401
24402         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
24403         not HAVE_CLOCK_SETTIME.
24404
24405 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24406
24407         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
24408         Check for clock_settime.
24409
24410 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24411
24412         * lib/nanosleep.h: Rename to....
24413         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
24414
24415         * lib/gettime.c: New file.
24416         * lib/settime.c: New file.
24417         * lib/stime.c: Remove.
24418
24419         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
24420         timespec.h.  Remove nanosleep.h.
24421
24422 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24423
24424         * m4/acl.m4: New file.
24425         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
24426         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
24427
24428 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24429
24430         * lib/acl.c, lib/acl.h: New files.
24431         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
24432
24433 2002-02-24  Jim Meyering  <meyering@lucent.com>
24434
24435         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
24436         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
24437         cause trouble.  Reported by Nelson Beebe.
24438
24439 2002-02-23  Paul Eggert  <eggert@twinsun.com>
24440
24441         * lib/path-concat.c (xpath_concat): Reorder code to pacify
24442         compilers that don't know that xalloc_die never returns.
24443
24444 2002-02-20  Jim Meyering  <meyering@lucent.com>
24445
24446         * lib/getdate.c: Regenerate using bison-1.33.
24447
24448 2002-02-17  Jim Meyering  <meyering@lucent.com>
24449
24450         * config/config.guess (main): Don't use `head -1'; it's no longer
24451         portable. Use `sed 1q' instead.
24452
24453 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
24454
24455         * m4/codeset.m4: Upgrade to gettext-0.11.
24456         * m4/gettext.m4: Upgrade to gettext-0.11.
24457         * m4/glibc21.m4: Upgrade to gettext-0.11.
24458         * m4/iconv.m4: Upgrade to gettext-0.11.
24459         * m4/isc-posix.m4: Upgrade to gettext-0.11.
24460         * m4/lcmessage.m4: Upgrade to gettext-0.11.
24461         * m4/lib-ld.m4: New file, from gettext-0.11.
24462         * m4/lib-link.m4: New file, from gettext-0.11.
24463         * m4/lib-prefix.m4: New file, from gettext-0.11.
24464         * m4/progtest.m4: Upgrade to gettext-0.11.
24465
24466 2002-02-15  Paul Eggert  <eggert@twinsun.com>
24467
24468         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
24469         (jm_PREREQ): Use it.
24470
24471 2002-02-15  Paul Eggert  <eggert@twinsun.com>
24472
24473         * lib/posixver.c, lib/posixver.h: New files.
24474         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
24475
24476 2002-02-02  Paul Eggert  <eggert@twinsun.com>
24477             Bruno Haible  <bruno@clisp.org>
24478
24479         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
24480         (fwrite_success_callback): New declaration.
24481         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
24482         print_unicode_char. Call failure callback instead of error.
24483         (fwrite_success_callback): New function.
24484         (exit_failure_callback): New function.
24485         (fallback_failure_callback): New function.
24486         (print_unicode_char): Call unicode_to_mb.
24487
24488 2002-01-26  Jim Meyering  <meyering@lucent.com>
24489
24490         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
24491         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
24492
24493 2002-01-26  Jim Meyering  <meyering@lucent.com>
24494
24495         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
24496
24497 2002-01-22  Paul Eggert  <eggert@twinsun.com>
24498
24499         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
24500
24501 2002-01-22  Jim Meyering  <meyering@lucent.com>
24502
24503         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
24504         Otherwise, some versions of automake would omit the rule that makes
24505         Makefile from Makefile.in.
24506
24507 2002-01-21  Paul Eggert  <eggert@twinsun.com>
24508
24509         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
24510         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
24511         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
24512         (memcoll): Set errno to zero if there is no error.
24513
24514         * lib/quotearg.c (quotearg_buffer_restyled):
24515         Fix bug with quoting buffers containing NUL when backslashing escapes.
24516         This bug was exposed by the other changes in this patch.
24517         (quotearg_n_options): New arg ARGSIZE.
24518         All callers changed.
24519         (quoting_options_from_style): New function.
24520         (quotearg_n_style): Use it.
24521         (quotearg_n_style_mem): New function.
24522
24523         * lib/quotearg.h (quotearg_n_style_mem): New function.
24524
24525 2002-01-19  Jim Meyering  <meyering@lucent.com>
24526
24527         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
24528         Remove useless quotes: DF_PROG="df".
24529         * m4/strnlen.m4: New file.
24530
24531 2002-01-16  Paul Eggert  <eggert@twinsun.com>
24532
24533         * lib/backupfile.c (ISDIGIT): Comment fix.
24534         * lib/getdate.y (ISDIGIT): Likewise.
24535         * lib/posixtm.c (ISDIGIT, year): Likewise.
24536         * lib/strverscmp.c (ISDIGIT): Likewise.
24537         * lib/userspec.c (ISDIGIT): Likewise.
24538
24539 2002-01-16  Jim Meyering  <meyering@lucent.com>
24540
24541         * lib/getdate.y: Add three semicolons, each just before a closing
24542         brace. Bison (as of version 1.31) no longer papers over that mistake.
24543
24544 2002-01-05  Jim Meyering  <meyering@lucent.com>
24545
24546         * lib/version-etc.c (version_etc_copyright): Update copyright year.
24547
24548 2001-12-19  Paul Eggert  <eggert@twinsun.com>
24549
24550         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
24551         not silently exit merely because the output buffer happens to
24552         have nothing pending.
24553
24554 2001-12-18  Paul Eggert  <eggert@twinsun.com>
24555
24556         See the big note in ../ChangeLog.
24557         * lib/human.c (suffixes): Prefer K to k for 1024.
24558         (generate_suffix_backwards): New function.
24559         (human_readable_inexact): Use it.
24560         * lib/xstrtol.c (__xstrtol): If there is no number but there
24561         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
24562         Accept 'K' as well as 'k'.
24563
24564 2001-12-15  Jim Meyering  <meyering@lucent.com>
24565
24566         * lib/regex.h (__restrict_arr): Update from libc.
24567
24568         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
24569         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
24570         (STREQ): Define.
24571
24572 2001-12-14  Jim Meyering  <meyering@lucent.com>
24573
24574         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
24575         Suggestion from Bruno Haible.
24576
24577 2001-12-10  Jim Meyering  <meyering@lucent.com>
24578
24579         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
24580         xrealloc, Instead, include "xalloc.h".
24581         (initbuffer): Don't cast xmalloc return value to char*.
24582         (readline): Reword comment.
24583         Don't cast xrealloc return value to char*
24584         Return NULL, not 0.
24585
24586 2001-12-09  Jim Meyering  <meyering@lucent.com>
24587
24588         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
24589         about `signed and unsigned type in conditional expression'.
24590         * lib/posixtm.c (posix_time_parse): Likewise.
24591
24592         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
24593
24594         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
24595         to avoid a pedantic warning.
24596
24597         * lib/getstr.c: Don't include assert.h.
24598         (getstr): Remove warning-evoking assertions.
24599         Return -1 if offset parameter is out of bounds.
24600         Change the type of a local from int to size_t.
24601
24602         * lib/strftime.c (my_strftime_localtime_r): Include this function
24603         definition in the `#if ! HAVE_TM_GMTOFF' block.
24604
24605         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
24606         Include xalloc.h instead.
24607
24608 2001-12-02  Jim Meyering  <meyering@lucent.com>
24609
24610         * lib/tempname.c: Don't declare getenv, thus reverting the change of
24611         2001-11-18.  It's no longer necessary, now that stdlib.h is always
24612         included.
24613
24614         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
24615         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
24616
24617 2001-11-30  Akim Demaille  <akim@epita.fr>
24618
24619         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
24620         before being defined.
24621
24622 2001-11-27  Paul Eggert  <eggert@twinsun.com>
24623
24624         * lib/quotearg.h (quotearg_n, quotearg_n_style):
24625         First arg is int, not unsigned.
24626         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
24627         (SIZE_MAX, UINT_MAX): New macros.
24628         (quotearg_n_options): Abort if N is negative.
24629         Avoid overflow check on hosts where size_t is 64 bits and int
24630         is 32 bits, as overflow is impossible there.
24631         Fix off-by-one typo that caused unnecessary reallocation.
24632
24633 2001-11-27  Jim Meyering  <meyering@lucent.com>
24634
24635         * lib/tempname.c: Merge with version from libc.
24636         * lib/regex.c: Likewise.
24637
24638         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
24639         systems for which STDC_HEADERS is 0, it was not included, resulting in
24640         a warning about an integer-to-pointer conversion problem with getenv.
24641         Reported by Volker Borchert.
24642
24643 2001-11-26  Jim Meyering  <meyering@lucent.com>
24644
24645         * lib/gtod.h: Remove file.
24646         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
24647         * lib/gettimeofday.c: Don't include gtod.h.
24648         (GTOD_init): Remove function.
24649         (rpl_gettimeofday): Do its job here instead, rather than aborting.
24650         Suggestion from Volker Borchert.
24651
24652 2001-11-23  Jim Meyering  <meyering@lucent.com>
24653
24654         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
24655         it.
24656         * lib/hash.c (struct hash_table): Define it here instead.
24657
24658 2001-11-22  Jim Meyering  <meyering@lucent.com>
24659
24660         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
24661
24662 2001-11-20  Jim Meyering  <meyering@lucent.com>
24663
24664         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
24665         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
24666
24667 2001-11-19  Jim Meyering  <meyering@lucent.com>
24668
24669         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
24670         directory.  Use "conftestXXXXXX" as the template.
24671         Suggestion from Paul Eggert.
24672
24673         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
24674         immediately, so the test doesn't mistakenly hit the max-open-files
24675         limit.
24676
24677 2001-11-18  Paul Eggert  <eggert@twinsun.com>
24678
24679         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
24680         (TEMPORARIES): New macro.
24681         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
24682         removes an artificial limitation (e.g. HP-UX 10.20, where
24683         TMP_MAX is 17576).
24684
24685 2001-11-18  Jim Meyering  <meyering@lucent.com>
24686
24687         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
24688
24689 2001-11-18  Jim Meyering  <meyering@lucent.com>
24690
24691         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
24692         on SunOS 4.
24693
24694         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
24695         files will be created before anything else.
24696
24697 2001-11-17  Paul Eggert  <eggert@twinsun.com>
24698
24699         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
24700         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
24701
24702 2001-11-17  Jim Meyering  <meyering@lucent.com>
24703
24704         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
24705         Prompted by a report from Bob Proulx.
24706
24707         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
24708         Instead, require UTILS_FUNC_MKSTEMP.
24709
24710 2001-11-17  Jim Meyering  <meyering@lucent.com>
24711
24712         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
24713         Now, that's done as part of AC_FUNC_STRTOD.
24714
24715 2001-11-17  Jim Meyering  <meyering@lucent.com>
24716
24717         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
24718         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
24719         rather than group writable.  Patch by Juan F. Codagnone.
24720
24721         * lib/readtokens.c: Remove explicit declarations of xmalloc and
24722         xrealloc, Instead, include "xalloc.h".
24723
24724         * lib/mountlist.c: Include unlocked-io.h after all system headers.
24725         Remove explicit declarations of xmalloc, xrealloc,
24726         and xstrdup.  Instead, include "xalloc.h".
24727
24728         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
24729         unlocked-io.h.
24730         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
24731         Likewise.
24732         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
24733
24734         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
24735         Reported by Padraig Brady.
24736
24737         * lib/mkstemp.c: #undef mkstemp.
24738         Include config.h.
24739         (rpl_mkstemp): Rename from mkstemp.
24740         Protoize.
24741
24742 2001-11-16  Jim Meyering  <meyering@lucent.com>
24743
24744         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
24745         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
24746         determine the amount of total physical memory, use pstat_getstatic.
24747         HPUX-11 doesn't define _SC_PHYS_PAGES.
24748         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
24749         If sysconf couldn't be used to determine the amount of available
24750         physical memory, use both pstat_getstatic and pstat_getdynamic.
24751         Based on a patch from Bob Proulx.
24752
24753 2001-11-10  Jim Meyering  <meyering@lucent.com>
24754
24755         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
24756         (jm_PREREQ): Use it.
24757
24758 2001-11-09  Jim Meyering  <meyering@lucent.com>
24759
24760         * m4/jm-macros.m4: Require autoconf-2.52f.
24761         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
24762         Use these AC_-prefixed names, not the AM_-prefixed ones.
24763
24764         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
24765
24766 2001-11-05  Jim Meyering  <meyering@lucent.com>
24767
24768         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
24769
24770 2001-11-04  Jim Meyering  <meyering@lucent.com>
24771
24772         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
24773         $DEFS.
24774
24775 2001-11-03  Jim Meyering  <meyering@lucent.com>
24776
24777         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
24778         of AC_DEFUN.
24779
24780         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
24781         know the name of the variable in the macro definition.
24782
24783 2001-11-03  Jim Meyering  <meyering@lucent.com>
24784
24785         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
24786         in argmatch_to_argument call.
24787
24788         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
24789         argument.
24790
24791         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
24792         e.g., a fault due to an attempt to free a NULL pointer.
24793
24794 2001-11-01  Jim Meyering  <meyering@lucent.com>
24795
24796         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
24797         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
24798
24799 2001-11-01  Jim Meyering  <meyering@lucent.com>
24800
24801         * lib/dirfd.c, lib/dirfd.h: New files.
24802         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
24803
24804         * lib/hash.c (hash_print) [TESTING]: Clean up.
24805
24806 2001-10-22  Paul Eggert  <eggert@twinsun.com>
24807
24808         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
24809         to avoid a warning if -Wall.
24810
24811 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
24812
24813         * README: New file
24814         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
24815         (per RMS's instructions, this is now the canonical source)
24816         * lgpl/, gpl/: New directories.
24817
24818 2001-10-21  Paul Eggert  <eggert@twinsun.com>
24819
24820         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
24821
24822 2001-10-21  Jim Meyering  <meyering@lucent.com>
24823
24824         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
24825         this code would end up calling gettext even in packages built
24826         with --disable-nls.
24827         * lib/getopt.c (_): Likewise.
24828         * lib/regex.c (_): Likewise.
24829
24830 2001-10-20  Paul Eggert  <eggert@twinsun.com>
24831
24832         * m4/error.m4 (jm_PREREQ_ERROR):
24833         Do not invoke AC_CHECK_FUNCS with strerror_r, as
24834         AC_FUNC_STRERROR_R does that.
24835         Check for strerror declaration.
24836
24837         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
24838         are supposed to have them these days.
24839         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
24840         Merge changes from latest Autoconf CVS.
24841         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
24842         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
24843         POSIX decided to standardize on the int flavor of strerror_r.
24844
24845 2001-10-20  Paul Eggert  <eggert@twinsun.com>
24846
24847         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
24848         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
24849         Use strerror_r that is only a macro, even if it is not a function.
24850         (strerror): Check for HAVE_DECL_STRERROR before declaring.
24851         (private_strerror): Use prototypes, not old-style function definition.
24852         (print_errno_message): New function.
24853         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
24854         char*-flavored one.
24855         (error_tail, error, error_at_line): Use it.
24856
24857 2001-10-11  Jim Meyering  <meyering@lucent.com>
24858
24859         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
24860         and quote_n (1, ... to avoid clobbering a buffer.
24861
24862 2001-10-05  Jim Meyering  <meyering@lucent.com>
24863
24864         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
24865         hash-pjw.h.
24866         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
24867         * lib/hash-pjw.h: New file.
24868
24869 2001-09-30  Jim Meyering  <meyering@lucent.com>
24870
24871         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
24872         `struct fsstat' has the `f_fstypename' member.
24873         Use that to define FS_TYPE, which is now used to make
24874         the getfsstat link test tighter.
24875
24876 2001-09-30  Jim Meyering  <meyering@lucent.com>
24877
24878         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
24879         Include <sys/ucred.h>, for Apple Darwin.
24880         Include sys/mount.h and sys/fs_types.h only if available.
24881         (FS_TYPE): Define.
24882         (read_filesystem_list): Use FS_TYPE.
24883
24884 2001-09-29  Paul Eggert  <eggert@twinsun.com>
24885
24886         * lib/exclude.c (excluded_filename): 0 -> false, since it's
24887         a boolean context.
24888
24889 2001-09-29  Jim Meyering  <meyering@lucent.com>
24890
24891         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
24892         [one-argument getmntent function]): Include stdio.h before mntent.h.
24893         SunOS 4.1.x needs it for the declaration of `FILE'.
24894         Patch by Volker Borchert.
24895
24896         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
24897         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
24898         sys/fs_types.h, and make the link-test for getfsstat guard #include
24899         directives with appropriate #if HAVE_*_H tests so that we can
24900         detect getfsstat on Apple Darwin1.3.7 systems.
24901         Reported by Nelson Beebe.
24902         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
24903
24904 2001-09-28  Paul Eggert  <eggert@twinsun.com>
24905
24906         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
24907         #defines strtoimax.  Also treat the other strto* functions
24908         like strtoimax.
24909
24910         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
24911         Check for strtoul and strtoumax,
24912         as those declarations are made even in the signed case.
24913         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
24914         Likewise, for strtol and strtoimax.
24915
24916 2001-09-28  Paul Eggert  <eggert@twinsun.com>
24917
24918         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
24919         #defines strtoimax.  Also treat the other strto* functions
24920         like strtoimax.
24921
24922         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
24923         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
24924         (strtoimax, strtoumax): Do not declare if already defined as a macro.
24925
24926 2001-09-26  Jim Meyering  <meyering@lucent.com>
24927
24928         Most macros in unlocked-io.h had the wrong number of arguments.
24929         * lib/gen-uio: New script.
24930         (USE_UNLOCKED_IO): Define to 1 if not already defined.
24931         * lib/unlocked-io.hin: Remove file.
24932         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
24933         rather than trying to embed it here.
24934         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
24935         Reported by Padraig Brady.
24936
24937 2001-09-25  Volker Borchert  <bt@teknon.de>
24938
24939         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
24940         `result'.
24941
24942 2001-09-24  Jim Meyering  <meyering@lucent.com>
24943
24944         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
24945
24946 2001-09-23  Jim Meyering  <meyering@lucent.com>
24947
24948         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
24949         instead of the mere test for existence of mntent.h.  The latter
24950         would get a false-positive on AIX 3.4 systems.
24951         In the outer getmntent if-block, don't die if neither of the getmntent
24952         tests succeeds.  Instead, just fall through and continue with the
24953         remaining tests.
24954
24955 2001-09-23  Jim Meyering  <meyering@lucent.com>
24956
24957         * lib/mountlist.c: Remove useless parentheses in #if directives.
24958         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
24959         the deprecated MOUNTED symbol is no longer defined in mntent.h.
24960
24961 2001-09-22  Jim Meyering  <meyering@lucent.com>
24962
24963         * m4/gettext.m4: New file.  From gettext.
24964         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
24965         * m4/progtest.m4: Likewise
24966         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
24967         * m4/glibc21.m4: Likewise.
24968
24969         * m4/libintl.m4: Remove.  No longer used.
24970
24971 2001-09-22  Jim Meyering  <meyering@lucent.com>
24972
24973         * lib/localcharset.c: Update from latest gettext.
24974         * lib/config.charset: Likewise.
24975
24976 2001-09-20  Jim Meyering  <meyering@lucent.com>
24977
24978         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
24979         strtoimax.
24980         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
24981         strtoumax.
24982
24983 2001-09-20  Jim Meyering  <meyering@lucent.com>
24984
24985         * lib/xstrtol.c (strtoimax): Guard declaration with
24986         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
24987         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
24988         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
24989         (strtoumax): Likewise, for completeness (it wasn't necessary).
24990
24991 2001-09-17  Paul Eggert  <eggert@twinsun.com>
24992
24993         * lib/strtoimax.c (HAVE_LONG_LONG):
24994         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
24995         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
24996         to work around bug in IBM C compiler.
24997
24998 2001-09-17  Jim Meyering  <meyering@lucent.com>
24999
25000         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
25001         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
25002         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
25003         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
25004         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
25005         whenever the right hand side need not be expanded by the shell.
25006
25007 2001-09-16  Paul Eggert  <eggert@twinsun.com>
25008
25009         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
25010         library.  It's not correct, as some older glibcs are buggy.
25011         fnmatch wasn't fixed until glibc 2.2.
25012
25013         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
25014         special shell magic here.
25015
25016 2001-09-16  Jim Meyering  <meyering@lucent.com>
25017
25018         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
25019         * m4/jm-macros.m4: Require it.
25020
25021 2001-09-16  Jim Meyering  <meyering@lucent.com>
25022
25023         * lib/mkdir.c: New file.
25024
25025 2001-09-15  Jim Meyering  <meyering@lucent.com>
25026
25027         * m4/jm-macros.m4: Check for help2man.
25028
25029 2001-09-11  Jim Meyering  <meyering@lucent.com>
25030
25031         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
25032         The body, by Paul Eggert, was moved here from configure.in.
25033         * m4/jm-macros.m4: Require UTILS_HOST_OS.
25034
25035 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25036
25037         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
25038         (jm_PREREQ): Use it.
25039
25040 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25041
25042         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
25043         Use ssize_t, not int, to store result of readlink.
25044         Check for ssize_t overflow as well as size_t overflow,
25045         as POSIX says the result of readlink is implementation-defined
25046         when ssize_t overflows.
25047         Remove unnecessary cast to char*.
25048         Use free+malloc instead of realloc, as the storage doesn't need
25049         to be preserved and it's clearer and can be more efficient that way.
25050         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
25051         * lib/xreadlink.h (xreadlink): Update prototype.
25052
25053 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25054
25055         * lib/xgetcwd.c: Revert some of the previous change; intead,
25056         fix the HAVE_GETCWD_NULL code to behave more like the
25057         !HAVE_GETCWD_NULL code used to.
25058
25059         Include "xalloc.h".
25060         (xgetcwd): Do not return NULL when memory is exhausted; instead,
25061         invoke xalloc_die.
25062
25063 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25064
25065         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
25066         sys/param.h, as pathmax.h includes them.
25067
25068 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25069
25070         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
25071         (jm_PREREQ_XGETCWD): New macro.
25072
25073         * m4/getcwd.m4: New file.
25074
25075 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25076
25077         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
25078         like the HAVE_GETCWD_NULL code.
25079         Include pathmax.h if not HAVE_GETCWD.
25080         Do not include xalloc.h.
25081         (INITIAL_BUFFER_SIZE): New symbol.
25082         Do not use xmalloc / xrealloc, since the caller is responsible for
25083         handling errors.  Preserve errno around `free' during failure.
25084         Do not overrun buffer when using getwd.
25085
25086 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25087
25088         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
25089         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
25090         getcwd (NULL, 0).
25091
25092 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25093
25094         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
25095         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
25096         spotted by Jim Meyering.
25097
25098 2001-09-03  Jim Meyering  <meyering@lucent.com>
25099
25100         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
25101         failure.
25102
25103 2001-09-02  Jim Meyering  <meyering@lucent.com>
25104
25105         * lib/error.c: Update from GNU libc.
25106
25107 2001-09-01  Jim Meyering  <meyering@lucent.com>
25108
25109         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
25110         Used by df.
25111
25112 2001-09-01  Jim Meyering  <meyering@lucent.com>
25113
25114         * lib/xreadlink.c: New file.
25115         * lib/xreadlink.h: New file.
25116         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
25117         xreadlink.h.
25118
25119         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
25120         doesn't conflict with sparc Solaris 7's definition in
25121         /usr/include/sys/int_types.h.
25122
25123         * lib/exclude.c: Use `""', not `<>' to #include non-system header
25124         files.
25125         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
25126         and strncasecmp as r-values.  Unixware didn't have declarations.
25127
25128 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25129
25130         * lib/xstrtol.h: Add copyright notice.
25131         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
25132         LONGINT_INVALID_SUFFIX_CHAR.
25133
25134 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25135
25136         * lib/xstrtol.c (strtoimax): New decl.
25137
25138 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25139
25140         * lib/xgetcwd.c: Don't include pathmax.h.
25141         Include stdlib.h and unistd.h if available.
25142         Include xalloc.h.
25143         (xmalloc, xstrdup, free): Remove decls.
25144         (xgetcwd): Don't assume sizes fit in unsigned.
25145         Check for overflow when computing sizes.
25146         Simplify reallocation code.
25147
25148 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25149
25150         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
25151         a directory's st_size can have an arbitrary value, so the old
25152         usage could waste an arbitrary amount of memory.  All uses
25153         changed.
25154         * lib/savedir.h: Update prototype.
25155
25156 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25157
25158         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
25159
25160         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
25161         old strtoimax.c.
25162
25163         Also, make the following further changes to make this file's
25164         configuration more similar to that of strtol.c:
25165         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
25166         (strtoumax, uintmax_t, strtoull, strtol): Remove.
25167         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
25168         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
25169         changed to signed values.
25170
25171         And make the following changes as well:
25172         Fix copyright notice, as 1999 was missing.
25173         (verify): New macro.
25174         (strtoimax): Check sizes at compile-time, not run-time.
25175         Prefer strtol to strtoll if both work.
25176         (main): Remove; it was not that useful and was a pain to maintain.
25177
25178         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
25179
25180 2001-08-31  Jim Meyering  <meyering@lucent.com>
25181
25182         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
25183         Use an initial, malloc'd, buffer of length 128 rather than
25184         a statically allocated one of length 1024.
25185
25186 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25187
25188         Simplify code, partly by assuming autoconf 2.52 semantics.
25189
25190         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
25191
25192         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
25193         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
25194         All uses removed.
25195         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
25196         Move AC_REQUIRE to next-to-top level, to avoid confusion.
25197         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
25198         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
25199         jm_AC_HEADER_INTTYPES_H.
25200         * m4/jm-macros.m4 (jm_MACROS): Likewise.
25201
25202         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
25203
25204         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
25205         Quote first arg of AC_DEFUN.
25206         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
25207         since they are needed to parse the include file even if we need
25208         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
25209         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
25210         but with opposite signedness.
25211
25212 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25213
25214         Merge 'exclude' changes from tar 1.13.22.
25215         This fixes one or two unlikely storage allocation overflow bugs,
25216         but doesn't change user-visible behavior otherwise.
25217
25218 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25219
25220         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
25221         (jm_PREREQ_EXCLUDE): New macro.
25222
25223 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25224
25225         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
25226         tm to be declared.
25227
25228 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25229
25230         * lib/hash.c: Remove '2001' from copyright notice.
25231
25232 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25233
25234         * lib/full-write.h: New file.
25235         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
25236         * lib/full-write.c: Correct credits, as cccp.c no longer
25237         exists and anyway it was so heavily changed from the old cccp
25238         code as to be unrecognizable.  Include full-write.h.
25239         (full_write) Return size_t, with short writes meaning failure.
25240         All callers changed.  This fixes a bug with large buffers
25241         on 64-bit hosts.
25242         * lib/utime.c: Include full-write.h.
25243
25244 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25245
25246         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
25247         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
25248         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
25249         Include if available.
25250         (<xalloc.h>): Include
25251         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
25252         (verify): New macro.  Use it to verify that EXCLUDE macros do not
25253         collide with FNM macros.
25254         (struct patopts): New struct.
25255         (struct exclude): Use it, as exclude patterns now come with options.
25256         (new_exclude): Support above changes.
25257         (new_exclude, add_exclude_file):
25258         Initial size must now be a power of two to simplify overflow checking.
25259         (free_exclude, fnmatch_no_wildcards): New function.
25260         (excluded_filename): No longer requires options arg, as the options
25261         are determined by add_exclude.  Now returns bool, not int.
25262         (excluded_filename, add_exclude):
25263         Add support for the fancy new exclusion options.
25264         (add_exclude, add_exclude_file): Now takes int options arg.
25265         Check for arithmetic overflow when computing sizes.
25266         (add_exclude_file): xrealloc might modify errno, so don't
25267         realloc until after errno might be used.
25268
25269         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
25270         New macros.
25271         (free_exclude): New decl.
25272         (add_exclude, add_exclude_file): Now takes int options arg.
25273         (excluded_filename): No longer requires options arg, as the options
25274         are determined by add_exclude.  Now returns bool, not int.
25275
25276 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25277
25278         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
25279
25280 2001-08-27  Jim Meyering  <meyering@lucent.com>
25281
25282         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
25283
25284         * lib/version-etc.c (N_): Remove definition.
25285         Revert most of last change.
25286         Instead, simply don't mark the `Copyright...' string for translation.
25287         Based on advice from Paul Eggert.
25288
25289         * lib/strtoxmax.c: Tweak comment.
25290
25291 2001-08-26  Jim Meyering  <meyering@lucent.com>
25292
25293         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
25294
25295         * m4/xstrtoimax.m4: New file.
25296         * m4/xstrtoumax.m4: Add comments explaining why we
25297         AC_REPLACE_FUNCS(strtol).
25298
25299 2001-08-26  Jim Meyering  <meyering@lucent.com>
25300
25301         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
25302         of copyright with `%s' so translators don't get an untranslated
25303         message in 2002.
25304         (COPYRIGHT_YEAR): Define.
25305         (version_etc): Use fprintf rather than fputs.
25306         Suggestion from Ulrich Drepper.
25307
25308         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
25309
25310         * lib/strtoll.c: New file, from GNU libc.
25311         * lib/xstrtoimax.c: New file.
25312
25313         * lib/xstrtol.h: Add xstrtoimax.
25314         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
25315         * lib/strtoimax.c: New file.  Likewise, but first define
25316         STRTOUXMAX_SIGNED.
25317
25318         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
25319         ...
25320         * lib/strtoxmax.c: ... then renamed to this.
25321
25322 2001-08-18  Paul Eggert  <eggert@twinsun.com>
25323
25324         * m4/inttypes.m4: Add AC_PREREQ(2.13).
25325         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
25326         (jm_AC_TYPE_INTMAX_T): New macro.
25327         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
25328
25329         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
25330
25331         * m4/longlong.m4: Renamed from ulonglong.m4.
25332         * m4/inttypes.m4: Renamed from inttypes_h.m4.
25333         * m4/uintmax_t.m4: Removed.
25334
25335 2001-08-13  Paul Eggert  <eggert@twinsun.com>
25336
25337         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
25338         Port to Solaris 8, where 'sed' requires a space after the 'r'
25339         command, and where sh dislikes "$/".  Clean up the spacing a bit.
25340         Redirect output to $tmp just once.
25341
25342 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
25343
25344         * lib/addext.c (<errno.h>): Include.
25345         (errno): Declare if not defined.
25346         (addext): Work correctly when pathconf returns -1 and leaves
25347         errno alone because there is no limit.  Also, work even if
25348         pathconf returns a value greater than SIZE_MAX.
25349
25350 2001-08-12  Jim Meyering  <meyering@lucent.com>
25351
25352         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
25353         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
25354         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
25355         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
25356         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
25357         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
25358         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
25359         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
25360         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
25361         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
25362         utime.m4, utimes.m4, xstrtoumax.m4:
25363         Quote the first argument in each use of AC_DEFUN.
25364
25365 2001-08-12  Jim Meyering  <meyering@lucent.com>
25366
25367         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
25368         Simply `return getcwd (NULL, 0);'.
25369         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
25370         Use 1300 as initial value for length, not PATH_MAX.
25371
25372         * lib/pathmax.h: Clean up cpp syntax.
25373
25374 2001-08-12  Jim Meyering  <meyering@lucent.com>
25375
25376         * lib/gettimeofday.c: New file.
25377         * lib/gtod.h: New file.
25378         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
25379
25380 2001-08-05  Jim Meyering  <meyering@lucent.com>
25381
25382         * m4/jm-macros.m4: Require autoconf-2.52.
25383
25384 2001-08-04  Jim Meyering  <meyering@lucent.com>
25385
25386         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
25387         stmt, to get in sync with glibc.
25388
25389 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25390
25391         The following changes are from gettext 0.10.39 as maintained by
25392         Bruno Haible.
25393
25394         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
25395         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
25396         with inverted sense.  All uses changed.
25397
25398         * lib/mbswidth.c: Don't include <limits.h>.
25399         Include <stdlib.h> and <string.h> unconditionally.
25400         (iswcntrl, mbsinit, ISCNTRL): New macros.
25401         (mbsnwidth): Use K&R style function declarations.
25402         Don't bother checking for MB_LEN_MAX == 1, since the compiler
25403         can optimize it when MB_CUR_MAX == 1.
25404         The width of control characters is zero, not 1.
25405
25406 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25407
25408         The following changes are from gettext 0.10.39 as maintained by
25409         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
25410
25411         * m4/codeset.m4: Upgrade to serial AM1.
25412         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
25413         all uses changed.  Quote first arg of AC_DEFUN.
25414         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
25415
25416         * m4/iconv.m4: Upgrade to serial AM2.
25417         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
25418         Add --with-libconv-prefix.
25419         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
25420         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
25421         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
25422         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
25423         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
25424
25425         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
25426         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
25427         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
25428         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
25429         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
25430         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
25431         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
25432         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
25433         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
25434
25435         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
25436         string.h any more.
25437
25438         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
25439         not the default value.
25440
25441         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
25442         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
25443         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
25444         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
25445         Also check for iswcntrl, used for wcwidth fallback.
25446         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
25447         to Autoconf 2.13.
25448
25449 2001-08-03  Jim Meyering  <meyering@lucent.com>
25450
25451         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
25452         as it was in the original.  Reported by Paul Eggert.
25453
25454 2001-07-16  Jim Meyering  <meyering@lucent.com>
25455
25456         * m4/gettimeofday.m4: New file.
25457         Prompted by a report from Bernhard Baehr.
25458
25459 2001-07-15  Jim Meyering  <meyering@lucent.com>
25460
25461         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
25462         stuff. Now it's in ../Makefile.cfg.
25463
25464 2001-07-15  Jim Meyering  <meyering@lucent.com>
25465
25466         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
25467         (BUILT_SOURCES): Add unlocked-io.h.
25468         (io_functions): Define.
25469         (unlocked-io.h): New rule.
25470         (DISTCLEANFILES): Add unlocked-io.h.
25471         (all-local): Depend on unlocked-io.h, to ensure it is created.
25472
25473         * lib/unlocked-io.hin: New file
25474
25475         * lib/regex.c: Update from glibc.
25476
25477 2001-07-05  Jim Meyering  <meyering@lucent.com>
25478
25479         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
25480         recommendation.
25481         (libfetish_a_SOURCES): Put all .h files here instead.
25482         Remove a thus-exposed (better checks in automake) duplicate and
25483         two unnecessary .h files.
25484
25485 2001-07-04  Jim Meyering  <meyering@lucent.com>
25486
25487         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
25488         that generates jm-glibc-io.m4 so that it doesn't trigger any make
25489         distcheck failure.
25490
25491 2001-07-02  Jim Meyering  <meyering@lucent.com>
25492
25493         The following changes were prompted by suggestions from Bruno Haible.
25494
25495         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
25496         is now generated.
25497         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
25498         definition of EXTRA_DIST.
25499         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
25500         ensure that the generated file is created/updated whenever the list
25501         of $(unlocked_functions) is changed.
25502         (jm-glibc-io.m4): New rule.
25503         (unlocked-io.h): New rule -- currently unused.
25504
25505 2001-06-24  Jim Meyering  <meyering@lucent.com>
25506
25507         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
25508         unmatched right bracket, rather than kludging it with an extra,
25509         falsely-matching quote in a comment.  Patch by Akim Demaille.
25510
25511 2001-06-11  Jim Meyering  <meyering@lucent.com>
25512
25513         * lib/regex.c: Update from GNU libc.
25514
25515 2001-05-27  Jim Meyering  <meyering@lucent.com>
25516
25517         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
25518         Check for ut_type in struct utmp.
25519
25520 2001-05-27  Jim Meyering  <meyering@lucent.com>
25521
25522         * lib/readutmp.h (UT_TYPE): Define.
25523
25524 2001-05-24  Jim Meyering  <meyering@lucent.com>
25525
25526         * lib/argmatch.c: Include "quote.h".
25527         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
25528         quote function.  Reported by Göran Uddeborg.
25529
25530 2001-05-22  Jim Meyering  <meyering@lucent.com>
25531
25532         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
25533         now that we use the package-supplied version unconditionally.
25534         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
25535
25536 2001-05-21  Jim Meyering  <meyering@lucent.com>
25537
25538         * m4/regex.m4: Change a couple backticks to single quotes to avoid
25539         shell syntax errors.
25540
25541 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
25542
25543         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
25544
25545 2001-05-20  Paul Eggert  <eggert@twinsun.com>
25546
25547         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
25548         Don't bother to check library strftime, since
25549         we'll be using our own my_strftime function anyway.
25550         Define my_strftime instead of strftime.
25551
25552 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
25553
25554         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
25555         which is not yet declared.
25556
25557 2001-05-15  Jim Meyering  <meyering@lucent.com>
25558
25559         * m4/regex.m4: Use proper quoting so brackets appear in the test
25560         program.
25561         Reported by, and with help from, Bruno Haible.
25562
25563 2001-05-13  Jim Meyering  <meyering@lucent.com>
25564
25565         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
25566         undefined.
25567
25568 2001-05-11  Paul Eggert  <eggert@twinsun.com>
25569
25570         dirname code cleanup.  base_name now behaves more compatibly
25571         with POSIX basename when given file names that have trailing
25572         slashes, and similarly for dir_name.  Add new primitives
25573         base_len and dir_len.  Put the directory-name-related decls
25574         into dirname.h.
25575
25576         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
25577         * lib/backupfile.c (base_name): Likewise.
25578         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
25579         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
25580         * lib/makepath.c (strip_trailing_slashes): Likewise.
25581         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
25582         ISSLASH): Likewise.
25583         * lib/rename.c (strip_trailing_slashes): Likewise.
25584         * lib/same.c (base_name): Likewise.
25585         * lib/stripslash.c (ISSLASH): Likewise.
25586
25587         * lib/addext.c: Include <dirname.h> after size_t is defined.
25588         * lib/backupfile.c: Likewise.
25589
25590         * lib/addext.c (addext): Use base_len to trim redundant
25591         trailing slashes instead of doing it ourselves.
25592         But do not trim the last slash if it is not redundant.
25593
25594         * lib/backupfile.c (find_backup_file_name,
25595         max_backup_version): Use base_len instead of rolling it ourselves.
25596         Handle the case of "" and (on DOS) "C:" correctly.
25597
25598         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
25599         needed. Include <string.h>, <dirname.h>.
25600         (base_name): Allow file names ending in slashes, other than names
25601         that are all slashes.  In this case, return the basename followed
25602         by the slashes.  This is more general, and can be used in places
25603         where the original base_name purposely had an assertion failure.
25604         (base_len): New function.
25605
25606         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
25607         Do not include <assert.h>; no longer needed.
25608         Include xalloc.h.
25609         (memrchr): Remove decl.
25610         (dir_name_r): Remove.
25611         (dir_len): Renamed from dirlen.  All callers changed.
25612         Rewrite in terms of base_name, for simplicity and consistency.
25613         (dir_name): Never return NULL.  All callers changed.
25614         Do not include <stdlib.h> in test program; no longer needed.
25615         return 0; is fine for test program.
25616
25617         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
25618         New macros.
25619         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
25620
25621         * lib/path-concat.c (path_concat): Use base_len to compute
25622         base length, not strlen; this means we cannot rely on memcpy
25623         to null-terminate.
25624
25625         * lib/same.c (STREQ): Remove.
25626         (same_name): Handle the case where the basename ends in trailing '/'.
25627
25628         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
25629         a slash was stripped.  Do not strip the last slash after a
25630         file system prefix.
25631
25632 2001-05-11  Paul Eggert  <eggert@twinsun.com>
25633
25634         * lib/Makefile.am (libfetish_a_SOURCES):
25635         Add strftime.c, since we now compile it on all hosts.
25636
25637         * lib/strftime.c (my_strftime):
25638         Define to nstrftime if emacs, but only if my_strftime is not defined.
25639         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
25640         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
25641         Add one more extra argument: a nanoseconds value.
25642         All uses changed.
25643         (ns): New macro.
25644         (my_strftime function): Add %N format.
25645         (emacs_strftimeu): Renamed from emacs_strftime,
25646         with extra ut argument.
25647
25648 2001-05-09  Paul Eggert  <eggert@twinsun.com>
25649
25650         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
25651
25652 2001-04-21  Jim Meyering  <meyering@lucent.com>
25653
25654         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
25655         doesn't interfere.
25656
25657 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
25658
25659         * m4/ftruncate.m4: Check for chsize.
25660         Link with ftruncate.o unconditionally if ftruncate is missing.
25661         This was required when cross-compiling to i586-mingw32msvc.
25662
25663 2001-04-08  Jim Meyering  <meyering@lucent.com>
25664
25665         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
25666         recomputed; that's necessary when the offset spans a DST transition.
25667         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
25668
25669 2001-04-02  Jim Meyering  <meyering@lucent.com>
25670
25671         * lib/regex.h, regex.c: Update from GNU libc.
25672
25673 2001-03-24  Jim Meyering  <meyering@lucent.com>
25674
25675         * m4/jm-macros.m4: Require autoconf-2.49d.
25676
25677 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
25678
25679         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
25680
25681 2001-03-19  Paul Eggert  <eggert@twinsun.com>
25682
25683         * lib/version-etc.c (version_etc_copyright): Update to 2001.
25684
25685 2001-03-17  Jim Meyering  <meyering@lucent.com>
25686
25687         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
25688         now that the version in autoconf is equivalent.
25689         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
25690
25691         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
25692         Suggestion from Akim Demaille.
25693
25694         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
25695         (jm_PREREQ_TEMPNAME): New function.
25696
25697 2001-03-16  Paul Eggert  <eggert@twinsun.com>
25698
25699         * lib/tempname.c (uint64_t): Define to uintmax_t if
25700         not defined, and if UINT64_MAX is not defined.
25701         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
25702         Reported by John David Anglin.
25703
25704 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
25705
25706         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
25707         resolve alias if codeset is empty.
25708         * lib/config.charset (BeOS): Use wildcard syntax.
25709
25710 2001-03-13  Jim Meyering  <meyering@lucent.com>
25711
25712         * lib/path-concat.c (path_concat)
25713         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
25714         concatenating e.g., `C:' and `foo'.
25715         From Bruno Haible.
25716
25717 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
25718
25719         * lib/localcharset.c (locale_charset): Don't use
25720         setlocale(LC_CTYPE,NULL). Don't return NULL.
25721         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
25722
25723 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
25724
25725         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
25726         support for DOS/DJGPP.
25727
25728 2001-03-01  Paul Eggert  <eggert@twinsun.com>
25729
25730         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
25731         lacks mkstemp.  Compile our own tempname.c if we compile our own
25732         mkstemp.c, as mkstemp relies on tempname.
25733
25734 2001-03-01  Jim Meyering  <meyering@lucent.com>
25735
25736         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
25737         AH_VERBATIM really does output its argument verbatim.
25738
25739 2001-02-28  Paul Eggert  <eggert@twinsun.com>
25740
25741         * lib/Makefile.am (libfetish_a_SOURCES):
25742         Add dup-safer.c, fopen-safer.c.
25743         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
25744
25745         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
25746         * lib/unistd-safer.h: New files.
25747
25748 2001-02-25  Paul Eggert  <eggert@twinsun.com>
25749
25750         The mkstemp replacement is taken from glibc 2.2.2, with some
25751         portability fixes for use outside glibc, as follows:
25752
25753         * lib/tempname.c (struct_stat64): New macro.
25754         (direxists, __gen_tempname): Use it.
25755         This avoids a portability problem with Solaris 8.
25756
25757         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
25758         (<stddef.h>, <stdint.h>, <string.h>):
25759         Include only if STDC_HEADERS || _LIBC.
25760         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
25761         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
25762         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
25763         (__set_errno): Define this macro if <errno.h> doesn't.
25764         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
25765         Define these macros if <stdio.h> doesn't.
25766         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
25767         Define these macros if <sys/stat.h>
25768         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
25769         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
25770         __xstat64): Define if not _LIBC.
25771         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
25772         (__gen_tempname): Invoke gettimeofday only if
25773         HAVE_GETTIMEOFDAY || _LIBC;
25774         otherwise, fall back on plain "time".
25775         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
25776
25777         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
25778
25779         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
25780
25781 2001-02-18  Paul Eggert  <eggert@twinsun.com>
25782
25783         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
25784
25785 2001-02-17  Paul Eggert  <eggert@twinsun.com>
25786
25787         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
25788         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
25789         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
25790         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
25791
25792 2001-02-17  Paul Eggert  <eggert@twinsun.com>
25793
25794         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
25795         Remove workaround macros for hosts that have mbrtowc but not
25796         mbstate_t, as we now insist on proper declarations for both
25797         before using mbrtowc.
25798
25799 2001-02-17  Jim Meyering  <meyering@lucent.com>
25800
25801         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
25802         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
25803         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
25804         UnixWare 7.1.1.
25805
25806         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
25807         rather than AC_CACHE_VAL.
25808
25809 2001-02-17  Jim Meyering  <meyering@lucent.com>
25810
25811         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
25812         around included file name.
25813
25814         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
25815
25816         * lib/strftime.c: Update from GNU libc (the only changes were to
25817         comments).
25818
25819 2001-02-17  Jim Meyering  <meyering@lucent.com>
25820
25821         * lib/regex.c: Update from libc.
25822
25823 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
25824
25825         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
25826         clash.
25827
25828 2001-02-16  Paul Eggert  <eggert@twinsun.com>
25829
25830         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
25831         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
25832         Reported by Mark Hounschell via Paul Eggert.
25833
25834 2001-02-07  Jim Meyering  <meyering@lucent.com>
25835
25836         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
25837
25838 2001-02-05  Jim Meyering  <meyering@lucent.com>
25839
25840         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
25841         it includes the patch required for `large file' support with at least
25842         HP-UX's 10.20 /bin/cc.
25843
25844 2001-02-03  Jim Meyering  <meyering@lucent.com>
25845
25846         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
25847         AS_IF, now that it works once again (mysteriously).
25848         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
25849
25850 2001-01-30  Jim Meyering  <meyering@lucent.com>
25851
25852         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
25853         * m4/chown.m4: Rename conftestchown to conftest.chown.
25854         * m4/rename.m4: s/conftestdir/conftest.d1/ and
25855         s/conftestdir2/conftest.d2/.
25856         * m4/utimes.m4: s/conftestdata/conftest.data/
25857         Inspired by Pavel Roskin's change in autoconf.
25858
25859 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
25860
25861         * lib/config.charset: Update for FreeBSD 4.2.
25862
25863 2001-01-27  Jim Meyering  <meyering@lucent.com>
25864
25865         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
25866         a use of AS_IF.
25867         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
25868
25869 2001-01-26  Jim Meyering  <meyering@lucent.com>
25870
25871         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
25872         quotearg.c includes it.
25873
25874 2001-01-26  Jim Meyering  <meyering@lucent.com>
25875
25876         * lib/quotearg.c: Include stddef.h.
25877         * lib/quote.c: Include stddef.h.
25878         Reported by Axel Kittenberger.
25879
25880         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
25881         line in double quotes so that it evokes a better diagnostic.
25882         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
25883         Reported by Axel Kittenberger.
25884
25885 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
25886
25887         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
25888         as if it was a `charset'.
25889
25890 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
25891
25892         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
25893         has const.
25894
25895 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
25896
25897         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
25898         to avoid a warning.  Add back 'const' to inptr.
25899
25900 2001-01-20  Jim Meyering  <meyering@lucent.com>
25901
25902         Be sure that headers are checked before used in code compiled
25903         for the type checks.
25904         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
25905         In place of that, invoke jm_CHECK_ALL_TYPES.
25906         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
25907         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
25908         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
25909         The check for ssize_t was mistakenly run before the test for unistd.h.
25910
25911         The configure-time check for stdbool.h was missing.
25912         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
25913         (jm_PREREQ_HASH): New function.
25914
25915 2001-01-17  Jim Meyering  <meyering@lucent.com>
25916
25917         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
25918         for autoconf-2.49c.
25919         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
25920
25921 2001-01-16  Jim Meyering  <meyering@lucent.com>
25922
25923         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
25924         From Bruno Haible.
25925
25926 2001-01-14  Jim Meyering  <meyering@lucent.com>
25927
25928         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
25929         foo and bar.  Create conftestdir/ in the script, not in the C code.
25930         Remove directories in the script, not in the C code.
25931         Remove conftestdir{,2} before trying to create the directory.
25932         Make the entire configure script fail if the mkdir fails.
25933
25934 2001-01-14  Jim Meyering  <meyering@lucent.com>
25935
25936         * lib/rename.c: New file.  From Volker Borchert.
25937         Include stdlib.h, string.h or strings.h, and xalloc.h.
25938         Use strip_trailing_slashes rather than open-coding it.
25939
25940 2001-01-03  Paul Eggert  <eggert@twinsun.com>
25941
25942         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
25943
25944 2001-01-03  Jim Meyering  <meyering@lucent.com>
25945
25946         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
25947         of local `inptr' to avoid warning with some system declarations of
25948         iconv.
25949
25950 2001-01-02  Volker Borchert  <bt@teknon.de>
25951
25952         * m4/rename.m4: New file.
25953         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
25954
25955 2001-01-01  Jim Meyering  <meyering@lucent.com>
25956
25957         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
25958         even on systems with utmpx.h.  It's necessary for the declaration of
25959         utmp's ut_user member.  Reported by Andreas Jaeger.
25960
25961         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
25962         available. They are required for the declarations of getgrgid and
25963         getpwuid resp.
25964         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
25965         Reported by Andreas Jaeger.
25966
25967 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
25968
25969         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
25970         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
25971         so `make install' also works in VPATH builds.
25972
25973 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
25974
25975         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
25976         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
25977         can be used in subdirectories.
25978
25979 2000-12-29  Paul Eggert  <eggert@twinsun.com>
25980
25981         * lib/modechange.c: Do not assume that mode_t uses the
25982         traditional octal encoding.  E.g. "chmod 1 FOO" should set
25983         the other-execute bit of FOO even if S_IXOTH != 1.
25984
25985         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
25986         WOTH, XOTH, ALLM): New macros.
25987         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
25988          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
25989         Use them.
25990         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
25991         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
25992         (mode_compile):
25993         No need to use uintmax_t; unsigned long is long enough.
25994         Don't bother to get suffix since we don't use it.
25995
25996 2000-12-26  Jim Meyering  <meyering@lucent.com>
25997
25998         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
25999         better with autoheader.
26000
26001 2000-12-24  Jim Meyering  <meyering@lucent.com>
26002
26003         * lib/hash.c (is_prime): Return explicit boolean values.
26004         (hash_get_first): Return NULL to appease Irix5.6's 89.
26005         Reported by Nelson Beebe.
26006
26007 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
26008
26009         * lib/localcharset.c (locale_charset): Add support for Win32.
26010
26011 2000-12-18  Paul Eggert  <eggert@twinsun.com>
26012
26013         * lib/physmem.h, lib/physmem.c: New files.
26014
26015         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
26016         (noinst_HEADERS): Add physmem.h.
26017
26018         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
26019         't' for compatibility with Solaris 8 sort.
26020
26021 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
26022
26023         * lib/config.charset: Add support for BeOS.
26024
26025 2000-12-17  Jim Meyering  <meyering@lucent.com>
26026
26027         * m4/dos.m4 (jm_AC_DOS): New file and macro.
26028         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
26029
26030 2000-12-16  Jim Meyering  <meyering@lucent.com>
26031
26032         This bug had a serious impact on chown: `chown N:M FILE' (for integer
26033         N and M) would have treated it like `chown N:N FILE'.
26034
26035         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
26036
26037 2000-12-16  Jim Meyering  <meyering@lucent.com>
26038
26039         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
26040         SHELLS_FILE to a file name that's useful on djgpp systems.
26041         Include stdlib.h.
26042         (ADDITIONAL_DEFAULT_SHELLS): Define.
26043         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
26044         Based mostly on a patch from Prashant TR.
26045
26046 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
26047
26048         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
26049         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
26050         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
26051
26052 2000-12-08  Andreas Schwab  <schwab@suse.de>
26053
26054         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
26055         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
26056
26057 2000-12-07  Jim Meyering  <meyering@lucent.com>
26058
26059         * lib/stripslash.c (ISSLASH): Define.
26060         (strip_trailing_slashes): Use ISSLASH rather than comparing against
26061         `/'.
26062         From Prashant TR.
26063
26064         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
26065         (dir_name_r): Declare this function as static.
26066         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
26067         manifest itself on a name containing a mix of slashes and
26068         backslashes.
26069         Make this function work with names starting with a DOS-style
26070         drive letter and colon prefix.
26071         (dir_name): Append `.' if necessary.
26072         Based mostly on patches from Prashant TR and Eli Zaretskii.
26073
26074         * lib/dirname.h (dir_name_r): Remove prototype.
26075
26076 2000-12-06  Paul Eggert  <eggert@twinsun.com>
26077
26078         * m4/off_t-format.m4: Remove this file.
26079         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
26080
26081 2000-12-06  Jim Meyering  <meyering@lucent.com>
26082
26083         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
26084         replacement strtoull, we may well need the replacement strtoul, too.
26085         Check for declarations of strtoul and strtoull.
26086         Check for strtol.  Mainly as a cue to cause automake to include
26087         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
26088         Check for limits.h -- strtol.c needs it.
26089
26090 2000-12-05  Jim Meyering  <meyering@lucent.com>
26091
26092         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
26093
26094 2000-12-04  Jim Meyering  <meyering@lucent.com>
26095
26096         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
26097         Also include memory.h, stdlib.h, unistd.h if appropriate.
26098         Reported by Andreas Jaeger (conflicting declaration of malloc).
26099
26100 2000-12-02  Jim Meyering  <meyering@lucent.com>
26101
26102         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
26103         * m4/jm-macros.m4 (jm_MACROS): require it.
26104
26105 2000-12-02  Jim Meyering  <meyering@lucent.com>
26106
26107         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
26108
26109 2000-12-01  Paul Eggert  <eggert@twinsun.com>
26110
26111         * lib/memrchr.c: Include <config.h> before any system include file.
26112
26113 2000-11-30  Jim Meyering  <meyering@lucent.com>
26114
26115         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
26116
26117 2000-11-30  Jim Meyering  <meyering@lucent.com>
26118
26119         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
26120
26121 2000-11-29  Paul Eggert  <eggert@twinsun.com>
26122
26123         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
26124
26125 2000-11-26  Jim Meyering  <meyering@lucent.com>
26126
26127         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
26128
26129 2000-11-22  Paul Eggert  <eggert@twinsun.com>
26130
26131         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
26132         size of (size_t) -1; it's not portable.
26133
26134 2000-11-17  Jim Meyering  <meyering@lucent.com>
26135
26136         * lib/strstr.c: Update from GNU libc.
26137
26138 2000-11-17  Akim Demaille  <akim@epita.fr>
26139
26140         * lib/obstack.h: Formatting changes.
26141         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
26142         prevent type checking.
26143         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
26144         cast the value to (void *): assigning a `foo *' to a `void *'
26145         variable is valid.
26146         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
26147
26148 2000-11-16  Jim Meyering  <meyering@lucent.com>
26149
26150         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
26151
26152 2000-11-11  Jim Meyering  <meyering@lucent.com>
26153
26154         * lib/error.c: Add a couple #includes, merging from GNU libc version.
26155
26156 2000-11-10  Jim Meyering  <meyering@lucent.com>
26157
26158         * lib/obstack.h: Update from GNU libc.
26159         * lib/obstack.c: Likewise.
26160
26161 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
26162
26163         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
26164
26165 2000-11-06  Paul Eggert  <eggert@twinsun.com>
26166
26167         * lib/getusershell.c (setusershell): Use rewind rather than
26168         fseek/fseeko, to avoid configuration hassles with fseeko.
26169         Don't bother opening SHELLS_FILE if shellstream is NULL;
26170         it's not necessary.
26171
26172 2000-11-05  Jim Meyering  <meyering@lucent.com>
26173
26174         * lib/makepath.h (make_dir): Declare.
26175         * lib/makepath.c (make_dir): Remove `static' attribute.
26176         Tweak a comment.
26177
26178 2000-11-04  Jim Meyering  <meyering@lucent.com>
26179
26180         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
26181
26182 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
26183
26184         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
26185         last one in a bucket, advance to the next bucket.
26186
26187 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
26188
26189         * lib/fnmatch.c: Do not comment out all the code if we are using
26190         the GNU C library, because in some cases we are replacing buggy
26191         code in the GNU C library itself.
26192
26193 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
26194
26195         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
26196         (regex_compile): Catch bogus \(\1\).
26197
26198 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26199
26200         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
26201         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
26202         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
26203
26204 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26205
26206         * lib/error.h, getline.h, modechange.h:
26207         Remove "2000" from Copyright line, as the file hasn't been
26208         changed this year other than in the copyright notice.
26209
26210         * lib/xalloc.h: Add "2000" to Copyright line, as this file
26211         was changed this year.
26212
26213 2000-10-29  Jim Meyering  <meyering@lucent.com>
26214
26215         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
26216         renaming.
26217         * m4/ls-mntd-fs.m4: Likewise
26218
26219 2000-10-29  Jim Meyering  <meyering@lucent.com>
26220
26221         * lib/xstat.in: Fix grammar in comment.
26222
26223 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
26224
26225         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
26226         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
26227         doesn't define __restrict_arr.
26228
26229 2000-10-28  Jim Meyering  <meyering@lucent.com>
26230
26231         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
26232         (jm_PREREQ_MEMCHR): New function.
26233
26234 2000-10-28  Jim Meyering  <meyering@lucent.com>
26235
26236         * lib/memchr.c: Update from libc.
26237         Adjust for portability:
26238         [HAVE_STDLIB_H]: Include stdlib.h.
26239         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
26240         Undef __memchr, too.
26241         [!weak_alias]: Define __memchr to memchr.
26242
26243         * lib/regex.c: Update from libc.
26244         * lib/regex.h: Likewise.
26245         * lib/getopt1.c: Likewise.
26246         * lib/memcmp.c: Likewise.
26247
26248         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
26249         Avoid using fseek, when possible -- it's broken by design.
26250         Patch by Ulrich Drepper.
26251
26252 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
26253
26254         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
26255         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
26256         Giving in to popular pressure to shut up the compiler with casts.
26257
26258 2000-10-26  Jim Meyering  <meyering@lucent.com>
26259
26260         * lib/strftime.c: Update from libc.
26261
26262 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
26263
26264         * regex.c: More `unsigned char' -> `re_char' changes.
26265         Also change several `int' into `re_wchar_t'.
26266         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
26267         (PUSH_FAILURE_POINTER): Don't cast any more.
26268         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
26269         We want GCC to complain, since this piece of code makes
26270         re_match non-reentrant, which *should* be fixed.
26271         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
26272         (EXTEND_BUFFER): Use RETALLOC.
26273         (SET_LIST_BIT): Don't cast.
26274         (re_wchar_t): New type.
26275         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
26276         that those two functions will always properly return.
26277         (IMMEDIATE_QUIT_CHECK): Cast to void.
26278         (analyse_first): Use recursion rather than an explicit stack.
26279         (re_compile_fastmap): Can't fail anymore.
26280         (re_search_2): Don't check re_compile_fastmap for failure.
26281         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
26282         Now also sets the new value (passed in a new argument).
26283         (re_match_2_internal): Use it.
26284         Also, use a new var `reg' of type size_t when looping through regs
26285         rather than reuse the inappropriate `mcnt'.
26286
26287 2000-10-25  Jim Meyering  <meyering@lucent.com>
26288
26289         * lib/obstack.c: Update from libc.
26290
26291 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
26292
26293         * regex.c (regex_compile): Change the way of handling a range from
26294         a char less than 256 to a char not less than 256.
26295
26296 2000-10-24  Andrew Innes  <andrewi@gnu.org>
26297
26298         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
26299         NT-Emacs only.
26300         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
26301         so that re_search functions only quit when callers expect them to.
26302
26303 2000-10-23  Jim Meyering  <meyering@lucent.com>
26304
26305         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
26306         wrong.  That set_locale call must not have any side effects.
26307         From Paul Eggert.
26308
26309 2000-10-22  Jim Meyering  <meyering@lucent.com>
26310
26311         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
26312         [CYCLIC]: Remove now-unused definition.
26313
26314         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
26315         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
26316         Suggestion from Ulrich Drepper.
26317
26318 2000-10-21  Jim Meyering  <meyering@lucent.com>
26319
26320         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
26321         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
26322         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
26323
26324 2000-10-21  Jim Meyering  <meyering@lucent.com>
26325
26326         * lib/dirname.c (memrchr): Declare if necessary.
26327         (dir_name): Remove the restriction that there be no
26328         trailing slashes.  Now, this code skips past them, effectively
26329         ignoring them.
26330         [TEST_DIRNAME] (main): New unit tests.
26331
26332         * lib/memrchr.c: New file from GNU libc.
26333         Undef __memrchr, too.
26334         [!weak_alias]: Define __memrchr to memrchr.
26335         Guard weak_alias use with `#ifdef weak_alias'.
26336
26337 2000-10-21  Jim Meyering  <meyering@lucent.com>
26338
26339         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
26340         (dir_name): Use dir_name_r.
26341         * lib/dirname.h (dir_name_r): Declare it.
26342
26343 2000-10-17  Jim Meyering  <meyering@lucent.com>
26344
26345         * lib/quote.h (PARAMS): Define and use.
26346         Reported by Akim Demaille.
26347
26348         * lib/getopt.c: Update from libc.
26349
26350 2000-10-16  Jim Meyering  <meyering@lucent.com>
26351
26352         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
26353         setlocale.
26354         From Jan Fedak.
26355
26356 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
26357
26358         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
26359
26360 2000-09-25  Jim Meyering  <meyering@lucent.com>
26361
26362         * lib/md5.h (rol): Define (from GnuPG).
26363
26364         * lib/sha.c: Give credit (GnuPG) where due.
26365         (M): Use rol rather than open-coding it.
26366         Add a FIXME comment.
26367
26368 2000-09-21  Jim Meyering  <meyering@lucent.com>
26369
26370         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
26371         Reported by Michael Stone.
26372
26373 2000-09-20  Jim Meyering  <meyering@lucent.com>
26374
26375         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
26376         (noinst_HEADERS): Add sha.h.
26377         Based on code from Scott G. Miller and from GnuPG.
26378
26379 2000-09-18  Jim Meyering  <meyering@lucent.com>
26380
26381         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
26382         LIBS. Otherwise, everyone ends up linking with -lelf for some
26383         configurations.
26384         Reported by Mike Stone.
26385
26386 2000-09-15  Jim Meyering  <meyering@lucent.com>
26387
26388         * lib/regex.c: Update from libc.
26389
26390 2000-09-10  Jim Meyering  <meyering@lucent.com>
26391
26392         * lib/getopt.c (_getopt_internal): Update from glibc.
26393
26394 2000-09-09  Jim Meyering  <meyering@lucent.com>
26395
26396         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
26397         think it should be used as a general replacement for isascii.
26398         * lib/fnmatch.c: Likewise.
26399         * lib/mbswidth.c: Likewise
26400         * lib/regex.c: Likewise.
26401
26402         Don't use atoi.
26403         * lib/userspec.c: Include sys/param.h and limits.h.
26404         Include xstrtol.h.
26405         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
26406         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
26407         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
26408         UID, GID.  Check range.
26409
26410 2000-09-06  Jim Meyering  <meyering@lucent.com>
26411
26412         * lib/getopt.c (_getopt_internal): Update from glibc.
26413
26414 2000-08-30  Jim Meyering  <meyering@lucent.com>
26415
26416         * lib/strftime.c: Merge in changes from GNU libc.
26417
26418 2000-08-26  Jim Meyering  <meyering@lucent.com>
26419
26420         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
26421         * m4/fpending.m4: New file.
26422
26423 2000-08-26  Jim Meyering  <meyering@lucent.com>
26424
26425         * lib/closeout.c: Include "__fpending.h".
26426         (close_stdout_status): Return right away if there's nothing to flush.
26427
26428         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
26429         * lib/__fpending.c: New file.
26430         * lib/__fpending.h: New file.
26431
26432 2000-08-20  Jim Meyering  <meyering@lucent.com>
26433
26434         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
26435         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
26436         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
26437
26438 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
26439
26440         Improve fileutils installation on systems where running
26441         programs (like install) can't be unlinked.
26442         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
26443         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
26444
26445 2000-08-07  Paul Eggert  <eggert@twinsun.com>
26446
26447         Standardize on "memory exhausted" instead of "Memory exhausted"
26448         or "virtual memory exhausted".
26449         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
26450         "virtual memory exhausted".
26451         * lib/same.c (same_name): Invoke xalloc_die instead of printing
26452         our own message.
26453         * lib/userspec.c (parse_user_spec): Likewise.
26454         * lib/bumpalloc.h: comment fix
26455         * lib/same.c, userspec.c: Include xalloc.h.
26456
26457         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
26458         not char *const and pointing to a constant array.
26459         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
26460         (xrealloc): Comment fix.
26461
26462         * lib/userspec.c (parse_user_spec):
26463         Don't translate a message until just before returning,
26464         to avoid unnecessary translation.
26465
26466 2000-08-07  Jim Meyering  <meyering@lucent.com>
26467
26468         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
26469         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
26470         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
26471         getgroups.c, gethostname.c, getopt.h, group-member.c,
26472         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
26473         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
26474         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
26475         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
26476         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
26477         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
26478         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
26479         yesno.c: Back out Copyright date changes for each file with no change
26480         this year.  This eases coordination with other programs using the same
26481         source code modules.  From Paul Eggert.
26482
26483 2000-08-06  Paul Eggert  <eggert@twinsun.com>
26484
26485         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
26486         not char, for compatibility with glibc 2.1.3 strftime.c.
26487
26488 2000-08-03  Greg McGary  <greg@mcgary.org>
26489
26490         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
26491         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
26492         (EXTEND_BUFFER): Use them.
26493
26494 2000-08-01  Jim Meyering  <meyering@lucent.com>
26495
26496         * lib/dirname.c (ISSLASH): Define.
26497         (BACKSLASH_IS_PATH_SEPARATOR): Define.
26498         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
26499         both `\' and `/' may be use as path separators.
26500         Based on a patch from Prashant TR.
26501
26502 2000-07-31  Paul Eggert  <eggert@twinsun.com>
26503
26504         * lib/quotearg.c (quotearg_n_options): Don't make the initial
26505         slot vector a constant, since it might get modified.
26506
26507 2000-07-31  Jim Meyering  <meyering@lucent.com>
26508
26509         * lib/xmalloc.c: Use `virtual memory exhausted', not
26510         `Memory exhausted'.
26511         * lib/obstack.c (print_and_abort): Likewise.
26512
26513 2000-07-30  Paul Eggert  <eggert@twinsun.com>
26514
26515         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
26516         buffer, so that the caller can always quote one small
26517         component of a "memory exhausted" message in slot 0.
26518         From a suggestion by Jim Meyering.
26519
26520 2000-07-30  Jim Meyering  <meyering@lucent.com>
26521
26522         * lib/makepath.c (make_path): Quote the other instance, too.
26523
26524         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
26525         (STATIC_BUF_SIZE): Define.
26526         (quotearg_n_options): Use only statically allocated storage when
26527         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
26528         than STATIC_BUF_SIZE.
26529
26530 2000-07-29  Jim Meyering  <meyering@lucent.com>
26531
26532         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
26533         * lib/dirname.c (dir_name): Likewise.
26534
26535         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
26536         `/'.
26537
26538         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
26539         (dir_name): Assert that there are no trailing slashes.
26540
26541 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
26542
26543         * lib/mbswidth.h (mbswidth): Add a flags argument.
26544         (mbswidth): New declaration.
26545         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
26546         * lib/mbswidth.c (mbswidth): Add a flags argument.
26547         (mbsnwidth): New function.
26548
26549 2000-07-24  Jim Meyering  <meyering@lucent.com>
26550
26551         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
26552
26553 2000-07-23  Paul Eggert  <eggert@twinsun.com>
26554
26555         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
26556
26557 2000-07-23  Paul Eggert  <eggert@twinsun.com>
26558
26559         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
26560         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
26561         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
26562         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
26563         invoke multibyte primitives.
26564
26565 2000-07-23  Paul Eggert  <eggert@twinsun.com>
26566
26567         * lib/quotearg.c:
26568         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
26569         so that mbstate_t is always defined.
26570
26571         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
26572         be 1 in at least one GCC installation, and this configuration
26573         error is likely to be common.  Ignoring MB_LEN_MAX hurts
26574         performance on hosts that have mbrtowc but have only unibyte
26575         locales, but I assume these hosts are rare.
26576
26577 2000-07-23  Paul Eggert  <eggert@twinsun.com>
26578
26579         * lib/mbswidth.c (_XOPEN_SOURCE):
26580         Don't define; this causes problems on Solaris 7.
26581         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
26582
26583 2000-07-23  Jim Meyering  <meyering@lucent.com>
26584
26585         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
26586         too: getgrgid, getpwuid, getuid.
26587
26588 2000-07-23  Jim Meyering  <meyering@lucent.com>
26589
26590         * lib/basename.c (base_name): Add an assertion.
26591
26592 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
26593
26594         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
26595         shadow its mbsinit function.
26596
26597 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
26598
26599         * lib/mbswidth.h: New file.
26600         * lib/mbswidth.c: New file.
26601         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
26602         (noinst_HEADERS): Add mbswidth.h.
26603
26604 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
26605
26606         * lib/config.charset: Add support for FreeBSD. Improve support for
26607         HP-UX and IRIX 6.
26608
26609 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
26610
26611         * m4/mbswidth.m4: New file.
26612         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
26613
26614 2000-07-15  Jim Meyering  <meyering@lucent.com>
26615
26616         * lib/makepath.c: Include quote.h.
26617         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
26618         corresponding argument in a `quote (...)' call.
26619         Give better diagnostics.
26620
26621         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
26622         (noinst_HEADERS): Add quote.h.
26623
26624         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
26625         from tar's src/misc.c.
26626         * lib/quote.h: New file.  Prototypes for same.
26627
26628 2000-07-14  Paul Eggert  <eggert@twinsun.com>
26629
26630         From a suggestion by Bruno Haible.
26631         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
26632         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
26633         to decide whether to define the BeOS workaround macro;
26634         this adjusts to the change to AC_MBSTATE_T.
26635
26636 2000-07-14  Jim Meyering  <meyering@lucent.com>
26637
26638         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
26639         jm_AC_TYPE_UINTMAX_T.
26640
26641 2000-07-13  Paul Eggert  <eggert@twinsun.com>
26642
26643         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
26644
26645         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
26646         quotearg_buffer_restyled): Add support for
26647         clocale_quoting_style.  Undo previous change to
26648         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
26649         and "{RIGHT QUOTATION MARK}" msgids.
26650
26651 2000-07-10  Paul Eggert  <eggert@twinsun.com>
26652
26653         From a suggestion by Bruno Haible.
26654         * m4/mbstate_t.m4 (AC_MBSTATE_T):
26655         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
26656         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
26657         and mbstate_t, to a single-part test that simply defines mbstate_t.
26658         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
26659         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
26660
26661 2000-07-10  Jim Meyering  <meyering@lucent.com>
26662
26663         * m4/strerror_r.m4: Mirror the correction made in autoconf.
26664
26665         * m4/gnu-source.m4: Output to confdefs.h directly.
26666         Suggestion from Akim Demaille.
26667
26668 2000-07-09  Paul Eggert  <eggert@twinsun.com>
26669
26670         The old behavior of quoting `like this' doesn't look good with
26671         newer, ISO-style fonts.  See:
26672         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
26673
26674         Instead, quote "like this" by default.  Let the translator
26675         tailor the locale-specific quoting behavior by providing
26676         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
26677
26678         * lib/quotearg.c (N_): New macro.
26679         (gettext_default): New function.
26680         (quotearg_buffer_restyled): Use
26681         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
26682         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
26683
26684 2000-07-09  Jim Meyering  <meyering@lucent.com>
26685
26686         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
26687         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
26688
26689         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
26690         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
26691
26692 2000-07-09  Jim Meyering  <meyering@lucent.com>
26693
26694         * lib/Most files: Update copyright dates to include 2000.
26695
26696 2000-07-08  Jim Meyering  <meyering@lucent.com>
26697
26698         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
26699         if not defined.
26700         (xgethostname): Remove now-unnecessary #ifdef.
26701         Move declaration of `err' into loop where it's used.
26702
26703 2000-07-05  Paul Eggert  <eggert@twinsun.com>
26704         and Bruno Haible  <haible@clisp.cons.org>
26705
26706         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
26707         only if the test for an object-type mbstate_t fails.  This
26708         prevents us from mistakenly reporting that mbstate_t is a
26709         system object type after we "#define mbstate_t int" to work
26710         around its lack.
26711
26712 2000-07-05  Paul Eggert  <eggert@twinsun.com>
26713         and Bruno Haible  <haible@clisp.cons.org>
26714
26715         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
26716
26717 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
26718
26719         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
26720         to strerror_r.
26721         Include <ctype.h> for use of isalpha.
26722
26723 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
26724
26725         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
26726         by allocating a larger buffer. Test the gethostname return value for
26727         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
26728         returns an error and ENAMETOOLONG isn't defined.
26729
26730 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
26731
26732         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
26733         dimension.
26734
26735 2000-07-04  Jim Meyering  <meyering@lucent.com>
26736
26737         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
26738         of the deprecated AC_CHECKING.
26739
26740 2000-07-04  Jim Meyering  <meyering@lucent.com>
26741
26742         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
26743         Reported by Bruno Haible.
26744
26745 2000-07-04  Jim Meyering  <meyering@lucent.com>
26746
26747         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
26748         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
26749         lacks mbrtowc.
26750
26751 2000-07-03  Paul Eggert  <eggert@twinsun.com>
26752
26753         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
26754         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
26755
26756 2000-07-03  Paul Eggert  <eggert@twinsun.com>
26757         and Bruno Haible  <haible@clisp.cons.org>
26758
26759         * lib/quotearg.c (mbrtowc):
26760         Assign to *pwc, and return 1 only if result is nonzero.
26761         (iswprint): Use ISPRINT when substituting our own mbrtowc.
26762
26763 2000-07-03  Jim Meyering  <meyering@lucent.com>
26764
26765         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
26766
26767 2000-07-03  Jim Meyering  <meyering@lucent.com>
26768
26769         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
26770         This is necessary to get a definition of e.g., UTMP_FILE on
26771         HP-UX 10.20.
26772         From Bob Proulx.
26773
26774 2000-07-02  Jim Meyering  <meyering@lucent.com>
26775
26776         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
26777
26778         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
26779         AC_LIBOBJ(function_name).
26780         * m4/chown.m4: Likewise.
26781         * m4/fnmatch.m4: Likewise.
26782         * m4/ftruncate.m4: Likewise.
26783         * m4/getgroups.m4: Likewise.
26784         * m4/getline.m4: Likewise.
26785         * m4/group-member.m4: Likewise.
26786         * m4/jm-macros.m4: Likewise.
26787         * m4/lstat.m4: Likewise.
26788         * m4/malloc.m4: Likewise.
26789         * m4/memcmp.m4: Likewise.
26790         * m4/nanosleep.m4: Likewise.
26791         * m4/putenv.m4: Likewise.
26792         * m4/realloc.m4: Likewise.
26793         * m4/regex.m4: Likewise.
26794         * m4/stat.m4: Likewise.
26795         * m4/strftime.m4: Likewise.
26796
26797 2000-07-02  Jim Meyering  <meyering@lucent.com>
26798
26799         * lib/quotearg.c (mbstate_t): Don't define here.
26800
26801 2000-07-02  Jim Meyering  <meyering@lucent.com>
26802
26803         * lib/nanosleep.c (SIGCONT): Define if not already defined.
26804
26805 2000-07-01  Jim Meyering  <meyering@lucent.com>
26806
26807         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
26808
26809 2000-07-01  Jim Meyering  <meyering@lucent.com>
26810
26811         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
26812         problem.
26813
26814 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
26815
26816         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
26817         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
26818
26819 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
26820
26821         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
26822         per change in ../m4/ls-mntd-fs.m4.
26823         (read_filesystem_list): Ignore symbolic links.
26824
26825 2000-06-29  Jim Meyering  <meyering@lucent.com>
26826
26827         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
26828         for declaration of strcmp.
26829
26830         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
26831
26832         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
26833         Avoid warning by casting result to `char *' to remove `const'.
26834
26835 2000-06-28  Jim Meyering  <meyering@lucent.com>
26836
26837         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
26838         included by quotearg.c, for which we perform this test.  From
26839         Bruno Haible.
26840
26841 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
26842
26843         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
26844         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
26845         <utmpx.h> exists, put readutmp.o into LIBOBJS.
26846
26847 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
26848
26849         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
26850
26851 2000-06-26  Paul Eggert  <eggert@twinsun.com>
26852
26853         savedir now sets errno on failure and invokes xmalloc to get memory.
26854         Fix a couple of other minor bugs while we're at it.
26855
26856         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
26857         (NAMLEN): Remove macro.
26858         (malloc, realloc): Remove decls.
26859         (stpcpy): Likewise.
26860         ("xalloc.h"): Include.
26861         (NAME_SIZE_DEFAULT): New macro.
26862         (savedir): Use xmalloc / xrealloc to allocate memory.
26863         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
26864         Skip "" directory entries.
26865         Use strlen to calculate directory entry length, since the old method
26866         is rarely used these days and isn't worth supporting.
26867         Don't use a pointer after freeing it.
26868         Check for integer overflow when calculating allocation size.
26869         Use memcpy to copy entries, instead of stpcpy.
26870         Set errno properly when returning NULL.
26871         Check for readdir error.
26872
26873 2000-06-26  Jim Meyering  <meyering@lucent.com>
26874
26875         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
26876
26877 2000-06-25  Jim Meyering  <meyering@lucent.com>
26878
26879         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
26880         Linux header bug when _XOPEN_SOURCE is defined to 500.
26881
26882 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
26883
26884         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
26885         deficiency.
26886
26887 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
26888
26889         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
26890         Include xalloc.h.
26891         Don't include <stdlib.h>.  Don't declare malloc, realloc.
26892
26893 2000-06-24  Jim Meyering  <meyering@lucent.com>
26894
26895         * m4/strerror_r.m4: Revive this file -- to try out an experimental
26896         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
26897         for which strerror does return char*, but which lacks a conveniently
26898         accessible declaration of the function.  If the compile-test says
26899         strerror_r doesn't work, then resort to a `run'-test that works on
26900         BeOS and segfaults on DEC Unix.
26901
26902 2000-06-24  Jim Meyering  <meyering@lucent.com>
26903
26904         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
26905
26906 2000-06-23  Paul Eggert  <eggert@twinsun.com>
26907
26908         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
26909         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
26910
26911 2000-06-23  Paul Eggert  <eggert@twinsun.com>
26912
26913         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
26914         (mbrtowc, mbstate_t): Define substitutes if
26915         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
26916         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
26917         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
26918
26919 2000-06-23  Jim Meyering  <meyering@lucent.com>
26920
26921         * m4/afs.m4: Add missing AC_MSG_RESULT.
26922         Reported by Bruno Haible.
26923
26924         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
26925         Suggestion from Bruno Haible.
26926
26927 2000-06-23  Jim Meyering  <meyering@lucent.com>
26928
26929         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
26930
26931 2000-06-21  Jim Meyering  <meyering@lucent.com>
26932
26933         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
26934
26935 2000-06-21  Jim Meyering  <meyering@lucent.com>
26936
26937         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
26938         (noinst_HEADERS): Add getstr.h.
26939
26940         * lib/getline.c (getstr): Move into a separate file.
26941         * lib/getstr.c (getstr): New file, extracted from getline.c, with
26942         the following changes: new parameter, delim2; both delim[12]
26943         parameters have type `int', not `char'.  The latter would lose
26944         with 8-bit delimiters.
26945         * lib/getstr.h: New file.
26946
26947 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
26948
26949         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
26950         than 1024, return a memory chunk of least possible size, instead
26951         of size PATH_MAX + 2. In the loop, increment the size proportionally.
26952         Use free/xmalloc instead of xrealloc to avoid copying for very long
26953         paths.
26954
26955 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
26956
26957         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
26958         the empty string.
26959
26960 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
26961
26962         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
26963         address, not strdup.  Include <stdlib.h> and don't declare free().
26964
26965 2000-06-19  Jim Meyering  <meyering@lucent.com>
26966
26967         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
26968
26969 2000-06-18  Jim Meyering  <meyering@lucent.com>
26970
26971         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
26972
26973         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
26974         `checking whether...' message to be consistent with that of the
26975         lstat test.
26976
26977 2000-06-18  Jim Meyering  <meyering@lucent.com>
26978
26979         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
26980         Besides, these days every porting target provides a mkdir function.
26981
26982         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
26983         needed. (this snippet comes from src/system.h).
26984
26985 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
26986
26987         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
26988
26989 2000-06-15  Paul Eggert  <eggert@twinsun.com>
26990
26991         * lib/human.c (adjust_value): New function.
26992         (human_readable_inexact): Apply rounding style even when
26993         printing approximate values.
26994
26995 2000-06-14  Paul Eggert  <eggert@twinsun.com>
26996
26997         * lib/human.c (human_readable_inexact): Allow an input block
26998         size that is not a multiple of the output block size, and vice versa.
26999         Reported by Piergiorgio Sartor.
27000
27001 2000-06-14  Paul Eggert  <eggert@twinsun.com>
27002
27003         * lib/getdate.y (get_date): Apply relative times after time
27004         zone indicator, not before.  Reported by Todd A. Jacobs.
27005
27006 2000-06-13  Jim Meyering  <meyering@lucent.com>
27007
27008         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
27009
27010         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
27011
27012 2000-06-12  Paul Eggert  <eggert@twinsun.com>
27013
27014         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
27015
27016 2000-06-12  Jim Meyering  <meyering@lucent.com>
27017
27018         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
27019         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
27020         optional argument.
27021         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
27022         the optional argument, `lib'.
27023
27024 2000-06-08  Jim Meyering  <meyering@lucent.com>
27025
27026         * m4/largefile.m4: Remove file (now that it's part of autoconf).
27027
27028 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27029
27030         Rewrite largefile configuration so that we don't need to run
27031         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
27032         AC_CANONICAL_HOST in configure.in -- jmm]
27033
27034         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
27035         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
27036         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
27037         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
27038         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
27039         All uses changed.
27040         Instead of inspecting the output of getconf, try to compile the
27041         test program without and with the macro definition.
27042         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
27043         for getconf.  Instead, check for the needed flags by compiling
27044         test programs.
27045
27046 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27047
27048         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
27049
27050 2000-06-04  Jim Meyering  <meyering@lucent.com>
27051
27052         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
27053         SunOS 4.1.4 for which gid_t is an unsigned type.
27054
27055 2000-06-03  Jim Meyering  <meyering@lucent.com>
27056
27057         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
27058         now that autoconf requires that.
27059
27060         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
27061         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
27062         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
27063
27064 2000-06-03  Jim Meyering  <meyering@lucent.com>
27065
27066         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
27067
27068 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27069
27070         * m4/glibc21.m4: New file.
27071         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
27072
27073 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27074
27075         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
27076         newer, don't install charset.alias.
27077         * lib/config.charset: Change the Linux/glibc rules so they become empty
27078         on glibc-2.1 or newer.
27079
27080 2000-06-02  Jim Meyering  <meyering@lucent.com>
27081
27082         * lib/mountlist.c: Back out last change.  Instead, do this...
27083         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
27084         me_dummy member using the same `ignore'-testing code.
27085         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
27086         fs_type strings.
27087         From Mark D. Roth.
27088
27089 2000-05-29  Jim Meyering  <meyering@lucent.com>
27090
27091         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
27092         mounts with the `ignore' attribute.  Based on a patch from
27093         Mark D. Roth.
27094
27095 2000-05-28  Jim Meyering  <meyering@lucent.com>
27096
27097         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
27098         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27099         * m4/stat.m4: Likewise.
27100         * m4/lstat.m4: Likewise.
27101         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
27102
27103         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
27104         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
27105
27106 2000-05-26  Jim Meyering  <meyering@lucent.com>
27107
27108         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
27109
27110 2000-05-24  Jim Meyering  <meyering@lucent.com>
27111
27112         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
27113         autoconf requires that.
27114         * m4/lib-check.m4: Likewise.
27115         * m4/jm-macros.m4: Likewise.
27116         * m4/strftime.m4: Likewise.
27117
27118         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
27119         AC_CHECK_DECLS, now that autoconf requires that.
27120
27121 2000-05-22  Jim Meyering  <meyering@lucent.com>
27122
27123         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27124         * m4/lstat.m4: Likewise.
27125
27126 2000-05-22  Jim Meyering  <meyering@lucent.com>
27127
27128         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
27129
27130 2000-05-20  Jim Meyering  <meyering@lucent.com>
27131
27132         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
27133         (jm_PREREQ): Use it.
27134
27135 2000-05-18  Jim Meyering  <meyering@lucent.com>
27136
27137         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
27138         back, too, since it may have been modified by allocate_entry.
27139         (hash_delete): Rewrite to use neither the assignment operator
27140         nor the comma operator in an if-expression.
27141
27142 2000-05-15  Paul Eggert  <eggert@twinsun.com>
27143
27144         * lib/closeout.c:
27145         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
27146         Remove; no longer needed.
27147         "quotearg.h": Add include.
27148         (file_name): Do not bother to explicitly initialize to NULL; it's less
27149         efficient on some hosts.
27150         (close_stdout_status): Remove test as to whether stdout was already
27151         closed; it breaks for the case "echo x | sort >&-".
27152         Quote file name colons.
27153         Do not assume that _("write error") lacks format strings.
27154
27155 2000-05-15  Jim Meyering  <meyering@lucent.com>
27156
27157         * lib/version-etc.c (version_etc_copyright): Update the copyright
27158         string used in all --version output.
27159
27160 2000-05-14  Jim Meyering  <meyering@lucent.com>
27161
27162         * lib/closeout.c (close_stdout_set_file_name): New function.
27163         (close_stdout_status): Use new file-scoped global.
27164         Return right away if fstat says the stdout file descriptor is invalid.
27165         * lib/closeout.h (close_stdout_set_file_name): Declare.
27166
27167 2000-05-10  Jim Meyering  <meyering@lucent.com>
27168
27169         * lib/closeout.c [default_exit_status]: New file-scoped variable.
27170         (close_stdout_set_status): New function.
27171         * lib/closeout.h (close_stdout_set_status): Declare.
27172
27173 2000-05-09  Jim Meyering  <meyering@lucent.com>
27174
27175         * m4/gettext.m4: Rename this...
27176         * m4/libintl.m4: ...to this.
27177
27178 2000-05-08  Jim Meyering  <meyering@lucent.com>
27179
27180         * lib/long-options.c: Don't include closeout.h.
27181         (parse_long_options): Don't call close_stdout for --version.
27182
27183 2000-05-06  Paul Eggert  <eggert@twinsun.com>
27184
27185         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
27186         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
27187         2.1.3 bug.  This avoids a clash when files like regex.c define
27188         _GNU_SOURCE.
27189
27190 2000-05-06  Jim Meyering  <meyering@lucent.com>
27191
27192         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
27193         (AC_REPLACE_FUNCS): Add strnlen.
27194
27195         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
27196         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
27197
27198         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
27199         AC_SEARCH_LIBS call for nanosleep.
27200         (LIB_NANOSLEEP): Set and AC_SUBST.
27201
27202 2000-05-06  Jim Meyering  <meyering@lucent.com>
27203
27204         * lib/strnlen.c: Undefine __strnlen and strnlen.
27205         [!weak_alias]: Define __strnlen to strnlen.
27206
27207         * lib/atexit.c: New file, from libiberty.
27208
27209 2000-05-06  Jim Meyering  <meyering@lucent.com>
27210
27211         * lib/closeout.c (close_stdout_status): Also check for errors on the
27212         stderr stream.
27213
27214 2000-05-05  Jim Meyering  <meyering@lucent.com>
27215
27216         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
27217         AC_SEARCH_LIBS call for clock_gettime.
27218         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
27219
27220         * m4/search-libs.m4: Update from autoconf.
27221
27222         su doesn't work on Solaris 2.6.
27223         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
27224         <shadow.h>.  Reported by Dragos Harabor.
27225
27226 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
27227
27228         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
27229         memcpy instead of xmalloc, xrealloc, path_concat.
27230         (locale_charset): Treat empty environment variables as absent.
27231         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
27232
27233 2000-05-04  Jim Meyering  <meyering@lucent.com>
27234
27235         * lib/getopt.c: Update from glibc.
27236         * lib/obstack.c: Likewise.
27237         * lib/obstack.h: Likewise.
27238         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
27239         file
27240
27241         * lib/regex.h: Likewise.
27242         * lib/strndup.c: Likewise.
27243         * lib/strnlen.c: New file, from glibc.
27244
27245 2000-05-03  Jim Meyering  <meyering@lucent.com>
27246
27247         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
27248
27249 2000-05-02  Paul Eggert  <eggert@twinsun.com>
27250
27251         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
27252         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
27253         compile-time test, rather than inspecting host and OS, to
27254         decide whether to define _LARGEFILE_SOURCE.
27255
27256 2000-05-01  Jim Meyering  <meyering@lucent.com>
27257
27258         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
27259
27260         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
27261         Based on a patch from Bruno Haible.
27262
27263 2000-05-01  Jim Meyering  <meyering@lucent.com>
27264
27265         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
27266
27267 2000-04-29  Jim Meyering  <meyering@lucent.com>
27268
27269         * lib/path-concat.c: Declare strdup only if it's not defined.
27270         * lib/canon-host.c: Likewise.
27271
27272 2000-04-28  Jim Meyering  <meyering@lucent.com>
27273
27274         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
27275         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
27276         is included first, then limits.h is included by locale.h by libintl.h.
27277         From John David Anglin.
27278
27279 2000-04-25  Jim Meyering  <meyering@lucent.com>
27280
27281         * lib/makepath.c (S_IRWXUGO): Define.
27282         (make_path): Always perform explicit chmod if MODE specifies any
27283         of the `special' permission bits.  Prompted by a bug report against
27284         install from Mate Wierdl and Joost van Baal.
27285
27286 2000-04-18  Jim Meyering  <meyering@lucent.com>
27287
27288         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
27289         (jm_PREREQ): Use it.
27290
27291 2000-04-18  Jim Meyering  <meyering@lucent.com>
27292
27293         * lib/README: New file.
27294
27295         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
27296         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
27297
27298 2000-04-17  Jim Meyering  <meyering@lucent.com>
27299
27300         Get it right :-)
27301         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
27302         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
27303         Suggestion from Akim Demaille.
27304
27305 2000-04-17  Jim Meyering  <meyering@lucent.com>
27306
27307         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
27308         the definition of it to rpl_strftime also defined-away the system's
27309         declaration.
27310
27311 2000-04-15  Jim Meyering  <meyering@lucent.com>
27312
27313         Use `C' to denote so-called `contiguous' files, the same way
27314         that tar does.
27315         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
27316         (ftypelet): Use S_ISCTG.
27317         From Michael Deutschmann.
27318
27319 2000-04-14  Jim Meyering  <meyering@lucent.com>
27320
27321         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
27322         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
27323         clobbered.
27324
27325 2000-04-14  Jim Meyering  <meyering@lucent.com>
27326
27327         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
27328
27329 2000-04-13  Jim Meyering  <meyering@lucent.com>
27330
27331         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
27332         AH_VERBATIM to insert required #ifndef into config.h.in.
27333         Suggestion from Akim Demaille.
27334
27335 2000-04-12  Jim Meyering  <meyering@lucent.com>
27336
27337         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
27338         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
27339         Christian Krackowizer.
27340
27341         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
27342         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
27343         (AC_SYS_LARGEFILE): Require.
27344         (AM_C_PROTOTYPES): Require.
27345
27346 2000-04-08  Jim Meyering  <meyering@lucent.com>
27347
27348         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
27349         names don't conflict.  Reported by Eli Zaretskii.
27350
27351 2000-04-07  Jim Meyering  <meyering@lucent.com>
27352
27353         * lib/putenv.c: Move inclusion of errno.h so it follows that of
27354         sys/types.h, to work around system header problems on AIX 3.2.5.
27355         From Bruno Haible.
27356
27357 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
27358
27359         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
27360         bug.  Deal with the different error behavior of Irix iconv.
27361
27362 2000-04-05  Paul Eggert  <eggert@twinsun.com>
27363
27364         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
27365         IRIX if the installer said otherwise.
27366
27367 2000-04-05  Jim Meyering  <meyering@lucent.com>
27368
27369         Portability tweaks required for ultrix4.3.
27370         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
27371         (jm_CHECK_DECLS): Add getutent to the list of functions.
27372         (_jm_DECL_HEADERS): Add utmpx.h.
27373         From John David Anglin.
27374
27375         * m4/strftime.m4: Back out the 2000-04-02 change.
27376         Instead of that change, simply undefine putenv in the test program.
27377
27378 2000-04-05  Jim Meyering  <meyering@lucent.com>
27379
27380         Portability tweaks required for ultrix4.3.
27381         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
27382         getutent.
27383         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
27384         * lib/canon-host.c: Declare strdup.
27385         * lib/path-concat.c: Likewise.
27386         From John David Anglin.
27387
27388 2000-04-04  Jim Meyering  <meyering@lucent.com>
27389
27390         Be more DOS 8.3-friendly.
27391         * lib/ref-add.sin: Renamed from ref-add.sed.in.
27392         * lib/ref-del.sin: Renamed from ref-del.sed.in.
27393         * lib/Makefile.am: Reflect renaming.
27394         Reported by Eli Zaretskii.
27395
27396         Use a temporary file name that won't clash with `charset.alias'
27397         in the DOS 8.3 name space.
27398         * lib/Makefile.am (charset_tmp): Define.
27399         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
27400         (uninstall-local): Likewise.
27401         Reported by Eli Zaretskii.
27402
27403 2000-04-03  Jim Meyering  <meyering@lucent.com>
27404
27405         * m4/gettext.m4: Fix typo in comment.
27406
27407         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
27408         textutils/configure.in).  Suggestion from Paul Eggert.
27409         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
27410
27411 2000-04-02  Paul Eggert  <eggert@twinsun.com>
27412
27413         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
27414         variable in the shell rather than using putenv, which isn't
27415         portable.  This avoids the configure-time inter-test dependency
27416         on the potentially-renamed putenv function.
27417
27418 2000-03-30  Paul Eggert  <eggert@twinsun.com>
27419
27420         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
27421         before checking struct stat.st_blksize, so that
27422         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
27423
27424 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27425
27426         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
27427         since strftime.c uses HAVE_STRFTIME to decide whether to use
27428         the underlying strftime.
27429
27430 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27431
27432         * lib/time/strftime.c (my_strftime): Make sure we call the system
27433         strftime, not ourselves, when invoking the underlying strftime.
27434
27435 2000-03-24  Jim Meyering  <meyering@lucent.com>
27436
27437         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
27438         (charset_alias): Define.
27439         (install-exec-local): Factor out common code.
27440         (uninstall-local): Split lines longer than 80.
27441         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
27442         (SUFFIXES): Define.
27443         (.sed.in.sed): New rule.  Don't redirect directly to $@.
27444         (CLEANFILES): Add ref-add.sed and ref-del.sed.
27445
27446 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
27447
27448         * lib/config.charset: Output a line containing "Packages using this
27449         file".
27450         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
27451         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
27452         ref-del.sed): New rules.
27453
27454 2000-03-17  Jim Meyering  <meyering@lucent.com>
27455
27456         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
27457         Otherwise, include <strings.h>
27458
27459 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
27460
27461         * lib/unicodeio.c (utf8_wctomb): New function.
27462         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
27463         format instead of in UCS-4 with platform dependent endianness.
27464
27465 2000-03-10  Jim Meyering  <meyering@lucent.com>
27466
27467         * m4/lib-check.m4: Look for getspnam in -lgen, too.
27468         From Marco Franzen.
27469
27470 2000-03-07  Paul Eggert  <eggert@twinsun.com>
27471
27472         * lib/savedir.c (savedir): Work even if directory size is
27473         negative; this can happen with some screwy NFS configurations.
27474
27475 2000-03-06  Jim Meyering  <meyering@lucent.com>
27476
27477         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
27478         if it's NULL (because we ran out of memory).  From Bruno Haible.
27479
27480 2000-03-05  Jim Meyering  <meyering@lucent.com>
27481
27482         * lib/localcharset.c ("path-concat.h"): Include.
27483         (get_charset_aliases): Use path_concat instead of ANSI string
27484         concatenation.
27485
27486         * lib/unicodeio.h (PARAMS): Define.
27487         Use it to guard prototype.
27488
27489 2000-03-04  Jim Meyering  <meyering@lucent.com>
27490
27491         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
27492         for lib/localcharset.c.
27493
27494 2000-03-04  Jim Meyering  <meyering@lucent.com>
27495
27496         * lib/Makefile.am (install-exec-local): Create $(libdir) before
27497         installing into it.
27498         (uninstall-local): Uncomment this rule so `make distcheck' works
27499         once again.
27500
27501         * lib/unicodeio.c (<errno.h>): Include it.
27502         (errno): Declare if not defined.
27503
27504         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
27505
27506         * lib/config.charset: New version, incorporating remarks from a linux
27507         i18n mailing list.  From Bruno Haible.
27508
27509 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
27510
27511         * m4/codeset.m4: New file.
27512         * m4/iconv.m4: New file.
27513         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
27514
27515 2000-03-03  Jim Meyering  <meyering@lucent.com>
27516
27517         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
27518
27519 2000-03-02  Jim Meyering  <meyering@lucent.com>
27520
27521         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
27522         the messages come out on separate lines.
27523
27524         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
27525         rather than jm_CHECK_DECLARATIONS.
27526         * m4/decl.m4: Remove now-unused file.
27527
27528         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
27529         geteuid.
27530
27531 2000-03-02  Jim Meyering  <meyering@lucent.com>
27532
27533         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
27534
27535 2000-03-01  Jim Meyering  <meyering@lucent.com>
27536
27537         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
27538         * lib/unicodeio.c: Likewise.
27539
27540 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
27541
27542         * lib/config.charset: New file.
27543         * lib/localcharset.c: New file.
27544         * lib/unicodeio.h, lib/unicodeio.c: New files.
27545         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
27546         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
27547         (noinst_HEADERS): Add unicodeio.h.
27548         (all-local, install-exec-local, charset.alias): New targets.
27549
27550 2000-02-28  Paul Eggert  <eggert@twinsun.com>
27551
27552         * lib/quotearg.c (ALERT_CHAR): New macro.
27553         (quotearg_buffer_restyled): Use it.
27554
27555 2000-02-27  Jim Meyering  <meyering@lucent.com>
27556
27557         * m4/check-decl.m4: Add getenv to the list.
27558
27559 2000-02-27  Jim Meyering  <meyering@lucent.com>
27560
27561         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
27562         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
27563
27564         * lib/backupfile.c: Guard inclusion of stdlib.h with
27565         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
27566         Declare malloc if needed.
27567
27568         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
27569         `#ifndef HAVE_DECL..'
27570         now that autoconf always defines the HAVE_DECL_ symbols.
27571         * lib/human.c: Likewise.
27572         * lib/same.c: Likewise.
27573         * lib/strtoumax.c: Likewise.
27574
27575         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
27576         declaration check was not run.
27577         * lib/hash.c: Likewise.
27578         * lib/human.c: Likewise.
27579         * lib/same.c: Likewise.
27580         * lib/strtoumax.c: Likewise.
27581
27582         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
27583         `.', then first look up the entire `.'-containing string as a login
27584         name.
27585
27586 2000-02-23  Jim Meyering  <meyering@lucent.com>
27587
27588         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
27589         in place of my hack.
27590
27591 2000-02-18  Paul Eggert  <eggert@twinsun.com>
27592
27593         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
27594         (textint): New typedef.
27595         (parser_control): Member year changed from int to textint.
27596         All uses changed.
27597         (YYSTYPE): Removed; replaced by %union with int and textint members.
27598         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
27599         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
27600         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
27601         (tSNUMBER, tUNUMBER): Now of type <textintval>.
27602         (date, number, to_year): Use width of number in digits, not its value,
27603         to determine whether it's a 2-digit year, or a 2-digit time.
27604         (yylex): Store number of digits of numeric tokens.
27605         Reported by John Kendall.
27606
27607         (parser_control): Changed from struct parser_control to typedef (for
27608         consistency).  All uses changed.
27609
27610         (tID): Removed; not used.
27611         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
27612
27613 2000-02-14  Paul Eggert  <eggert@twinsun.com>
27614
27615         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
27616         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
27617
27618 2000-02-12  Jim Meyering  <meyering@lucent.com>
27619
27620         * lib/userspec.c (ISDIGIT): Define it.
27621         (isdigit): Remove definition.
27622         (is_number): Use ISDIGIT, not isdigit.
27623         <libintl.h>: Include.
27624         (_ and N_): Define.
27625         (parse_user_spec): Mark translatable strings.
27626
27627 2000-02-10  Jim Meyering  <meyering@lucent.com>
27628
27629         With these changes, nanosleep.[ch] are finally enough like the other
27630         lib/* replacement files to compile on a few more losing systems.
27631
27632         * lib/nanosleep.h: Don't include config.h.
27633         Remove prototype from declaration of nanosleep.
27634         (PARAMS): Remove now-unneeded definition.
27635         * lib/nanosleep.c: #undef nanosleep.
27636         (rpl_nanosleep): Rename from nanosleep.
27637
27638 2000-02-10  Jim Meyering  <meyering@lucent.com>
27639
27640         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
27641         gnu_nanosleep to rpl_nanosleep.
27642
27643 2000-02-09  Jim Meyering  <meyering@lucent.com>
27644
27645         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
27646         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
27647
27648 2000-02-08  Akim Demaille  <akim@epita.fr>
27649
27650         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
27651         `[' and `]' and remove uses of `changequote'.
27652         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
27653         (AC_SYS_LARGEFILE): Likewise.
27654         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
27655         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
27656         of changequote.
27657         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
27658         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
27659         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
27660         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
27661
27662 2000-02-05  Jim Meyering  <meyering@lucent.com>
27663
27664         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
27665         Remove explicit use of AC_HEADER_TIME.  It is required by
27666         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
27667         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
27668         in autoconf whereby the expansion of the latter ended up preceding
27669         the expansion of its prerequisite, AC_HEADER_TIME.
27670         Reported by Volker Borchert.
27671
27672 2000-02-03  Jim Meyering  <meyering@lucent.com>
27673
27674         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
27675
27676 2000-02-03  Jim Meyering  <meyering@lucent.com>
27677
27678         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
27679         rather than with `#if HAVE_UTMPNAME'.
27680
27681 2000-02-02  Jim Meyering  <meyering@lucent.com>
27682
27683         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
27684         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
27685         Reported by Eli Zaretskii.
27686
27687 2000-02-01  Jim Meyering  <meyering@lucent.com>
27688
27689         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
27690
27691 2000-01-31  Jim Meyering  <meyering@lucent.com>
27692
27693         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
27694         functions.  Add the time.h and sys/time.h headers along with the
27695         AC_REQUIRE'ment of AC_HEADER_TIME.
27696
27697 2000-01-31  Jim Meyering  <meyering@lucent.com>
27698
27699         * lib/nanosleep.h (nanosleep): Guard declaration with
27700         `#if ! HAVE_DECL_NANOSLEEP'.
27701         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
27702         the declaration in that vendor's sys/timers.h.
27703         Reported by Christian Krackowizer.
27704
27705         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
27706         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
27707         (ISPRINT): Likewise.
27708         Reported by Tom Tromey.
27709
27710 2000-01-30  Jim Meyering  <meyering@lucent.com>
27711
27712         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
27713
27714         * m4/prereq.m4 (utmp_includes): Define.
27715         Check for ut_user and ut_name members in both struct utmpx
27716         and struct utmp.
27717
27718 2000-01-30  Jim Meyering  <meyering@lucent.com>
27719
27720         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
27721         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
27722         header files where only utmpx.ut_user is declared.
27723
27724         * lib/readutmp.h (UT_USER): Define.
27725
27726 2000-01-29  Jim Meyering  <meyering@lucent.com>
27727
27728         * m4/lib-check.m4: New file containing library-related checks from
27729         fileutils and sh-utils (textutils had none).
27730
27731 2000-01-28  Jim Meyering  <meyering@lucent.com>
27732
27733         * m4/perl.m4: Change format of warning message to look more like that
27734         from the missing script.  Suggestion from François Pinard.
27735
27736 2000-01-25  Jim Meyering  <meyering@lucent.com>
27737
27738         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
27739         well as time.h in the compile check.
27740         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
27741         Fix typo in cross-compiling case: s/yes/no/.
27742
27743 2000-01-23  Jim Meyering  <meyering@lucent.com>
27744
27745         * m4/jm-macros.m4: Move df-related tests here from
27746         fileutils/configure.in
27747
27748         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
27749         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
27750
27751         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
27752         s/space/ac_fsusage_space/.
27753         (jm_FILE_SYSTEM_USAGE): Take two parameters.
27754
27755         * m4/ftruncate.m4: New file (derived from part of
27756         fileutils/configure.in).
27757         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
27758         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
27759
27760         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
27761         AC_SUBST these here, rather than just in sh-util/configure.in, so
27762         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
27763         all the same.
27764         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
27765         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
27766         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
27767         (AC_SUBST(POW_LIBM)): Likewise.
27768         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
27769
27770 2000-01-23  Jim Meyering  <meyering@lucent.com>
27771
27772         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
27773         obstack.c.
27774
27775 2000-01-22  Jim Meyering  <meyering@lucent.com>
27776
27777         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
27778
27779         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
27780
27781         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
27782         configure.in
27783         (AC_CHECK_HEADERS): Likewise for sh-utils.
27784         (AC_CHECK_HEADERS): Likewise for textutils.
27785         Merge the three lists of headers.
27786
27787         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
27788         from fileutils' configure.in.
27789
27790         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
27791         code. Moved tests into their own function (_jm_DECL_HEADERS) in
27792         check-decl.m4.
27793
27794         * m4/check-decl.m4: Use #if rather than #ifdef.
27795         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
27796         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
27797         (_jm_DECL_HEADERS): Define new function.
27798         (jm_CHECK_DECLARATIONS): Require it.
27799
27800 2000-01-22  Jim Meyering  <meyering@lucent.com>
27801
27802         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
27803         [! HAVE_DECL_STRTOULL]: Declare strtoull.
27804         Required for some AIX systems.  Reported by Christian Krackowizer.
27805         [TESTING] (main): New function.
27806
27807         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
27808         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
27809         letters.
27810
27811         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
27812         iswprint.
27813
27814         * lib/strverscmp.c (ISDIGIT): Define.
27815         (strverscmp): Use ISDIGIT, not isdigit.
27816
27817 2000-01-19  Jim Meyering  <meyering@lucent.com>
27818
27819         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
27820         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
27821         defines `struct timespec' in <sys/time.h>
27822
27823         * m4/c-bs-a.m4: Remove uses of changequote altogether.
27824         Thanks to Akim for explaining.
27825
27826 2000-01-17  Paul Eggert  <eggert@twinsun.com>
27827
27828         * lib/nanosleep.c (nanosleep):
27829         Don't use SA_INTERRUPT to decide whether to call sigaction, as
27830         POSIX.1 doesn't require SA_INTERRUPT and some systems
27831         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
27832         it's been part of POSIX.1 since day 1 (in 1988).
27833
27834 2000-01-17  Jim Meyering  <meyering@lucent.com>
27835
27836         * lib/interlock: Remove unused file.  Reported by François Pinard.
27837
27838 2000-01-16  Paul Eggert  <eggert@twinsun.com>
27839
27840         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
27841         alert, backslash, formfeed, and vertical tab unnecessarily in
27842         shell quoting style.
27843
27844 2000-01-16  Jim Meyering  <meyering@lucent.com>
27845
27846         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
27847         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
27848         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
27849         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
27850
27851 2000-01-16  Jim Meyering  <meyering@lucent.com>
27852
27853         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
27854         because the latter didn't work.
27855
27856 2000-01-15  Jim Meyering  <meyering@lucent.com>
27857
27858         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
27859         (AC_REPLACE_FUNCS): Add memcpy and memset.
27860         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
27861         Add strpbrk.
27862         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
27863
27864 2000-01-12  Jim Meyering  <meyering@lucent.com>
27865
27866         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
27867         (jm_PREREQ): Use it.
27868         (jm_PREREQ_READUTMP): New macro.
27869         (jm_PREREQ): Use it.
27870
27871 2000-01-11  Paul Eggert  <eggert@twinsun.com>
27872
27873         Quote multibyte characters correctly.
27874         * m4/c-bs-a.m4: New file.
27875         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
27876         (jm_PREREQ): Use it.
27877
27878 2000-01-11  Paul Eggert  <eggert@twinsun.com>
27879
27880         * m4/uintmax_t.m4: Port to autoconf 2.13.
27881
27882 2000-01-08  Jim Meyering  <meyering@ascend.com>
27883
27884         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
27885         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
27886
27887 2000-01-04  Jim Meyering  <meyering@ascend.com>
27888
27889         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
27890         jm_STRUCT_DIRENT_D_TYPE.
27891         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
27892         jm_STRUCT_DIRENT_D_INO.
27893         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
27894         jm_STRUCT_UTIMBUF.
27895         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
27896         renamings.
27897         * m4/utime.m4: Likewise.
27898
27899         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
27900         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
27901
27902 2000-01-03  Paul Eggert  <eggert@twinsun.com>
27903
27904         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
27905         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
27906
27907 2000-01-02  Jim Meyering  <meyering@ascend.com>
27908
27909         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
27910         remember if this is necessary.
27911
27912 1999-12-26  Jim Meyering  <meyering@ascend.com>
27913
27914         * m4/jm-macros.m4: Use it here.
27915         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
27916
27917 1999-12-23  Jim Meyering  <meyering@ascend.com>
27918
27919         * m4/jm-macros.m4: Check for clock_gettime (moved from
27920         fileutils/configure.in)
27921         Check for gettimeofday.
27922
27923 1999-12-20  Jim Meyering  <meyering@ascend.com>
27924
27925         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
27926         autoconf-2.14a-1999-12-20.
27927
27928 1999-12-19  Jim Meyering  <meyering@ascend.com>
27929
27930         * m4/lstat-slash.m4: New file.
27931         * m4/jm-macros.m4: Use the new macro:
27932         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27933
27934 1999-12-07  Jim Meyering  <meyering@ascend.com>
27935
27936         * m4/perl.m4: Require that File::Compare be available, too.
27937         Too many systems seem to lack it.
27938
27939         * m4/strftime.m4: Add checks for most of the cpp macros tested in
27940         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
27941
27942 1999-11-18  Paul Eggert  <eggert@twinsun.com>
27943
27944         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
27945         problem with the QNX 4.25 shell, which doesn't propagate exit
27946         status of failed commands inside shell assignments.
27947
27948 1999-11-17  Jim Meyering  <meyering@ascend.com>
27949
27950         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
27951
27952 1999-11-07  Jim Meyering  <meyering@ascend.com>
27953
27954         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
27955
27956 1999-11-06  Jim Meyering  <meyering@ascend.com>
27957
27958         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
27959         * m4/jm-macros.m4 (jm_MACROS): Use it here.
27960
27961 1999-11-05  Jim Meyering  <meyering@ascend.com>
27962
27963         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
27964         configure.in of textutils, fileutils, and sh-utils into this one
27965         (shared between those packages) file.
27966         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
27967         AC_STRUCT_ST_BLKSIZE.
27968
27969 1999-11-03  Jim Meyering  <meyering@ascend.com>
27970
27971         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
27972         of AC_CHECK_TYPE checks includes unistd.h.
27973         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
27974         Suggestion from Akim Demaille.
27975
27976 1999-10-30  Jim Meyering  <meyering@ascend.com>
27977
27978         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
27979         m4-quoted string.
27980         * m4/ls-mntd-fs.m4: Likewise.
27981         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
27982         * m4/jm-winsz1.m4: Likewise.
27983
27984         * m4/const.m4: Remove file, since the fix made it into the experimental
27985         version of autoconf.
27986         * m4/mktime.m4: Likewise.
27987
27988         * m4/check-type.m4: Remove file, now that the latest version of
27989         AC_CHECK_TYPE takes a third arg to specify additional #includes.
27990
27991         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
27992         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
27993         AC_CHECK_TYPE.
27994
27995 1999-10-04  Jim Meyering  <meyering@ascend.com>
27996
27997         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
27998
27999 1999-09-22  Paul Eggert  <eggert@twinsun.com>
28000
28001         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
28002         2.95.1 bug with HP-UX 10.20.
28003
28004 1999-09-17  Jim Meyering  <meyering@ascend.com>
28005
28006         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
28007         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
28008         due to missing strdup (against sh-utils-2.0).
28009
28010 1999-08-29  Jim Meyering  <meyering@ascend.com>
28011
28012         * m4/jm-macros.m4: Require jm_BISON.
28013         * m4/bison.m4: New file.
28014
28015 1999-08-17  Paul Eggert  <eggert@twinsun.com>
28016
28017         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
28018         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
28019
28020 1999-08-05  Jim Meyering  <meyering@ascend.com>
28021
28022         * m4/getline.m4: Rename test file from conftestdata to conftest.data
28023         to avoid conflicts with `conftest' on 8+3 filesystems.
28024         Suggestion from Eli Zaretskii.
28025
28026 1999-08-04  Jim Meyering  <meyering@ascend.com>
28027
28028         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
28029         fileutils and sh-utils (textutils's getline test was inadequate).
28030         (AM_FUNC_GETLINE): Run this test.
28031         (AC_CHECK_FUNCS): Check for getdelim.
28032         Reported by Bob Proulx.
28033
28034 1999-08-02  Jim Meyering  <meyering@ascend.com>
28035
28036         * m4/jm-macros.m4: Add a comment.
28037
28038 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28039
28040         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
28041         <inttypes.h> defines strtoumax as a macro (and not as a
28042         function).
28043
28044 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28045
28046         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
28047         that we can shift, multiply and divide unsigned long long
28048         values; Ultrix cc can't do it.
28049
28050 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28051
28052         * m4/mktime.m4: New file, which is a preview of what should appear
28053         in the next public autoconf release.
28054
28055 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28056
28057         * m4/lfs.m4: Remove this file.
28058         * m4/largefile.m4: New file.  It contains the old contents of
28059         lfs.m4, except that all names with prefix AC_LFS have been
28060         changed to use the prefix AC_SYS_LARGEFILE instead, to be
28061         compatible with future autoconf versions.  Also, some minor m4
28062         quoting problems have been fixed.
28063
28064 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28065
28066         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
28067         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
28068         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
28069         and simplify the shell code.
28070
28071 1999-08-01  Jim Meyering  <meyering@ascend.com>
28072
28073         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
28074         m4.
28075
28076 1999-07-20  Jim Meyering  <meyering@ascend.com>
28077
28078         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
28079
28080 1999-07-15  Jim Meyering  <meyering@ascend.com>
28081
28082         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
28083
28084 1999-05-22  Jim Meyering  <meyering@ascend.com>
28085
28086         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
28087
28088 1999-05-20  Jim Meyering  <meyering@ascend.com>
28089
28090         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
28091         Add a colon after each `then' in case $4 is empty.
28092
28093 1999-05-16  Jim Meyering  <meyering@ascend.com>
28094
28095         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
28096
28097 1999-05-10  Jim Meyering  <meyering@ascend.com>
28098
28099         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
28100
28101         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
28102         AC_FUNC_MKTIME.
28103
28104 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
28105
28106         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
28107
28108 1999-05-04  Paul Eggert  <eggert@twinsun.com>
28109
28110         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
28111         not CPPFLAGS, so that linking works correctly in IRIX.
28112
28113 1999-04-30  Paul Eggert  <eggert@twinsun.com>
28114
28115         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
28116
28117 1999-04-20  Paul Eggert  <eggert@twinsun.com>
28118
28119         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
28120         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
28121         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
28122         jm_AC_TYPE_UNSIGNED_LONG_LONG.
28123         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
28124
28125         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
28126
28127 1999-04-20  Jim Meyering  <meyering@ascend.com>
28128
28129         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
28130         AC_REPLACE xstroull if necessary.  From Paul Eggert.
28131         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
28132
28133 1999-04-18  Jim Meyering  <meyering@ascend.com>
28134
28135         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
28136         * m4/jm-macros.m4: Use it.
28137
28138 1999-04-06  Jim Meyering  <meyering@ascend.com>
28139
28140         * m4/strftime.m4: Remove test for %f.
28141
28142 1999-03-29  Jim Meyering  <meyering@ascend.com>
28143
28144         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
28145         superset of the AC_TYPE_* checks in the textutils, fileutils,
28146         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
28147         AC_TYPE_PID_T.
28148
28149 1999-03-28  Jim Meyering  <meyering@ascend.com>
28150
28151         * m4/jm-macros.m4: Define GNU_PACKAGE here.
28152         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
28153         replaced e.g., in the *.sh files of the sh-utils.
28154
28155 1999-03-20  Jim Meyering  <meyering@ascend.com>
28156
28157         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
28158         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
28159         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
28160
28161 1999-03-19  Jim Meyering  <meyering@ascend.com>
28162
28163         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
28164
28165 1999-03-12  Jim Meyering  <meyering@ascend.com>
28166
28167         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
28168
28169 1999-03-07  Jim Meyering  <meyering@ascend.com>
28170
28171         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
28172         declared.
28173
28174 1999-02-17  Jim Meyering  <meyering@ascend.com>
28175
28176         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
28177         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
28178
28179 1999-02-07  Jim Meyering  <meyering@ascend.com>
28180
28181         * m4/group-member.m4: New file -- extracted from sh-utils'
28182         configure.in.
28183
28184         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
28185         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
28186
28187 1999-02-06  Jim Meyering  <meyering@ascend.com>
28188
28189         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
28190         * m4/fnmatch.m4: Likewise.
28191         * m4/getgroups.m4: Likewise.
28192         * m4/lstat.m4: Likewise.
28193         * m4/malloc.m4: Likewise.
28194         * m4/putenv.m4: Likewise.
28195         * m4/realloc.m4: Likewise.
28196         * m4/regex.m4: Likewise.
28197         * m4/stat.m4: Likewise.
28198         * m4/strftime.m4: Likewise.
28199         Suggestion from Alain Magloire.
28200
28201         * m4/chown.m4: Use `.$ac_objext', not `.o'.
28202         * m4/fnmatch.m4: Likewise.
28203         * m4/getgroups.m4: Likewise.
28204         * m4/getline.m4: Likewise.
28205         * m4/lstat.m4: Likewise.
28206         * m4/malloc.m4: Likewise.
28207         * m4/memcmp.m4: Likewise.
28208         * m4/putenv.m4: Likewise.
28209         * m4/realloc.m4: Likewise.
28210         * m4/regex.m4: Likewise.
28211         * m4/stat.m4: Likewise.
28212         * m4/strftime.m4: Likewise.
28213         Suggestion from Alain Magloire.
28214
28215         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
28216         an argument.
28217
28218         * m4/regex.m4: Add a run-time Test for proper operation of
28219         re_compile_pattern.
28220
28221 1999-01-31  Jim Meyering  <meyering@ascend.com>
28222
28223         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
28224
28225 1999-01-30  Jim Meyering  <meyering@ascend.com>
28226
28227         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
28228
28229         * m4/jm-mktime.m4: Make this a wrapper around the official
28230         AM_FUNC_MKTIME rather than my private copy, now that the official one
28231         is up to date.
28232         * m4/mktime.m4: Remove file.
28233
28234         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
28235         * m4/uptime.m4: Likewise.
28236         * m4/uintmax_t.m4: Likewise.
28237
28238 1999-01-28  Jim Meyering  <meyering@ascend.com>
28239
28240         * m4/jm-macros.m4: Use jm_AFS.
28241         * m4/afs.m4: New file (from fileutils' configure.in).
28242
28243         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
28244         * m4/chown.m4: Likewise.
28245         * m4/d-ino.m4: Likewise.
28246         * m4/d-type.m4: Likewise.
28247         * m4/fnmatch.m4: Likewise.
28248         * m4/getgroups.m4: Likewise.
28249         * m4/gettext.m4: Likewise.
28250         * m4/jm-mktime.m4: Likewise.
28251         * m4/jm-winsz2.m4: Likewise.
28252         * m4/lcmessage.m4: Likewise.
28253         * m4/ls-mntd-fs.m4: Likewise.
28254         * m4/malloc.m4: Likewise.
28255         * m4/memcmp.m4: Likewise.
28256         * m4/putenv.m4: Likewise.
28257         * m4/realloc.m4: Likewise.
28258         * m4/st_mtim.m4: Likewise.
28259         * m4/strftime.m4: Likewise.
28260
28261 1999-01-16  Jim Meyering  <meyering@ascend.com>
28262
28263         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
28264         (ARGMATCH_DIE_DECL): Define.
28265
28266 1999-01-12  Jim Meyering  <meyering@ascend.com>
28267
28268         * m4/Makefile.am.in: Rewrite to avoid using fmt.
28269         Reported by Lars Hecking.
28270
28271 1999-01-10  Jim Meyering  <meyering@ascend.com>
28272
28273         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
28274         gross kludge.
28275         * m4/inttypes_h.m4: Likewise.
28276         * m4/lstat.m4: Likewise.
28277         * m4/malloc.m4: Likewise.
28278         * m4/readdir.m4: Likewise.
28279         * m4/realloc.m4: Likewise.
28280         * m4/st_dm_mode.m4: Likewise.
28281         * m4/stat.m4: Likewise.
28282         * m4/utimbuf.m4: Likewise.
28283         * m4/utimes.m4: Likewise.
28284
28285         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
28286         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
28287         comments in config.h.in are meaningful.
28288
28289         * m4/jm-macros.m4: Require autoconf-2.13 here.
28290
28291         * m4/regex.m4: By default, don't use the included regex.c on systems
28292         with glibc 2.  Suggestion from Uli Drepper.
28293
28294 1999-01-02  Jim Meyering  <meyering@ascend.com>
28295
28296         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
28297
28298 1998-12-18  Jim Meyering  <meyering@ascend.com>
28299
28300         * m4/Makefile.am.in (Makefile.am): Simplify rule.
28301         Based on a suggestion from Lars Hecking.
28302
28303 1998-11-16  Paul Eggert  <eggert@twinsun.com>
28304
28305         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
28306
28307 1998-11-16  Jim Meyering  <meyering@ascend.com>
28308
28309         * m4/lfs.m4: Double-quote the `uname...` expression.
28310
28311 1998-11-14  Jim Meyering  <meyering@ascend.com>
28312
28313         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
28314         * m4/stat.m4: Likewise.
28315
28316 1998-11-03  Jim Meyering  <meyering@ascend.com>
28317
28318         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
28319         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
28320
28321 1998-10-18  Jim Meyering  <meyering@ascend.com>
28322
28323         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
28324
28325 1998-10-17  Jim Meyering  <meyering@ascend.com>
28326
28327         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
28328         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
28329         calls for those previously hard-coded headers.  Instead, take a new
28330         parameter.
28331         (jm_CHECK_DECLARATIONS): Reflect interface change.
28332         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
28333         (jm_CHECK_DECL_LOCALTIME_R): New macro.
28334
28335         * m4/mktime.m4: Test for spring-forward gap before long-running test.
28336
28337 1998-10-14  Jim Meyering  <meyering@ascend.com>
28338
28339         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
28340         instead of "TZ=America/Vancouver".  From Paul Eggert.
28341
28342 1998-10-11  Jim Meyering  <meyering@ascend.com>
28343
28344         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
28345         This adds a test for a recently added compatibility fix for mktime.c.
28346         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
28347
28348 1998-09-27  Jim Meyering  <meyering@ascend.com>
28349
28350         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
28351
28352         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
28353         ../configure.in, including a change from Gordon Matzigkeit to allow
28354         cross-compiling for the Hurd.
28355
28356         * m4/glibc.m4: New file/macro to test for the GNU C Library
28357         versions 1 and 2.  From Gordon Matzigkeit.
28358         Indent.
28359
28360 1998-09-21  Jim Meyering  <meyering@ascend.com>
28361
28362         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
28363
28364 1998-08-18  Paul Eggert  <eggert@twinsun.com>
28365
28366         Port nanosecond-resolution times to UnixWare 2.1.2 and
28367         pedantic Solaris 2.6.
28368
28369         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
28370         AC_STRUCT_ST_MTIM.
28371         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
28372         Generate name of ns member, instead of just 1 or undef.
28373         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
28374
28375 1998-08-15  Jim Meyering  <meyering@ascend.com>
28376
28377         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
28378         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
28379         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
28380         instead of jm_TYPE_SSIZE_T.
28381
28382 1998-08-12  Jim Meyering  <meyering@ascend.com>
28383
28384         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
28385
28386 1998-08-02  Jim Meyering  <meyering@ascend.com>
28387
28388         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
28389         in acconfig.h manually.
28390
28391 1998-07-31  Paul Eggert  <eggert@twinsun.com>
28392
28393         * m4/st_mtim.m4: New file.
28394
28395 1998-07-28  Jim Meyering  <meyering@ascend.com>
28396
28397         * m4/utimes.m4: Undef stat.
28398
28399 1998-07-25  Jim Meyering  <meyering@ascend.com>
28400
28401         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
28402         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
28403
28404 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
28405
28406         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
28407         uid and gid actually remain unchanged.
28408
28409 1998-07-07  Jim Meyering  <meyering@ascend.com>
28410
28411         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
28412
28413 1998-07-04  Jim Meyering  <meyering@ascend.com>
28414
28415         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
28416         to prove that this macro can be used in packages without regex.c.
28417
28418 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
28419
28420         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
28421         is to be used.
28422
28423 1998-07-03  Jim Meyering  <meyering@ascend.com>
28424
28425         * m4/gettext.m4: Add -lintl if it's found to be necessary.
28426
28427         * m4/gettext.m4: New file -- from gettext-0.10.35.
28428         * m4/lcmessage.m4: Likewise.
28429         * m4/progtest.m4: Likewise.
28430
28431         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
28432         * m4/jm-macros.m4: Require the new macro.
28433
28434 1998-06-29  Jim Meyering  <meyering@ascend.com>
28435
28436         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
28437         for the definition of NGROUPS (used in a system header included
28438         by sys/mount.h).
28439
28440 1998-06-28  Jim Meyering  <meyering@ascend.com>
28441
28442         * m4/ls-mntd-fs.m4: New file.
28443         * m4/fstypename.m4: New file.
28444
28445         * m4/jm-macros.m4: Require the new macro.
28446         * m4/jm-glibc-io.m4: New file.
28447
28448 1998-05-19  Jim Meyering  <meyering@ascend.com>
28449
28450         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
28451         * m4/lchown.m4: New file.
28452
28453         * m4/Makefile.am.in: New file.
28454         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
28455
28456 1998-05-14  Jim Meyering  <meyering@ascend.com>
28457
28458         * m4/Makefile.am (EXTRA_DIST): Add them.
28459         * m4/jm-macros.m4: New file.
28460         * m4/utimbuf.m4: New file.
28461
28462 1998-05-12  Jim Meyering  <meyering@ascend.com>
28463
28464         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
28465
28466 1998-05-11  Jim Meyering  <meyering@ascend.com>
28467
28468         * m4/isc-posix.m4: New file.
28469
28470 1998-05-10  Jim Meyering  <meyering@ascend.com>
28471
28472         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
28473
28474 1998-05-09  Jim Meyering  <meyering@ascend.com>
28475
28476         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
28477         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
28478         with automake.
28479
28480         * m4/ssize_t.m4: New file.
28481         * m4/mktime.m4: Remove file -- the new automake has this now.
28482
28483 1998-04-26  Jim Meyering  <meyering@ascend.com>
28484
28485         * m4/assert.m4: New file.
28486         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
28487
28488 1998-04-05  Jim Meyering  <meyering@ascend.com>
28489
28490         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
28491         (jm_PREREQ): Use it here.
28492
28493 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
28494
28495         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
28496         in acconfig.h.
28497
28498 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
28499
28500         * m4/prereq.m4: New file.
28501         * m4/error.m4: New file.
28502         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
28503
28504 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
28505
28506         * m4/getline.m4: Don't set am_cv_func_working_getline before the
28507         cache-check for the same variable -- that defeated the purpose of
28508         the test; the test program was never run.  This was a problem only
28509         on systems with losing getline functions -- HP-UX 10.20 is one.
28510         Reported by Bjorn Helgaas.
28511
28512 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
28513
28514         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
28515
28516 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
28517
28518         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
28519
28520         * m4/const.m4: New file.  Use an initializer in this declaration
28521         typedef int charset[2]; const charset x;
28522         Reported by Bob Glickstein.
28523
28524 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
28525
28526         * m4/chown.m4: Fix reversed types on -1 args to chown.
28527         From Kaveh Ghazi.
28528
28529 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
28530
28531         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
28532         Add lseek and memchr.
28533
28534         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
28535         T.E.Dickey <dickey@clark.net> said that some older preprocessors
28536         have a 20-character limit on names.
28537
28538 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
28539
28540         * m4/inttypes_h.m4: New file.
28541         * m4/uintmax_t.m4: New file.
28542         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
28543
28544 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
28545   Free Software Foundation, Inc.
28546 Copying and distribution of this file, with or without modification,
28547 are permitted provided the copyright notice and this notice are preserved.