57d8087b2552c0d20f2ff09525977935d54e9aea
[gnulib.git] / ChangeLog
1 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2
3         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
4         for NetBSD.  Problem reported by Bruno Haible.
5
6 2006-10-09  Jim Meyering  <jim@meyering.net>
7
8         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
9         Patch from Bruno Haible.
10
11 2006-10-09  Jim Meyering  <jim@meyering.net>
12
13         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
14         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
15         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
16
17 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
18
19         Don't include <config.h> twice; this doesn't work in some cases,
20         e.g., when config.h has "#define intmax_t long long int" and
21         we include <config.h>, <inttypes.h>, <config.h> in that order.
22         Problem reported by Matthew Woehlke in:
23         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
24         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
25         * lib/fts-cycle.c: Don't include config.h.
26         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
27         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
28         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
29         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
30         inttypes.h.
31         * lib/xstrtoumax.c: Likewise.
32         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
33         __strtol and the like, so that this module is more like its siblings.
34         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
35         Remove; no longer needed now that we assume gnulib inttypes.h.
36
37 2006-10-08  Bruno Haible  <bruno@clisp.org>
38
39         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
40         option.
41
42 2006-10-07  Jim Meyering  <jim@meyering.net>
43
44         * modules/inttypes (inttypes.h): Revert what seems to have been
45         an inadvertent part of today's change: use "|", not "/" in the
46         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
47
48 2006-10-07  Bruno Haible  <bruno@clisp.org>
49
50         * modules/sublist: New file.
51
52 2006-10-07  Bruno Haible  <bruno@clisp.org>
53
54         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
55         * modules/argz (argz.h): Likewise.
56         * modules/arpa_inet (arpa/inet.h): Likewise.
57         * modules/byteswap (byteswap.h): Likewise.
58         * modules/configmake (configmake.h): Likewise.
59         * modules/fcntl (fcntl.h): Likewise.
60         * modules/fnmatch (fnmatch.h): Likewise.
61         * modules/getopt (getopt.h): Likewise.
62         * modules/glob (glob.h): Likewise.
63         * modules/inttypes (inttypes.h): Likewise.
64         * modules/netinet_in (netinet/in.h): Likewise.
65         * modules/poll (poll.h): Likewise.
66         * modules/stdbool (stdbool.h): Likewise.
67         * modules/stdint (stdint.h): Likewise.
68         * modules/sys_select (sys/select.h): Likewise.
69         * modules/sys_socket (sys/socket.h): Likewise.
70         * modules/sys_stat (sys/stat.h): Likewise.
71         * modules/sysexits (sysexits.h): Likewise.
72         * modules/unistd (unistd.h): Likewise.
73         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
74         Add a "DO NOT EDIT" comment to the generated file.
75         (func_import): Likewise for gnulib-comp.m4.
76
77 2006-10-07  Bruno Haible  <bruno@clisp.org>
78
79         * lib/gl_sublist.h: New file.
80         * lib/gl_sublist.c: New file.
81
82 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
83
84         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
85         name (relative to the original working directory) and the file
86         name component (relative to the temporary working directory).  All
87         callers changed.
88         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
89         * lib/mkdir-p.c (make_dir_parents): Likewise.
90         * lib/mkdir-p.h (make_dir_parents): Likewise.
91
92 2006-10-06  Eric Blake  <ebb9@byu.net>
93
94         Define several macros for use by the clean-temp module.
95         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
96         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
97         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
98
99         * lib/clean-temp.h (close_stream_temp): New declaration.
100         * lib/clean-temp.c (includes): Pull in headers according to what
101         other modules are in use.
102         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
103
104 2006-10-06  Bruno Haible  <bruno@clisp.org>
105
106         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
107         instead of fopen, fwriteerror.
108
109 2006-10-06  Bruno Haible  <bruno@clisp.org>
110
111         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
112         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
113         int.
114         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
115         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
116         Return an error indicator.
117         Suggested by Eric Blake.
118
119 2006-10-06  Bruno Haible  <bruno@clisp.org>
120
121         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
122         Reported by Eric Blake.
123
124 2006-10-06  Bruno Haible  <bruno@clisp.org>
125
126         * modules/closeout (Description): Mention stderr too.
127
128 2006-10-06  Bruno Haible  <bruno@clisp.org>
129         and Paul Eggert  <eggert@cs.ucla.edu>
130
131         * lib/closeout.c (close_stdout): Also close stderr.
132         * lib/closeout.h: Update comment.
133
134 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
135
136         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
137         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
138         * lib/dirchownmod.c: Include lchown.h.
139         * lib/lchown.c: Don't include files that lchown.h now includes.
140         Don't declare chown, since lchown.h now does that.
141         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
142         (lchown): Define to rpl_chown if lchown is declared but
143         does not exist.  Declare using a prototype if lchown is not
144         declared.  Add a copyright notice.
145         * lib/mkstemp.h: Include <unistd.h>.
146         * lib/openat.c: Include lchown.h.
147
148         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
149         we now test for that separately.
150         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
151         rather than O_NOFOLLOW, when testing whether it's possible to
152         avoid a race condition reliably.
153         * lib/savewd.c (savewd_chdir): Likewise.
154
155         Remove macros that are no longer needed now that stdint.h is
156         reliable.
157         * lib/fsusage.c (UINTMAX_MAX): Remove.
158         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
159         * lib/utimecmp.c (SIZE_MAX): Remove.
160
161         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
162
163         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
164         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
165         O_NOATIME works.
166
167 2006-10-05  Bruno Haible  <bruno@clisp.org>
168
169         * lib/gl_list.h (gl_sortedlist_search_from_to,
170         gl_sortedlist_indexof_from_to): New declarations.
171         (gl_list_implementation): New fields sortedlist_search_from_to,
172         sortedlist_indexof_from_to.
173         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
174         inline functions.
175         * lib/gl_list.c (gl_sortedlist_search_from_to,
176         gl_sortedlist_indexof_from_to): New functions.
177         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
178         function.
179         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
180         (gl_array_sortedlist_search_from_to): New function.
181         (gl_array_list_implementation): Update.
182         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
183         function.
184         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
185         (gl_carray_sortedlist_search_from_to): New function.
186         (gl_carray_list_implementation): Update.
187         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
188         gl_linked_sortedlist_indexof_from_to): New functions.
189         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
190         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
191         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
192         gl_tree_sortedlist_indexof_from_to): New functions.
193         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
194         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
195         Update.
196         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
197         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
198         Update.
199
200 2006-10-05  Bruno Haible  <bruno@clisp.org>
201
202         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
203         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
204         (struct gl_list_implementation): Add fields search_from_to,
205         indexof_from_to. Remove fields search, indexof.
206         (gl_list_search): Use the search_from_to method.
207         (gl_list_search_from, gl_list_search_from_to): New functions.
208         (gl_list_indexof): Use the indexof_from_to method.
209         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
210         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
211         (gl_list_search_from, gl_list_search_from_to): New functions.
212         (gl_list_indexof): Use the indexof_from_to method.
213         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
214         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
215         gl_array_indexof. Add start_index, end_index arguments.
216         (gl_array_search_from_to): Renamed from gl_array_search. Add
217         start_index, end_index arguments.
218         (gl_array_remove, gl_array_list_implementation): Update.
219         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
220         gl_carray_indexof. Add start_index, end_index arguments.
221         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
222         start_index, end_index arguments.
223         (gl_carray_remove, gl_carray_list_implementation): Update.
224         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
225         gl_linked_search. Add start_index, end_index arguments.
226         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
227         start_index, end_index arguments.
228         (gl_linked_remove): Update.
229         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
230         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
231         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
232         field to 'size_t'.
233         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
234         gl_tree_search. Add start_index, end_index arguments.
235         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
236         start_index, end_index arguments.
237         (gl_tree_remove): Update.
238         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
239         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
240         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
241         function.
242         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
243         gl_tree_search. Add start_index, end_index arguments.
244         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
245         start_index, end_index arguments.
246         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
247         Update.
248         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
249
250 2006-10-05  Bruno Haible  <bruno@clisp.org>
251
252         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
253
254         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
255         fwriteerror_temp): New declarations.
256         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
257         (descriptors): New variable.
258         (cleanup): First, close the descriptors.
259         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
260         fclose_temp, fwriteerror_temp): New functions.
261
262 2006-10-04  Jim Meyering  <jim@meyering.net>
263
264         * lib/fts.c (fts_open): Tiny comment change.
265
266 2006-10-04  Bruno Haible  <bruno@clisp.org>
267
268         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
269         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
270         gl_LOCK_BODY.
271         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
272         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
273         gl_LOCK_EARLY_BODY.
274         (gl_LOCK): Require gl_LOCK_BODY.
275
276 2006-10-04  Bruno Haible  <bruno@clisp.org>
277
278         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
279         (gl_oset_search_atleast): New declaration.
280         (struct gl_oset_implementation): Add field 'search_atleast'.
281         (gl_oset_search_atleast): New inline function.
282         * lib/gl_oset.c (gl_oset_search_atleast): New function.
283         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
284         (gl_array_oset_implementation): Update.
285         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
286         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
287         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
288
289 2006-10-04  Bruno Haible  <bruno@clisp.org>
290
291         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
292
293 2006-10-03  Bruno Haible  <bruno@clisp.org>
294
295         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
296         from gl_avltreehash_list_implementation.
297
298 2006-10-03  Bruno Haible  <bruno@clisp.org>
299
300         * lib/gl_oset.c (gl_oset_add): Fix return type.
301
302 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>
303
304         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
305
306 2006-10-02  Eric Blake  <ebb9@byu.net>
307
308         * modules/strnlen (Depends-on): Add extensions.
309
310 2006-10-02  Eric Blake  <ebb9@byu.net>
311
312         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
313         definition in 2.60+.
314
315 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
316
317         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
318         checks.
319
320 2006-10-02  Bruno Haible  <bruno@clisp.org>
321
322         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
323         to the AUTOMAKE_OPTIONS.
324         Reported by Jim Meyering.
325
326 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
327
328         Work around bug in Solaris 10 /proc file system:
329         /proc/self/fd/NNN/.. isn't the parent directory of
330         the directory whose file descriptor is NNN.  This needs to
331         be worked around at run time, not compile time, since a
332         program might be built on Solaris 8, where things work, and
333         run on Solaris 10.
334         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
335         to use the following interface instead:
336         (OPENAT_BUFFER_SIZE): New macro.
337         (openat_proc_name): New function.
338         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
339         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
340         Likewise.
341         * lib/openat-proc.c: New file.
342         * modules/openat (Files): Add lib/openat-proc.c.
343         (Depends-on): Add same-inode, stdbool.
344         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
345
346 2006-09-29  Bruno Haible  <bruno@clisp.org>
347
348         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
349         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
350         argument. Set stdout_closed before testing for ferror, not after.
351         (fwriteerror, fwriteerror_no_ebadf): New functions.
352
353 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
354
355         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
356
357 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
358
359         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
360         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
361
362 2006-09-28  Jim Meyering  <jim@meyering.net>
363
364         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
365         Include <unistd.h>.
366
367 2006-09-28  Bruno Haible  <bruno@clisp.org>
368
369         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
370         * modules/linkedhash-list (Depends-on): Likewise.
371         * modules/rbtreehash-list (Depends-on): Likewise.
372
373 2006-09-28  Bruno Haible  <bruno@clisp.org>
374
375         * lib/strndup.h: Simplify the redefinition of strndup.
376         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
377         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
378
379 2006-09-28  Bruno Haible  <bruno@clisp.org>
380
381         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
382         * lib/gl_linkedhash_list.c: Likewise.
383         * lib/gl_rbtreehash_list.c: Likewise.
384
385 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
386
387         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
388         getaddrinfo.
389
390         * lib/__fpending.h: Don't include <stdio_ext.h> unless
391         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
392         it causes <stdio_ext.h> to cause a compile-time error.
393         Problem reported by Nelson H. F. Beebe.
394         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
395         of HAVE_DECL___PENDING.
396
397         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
398         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
399         declaration.
400
401 2006-09-27  Jim Meyering  <jim@meyering.net>
402
403         This file could end up with a definition for a function
404         named __strndup, rather than rpl_strndup on a system with
405         incomplete weak_alias support.
406         * lib/strndup.c (strndup): Rename from __strndup.
407         Remove #defines that used to map __strndup to strndup.
408         Don't use K&R prototypes.
409         Remove LIBC-related code, since this file is not sync'd with glibc.
410         * lib/strndup.h: Revamp, accordingly.
411         * m4/strndup.m4: Modernize.
412
413 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
414
415         * modules/savewd (Depends-on): Add 'raise'.
416         * lib/savewd.c: Include <signal.h>, for 'raise'.
417
418 2006-09-26  Jim Meyering  <jim@meyering.net>
419
420         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
421         when we detect Darwin 8.7.0's acl_get_file bug.
422         Rearrange to perform the new (below) run-test while $LIBS
423         contains any acl-related library.  Set USE_ACL at the end.
424         (gl_ACL_GET_FILE): New function.
425
426 2006-09-26  Eric Blake  <ebb9@byu.net>
427
428         * lib/verror.c: Include <config.h> unconditionally.
429
430 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
431
432         * modules/clock-time (Maintainer): Add self.
433         * modules/getlogin_r (Depends-on): Add extensions.
434
435 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
436
437         * modules/clock-time: New module.
438         * modules/nanosleep (Depends-on): Add clock-time.
439         * modules/gethrxtime (Depends-on): Likewise.
440         * modules/gettime (Depends-on): Likewise.
441         * modules/settime (Depends-on): Likewise.
442
443         * modules/fts-lgpl: Depend on openat.
444         * modules/mkancesdirs: Depend on savewd.
445         * modules/mkdir-p: Likewise.
446
447 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
448
449         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
450
451         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
452         `gl_have_arbitrary_file_name_length_limit' to
453         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
454         actually works between configure runs.
455
456 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
457             Bruno Haible  <bruno@clisp.org>
458
459         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
460
461 2006-09-25  Jim Meyering  <jim@meyering.net>
462
463         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
464         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
465
466 2006-09-25  Eric Blake  <ebb9@byu.net>
467
468         * gnulib-tool (func_import, func_create_testdir): Fix typos in
469         exec's in 2006-09-18 patch when shuffling fds.
470
471 2006-09-25  Bruno Haible  <bruno@clisp.org>
472
473         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
474         Reported by Jim Meyering.
475
476 2006-09-24  Jim Meyering  <jim@meyering.net>
477
478         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
479         compare a pointer against a literal "0".  That caused failures with
480         at least HP-UX's hpcc.
481
482 2006-09-22  Simon Josefsson  <jas@extundo.com>
483
484         * modules/gc-sha1:
485         * modules/gc-md4:
486         * modules/gc-hmac-sha1:
487         * modules/gc-hmac-md5:
488         * modules/gc-des:
489         * modules/gc-arcfour: Distribute more files.
490
491 2006-09-22  Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
492
493         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
494         (gl_linked_iterator_from_to): Initialize struct completely.
495         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
496         (gl_tree_iterator_from_to): Likewise
497         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
498         * lib/gl_array_list.c [lint] (gl_array_iterator)
499         (gl_array_iterator_from_to): Likewise.
500         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
501         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
502         (gl_carray_iterator_from_to): Likewise.
503
504         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
505         * lib/md4.c (md4_process_block): Remove unused variable.
506         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
507         parentheses for clarity.
508
509 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
510
511         * modules/bison-i18n (Depends-on): Add gettext.
512
513 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
514
515         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
516         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
517         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
518         also add missing comma that caused broken test.
519         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
520         stdlib.h, for `abort'.
521         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
522         variables.
523         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
524         include unistd.h if present, for `rmdir'.
525         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
526         variables.
527         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
528         in the process include standard headers for prototypes.
529         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
530         gets declared on GNU/Linux.
531         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
532         unistd.h, for `rmdir'.
533         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
534
535         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
536         always true.
537         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
538
539         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
540
541 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
542
543         * gnulib-tool (func_version): Create output all at once.  This
544         may help avoid triggering unnecessary SIGPIPEs, and at any
545         rate it doesn't hurt.
546
547 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
548             Bruno Haible  <bruno@clisp.org>
549
550         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
551         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
552         * m4/signed.m4 (bh_C_SIGNED): Likewise.
553
554         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
555         (gl_FUNC_VASPRINTF): Invoke it.
556
557 2006-09-22  Bruno Haible  <bruno@clisp.org>
558
559         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
560         getloadavg.c as first argument.
561
562 2006-09-22  Bruno Haible  <bruno@clisp.org>
563
564         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
565         at the beginning of the gl_INIT macro.
566         * modules/getloadavg (configure.ac): Pass $gl_source_base to
567         gl_GETLOADAVG.
568
569 2006-09-22  Bruno Haible  <bruno@clisp.org>
570
571         * gnulib-tool (func_create_megatestdir): Don't include the config-h
572         module.
573         Suggested by Ralf Wildenhues.
574
575 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
576
577         Import this patch from libc:
578
579         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
580
581         * lib/regex_internal.c (re_string_reconstruct): Handle
582         offset < pstr->valid_raw_len && pstr->offsets_needed case.
583         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
584         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
585         re_string_context_at.
586
587         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
588         now requires it.
589         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
590         gl_REGEX now does it for us.
591         (gl_REGEX): Add test taken from
592         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
593
594         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
595         Check that large offsets work.  Modernize Autoconf usages.
596         Prefer "yes" to mean a good thing rather than a bad.
597         Don't put "#define mkstemp" in config.h, as this might interfere
598         with standard system headers that "#define mkstemp mkstemp64".
599
600         * modules/mkstemp (Depends-on): Add extensions, so that
601         mkstemp is visible on some platforms.
602         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
603         (Include): Change to "mkstemp.h" from <stdlib.h>.
604         (Files): Add mkstemp.h.
605
606         * lib/mkstemp.h: New file, since some standard headers
607         #define mkstemp.
608         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
609         Include "mkstemp.h".
610         Make the _LIBC code resemble glibc original more,
611         e.g., use K&R style.
612         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
613         (mkstemp): Remove, since mkstemp.h does this for us.
614         * lib/stdlib--.h: Include mkstemp.h.
615
616         Import this patch from libc:
617
618         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
619
620         * lib/tempname.c (__gen_tempname): Change attempts_min
621         into a macro.  Use preprocessor to decide how to initialize
622         attempts [Coverity CID 67].
623
624 2006-09-20  Bruno Haible  <bruno@clisp.org>
625
626         * lib/mkdtemp.c: Import from libc.
627         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
628                 * sysdeps/posix/tempname.c (__gen_tempname): Change
629                 attempts_min into a macro.  Use preprocessor to decide how to
630                 initialize attempts [Coverity CID 67].
631         2001-11-27  Paul Eggert  <eggert@twinsun.com>
632                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
633                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
634
635 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
636
637         * gnulib-tool (func_exit): New function, to allow to pass the
638         exit status portably through the trap.  Use everywhere.
639         (--help, --version): Signal a write error.
640         (trap): catch SIGPIPE, for write errors.
641         Exit at the end of the trap, with the correct exit status.
642
643 2006-09-19  Karl Berry  <karl@gnu.org>
644
645         * doc/gnulib.texi: note about the license texinfo files.
646
647 2006-09-19  Eric Blake  <ebb9@byu.net>
648
649         * gnulib-tool: Avoid space-tab.
650
651 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
652
653         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
654         that prevented coreutils 6.1 from building.  Problem reported
655         by Petter Reinholdtsen.
656
657 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
658
659         * gnulib-tool (avoidlist): Fix typo that broke options like
660         --avoid=lock that are used by coreutils bootstrap.
661
662 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
663
664         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
665         more systematically.
666
667 2006-09-18  Jim Meyering  <jim@meyering.net>
668
669         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
670
671 2006-09-18  Bruno Haible  <bruno@clisp.org>
672
673         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
674
675 2006-09-18  Bruno Haible  <bruno@clisp.org>
676
677         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
678         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
679         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
680         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
681         * m4/gettext.m4: Require autoconf >= 2.52.
682         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
683         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
684         of gl_cv_header_inttypes_h.
685
686 2006-09-18  Bruno Haible  <bruno@clisp.org>
687
688         * lib/javaversion.c: Include configmake.h.
689
690 2006-09-18  Bruno Haible  <bruno@clisp.org>
691
692         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
693         avoid that the while loops be executed in a subshell.
694
695 2006-09-18  Bruno Haible  <bruno@clisp.org>
696
697         * MODULES.html.sh (func_module): Break long lines.
698         Suggested by Bruce Korb <bkorb@gnu.org>.
699
700 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
701
702         Speed up by a factor of 1.12.
703         * gnulib-tool (nl): New variable.
704         (func_import): Rewrite include directive extraction to only read each
705         directive once.
706
707 2006-09-17  Bruno Haible  <bruno@clisp.org>
708
709         * modules/javaversion (Makefile.am): Remove DEFS setting.
710         (Depends-on): Add configmake, for PKGDATADIR definition.
711
712 2006-09-17  Bruno Haible  <bruno@clisp.org>
713
714         * gnulib-tool (func_create_testdir): Rewrite all files at once.
715
716 2006-09-17  Bruno Haible  <bruno@clisp.org>
717
718         * gnulib-tool (func_append): New function, stolen from libtool.m4.
719         (func_modules_transitive_closure, func_modules_add_dummy,
720         func_modules_to_filelist, func_import, func_create_testdir,
721         func_create_megatestdir, ...): Use it wherever possible.
722         Suggested by Ralf Wildenhues.
723
724 2006-09-16  Karl Berry  <karl@gnu.org>
725
726         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
727         to avoid sectioning errors.
728         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
729         [ifinfo]: blank line after @center-ed titles.
730         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
731         Spell FSF address consistently with others.
732         (These changes approved by rms.)
733
734 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
735
736         Speed up by a factor of 1.61.
737         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
738         already checked module names again.
739
740 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
741
742         Speed up by a factor of 1.13.
743         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
744         for new_files, and the input to func_add_or_update.
745
746 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
747
748         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
749         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
750
751 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
752
753         * modules/mkancesdirs (Depends-on): Add fcntl.
754         * modules/savewd: New file.
755         * MODULES.html.sh (File system functions): Add savewd.
756
757         * modules/configmake (Makefile.am): Add support for the
758         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
759
760 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
761
762         * m4/savewd.m4: New file.
763
764 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
765
766         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
767         (dirchownmod): New arg FD.  All callers changed.
768         Use FD rather than opening the directory ourself, as opening is
769         now the caller's responsibility.
770         * lib/dirchownmod.h: Likewise.
771         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
772         hosts that require <sys/types.h> before <sys/stat.h>.  Include
773         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
774         (test_dir): Remove.
775         (mkancesdirs): Return length of prefix of FILE that has already
776         been made, or -2 if there is a child doing the work.  Redo
777         algorithm so that it is O(N) rather than O(N**2).  Optimize away
778         ".", and treat ".." specially since it might stray back into
779         already-created areas.  Use a subprocess if necessary.  New arg
780         WD; all users changed.  MAKE_DIR function should now return 1
781         if it creates a directory that is not readable.  Return -2 if
782         a child process is spun off.
783         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
784         Adjust signature to match code.
785         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
786         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
787         all users changed.
788         * lib/savewd.c, savewd.h: New files.
789
790 2006-09-15  Jim Meyering  <jim@meyering.net>
791
792         * modules/rename-dest-slash: New module.
793         * MODULES.html.sh (posix_compat): Add it here.
794
795         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
796
797 2006-09-15  Jim Meyering  <jim@meyering.net>
798
799         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
800         file.
801
802         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
803
804 2006-09-15  Jim Meyering  <jim@meyering.net>
805
806         * lib/rename-dest-slash.c (has_trailing_slash): Use
807         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
808         (rpl_rename_dest_slash): Perform the cheaper trailing slash
809         test before testing whether SRC is a directory.
810         Suggestions from Bruno Haible.
811
812         Avoid a warning about an unused variable.
813         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
814         into the #ifdef block where it's used.
815
816         * lib/rename-dest-slash.c: New file.
817
818 2006-09-14  Bruno Haible  <bruno@clisp.org>
819
820         * lib/allocsa.c: Include <config.h> unconditionally.
821         * lib/asnprintf.c: Likewise.
822         * lib/asprintf.c: Likewise.
823         * lib/c-strcasecmp.c: Likewise.
824         * lib/c-strcasestr.c: Likewise.
825         * lib/c-strncasecmp.c: Likewise.
826         * lib/c-strstr.c: Likewise.
827         * lib/classpath.c: Likewise.
828         * lib/clean-temp.c: Likewise.
829         * lib/concatpath.c: Likewise.
830         * lib/copy-file.c: Likewise.
831         * lib/csharpcomp.c: Likewise.
832         * lib/csharpexec.c: Likewise.
833         * lib/execute.c: Likewise.
834         * lib/fatal-signal.c: Likewise.
835         * lib/findprog.c: Likewise.
836         * lib/fwriteerror.c: Likewise.
837         * lib/gl_array_list.c: Likewise.
838         * lib/gl_array_oset.c: Likewise.
839         * lib/gl_avltree_list.c: Likewise.
840         * lib/gl_avltree_oset.c: Likewise.
841         * lib/gl_avltreehash_list.c: Likewise.
842         * lib/gl_carray_list.c: Likewise.
843         * lib/gl_linked_list.c: Likewise.
844         * lib/gl_linkedhash_list.c: Likewise.
845         * lib/gl_list.c: Likewise.
846         * lib/gl_oset.c: Likewise.
847         * lib/gl_rbtree_list.c: Likewise.
848         * lib/gl_rbtree_oset.c: Likewise.
849         * lib/gl_rbtreehash_list.c: Likewise.
850         * lib/imaxabs.c: Likewise.
851         * lib/imaxdiv.c: Likewise.
852         * lib/javacomp.c: Likewise.
853         * lib/javaexec.c: Likewise.
854         * lib/javaversion.c: Likewise.
855         * lib/linebreak.c: Likewise.
856         * lib/localcharset.c: Likewise.
857         * lib/lock.c: Likewise.
858         * lib/mbchar.c: Likewise.
859         * lib/mbswidth.c: Likewise.
860         * lib/mkdtemp.c: Likewise.
861         * lib/pipe.c: Likewise.
862         * lib/printf-args.c: Likewise.
863         * lib/printf-parse.c: Likewise.
864         * lib/progname.c: Likewise.
865         * lib/progreloc.c: Likewise.
866         * lib/readlink.c: Likewise.
867         * lib/sh-quote.c: Likewise.
868         * lib/stpcpy.c: Likewise.
869         * lib/stpncpy.c: Likewise.
870         * lib/strcasecmp.c: Likewise.
871         * lib/strcasestr.c: Likewise.
872         * lib/strcspn.c: Likewise.
873         * lib/striconv.c: Likewise.
874         * lib/strncasecmp.c: Likewise.
875         * lib/strnlen1.c: Likewise.
876         * lib/strstr.c: Likewise.
877         * lib/strtok_r.c: Likewise.
878         * lib/tls.c: Likewise.
879         * lib/tmpdir.c: Likewise.
880         * lib/unicodeio.c: Likewise.
881         * lib/unsetenv.c: Likewise.
882         * lib/vasnprintf.c: Likewise.
883         * lib/vasprintf.c: Likewise.
884         * lib/wait-process.c: Likewise.
885         * lib/xallocsa.c: Likewise.
886         * lib/xsetenv.c: Likewise.
887         * lib/xstriconv.c: Likewise.
888
889 2006-09-13  Simon Josefsson  <jas@extundo.com>
890
891         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
892         that internally, suggested by Ralf Wildenhues
893         <Ralf.Wildenhues@gmx.de>.
894
895 2006-09-13  Simon Josefsson  <jas@extundo.com>
896
897         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
898         @LIBOBJS@.
899         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
900
901 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
902
903         * lib/_fpending.c: Include <config.h> unconditionally, since we no
904         longer worry about uses that don't define HAVE_CONFIG_H.
905         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
906         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
907         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
908         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
909         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
910         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
911         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
912         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
913         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
914         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
915         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
916         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
917         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
918         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
919         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
920         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
921         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
922         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
923         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
924         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
925         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
926         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
927         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
928         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
929         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
930         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
931         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
932         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
933         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
934         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
935         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
936         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
937         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
938         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
939         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
940         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
941         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
942         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
943         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
944         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
945         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
946         Likewise.
947
948 2006-09-13  Eric Blake  <ebb9@byu.net>
949
950         * lib/getopt.c: Fix typo in last commit.
951
952 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
953
954         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
955         dgettext.
956
957 2006-09-12  Jim Meyering  <jim@meyering.net>
958
959         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
960         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
961         Reported by Nelson H. F. Beebe.
962
963 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
964
965         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
966         program_invocation_name and program_invocation_short_name are
967         initialized.
968         * lib/argp-namefrob.h: Move declarations of program_invocation_name
969         and program_invocation_short_name to argp.h, so they are visible
970         to user programs.
971         * lib/argp.h: Likewise
972
973 2006-09-10  Bruno Haible  <bruno@clisp.org>
974
975         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
976         m4/inttypes_h.m4, m4/uintmax_t.m4.
977
978 2006-09-10  Bruno Haible  <bruno@clisp.org>
979
980         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
981         gl_AC_TYPE_UINTMAX_T.
982
983 2006-09-10  Bruno Haible  <bruno@clisp.org>
984
985         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
986
987 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
988
989         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
990         convention.  Text proposed by Bruno Haible.
991         (struct argp_option): Document the use of N_() wrappers.
992
993         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
994         '\v', and translate the two parts separately, instead of feeding
995         the whole string to gettext.  This allows to exclude
996         '\v' from the strings visible to the translator by writing doc
997         strings as N_("..") "\v" N_("..").
998
999 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
1000
1001         * config/srclist.txt: Undo latest change; the bug was fixed.
1002
1003 2006-09-09  Bruno Haible  <bruno@clisp.org>
1004
1005         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
1006         assignments if building a library without libtool.
1007         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
1008         in func_emit_lib_Makefile_am.
1009         (func_import): When building a static library libfoo.a, arrange to
1010         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
1011         (func_create_testdir): Likewise.
1012         * modules/gc (configure.ac, Makefile.am): If building statically,
1013         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
1014         * modules/iconvme (configure.ac, Makefile.am): Likewise.
1015         * modules/striconv (configure.ac, Makefile.am): Likewise.
1016         Based on a suggestion by Ralf Wildenhues.
1017
1018 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
1019
1020         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
1021         Check for unistd.h too, since Autoconf doesn't assume POSIX.
1022         Also:
1023
1024         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
1025         Add year_2050_test to catch glibc bug 2821
1026         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
1027
1028         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
1029         Prefer #ifdef to #if.
1030
1031         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
1032         Return from 'main' instead of calling 'exit'.
1033
1034 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
1035
1036         * lib/mktime.c (guess_time_tm): Fix bug where mktime
1037         returned the maximum time_t value rather than (time_t) -1.
1038         Problem originally reported by William Bardwell
1039         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
1040
1041         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
1042         Moved to here ...
1043         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
1044         ... from here.
1045
1046 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
1047
1048         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
1049         2821 is fixed.
1050
1051 2006-09-08  Jim Meyering  <jim@meyering.net>
1052
1053         Don't make generated files read-only.  That would bother too many
1054         people.  However, do retain the ability to work when targets are
1055         read-only: remove the destination and temporary files before writing
1056         them (when generated via sed or echo), or by using the -f option for
1057         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
1058         * modules/alloca-opt, modules/argz, modules/arpa_inet:
1059         * modules/byteswap, modules/configmake, modules/fcntl:
1060         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
1061         * modules/localcharset, modules/netinet_in, modules/poll:
1062         * modules/stdbool, modules/stdint, modules/sys_select:
1063         * modules/sys_socket, modules/sys_stat, modules/sysexits:
1064
1065 2006-09-08  Jim Meyering  <jim@meyering.net>
1066
1067         Avoid new build failure on FreeBSD 6.0.
1068         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
1069         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
1070         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
1071
1072 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1073
1074         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
1075
1076 2006-09-07  Jim Meyering  <jim@meyering.net>
1077
1078         Fix global typo in last change: use chmod u-w, not chmod u-x.
1079         Spotted by Paul Eggert and Bruce Korb.
1080         * modules/alloca-opt, modules/argz, modules/arpa_inet:
1081         * modules/byteswap, modules/configmake, modules/fcntl:
1082         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
1083         * modules/localcharset, modules/netinet_in, modules/poll:
1084         * modules/stdbool, modules/stdint, modules/sys_select:
1085         * modules/sys_socket, modules/sys_stat, modules/sysexits:
1086
1087 2006-09-06  Jim Meyering  <jim@meyering.net>
1088
1089         Make generated files be read-only.
1090         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
1091         Ensure that each generated file is now read-only.
1092         * modules/argz: Likewise.
1093         * modules/arpa_inet: Likewise.
1094         * modules/byteswap: Likewise.
1095         * modules/configmake: Likewise.
1096         * modules/fcntl: Likewise.
1097         * modules/fnmatch: Likewise.
1098         * modules/getopt: Likewise.
1099         * modules/glob: Likewise.
1100         * modules/inttypes: Likewise.
1101         * modules/netinet_in: Likewise.
1102         * modules/poll: Likewise.
1103         * modules/stdbool: Likewise.
1104         * modules/stdint: Likewise.
1105         * modules/sys_select: Likewise.
1106         * modules/sys_socket: Likewise.
1107         * modules/sys_stat: Likewise.
1108         * modules/sysexits: Likewise.
1109         * modules/localcharset: Same as above, but continue using temporary
1110         file named "t-$@" (why different?) rather than the "$@-t" used
1111         everywhere else.
1112
1113         * modules/sysexits (Makefile.am): Replace literal occurrences
1114         of "sysexit.h" more readable, and more consistent, "$@".
1115
1116 2006-09-06  Bruno Haible  <bruno@clisp.org>
1117
1118         * modules/striconv: New file.
1119         * modules/xstriconv: New file.
1120         * MODULES.html.sh (Internationalization functions): Add striconv,
1121         xstriconv.
1122
1123 2006-09-06  Bruno Haible  <bruno@clisp.org>
1124
1125         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
1126         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
1127         not using libtool correctly.
1128
1129 2006-09-06  Bruno Haible  <bruno@clisp.org>
1130
1131         * lib/striconv.h: New file.
1132         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
1133         iconvstring.c.
1134         * lib/xstriconv.h: New file.
1135         * lib/xstriconv.c: New file.
1136
1137 2006-09-06  Bruno Haible  <bruno@clisp.org>
1138
1139         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1140         lib_..._LDFLAGS.
1141
1142 2006-09-05  Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1143
1144         * lib/argz_.h: Sync from Libtool.
1145
1146         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
1147                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1148
1149         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
1150
1151 2006-09-05  Davide Angelocola <davide.angelocola@tiscali.it>
1152
1153         * modules/trim: New file.
1154
1155 2006-09-05  Davide Angelocola <davide.angelocola@tiscali.it>
1156
1157         * lib/trim.h: New file.
1158         * lib/trim.c: New file.
1159
1160 2006-09-05  Bruno Haible  <bruno@clisp.org>
1161
1162         * MODULES.html.sh (String handling): Add trim.
1163
1164 2006-09-04  Karl Berry  <karl@gnu.org>
1165
1166         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
1167         until next release.
1168
1169 2006-09-03  Bruno Haible  <bruno@clisp.org>
1170
1171         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
1172         correctly.
1173
1174 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
1175
1176         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
1177         not gl_GETLOADAVG.  Omit unneeded semicolons.
1178         Problems reported by Ralf Wildenhues in
1179         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
1180         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
1181         at the end, which is the usual gnulib style.
1182
1183         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
1184         of doing all the work ourselves.
1185         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
1186         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
1187
1188 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
1189
1190         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
1191         Problem reported by Ralf Wildenhues in
1192         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
1193
1194         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
1195         HAVE_STRUCT_STATFS_F_FSTYPENAME.
1196
1197 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
1198
1199         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
1200         yesterday's patch by changing test -n to test -z.
1201
1202 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
1203
1204         * modules/getloadavg (Files): Add m4/getloadavg.m4.
1205         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
1206         the former is now obsolescent.
1207
1208         * modules/chdir-long (Depends-on): Add fcntl.
1209
1210 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
1211
1212         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
1213         obsolescent, and programs should use gnulib instead.
1214         * m4/getloadavg.m4: New file, with contents taken from Autoconf
1215         but with prefixes changed.
1216
1217 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
1218
1219         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
1220         or stdbool.h, because they might not exist while configuring.
1221
1222         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
1223         Don't include unistd.h or limits.h; not needed, since chdir-long.h
1224         does that for us.
1225         (O_DIRECTORY): Remove.
1226
1227 2006-08-31  Eric Blake  <ebb9@byu.net>
1228
1229         * gnulib-tool: Don't let emacs change spaces to TAB.
1230
1231 2006-08-31  Bruno Haible  <bruno@clisp.org>
1232
1233         * gnulib-tool: When calling func_import more than once, do it in a
1234         subshell.
1235         Reported by Eric Blake <ebb9@byu.net>.
1236
1237 2006-08-31  Bruno Haible  <bruno@clisp.org>
1238
1239         * gnulib-tool (nl): Remove variable.
1240         (sed_transform_lib_file): Use more robust test for config-h module.
1241         (func_import): Fix typo in 2006-08-25 patch.
1242
1243 2006-08-31  Bruno Haible  <bruno@clisp.org>
1244
1245         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
1246         specified, augment Makefile.am variables instead of assigning them.
1247
1248 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
1249
1250         Work around a bug in both the Linux and SunOS 64-bit kernels:
1251         nanosleep mishandles sleeps for longer than 2**31 seconds.
1252         Problem reported by Frank v Waveren in
1253         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
1254         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
1255         Check for nanosleep bug.
1256         (LIB_NANOSLEEP): Append clock_gettime library if needed.
1257
1258 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
1259
1260         Work around a bug in both the Linux and SunOS 64-bit kernels:
1261         nanosleep mishandles sleeps for longer than 2**31 seconds.
1262         Problem reported by Frank v Waveren in
1263         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
1264         * lib/nanosleep.c (BILLION): New constant.
1265         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
1266         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
1267         implementation.
1268
1269 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
1270
1271         * modules/nanosleep (Depends-on): Add gettime.
1272
1273 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
1274         and Simon Josefsson  <jas@extundo.com>
1275         and Oskar Liljeblad  <oskar@osk.mine.nu>
1276
1277         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
1278         * gnulib-tool (func_import): New license type 'unmodifiable license
1279         text'.
1280         * modules/fdl: Use it.  Longer description.
1281         * module/gpl, module/lgpl: New files.
1282
1283 2006-08-30  Jim Meyering  <jim@meyering.net>
1284
1285         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
1286         shadowing the parameter.
1287
1288 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1289
1290         Sync from Libtool:
1291
1292         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1293
1294         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
1295         sharing with gnulib.  Report by Eric Blake.
1296
1297 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
1298
1299         * modules/isapipe: New file.
1300         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
1301
1302 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
1303
1304         * modules/configmake (Makefile.am): Add a comment, and omit
1305         the CONFIGMAKE_ prefix from generated macro names.  Suggested
1306         by Bruno Haible.
1307
1308 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
1309
1310         * m4/isapipe.m4: New file.
1311
1312 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
1313
1314         * lib/isapipe.c, isapipe.h: New files.
1315
1316 2006-08-29  Jim Meyering  <jim@meyering.net>
1317
1318         * modules/configmake (Makefile.am): Make configmake.h depend on
1319         Makefile.  Otherwise, a stale configmake.h could hang around.
1320
1321 2006-08-29  Eric Blake  <ebb9@byu.net>
1322
1323         * lib/error.c (error_at_line, print_errno_message): Match libc, after
1324         resolution of upstream bug 3044.
1325
1326 2006-08-29  Bruno Haible  <bruno@clisp.org>
1327
1328         * modules/localcharset (Depends-on): Add configmake.
1329         (Makefile.am): Remove setting of LIBDIR through DEFS.
1330
1331 2006-08-29  Bruno Haible  <bruno@clisp.org>
1332
1333         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
1334         defined.
1335
1336 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
1337
1338         * modules/fcntl: New file.
1339         * modules/chdir-safer (Depends-on): Add fcntl.
1340         * modules/fts: Likewise.
1341         * modules/mkdir-p: Likewise.
1342
1343         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
1344         This undoes the most recent change, since we're now addressing the
1345         problem in a different way.
1346
1347         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
1348         into output, since the output might be called Makefile.am even
1349         if $makefile_name is something different.
1350         (func_import): Use $makefile_am rather than
1351         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
1352         empty.
1353
1354         * modules/inttypes (Files): Add m4/inttypes-h.m4.
1355
1356 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
1357
1358         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
1359         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
1360         recent change to stdint.m4, since we're now addressing the problem in a
1361         different way.
1362
1363 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
1364
1365         * m4/fcntl_h.m4: New file.
1366
1367 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
1368
1369         * lib/fcntl_.h: New file.
1370         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
1371         the fcntl module.
1372         * lib/dirchownmod.c: Likewise.
1373         * lib/fts.c: Likewise.
1374
1375         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
1376         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
1377         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
1378         just before including <inttypes.h>, to avoid circular inclusion.
1379
1380 2006-08-28  Jim Meyering  <jim@meyering.net>
1381
1382         * doc/visibility.texi: Actually read and correct the grammar of the
1383         sentence affected by yesterday's change.
1384
1385 2006-08-28  Eric Blake  <ebb9@byu.net>
1386
1387         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
1388         needs wrapper.
1389
1390 2006-08-28  Eric Blake  <ebb9@byu.net>
1391
1392         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
1393
1394 2006-08-28  Eric Blake  <ebb9@byu.net>
1395
1396         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
1397
1398 2006-08-28  Bruno Haible  <bruno@clisp.org>
1399
1400         * modules/c-strstr: New file, from GNU gettext.
1401         * MODULES.html.sh (String handling): Add c-strstr.
1402
1403 2006-08-28  Bruno Haible  <bruno@clisp.org>
1404
1405         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
1406         macros.
1407         Reported by Eric Blake.
1408
1409 2006-08-28  Bruno Haible  <bruno@clisp.org>
1410
1411         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
1412         (VASNPRINTF): Return a string of length > INT_MAX without failing.
1413         * lib/vasprintf.c: Include errno.h, limits.h.
1414         (EOVERFLOW): New fallback definition.
1415         (vasprintf): Test here whether the string length is > INT_MAX.
1416         * lib/vsnprintf.c: Include errno.h, limits.h.
1417         (EOVERFLOW): New fallback definition.
1418         (vsnprintf): Fix bug when generated string was too long for the buffer.
1419         Test here whether the string length is > INT_MAX.
1420
1421 2006-08-28  Bruno Haible  <bruno@clisp.org>
1422
1423         * lib/inttypes_.h (SCNX*): Remove definitions.
1424         Reported by Eric Blake.
1425
1426 2006-08-28  Bruno Haible  <bruno@clisp.org>
1427
1428         * lib/c-strstr.h: New file, from GNU gettext.
1429         * lib/c-strstr.c: New file, from GNU gettext.
1430
1431 2006-08-28  Bruno Haible  <bruno@clisp.org>
1432
1433         * gnulib-tool: Reorder some statements.
1434
1435 2006-08-28  Bruno Haible  <bruno@clisp.org>
1436
1437         * gnulib-tool: New option --makefile-name.
1438         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
1439         $makefile_name.
1440         (func_import): Write $makefile_name to the cache file, and read it from
1441         there unless explicitly specified. Use $makefile_name as file name
1442         instead of Makefile.am. Adjust the recommendations accordingly.
1443
1444 2006-08-28  Bruno Haible  <bruno@clisp.org>
1445
1446         * gnulib-tool (func_verify_module): Check against misapplying patch.
1447
1448 2006-08-28  Bruno Haible  <bruno@clisp.org>
1449
1450         * gnulib-tool (func_relativize, func_relconcat): New functions.
1451         Give an error if --local-dir is given with --update.
1452         Remove trailing slashes from $local_gnulib_dir.
1453         (func_import): Store the relativized $local_gnulib_dir in
1454         gnulib-cache.m4, and read it from there if not specified explicitly.
1455
1456 2006-08-28  Bruno Haible  <bruno@clisp.org>
1457
1458         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
1459         is the current directory. Respect also $local_gnulib_dir.
1460
1461 2006-08-28  Bruno Haible  <bruno@clisp.org>
1462             Simon Josefsson  <jas@extundo.com>
1463
1464         BeOS portability.
1465         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
1466
1467 2006-08-27  Jim Meyering  <jim@meyering.net>
1468
1469         * doc/visibility.texi: Remove duplicate word: "pointer".
1470
1471 2006-08-26  Bruno Haible  <bruno@clisp.org>
1472
1473         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
1474         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
1475         (Makefile.am): Create inttypes.h from inttypes_.h.
1476         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
1477
1478         * modules/imaxabs: New file.
1479
1480         * modules/imaxdiv: New file.
1481
1482 2006-08-26  Bruno Haible  <bruno@clisp.org>
1483
1484         * m4/inttypes.m4: New file.
1485         * m4/_inttypes_h.m4: Remove file.
1486         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
1487         PRI_MACROS_BROKEN.
1488         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
1489
1490         * m4/imaxabs.m4: New file.
1491
1492         * m4/imaxdiv.m4: New file.
1493
1494 2006-08-26  Bruno Haible  <bruno@clisp.org>
1495
1496         * lib/inttypes_.h: New file.
1497         * lib/inttypes.h: Remove file.
1498         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
1499
1500         * lib/imaxabs.c: New file.
1501
1502         * lib/imaxdiv.c: New file.
1503
1504 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
1505
1506         New config-h module, so that "make" output needn't be cluttered
1507         by -DHAVE_CONFIG_H.
1508         * MODULES.html.sh (Support for building libraries and executables):
1509         Add config-h.
1510         * modules/config-h: New file.
1511         * gnulib-tool (nl, sed_transform_lib_file): New vars.
1512         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
1513         the config-h module is used.
1514
1515         New configmake module, so that "make" output needn't be cluttered
1516         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
1517         * MODULES.html.sh (Support for building libraries and executables):
1518         Add configmake.
1519         * modules/configmake: New file.
1520
1521 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
1522
1523         * m4/config-h.m4: New file.
1524
1525 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
1526
1527         * config/srclist.txt: Add elisp-comp.
1528
1529 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
1530
1531         * MODULES.html.sh (Support for building libraries and executables):
1532         Add elisp-comp.
1533         * build-aux/elisp-comp: New file.
1534         * modules/elisp-comp: New file.
1535
1536 2006-08-24  Bruno Haible <bruno@clisp.org>
1537
1538         * gnulib-tool (func_create_testdir): Use non-default values of
1539         sourcebase and m4base.
1540
1541 2006-08-24  Bruno Haible <bruno@clisp.org>
1542
1543         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
1544         HTML structure.
1545
1546 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
1547
1548         * modules/openat (Depends-on): Add lchown.
1549
1550 2006-08-23  Bruno Haible <bruno@clisp.org>
1551
1552         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
1553         of gl_LOCK_EARLY instead of gl_LOCK.
1554
1555 2006-08-23  Bruno Haible  <bruno@clisp.org>
1556
1557         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
1558         on OSF/1 to no.
1559         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
1560
1561 2006-08-23  Bruno Haible  <bruno@clisp.org>
1562
1563         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
1564         as unusable.
1565
1566         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
1567         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
1568         (gl_LOCK): New macro.
1569
1570 2006-08-22  Simon Josefsson  <jas@extundo.com>
1571
1572         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
1573         to md5 module.
1574
1575 2006-08-22  Simon Josefsson  <jas@extundo.com>
1576
1577         * MODULES.html.sh: Add "Support for maintaining and release
1578         projects".
1579
1580         * build-aux/gnupload: New file, from coreutils.
1581
1582 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
1583
1584         Avoid the need for AC_LIBSOURCES in m4 macros.
1585         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
1586         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
1587         * modules/check-version (EXTRA_DIST): Add check-version.h.
1588         * modules/crc (EXTRA_DIST): Add crc.h.
1589         * modules/des (EXTRA_DIST): Add des.h.
1590         * modules/gc (EXTRA_DIST): Add gc.h.
1591         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
1592         * modules/getline (EXTRA_DIST): Add getline.h.
1593         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
1594         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
1595         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
1596         * modules/md2 (EXTRA_DIST): Add md2.h.
1597         * modules/md4 (EXTRA_DIST): Add md4.h.
1598         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
1599         * modules/read-file (EXTRA_DIST): Add read-file.h.
1600         * modules/readline (EXTRA_DIST): Add readline.h.
1601         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
1602         rijndael-api-fst.h.
1603
1604 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
1605
1606         * m4/rijndael.m4 (gl_ARCFOUR):
1607         * m4/arctwo.m4 (gl_ARCTWO):
1608         * m4/check-version.m4 (gl_CHECK_VERSION):
1609         * m4/crc.m4 (gl_CRC):
1610         * m4/des.m4 (gl_DES):
1611         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
1612         * m4/gc.m4 (gl_GC):
1613         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
1614         * m4/getline.m4 (gl_FUNC_GETLINE):
1615         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
1616         * m4/hmac-md5.m4 (gl_HMAC_MD5):
1617         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
1618         * m4/md2.m4 (gl_MD2):
1619         * m4/md4.m4 (gl_MD4):
1620         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
1621         * m4/read-file.m4 (gl_FUNC_READ_FILE):
1622         * m4/readline.m4 (gl_FUNC_READLINE):
1623         * m4/rijndael.m4 (gl_RIJNDAEL):
1624         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
1625         to get the necessary .h files and whatnot.
1626
1627 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
1628
1629         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
1630         gnulib rather than the other way around.
1631         * config/srclistvars.sh (COREUTILS): Remove.
1632
1633 2006-08-22  Jim Meyering  <jim@meyering.net>
1634
1635         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
1636
1637         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
1638
1639 2006-08-22  Eric Blake  <ebb9@byu.net>
1640
1641         * modules/regexprops-generic: New file.
1642         * MODULES.html.sh (Support for building documentation): List it.
1643
1644 2006-08-22  Eric Blake  <ebb9@byu.net>
1645
1646         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
1647         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
1648         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
1649         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
1650
1651 2006-08-22  Bruno Haible <bruno@clisp.org>
1652
1653         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
1654         and lib_LTLIBRARIES like the other lib_* variables.
1655
1656 2006-08-22  Bruno Haible <bruno@clisp.org>
1657
1658         * build-aux/x-to-1.in: New file, from GNU gettext.
1659
1660 2006-08-22  Bruno Haible  <bruno@clisp.org>
1661
1662         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
1663         <utmpx.h> exists.
1664
1665 2006-08-22  Bruno Haible  <bruno@clisp.org>
1666
1667         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
1668         <utmpx.h> exists.
1669
1670 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
1671
1672         BeOS portability.
1673         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
1674         exist.
1675         Problem reported by Bruno Haible.
1676
1677 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
1678
1679         Avoid the need for AC_LIBSOURCES in m4 macros.
1680         * modules/acl (EXTRA_DIST): Add acl.h.
1681         * modules/argmatch (Files): Add m4/argmatch.m4.
1682         (configure.ac): Add gl_ARGMATCH.
1683         (EXTRA_DIST): Renamed from lib_SOURCES, for
1684         consistency with the other modules.  Remove argmatch.c.
1685         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
1686         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
1687         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
1688         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
1689         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
1690         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
1691         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
1692         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
1693         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
1694         * modules/closeout (EXTRA_DIST): Add closeout.h.
1695         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
1696         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
1697         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
1698         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
1699         dirname.h; remove basename.c and stripslash.c.
1700         * modules/exclude (EXTRA_DIST): Add exclude.h.
1701         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
1702         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
1703         * modules/file-type (EXTRA_DIST): Add file-type.h.
1704         * modules/filemode (EXTRA_DIST): Add filemode.h.
1705         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
1706         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
1707         * modules/fpending (EXTRA_DIST): Add __fpending.h.
1708         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
1709         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
1710         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
1711         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
1712         * modules/getdate (EXTRA_DIST): Add getdate.c.
1713         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
1714         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
1715         * modules/getpass (EXTRA_DIST): Add getpass.h.
1716         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
1717         * modules/group-member (EXTRA_DIST): Add group-member.h.
1718         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
1719         * modules/hash (EXTRA_DIST): Add hash.h.
1720         * modules/human (EXTRA_DIST): Add human.h.
1721         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
1722         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
1723         * modules/lchown (EXTRA_DIST): Add lchown.h.
1724         * modules/long-options (EXTRA_DIST): Add long-options.h.
1725         * modules/lstat (EXTRA_DIST): Add lstat.h.
1726         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
1727         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
1728         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
1729         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
1730         * modules/memxor (EXTRA_DIST): Add memxor.h.
1731         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
1732         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
1733         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
1734         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
1735         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
1736         * modules/physmem (EXTRA_DIST): Add physmem.h.
1737         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
1738         * modules/posixver (EXTRA_DIST): Add posixver.h.
1739         * modules/quote (EXTRA_DIST): Add quote.h.
1740         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
1741         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
1742         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
1743         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
1744         regex_internal.h regexec.c.
1745         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
1746         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
1747         * modules/same (EXTRA_DIST): Add same.h.
1748         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
1749         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
1750         * modules/savedir (EXTRA_DIST): Add savedir.h.
1751         * modules/sha1 (EXTRA_DIST): Add sha1.h.
1752         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
1753         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
1754         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
1755         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
1756         * modules/strdup (EXTRA_DIST): Add strdup.h.
1757         * modules/strftime (EXTRA_DIST): Add strftime.h.
1758         * modules/strndup (EXTRA_DIST): Add strndup.h.
1759         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
1760         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
1761         * modules/time_r (EXTRA_DIST): Add time_r.h.
1762         * modules/timespec (EXTRA_DIST): Add timespec.h.
1763         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
1764         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
1765         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
1766         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
1767         * modules/userspec (EXTRA_DIST): Add userspec.h.
1768         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
1769         * modules/utimens (EXTRA_DIST): Add utimens.h.
1770         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
1771         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
1772         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
1773         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
1774         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
1775         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
1776         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
1777         * modules/yesno (EXTRA_DIST): Add yesno.h.
1778
1779 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
1780
1781         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
1782
1783         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
1784         * m4/dev-ino.m4, same-inode.m4: Remove.
1785
1786         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
1787         * m4/acl.m4 (AC_FUNC_ACL):
1788         * m4/backupfile.m4 (gl_BACKUPFILE):
1789         * m4/c-strtod.m4 (gl_C99_STRTOLD):
1790         * m4/canon-host.m4 (gl_CANON_HOST):
1791         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1792         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
1793         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
1794         * m4/cloexec.m4 (gl_CLOEXEC):
1795         * m4/close-stream.m4 (gl_CLOSE_STREAM):
1796         * m4/closeout.m4 (gl_CLOSEOUT):
1797         * m4/dirfd.m4 (gl_FUNC_DIRFD):
1798         * m4/dirname.m4 (gl_DIRNAME):
1799         * m4/exclude.m4 (gl_EXCLUDE):
1800         * m4/exitfail.m4 (gl_EXITFAIL):
1801         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
1802         * m4/file-type.m4 (gl_FILE_TYPE):
1803         * m4/filemode.m4 (gl_FILEMODE):
1804         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
1805         * m4/fpending.m4 (gl_FUNC_FPENDING):
1806         * m4/fprintftime.m4 (gl_FPRINTFTIME):
1807         * m4/fts.m4 (gl_FUNC_FTS):
1808         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
1809         * m4/getdate.m4 (gl_GETDATE):
1810         * m4/gethrxtime.m4 (gl_GETHRXTIME):
1811         * m4/getpagesize.m4 (gl_GETPAGESIZE):
1812         * m4/getpass.m4 (gl_FUNC_GETPASS):
1813         * m4/gettime.m4 (gl_GETTIME):
1814         * m4/getugroups.m4 (gl_GETUGROUPS):
1815         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
1816         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
1817         * m4/hard-locale.m4 (gl_HARD_LOCALE):
1818         * m4/hash.m4 (gl_HASH):
1819         * m4/idcache.m4 (gl_IDCACHE):
1820         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
1821         * m4/lchown.m4 (gl_FUNC_LCHOWN):
1822         * m4/long-options.m4 (gl_LONG_OPTIONS):
1823         * m4/lstat.m4 (gl_FUNC_LSTAT):
1824         * m4/md5.m4 (gl_MD5):
1825         * m4/memcasecmp.m4 (gl_MEMCASECMP):
1826         * m4/memcoll.m4 (gl_MEMCOLL):
1827         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
1828         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
1829         * m4/memxor.m4 (gl_MEMXOR):
1830         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
1831         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
1832         * m4/modechange.m4 (gl_MODECHANGE):
1833         * m4/mountlist.m4 (gl_MOUNTLIST):
1834         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
1835         * m4/openat.m4 (gl_FUNC_OPENAT):
1836         * m4/pathmax.m4 (gl_PATHMAX):
1837         * m4/physmem.m4 (gl_PHYSMEM):
1838         * m4/posixtm.m4 (gl_POSIXTM):
1839         * m4/posixver.m4 (gl_POSIXVER):
1840         * m4/quote.m4 (gl_QUOTE):
1841         * m4/quotearg.m4 (gl_QUOTEARG):
1842         * m4/readtokens.m4 (gl_READTOKENS):
1843         * m4/readutmp.m4 (gl_READUTMP):
1844         * m4/regex.m4 (gl_REGEX):
1845         * m4/safe-read.m4 (gl_SAFE_READ):
1846         * m4/safe-write.m4 (gl_SAFE_WRITE):
1847         * m4/same.m4 (gl_SAME):
1848         * m4/save-cwd.m4 (gl_SAVE_CWD):
1849         * m4/savedir.m4 (gl_SAVEDIR):
1850         * m4/settime.m4 (gl_SETTIME):
1851         * m4/sha1.m4 (gl_SHA1):
1852         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
1853         * m4/stat-macros.m4 (gl_STAT_MACROS):
1854         * m4/stat-time.m4 (gl_STAT_TIME):
1855         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
1856         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
1857         * m4/strdup.m4 (gl_FUNC_STRDUP):
1858         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
1859         * m4/strndup.m4 (gl_FUNC_STRNDUP):
1860         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
1861         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
1862         * m4/time_r.m4 (gl_TIME_R):
1863         * m4/timespec.m4 (gl_TIMESPEC):
1864         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
1865         * m4/unlinkdir.m4 (gl_UNLINKDIR):
1866         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
1867         * m4/userspec.m4 (gl_USERSPEC):
1868         * m4/utimecmp.m4 (gl_UTIMECMP):
1869         * m4/utimens.m4 (gl_UTIMENS):
1870         * m4/xalloc.m4 (gl_XALLOC):
1871         * m4/xgetcwd.m4 (gl_XGETCWD):
1872         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
1873         * m4/xreadlink.m4 (gl_XREADLINK):
1874         * m4/xstrtod.m4 (gl_XSTRTOD):
1875         * m4/yesno.m4 (gl_YESNO):
1876         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
1877         to get the necessary .h files and whatnot.
1878
1879 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
1880             Bruno Haible <bruno@clisp.org>
1881
1882         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
1883         /bin/sh understanding of '!' conditional negation.
1884
1885 2006-08-21  Jim Meyering  <jim@meyering.net>
1886
1887         * modules/openat (Depends-on): Really alphabetize.
1888
1889         * modules/acl (Depends-on): Add error and quote.
1890
1891         * check-module (find_included_lib_files): Add at-func.c to the
1892         ok-to-include-more-than-once white list.
1893
1894         * modules/openat (Depends-on): Add lstat.  Alphabetize.
1895
1896 2006-08-21  Bruno Haible <bruno@clisp.org>
1897
1898         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1899         Emit a pkgdata_DATA variable only if some snippets add contents to it.
1900         Reported by Martin Lambers <marlam@marlam.de>.
1901
1902 2006-08-21  Bruno Haible <bruno@clisp.org>
1903
1904         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
1905         specify an installation location, don't emit a noinst_LIBRARIES or
1906         noinst_LTLIBRARIES assignment.
1907
1908 2006-08-21  Bruno Haible  <bruno@clisp.org>
1909
1910         BeOS portability.
1911         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
1912         BeOS has mbrtowc() but no <wctype.h>.
1913
1914 2006-08-21  Bruno Haible  <bruno@clisp.org>
1915
1916         BeOS portability.
1917         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
1918         exist.
1919
1920 2006-08-21  Bruno Haible  <bruno@clisp.org>
1921
1922         BeOS portability.
1923         * lib/mbchar.h: Include <wctype.h> only if it exists.
1924
1925 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
1926
1927         Remove files that are no longer needed by their respective modules.
1928         * m4/obstack.m4: Remove.
1929         * m4/strerror_r.m4: Remove.
1930         * m4/uint32_t.m4: Remove.
1931         * m4/uintptr_t.m4: Remove.
1932         * m4/ullong_max.m4: Remove.
1933         * m4/xstrtoimax.m4: Remove.
1934         * m4/xstrtoumax.m4: Remove.
1935
1936         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
1937         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
1938         dependencies now capture this.
1939
1940         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
1941         Do not use AC_LIBSOURCES, since gnulib modules now do this.
1942         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
1943         * m4/human.m4 (gl_HUMAN): Likewise.
1944         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
1945         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
1946
1947         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
1948
1949         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
1950         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
1951         stdint.
1952         * m4/human.m4 (gl_HUMAN): Likewise.
1953         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
1954         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
1955         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
1956         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
1957         * m4/xstrtol (gl_XSTRTOL): Likewise.
1958
1959         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
1960         AC_TYPE_LONG_LONG_INT.
1961         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
1962         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
1963         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
1964         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
1965
1966         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
1967         on stdbool.
1968
1969         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
1970         (gl_PREREQ_XSTRTOUL): Remove.
1971
1972         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
1973
1974         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
1975         mode.
1976
1977 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
1978
1979         Add and change modules to make it easier for coreutils to use
1980         gnulib-tool.
1981         * modules/backupfile (Files): Remove m4/d-ino.m4.
1982         (Depends-on): Add d-ino.
1983         * modules/cycle-check (Depends-on): Add stdint.
1984         (lib_SOURCES): Add cycle-check.h.
1985         * modules/d-ino: New module.
1986         * modules/d-type: New module.
1987         * modules/error (Files): Remove m4/strerror_r.m4.
1988         * modules/filemode (Files): Add m4/st_dm_mode.m4.
1989         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
1990         m4/inttypes_h.m4, m4/uintmax_t.m4.
1991         (Depends-on): Add stdint.
1992         (lib_SOURCES): Add fsusage.h.
1993         * modules/getcwd (Files): Remove d-ino.m4.
1994         (Depends-on): Add d-ino.
1995         * modules/getndelim2 (Depends-on): Add stdint.
1996         * modules/glob (Files): Remove m4/d-type.m4.
1997         (Depends-on): Add d-type.
1998         * modules/host-os: New module.
1999         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
2000         m4/inttypes_h.m4, m4/uintmax_t.m4.
2001         * Depends-on: Add stdint.
2002         (lib_SOURCES): Add human.h.
2003         * modules/inttostr (Files): Remove m4/intmax_t.m4,
2004         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
2005         m4/uintmax_t.m4, m4/ulonglong.m4.
2006         (Depends-on): Add stdint.
2007         (EXTRA_DIST): Add inttostr.h.
2008         * modules/lchmod: New module.
2009         * modules/link-follow: New module.
2010         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
2011         (Depends-on): Add lchmod.
2012         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
2013         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
2014         (Depends-on): Add stdint.
2015         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
2016         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
2017         (Depends-on): Add stdint.
2018         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
2019         * modules/perl: New module.
2020         * modules/regex (Depends-on): Add stdint.
2021         * modules/rmdir-errno: New module.
2022         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
2023         m4/intmax_t.m4.
2024         (Depends-on): Add stdint.
2025         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
2026         m4/uintmax_t.m4.
2027         (Depends-on): Add stdint.
2028         * modules/unlink-busy: New module.
2029         * modules/utimecmp (Depends-on): Add stdint.
2030         * modules/uptime: New module.
2031         * modules/winsz-ioctl: New module.
2032         * modules/winsz-termios: New module.
2033         * modules/xnanosleep (Depends-on): Add nanosleep.
2034         * modules/ullong_max: Remove.
2035         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
2036         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
2037         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
2038         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
2039         (Depends-on): Add inttypes.
2040         (lib_SOURCES): Add xstrtol.h.
2041         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
2042         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
2043         * MODULES.html.sh: Move 'assert' into the assert section.
2044         Move 'dummy' into the linking section.
2045         Remove ullong_max.
2046         Add section for compatibility checks for POSIX:2001 functions,
2047         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
2048         winsz-ioctl, and winsz-termios into it.
2049         Add lchmod.
2050         Add top-level Misc section and put host-os, perl, and uptime
2051         into it.
2052
2053 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
2054
2055         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
2056         now assume the stdint module.  Do not include inttypes.h.
2057         * lib/fsusage.h: Likewise.
2058         * lib/getndelim2.c: Likewise.
2059         * lib/human.h: Likewise.
2060         * lib/inttostr.h: Likewise.
2061         * lib/obstack.c: Likewise.
2062         * lib/regex_internal.h: Likewise.
2063         * lib/tempname.c: Likewise.
2064         * lib/utimecmp.c: Likewise.
2065         * lib/xstrtol.h: Likewise.
2066
2067         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
2068
2069         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
2070         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
2071         * lib/xtime.h: Likewise.
2072
2073 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
2074
2075         * modules/openat (Files): Add lib/fchmodat.c.
2076         Fixes problem reported by Jay Youngman.
2077
2078 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
2079
2080         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
2081         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
2082
2083 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
2084             Bruno Haible  <bruno@clisp.org>
2085
2086         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
2087         and is a script that invokes bison. Tighten the code. Add comments.
2088
2089 2006-08-18  Jim Meyering  <jim@meyering.net>
2090
2091         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
2092         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
2093         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
2094         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
2095
2096 2006-08-18  Bruno Haible  <bruno@clisp.org>
2097
2098         * modules/bison-i18n: New file.
2099         * MODULES.html.sh (Internationalization functions): Add it.
2100
2101 2006-08-18  Bruno Haible  <bruno@clisp.org>
2102
2103         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
2104         sys/statvfs.h. When getmntinfo was found, check its declaration and
2105         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
2106
2107 2006-08-18  Bruno Haible  <bruno@clisp.org>
2108
2109         * m4/bison-i18n.m4: New file, from bison.
2110
2111 2006-08-18  Bruno Haible  <bruno@clisp.org>
2112
2113         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
2114         (ME_DUMMY): Treat "kernfs" as a dummy.
2115         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
2116
2117 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
2118
2119         Update from coreutils.
2120
2121         2006-08-15  Jim Meyering  <jim@meyering.net>
2122
2123         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
2124
2125         2006-01-17  Jim Meyering  <jim@meyering.net>
2126
2127         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
2128
2129         2006-01-11  Jim Meyering  <jim@meyering.net>
2130
2131         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
2132         Check for the lchmod function.
2133
2134 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
2135
2136         Update from coreutils.
2137
2138         * lib/__fpending.h: Add copyright notice.
2139         * lib/fprintftime.h: Likewise.
2140         * lib/savedir.c: Use (C) in copyright notice.
2141         * lib/savedir.h: Likewise.
2142
2143         2006-08-15  Jim Meyering  <jim@meyering.net>
2144
2145         * lib/at-func.c: New file, with the logic of all emulated at-functions.
2146         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
2147         in support of the EXPECTED_ERRNO macro.
2148         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
2149         definitions.  Instead, define the appropriate symbols and include
2150         "at-func.c".
2151         * lib/mkdirat.c (mkdirat): Likewise.
2152         * lib/fchmodat.c (fchmodat): Likewise.
2153         (ENOSYS): Remove definition.
2154         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
2155         it.  Don't include "unistd--.h" -- it wasn't ever used.
2156
2157         2006-01-17  Jim Meyering  <jim@meyering.net>
2158
2159         Rewrite fts.c not to change the current working directory,
2160         by using openat, fstatat, fdopendir, etc..
2161
2162         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
2163         (HAVE_OPENAT_SUPPORT): Define.
2164         [_LIBC] (fchdir): Don't undef or define; no longer used.
2165         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
2166         Now, this `function' always succeeds, and consumes its file descriptor
2167         parameter -- so callers must not close such FDs.  Update callers.
2168         (diropen_fd, opendirat, cwd_advance_fd): New functions.
2169         (diropen): Add parameter, SP.  Adjust all callers.
2170         Implement using diropen_fd, rather than open.
2171         (fts_open): Initialize new member, fts_cwd_fd.
2172         Remove fts_rft-setting code.
2173         (fts_close): Close fts_cwd_fd, if necessary.
2174         (__opendir2): Define in terms of opendir or opendirat,
2175         depending on whether the FST_NOCHDIR flag is set.
2176         (fts_build): Since fts_safe_changedir consumes its FD, and since
2177         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
2178         and close the dup'd file descriptor upon failure.
2179         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
2180         (fts_safe_changedir): Tweak semantics to reflect that this function
2181         now calls cwd_advance_fd and hence consumes its FD argument.
2182         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
2183         [struct FTS] (fts_rft): Remove now-unused member.
2184         [struct FTS] (fts_cycle.state): Improve comment.
2185
2186         * lib/openat.c (openat_needs_fchdir): New function.
2187         * lib/openat.h (openat_needs_fchdir): Declare it.
2188
2189 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
2190
2191         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
2192         Problem and fix reported by Pádraig Brady in
2193         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
2194
2195 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
2196
2197         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
2198
2199 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
2200
2201         * lib/memcoll.c (memcoll): Optimize for the common case where the
2202         arguments are bytewise equal.
2203
2204 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
2205
2206         * doc/regexprops-generic.texi: Add a copyright notice.
2207
2208 2006-08-15  Bruno Haible  <bruno@clisp.org>
2209
2210         * modules/tmpdir (License): Change to LGPL.
2211
2212 2006-08-15  Bruno Haible  <bruno@clisp.org>
2213
2214         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
2215         module.
2216
2217 2006-08-14  Simon Josefsson  <jas@extundo.com>
2218
2219         * config/srclist.txt: Add gnupload.
2220
2221 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
2222
2223         Change copyright notice from LGPL 2 to GPL 2, since that's the
2224         standard form used in the gnulib repository.
2225         * tests/test-lock.c: Likewise.
2226         * tests/test-stdint.c: Likewise.
2227         * tests/test-tls.c: Likewise.
2228
2229         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
2230         prelude-manager.  User shorter URLs for GNU projects, without '?'.
2231         Add copyright notice.
2232
2233         * check-module: Add copyright notice.  Output a copyright
2234         notice if "--version" is specified.
2235         * modules/COPYING: New file.
2236         * tests/test-getaddrinfo.c: Add copyright notice.
2237         * tests/test-verify.c: Likewise.
2238
2239 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
2240
2241         Change copyright notice from LGPL 2 to GPL 2, since that's the
2242         standard form used in the gnulib repository.
2243         * lib/lock.c: LGPL -> GPL.
2244         * lib/lock.h: Likewise.
2245         * lib/strnlen1.c: Likewise.
2246         * lib/strnlen1.h: Likewise.
2247         * lib/tls.c: Likewise.
2248         * lib/tls.h: Likewise.
2249         * lib/tmpdir.c: Likewise.
2250
2251         * lib/TODO: Remove; this belongs only in coreutils.
2252
2253 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
2254
2255         Add copyright notices to long-enough files that lack them, since
2256         otherwise the files aren't clearly free.  Use the same notice that
2257         getdate.texi already uses.
2258         * doc/alloca-opt.texi: Add copyright notice.
2259         * doc/alloca.texi: Likewise.
2260         * doc/ctime.texi: Likewise.
2261         * doc/functions.texi: Likewise.
2262         * doc/gcd.texi: Likewise.
2263         * doc/gnulib-tool.texi: Likewise.
2264         * doc/inet_ntoa.texi: Likewise.
2265         * doc/visibility.texi: Likewise.
2266
2267         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
2268         * doc/quote.texi: Add copyright notice.
2269
2270         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
2271         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
2272         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
2273         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
2274         is now obsolete, and give a pointer to the Sun list.
2275         Add copyright notice.
2276
2277 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
2278
2279         * config/srclistvars.sh: Add copyright notice.
2280
2281 2006-08-14  Eric Blake  <ebb9@byu.net>
2282
2283         Import the following change from libc:
2284
2285         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
2286
2287         Upstream bug 2997.
2288         * lib/misc/error.c: Add space between program name and message if file
2289         name is missing.
2290
2291 2006-08-12  Karl Berry  <karl@gnu.org>
2292
2293         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
2294         remove, these originate in gnulib now.
2295
2296 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2297
2298         * doc/Makefile (standards.info standards.html standards.dvi):
2299         Also depend on make-stds.texi.
2300
2301 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
2302
2303         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
2304         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
2305
2306         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
2307         in wchar_t.  Problem reported by Eric Blake.
2308
2309         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
2310         LEN is smaller than SIZE.  Suggested by Bruno Haible.
2311         Also, help the compiler to keep LEN in a register.
2312
2313 2006-08-11  Eric Blake  <ebb9@byu.net>
2314
2315         * users.txt: Sort.  Add tar.
2316
2317 2006-08-11  Bruno Haible  <bruno@clisp.org>
2318
2319         * users.txt: New file.
2320
2321 2006-08-11  Bruno Haible  <bruno@clisp.org>
2322
2323         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
2324         before <wchar.h>. Needed for OSF/1 and BSD/OS.
2325
2326 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
2327
2328         * modules/snprintf (Depends-on): Remove minmax.
2329         (Maintainer): Add self and Bruno.
2330
2331 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
2332
2333         * lib/.cppi-disable: Add snprintf.h, socket_.h.
2334         * lib/snprintf.c: Include <errno.h> and <limits.h>.
2335         (EOVERFLOW): Define if the system does not.
2336         Do not include "minmax.h"; it wasn't used.
2337         (snprintf): Don't assume size_t promotes to an unsigned type.
2338         Fix bug when generated string was too long for the buffer: the
2339         buffer's contents are supposed to be the initial prefix of the
2340         output.  Don't assume vasnprintf returns EOVERFLOW if the size
2341         exceeds INT_MAX; do the check ourselves.
2342
2343         Import the following changes from libc:
2344
2345         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
2346
2347         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
2348         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
2349         set wc to the byte which couldn't be converted.
2350         (re_string_reconstruct): Don't clear valid_raw_len before calling
2351         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
2352         tip_context using re_string_context_at.
2353
2354         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
2355
2356         * lib/posix/regex.h: g++ still cannot handled [restrict].
2357
2358         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
2359
2360         * lib/posix/regex.h: Remove special handling for VMS.
2361
2362 2006-08-10  Jim Meyering  <jim@meyering.net>
2363
2364         * modules/same-inode: New module.
2365         * modules/dev-ino: New module.
2366         * modules/cycle-check: Depend on these modules, rather than simply
2367         including their .h files.
2368         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
2369         required via m4/cycle-check.m4.
2370         * modules/same: Depend on new same-inode module, rather than
2371         including same-inode.h.
2372         * modules/chdir-safer: New file.
2373
2374         * modules/chown (Depends-on): Add stat-macros.
2375
2376 2006-08-10  Jim Meyering  <jim@meyering.net>
2377
2378         * m4/cycle-check.m4: New file.
2379         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
2380         * m4/dev-ino.m4, same-inode.m4: New files.
2381
2382 2006-08-10  Eric Blake  <ebb9@byu.net>
2383
2384         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
2385         in from original proposal.
2386
2387 2006-08-10  Eric Blake  <ebb9@byu.net>
2388         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2389
2390         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
2391         namespace.
2392
2393 2006-08-10  Bruno Haible  <bruno@clisp.org>
2394
2395         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
2396         as well.
2397
2398 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
2399
2400         Sync from coreutils.
2401
2402         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
2403
2404         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
2405         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
2406
2407 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
2408
2409         * modules/restrict: Remove; no longer needed now that we assume
2410         Autoconf 2.59 or later.
2411         * MODULES.html.sh: Remove 'restrict'.
2412         * modules/argp (Depends-on): Remove 'restrict'.
2413         * modules/base64 (Depends-on): Likewise.
2414         * modules/gc (Depends-on): Likewise.
2415         * modules/getaddrinfo (Depends-on): Likewise.
2416         * modules/glob (Depends-on): Likewise.
2417         * modules/inet_ntop (Depends-on): Likewise.
2418         * modules/inet_pton (Depends-on): Likewise.
2419         * modules/memxor (Depends-on): Likewise.
2420         * modules/regex (Depends-on): Likewise.
2421         * modules/strtok_r (Depends-on): Likewise.
2422         * modules/time_r (Depends-on): Likewise.
2423
2424 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
2425
2426         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
2427         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
2428         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
2429         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
2430         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
2431         * m4/memxor.m4 (gl_MEMXOR): Likewise.
2432         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
2433         gl_C_RESTRICT replaced by AC_C_RESTRICT.
2434
2435         Merge from coreutils.
2436         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
2437         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
2438         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2439         * m4/time_r.m4 (gl_TIME_R): Likewise.
2440
2441 2006-08-09  Karl Berry  <karl@gnu.org>
2442
2443         * config/srclist.txt: no more gettext-tools, per Bruno.
2444
2445 2006-08-08  Eric Blake  <ebb9@byu.net>
2446
2447         * modules/verror: New module.
2448         * MODULES.html.sh: Document it.
2449
2450 2006-08-08  Eric Blake  <ebb9@byu.net>
2451
2452         * lib/verror.h, verror.c: New files.
2453
2454 2006-08-08  Eric Blake  <ebb9@byu.net>
2455
2456         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
2457         verror_at_line output complies with GNU Coding Standards even when
2458         file is NULL.
2459
2460 2006-08-07  Bruno Haible  <bruno@clisp.org>
2461
2462         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
2463         versions of AIX.
2464         Reported by Ralf Wildenhues.
2465
2466 2006-08-07  Bruno Haible  <bruno@clisp.org>
2467
2468         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
2469         in an AC_DEFUN. Needed so that the autoconf snippets can use
2470         AC_REQUIRE.
2471
2472 2006-08-06  Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2473
2474         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2475         Initialize pkgdata_DATA.
2476         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
2477         overriding it.
2478
2479 2006-08-06  Eric Blake  <ebb9@byu.net>
2480
2481         * lib/error.h: Fold in some upstream changes from glibc.
2482         * lib/error.c: Likewise.
2483
2484 2006-08-04  Bruno Haible  <bruno@clisp.org>
2485
2486         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2487         Make the mostlyclean-local rule depend on mostlyclean-generic.
2488         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
2489
2490 2006-07-31  Bruno Haible  <bruno@clisp.org>
2491
2492         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
2493         <stdlib.h>, <string.h>.
2494
2495 2006-07-30  Bruno Haible  <bruno@clisp.org>
2496
2497         * modules/readlink (License): Change to LGPL.
2498
2499 2006-07-30  Bruno Haible  <bruno@clisp.org>
2500
2501         * modules/javaversion (Makefile.am): Distribute javaversion.java and
2502         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
2503         set PKGDATADIR to point to it.
2504
2505 2006-07-30  Bruno Haible  <bruno@clisp.org>
2506
2507         * modules/csharpexec (configure.ac): Comment out macro invocation.
2508         * modules/javaexec (configure.ac): Likewise.
2509         * modules/javacomp-script (configure.ac): Likewise.
2510
2511         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
2512
2513 2006-07-30  Bruno Haible  <bruno@clisp.org>
2514
2515         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
2516         linked-list.
2517
2518 2006-07-30  Bruno Haible  <bruno@clisp.org>
2519
2520         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
2521
2522 2006-07-30  Bruno Haible  <bruno@clisp.org>
2523
2524         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2525         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
2526         get removed.
2527
2528 2006-07-29  Bruno Haible  <bruno@clisp.org>
2529
2530         Make it possible for gnulib-tool to work with locally modified or
2531         augmented gnulib repositories.
2532         * gnulib-tool (func_usage): Document --local-dir option.
2533         (local_gnulib_dir): New variable.
2534         Handle --local-dir option.
2535         (func_lookup_file): New function.
2536         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
2537         (func_get_description, func_get_filelist, func_get_description,
2538         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
2539         func_get_automake_snippet, func_get_include_directive,
2540         func_get_license, func_get_maintainer): Use func_lookup_file.
2541         (func_import, func_create_testdir): Use func_lookup_file.
2542
2543 2006-07-29  Bruno Haible  <bruno@clisp.org>
2544
2545         * modules/setenv (Depends-on): Add unistd.
2546
2547 2006-07-29  Bruno Haible  <bruno@clisp.org>
2548
2549         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
2550
2551 2006-07-29  Bruno Haible  <bruno@clisp.org>
2552
2553         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
2554
2555 2006-07-29  Bruno Haible  <bruno@clisp.org>
2556
2557         * gnulib-tool (import, update): If there is no Makefile.am, look at
2558         aclocal.m4, instead of bailing out.
2559
2560 2006-07-29  Bruno Haible  <bruno@clisp.org>
2561
2562         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
2563         Categorize the options by when they are useful.
2564
2565 2006-07-29  Bruno Haible  <bruno@clisp.org>
2566
2567         * gnulib-tool (func_usage): Document option --no-libtool.
2568         Handle option --no-libtool.
2569         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
2570         for changed semantics of $libtool variable.
2571         (func_import): Likewise. If libtool is not used, show this through
2572         an option --no-libtool.
2573         (func_create_testdir): Update.
2574
2575 2006-07-29  Bruno Haible  <bruno@clisp.org>
2576
2577         * gnulib-tool (func_import): Extend error message about missing
2578         --doc-base.
2579
2580 2006-07-29  Bruno Haible  <bruno@clisp.org>
2581
2582         * gnulib-tool (func_import): Don't create the $docbase directory if
2583         there is no file to store there.
2584
2585 2006-07-29  Bruno Haible  <bruno@clisp.org>
2586
2587         * gnulib-tool (autoconf_minversion): If a --dir option is given and
2588         relevant, look for configure.ac there, not in the current directory.
2589         Also use a simple search for AC_PREREQ, not "autoconf --trace".
2590
2591 2006-07-29  Bruno Haible  <bruno@clisp.org>
2592
2593         * gnulib-tool (SORT): New variable.
2594         (func_usage): Undocument --assume-autoconf option.
2595         Remove --assume-autoconf option handling.
2596         (autoconf_minversion): Determine from the contents of configure.ac.
2597         (func_import): Remove autoconf_minversion handling.
2598         Suggested by Eric Blake.
2599
2600 2006-07-29  Bruno Haible  <bruno@clisp.org>
2601
2602         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
2603
2604 2006-07-29  Bruno Haible  <bruno@clisp.org>
2605
2606         * config/srclist.txt (*setenv.[ch]): Remove rules.
2607
2608 2006-07-28  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
2609
2610         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
2611
2612 2006-07-28  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
2613
2614         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
2615         arpa/inet.h.
2616
2617 2006-07-28  Simon Josefsson  <jas@extundo.com>
2618
2619         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
2620         * modules/inet_pton (Depends-on): Likewise.
2621
2622 2006-07-28  Simon Josefsson  <jas@extundo.com>
2623
2624         * m4/netinet_in_h.m4: New file.
2625
2626 2006-07-28  Simon Josefsson  <jas@extundo.com>
2627
2628         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
2629         #include's.
2630
2631 2006-07-28  Simon Josefsson  <jas@extundo.com>
2632
2633         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
2634         #include's.
2635
2636 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
2637
2638         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
2639         setgid on directories only if they set these bits.
2640         * lib/modechange.h: Remove obsolete comment about masks.
2641
2642 2006-07-28  Eric Blake  <ebb9@byu.net>
2643
2644         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
2645         macro expansion.
2646
2647 2006-07-28  Bruno Haible <bruno@clisp.org>
2648
2649         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
2650
2651 2006-07-28  Bruno Haible  <bruno@clisp.org>
2652
2653         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
2654
2655 2006-07-28  Bruno Haible  <bruno@clisp.org>
2656
2657         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
2658         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
2659         Define fallbacks.
2660         Avoids link error on FreeBSD 4.x.
2661         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
2662
2663         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
2664         encoding.
2665         * lib/mbswidth.c (iswcntrl): Likewise.
2666
2667 2006-07-27  Bruno Haible  <bruno@clisp.org>
2668
2669         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
2670         test.
2671
2672 2006-07-27  Bruno Haible  <bruno@clisp.org>
2673
2674         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
2675         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
2676         defined.
2677
2678 2006-07-26  Eric Blake  <ebb9@byu.net>
2679
2680         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
2681
2682 2006-07-26  Eric Blake  <ebb9@byu.net>
2683
2684         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
2685         like mingw that lack mkstemp.
2686         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
2687         avoid compilation warning on mingw.
2688
2689 2006-07-26  Bruno Haible  <bruno@clisp.org>
2690
2691         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
2692         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
2693         INT_FAST*_MIN, INTPTR_MIN.
2694
2695 2006-07-25  Bruno Haible  <bruno@clisp.org>
2696
2697         * modules/version-etc (Depends-on): Add stdarg.
2698
2699 2006-07-25  Bruno Haible  <bruno@clisp.org>
2700
2701         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
2702         complex commands.
2703
2704 2006-07-25  Bruno Haible  <bruno@clisp.org>
2705
2706         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
2707         defined in <stdarg.h> or config.h.
2708
2709 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
2710
2711         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
2712         (gl_STDIO_SAFER): Remove.
2713
2714 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
2715
2716         * MODULES.html.sh (File stream based Input/Output):
2717         Add fopen-safer, tmpfile-safer; remove stdio-safer.
2718         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
2719         * modules/fopen-safer, modules/tmpfile-safer: New files.
2720         * modules/stdio-safer: Remove.
2721
2722 2006-07-24  Bruno Haible  <bruno@clisp.org>
2723
2724         * modules/tmpdir: New file.
2725         * MODULES.html.sh (File system functions): Add it.
2726
2727 2006-07-24  Bruno Haible  <bruno@clisp.org>
2728
2729         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
2730         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
2731
2732 2006-07-24  Bruno Haible  <bruno@clisp.org>
2733
2734         * modules/clean-temp: New file.
2735
2736 2006-07-24  Bruno Haible  <bruno@clisp.org>
2737
2738         * m4/tmpdir.m4: New file, from GNU gettext.
2739
2740 2006-07-24  Bruno Haible  <bruno@clisp.org>
2741
2742         * lib/tmpdir.h: New file, from GNU gettext.
2743         * lib/tmpdir.c: New file, from GNU gettext.
2744
2745 2006-07-24  Bruno Haible  <bruno@clisp.org>
2746
2747         * lib/clean-temp.h: New file, from GNU gettext.
2748         * lib/clean-temp.c: New file, from GNU gettext.
2749
2750 2006-07-23  Eric Blake  <ebb9@byu.net>
2751
2752         * modules/stdio-safer (Files): Add tmpfile-safer.c.
2753         (Depends-on): Add binary-io.
2754
2755 2006-07-23  Eric Blake  <ebb9@byu.net>
2756
2757         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
2758
2759 2006-07-23  Eric Blake  <ebb9@byu.net>
2760
2761         * lib/tmpfile-safer.c: New file.
2762         * lib/stdio-safer.h (fopen_safer): Add prototype.
2763         * lib/stdio--.h (tmpfile): Make safer.
2764
2765 2006-07-23  Bruno Haible  <bruno@clisp.org>
2766
2767         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
2768         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
2769         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
2770         gl_linked_remove_at): Use it.
2771
2772 2006-07-22  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
2773         and Simon Josefsson <jas@extundo.com>
2774
2775         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
2776
2777         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
2778
2779 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
2780
2781         * modules/close-stream: New file.
2782         * modules/closeout (Description): Make it clear that it exits
2783         with a diagnostic on error.
2784         (Depends-on): Add close-stream.  Remove fpending, stdbool.
2785         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
2786
2787 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
2788
2789         * m4/close-stream.m4: New file.
2790
2791 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
2792
2793         * lib/close-stream.c, close-stream.h: New files.
2794
2795 2006-07-22  Bruno Haible  <bruno@clisp.org>
2796
2797         Merge from GNU gettext 0.15.
2798
2799         2006-05-01  Bruno Haible  <bruno@clisp.org>
2800
2801                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
2802
2803         2006-07-22  Bruno Haible  <bruno@clisp.org>
2804
2805                 * modules/javaversion: New file.
2806                 * MODULES.html.sh (Java): Add javaversion.
2807
2808         2006-03-12  Bruno Haible  <bruno@clisp.org>
2809
2810                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
2811
2812         2005-12-04  Bruno Haible  <bruno@clisp.org>
2813
2814                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
2815                 (untested).
2816
2817         2006-06-21  Bruno Haible  <bruno@clisp.org>
2818
2819                 Avoid warnings from recent versions of mcs.
2820                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
2821                 -o, -L, -r any more. Use options documented since mcs-1.0
2822                 instead. Similarly for -g.
2823
2824         2005-12-04  Bruno Haible  <bruno@clisp.org>
2825
2826                 * build-aux/csharpcomp.sh.in: Suffix for resources is
2827                 .resources, not .resource.
2828
2829         2005-07-09  Bruno Haible  <bruno@clisp.org>
2830
2831                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
2832                 add a .dll suffix.
2833                 Reported by Mark Junker <mjscod@gmx.de>.
2834
2835         2006-07-22  Bruno Haible  <bruno@clisp.org>
2836
2837                 * modules/gettext: Upgrade to gettext-0.15.
2838                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
2839                 m4/visibility.m4.
2840                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
2841
2842 2006-07-22  Bruno Haible  <bruno@clisp.org>
2843
2844         Merge from GNU gettext 0.15.
2845
2846         2006-03-25  Bruno Haible  <bruno@clisp.org>
2847
2848                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
2849
2850         2006-07-21  Bruno Haible  <bruno@clisp.org>
2851
2852                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
2853                 "1.1".
2854
2855         2006-05-09  Bruno Haible  <bruno@clisp.org>
2856
2857                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
2858                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
2859                 for the conftestver execution.
2860
2861         2006-05-01  Bruno Haible  <bruno@clisp.org>
2862
2863                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
2864                 optional target-version argument. Verify that the compiler
2865                 groks source of the specified source-version, or add -source
2866                 option as necessary. Verify that the compiler produces
2867                 bytecode in the specified target-version, or add -target and
2868                 -source options as necessary. Make the result of the test
2869                 available as variable CONF_JAVAC. Also log error output in
2870                 config.log.
2871
2872         2006-03-11  Bruno Haible  <bruno@clisp.org>
2873
2874                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
2875
2876         2006-05-09  Bruno Haible  <bruno@clisp.org>
2877
2878                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
2879                 CLASSPATH_SEPARATOR to a semicolon.
2880
2881         2006-03-12  Bruno Haible  <bruno@clisp.org>
2882
2883                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
2884                 available as variable CONF_JAVA, for subsequent autoconf
2885                 tests. Also log error output in config.log.
2886
2887         2006-07-19  Bruno Haible  <bruno@clisp.org>
2888
2889                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
2890                 that getline works on glibc2 systems. Needed to avoid trouble
2891                 in relocatable.c.
2892                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
2893
2894         2005-12-04  Bruno Haible  <bruno@clisp.org>
2895
2896                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
2897                 launcher (untested).
2898
2899         2005-12-04  Bruno Haible  <bruno@clisp.org>
2900
2901                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
2902
2903         2006-07-22  Bruno Haible  <bruno@clisp.org>
2904
2905                 * gettext.m4: Update from GNU gettext-0.15.
2906                 * nls.m4: Likewise.
2907                 * po.m4: Likewise.
2908                 * inttypes-pri.m4: Likewise.
2909                 * inttypes-h.m4: Renamed from inttypes.m4.
2910                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
2911
2912 2006-07-22  Bruno Haible  <bruno@clisp.org>
2913
2914         Merge from GNU gettext 0.15.
2915
2916         2005-07-05  Bruno Haible  <bruno@clisp.org>
2917
2918                 * printf-args.c (printf_fetchargs): Work around broken
2919                 definition of wint_t on mingw.
2920
2921         2005-02-12  Bruno Haible  <bruno@clisp.org>
2922
2923                 * xallocsa.h: Add extern "C" for C++.
2924
2925         2006-05-17  Bruno Haible  <bruno@clisp.org>
2926
2927                 Cygwin portability.
2928                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
2929
2930         2006-04-30  Bruno Haible  <bruno@clisp.org>
2931
2932                 * progreloc.c: Include <mach-o/dyld.h> if available.
2933                 (find_executable): Use _NSGetExecutablePath when possible.
2934
2935         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
2936
2937                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
2938                 function.
2939
2940         2005-12-29  Bruno Haible  <bruno@clisp.org>
2941
2942                 * progreloc.c (set_program_name_and_installdir): Fix
2943                 compilation error.
2944
2945         2005-12-04  Bruno Haible  <bruno@clisp.org>
2946
2947                 Cygwin portability.
2948                 * progreloc.c: Include <windows.h> also on Cygwin.
2949                 (find_executable): Add support for Cygwin.
2950                 (set_program_name_and_installdir): Handle also platforms with
2951                 nonempty EXEEXT.
2952
2953         2006-07-11  Bruno Haible  <bruno@clisp.org>
2954
2955                 * javacomp.c: Fix a comment.
2956                 Reported by Jim Meyering.
2957
2958         2006-04-30  Bruno Haible  <bruno@clisp.org>
2959
2960                 * javacomp.h (compile_java_class): Add source_version,
2961                 target_version arguments.
2962                 * javacomp.c: Rewritten to choose only a compiler that
2963                 respects the specified source_version and target_version.
2964
2965         2006-06-27  Bruno Haible  <bruno@clisp.org>
2966
2967                 Assume correct S_ISDIR macro.
2968                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
2969
2970         2006-07-22  Bruno Haible  <bruno@clisp.org>
2971
2972                 * javaversion.h: New file, from GNU gettext.
2973                 * javaversion.c: New file, from GNU gettext.
2974                 * javaversion.java: New file, from GNU gettext.
2975                 * javaversion.class: New file, from GNU gettext.
2976
2977         2006-05-17  Bruno Haible  <bruno@clisp.org>
2978
2979                 Cygwin portability.
2980                 * javaexec.c (execute_java_class): Test for jview program
2981                 also on Cygwin.
2982
2983         2006-04-09  Bruno Haible  <bruno@clisp.org>
2984
2985                 * fatal-signal.c: Don't include string.h.
2986                 (at_fatal_signal): Use a copying loop instead of memcpy.
2987
2988         2005-12-04  Bruno Haible  <bruno@clisp.org>
2989
2990                 * csharpexec.c: Add support for 'clix' launcher (untested).
2991                 (execute_csharp_using_sscli): New function.
2992                 (execute_csharp_program): Call it.
2993
2994         2006-06-21  Bruno Haible  <bruno@clisp.org>
2995
2996                 Avoid warnings from recent versions of mcs.
2997                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
2998                 -o, -L, -r any more. Use options documented since mcs-1.0
2999                 instead. Similarly for -g.
3000
3001         2005-07-09  Bruno Haible  <bruno@clisp.org>
3002
3003                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
3004                 add a .dll suffix.
3005                 Reported by Mark Junker <mjscod@gmx.de>.
3006
3007         2006-06-17  Bruno Haible  <bruno@clisp.org>
3008
3009                 * config.charset: Update for NetBSD 3.0.
3010
3011         2006-05-17  Bruno Haible  <bruno@clisp.org>
3012
3013                 Cygwin portability.
3014                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
3015
3016         2006-05-16  Bruno Haible  <bruno@clisp.org>
3017
3018                 * localcharset.c [CYGWIN]: Include <windows.h>.
3019                 (get_charset_aliases): For Cygwin, return the same CPxxx
3020                 aliases list as under WIN32.
3021                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
3022                 the environment variables. Fall back to GetACP().
3023
3024         2006-04-05  Bruno Haible  <bruno@clisp.org>
3025
3026                 * config.charset: Update Juan Manuel Guerrero's address.
3027
3028         2005-02-12  Bruno Haible  <bruno@clisp.org>
3029
3030                 * allocsa.h: Add extern "C" for C++.
3031
3032         2005-02-10  Bruno Haible  <bruno@clisp.org>
3033
3034                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
3035                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
3036
3037         2006-07-22  Bruno Haible  <bruno@clisp.org>
3038
3039                 * gettext.h: Update to GNU gettext-0.15.
3040
3041 2006-07-22  Bruno Haible  <bruno@clisp.org>
3042
3043         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
3044         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
3045         lib-prefix.m4, longdouble.m4, ssize_t.m4.
3046
3047 2006-07-21  Eric Blake  <ebb9@byu.net>
3048
3049         * modules/stdlib-safer: New file.
3050         * MODULES.html.sh (File stream based Input/Output): Add
3051         stdlib-safer.
3052
3053 2006-07-21  Eric Blake  <ebb9@byu.net>
3054
3055         * lib/stdlib-safer.h: New file from coreutils, required by
3056         stdlib--.h.
3057
3058 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
3059
3060         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
3061
3062 2006-07-20  Bruno Haible  <bruno@clisp.org>
3063
3064         * gnulib-tool: Recognize new option --assume-autoconf.
3065         (autoconf_minversion): New variable.
3066         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
3067
3068 2006-07-20  Bruno Haible  <bruno@clisp.org>
3069
3070         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
3071
3072 2006-07-19  Derek R. Price  <derek@ximbiot.com>
3073
3074         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
3075         Reindent and repaginate.
3076
3077 2006-07-19  Derek Price  <derek@ximbiot.com>
3078
3079         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
3080         Correct grammar.
3081
3082 2006-07-17  Bruno Haible  <bruno@clisp.org>
3083
3084         * modules/list: New file.
3085         * modules/array-list: New file.
3086         * modules/carray-list, modules/carray-list-tests: New files.
3087         * modules/linked-list, modules/linked-list-tests: New files.
3088         * modules/avltree-list, modules/avltree-list-tests: New files.
3089         * modules/rbtree-list, modules/rbtree-list-tests: New files.
3090         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
3091         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
3092         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
3093         * modules/oset: New file.
3094         * modules/array-oset: New file.
3095         * modules/avltree-oset, modules/avltree-oset-tests: New files.
3096         * modules/rbtree-oset, rbtree-oset-tests: New files.
3097         * tests/test-carray_list.c: New file.
3098         * tests/test-linked_list.c: New file.
3099         * tests/test-avltree_list.c: New file.
3100         * tests/test-rbtree_list.c: New file.
3101         * tests/test-linkedhash_list.c: New file.
3102         * tests/test-avltreehash_list.c: New file.
3103         * tests/test-rbtreehash_list.c: New file.
3104         * tests/test-avltree_oset.c: New file.
3105         * tests/test-rbtree_oset.c: New file.
3106         * MODULES.html.sh (Container data structures): New section.
3107
3108 2006-07-17  Bruno Haible  <bruno@clisp.org>
3109
3110         * m4/gl_list.m4: New file.
3111
3112 2006-07-17  Bruno Haible  <bruno@clisp.org>
3113
3114         * lib/gl_list.h: New file.
3115         * lib/gl_list.c: New file.
3116         * lib/gl_array_list.h: New file.
3117         * lib/gl_array_list.c: New file.
3118         * lib/gl_carray_list.h: New file.
3119         * lib/gl_carray_list.c: New file.
3120         * lib/gl_linked_list.h: New file.
3121         * lib/gl_linked_list.c: New file.
3122         * lib/gl_anylinked_list1.h: New file.
3123         * lib/gl_anylinked_list2.h: New file.
3124         * lib/gl_avltree_list.h: New file.
3125         * lib/gl_avltree_list.c: New file.
3126         * lib/gl_anyavltree_list1.h: New file.
3127         * lib/gl_anyavltree_list2.h: New file.
3128         * lib/gl_rbtree_list.h: New file.
3129         * lib/gl_rbtree_list.c: New file.
3130         * lib/gl_anyrbtree_list1.h: New file.
3131         * lib/gl_anyrbtree_list2.h: New file.
3132         * lib/gl_anytree_list1.h: New file.
3133         * lib/gl_anytree_list2.h: New file.
3134         * lib/gl_linkedhash_list.h: New file.
3135         * lib/gl_linkedhash_list.c: New file.
3136         * lib/gl_anyhash_list1.h: New file.
3137         * lib/gl_anyhash_list2.h: New file.
3138         * lib/gl_avltreehash_list.h: New file.
3139         * lib/gl_avltreehash_list.c: New file.
3140         * lib/gl_rbtreehash_list.h: New file.
3141         * lib/gl_rbtreehash_list.c: New file.
3142         * lib/gl_anytreehash_list1.h: New file.
3143         * lib/gl_anytreehash_list2.h: New file.
3144
3145         * lib/gl_oset.h: New file.
3146         * lib/gl_oset.c: New file.
3147         * lib/gl_array_oset.h: New file.
3148         * lib/gl_array_oset.c: New file.
3149         * lib/gl_avltree_oset.h: New file.
3150         * lib/gl_avltree_oset.c: New file.
3151         * lib/gl_rbtree_oset.h: New file.
3152         * lib/gl_rbtree_oset.c: New file.
3153         * lib/gl_anytree_oset.h: New file.
3154
3155 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
3156
3157         * m4/mkancesdirs.m4: New file.
3158         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
3159         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
3160         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
3161         it.
3162
3163 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
3164
3165         * lib/dirchownmod.c, dirchownmod.h, mkancesdirs.c, mkancesdirs.h:
3166         New files.
3167         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
3168         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
3169         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
3170         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
3171         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
3172         callers changed.  Revamp internals significantly, by not
3173         attempting to create directories that are temporarily more
3174         permissive than the final results.  Do not attempt to use
3175         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
3176         This removes some race conditions, fixes some bugs, and simplifies
3177         things.  Use new dirchownmod function to do owner and mode changes.
3178         * lib/mkdir-p.h: Likewise.
3179         * lib/modechange.c (octal_to_mode): New function.
3180         (struct mode_change): New member mentioned.
3181         (make_node_op_equals): New arg mentioned.  All callers changed.
3182         (mode_compile): Keep track of which mode bits the user has explicitly
3183         mentioned.
3184         (mode_adjust): New arg DIR, so that we implement the X op correctly.
3185         New arg PMODE_BITS, to keep track of which mode bits the user
3186         mentioned; it treats S_ISUID and S_ISGID speciall.
3187         All callers changed.
3188         * lib/modechange.h: Likewise.
3189
3190 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
3191
3192         * MODULES.html.sh: Add mkancestors.
3193         * modules/mkancesdirs: New module.
3194         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
3195         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
3196         The chdir-safer and afs files are now orphans; I'll remove them
3197         unless someone speaks up.
3198         Add lib/dirchownmod.c, lib/dirchownmod.h.
3199         (Depends-on): Remove alloca, chown, save-cwd, dirname.
3200         Add lchown, mkancesdirs.
3201         (Maintainer): Add self.
3202
3203 2006-07-15  Karl Berry  <karl@gnu.org>
3204
3205         * gnulib-tool: help message wording/arrangement.
3206
3207 2006-07-14  Simon Josefsson  <jas@extundo.com>
3208
3209         * doc/gnulib.texi (Libtool and Windows): New section.
3210
3211 2006-07-12  Simon Josefsson  <jas@extundo.com>
3212
3213         * modules/gendocs (License): Fix license, approved by Karl.
3214
3215 2006-07-12  Eric Blake  <ebb9@byu.net>
3216
3217         * MODULES.html.sh: Add gendocs.
3218
3219 2006-07-11  Eric Blake  <ebb9@byu.net>
3220
3221         * modules/fdl: New module, to install doc/fdl.texi.
3222         * MODULES.html.sh: Add new section for documentation modules.
3223         * gnulib-tool: Avoid space-tab.
3224         (--doc-base): New option, to manage files from doc.
3225
3226 2006-07-11  Eric Blake  <ebb9@byu.net>
3227
3228         * m4/absolute-header.m4: Fix comments to match recent change.
3229
3230 2006-07-11  Eric Blake  <ebb9@byu.net>
3231
3232         * gnulib-tool: List --doc-base before --tests-base.
3233
3234 2006-07-11  Derek R. Price  <derek@ximbiot.com>
3235
3236         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
3237
3238 2006-07-11  Bruno Haible  <bruno@clisp.org>
3239
3240         * README: Mention where to put documentation.
3241
3242 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3243
3244         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
3245
3246 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
3247
3248         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
3249         to stdint.m4.
3250
3251 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
3252
3253         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
3254         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
3255         "no/such/file/stdint.h" when there is no such file, so that
3256         the resulting C code can be parsed by dodgy compilers.
3257         Problems reported by Bob Proulx.
3258
3259 2006-07-10  Derek R. Price  <derek@ximbiot.com>
3260
3261         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
3262         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
3263         macros into the GNU _D_EXACT_NAMLEN.
3264         * lib/savedir.c:  Likewise.
3265         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
3266
3267 2006-07-10  Derek R. Price  <derek@ximbiot.com>
3268         and Paul Eggert  <eggert@cs.ucla.edu>
3269
3270         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
3271         * m4/savedir.m4:
3272         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
3273         macros into the GNU _D_EXACT_NAMLEN.
3274
3275 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
3276
3277         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
3278         around the absolute name, to work around a problem with the HP-UX
3279         11.23 native C compiler, reported by Bob Proulx.
3280
3281 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
3282
3283         * doc/maintain.texi, make-stds.texi: Sync from
3284         <http://savannah.gnu.org/projects/gnustandards>.
3285
3286 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
3287
3288         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
3289
3290 2006-07-09  Jim Meyering  <jim@meyering.net>
3291
3292         * m4/glob.m4: Remove a doubled word in a comment.
3293
3294 2006-07-09  Jim Meyering  <jim@meyering.net>
3295
3296         * lib/argp-pv.c: Remove a doubled word in a comment.
3297         * lib/check-version.c (check_version): Likewise.
3298         * lib/javacomp.c (compile_java_class): Likewise.
3299
3300 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
3301
3302         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
3303         for the benefit of people using Autoconf 2.60.  If you want to
3304         support older Autoconf versions you can copy m4/onceonly_2_57.m4
3305         (or m4/onceonly.m4, if pre-2.57) manually.
3306
3307 2006-07-08  Jim Meyering  <jim@meyering.net>
3308
3309         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
3310         comment.
3311         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
3312         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
3313         comment.
3314
3315 2006-07-08  Jim Meyering  <jim@meyering.net>
3316
3317         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
3318
3319 2006-07-07  Simon Josefsson  <jas@extundo.com>
3320
3321         * tests/test-crc.c: Change expected crc value, the test vector
3322         were probably computed using the old broken crc.c?
3323
3324 2006-07-06  Simon Josefsson  <jas@extundo.com>
3325
3326         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
3327         now the canonical place for the M4 file).
3328
3329         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
3330         from the sys_socket dependency now.
3331
3332         * modules/inet_pton (Files): Ditto.
3333
3334         * modules/inet_ntop (Files): Ditto.
3335
3336 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3337
3338         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
3339         not gl_PREREQ_GETUSERSHELL.
3340
3341 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3342
3343         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
3344         with only one argument, for Autoconf 2.60.
3345         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
3346         expand to nothing, so add a shell command to avoid syntax error.
3347         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
3348
3349 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3350
3351         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
3352
3353 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
3354
3355         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
3356         no longer needed.  Check for isblank decl.
3357         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
3358         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
3359         of existence.
3360
3361 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
3362
3363         * lib/getloadavg.c: Use __VMS, not VMS.
3364         * lib/getopt.c: Likewise.
3365         * lib/getpagesize.h: Likewise.
3366         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
3367         and probably does not work.
3368
3369 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
3370
3371         * lib/.cppi-disable: Add wcwidth.
3372         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
3373         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
3374         (ISGRAPH): Remove.  All uses changed to isgraph.
3375         (FOLD) [!defined _LIBC]: Remove special case.
3376         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
3377         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
3378         HAVE_ISBLANK.
3379         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
3380         case.
3381
3382 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>
3383
3384         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
3385         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
3386         brackets.  Other minor changes to suppress some compiler
3387         warnings.
3388
3389 2006-07-06  Derek R. Price  <derek@ximbiot.com>
3390         and Paul Eggert  <eggert@cs.ucla.edu>
3391
3392         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
3393         of invoking obsolescent AC_HEADER_DIRENT macro.
3394         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
3395         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
3396         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
3397         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
3398         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
3399         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
3400         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
3401         * m4/readdir.m4: Remove; no longer needed.
3402
3403 2006-07-06  Derek R. Price  <derek@ximbiot.com>
3404         and Paul Eggert  <eggert@cs.ucla.edu>
3405
3406         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
3407         Don't worry about this obsolete case any more.
3408         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
3409         directories.
3410         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
3411         worry about this obsolete case any more.
3412         * lib/fts.c: Likewise.
3413         * lib/getcwd.c: Likewise.
3414         * lib/glob.h: Likewise.
3415         * lib/savedir.c: Likewise.
3416
3417 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
3418
3419         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
3420         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
3421         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
3422         needed.
3423         All uses removed.
3424         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
3425         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
3426         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
3427         needed.
3428         * m4/getdate.m4 (gl_GETDATE): Likewise.
3429         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
3430         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
3431         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
3432         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
3433         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
3434         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
3435         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
3436         needed.
3437
3438 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
3439
3440         * lib/memcasecmp.c: Include <limits.h>.
3441         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
3442         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
3443         Don't assume isdigit succeeds only on '0' through '9'.
3444
3445 2006-07-05  Eric Blake  <ebb9@byu.net>
3446
3447         * modules/getaddrinfo (Depends-on): Add snprintf.
3448
3449 2006-07-05  Eric Blake  <ebb9@byu.net>
3450
3451         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
3452         to avoid 'header present but could not be compiled' on cygwin.
3453
3454 2006-07-05  Eric Blake  <ebb9@byu.net>
3455
3456         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
3457         missing from netdb.h.
3458         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
3459
3460 2006-07-05  Derek R. Price  <derek@ximbiot.com>
3461
3462         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
3463         no longer needed.
3464         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
3465         * m4/getdate.m4 (gl_GETDATE): Likewise.
3466         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
3467         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
3468         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
3469         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
3470         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
3471
3472 2006-07-05  Derek R. Price  <derek@ximbiot.com>
3473
3474         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
3475         All uses of is_space replaced by isspace.
3476         * lib/exit.h: Don't talk about STDC_HEADERS.
3477         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
3478         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
3479         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
3480         replaced by isprint etc.
3481         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
3482         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
3483         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
3484         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
3485         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
3486         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
3487
3488 2006-07-05  Bruno Haible  <bruno@clisp.org>
3489
3490         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
3491         the function exists, before testing against AIX.
3492         Reported by Martin Lambers <marlam@marlam.de>.
3493
3494 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
3495
3496         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
3497         From Mark D. Baushke.
3498
3499 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
3500
3501         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
3502         to the absolute name, not just one, to bypass Sun C 5.8's
3503         "warning: #include of /usr/include/... may be non-portable".
3504
3505 2006-07-04  Eric Blake  <ebb9@byu.net>
3506
3507         * modules/dirname-tests: New test module.
3508         * tests/test-dirname.c: New file, replacing dirname.c
3509         TEST_DIRNAME section that was recently deleted.
3510
3511 2006-07-04  Bruno Haible  <bruno@clisp.org>
3512
3513         Assume ANSI C header files and <ctype.h> functions.
3514         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
3515         (mbsnwidth): Use isprint, iscntrl instead.
3516
3517 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
3518
3519         Merge from coreutils.
3520         * MODULES.html.sh: Add xstrtold.
3521         * modules/xstrtold: New file.
3522         * modules/cycle-check (Files): Add lib/same-inode.h.
3523         * modules/dirname (Files): Add m4/double-slash-root.m4.
3524         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
3525         * modules/mkdir-p (Files): Add lib/same-inode.h.
3526         * modules/same (Files): Add lib/same-inode.h.
3527
3528 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
3529
3530         * m4/absolute-header.m4: Renamed from full-header-path.m4.
3531         This is to keep the terminology clean; POSIX talks about
3532         "absolute pathnames", not "full pathnames", but the GNU
3533         Coding Standards say to use "path" for something else;
3534         so use "absolute" to keep both sides happy.
3535         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
3536         Set gl_absolute_header, not gl_full_header_path.
3537         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
3538         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
3539         All uses changed.
3540
3541         Merge from coreutils.
3542
3543         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
3544
3545         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
3546         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
3547         want to require the building of c-strtod.o.
3548         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
3549         needs -lm directly.
3550         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
3551
3552         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
3553
3554         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
3555         --as-needed option if available.  Problem reported by Albert Chin in
3556         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
3557         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
3558         cc merely issues a bunch of annoying warnings for --as-needed
3559         (this problem was reported by Bob Proulx).  Also, try linking with
3560         -lm to detect a bug in binutils 2.16 (this problem was reported
3561         by Ralf Wildenhues).
3562
3563         2006-06-18  Jim Meyering  <jim@meyering.net>
3564
3565         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
3566         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
3567         macro.
3568         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
3569         also check for glibc-2.4's abort-inducing bug.
3570
3571         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
3572         Low-probability clean-up should be to use rmdir to get rid of
3573         the just-created directory, not unlink.
3574
3575         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
3576         configure fail, and request a bug report to inform us about it.
3577         Add a comment that, barring reports to the contrary, in 2007 we'll
3578         assume ftruncate is universally available.
3579
3580         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
3581
3582         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
3583
3584         2006-03-12  Jim Meyering  <jim@meyering.net>
3585
3586         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
3587         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
3588         * m4/same.m4 (gl_SAME): Likewise.
3589         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
3590
3591         2006-03-11  Eric Blake  <ebb9@byu.net>
3592
3593         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
3594         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
3595         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
3596         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
3597
3598 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
3599
3600         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
3601         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
3602         reported by Mark D. Baushke, one in
3603         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
3604
3605         Merge from coreutils.
3606
3607         * lib/.cppi-disable: Add stdint_.h.
3608         * lib/.cvsignore: Add stdint.h.
3609
3610         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
3611
3612         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
3613         both double and long double versions.
3614         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
3615         * lib/xstrtold.c: New file.
3616         * lib/xstrtod.h (xstrtold): New decl.
3617
3618         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
3619
3620         * lib/filemode.c (setst): Remove.
3621         (strmode): Rewrite to avoid setst.  This makes the code shorter,
3622         (arguably) clearer, and the generated code is a bit smaller on my
3623         Debian GNU/Linux stable x86 host.
3624
3625         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
3626
3627         * lib/filemode.c: Include "filemode.h" first, to test the interface.
3628         Assume that filemode.h includes sys/types.h and sys/stat.h.
3629         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
3630         (ftypelet): Reorder to put common cases first, for efficiency.
3631         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
3632         to do 'M'.
3633         (strmode): Renamed from mode_string, and now stores 12 bytes instead
3634         of 10, for compatibility with FreeBSD.  All callers changed.
3635         (filemodestring): Now stores 12 bytes instead of 10, and sets file
3636         types that can't be deduced solely from st_mode.  First arg is now a
3637         const pointer.
3638         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
3639         (strmode): Renamed from mode_string.
3640         (filemodestring): New decl.
3641         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
3642         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
3643         needed.
3644         (S_ISPORT, S_ISWHT): New macros, if not already defined.
3645
3646         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
3647
3648         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
3649         fsusage.h now does that.  Include fsusage.h first, to test interface.
3650         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
3651         at most one method (the old code could have generated decls that
3652         didn't conform to C89, not that this was ever exercised).
3653         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
3654
3655         2006-03-19  Jim Meyering  <jim@meyering.net>
3656
3657         Work even in a chroot where d_ino values for entries in "/"
3658         don't match the stat.st_ino values for the same names.
3659         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
3660         number, iterate through all entries again, using lstat instead.
3661         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
3662         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
3663
3664         * lib/getcwd.c (__getcwd): Clarify a comment.
3665         Use memcpy in place of a call to strcpy.
3666
3667         2006-03-12  Jim Meyering  <jim@meyering.net>
3668
3669         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
3670         matches that of the current directory (which we're about to chdir ".."
3671         out of), then save the dev-ino of the parent, instead.
3672
3673         * lib/same-inode.h (SAME_INODE): New file/macro.
3674         * lib/chdir-safer.c (SAME_INODE): Remove definition.
3675         Include "same-inode.h", instead.
3676         * lib/same.c: Likewise.
3677         * lib/cycle-check.h: Include "same-inode.h".
3678         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
3679         * lib/cycle-check.c (SAME_INODE): Remove definition.
3680         * lib/root-dev-ino.h: Include "same-inode.h".
3681
3682         2006-03-11  Eric Blake  <ebb9@byu.net>
3683
3684         * lib/same.c (same_name): s/base_name/last_component/
3685         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
3686         * lib/filenamecat.c (file_name_concat): Likewise.
3687
3688         2006-03-11  Eric Blake  <ebb9@byu.net>,
3689                     Paul Eggert  <eggert@cs.ucla.edu>
3690
3691         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
3692         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
3693         drive prefix.
3694         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
3695         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
3696         (last_component): New method.
3697         * lib/dirname.c (dir_len): Determine when drive letters need a
3698         subsequent slash.  Preserve // when it is special.
3699         (dir_name): Don't append dot when drive letter is absolute.
3700         [TEST_DIRNAME]: Move into a full-blown gnulib test.
3701         * lib/basename.c (base_name): New semantics - malloc the result.
3702         Preserve // when it is special.  Preserve relative files that look
3703         like drive letters.
3704         (base_len): Preserve // when it is special.
3705         (last_component): New method, similar to old base_name semantics.
3706         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
3707         base_name.  Strip redundant slashes from ///.
3708
3709 2006-07-03  Jim Meyering  <jim@meyering.net>
3710
3711         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
3712         macro is used before the first cycle_check call.
3713
3714 2006-07-03  Eric Blake  <ebb9@byu.net>
3715
3716         * modules/dirname (Depends-on): Add xstrndup.
3717
3718 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
3719
3720         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
3721         test cases, so that config.log is a bit easier to follow.
3722
3723 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
3724
3725         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
3726         both are 64 bits, since this seems to be the tradition, and this
3727         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
3728         we ever run into a host that prefers long long to long in this
3729         case, we'll need another configure-time test.  Problem reported by
3730         Jim Meyering.
3731
3732 2006-07-02  Eric Blake  <ebb9@byu.net>
3733
3734         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
3735
3736 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
3737
3738         * modules/inttypes (Depends-on): No longer depends on stdint.
3739         * modules/stdint (Description): Say more about assumptions.
3740         Say that the fast types might differ.  Say macros are used.
3741         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
3742         (Makefile.am): Revise list of substituted symbols to match
3743         new stdint.m4.
3744         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
3745         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
3746         * tests/test-stdint.c (verify_same_types)
3747         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
3748         the code conforms to C99/C89.
3749         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
3750         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
3751
3752 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
3753
3754         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
3755         but fix a bug, by requiring at least 64 bits.
3756         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
3757         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
3758         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
3759         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
3760
3761         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
3762         changes.  Make 2.59 a prerequisite.  Check and substitute for
3763         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
3764         inttypes.h.  Do not use special include files; just use the
3765         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
3766         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
3767         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
3768         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
3769         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
3770         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
3771         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
3772         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
3773         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
3774         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
3775         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
3776         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
3777         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
3778         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
3779         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
3780         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
3781         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
3782         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
3783         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
3784         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
3785         WINT_MAX.  Check for C99 conformance more strictly, by detecting
3786         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
3787         not check for things that C99 does not require, e.g., int8_t.  If
3788         a test isn't needed unless <stdint.h> isn't working, and is
3789         unlikely to be needed for any other reason, then don't do it
3790         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
3791         size_t, since we assume C89 freestanding at least.  Do not check
3792         for sig_atomic_t, wchar_t, or wint_t, since the code now does
3793         the right thing even if the types are not defined.  Instead use:
3794         (gl_STDINT_TYPE_PROPERTIES): New macro.
3795         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
3796         testing whether <sys/types.h> clashes, as Autoconf does this for
3797         us now.  All uses removed.
3798         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
3799         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
3800         (gl_CHECK_TYPE_SAME):
3801         Remove; no longer needed.
3802         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
3803         exists, since we'll return 0 anyway in that case.
3804         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
3805
3806 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
3807
3808         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
3809         possible collision with system files.
3810         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
3811         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
3812         WCHAR_MIN and WCHAR_MAX in this case.
3813         (<stddef.h>): Do not include; no longer needed.
3814         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
3815         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
3816         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
3817         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
3818         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
3819         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
3820         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
3821         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
3822         !defined(__c99))]: Include in this case too, since it's harmless
3823         now.
3824         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
3825         dangerous to do so.
3826         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
3827         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
3828         (_STDINT_MIN, _STDINT_MAX): New macros.
3829         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
3830         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
3831         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
3832         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
3833         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
3834         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
3835         macros, not typedefs; this simplifies things quite a bit.
3836         Use long int for all types narrower than int64_t.
3837         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
3838         Define in terms of long long int or int64_t or long int,
3839         not int64_t or int32_t.  This saves some compile-time testing.
3840         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
3841         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
3842         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
3843         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
3844         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
3845         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
3846         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
3847         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
3848         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
3849         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
3850         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
3851         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
3852         undef any previous version and define our own version, for
3853         simplicity and consistency with the new macros for types.
3854         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
3855         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
3856         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
3857         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
3858         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
3859         @WINT_T_SUFFIX@ to keep things simple here.
3860         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
3861         Simplify by assuming typical 8/16/32/64 host, since we're
3862         already doing that elsewhere anyway.
3863         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
3864         and assume long long int is 64 bits if available.  This
3865         speeds up 'configure'.
3866
3867 2006-07-01  Eric Blake  <ebb9@byu.net>
3868
3869         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
3870         Reported by Andreas Buening.
3871
3872 2006-07-01  Eric Blake  <ebb9@byu.net>
3873
3874         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
3875
3876 2006-06-30  Jim Hyslop <jhyslop@dreampossible.ca>
3877
3878         * lib/getaddrinfo.c: fixed typo
3879
3880 2006-06-29  Jim Meyering  <jim@meyering.net>
3881
3882         * modules/strftime (Maintainer): Add my name, since with the
3883         FPRINTFTIME changes strftime.c has forked from glibc.
3884
3885 2006-06-29  Eric Blake  <ebb9@byu.net>
3886
3887         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
3888
3889 2006-06-29  Eric Blake  <ebb9@byu.net>
3890
3891         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
3892
3893 2006-06-29  Eric Blake  <ebb9@byu.net>
3894
3895         * lib/stat_.h: New file.
3896
3897 2006-06-29  Eric Blake  <ebb9@byu.net>
3898
3899         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
3900         unused static function.
3901
3902 2006-06-29  Eric Blake  <ebb9@byu.net>
3903
3904         * doc/functions.texi (Function Portability): Document missing lstat
3905         on mingw.
3906
3907 2006-06-29  Eric Blake  <ebb9@byu.net>
3908
3909         * MODULES.html.sh: Add sys_stat.
3910         * modules/sys_stat: New module.
3911         * modules/mkstemp (Depends-on): Add sys_stat.
3912
3913 2006-06-29  Derek R. Price  <derek@ximbiot.com>
3914
3915         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
3916
3917 2006-06-29  Derek R. Price  <derek@ximbiot.com>
3918
3919         * m4/c-bs-a.m4: Removed.
3920
3921 2006-06-29  Derek R. Price  <derek@ximbiot.com>
3922
3923         * lib/strftime.c: Assume strftime() exists.
3924
3925 2006-06-29  Derek Price  <derek@ximbiot.com>
3926
3927         * modules/c-bs-a: Removed - \a is C89.
3928         * MODULES.html.sh: Remove c-bs-a.
3929
3930 2006-06-29  Bruno Haible  <bruno@clisp.org>
3931
3932         * modules/wcwidth (License): Change to LGPL.
3933
3934 2006-06-28  Simon Josefsson  <jas@extundo.com>
3935
3936         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
3937         on _WIN32.
3938
3939         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
3940         getnameinfo.
3941
3942 2006-06-28  Simon Josefsson  <jas@extundo.com>
3943
3944         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
3945
3946 2006-06-28  Simon Josefsson  <jas@extundo.com>
3947
3948         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
3949         functions there.  It will succeed on Windows XP, but on Windows
3950         2000 and (presumably) earlier, it will fail, and use the internal
3951         re-implementation.
3952         (use_win32_p): New function.
3953         (getaddrinfo): Use strtoul on servname, to support numeric ports.
3954         Support AI_NUMERICSERV to disable getservbyname.
3955         (getnameinfo): New function, only supports
3956         NI_NUMERICHOST|NI_NUMERICSERV for now.
3957
3958         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
3959         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
3960         getnameinfo.
3961
3962 2006-06-28  Eric Blake  <ebb9@byu.net>
3963
3964         * modules/wcwidth: New file.
3965         * modules/mbchar (Depends-on): Add wcwidth.
3966         * modules/mbswidth (Depends-on): Add wcwidth.
3967         * MODULES.html.sh: Add wcwidth.
3968
3969 2006-06-28  Eric Blake  <ebb9@byu.net>
3970
3971         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
3972         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
3973
3974 2006-06-28  Eric Blake  <ebb9@byu.net>
3975
3976         * lib/xvasprintf.h: Fix comments.
3977
3978 2006-06-28  Eric Blake  <ebb9@byu.net>
3979
3980         * lib/mbchar.h (wcwidth): Include wcwidth.h.
3981         * lib/mbswidth.c (wcwidth): Move from here...
3982         * lib/wcwidth.h: ...to this new file.
3983
3984 2006-06-28  Derek R. Price  <derek@ximbiot.com>
3985
3986         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
3987
3988         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
3989         it's obsolete.
3990         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
3991
3992 2006-06-28  Derek R. Price  <derek@ximbiot.com>
3993
3994         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
3995         Autoconf 2.60 says this stuff was obsolete.
3996
3997 2006-06-28  Bruno Haible  <bruno@clisp.org>
3998
3999         * modules/wcwidth (Files): Add m4/wchar_t.m4.
4000
4001 2006-06-28  Bruno Haible  <bruno@clisp.org>
4002
4003         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
4004         gt_TYPE_WCHAR_T.
4005
4006 2006-06-28  Bruno Haible  <bruno@clisp.org>
4007
4008         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
4009         declaration for wcwidth.
4010         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
4011
4012 2006-06-28  Bruno Haible  <bruno@clisp.org>
4013
4014         * lib/mkdtemp.c [MINGW]: Include <io.h>.
4015         (mkdir): Define using _mkdir.
4016
4017 2006-06-28  Bruno Haible  <bruno@clisp.org>
4018
4019         * lib/getaddrinfo.h: Fix POSIX URL.
4020         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
4021         _WIN32.
4022         (use_win32_p): Make static.
4023         (getaddrinfo): Reject service name if it is empty or does not consist
4024         solely of decimal digits, or if its value is > 65535.
4025         (getnameinfo): Remove useless casts.
4026
4027 2006-06-27  Simon Josefsson  <jas@extundo.com>
4028
4029         * modules/sys_select: New file, suggested by Bruno Haible, Paul
4030         Eggert and Martin Lambers.
4031
4032 2006-06-27  Simon Josefsson  <jas@extundo.com>
4033
4034         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
4035         Eggert and Martin Lambers.
4036
4037 2006-06-27  Bruno Haible  <bruno@clisp.org>
4038
4039         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
4040         result to 0, not to empty.
4041         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
4042
4043 2006-06-27  Bruno Haible  <bruno@clisp.org>
4044
4045         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
4046
4047 2006-06-26  Simon Josefsson  <jas@extundo.com>
4048
4049         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
4050         present.
4051
4052 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
4053
4054         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
4055         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
4056         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
4057
4058 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
4059
4060         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
4061
4062 2006-06-26  Bruno Haible  <bruno@clisp.org>
4063
4064         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
4065
4066 2006-06-26  Bruno Haible  <bruno@clisp.org>
4067
4068         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
4069
4070 2006-06-26  Bruno Haible  <bruno@clisp.org>
4071
4072         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
4073         SGI C compiler in pre-C99 mode.
4074         Suggested by Mark D. Baushke and Larry Jones.
4075
4076 2006-06-26  Bruno Haible  <bruno@clisp.org>
4077
4078         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
4079         WCHAR_MAX.
4080         Reported by Mark D. Baushke and Larry Jones.
4081
4082 2006-06-26  Bruno Haible  <bruno@clisp.org>
4083
4084         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
4085         in pre-C99 mode.
4086         Suggested by Mark D. Baushke and Larry Jones.
4087
4088 2006-06-23  Simon Josefsson  <jas@extundo.com>
4089             Bruno Haible  <bruno@clisp.org>
4090
4091         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
4092         Emit mostlyclean-local rule.
4093         (func_emit_tests_Makefile_am): Likewise.
4094         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
4095
4096 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
4097
4098         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
4099
4100 2006-06-23  Bruno Haible  <bruno@clisp.org>
4101
4102         * tests/test-stdint.c: Update to match ISO C 99 Technical
4103         Corrigendum 1.
4104
4105 2006-06-23  Bruno Haible  <bruno@clisp.org>
4106
4107         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
4108
4109 2006-06-23  Bruno Haible  <bruno@clisp.org>
4110
4111         * lib/stdint_.h: Treat IRIX like OpenBSD.
4112
4113 2006-06-23  Bruno Haible  <bruno@clisp.org>
4114
4115         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
4116         ISO C 99 Technical Corrigendum 1.
4117
4118 2006-06-22  Simon Josefsson  <jas@extundo.com>
4119
4120         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
4121         MinGW.
4122
4123 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
4124
4125         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
4126         needed.  Some compiler complained about some of them.  Problem reported
4127         by Larry Jones in
4128         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
4129
4130 2006-06-21  Simon Josefsson  <jas@extundo.com>
4131
4132         * tests/test-getaddrinfo.c: New file.
4133
4134         * modules/getaddrinfo-tests: New file.
4135
4136         * MODULES.html.sh: Add inet_pton.
4137
4138         * modules/inet_pton: New file.
4139
4140 2006-06-21  Simon Josefsson  <jas@extundo.com>
4141
4142         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
4143         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
4144         of using the (limited) gnulib implementation on Windows XP.
4145
4146         * m4/inet_pton.m4: New file.
4147
4148 2006-06-21  Simon Josefsson  <jas@extundo.com>
4149
4150         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
4151         variable.
4152
4153         * lib/socket_.h: Don't define WINVER.
4154
4155         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
4156         slightly modified to work in gnulib.
4157
4158 2006-06-21  Simon Josefsson  <jas@extundo.com>
4159
4160         * doc/gnulib.texi (Windows sockets): Add.
4161
4162 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
4163
4164         * lib/read-file.c (fread_file): Start with buffer allocation of
4165         0 bytes rather than 1 byte; this simplifies the code.
4166         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
4167         code to free buffer and save/restore errno.
4168         (internal_read_file): Remove unused local.
4169
4170 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
4171
4172         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
4173         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
4174         Problem reported by Denis Excoffier in
4175         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
4176
4177 2006-06-19  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
4178
4179         * modules/sys_socket, modules/socklen: Include sys/types since
4180         FreeBSD 4.x's sys/socket.h needs it.
4181
4182 2006-06-19  Simon Josefsson  <jas@extundo.com>
4183
4184         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
4185
4186 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
4187
4188         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
4189
4190 2006-06-19  Bruno Haible  <bruno@clisp.org>
4191
4192         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
4193         and FULL_PATH_INTTYPES_H in angle brackets.
4194         Reported by Mark D. Baushke <mdb@gnu.org>.
4195
4196 2006-06-17  Eric Blake  <ebb9@byu.net>
4197
4198         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
4199         errno.
4200
4201 2006-06-17  Bruno Haible  <bruno@clisp.org>
4202
4203         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
4204         <sys/inttypes.h>.
4205
4206 2006-06-17  Bruno Haible  <bruno@clisp.org>
4207
4208         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
4209         whether errno is declared. Assume <errno.h> declares errno.
4210
4211 2006-06-17  Bruno Haible  <bruno@clisp.org>
4212
4213         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
4214
4215 2006-06-17  Bruno Haible  <bruno@clisp.org>
4216
4217         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
4218         problem on Solaris 2.5.1.
4219
4220 2006-06-16  Eric Blake  <ebb9@byu.net>
4221
4222         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
4223         * lib/unicodeio.c [!defined errno]: Likewise.
4224         * lib/strtol.c [!defined errno]: Likewise.
4225         * lib/strtod.c [!defined errno]: Likewise.
4226
4227 2006-06-15  Eric Blake  <ebb9@byu.net>
4228
4229         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
4230
4231 2006-06-15  Eric Blake  <ebb9@byu.net>
4232
4233         * config/srclist.txt (ssize_t.m4): Lose sync.
4234
4235 2006-06-15  Bruno Haible  <bruno@clisp.org>
4236
4237         * modules/stdint (Files): Include m4/full-header-path.m4,
4238         m4/size_max.m4, m4/wchar_t.m4.
4239         (Makefile.am): Many more substitutions.
4240         * modules/stdint-tests: New file.
4241         * tests/test-stdint.c: New file.
4242
4243 2006-06-15  Bruno Haible  <bruno@clisp.org>
4244
4245         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
4246         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
4247         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
4248         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
4249         gl_CHECK_TYPE_SAME): New macros.
4250
4251 2006-06-15  Bruno Haible  <bruno@clisp.org>
4252
4253         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
4254
4255 2006-06-15  Bruno Haible  <bruno@clisp.org>
4256
4257         * lib/stdint_.h: Rewritten to be fully auto-configured.
4258         Fixes bug on HP-UX/IA64.
4259
4260 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
4261
4262         * lib/getdate.y (__attribute__): Don't define if already defined.
4263         Problem reported by Larry Jones.
4264         * lib/utimens.c (__attribute__): Likewise.
4265
4266 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
4267
4268         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
4269         reported by Andreas Schwab.
4270
4271 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4272             Bruno Haible  <bruno@clisp.org>
4273
4274         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
4275         check for the declaration of strnlen and a run test that exposes the
4276         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
4277         rpl_strndup.
4278
4279 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4280             Bruno Haible  <bruno@clisp.org>
4281
4282         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
4283
4284 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4285
4286         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
4287         compile test, for Tru64 4.0D.
4288
4289 2006-05-28  Karl Berry  <karl@gnu.org>
4290
4291         * config/srclist.txt (printf-args.c): lose sync.
4292
4293 2006-05-26  Martin Lambers  <marlam@marlam.de>
4294
4295         * lib/getpass.c: Updates the test for the native W32 API, and adds
4296         missing includes, thus fixing compilation warnings.
4297
4298 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
4299
4300         * lib/exclude.c (exclude_fnmatch): New function.
4301         (excluded_file_name): Call exclude_fnmatch.
4302         * lib/exclude.h (excluded_file_name): New prototype
4303
4304 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
4305
4306         * lib/tempname.c (small_open, large_open): New macros.
4307         (__open, __open64) [!_LIBC]: Remove.
4308         (__gen_tempname): Use small_open and large_open instead of __open
4309         and __open64.  This fixes a portability bug on HP-UX 11.11i
4310         reported by Simon Wing-Tang in
4311         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
4312
4313 2006-05-24  Bruno Haible  <bruno@clisp.org>
4314
4315         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
4316         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
4317         Reported by Thorsten Maerz <torte@netztorte.de> via
4318         Aaron Stone <aaron@serendipity.cx>.
4319
4320 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
4321
4322         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
4323         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
4324         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
4325         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
4326         not really conditional on the cache.
4327         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
4328
4329 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
4330
4331         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
4332         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
4333         (my_usleep): Don't mishandle maximum value.
4334
4335 2006-05-19  Jim Meyering  <jim@meyering.net>
4336
4337         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
4338
4339 2006-05-17  Bruno Haible  <bruno@clisp.org>
4340
4341         Cygwin portability.
4342         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
4343
4344 2006-05-17  Bruno Haible  <bruno@clisp.org>
4345
4346         * lib/stdint_.h: Fix recognition of Cygwin.
4347
4348 2006-05-15  Bruno Haible  <bruno@clisp.org>
4349
4350         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
4351         on libtool patch by Ralf Wildenhues.
4352
4353 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
4354
4355         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
4356         test for C99 conformance; (bool) 0.5 is an integer constant
4357         expression, but (bool) -0.5 is not.  Problem reported by Fedor
4358         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
4359
4360 2006-05-11  Simon Josefsson  <jas@extundo.com>
4361
4362         * m4/xvasprintf.m4: Fix obvious typo.
4363
4364 2006-05-11  Jim Meyering  <jim@meyering.net>
4365
4366         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
4367         James Lemley.
4368
4369 2006-05-10  Simon Josefsson  <jas@extundo.com>
4370
4371         * lib/md4.c: Typo fix, update copyright years.
4372         (K1, K2): Don't use L because it turn computations into 64-bit on
4373         64-bit platforms.
4374
4375 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
4376
4377         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
4378         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
4379         unwanted sign propagation, e.g., on hosts with 64-bit int.
4380         There still are some problems with reeelly weird theoretical hosts
4381         (e.g., 33-bit int) but it's not worth worrying about now.
4382         * lib/sha1.c (rol): Likewise.
4383         (K1, K2, K3, K4): Remove unnecessary L suffix.
4384
4385 2006-05-10  Bruno Haible  <bruno@clisp.org>
4386
4387         * lib/des.c: Cast to avoid warnings.
4388
4389 2006-05-09  Bruno Haible  <bruno@clisp.org>
4390
4391         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
4392         (Depends-on): Depend also on xsize, stdarg.
4393         (configure.ac): Add gl_XVASPRINTF.
4394
4395 2006-05-09  Bruno Haible  <bruno@clisp.org>
4396
4397         * m4/xvasprintf.m4: New file.
4398
4399 2006-05-09  Bruno Haible  <bruno@clisp.org>
4400
4401         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
4402         (EOVERFLOW): Define fallback value.
4403         (xstrcat): New function.
4404         (xvasprintf): Recognize the special case of a string concatenation.
4405
4406 2006-05-08  Eric Blake  <ebb9@byu.net>
4407
4408         * gnulib-tool (func_version): Base copyright year on CVS date.
4409         (func_emit_copyright_notice): New function.
4410         (func_emit_lib_Makefile_am): Use it.
4411         (func_emit_tests_Makefile_am): Likewise.
4412         (func_import): Likewise.
4413
4414 2006-05-08  Bruno Haible  <bruno@clisp.org>
4415
4416         * modules/stdarg: New file.
4417         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
4418
4419 2006-05-08  Bruno Haible  <bruno@clisp.org>
4420
4421         * m4/stdarg.m4: New file, from GNU gettext.
4422
4423 2006-05-08  Bruno Haible  <bruno@clisp.org>
4424
4425         * config/srclist.txt (build-aux/config.rpath): different from latest
4426         release.
4427
4428 2006-05-08  Bruno Haible  <bruno@clisp.org>
4429
4430         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
4431
4432 2006-05-05  Jim Meyering  <jim@meyering.net>
4433
4434         * m4/warning.m4: New file, derived from bison's file by the same name.
4435
4436 2006-05-03  Bruno Haible  <bruno@clisp.org>
4437
4438         * lib/stdint_.h: Shorter URL.
4439         * lib/inttypes.h: Likewise.
4440
4441 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
4442
4443         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
4444
4445 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
4446
4447         * lib/verify.h: Document the internals better.  Most of this change
4448         was written by Bruno Haible.
4449
4450 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
4451
4452         * doc/verify.texi: New file, partly based on a proposal by
4453         Bruno Haible.
4454
4455 2006-05-02  Bruno Haible  <bruno@clisp.org>
4456
4457         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
4458         test from here...
4459         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
4460
4461 2006-04-29  Bruno Haible  <bruno@clisp.org>
4462
4463         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
4464         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
4465
4466 2006-04-29  Bruno Haible  <bruno@clisp.org>
4467
4468         * gnulib-tool: Make --update option actually work.
4469
4470 2006-04-29  Bruno Haible  <bruno@clisp.org>
4471
4472         * doc/gcd.texi: New file.
4473         * doc/gnulib.texi: Include it.
4474
4475 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
4476
4477         * lib/getdate.y (get_date): When adding relative date, start with the
4478         initial time, not with the result of the first mktime call.
4479
4480 2006-04-25  Bruno Haible  <bruno@clisp.org>
4481
4482         * gnulib-tool (func_import): Output the include directives in three
4483         blocks, sorted separately.
4484         Reported by Ben Pfaff <blp@cs.stanford.edu>.
4485
4486 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
4487
4488         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
4489         to define main with arguments, for C++.  Reported by Eric Blake.
4490         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
4491         Prefer 'int main ()' to 'int main (void)', for C++.
4492         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
4493         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
4494         for 'main', for C99 and C++.
4495
4496 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
4497
4498         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
4499         Don't assume that exit status -1 is valid.
4500         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
4501         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
4502         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
4503         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
4504         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
4505         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
4506         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
4507         functions can be used without declaring them, or that you can
4508         exit with status -1.
4509         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
4510
4511 2006-04-24  Karl Berry  <karl@gnu.org>
4512
4513         * config/srclist.txt (longdouble.m4): sync lost.
4514
4515 2006-04-24  Eric Blake  <ebb9@byu.net>
4516
4517         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
4518
4519 2006-04-24  Bruno Haible  <bruno@clisp.org>
4520
4521         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
4522         poll() implementation in AIX.
4523         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4524
4525 2006-04-24  Bruno Haible  <bruno@clisp.org>
4526
4527         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
4528         assigned exactly once.
4529
4530 2006-04-23  Claudio Fontana  <claudio@gnu.org>
4531             Bruno Haible  <bruno@clisp.org>
4532
4533         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
4534         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
4535         for AM_CPPFLAGS.
4536
4537 2006-04-23  Bruno Haible  <bruno@clisp.org>
4538
4539         * modules/copy-file: Depend on unistd.
4540         * modules/execute: Likewise.
4541         * modules/fatal-signal: Likewise.
4542         * modules/findprog: Likewise.
4543         * modules/mkdtemp : Likewise.
4544         * modules/pipe: Likewise.
4545         * modules/wait-process: Likewise.
4546
4547 2006-04-23  Bruno Haible  <bruno@clisp.org>
4548
4549         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
4550         condition was already detected.
4551         Reported by Ben Pfaff <blp@cs.stanford.edu>.
4552
4553 2006-04-23  Bruno Haible  <bruno@clisp.org>
4554
4555         * lib/copy-file.c: Include <unistd.h> unconditionally.
4556         * lib/execute.c: Likewise.
4557         * lib/fatal-signal.c: Likewise.
4558         * lib/findprog.c: Likewise.
4559         * lib/mkdtemp.c: Likewise.
4560         * lib/pipe.h: Likewise.
4561         * lib/pipe.c: Likewise.
4562         * lib/wait-process.h: Likewise.
4563
4564 2006-04-23  Bruno Haible  <bruno@clisp.org>
4565
4566         * gnulib-tool (func_usage): Fix --import description. Document
4567         --update.
4568         (func_import): Create temporary file in a temporary directory, if
4569         --dry-run is specified. Silence errors from 'grep' when there are no
4570         m4 files in $m4dir.
4571         (func_create_testdir): Silence errors from 'grep' when there are no
4572         m4 files in $m4dir.
4573         Reported by Karl Berry <karl@freefriends.org>.
4574
4575 2006-04-20  Bruno Haible  <bruno@clisp.org>
4576
4577         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
4578         one argument, so that the code will be portable to Autoconf 2.60.
4579         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
4580         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
4581         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
4582
4583 2006-04-19  Derek Price  <derek@ximbiot.com>
4584             Eric Blake  <ebb9@byu.net>
4585
4586         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
4587         rather than "/full/path.h".  Update comment to match.  Shorten &
4588         generalize m4_translit call via AS_TR_CPP.
4589
4590 2006-04-19  Derek Price  <derek@ximbiot.com>
4591             Eric Blake  <ebb9@byu.net>
4592
4593         * lib/inttypes.h: Correct grammar in comment.
4594
4595 2006-04-18  Derek Price  <derek@ximbiot.com>
4596             Paul Eggert  <eggert@cs.ucla.edu>
4597
4598         * modules/inttypes: New file.
4599         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
4600
4601 2006-04-18  Derek Price  <derek@ximbiot.com>
4602             Paul Eggert  <eggert@cs.ucla.edu>
4603
4604         * m4/_inttypes_h.m4, full-header-path.m4, include_next: New files.
4605
4606 2006-04-18  Derek Price  <derek@ximbiot.com>
4607             Paul Eggert  <eggert@cs.ucla.edu>
4608
4609         * lib/inttypes.h: New file.
4610         * lib/strtoimax.c: Assume <inttypes.h>.
4611
4612 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
4613
4614         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
4615         isn't mounted.  Problem reported by Kir Kolyshkin.
4616
4617 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
4618
4619         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
4620         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
4621         Derek R. Price.
4622         * lib/regex.h (RE_DUP_MAX): Update comment to match current
4623         implementation.
4624
4625 2006-04-12  Eric Blake  <ebb9@byu.net>
4626
4627         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
4628         is now done automatically by the corresponding Autoconf macro.
4629
4630 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
4631
4632         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
4633         time_r.h.
4634
4635 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
4636
4637         Merge regex changes from libc, removing some of our
4638         POSIX-conformance changes that were rejected and redoing them in a
4639         less-intrusive way.
4640
4641         * lib/regcomp.c (re_compile_internal, init_dfa):
4642         Length arg is now size_t, not Idx.  All uses changed.
4643         (peek_token): Forward decl now says internal_function.
4644         (__re_error_msgid, __re_error_msgid_idx):
4645         Now static rather than extern with attribute_hidden.
4646         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
4647         For some reason libc prefers K&R style defns for external functions.
4648         (regerror) [!defined _LIBC]: Likewise.
4649         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
4650         (seek_collating_symbol_entry, lookup_collation_sequence_value):
4651         (build_range_exp, build_collating_symbol):
4652         Use K&R-style defn.
4653         (re_compile_fastmap): Use '\0' to memset, not 0.
4654         (utf8_sb_map): Make the calculations more obvious.
4655         (init_dfa, parse_bracket_exp, build_charclass_op):
4656         Call calloc and cast result, as glibc does.
4657         (init_word_char, fetch_token, peek_token, peek_token_bracket):
4658         (build_range_exp, build_collating_symbol):
4659         Now internal functions.
4660
4661         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
4662
4663         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
4664         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
4665         Don't depend on VMS; depend on __VMS instead, for POSIX
4666         namespace cleanness.
4667         (regoff_t): Define to ssize_t, not long int.
4668
4669         Remove the REG_ macros named below.  Instead, make the old names
4670         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
4671         __USE_GNU_REGEX.
4672         (REG_BACKSLASH_ESCAPE_IN_LISTS):
4673         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
4674         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
4675         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
4676         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
4677         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
4678         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
4679         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
4680         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
4681         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
4682         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
4683         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
4684         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
4685         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
4686         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
4687         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
4688         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
4689         (REG_NREGS):
4690         Remove.  All uses replaced by the old RE_* names.
4691         (RE_BACKSLASH_ESCAPE_IN_LISTS):
4692         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
4693         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
4694         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
4695         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
4696         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
4697         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
4698         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
4699         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
4700         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
4701         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
4702         Don't bother having these macros be independent of each others'
4703         values, since they no longer exist in the POSIX name space.
4704
4705         Rename the following member names back to their old names,
4706         unless !__USE_GNU_REGEX.  All uses changed back.
4707         (buffer): Renamed from re_buffer.
4708         (allocated): Renamed from re_allocated.
4709         (used): Renamed from re_used.
4710         (syntax): Renamed from re_syntax.
4711         (fastmap): Renamed from re_fastmap.
4712         (translate): Renamed from re_translate.
4713         (can_be_null): Renamed from re_can_be_null.
4714         (regs_allocated): Renamed from re_regs_allocated.
4715         (fastmap_accurate): Renamed from re_fastmap_accurate.
4716         (no_sub): Renamed from re_no_sub.
4717         (not_bol): Renamed from re_not_bol.
4718         (not_eol): Renamed from re_not_eol.
4719         (newline_anchor): Renamed from re_newline_anchor.
4720         (num_regs): Renamed from rm_num_regs.
4721         (start): Renamed from rm_start.
4722         (end): Renamed from rm_end.
4723
4724         (free_state): Move up a bit.
4725
4726         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
4727         #define to be empty.
4728         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
4729         when that is what is intended.
4730         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
4731         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
4732         (MAX): New macro.
4733         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
4734         All uses changed back to re_malloc, etc.  It's now the caller's
4735         responsibility to check for overflow; all callers changed.
4736         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
4737         (re_x2nrealloc): Remove.
4738         (free_state): Remove decl.
4739
4740         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
4741         (re_set_registers, re_exec):
4742         Use K&R-style defn.
4743
4744         2006-01-31  Roland McGrath  <roland@redhat.com>
4745
4746         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
4747         Reported by Mike Frysinger <vapier@gentoo.org>.
4748
4749         2006-01-15  Andreas Jaeger  <aj@suse.de>
4750
4751         [BZ #1950]
4752         * lib/regex_internal.c (re_string_reconstruct): Adjust for
4753         build_wcs_upper_buffer change.
4754         (build_wcs_upper_buffer): Change return type.
4755
4756         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
4757
4758         * lib/regex_internal.h: Include <stdint.h> if available.
4759
4760         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
4761
4762         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
4763
4764         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
4765
4766         * lib/regcomp.c: Adjust for changed secondary hash function.
4767
4768         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
4769
4770         * lib/regex.h: Pretty printing.
4771         Clean up namespace a bit.
4772
4773         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
4774
4775         * lib/regexec.c (update_cur_sifted_state, check_arrival,
4776         check_arrival_add_next_nodes): Avoid using uninitialized variable.
4777
4778         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
4779                     Ulrich Drepper  <drepper@redhat.com>
4780
4781         [BZ #1302]
4782         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
4783         changed.
4784         (bitset_word_t): Renamed from bitset_word.  All uses changed.
4785
4786         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
4787
4788         [BZ #281]
4789         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
4790         * lib/regcomp.c: Remove unnecessary uses of
4791         unsigned RE_TRANSLATE_TYPE.
4792         * lib/regex_internal.h: Likewise.
4793         * lib/regex_internal.c: Likewise.
4794         * lib/regexec.c: Likewise.
4795         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
4796
4797         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
4798
4799         * lib/regexec.c (find_recover_state): Remove unnecessary
4800         initialization.
4801         (transit_state_bkref): Make DFA a const pointer.
4802         (get_subexp): Likewise.
4803         (check_arrival): Likewise.
4804         (update_cur_sifted_state): Likewise.
4805         (re_search_internal): Likewise.
4806         (prune_impossible_nodes): Likewise.
4807         (acquire_init_state_context): Likewise.
4808         (proceed_next_node): Likewise.
4809         (set_regs): Likewise.
4810         (free_fail_stack_return): Likewise.
4811         (check_arrival_expand_ecl): Mark DFA parameter as const.
4812         (check_arrival_expand_ecl_sub): Likewise.
4813         (check_subexp_limits): Likewise.
4814         (sub_epsilon_src_nodes):  Likewise.
4815         (add_epsilon_src_nodes):  Likewise.
4816         (merge_state_array): Likewise.
4817         (update_regs): Likewise.
4818         (build_trtable): Likewise.
4819         (sift_states_backward): Mark MCTX parameter as const.
4820         (build_sifted_states): Likewise.
4821         (update_cur_sifted_state): Likewise.
4822         (sift_states_mkref): Likewise.
4823         (check_arrival_expand_ecl): Mark eclosure as const.
4824         (check_dst_limits_calc_pos_1): Likewise.
4825         * lib/regex_internal.h (re_match_context_t): Make dfa a const
4826         pointer.
4827
4828         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
4829
4830         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
4831         (transit_state_sb): Likewise.
4832         (transit_state_mb): Likewise.
4833         (sift_states_iter_mb): Likewise.
4834         (check_arrival_add_next_nodes): Likewise.
4835         (check_node_accept_bytes): Change first parameter to pointer-to-const.
4836         [_LIBC] (re_search_2_stub): Use mempcpy.
4837
4838         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
4839         mbrtowc for very simple UTF-8 case.
4840
4841         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
4842         a pointer-to-const.
4843         (re_acquire_state_context): Likewise.
4844         * lib/regex_internal.h: Adjust prototypes.
4845
4846         * lib/regex.c: Prevent using C++ compilers.
4847
4848         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
4849         (re_acquire_state_context): Likewise.
4850
4851 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
4852
4853         * modules/regex (Depends-on): Add ssize_t.
4854
4855 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
4856
4857         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
4858         translation table.
4859
4860 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
4861
4862         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
4863
4864 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
4865             Bruno Haible  <bruno@clisp.org>
4866
4867         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
4868         <sys/types.h> and <inttypes.h>.
4869
4870 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4871
4872         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
4873         `__error_t_defined', so argp.h will not typedef the former.
4874
4875 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
4876
4877         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
4878         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
4879         glibc names.  Even if glibc is changed to conform to POSIX, the
4880         traditional names will be available anyway, since regex depends on
4881         the extensions module.  Also, fix a longstanding typo in the
4882         implementation of Spencer ERE test #75 from grep 2.3.  Problems
4883         reported by Emanuele Giaquinta.  Also, change sense of cached
4884         variable, so that the message makes sense.
4885
4886 2006-03-24  Simon Josefsson  <jas@extundo.com>
4887
4888         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
4889         including some doc fixes.
4890         (base64_encode_alloc): Fix +1 bug on allocation failures.
4891
4892 2006-03-24  Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4893
4894         * lib/base64.c (base64_encode): Do not read past end of array with
4895         unsanitized input on systems with CHAR_BIT > 8.
4896
4897 2006-03-24  Eric Blake  <ebb9@byu.net>
4898
4899         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
4900
4901 2006-03-22  Karl Berry  <karl@gnu.org>
4902
4903         * config/srclist.txt (*setenv.[ch]): get from coreutils.
4904         * config/srclistvars.sh (COREUTILS): new var.
4905
4906 2006-03-17  Jim Meyering  <jim@meyering.net>
4907
4908         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
4909         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
4910
4911 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
4912
4913         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
4914         no longer needs it.  Instead, check that regoff_t is as least
4915         as wide as ptrdiff_t.
4916
4917         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
4918         so that our regex.h stays compatible with the installed regex.
4919         This is helpful for installers who configure --without-included-regex.
4920         Problem reported by Emanuele Giaquinta.
4921
4922 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
4923
4924         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
4925         Typedef to long int, not to off_, as POSIX will likely change
4926         in that direction.
4927
4928 2006-03-15  Eric Blake  <ebb9@byu.net>
4929
4930         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
4931
4932 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
4933
4934         * lib/argp-help.c (validate_uparams): Fix typo
4935         * lib/argp-parse.c (argp_default_options): Consistently begin help
4936         messages with a lowercase letter.
4937
4938 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
4939
4940         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
4941         overrun buffers and shouldn't be used (much as gets shouldn't be
4942         used).
4943         * lib/time_r.c (asctime_r, ctime_r): Likewise.
4944
4945 2006-03-08  Simon Josefsson  <jas@extundo.com>
4946
4947         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
4948         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4949
4950 2006-03-08  Simon Josefsson  <jas@extundo.com>
4951
4952         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
4953         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4954
4955 2006-03-08  Simon Josefsson  <jas@extundo.com>
4956
4957         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
4958         signal that configure disabled the device.
4959
4960 2006-03-08  Simon Josefsson  <jas@extundo.com>
4961
4962         * build-aux/maint.mk: Fix refresh-po, to handle no translated
4963         languages.
4964
4965 2006-03-07  Simon Josefsson  <jas@extundo.com>
4966
4967         * modules/getopt (Depends-on): Add unistd.
4968
4969         * modules/unistd: New file.
4970
4971 2006-03-07  Simon Josefsson  <jas@extundo.com>
4972
4973         * modules/gc-random: New file.
4974
4975 2006-03-07  Simon Josefsson  <jas@extundo.com>
4976
4977         * m4/unistd_h.m4: New file.
4978
4979 2006-03-07  Simon Josefsson  <jas@extundo.com>
4980
4981         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
4982         test to be side-effect free by storing the result in the cache
4983         variable gl_cv_lib_readline, and moving the assignment of
4984         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
4985         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4986
4987 2006-03-07  Simon Josefsson  <jas@extundo.com>
4988
4989         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
4990         error on missing devices (the functions will return an error).
4991
4992         * m4/gc.m4: Move random stuff to gc-random.m4
4993
4994 2006-03-07  Simon Josefsson  <jas@extundo.com>
4995
4996         * lib/unistd_.h: New file.
4997
4998 2006-03-07  Simon Josefsson  <jas@extundo.com>
4999
5000         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
5001
5002 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
5003
5004         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
5005         Problem reported by Juan Manuel Guerrero.
5006
5007 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
5008
5009         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
5010         the unistd module.
5011         * lib/getlogin_r.c: Likewise.
5012         * lib/getlogin_r.h: Likewise.
5013         * lib/glob.c: Likewise.
5014         * lib/pagealign_alloc.c: Likewise.
5015         * lib/unistd_.h: Remove; no longer needed.
5016
5017 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
5018
5019         * MODULES.html.sh (Support for systems lacking POSIX:2001):
5020         Add unistd.
5021         * modules/c-stack (Depends-on): Add unistd.
5022         * modules/getlogin_r: Likewise.
5023         * modules/glob: Likewise.
5024         * modules/pagealign_alloc: Likewise.
5025         * modules/unistd (Files): Remove lib/unistd_.h.
5026         (EXTRA_DIST): Remove.
5027         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
5028         need unistd_.h.
5029         (MOSTLYCLEANFILES): Remove unistd.h-t.
5030
5031 2006-03-03  Simon Josefsson  <jas@extundo.com>
5032
5033         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
5034
5035 2006-03-03  Simon Josefsson  <jas@extundo.com>
5036
5037         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
5038         libidn and bison.
5039
5040 2006-03-03  Simon Josefsson  <jas@extundo.com>
5041
5042         * build-aux/maint.mk: Add indent target.
5043
5044 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5045
5046         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
5047         our replacement poll.h in any case, to avoid a differing
5048         declaration from a system header.  Seen on AIX.
5049
5050 2006-03-01  Simon Josefsson  <jas@extundo.com>
5051
5052         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
5053         <kasal@ucw.cz>.
5054
5055 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5056
5057         * modules/gettime (Depends-on): Add extensions module.
5058         * modules/nanosleep (Depends-on): Likewise.
5059         * modules/settime (Depends-on): Likewise.
5060
5061 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5062
5063         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
5064         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
5065         pedantically.
5066         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
5067         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
5068
5069         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
5070         not "==".  Reported by Ralf Wildenhues.
5071
5072 2006-03-01  Karl Berry  <karl@gnu.org>
5073
5074         * doc/Copyright/request-*: new files, synced from gnuorg.
5075
5076 2006-03-01  Karl Berry  <karl@gnu.org>
5077
5078         * config/srclist.txt (Copyright/*): new entries.
5079
5080 2006-02-28  Simon Josefsson  <jas@extundo.com>
5081
5082         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
5083
5084 2006-02-27  Simon Josefsson  <jas@extundo.com>
5085
5086         * lib/base64.h: Indent #define's.  From Jim Meyering
5087         <jim@meyering.net>.
5088
5089 2006-02-27  Jim Meyering  <jim@meyering.net>
5090
5091         Revert the change of 2006-02-24, so these files can continue
5092         to be sync'd from gettext.
5093         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
5094         of `config.h'.
5095
5096 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
5097
5098         * modules/intprops: New file.
5099         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
5100         Add intprops.
5101         * modules/getloadavg (Files): Remove lib/intprops.h.
5102         (Depends-on): Add intprops.
5103         * modules/human: Likewise.
5104         * modules/inttostr: Likewise.
5105         * modules/openat: Likewise.
5106         * modules/sig2str: Likewise.
5107         * modules/userspec: Likewise.
5108         * modules/utimecmp: Likewise.
5109         * modules/xnanosleep: Likewise.
5110         * modules/xstrtol: Likewise.
5111
5112 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5113
5114         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
5115         * modules/lock-tests (TESTS): Use $(EXEEXT).
5116         * modules/tls-tests: Likewise.
5117         * modules/argp-tests: Likewise.
5118         (check_PROGRAMS): New var, replacing...
5119         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
5120
5121 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5122
5123         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
5124         `config.h'.
5125
5126 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
5127
5128         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
5129
5130 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5131
5132         Sync from coreutils.
5133         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
5134         gl_CHDIR_SAFER.
5135
5136 2006-02-22  Jim Meyering  <jim@meyering.net>
5137
5138         Sync from coreutils.
5139         * m4/chdir-safer.m4: New file.
5140
5141 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
5142
5143         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
5144         AT_FDCWD exceeds INT_MAX.
5145         * lib/openat.h (AT_FDCWD): Likewise.
5146
5147 2006-02-17  Eric Blake  <address@hidden>
5148
5149         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
5150
5151 2006-02-16  Simon Josefsson  <jas@extundo.com>
5152
5153         * modules/getaddrinfo (Depends-on): Add sys_socket.
5154
5155 2006-02-15  Simon Josefsson  <jas@extundo.com>
5156
5157         * build-aux/maint.mk: Add dsyntax-check rule.
5158
5159 2006-02-15  Eric Blake  <ebb9@byu.net>
5160
5161         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
5162         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
5163         'present but cannot compile' warnings on cygwin.
5164         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
5165         use ws2tcpip.h if sys/socket.h works.
5166         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
5167         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
5168
5169 2006-02-14  Simon Josefsson  <jas@extundo.com>
5170
5171         * modules/maintainer-makefile (Files): Rename.
5172
5173         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
5174         and (the local) Makefile.cfg to maint-cfg.mk.
5175
5176         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
5177         to the latter.
5178
5179         * modules/maintainer-makefile: New module.
5180
5181         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
5182         severaly stripped to make it possible to build it up from scratch
5183         with reliable tests.
5184
5185         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
5186         fixes to permit overriding the default actions when configure and
5187         makefile are not available.
5188
5189 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
5190
5191         Sync from coreutils.
5192         * modules/lstat (Depends-on): Don't depend on xalloc.
5193         (License): Change from GPL to LGPL, since this is now simply a
5194         replacement for a libc function.
5195
5196 2006-02-14  Jim Meyering  <jim@meyering.net>
5197
5198         Sync from coreutils.
5199
5200         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
5201         failure on deficient systems, and simplify gnulib lgpl dependencies.
5202         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
5203         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
5204
5205         * lib/xalloc-die.c: Remove unused definition of N_.
5206
5207 2006-02-14  Jim Meyering  <jim@meyering.net>
5208
5209         Sync from coreutils.
5210         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
5211         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
5212         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
5213         double-quote uses of that variable, to accommodate the rare case in
5214         which getmntent is available in none of the libraries checked.  This
5215         happens at least on FreeBSD 5.0.
5216
5217 2006-02-13  Simon Josefsson  <jas@extundo.com>
5218
5219         * gnulib-tool (Usage): Fix --import, from
5220         karl@freefriends.org (Karl Berry).
5221
5222 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
5223
5224         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
5225
5226 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
5227
5228         * lib/argp-namefrob.h: Restore changes accidentally lost during the
5229         "autoupdate" on 2005-12-12.
5230
5231 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
5232
5233         * modules/closeout (Depends-on): Remove atexit.
5234
5235 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
5236
5237         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
5238         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
5239
5240 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
5241
5242         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
5243         __EXTENSIONS__ if this causes compilation to fail.  Problem
5244         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
5245         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
5246
5247 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
5248
5249         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
5250         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
5251         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
5252         All uses changed.
5253
5254 2006-01-26  Simon Josefsson  <jas@extundo.com>
5255
5256         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
5257         prototype is visible on mingw32.
5258
5259         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
5260         for mingw32.
5261
5262         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
5263         mingw32).
5264
5265 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
5266
5267         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
5268         attempt to open for write; this always fails, at least on POSIX
5269         hosts.  This reinstates the 2006-01-09 change, which was
5270         inadvertently removed.
5271
5272 2006-01-26  Bruno Haible  <bruno@clisp.org>
5273
5274         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
5275         Reported by Paul Eggert.
5276
5277 2006-01-26  Bruno Haible  <bruno@clisp.org>
5278             Paul Eggert  <eggert@cs.ucla.edu>
5279
5280         * lib/stdbool_.h (_Bool)
5281         [(! (defined __cplusplus || defined __BEOS__)
5282           && !defined __GNUC__
5283           && !(defined __HP_cc || defined __xlc__
5284                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
5285                || defined __sgi))]:
5286         #define to signed char in these cases too; this simplifies
5287         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
5288         etc., separately) and makes it more conservative.
5289
5290 2006-01-25  Simon Josefsson  <jas@extundo.com>
5291
5292         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
5293         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
5294         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
5295
5296 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
5297
5298         * lib/argp-namefrob.h: Bugfix. Remove stray #
5299
5300 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
5301
5302         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
5303         so that we test the test.
5304         Check for yet another HP-UX cc bug involving *bool |= bool.
5305
5306 2006-01-25  Karl Berry  <karl@gnu.org>
5307
5308         * config/srclist.txt (vasnprintf.c): sync lost.
5309
5310 2006-01-25  Jim Meyering  <jim@meyering.net>
5311
5312         Sync from the stable (b5) branch of coreutils:
5313
5314         * lib/fts.c (fts_children): Don't let close() clobber errno from
5315         failed fchdir().
5316
5317         * lib/fts.c (fts_stat): When following a symlink-to-directory,
5318         don't necessarily interpret stat-fails+lstat-succeeds as indicating
5319         a dangling symlink.  That can also happen at least for ELOOP.
5320         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
5321         FYI, this bug predates the inclusion of fts.c in coreutils.
5322
5323         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
5324         in their own block, so pre-c99 compilers don't object.
5325
5326         Avoid the double-free (first in fts_read, second in fts_close) that
5327         would occur when an `active' directory is made inaccessible (e.g.,
5328         via chmod a-x) during a traversal.
5329         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
5330         before returning.  Reproduce this failure by
5331         mkdir -p a/b; cd a; chmod a-x . b
5332         Reported by Stavros Passas.
5333
5334 2006-01-25  Jim Meyering  <jim@meyering.net>
5335
5336         * lib/fileblocks.c: Remove more useless parentheses.
5337         * lib/readutmp.h: Likewise.
5338
5339 2006-01-25  Bruno Haible  <bruno@clisp.org>
5340
5341         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
5342         warnings.
5343         Reported by Paul Eggert.
5344
5345 2006-01-25  Bruno Haible  <bruno@clisp.org>
5346
5347         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
5348         rid of a trap command. For Solaris sh.
5349         Reported by Mark D. Baushke <mdb@gnu.org>.
5350
5351 2006-01-24  Simon Josefsson  <jas@extundo.com>
5352
5353         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
5354         Bruno.
5355
5356 2006-01-24  Karl Berry  <karl@gnu.org>
5357
5358         * config/srclist.txt (argp-namefrob.h): sync lost.
5359
5360 2006-01-24  Jim Meyering  <jim@meyering.net>
5361
5362         * modules/openat (Files): Add lib/intprops.h.
5363         From Mark D. Baushke.
5364
5365 2006-01-24  Jim Meyering  <jim@meyering.net>
5366
5367         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
5368         Reported by Mark D. Baushke.
5369
5370 2006-01-24  Jim Meyering  <jim@meyering.net>
5371
5372         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
5373
5374 2006-01-24  Bruno Haible  <bruno@clisp.org>
5375
5376         * modules/strnlen (Maintainer): Change from glibc to all.
5377
5378 2006-01-24  Bruno Haible  <bruno@clisp.org>
5379
5380         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
5381         Patch by Paul Eggert.
5382
5383 2006-01-24  Bruno Haible  <bruno@clisp.org>
5384
5385         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
5386         already has it.
5387         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
5388         2005-11-26.
5389
5390         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
5391         'signed char' to avoid problems with the built-in _Bool type.
5392         Reported by Paul Eggert on 2005-11-26.
5393
5394 2006-01-24  Bruno Haible  <bruno@clisp.org>
5395
5396         * gnulib-tool (func_import): Avoid constructing complicated sed
5397         expressions inside backquote.
5398         Report and solution by Mark D. Baushke <mdb@gnu.org>.
5399
5400 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
5401
5402         These changes imported from libc.
5403         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
5404         test and two separate function calls.
5405         * lib/strndup.c (__strndup): Add libc_hidden_def.
5406
5407 2006-01-23  Simon Josefsson  <jas@extundo.com>
5408
5409         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
5410         Remove the test_*_SOURCES variable: automake infers it by default.
5411         * modules/tls-tests: Likewise.
5412
5413 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
5414
5415         Work around porting bugs reported by Dieter in
5416         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
5417         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
5418         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
5419         Include "getopt.h" first, to check interface.
5420         (getenv): Declare only if defined HAVE_DECL_GETENV &&
5421         !HAVE_DECL_GETENV.
5422         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
5423         (__strndup): Revert to K&R-style function dfns, the glibc style.
5424         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
5425         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
5426         Include strnlen.h first, to get prototype properly.
5427         (strnlen): Renamed from __strnlen.
5428         Remove weak alias.
5429
5430 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
5431
5432         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
5433
5434 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
5435
5436         * config/srclist.txt: Adjust to reflect glibc reorganization.
5437         This affects only comments.
5438
5439 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5440
5441          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
5442          Reported by Bruce Korb <bkorb@gnu.org>.
5443
5444 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
5445
5446         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
5447         to pacify gcc -Wswitch-default.
5448
5449 2006-01-22  Bruno Haible  <bruno@clisp.org>
5450
5451         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
5452         temporary buffer for sprintf, take into account the precision also
5453         for 'd', 'i', 'u', 'o', 'x', 'X'.
5454
5455 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
5456
5457         * modules/argp-tests: New module
5458         * tests/test-argp.c: New file
5459         * tests/test-argp-2.sh: New file
5460
5461 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
5462
5463         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
5464         (__argp_base_name): Removed
5465         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
5466         typo.
5467         (__argp_base_name): Provide macro definition or extern declaration
5468         depending on the configuration
5469
5470 2006-01-20  Simon Josefsson  <jas@extundo.com>
5471
5472         * modules/inet_ntop (Depends-on): Depend on sys_socket.
5473
5474 2006-01-20  Simon Josefsson  <jas@extundo.com>
5475
5476         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
5477
5478 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
5479
5480         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
5481         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
5482         Suggested by Bruno Haible.
5483
5484 2006-01-20  Karl Berry  <karl@gnu.org>
5485
5486         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
5487         until changes propagate, I guess.
5488
5489 2006-01-19  Simon Josefsson  <jas@extundo.com>
5490
5491         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
5492
5493 2006-01-19  Simon Josefsson  <jas@extundo.com>
5494
5495         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
5496
5497 2006-01-19  Simon Josefsson  <jas@extundo.com>
5498
5499         * gnulib-tool: Set check_PROGRAMS.
5500
5501         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
5502         modules/des-tests, modules/gc-arcfour-tests,
5503         modules/gc-arctwo-tests, modules/gc-des-tests,
5504         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
5505         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
5506         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
5507         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
5508         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
5509         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
5510         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
5511         test_*_SOURCES.
5512
5513 2006-01-18  Simon Josefsson  <jas@extundo.com>
5514
5515         * modules/socklen (Depends-on): Depend on sys_socket.
5516
5517 2006-01-18  Simon Josefsson  <jas@extundo.com>
5518
5519         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
5520         modules/des-tests, modules/gc-arcfour-tests,
5521         modules/gc-arctwo-tests, modules/gc-des-tests,
5522         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
5523         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
5524         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
5525         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
5526         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
5527         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
5528         $(EXEEXT) to automake TESTS variable, for mingw32.
5529
5530 2006-01-17  Simon Josefsson  <jas@extundo.com>
5531
5532         * modules/socklen (Include): Need sys/socket.h.
5533
5534 2006-01-17  Bruno Haible  <bruno@clisp.org>
5535
5536         * modules/ssize_t (Include): Add <sys/types.h>.
5537
5538 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
5539
5540         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
5541         it's not portable and it doesn't work with cross-compiles.
5542         Problem reported by Bruno Haible.  Fix missing-$ typo in
5543         'test "gl_cv_ignore_unused_libraries" ...' that prevented
5544         -zignore from being used with Sun's C compiler.
5545
5546 2006-01-12  Simon Josefsson  <jas@extundo.com>
5547
5548         * lib/base64.c: Fix warning, reported by Bruno Haible
5549         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
5550
5551 2006-01-12  Bruno Haible  <bruno@clisp.org>
5552
5553         * modules/ldd: New file.
5554         * build-aux/ldd.sh.in: New file.
5555         * MODULES.html.sh (Support for building libraries and executables): Add
5556         ldd.
5557
5558 2006-01-12  Bruno Haible  <bruno@clisp.org>
5559
5560         * m4/ldd.m4: New file.
5561
5562 2006-01-12  Bruno Haible  <bruno@clisp.org>
5563
5564         * gnulib-tool (func_import, func_create_testdir): Don't go into an
5565         endless loop while replacing $auxdir with build-aux.
5566
5567 2006-01-11  Simon Josefsson  <jas@extundo.com>
5568
5569         * lib/stdint_.h (SIZE_MAX): Add missing (.
5570
5571 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
5572
5573         Sync from coreutils.
5574         * lib/md5.c: Fix commentary typos.
5575         (alignof, UNALIGNED_P): No need for a GCC-specific version.
5576         * lib/md5.h (__attribute__): Remove; unused.
5577         * lib/sha1.c: Fix commentary to match md5 better.
5578         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
5579         so that we don't need to worry about alignment.  All uses changed.
5580         This merges the 2005-10-28 md5 change into sha1.
5581
5582 2006-01-11  Jim Meyering  <jim@meyering.net>
5583
5584         Sync from coreutils.
5585         * lib/md5.c (OP): Fix spacing.
5586
5587 2006-01-11  Bruno Haible  <bruno@clisp.org>
5588
5589         Ensure automatic ordering between gl_LOCK and gl_ARGP.
5590         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
5591         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
5592
5593 2006-01-11  Bruno Haible  <bruno@clisp.org>
5594
5595         Ensure automatic ordering between gl_LOCK and gl_ARGP.
5596         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
5597         the "early" section as well.
5598
5599 2006-01-11  Bruno Haible  <bruno@clisp.org>
5600
5601         Avoid "ar: no archive members specified" error on MacOS X.
5602         * gnulib-tool (func_modules_add_dummy): New function.
5603         (func_import, func_create_testdir): Invoke it.
5604
5605 2006-01-11  Bruno Haible  <bruno@clisp.org>
5606
5607         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
5608         with $auxdir in AC_CONFIG_FILES statements.
5609
5610 2006-01-11  Bruno Haible  <bruno@clisp.org>
5611
5612         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5613         Initialize also noinst_HEADERS to empty.
5614
5615 2006-01-11  Bruno Haible  <bruno@clisp.org>
5616
5617         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
5618         variables.
5619         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
5620         autoreconf.
5621
5622 2006-01-11  Bruno Haible  <bruno@clisp.org>
5623
5624         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
5625         overridable by the user.
5626         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5627
5628 2006-01-10  Simon Josefsson  <jas@extundo.com>
5629
5630         * modules/sys_socket: New file.
5631
5632 2006-01-10  Simon Josefsson  <jas@extundo.com>
5633
5634         * m4/sys_socket_h.m4: New file.
5635
5636 2006-01-10  Simon Josefsson  <jas@extundo.com>
5637
5638         * lib/socket_.h: New file.
5639
5640 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
5641
5642         * modules/readutmp (Maintainer): Add myself.
5643
5644 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
5645
5646         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
5647         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
5648         People who are still concerned with buggy memcmp implementations
5649         can invoke gl_FUNC_MEMCMP themselves.
5650
5651 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
5652
5653         * lib/regex_internal.h (BITSET_WORD_BITS):
5654         Work around a bug in 64-bit PGC (before version 6.1-2), where the
5655         preprocessor mishandles large unsigned values as if they were signed.
5656         Problem reported by Claudio Fontana in
5657         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
5658
5659 2006-01-10  Jim Meyering  <jim@meyering.net>
5660
5661         Avoid the double-free (first in fts_read, second in fts_close) that
5662         would occur when an `active' directory is made inaccessible (e.g.,
5663         via chmod a-x) during a traversal.
5664         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
5665         before returning.  Reproduce this failure by
5666         mkdir -p a/b; cd a; chmod a-x . b
5667         Reported by Stavros Passas.
5668
5669         Sync from coreutils.
5670         * lib/sha1.c: Tweak grammar in a comment.
5671
5672 2006-01-10  Jim Meyering  <jim@meyering.net>
5673
5674         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
5675         Patch by Joerg Sonnenberger.
5676
5677 2006-01-10  Bruno Haible  <bruno@clisp.org>
5678
5679         * modules/readutmp: Depend on module free.
5680         * modules/strtok_r: Depend on module restrict.
5681
5682 2006-01-10  Bruno Haible  <bruno@clisp.org>
5683
5684         * modules/gettext (configure.ac): Add an invocation of
5685         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
5686
5687 2006-01-10  Bruno Haible  <bruno@clisp.org>
5688
5689         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
5690         Reported by Werner Lemberg <wl@gnu.org>.
5691
5692 2006-01-10  Bruno Haible  <bruno@clisp.org>
5693
5694         * lib/localcharset.c: Update from GNU gettext.
5695
5696 2006-01-10  Bruno Haible  <bruno@clisp.org>
5697
5698         * lib/argp.h (__const): Remove macro. Use const instead.
5699         * lib/argp-fmtstream.h (__const): Likewise.
5700         * lib/glob_.h (__const): Remove macro.
5701         * lib/glob-libc.h: Use const instead of __const.
5702
5703 2006-01-10  Bruno Haible  <bruno@clisp.org>
5704
5705         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
5706         variable.
5707         Needed to avoid an automake error regarding the 'gettext' module.
5708
5709 2006-01-09  Simon Josefsson  <jas@extundo.com>
5710
5711         * modules/inet_ntop (Depends-on): Add restrict.
5712
5713 2006-01-09  Simon Josefsson  <jas@extundo.com>
5714
5715         * modules/gc-rijndael-tests (License): Put under LGPL.
5716
5717         * modules/gc-des-tests (License): Likewise.
5718
5719         * modules/gc-arcfour-tests (License): Likewise.
5720
5721         * modules/gc-arctwo-tests (License): Likewise.
5722
5723         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
5724
5725         * modules/gc-hmac-sha1-tests (Files): Likewise.
5726
5727         * modules/gc-hmac-md5-tests (License): Likewise.
5728
5729         * modules/gc-sha1-tests (License): Likewise.
5730
5731         * modules/gc-md5-tests (License): Likewise.
5732
5733         * modules/gc-md4-tests (License): Likewise.
5734
5735         * modules/gc-md2-tests (License): Likewise.
5736
5737         * modules/gc-tests (License): Likewise.
5738
5739         * modules/des-tests (License): Likewise.
5740
5741         * modules/md4-tests (License): Likewise.
5742
5743         * modules/md2-tests (License): Likewise.
5744
5745 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
5746
5747         Sync from coreutils:
5748
5749         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
5750         * modules/lib-ignore: New file.
5751         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
5752         chdir-safer.m4, lchmod.m4.
5753         * modules/openat: Add mkdirat.c, openat-priv.h.
5754
5755 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
5756
5757         Sync from coreutils.
5758         * m4/lib-ignore.m4: New file.
5759         * m4/lchmod.m4: New file.
5760
5761 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
5762
5763         Sync from coreutils.
5764         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
5765         for write access: POSIX says that must fail.
5766         * lib/fts.c (diropen): Likewise.
5767         * lib/save-cwd.c (save_cwd): Likewise.
5768         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
5769         well, for minor improvements on hosts that lack O_DIRECTORY.
5770         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
5771         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
5772         Fall back on chown if open failed with EACCES.
5773
5774         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
5775         Report an error at compile-time if only a 1-second nominal clock
5776         resolution is found.
5777
5778         * lib/lchmod.h: New file.
5779         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
5780         (make_dir_parents): Use lchown rather than chown, and
5781         lchmod rather than chmod.
5782
5783         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
5784         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
5785         "proc" reported by n0dalus.
5786
5787         * lib/mountlist.c: Include <limits.h>.
5788         (dev_from_mount_options)
5789         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
5790         New function.  It no longer assumes "dev=" has the System V meaning
5791         on Linux (since it doesn't).  It also parses "dev=" more carefully.
5792         (read_file_system_list)
5793         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
5794         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
5795         dev= in that case.
5796
5797         * lib/posixtm.h (PDS_PRE_2000): New macro.
5798         * lib/posixtm.c (year): Arg is now syntax_bits rather than
5799         allow_century.  All usages changed.  Reject dates outside the range
5800         1969-1999 if PDS_PRE_2000 is used.
5801
5802 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
5803
5804         Sync from coreutils.
5805         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
5806         (Time of day items): Mention the possibility of leap seconds.
5807         Problem reported by Dr. David Alan Gilbert.
5808
5809 2006-01-09  Jim Meyering  <jim@meyering.net>
5810
5811         Sync from coreutils.
5812
5813         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
5814
5815         * lib/chdir-safer.h, chdir-safer.c: New files.
5816
5817         * lib/modechange.c (mode_compile): Reject an invalid mode string
5818         that starts with an octal digit.  From Andreas Gruenbacher.
5819
5820         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
5821         and dup to open_safer and dup_safer, respectively.
5822         (openat_permissive): Fix typo in comment.
5823
5824         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
5825         "gettext.h"; either no longer needed or are guaranteed by openat.h.
5826         (_): Remove; no longer needed.
5827         (openat): Renamed from rpl_openat; no need for rpl_openat
5828         since openat.h renames openat for us.
5829         Replace most of the body with a call to openat_permissive,
5830         to avoid duplicate code.
5831         Port to (probably hypothetical) environments were mode_t is
5832         wider than int.
5833         (openat_permissive): Require mode arg, so that we can check
5834         types better.  Put it just after flags.  Change cwd failure
5835         indicator from pointer-to-bool to pointer-to-errno-value.
5836         All callers changed.
5837         Invoke openat_save_fail and/or openat_restore_fail if
5838         cwd_errno is null, so that openat can call us.
5839         (openat_permissive, fdopendir, fstatat, unlinkat):
5840         Simplify errno handling to avoid some duplicate code,
5841         as it's OK to set errno on success.
5842         * lib/openat.h: Revamp code so that function macros depend on
5843         __OPENAT_PREFIX only, not also on AT_FDCWD.
5844         (openat_ro): Remove.  Caller changed to use openat_permissive.
5845         (openat_permissive): Now a macro, if not a function.
5846         (openat_restore_fail, openat_save_fail): Now always functions,
5847         since mkdirat needs them even if __OPENAT_PREFIX is defined.
5848
5849         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
5850         and openat.c.
5851         * lib/mkdirat.c: Include openat-priv.h.
5852         Remove definitions of macros defined therein.
5853         * lib/openat.c: Likewise.
5854
5855         * lib/mkdirat.c (mkdirat): New file and function.
5856         * lib/openat.h (mkdirat): Declare.
5857
5858         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
5859
5860         * lib/openat.h (openat_permissive): Declare.
5861         (openat_ro): Define.
5862
5863         * lib/openat.c (EXPECTED_ERRNO): New macro.
5864         (openat_permissive): New function -- used in remove.c rewrite.
5865         (all functions): Set errno just before returning, only if there
5866         was an actual failure.
5867         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
5868
5869         Emulate openat-family functions using Linux's procfs, if possible.
5870         Idea and some code based on Ulrich Drepper's glibc changes.
5871
5872         * lib/openat.c: (BUILD_PROC_NAME): New macro.
5873         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
5874         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
5875         before falling back on save_cwd and restore_cwd.
5876         (fdopendir, fstatat, unlinkat): Likewise.
5877
5878         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
5879         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
5880
5881         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
5882         as second argument to va_arg.  Otherwise, some versions of gcc
5883         warn that `if this code is reached, the program will abort'.
5884
5885 2006-01-09  Jim Meyering  <jim@meyering.net>
5886
5887         Sync from coreutils.
5888         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
5889         Require openat-priv.h.
5890
5891 2006-01-09  Bruno Haible  <bruno@clisp.org>
5892
5893         * modules/strnlen (Include): Use strnlen.h.
5894
5895 2006-01-09  Bruno Haible  <bruno@clisp.org>
5896
5897         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
5898
5899 2006-01-09  Bruno Haible  <bruno@clisp.org>
5900
5901         * lib/sysexit_.h (EX_OK): New macro.
5902         Suggested by Martin Lambers <marlam@marlam.de>.
5903
5904 2006-01-09  Bruno Haible  <bruno@clisp.org>
5905
5906         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
5907         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
5908
5909 2006-01-09  Bruno Haible  <bruno@clisp.org>
5910
5911         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
5912         numbers.
5913
5914 2006-01-09  Bruno Haible  <bruno@clisp.org>
5915
5916         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
5917         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
5918         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
5919         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
5920
5921 2006-01-09  Bruno Haible  <bruno@clisp.org>
5922
5923         * build-aux/javacomp.sh.in: New file, moved from lib/.
5924         * modules/javacomp-script (Files): Update.
5925         (configure.ac): Add AC_CONFIG_FILES invocation.
5926         (EXTRA_DIST): Remove variable.
5927
5928         * build-aux/javaexec.sh.in: New file, moved from lib/.
5929         * modules/javaexec (Files): Update.
5930         (configure.ac): Add AC_CONFIG_FILES invocation.
5931         (EXTRA_DIST): Remove javaexec.sh.in.
5932
5933         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
5934         * modules/csharpcomp-script (Files): Update.
5935         (configure.ac): Add AC_CONFIG_FILES invocation.
5936         (EXTRA_DIST): Remove variable.
5937
5938         * build-aux/csharpexec.sh.in: New file, moved from lib/.
5939         * modules/csharpexec (Files): Update.
5940         (configure.ac): Add AC_CONFIG_FILES invocation.
5941         (EXTRA_DIST): Remove csharpexec.sh.in.
5942
5943 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
5944
5945         Sync from coreutils.
5946
5947         Add POSIX ACL support
5948         * lib/acl.h (copy_acl, set_acl): Add declarations.
5949         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
5950         systems other than Linux.
5951         (chmod_or_fchmod): New function: use fchmod when possible,
5952         and chmod otherwise.
5953         (file_has_acl): Add a POSIX ACL implementation, with a
5954         Linux-specific subcase.
5955         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
5956         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
5957         acls are unsupported.
5958         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
5959         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
5960         are unsupported.
5961
5962 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
5963
5964         Sync from coreutils.
5965         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
5966
5967 2006-01-07  Bruno Haible  <bruno@clisp.org>
5968
5969         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
5970         gl_EARLY.
5971
5972 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
5973
5974         * lib/strftime.c (tzname): Don't declare if it is already #defined.
5975         Problem reported for Mingw by Mark Junker.
5976
5977 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
5978
5979         * README: Gnulib normally doesn't generate a tarball.
5980
5981 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
5982
5983         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
5984         long int, not int, for nanosecond counts, so that people who are
5985         used to POSIX struct timespec won't be surprised.  Reported by Jim
5986         Meyering.
5987
5988 2005-12-28  Bruno Haible  <bruno@clisp.org>
5989
5990         * build-aux/config.rpath: Update from GNU gettext.
5991
5992 2005-12-16  Jim Meyering  <jim@meyering.net>
5993
5994         * modules/fprintftime: New module.
5995         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
5996
5997 2005-12-16  Jim Meyering  <jim@meyering.net>
5998
5999         * m4/fprintftime.m4: New file.
6000
6001 2005-12-16  Jim Meyering  <jim@meyering.net>
6002
6003         * lib/fprintftime.c, fprintftime.h: New files.
6004
6005 2005-12-15  Simon Josefsson  <jas@extundo.com>
6006
6007         * modules/socklen (configure.ac): Fix M4 macro name, to align with
6008         new m4/socklen.m4.
6009
6010 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
6011
6012         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
6013         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
6014
6015 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
6016
6017         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
6018         * lib/argp-help.c (fill_in_uparams): Check if the constructed
6019         struct uparams is valid. Fall back to the default values if it is
6020         not.
6021
6022 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
6023
6024         * modules/argp (Files): Add argp-pin.c
6025         (Depends-on): dirname
6026         (lib_SOURCES): Add argp-pin.c
6027
6028 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
6029
6030         * m4/argp.m4:  Check if program_invocation_name and
6031         program_invocation_short_name are declared and define appropriate
6032         macros if they are not.
6033
6034 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
6035
6036         * lib/argp-help.c (__argp_base_name): New function
6037         (__argp_short_program_name): Rewrite using __argp_base_name
6038         * lib/argp-namefrob.h: Define program_invocation_name and
6039         program_invocation_short_name if requested
6040         (__argp_base_name): Add prototype
6041         * lib/argp-parse.c (argp_def): Use gettext wrappers
6042         (argp_default_parser): Use __argp_base_name
6043         * lib/argp-pin.c: New file. Defines program_invocation_name and
6044         program_invocation_short_name on systems that lack them.
6045
6046 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
6047
6048         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
6049         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
6050         porting problem reported by Georg Schwarz in
6051         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
6052
6053 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
6054
6055         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
6056         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
6057         porting problem reported by Georg Schwarz in
6058         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
6059
6060 2005-12-05  Bruno Haible  <bruno@clisp.org>
6061
6062         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
6063         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
6064         Reported by Mark Junker <mjscod@gmx.de>.
6065
6066 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
6067
6068         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
6069         Use implementation from Albert Chin, with some
6070         comments/corrections by Stepan Kasal and myself.
6071
6072 2005-12-02  Bruno Haible  <bruno@clisp.org>
6073
6074         * gnulib-tool (func_import): Accept GPLed build tool modules when
6075         --lgpl is given.
6076         * modules/csharpcomp-script: New file.
6077         * modules/csharpcomp: Depend on it.
6078         * modules/javacomp-script: New file.
6079         * modules/javacomp: Depend on it.
6080         Suggested by Simon Josefsson.
6081
6082 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
6083
6084         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
6085         statement, to work around an HP-UX 10.20 compiler bug reported by
6086         Peter O'Gorman.
6087
6088 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
6089
6090         * modules/savedir (Depends-on): Add openat.
6091
6092 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
6093
6094         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
6095         (uintmax_t) [defined uintmax_t]: Do not declare.
6096         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
6097         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
6098         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
6099         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
6100         sake of portability to weird hosts that C allows (though we don't
6101         know of any practical examples).
6102
6103         * lib/savedir.h (fdsavedir): New decl.
6104         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
6105         contains most of the former guts of savedir.
6106         (savedir): Use savedirstream.
6107         Include "openat.h".
6108
6109 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
6110
6111         * modules/obstack (Files): Add m4/ulonglong.m4.
6112         Problem reported by Davide Angelocola.
6113
6114 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
6115
6116         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
6117         coreutils no longer futzes with rounding modes.
6118
6119 2005-11-14  Jim Meyering  <jim@meyering.net>
6120
6121         * lib/mkstemp-safer.c: Include <config.h>, required for possible
6122         replacement of mkstemp.
6123
6124 2005-11-10  Simon Josefsson  <jas@extundo.com>
6125
6126         * lib/readline.c: Remove EOL.
6127
6128 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
6129
6130         * modules/gethrxtime (Depends-on): Add gettime.
6131
6132 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
6133
6134         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
6135         or gettimeofday; no longer needed.
6136
6137 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
6138
6139         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
6140         time business.
6141         (gethrxtime) [! (HAVE_NANOUPTIME
6142         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
6143         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
6144         our own approximation.
6145
6146 2005-11-08  Eric Blake  <ebb9@byu.net>
6147
6148         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
6149
6150 2005-11-08  Eric Blake  <ebb9@byu.net>
6151
6152         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
6153
6154 2005-11-04  Bruno Haible  <bruno@clisp.org>
6155
6156         * gnulib-tool: Implement --update mode.
6157
6158 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
6159
6160         Fix porting problem reported by Theodoros V. Kalamatianos.
6161         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
6162         Don't assume that futimes failing means we must fail.
6163
6164 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
6165
6166         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
6167         variables to suggest the intended function of the PATH_MAX check.
6168
6169 2005-10-30  Kean Johnston  <jkj@sco.com>
6170
6171         Trivial changes to support SCO systems.
6172         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
6173         as PATH_MAX.
6174         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
6175         where __ptr is null when no I/O is pending.
6176
6177 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
6178
6179         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
6180         leave errno alone.  Problem reported by Dmitry V. Levin.
6181
6182 2005-10-28  Simon Josefsson  <jas@extundo.com>
6183
6184         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
6185         Test more.
6186
6187         * tests/test-gc-md2.c, tests/test-md2.c: New files.
6188
6189         * modules/md2, modules/md2-tests: New files.
6190
6191 2005-10-28  Simon Josefsson  <jas@extundo.com>
6192
6193         * m4/inet_ntop.m4: More tests.
6194
6195         * m4/gc-md2.m4, md2.m4: New file.
6196
6197 2005-10-28  Simon Josefsson  <jas@extundo.com>
6198
6199         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
6200         "restrict" keywords, as per POSIX.  Protect the function
6201         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
6202         Don't use K&R prototypes.  Check the sprintf return values.
6203         Re-define EAFNOSUPPORT if not present.  Indent.
6204
6205         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
6206         suggested by Bruno Haible <bruno@clisp.org>.
6207
6208         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
6209
6210         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
6211
6212         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
6213         libgcrypt).
6214
6215         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
6216
6217         * lib/md2.h, md2.c: New files.
6218
6219 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
6220
6221         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
6222         errno alone.  Problem reported by Frederic Jolliton.
6223
6224 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
6225
6226         * modules/verify (License): Change from GPL to LGPL.  This is a
6227         tiny module and there are apparently near-equivalents that are
6228         under the BSD license.
6229
6230 2005-10-24  Simon Josefsson  <jas@extundo.com>
6231
6232         * modules/sha1: Relicense to LGPL.
6233
6234 2005-10-24  Simon Josefsson  <jas@extundo.com>
6235
6236         * lib/md4.h: Shrink buffer size, now that we changed the type.
6237
6238 2005-10-23  Simon Josefsson  <jas@extundo.com>
6239
6240         * gnulib-tool (func_import): Fix --tests-base.
6241
6242 2005-10-22  Simon Josefsson  <jas@extundo.com>
6243
6244         * modules/arcfour (Depends-on): Need stdint.
6245
6246 2005-10-22  Simon Josefsson  <jas@extundo.com>
6247
6248         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
6249         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
6250
6251 2005-10-22  Simon Josefsson  <jas@extundo.com>
6252
6253         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
6254         suggested by Bruno Haible <bruno@clisp.org>.
6255
6256 2005-10-22  Simon Josefsson  <jas@extundo.com>
6257
6258         * lib/crc.h: Include stddef.h, for size_t.
6259
6260 2005-10-22  Simon Josefsson  <jas@extundo.com>
6261
6262         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
6263         arcfour_context struct (simplify test vector testing in GNU
6264         Shishi).
6265
6266 2005-10-21  Simon Josefsson  <jas@extundo.com>
6267
6268         * modules/des, modules/des-tests: New files.
6269
6270         * modules/gc-des, modules/gc-des-tests: New files.
6271
6272         * tests/test-des.c, tests/test-gc-des.c: New file.
6273
6274 2005-10-21  Simon Josefsson  <jas@extundo.com>
6275
6276         * modules/arctwo, modules/arctwo-tests: New files.
6277
6278         * tests/test-arctwo.c: New file.
6279
6280         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
6281
6282         * tests/test-gc-arctwo.c: New file.
6283
6284 2005-10-21  Simon Josefsson  <jas@extundo.com>
6285
6286         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
6287         Bruno Haible <bruno@clisp.org>.
6288
6289         * m4/gc-des.m4: New file.
6290
6291 2005-10-21  Simon Josefsson  <jas@extundo.com>
6292
6293         * m4/arctwo.m4: New file.
6294
6295         * m4/gc-arctwo.m4: New file.
6296
6297 2005-10-21  Simon Josefsson  <jas@extundo.com>
6298
6299         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
6300         block.
6301
6302 2005-10-21  Simon Josefsson  <jas@extundo.com>
6303
6304         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
6305         <bruno@clisp.org>.
6306
6307         * lib/hmac-sha1.c (hmac_sha1): Likewise.
6308
6309         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
6310         Bruno Haible <bruno@clisp.org>.
6311
6312         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
6313         <bruno@clisp.org>.
6314
6315 2005-10-21  Simon Josefsson  <jas@extundo.com>
6316
6317         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
6318
6319 2005-10-21  Simon Josefsson  <jas@extundo.com>
6320
6321         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
6322
6323 2005-10-21  Simon Josefsson  <jas@extundo.com>
6324
6325         * lib/des.h, des.c: New files.
6326
6327         * lib/gc-gnulib.c: Support DES.c
6328
6329 2005-10-21  Simon Josefsson  <jas@extundo.com>
6330
6331         * lib/arctwo.h, arctwo.c: New files.
6332
6333         * lib/gc-gnulib.c: Support ARCTWO.
6334
6335 2005-10-21  Simon Josefsson  <jas@extundo.com>
6336
6337         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
6338         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6339
6340 2005-10-21  Simon Josefsson  <jas@extundo.com>
6341
6342         * gnulib-tool (func_import, func_create_testdir): Define automake
6343         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
6344         Makefile.am snippet),
6345         suggested by Bruno Haible <bruno@clisp.org>.
6346
6347         * modules/gc (Makefile.am): Use it.
6348
6349 2005-10-21  Bruno Haible  <bruno@clisp.org>
6350
6351         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
6352         patch.
6353
6354 2005-10-19  Simon Josefsson  <jas@extundo.com>
6355
6356         * tests/test-gc-rijndael.c: New file.
6357
6358         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
6359
6360 2005-10-19  Simon Josefsson  <jas@extundo.com>
6361
6362         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
6363         interface too.
6364
6365 2005-10-19  Simon Josefsson  <jas@extundo.com>
6366
6367         * tests/test-gc-arcfour.c: New file.
6368
6369         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
6370
6371 2005-10-19  Simon Josefsson  <jas@extundo.com>
6372
6373         * modules/gc-md4, modules/gc-md4-tests: New file.
6374
6375         * tests/test-gc-md4.c: New file.
6376
6377 2005-10-19  Simon Josefsson  <jas@extundo.com>
6378
6379         * m4/gc-md4.m4: New file.
6380
6381 2005-10-19  Simon Josefsson  <jas@extundo.com>
6382
6383         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
6384         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
6385         <kasal@ucw.cz>.
6386
6387 2005-10-19  Simon Josefsson  <jas@extundo.com>
6388
6389         * m4/gc-arcfour.m4: New file.
6390
6391         * m4/gc-rijndael.m4: New file.
6392
6393 2005-10-19  Simon Josefsson  <jas@extundo.com>
6394
6395         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
6396
6397 2005-10-19  Simon Josefsson  <jas@extundo.com>
6398
6399         * lib/gc-gnulib.c: Support ARCFOUR.
6400
6401 2005-10-19  Simon Josefsson  <jas@extundo.com>
6402
6403         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
6404         support.
6405
6406         * lib/gc.h: Add ECB enum type.
6407
6408         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
6409
6410 2005-10-18  Simon Josefsson  <jas@extundo.com>
6411
6412         * tests/test-md5.c: New file.
6413
6414         * modules/md5-tests: New file.
6415
6416 2005-10-18  Simon Josefsson  <jas@extundo.com>
6417
6418         * tests/test-md4.c: New file.
6419
6420         * modules/md4, modules/md4-tests: New files.
6421
6422 2005-10-18  Simon Josefsson  <jas@extundo.com>
6423
6424         * m4/md4.m4: New file.
6425
6426 2005-10-18  Simon Josefsson  <jas@extundo.com>
6427
6428         * lib/md4.h, md4.c: New files, based on md5.?.
6429
6430 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
6431
6432         * gnulib-tool (func_create_testdir): Omit the second check whether
6433         BUILT_SOURCES in nonempty.
6434
6435 2005-10-17  Simon Josefsson  <jas@extundo.com>
6436
6437         * tests/test-rijndael.c: New file.
6438
6439 2005-10-17  Simon Josefsson  <jas@extundo.com>
6440
6441         * modules/sha1: Depend on stdint instead of md5.
6442
6443         * modules/md5: Depend on stdint, remove uint32_t.
6444
6445 2005-10-17  Simon Josefsson  <jas@extundo.com>
6446
6447         * modules/gc-sha1-tests: New file.
6448
6449         * tests/test-gc-sha1.c: New file.
6450
6451 2005-10-17  Simon Josefsson  <jas@extundo.com>
6452
6453         * m4/md5.m4: Remove call to uint32_t.m4.
6454
6455 2005-10-17  Simon Josefsson  <jas@extundo.com>
6456
6457         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
6458
6459         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
6460         md5.h.
6461
6462         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
6463
6464         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
6465
6466 2005-10-17  Simon Josefsson  <jas@extundo.com>
6467
6468         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
6469
6470 2005-10-17  Simon Josefsson  <jas@extundo.com>
6471
6472         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
6473
6474 2005-10-17  Simon Josefsson  <jas@extundo.com>
6475
6476         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
6477
6478         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
6479
6480 2005-10-17  Bruno Haible  <bruno@clisp.org>
6481
6482         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
6483         that it can also be used in a test.
6484
6485 2005-10-16  Bruno Haible  <bruno@clisp.org>
6486
6487         * gnulib-tool (func_emit_tests_Makefile_am): Also define
6488         TESTS_ENVIRONMENT, so that individual tests can augment it.
6489
6490         * gnulib-tool (func_create_testdir): Use an intermediate target for
6491         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
6492         macros, like $(ALLOCA_H), which cannot be passed through the command
6493         line.
6494
6495 2005-10-15  Simon Josefsson  <jas@extundo.com>
6496
6497         * modules/rijndael-tests: New file.
6498
6499         * modules/rijndael: New file.
6500
6501 2005-10-15  Simon Josefsson  <jas@extundo.com>
6502
6503         * m4/rijndael.m4: New file.
6504
6505 2005-10-15  Simon Josefsson  <jas@extundo.com>
6506
6507         * lib/rijndael-api-fst.h, rijndael-api-fst.c: New files.
6508
6509         * lib/rijndael-alg-fst.h, rijndael-alg-fst.c: New files.
6510
6511 2005-10-14  Simon Josefsson  <jas@extundo.com>
6512
6513         * tests/test-arcfour.c: New file.
6514
6515         * modules/arcfour, modules/arcfour-tests: New files.
6516
6517 2005-10-14  Simon Josefsson  <jas@extundo.com>
6518
6519         * m4/arcfour.m4: New file.
6520
6521 2005-10-14  Simon Josefsson  <jas@extundo.com>
6522
6523         * lib/arcfour.h, arcfour.c: New files.
6524
6525 2005-10-14  Roland McGrath  <roland@redhat.com>
6526
6527         Import from libc.  [BZ #1331]
6528         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
6529         macro argument.
6530         Reported by Matej Vela <vela@debian.org>.
6531
6532 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
6533
6534         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
6535         include <wchar.h>; no longer needed.
6536
6537 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
6538
6539         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
6540
6541 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
6542         and  Ulrich Drepper  <drepper@redhat.com>
6543
6544         Import from libc.
6545         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
6546         instead of inline stream orientation test and two separate
6547         function calls.  Pay no attention to USE_IN_LIBIO.
6548
6549 2005-10-13  Simon Josefsson  <jas@extundo.com>
6550
6551         * modules/gc-hmac-md5-tests: New file.
6552
6553         * tests/test-gc-hmac-sha1.c: New file.
6554
6555         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
6556
6557         * modules/gc-hmac-md5-tests: New file.
6558
6559         * tests/test-gc-md5.c: New file.
6560
6561         * modules/gc-md5-tests: New file.
6562
6563 2005-10-13  Simon Josefsson  <jas@extundo.com>
6564
6565         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
6566         Move memory allocation outside of loop.
6567
6568 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
6569
6570         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
6571         intermediate directory is in a read-only file system.  Problem
6572         reported by Eric Blake.
6573
6574 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
6575
6576         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
6577
6578 2005-10-12  Simon Josefsson  <jas@extundo.com>
6579
6580         * tests/test-hmac-sha1.c: New file.
6581
6582         * modules/hmac-sha1-tests: New file.
6583
6584         * modules/hmac-sha1: New file.
6585
6586 2005-10-12  Simon Josefsson  <jas@extundo.com>
6587
6588         * modules/gc-sha1: New file.
6589
6590 2005-10-12  Simon Josefsson  <jas@extundo.com>
6591
6592         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
6593
6594         * tests/test-gc-pbkdf2-sha1.c: New file.
6595
6596 2005-10-12  Simon Josefsson  <jas@extundo.com>
6597
6598         * modules/gc-md5, modules/gc-hmac-md5: New files.
6599
6600         * modules/gc (Files): Remove md5, memxor and hmac files.
6601
6602 2005-10-12  Simon Josefsson  <jas@extundo.com>
6603
6604         * m4/gc-pbkdf2-sha1.m4: New file.
6605
6606         * m4/gc-hmac-sha1.m4: New file.
6607
6608         * m4/gc-sha1: New file.
6609
6610         * m4/hmac-sha1.m4: New file.
6611
6612 2005-10-12  Simon Josefsson  <jas@extundo.com>
6613
6614         * m4/gc-md5.m4, gc-hmac-md5: New files.
6615
6616         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
6617
6618 2005-10-12  Simon Josefsson  <jas@extundo.com>
6619
6620         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
6621         suggested by Bruno Haible <bruno@clisp.org>.
6622
6623 2005-10-12  Simon Josefsson  <jas@extundo.com>
6624
6625         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
6626
6627 2005-10-12  Simon Josefsson  <jas@extundo.com>
6628
6629         * lib/gc-pbkdf2-sha1.c: New file.
6630
6631         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
6632
6633 2005-10-12  Simon Josefsson  <jas@extundo.com>
6634
6635         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
6636
6637         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
6638
6639 2005-10-12  Simon Josefsson  <jas@extundo.com>
6640
6641         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
6642         GC_USE_HMAC_MD5, respectively.
6643
6644         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
6645         (gc_md5): Fix typo.
6646
6647         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
6648
6649         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
6650
6651         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
6652
6653 2005-10-12  Bruno Haible  <bruno@clisp.org>
6654
6655         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
6656         Reported by Stepan Kasal <kasal@ucw.cz>.
6657
6658 2005-10-11  Simon Josefsson  <jas@extundo.com>
6659
6660         * tests/test-crc.c: New file.
6661
6662         * modules/crc, modules/crc-tests: New files.
6663
6664 2005-10-11  Simon Josefsson  <jas@extundo.com>
6665
6666         * m4/crc.m4: New file.
6667
6668 2005-10-11  Simon Josefsson  <jas@extundo.com>
6669
6670         * lib/gc.h: Add gc_hash and gc_hash_buffer.
6671
6672         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
6673
6674         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
6675
6676 2005-10-11  Simon Josefsson  <jas@extundo.com>
6677
6678         * lib/crc.h, crc.c: New files.
6679
6680         * lib/gc.h (gc_hash_buffer): Add doc.
6681
6682 2005-10-11  Bruno Haible  <bruno@clisp.org>
6683
6684         * modules/c-strcasestr: New file.
6685         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
6686
6687 2005-10-11  Bruno Haible  <bruno@clisp.org>
6688
6689         * modules/c-strcase: New file.
6690         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
6691
6692 2005-10-11  Bruno Haible  <bruno@clisp.org>
6693
6694         * lib/strcasecmp.c: Include limits.h.
6695         (strcasecmp): Avoid integer overflow on exotic platforms.
6696         * lib/strncasecmp.c: Include limits.h.
6697         (strncasecmp): Avoid integer overflow on exotic platforms.
6698         Reported by Paul Eggert.
6699
6700 2005-10-11  Bruno Haible  <bruno@clisp.org>
6701
6702         * lib/c-strcasestr.h: New file, from GNU gettext.
6703         * lib/c-strcasestr.c: New file, from GNU gettext.
6704
6705 2005-10-11  Bruno Haible  <bruno@clisp.org>
6706
6707         * lib/c-strcase.h: New file, from GNU gettext.
6708         * lib/c-strcasecmp.c: New file, from GNU gettext.
6709         * lib/c-strncasecmp.c: New file, from GNU gettext.
6710
6711 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
6712
6713         * modules/mempcpy (License): GPL -> LGPL.
6714         * modules/strchrnul (License): Likewise.
6715         * modules/sysexits (License): Likewise.
6716
6717 2005-10-08  Simon Josefsson  <jas@extundo.com>
6718
6719         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
6720
6721 2005-10-07  Simon Josefsson  <jas@extundo.com>
6722
6723         * m4/memxor.m4: Remove gl_C_RESTRICT call.
6724
6725 2005-10-06  Simon Josefsson  <jas@extundo.com>
6726
6727         * tests/test-hmac-md5.c: New file.
6728
6729         * modules/hmac-md5-tests: New file.
6730
6731         * modules/hmac-md5: New file.
6732
6733 2005-10-06  Simon Josefsson  <jas@extundo.com>
6734
6735         * m4/hmac-md5.m4: New file.
6736
6737         * m4/memxor.m4: Require gl_C_RESTRICT.
6738
6739 2005-10-06  Simon Josefsson  <jas@extundo.com>
6740
6741         * lib/memxor.c (memxor): Avoid casts and warnings.
6742
6743 2005-10-06  Simon Josefsson  <jas@extundo.com>
6744
6745         * lib/hmac-md5.c: New file.
6746
6747         * lib/hmac.h: New file.
6748
6749 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
6750
6751         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
6752         promotes to int, not unsigned int, to catch the AIX 5.3
6753         compiler bug.
6754
6755 2005-10-05  Simon Josefsson  <jas@extundo.com>
6756
6757         * modules/memxor: New file.
6758
6759         * modules/iconv (Files): Move config.rpath to havelib, it is used
6760         there.
6761
6762         * modules/havelib (Files): Add config.rpath.
6763
6764 2005-10-05  Simon Josefsson  <jas@extundo.com>
6765
6766         * m4/memxor.m4: New file.
6767
6768 2005-10-05  Simon Josefsson  <jas@extundo.com>
6769
6770         * lib/memxor.c (memxor): Fix compiler error.
6771
6772         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
6773         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
6774
6775         * lib/memxor.h, memxor.c: New files.
6776
6777         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
6778         we assume all systems have it, suggested by Jim Meyering
6779         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
6780         any systems lack sys/socket.h; mingw32 is known to lack it, but we
6781         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
6782         same reasons.
6783
6784 2005-10-05  Simon Josefsson  <jas@extundo.com>
6785
6786         * config/srclist.txt: Add glibc bug 1423 for md5.h.
6787
6788 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
6789
6790         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
6791         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
6792         needed, since the source code now assumes these .h files.
6793
6794 2005-10-05  Derek Price  <derek@ximbiot.com>
6795
6796         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
6797
6798 2005-10-05  Bruno Haible  <bruno@clisp.org>
6799
6800         * modules/stdint (License): Change to LGPL.
6801
6802 2005-10-04  Simon Josefsson  <jas@extundo.com>
6803
6804         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
6805         D. Baushke" <mdb@gnu.org>.
6806
6807 2005-10-04  Bruno Haible  <bruno@clisp.org>
6808
6809         * lib/verify.h (verify_true): Provide alternative definition for C++.
6810
6811 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
6812
6813         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
6814         (SSIZE_MAX): New macro, if not already defined.
6815         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
6816         than 2 GiB.
6817
6818 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
6819
6820         Sync from coreutils.
6821         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
6822         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
6823         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
6824         ULLONG_MAX doesn't work with 2.7.2.1.
6825
6826 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
6827
6828         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
6829         From Ben Pfaff.
6830
6831         * modules/exclude (Depends-on): Depend on verify.
6832         * modules/strtoimax (Depends-on): Likewise.
6833         * modules/utimecmp (Depends-on): Likewise.
6834
6835 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
6836
6837         * lib/exclude.c: Include verify.h.
6838         (verify): Remove.  All callers changed to use verify.h's version.
6839         * lib/strtoimax.c: Likewise.
6840         * lib/utimecmp.c: Likewis.e
6841
6842         Sync from coreutils.
6843         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
6844         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
6845         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
6846         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
6847         bother returning ENOSYS if settimeofday or stime fails; just let
6848         them return whatever errno they want to return.
6849         * lib/utimens.c: Include unistd.h, for dup2.
6850         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
6851         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
6852
6853 2005-10-02  Jim Meyering  <jim@meyering.net>
6854
6855         Sync from coreutils.
6856         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
6857         from glibc-2.2.5 that fails for read-only files.
6858
6859 2005-10-02  Jim Meyering  <jim@meyering.net>
6860
6861         Sync from coreutils.
6862         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
6863         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
6864         `#if HAVE_CONFIG_H'.
6865         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
6866         Remove AT_FDCWD test.
6867         Do not consume the fd unless successful.
6868         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
6869         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
6870         block, so that we don't even try to compile it if settimeofday is
6871         available.  This works around a compilation failure on OSF1 V5.1,
6872         due to stime requiring a `long int*' while tv_sec is `int'.
6873
6874 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
6875
6876         Sync from coreutils.
6877         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
6878         against `yes', rather than just testing for nonempty.
6879
6880 2005-10-01  Simon Josefsson  <jas@extundo.com>
6881
6882         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
6883         and Darwin.
6884
6885         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
6886         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
6887         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
6888         freeaddrinfo and gai_strerror are declared by the POSIX headers.
6889         Check if struct addrinfo is declared.
6890
6891 2005-10-01  Simon Josefsson  <jas@extundo.com>
6892
6893         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
6894         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
6895         AI_* and EAI_* definitions.  Protect function declarations.
6896
6897 2005-10-01  Jim Meyering  <jim@meyering.net>
6898
6899         Sync from coreutils.
6900
6901         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
6902         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
6903         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
6904         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
6905         in the inet and nsl libraries.  Required on Solaris 5.7.
6906
6907 2005-10-01  Jim Meyering  <jim@meyering.net>
6908
6909         Sync from coreutils.
6910         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
6911         in the inet and nsl libraries.  Required on Solaris 5.7.
6912
6913 2005-10-01  Eric Blake  <ebb9@byu.net>
6914
6915         * lib/getdelim.c (getdelim): Remove unused variables.
6916
6917 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
6918
6919         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
6920         so that the code works even with ancient cpp.  Portability problem
6921         with GCC 2.7.2.1 reported by Thomas M.Ott.
6922
6923 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
6924
6925         * modules/regex (Depends-on): Add strcase.
6926
6927         * modules/gethostname (Licence): Change from GPL to LGPL, since
6928         gethostname.c is a trivial implementation of a standard library
6929         function.
6930         * modules/poll (License): Change from GPL to LGPL, since it's
6931         derived from LGPL code.
6932
6933 2005-09-27  Jim Meyering  <jim@meyering.net>
6934
6935         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
6936         HAVE_CONFIG_H.
6937
6938         * lib/intprops.h (signed_type_or_expr__): Define.
6939         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
6940         for unsigned types.
6941
6942 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
6943
6944         * lib/verify.h (verify_expr): Remove, replacing with:
6945         (verify_true): New macro that returns true instead of void.
6946         (verify_type__): Remove.
6947         (verify): Use verify_true rather than verify_type__.
6948
6949 2005-09-26  Bruno Haible  <bruno@clisp.org>
6950
6951         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
6952         is necessary.
6953         (lib_SOURCES): Remove mbchar.c.
6954         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
6955         (Files): Add m4/mbrtowc.m4.
6956         * modules/mbiter: Likewise.
6957         * modules/mbuiter: Likewise.
6958
6959 2005-09-26  Bruno Haible  <bruno@clisp.org>
6960
6961         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
6962         compile mbchar.c if they are not both present.
6963         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
6964         * m4/mbiter.m4 (gl_MBITER): Likewise.
6965         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
6966         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
6967         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
6968
6969 2005-09-25  Jim Meyering  <jim@meyering.net>
6970
6971         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
6972         also uses socklen_t.
6973
6974 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
6975
6976         * lib/utimens.c (ENOSYS): Define if not already defined.
6977         (futimens): Support having a null PATH if the file descriptor
6978         is nonnegative.
6979
6980         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
6981         Remove.
6982         (__attribute): Define to empty unless GCC 3.1 or later.
6983         This works around a core dump on OpenBSD 3.4, which has GCC
6984         2.95.3, which dumps core when given __attribute__(()).  It also
6985         simplifies other tests, since we really don't want to bother with
6986         worrying about which ancient version of GCC supported what.
6987         Original problem reported by Yoann Vandoorselaere, with part of
6988         the fix suggested by Derek Price.
6989
6990 2005-09-24  Jim Meyering  <jim@meyering.net>
6991
6992         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
6993         so we can once again use a positive bitfield width of 1 -- now we
6994         don't have to explain why we were using a bitfield width of 2.
6995
6996 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
6997
6998         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
6999         and similarly for the other external symbols.  Problem reported
7000         by James Gallager.
7001
7002         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
7003         bug reported by Jim Meyering.
7004
7005         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
7006         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
7007         not needed, since socklen is a prerequisite module.
7008
7009 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
7010
7011         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
7012         Problem reported by Eric Blake.
7013         (getaddrinfo): Initialize se so that it's not garbage.
7014         Redo internal storage allocation so that it doesn't make unportable
7015         assumptions about alignment.
7016         Fix a memory leak.
7017
7018         * lib/utimens.c (futimens): Use futimesat if available.
7019         Prefer it to futimes since it doesn't have the futimes bug.
7020
7021         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
7022         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
7023         Instead, declare a function that returns a pointer to an array,
7024         and use verify_type__ to declare the size of the array.
7025         Problem and germ of a solution reported by Bruno Haible.
7026         (verify_type__): Use 2, not 1, for bitfield size, to avoid
7027         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
7028
7029 2005-09-23  Jim Meyering  <jim@meyering.net>
7030
7031         Sync from coreutils.
7032         Correct build failure (socklen_t not defined) on at least
7033         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
7034         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
7035
7036 2005-09-23  Jim Meyering  <jim@meyering.net>
7037
7038         * modules/getaddrinfo (Depends-on): Add socklen.
7039
7040 2005-09-23  Bruno Haible  <bruno@clisp.org>
7041
7042         * tests/test-verify.c: New file.
7043
7044 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
7045
7046         Sync from coreutils.
7047
7048         * modules/argmatch (Depends-on): Add verify.
7049         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
7050         unistd-safer.
7051         * modules/save-cwd (Depends-on): Likewise.
7052
7053         * modules/openat (Files): Add lib/openat-die.c.
7054         (Depends-on): Remove error, exitfail.
7055         Add dirname.
7056
7057         * modules/verify: New file.
7058         * MODULES.html.sh (Diagnostics <assert.h>): New section,
7059         with "verify" module.
7060
7061 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
7062
7063         Sync from coreutils.
7064
7065         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
7066         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
7067         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
7068         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
7069         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
7070         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
7071         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
7072         Don't bother checking for string.h, stdlib.h, unistd.h.
7073         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
7074         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
7075         module's job.
7076         * m4/jm-macros.m4 (gl_MACROS): Likewise.
7077         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
7078
7079         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
7080         (gl_GETDATE): Use it.
7081
7082         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
7083
7084 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
7085
7086         Sync from coreutils.
7087
7088         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
7089         stat-time.h.
7090         * lib/argmatch.h: Include verify.h
7091         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
7092         (ARGMATCH_ASSERT): Remove; unused.
7093         * lib/canonicalize.c: Assume STDC_HEADERS.
7094         * lib/exclude.c: Include "strcase.h".
7095         * lib/regex_internal.h [!defined _LIBC]: Likewise.
7096         * lib/getusershell.c: Include stdio--.h rather than stdio.h
7097         and stdio-safer.h.
7098         (getusershell): Call fopen, not fopen_safer.
7099         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
7100         Do not include unistd-safer.h.
7101         (save_cwd): Don't call fd_safer; no longer needed
7102         now that we include fcntl--.h.
7103
7104         * lib/getdate.y (relative_time): New type.
7105         (RELATIVE_TIME_0): New constant.
7106         (parser_control): Use relative_time instead of doing it ourselves.
7107         (%union): Add new relative_time rel member.
7108         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
7109         Now typeless.
7110         (relunit, relunit_snumber): Now of type rel.
7111         (zone, rel, relunit, get_date): Adjust to above changes.
7112
7113         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
7114         Do not include unistd-safer.h.
7115         (getloadavg): Don't call fd_safer; no longer needed
7116         now that we include fcntl--.h.
7117
7118         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
7119         (make_dir_parents): Treat ENOSYS like EEXIST.
7120
7121         Improve quality of diagnostics on restore_cwd failure.
7122         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
7123         (make_dir_parents): Last arg is now int * (for errno), not bool *.
7124         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
7125         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
7126         each time through the loop.  Do not diagnose restore_cwd failure;
7127         that is the caller's job (and perhaps the caller does not care).
7128
7129         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
7130         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
7131         If the file already exists but is not a directory, don't bother
7132         to try to make its parents.
7133         Close potential file descriptor leak if we can't chdir("/") (!).
7134         Don't always return true if chdir($PWD) fails; return true only
7135         if the requested action was done successfully (except for the
7136         chdir($PWD)).
7137         Don't log final directory unless we actually made it.
7138         Refactor to avoid duplicate code to fix up permissions.
7139         Don't attempt to fix up parent permissions if chdir($PWD) fails.
7140
7141         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
7142         to make it a bit faster and (I hope) clearer.
7143         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
7144         Fix bug in formats like %2N.
7145
7146         * lib/verify.h: New file.
7147
7148 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
7149
7150         Sync from coreutils.
7151         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
7152
7153 2005-09-22  Jim Meyering  <jim@meyering.net>
7154
7155         Sync from coreutils.
7156
7157         * m4/lstat.m4 (gl_FUNC_LSTAT):
7158         Use AC_LIBSOURCES to require lstat.c and lstat.h.
7159         Remove obsolete comment.
7160         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
7161         * m4/xstrtod.m4: Likewise.
7162
7163         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
7164
7165 2005-09-22  Jim Meyering  <jim@meyering.net>
7166
7167         Sync from coreutils.
7168
7169         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
7170
7171         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
7172         the .tm_year member, since otherwise gcc-4.0 would now warn about
7173         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
7174
7175         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
7176         order to avoid an unsuppressible warning from gcc on 64-bit systems.
7177
7178         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
7179         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
7180         when run in a time zone for which daylight savings time is in effect
7181         for the starting date.
7182
7183         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
7184         stop us from restricting permissions of just-created absolute-named
7185         directories.
7186         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
7187         to restore initial working directory.
7188         * lib/mkdir-p.c (make_dir_parents): New parameter:
7189         different_working_dir, to tell caller if/when we change the working
7190         directory and are unable to return to the initial one.
7191         * lib/mkdir-p.h (make_dir_parents): Update prototype.
7192         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
7193         `return false'.  This fixes a bug introduced on 2004-07-30.
7194
7195         * lib/openat.c (fdopendir): Be sure to close the supplied
7196         file descriptor before returning.  This makes our replacement
7197         implementation a little closer to Solaris's, where fdopendir
7198         ties the file descriptor to the returned DIR* pointer.
7199         * lib/openat.c (unlinkat): New function.
7200         * lib/openat.h (unlinkat): Add prototype.
7201         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
7202         (openat_restore_fail): Rename from openat_restore_die.
7203         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
7204
7205         Provide an alternative to exiting immediately upon save_cwd or
7206         restore_cwd failure.  Now, an application can arrange e.g.,
7207         to perform a longjump in that case.
7208         * lib/openat.c: Include dirname.h.
7209         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
7210         (rpl_openat, fdopendir, fstatat): Call openat_save_die
7211         and openat_restore_die rather than calling error directly.
7212         Don't include "error.h" or "exitfail.h"; they're no longer needed.
7213
7214         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
7215         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
7216         define.
7217
7218         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
7219         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
7220                             int utc, int nanoseconds);
7221         Background:
7222         date should not have to allocate a megabyte of virtual memory to
7223         handle a format argument like +%1048575T.  When implemented with
7224         strftime, it must allocate such a buffer, use strftime to fill it
7225         in, print it, then free it.
7226         With fprintftime, it simply prints everything and exits.
7227         With no need for memory allocation, that's one fewer way to fail.
7228         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
7229         optional field width, not before, so we accept %9:z, not %:9z.
7230         (my_strftime): Be sure to use L_('x') for literals.
7231
7232         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
7233         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
7234         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
7235         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
7236         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
7237         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
7238         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
7239         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
7240         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
7241         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
7242         * lib/xgethostname.c, lib/xreadlink.c:
7243         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
7244
7245         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
7246         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
7247         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
7248         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
7249         and don't include <sys/file.h>).
7250
7251 2005-09-22  Eric Blake  <ebb9@byu.net>
7252
7253         Sync from coreutils.
7254
7255         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
7256         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
7257         [!LDAV_DONE]: Avoid unused variable warning.
7258
7259 2005-09-21  Bruno Haible  <bruno@clisp.org>
7260
7261         * lib/unicodeio.h (unicode_to_mb): New declaration.
7262
7263 2005-09-20  Derek Price  <derek@ximbiot.com>
7264
7265         * lib/getaddrinfo.c: Don't include <netdb.h> included from
7266         getaddrinfo.h.
7267
7268 2005-09-20  Bruno Haible  <bruno@clisp.org>
7269
7270         * gnulib-tool: Remove trailing slashes from the values specified for
7271         --source-base, --m4-base, --tests-base, --aux-dir.
7272         Suggested by Simon Josefsson <jas@extundo.com>.
7273
7274 2005-09-20  Bruno Haible  <bruno@clisp.org>
7275
7276         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
7277         func_modules_to_filelist, func_import, func_create_testdir): Make all
7278         sorting results locale-independent, so that gnulib-cache.m4 doesn't
7279         change when gnulib-tool is invoked in a different locale.
7280
7281 2005-09-19  Simon Josefsson  <jas@extundo.com>
7282
7283         * m4/socklen.m4: Fix typo.
7284
7285 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7286
7287         Use a consistent style for including <config.h>.
7288         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
7289         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
7290         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
7291         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
7292         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
7293         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
7294         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
7295         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
7296         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
7297         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
7298         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
7299         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
7300         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
7301         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
7302         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
7303         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
7304         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
7305         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
7306         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
7307         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
7308         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
7309         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
7310         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
7311         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
7312         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
7313         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
7314         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
7315         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
7316         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
7317         lib/xstrtoumax.c, lib/yesno.c:
7318         Standardize inclusion of config.h.
7319         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
7320         lib/inttostr.h:  Removed inclusion of config.h from header files.
7321         * lib/inttostr.c:  Adjusted in-tree users.
7322         * lib/timespec.h: Remove superfluous warning to include config.h.
7323         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
7324         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
7325         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
7326         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
7327         config.h with HAVE_CONFIG_H.
7328
7329 2005-09-19  Jim Meyering  <jim@meyering.net>
7330
7331         * modules/pathmax (License): Change to LGPL.
7332
7333 2005-09-19  Derek Price  <derek@ximbiot.com>
7334
7335         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
7336
7337 2005-09-19  Bruno Haible  <bruno@clisp.org>
7338
7339         * gnulib-tool (import): Provide default for --tests-base.
7340
7341 2005-09-19  Bruno Haible  <bruno@clisp.org>
7342
7343         * doc/quote.texi: New file, extracted from gnulib.texi.
7344         * doc/ctime.texi: New file, extracted from gnulib.texi.
7345         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
7346         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
7347         * doc/gnulib.texi: Include them.
7348
7349 2005-09-18  Bruno Haible  <bruno@clisp.org>
7350
7351         Portability fix.
7352         * gnulib-tool (func_readlink): New function.
7353         (func_ln_if_changed): Use it.
7354
7355 2005-09-18  Bruno Haible  <bruno@clisp.org>
7356
7357         * gnulib-tool: Support --with-tests also with --import.
7358         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
7359         (func_import): Use variables $testsbase and $inctests. Emit a
7360         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
7361         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
7362         SUBDIRS += $testsdir.
7363         (func_create_testdir): Update.
7364
7365 2005-09-18  Bruno Haible  <bruno@clisp.org>
7366
7367         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
7368         instead of $dry_run.
7369         (func_cp_if_changed, func_mv_if_changed): Remove functions.
7370         (func_ln_if_changed): Don't handle dry-run here.
7371         (func_import): In dry-run mode, detect more precisely which actions
7372         would be performed, and don't use "...ing" verbs.
7373
7374 2005-09-18  Bruno Haible  <bruno@clisp.org>
7375
7376         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
7377         (func_import): Use join on two temporary files instead of three nested
7378         loops, in order to determine which files are new or old.
7379
7380 2005-09-18  Bruno Haible  <bruno@clisp.org>
7381
7382         * gnulib-tool (func_import): Comment out code that spits out the
7383         new files with --dry-run.
7384
7385 2005-09-18  Bruno Haible  <bruno@clisp.org>
7386
7387         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
7388
7389 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
7390
7391         * lib/stat-time.h: New file.
7392         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
7393         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
7394         in a different way.
7395         (timespec_cmp): New function.
7396         * lib/utimecmp.c: Include stat-time.h.
7397         (SYSCALL_RESOLUTION): Depend on whether various struct stat
7398         members exist, not on the obsolescent ST_MTIM_NSEC.
7399         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
7400
7401 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
7402
7403         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
7404
7405 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
7406
7407         * MODULES.html.sh (File system functions): Add stat-time.
7408         * modules/stat-time: New file.
7409         * modules/timespec (Files): Remove m4/st_mtim.m4; this
7410         is now done in a different way, by the stat-time module.
7411         * modules/utimecmp (Depends-on): Add stat-time.
7412
7413 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7414
7415         * m4/st_mtim.m4: Remove.  Superseded by...
7416         * m4/stat-time.m4: New file.
7417         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
7418         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
7419
7420 2005-09-15  Derek Price  <derek@ximbiot.com>
7421
7422         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
7423
7424 2005-09-15  Derek Price  <derek@ximbiot.com>
7425
7426         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
7427         * lib/regex_internal.c: Ditto, using this...
7428         (__GNUC_PREREQ): ...new macro.
7429         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
7430         using...
7431         (__GNUC_PREREQ): ...this new macro.
7432
7433         * lib/strstr.h: Include string.h. Define strstr as a macro here.
7434
7435 2005-09-15  Derek Price  <derek@ximbiot.com>
7436             Paul Eggert  <eggert@cs.ucla.edu>
7437
7438         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
7439         changes, consolidating in...
7440         * lib/regex_internal.h: ...this file.
7441
7442 2005-09-13  Jim Meyering  <jim@meyering.net>
7443
7444         * lib/canon-host.c: Filter through gnu indent and reword comments
7445         slightly.
7446         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
7447
7448 2005-09-13  Derek Price  <derek@ximbiot.com>
7449
7450         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
7451         failure.
7452         Reported by Jim Meyering  <jim@meyering.net>.
7453
7454 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7455
7456         * lib/base64.c: Typo.
7457         (base64_encode): Put b64str in initialized data section.
7458
7459 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
7460
7461         Merge glibc and coreutils changes into gnulib, plus a few
7462         extra fixes.
7463         * lib/md5.c: Use #error rather than a string.
7464         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
7465         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
7466         (__attribute__): Define to empty for non recent-GCC.
7467         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
7468         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
7469         Renamed from their non-__ counterparts, with new macros replacing
7470         them if not _LIBC.  Add __THROW attribute.
7471         (rol): Remove.
7472         (struct md5_ctx): Align buffer if using GCC.
7473         * lib/sha1.h (struct sha1_ctx): Likewise.
7474         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
7475         The old name was backwards.
7476         (NOTSWAP): Remove; not used.
7477         (rol): New macro, moved here from md5.h.
7478         (sha1_process_block): Remove a FIXME that doesn't make sense.
7479
7480 2005-09-12  Derek Price  <derek@ximbiot.com>
7481
7482         Return usable errors from canon-host.
7483         * lib/canon-host.h: New file.
7484         * lib/canon-host.c (canon_host): Wrap...
7485         (canon_host_r): ...this new function, which now relies exclusively on
7486         getaddrinfo.
7487         (ch_strerror): New function.
7488         (last_cherror): New global.
7489         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
7490         interface.
7491         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
7492         void *.
7493         (freeaddrinfo): Free ai->ai_canonname when set.
7494
7495 2005-09-12  Derek Price  <derek@ximbiot.com>
7496
7497         Make canon-host require getaddrinfo.
7498         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
7499         AC_LIBSOURCE canon-host.h.  Call...
7500         (gl_PREREQ_CANON_HOST): ...this new function, which requires
7501         gl_GETADDRINFO.
7502         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
7503
7504 2005-09-12  Derek Price  <derek@ximbiot.com>
7505
7506         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
7507         LGPL.
7508         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
7509
7510 2005-09-12  Derek Price  <derek@ximbiot.com>
7511
7512         * lib/gai_strerror.c: Include config.h when available.  Include
7513         getaddrinfo.h before other headers to test interface.
7514         Reported by Larry Jones <lawrence.jones@ugs.com>.
7515
7516 2005-09-12  Derek Price  <derek@ximbiot.com>
7517             Paul Eggert  <eggert@cs.ucla.edu>
7518
7519         * modules/glob (Files): Add glob-libc.h.
7520
7521 2005-09-12  Derek Price  <derek@ximbiot.com>
7522             Paul Eggert  <eggert@cs.ucla.edu>
7523
7524         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
7525         glob_.h, glob-libc.h.
7526         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
7527
7528 2005-09-12  Derek Price  <derek@ximbiot.com>
7529             Paul Eggert  <eggert@cs.ucla.edu>
7530
7531         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
7532         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
7533         protecting things that should be done only in gnulib contexts.
7534         * lib/glob_.h: New file, containing only the glob things needed for
7535         gnulib.
7536         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
7537         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
7538         (glob, globfree, glob_pattern_p): Now defined simply in terms of
7539         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
7540         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
7541         and to respect the namespace rules better.
7542
7543 2005-09-08  Simon Josefsson  <jas@extundo.com>
7544
7545         * modules/socklen: New file.
7546
7547 2005-09-08  Simon Josefsson  <jas@extundo.com>
7548
7549         * m4/socklen.m4: New file.
7550
7551 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7552
7553         * modules/utimens (Files): Add m4/utimbuf.m4, since
7554         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
7555         Reported by Sergey Poznyakoff.
7556
7557 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7558
7559         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
7560         definitions, since that's the preferred style in glibc.
7561         Fix a minor spacing issue, and update copyright notice to match
7562         glibc's.
7563
7564 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7565
7566         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
7567
7568 2005-09-06  Simon Josefsson  <jas@extundo.com>
7569
7570         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
7571         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
7572
7573 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7574
7575         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
7576         warning.
7577
7578 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7579
7580         * config/srclist.txt: Add glibc bug 1302.
7581
7582 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
7583
7584         Change bitset word type from unsigned int to unsigned long int,
7585         as this has better performance on typical 64-bit hosts.
7586         Port bitset code to hosts with unusual word sizes.
7587         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
7588         (build_collating_symbol):
7589         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
7590         argument is a bitset.  This is merely a style issue, but it makes
7591         it clearer that an entire array is expected.
7592         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
7593         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
7594         Port to the case where bitset_word is not the same as unsigned int.
7595         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
7596         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
7597         Likewise.
7598         * lib/regexec.c (check_dst_limits_calc_pos_1,
7599         check_subexp_matching_top):
7600         (build_trtable, group_nodes_into_DFAstates):
7601         Likewise.
7602         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
7603         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
7604         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
7605         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
7606         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
7607         * lib/regcomp.c (optimize_subexps, lower_subexp):
7608         Work even if bitset_word has holes in its bitwise representation.
7609         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
7610         * lib/regexec.c (check_dst_limits_calc_pos_1,
7611         check_subexp_matching_top):
7612         Likewise.
7613         * lib/regex_internal.c (re_string_reconstruct):
7614         Don't assume UCHAR_MAX == 255.
7615         * lib/regex_internal.h (bitset_set_all): Likewise.
7616         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
7617         All uses changed.
7618         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
7619         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
7620         All uses changed.
7621         (BITSET_WORD_MAX): New macro.
7622         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
7623         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
7624         (bitset_empty, bitset_copy):
7625         Prefer sizeof (bitset) to multiplying it out ourselves.
7626         (bitset_not_merge): Remove; unused.
7627         (bitset_contain): Return bool, not unsigned int with one bit on.
7628         All callers changed.
7629         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
7630         alignment than re_node_set; do this by defining a new internal
7631         type struct dests_alloc and using it to allocate memory.
7632
7633 2005-09-05  Bruno Haible  <bruno@clisp.org>
7634
7635         * gnulib-tool (func_import): Fix comparison in handling of symbolic
7636         links.
7637
7638 2005-09-04  Martin Lambers <marlam@marlam.de>
7639
7640         * modules/size_max (Makefile.am): Add size_max.h
7641
7642 2005-09-04  Derek Price  <derek@ximbiot.com>
7643
7644         * gnulib-tool (func_import): Fix reversed $symbolic logic.
7645
7646 2005-09-03  Simon Josefsson  <jas@extundo.com>
7647
7648         * gnulib-tool: Fix typo.
7649
7650 2005-09-03  Simon Josefsson  <jas@extundo.com>
7651
7652         * config/srclist.txt: Add glibc bug 1293.
7653
7654 2005-09-03  Derek Price  <derek@ximbiot.com>
7655
7656         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
7657         From Larry Jones <lawrence.jones@ugs.com>.
7658
7659 2005-09-02  Simon Josefsson  <jas@extundo.com>
7660
7661         * modules/socklen: New file.
7662
7663 2005-09-02  Simon Josefsson  <jas@extundo.com>
7664
7665         * modules/havelib: New module.
7666
7667         * modules/gettext, modules/iconv, modules/lock, modules/readline:
7668         Use havelib.
7669
7670 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
7671
7672         Check for arithmetic overflow when calculating sizes, to prevent
7673         some buffer-overflow issues.  These patches are conservative, in the
7674         sense that when I couldn't determine whether an overflow was possible,
7675         I inserted a run-time check.
7676         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
7677         macros.
7678         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
7679         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
7680         (re_xnrealloc, re_x2nrealloc): New inline functions.
7681         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
7682         parse_bracket_exp):
7683         (build_equiv_class, build_charclass): Check for arithmetic overflow
7684         in size expression calculations.
7685         * lib/regex_internal.c (re_string_realloc_buffers):
7686         (build_wcs_upper_buffer, re_node_set_add_intersect):
7687         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
7688         (re_dfa_add_node, register_state): Likewise.
7689         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
7690         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
7691         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
7692         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
7693
7694 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
7695
7696         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
7697         m4/ulonglong.m4.  Problem reported by Martin Lambers.
7698
7699 2005-09-02  Bruno Haible  <bruno@clisp.org>
7700
7701         Support for lib vs. lib64 distinction on biarch platforms.
7702         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
7703         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
7704         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
7705
7706 2005-09-02  Bruno Haible  <bruno@clisp.org>
7707
7708         * gnulib-tool (import): In the other first-use case, provide defaults
7709         as well.
7710
7711 2005-09-02  Bruno Haible  <bruno@clisp.org>
7712
7713         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
7714         patches not yet found in the latest gettext release.
7715
7716 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7717
7718         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
7719         to avoid a collision with bits/local_lim.h in glibc.
7720         All uses changed.  Problem reported by Dmitry V. Levin in
7721         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
7722
7723         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
7724         bugs in int versus size_t comparisons.
7725         (re_string_context_at): Fix bug where the code assumed that
7726         Idx is signed.
7727
7728         Use bool where appropriate.
7729         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
7730         All callers changed.
7731         (calc_eclosure_iter): Likewise, for ROOT arg.
7732         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
7733         (build_charclass_op): Likewise, for NON_MATCH arg.
7734         * lib/regex_internal.c (re_string_allocate, re_string_construct):
7735         (re_string_construct_common): Likewise, for ICASE arg.
7736         * lib/regexec.c (re_search_2_stub, re_search_stub):
7737         Likewise, for RET_LEN arg.
7738         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
7739         (set_regs): Likewise, for FL_BACKTRACK arg.
7740         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
7741         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
7742         (calc_eclosure_iter, parse_bracket_exp):
7743         Use bool for internal variables that are booleans.
7744         * lib/regexec.c (re_search_internal, check_matching,
7745         proceed_next_node):
7746         (set_regs, build_sifted_states, sift_states_bkref):
7747         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
7748         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
7749         (find_collation_sequence_value):
7750         Likewise.
7751         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
7752         (re_node_set_compare):
7753         Return bool, not int. All callers changed.
7754         * lib/regexec.c (check_halt_node_context, check_dst_limits):
7755         (build_trtable, check_node_accept): Likewise.
7756         * lib/regex_internal.h: Include stdbool.h.
7757
7758         Fix bugs uncovered when converting to bool.
7759         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
7760         failure instead of charging ahead blindly.
7761         * lib/regex_internal.c (register_state): Likewise.
7762         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
7763         for freeing internal storage.
7764         (group_nodes_into_DFA_states): Use unsigned int, not int, for
7765         bitset pieces used as boolean, to avoid undefined behavior
7766         on hosts that do int overflow checking.
7767
7768 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7769
7770         * config/srclist.txt: Add glibc bugs 1285-1287.
7771
7772 2005-09-01  Jim Meyering  <jim@meyering.net>
7773
7774         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
7775         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
7776         Require gl_STAT_MACROS, too.
7777
7778 2005-09-01  Bruno Haible  <bruno@clisp.org>
7779
7780         * gnulib-tool (import): In the first-use case, provide defaults.
7781
7782 2005-09-01  Bruno Haible  <bruno@clisp.org>
7783
7784         * gnulib-tool (func_import): Remove the .tmp files.
7785
7786 2005-09-01  Bruno Haible  <bruno@clisp.org>
7787
7788         * gnulib-tool (func_import): Fix handling of symbolic links.
7789
7790 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7791
7792         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
7793         old glibc regex code mishandles strings longer than 2**31 bytes.
7794         This patch fixes this when the regex code is used in gnulib
7795         (i.e., outside glibc).
7796
7797         This patch should not affect the use of the regex code inside
7798         glibc.  No doubt this problem also needs to be handled for glibc
7799         as well, but the result will be an incompatible change to the
7800         glibc ABI, and the old ABI will have to be supported too.  That
7801         can be the the subject for another patch.
7802
7803         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
7804         governing whether the rest of this patch is active.  By default,
7805         the macro is disabled and the patch has no effect.
7806         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
7807         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
7808         (struct re_pattern_buffer, re_search, re_search_2, re_match):
7809         (re_match_2, re_set_registers): Use the new types.
7810         * lib/regex_internal.h (Idx, re_hashval_t): New types.
7811         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
7812         New macros.
7813         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
7814         (re_string_context_at, bin_tree_t, re_dfastate_t):
7815         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
7816         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
7817         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
7818         (re_string_char_size_at, re_string_wchar_at):
7819         (re_string_elem_size_at):
7820         Use the new types and macros to port to 64-bit hosts.
7821         Use unsigned types for internal values, so that the code
7822         mostly works even for arrays larger than SSIZE_MAX.
7823         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
7824         (search_duplicated_node, calc_eclosure_iter, fetch_number):
7825         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
7826         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
7827         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
7828         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
7829         (calc_inveclosure, parse_dup_op, build_range_exp):
7830         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
7831         (fetch_number, create_token_tree, mark_opt_subexp):
7832         Likewise.
7833         * lib/regex_internal.c (re_string_construct_common,
7834         create_ci_newstate):
7835         (create_cd_newstate, re_string_allocate, re_string_construct):
7836         (re_string_realloc_buffers, build_wcs_upper_buffer):
7837         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
7838         (re_string_reconstruct, re_string_peek_byte_case):
7839         (re_string_fetch_byte_case, re_string_context_at):
7840         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
7841         (re_node_set_init_copy, re_node_set_add_intersect):
7842         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
7843         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
7844         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
7845         (re_acquire_state, re_acquire_state_context, register_state):
7846         Likewise.
7847         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
7848         search_cur_bkref_entry):
7849         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
7850         (re_search_internal, re_search_2_stub, re_search_stub)
7851         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
7852         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
7853         (update_cur_sifted_state, check_dst_limits):
7854         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
7855         (check_subexp_limits, sift_states_bkref, merge_state_array):
7856         (check_subexp_matching_top, get_subexp, get_subexp_sub):
7857         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
7858         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
7859         (expand_bkref_cache, check_node_accept_bytes):
7860         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
7861         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
7862         (acquire_init_state_context, check_halt_node_context):
7863         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
7864         (sift_states_backward, clean_state_log_if_needed):
7865         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
7866         (find_recover_state, transit_state_sb, transit_state_mb):
7867         (transit_state_bkref, build_trtable, match_ctx_clean):
7868         Likewise.
7869         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
7870         to work around an assumption that REG_MISSING is negative.
7871
7872         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
7873         (seek_collating_symbol_entry) [defined _LIBC]:
7874         (lookup_collation_sequence_value) [defined _LIBC]:
7875         (build_range_exp, build_collating_symbol) [defined _LIBC]:
7876         Use prototypes rather than old-style function definitions.
7877         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
7878         (transit_state_sb) [0]:
7879         (find_collation_sequence_value) [defined _LIBC]: Likewise.
7880
7881         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
7882         rm_eo.
7883
7884         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
7885         (optimize_subexps, lower_subexp):
7886         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
7887         since the signed shift might overflow.  Use 1u<<31 instead.
7888         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
7889         Likewise.
7890         * lib/regexec.c (check_dst_limits_calc_pos_1,
7891         check_subexp_matching_top): Likewise.
7892
7893         * lib/regcomp.c (optimize_subexps, lower_subexp):
7894         Use CHAR_BIT rather than 8, for clarity.
7895         * lib/regexec.c (check_dst_limits_calc_pos_1):
7896         (check_subexp_matching_top): Likewise.
7897         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
7898         have to worry about portability issues when shifting it left.
7899         Remove no-longer-needed test for table_size > 0.
7900         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
7901         in a word, as the resulting behavior is undefined.
7902         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
7903         in one case, a <= should have been an <, and in another case the
7904         whole test was missing.
7905         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
7906         the standard name CHAR_BIT.
7907         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
7908         this is not true on one's complement and signed-magnitude hosts.
7909
7910         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
7911         next_last_offset.
7912         (struct re_dfa_t): Remove unused member states_alloc.
7913         * lib/regcomp.c (init_dfa): Don't initialize unused members.
7914
7915 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7916
7917         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
7918         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
7919         and large-file glibc and in 32-bit large-file Solaris.
7920
7921 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7922
7923         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
7924         lengths fit in regoff_t; this isn't true if regoff_t is the same
7925         width as size_t.
7926         * lib/regex.c (re_search_internal): 5th arg is LAST_START
7927         (= START + RANGE) instead of RANGE.  This avoids overflow
7928         problems when regoff_t is the same width as size_t.
7929         All callers changed.
7930         (re_search_2_stub): Check for overflow when adding the
7931         sizes of the two strings.
7932         (re_search_stub): Check for overflow when adding START
7933         to RANGE; if it occurs, substitute the extreme value.
7934
7935 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7936
7937         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
7938
7939 2005-08-31  Jim Meyering  <jim@meyering.net>
7940
7941         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
7942         a pointer-to-const.
7943         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
7944         (register_state): Likewise.
7945         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
7946         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
7947         (group_nodes_into_DFAstates): Likewise.
7948
7949 2005-08-31  Jim Meyering  <jim@meyering.net>
7950
7951         * check-module: Add a FIXME comment.
7952
7953 2005-08-31  Eric Blake  <ebb9@byu.net>
7954
7955         * modules/unistd-safer (Files): Add unistd--.h.
7956         * modules/stdio-safer (Files): Add stdio--.h.
7957
7958 2005-08-31  Derek Price  <derek@ximbiot.com>
7959
7960         * lib/getdelim.c (getdelim): Return EOF on EOF.
7961         Reported by Larry Jones <lawrence.jones@ugs.com>.
7962
7963 2005-08-31  Bruno Haible  <bruno@clisp.org>
7964
7965         Avoid unnecessary diffs in the generated lib/Makefile.am.
7966         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
7967         the generated files.
7968         (func_import): Don't set cmd.
7969
7970 2005-08-31  Bruno Haible  <bruno@clisp.org>
7971
7972         * lib/strstr.c: Include <stddef.h>, for NULL.
7973         * lib/strcasestr.c: Likewise.
7974         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
7975
7976 2005-08-31  Bruno Haible  <bruno@clisp.org>
7977
7978         * gnulib-tool: New option --macro-prefix.
7979         (func_import): Use macro_prefix.
7980         (import): Handle option --macro-prefix.
7981
7982 2005-08-31  Bruno Haible  <bruno@clisp.org>
7983
7984         * gnulib-tool (import): Rename most ac_* variables to cached_*.
7985         Also use new variables cached_lgpl, cached_libtool.
7986
7987 2005-08-31  Bruno Haible  <bruno@clisp.org>
7988
7989         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
7990         always instantiating them.
7991
7992 2005-08-31  Bruno Haible  <bruno@clisp.org>
7993
7994         * gnulib-tool (func_import): Read the previous cached settings
7995         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
7996         earlier added by gnulib but are now dropped. Warn when a gnulib file
7997         overwrites a non-gnulib file.
7998
7999 2005-08-31  Bruno Haible  <bruno@clisp.org>
8000
8001         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
8002         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
8003         projects that don't keep autogenerated files in CVS. Put into
8004         actioncmd only the specified modules, not the transitive closure.
8005
8006 2005-08-31  Bruno Haible  <bruno@clisp.org>
8007
8008         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
8009         Create directories that shall be filled.
8010         (import): Don't look for gl_* macros in configure.ac. Recurse across
8011         all directories containing a gnulib-cache.m4 files, if meaningful.
8012
8013 2005-08-31  Bruno Haible  <bruno@clisp.org>
8014
8015         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
8016         (import): Set seen_libtool when we see gl_LIBTOOL.
8017
8018 2005-08-31  Bruno Haible  <bruno@clisp.org>
8019
8020         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
8021         declaration macro definitions from generated gnulib.m4.
8022
8023 2005-08-30  "Oskar Liljeblad" <oskar@osk.mine.nu>
8024
8025         * lib/iconvme.h: Add prototype for iconv_alloc.
8026
8027 2005-08-29  Simon Josefsson  <jas@extundo.com>
8028
8029         * lib/iconvme.c: Fix errno.
8030
8031 2005-08-29  Bruno Haible  <bruno@clisp.org>
8032
8033         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
8034         that it works when the directory contains spaces.
8035
8036 2005-08-29  Bruno Haible  <bruno@clisp.org>
8037
8038         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
8039
8040 2005-08-29  Bruno Haible  <bruno@clisp.org>
8041
8042         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
8043         Emit more advice.
8044
8045 2005-08-29  Bruno Haible  <bruno@clisp.org>
8046         and Stepan Kasal  <kasal@ucw.cz>
8047
8048         * check-module: If more parameters are given, check each of them
8049         separately; add more exceptions, as noted by Jim Meyering.
8050         (check_module): New procedure.
8051         (%exempt_header): Now contains all exceptions.
8052
8053 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
8054
8055         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
8056
8057 2005-08-29  "Oskar Liljeblad" <oskar@osk.mine.nu>
8058
8059         * lib/iconvme.c: Split iconv_string into iconv_alloc.
8060
8061 2005-08-28  Bruno Haible  <bruno@clisp.org>
8062
8063         * m4/gnulib-tool.m4: New file.
8064
8065 2005-08-27  Jim Meyering  <jim@meyering.net>
8066
8067         * modules/unistd-safer (Files): Add pipe-safer.c.
8068         * modules/fcntl-safer (Files): Add creat-safer.c.
8069
8070 2005-08-27  Jim Meyering  <jim@meyering.net>
8071
8072         * m4/stdlib-safer.m4: New file.  From coreutils.
8073         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
8074         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
8075         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
8076         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
8077         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
8078
8079 2005-08-27  Jim Meyering  <jim@meyering.net>
8080
8081         * lib/fopen-safer.c: Merge minor changes from coreutils.
8082         * lib/dup-safer.c: Likewise.
8083         * lib/fd-safer.c: Likewise.
8084
8085         Merge from coreutils.
8086         * lib/stdio--.h: New file.
8087         * lib/stdlib--.h: New file.
8088         * lib/mkstemp-safer.c: New file.
8089
8090         GNU tar needs these.
8091         * lib/pipe-safer.c: New file.
8092         * lib/creat-safer.c: New file.
8093         * lib/fcntl--.h (creat): Define to creat_safer.
8094         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
8095         * lib/unistd--.h (pipe): Define to pipe_safer.
8096         * lib/unistd-safer.h: Declare pipe_safer.
8097
8098 2005-08-26  Simon Josefsson  <jas@extundo.com>
8099
8100         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
8101         Haible <bruno@clisp.org>.
8102
8103 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
8104
8105         * lib/regex_internal.h: Remove all references to
8106         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
8107         or better.
8108         (bitset_not, bitset_merge, bitset_not_merge):
8109         (bitset_mask, re_string_allocate, re_string_construct):
8110         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
8111         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
8112         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
8113         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
8114         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
8115         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
8116         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
8117         (re_acquire_state_context):
8118         Remove unnecessary forward decls.
8119         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
8120         Put __attribute at function definition,
8121         now that the function decl has been removed.
8122         * lib/regex_internal.c (re_string_peek_byte_case):
8123         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
8124         Likewise.
8125
8126 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
8127
8128         * m4/regex.m4: Add AC_PREREQ(2.50).
8129         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
8130
8131 2005-08-25  Simon Josefsson  <jas@extundo.com>
8132
8133         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
8134         __fsetlocking.
8135
8136 2005-08-25  Simon Josefsson  <jas@extundo.com>
8137
8138         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
8139         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
8140         GLIBC specific code.
8141
8142 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8143
8144         Make regex safe for g++.  This fixes one real bug (an "err"
8145         that should have been "*err").  g++ problem reported by
8146         Sam Steingold.
8147         * lib/regex_internal.h (re_calloc): New macro, consistent with
8148         re_malloc etc.  All callers of calloc changed to use re_calloc.
8149         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
8150         not int.  All callers changed.
8151         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
8152         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
8153         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
8154         (find_recover_state): Change "err" to "*err"; this fixes what
8155         appears to be a real bug.
8156         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
8157         versus int.
8158
8159 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8160
8161         * modules/regex (Depends-on): Add malloc, since the code
8162         assumes that !malloc(0) means failure.
8163
8164 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8165
8166         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
8167
8168         alloca modernization/simplification for regex.
8169         * lib/regex.c: Remove portability cruft for alloca.  This no longer
8170         needs to be at the start of the file, and can be moved into
8171         regex_internal.h and simplified.
8172         * lib/regex_internal.h: Include <alloca.h>.
8173         (__libc_use_alloca) [!defined _LIBC]: New macro.
8174         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
8175         now works outside glibc.
8176
8177 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8178
8179         * config/srclist.txt: Add glibc bugs 1241, 1245.
8180
8181 2005-08-25  Jim Meyering  <jim@meyering.net>
8182
8183         * lib/open-safer.c: Include <config.h>.
8184         Otherwise, we'd lose LARGEFILE support in any file using
8185         e.g. "fcntl--.h"
8186
8187 2005-08-25  Bruno Haible  <bruno@clisp.org>
8188
8189         * m4/minmax.m4: Require autoconf 2.52.
8190         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
8191         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
8192         alternatives of translit over the alphabet.
8193         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
8194
8195 2005-08-24  Simon Josefsson  <jas@extundo.com>
8196
8197         * tests/test-getpass.c: New file.
8198
8199 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8200
8201         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
8202         for GNU regex features.
8203
8204 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8205
8206         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
8207         * lib/regex.h (regerror): Likewise.
8208
8209         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
8210         requires this.  (The code never needed it.)
8211
8212         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
8213         All uses of recently-renamed identifiers changed to use the new,
8214         POSIX-compliant names.  The code will build and run just fine
8215         without these changes, but it's better to eat our own dog food
8216         and use the standard-conforming names.
8217
8218         * lib/regex.h: Fix a multitude of POSIX name space violations.
8219         These changes have an effect only for programs that define
8220         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
8221         do not change anything for programs compiled in the normal way.
8222         Also, there is no effect on the ABI.
8223
8224         (_REGEX_SOURCE): New macro.
8225         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
8226         defined and _GNU_SOURCE is not; this fixes a name space violation.
8227
8228         Rename the following macros to obey POSIX requirements.
8229         The old names are still visible as macros if _REGEX_SOURCE is defined.
8230         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
8231         RE_BACKSLASH_ESCAPE_IN_LISTS.
8232         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
8233         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
8234         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
8235         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
8236         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
8237         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
8238         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
8239         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
8240         (REG_INTERVALS): renamed from RE_INTERVALS.
8241         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
8242         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
8243         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
8244         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
8245         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
8246         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
8247         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
8248         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
8249         RE_UNMATCHED_RIGHT_PAREN_ORD.
8250         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
8251         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
8252         (REG_DEBUG): renamed from RE_DEBUG.
8253         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
8254         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
8255         unusual, since we can't clash with the POSIX REG_ICASE.
8256         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
8257         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
8258         (REG_NO_SUB): renamed from RE_NO_SUB.
8259         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
8260         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
8261         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
8262         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
8263         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
8264         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
8265         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
8266         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
8267         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
8268         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
8269         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
8270         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
8271         RE_SYNTAX_POSIX_MINIMAL_BASIC.
8272         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
8273         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
8274         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
8275         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
8276         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
8277         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
8278         (REG_FIXED): Renamed from REGS_FIXED.
8279         (REG_NREGS): Renamed from RE_NREGS.
8280
8281         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
8282         of other REG_* macros, since POSIX says the user is allowed to
8283         #undef these macros selectively.
8284
8285         (reg_errcode_t): Update comment stating what other tables need
8286         to be consistent.
8287
8288         Rename the following enum values to obey POSIX requirements.
8289         The old names are still visible as macros.
8290         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
8291         is not defined, since GNU is supposed to be a superset of POSIX as
8292         much as possible, and since we want reg_errcode_t to be a signed
8293         type for implementation consistency.
8294         (_REG_NOERROR): Renamed from REG_NOERROR.
8295         (_REG_NOMATCH): Renamed from REG_NOMATCH.
8296         (_REG_BADPAT): Renamed from REG_BADPAT.
8297         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
8298         (_REG_ECTYPE): Renamed from REG_ECTYPE.
8299         (_REG_EESCAPE): Renamed from REG_EESCAPE.
8300         (_REG_ESUBREG): Renamed from REG_ESUBREG.
8301         (_REG_EBRACK): Renamed from REG_EBRACK.
8302         (_REG_EPAREN): Renamed from REG_EPAREN.
8303         (_REG_EBRACE): Renamed from REG_EBRACE.
8304         (_REG_BADBR): Renamed from REG_BADBR.
8305         (_REG_ERANGE): Renamed from REG_ERANGE.
8306         (_REG_ESPACE): Renamed from REG_ESPACE.
8307         (_REG_BADRPT): Renamed from REG_BADRPT.
8308         (_REG_EEND): Renamed from REG_EEND.
8309         (_REG_ESIZE): Renamed from REG_ESIZE.
8310         (_REG_ERPAREN): Renamed from REG_ERPAREN.
8311         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
8312         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
8313         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
8314         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
8315
8316         (_REG_RE_NAME, _REG_RM_NAME): New macros.
8317         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
8318         changed.  But support the old name if the new one is not defined
8319         and if _REGEX_SOURCE.
8320
8321         Change the following member names in struct re_pattern_buffer.
8322         The old names are still supported if !_REGEX_SOURCE.
8323         The new names are always supported, regardless of _REGEX_SOURCE.
8324         (re_buffer): Renamed from buffer.
8325         (re_allocated): Renamed from allocated.
8326         (re_used): Renamed from used.
8327         (re_syntax): Renamed from syntax.
8328         (re_fastmap): Renamed from fastmap.
8329         (re_translate): Renamed from translate.
8330         (re_can_be_null): Renamed from can_be_null.
8331         (re_regs_allocated): Renamed from regs_allocated.
8332         (re_fastmap_accurate): Renamed from fastmap_accurate.
8333         (re_no_sub): Renamed from no_sub.
8334         (re_not_bol): Renamed from not_bol.
8335         (re_not_eol): Renamed from not_eol.
8336         (re_newline_anchor): Renamed from newline_anchor.
8337
8338         Change the following member names in struct re_registers.
8339         The old names are still supported if !_REGEX_SOURCE.
8340         The new names are always supported, regardless of _REGEX_SOURCE.
8341         (rm_num_regs): Renamed from num_regs.
8342         (rm_start): Renamed from start.
8343         (rm_end): Renamed from end.
8344
8345         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
8346         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
8347         Prepend __ to parameter names.
8348
8349         Undo yesterday's changes.
8350
8351 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8352
8353         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
8354         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
8355         lib/regex.c.
8356
8357 2005-08-24  Jim Meyering  <jim@meyering.net>
8358
8359         Sync from coreutils.
8360         * m4/fcntl-safer.m4: New file.
8361
8362         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
8363         and object files for this module.
8364
8365 2005-08-24  Jim Meyering  <jim@meyering.net>
8366
8367         Sync from coreutils.
8368         * lib/fcntl--.h, fcntl-safer.h, open-safer.c: New files.
8369
8370 2005-08-24  Jim Meyering  <jim@meyering.net>
8371
8372         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
8373         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
8374
8375 2005-08-24  Jim Meyering  <jim@meyering.net>
8376
8377         * modules/fcntl-safer: New module.
8378         * modules/fts (Depends-on): Add fcntl-safer.
8379         * MODULES.html.sh (File descriptor based Input/Output):
8380         Add fcntl-safer.
8381
8382 2005-08-24  Bruno Haible  <bruno@clisp.org>
8383
8384         Support for unit test modules.
8385         * modules/README: Mention tests modules.
8386         * modules/TEMPLATE-TESTS: New file.
8387         * gnulib-tool: New options --extract-tests-module, --with-tests and
8388         --tests-base (unused for the moment).
8389         (testsbase, inctests): New variables.
8390         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
8391         (func_verify_module): Exclude TEMPLATE-TESTS.
8392         (func_verify_nontests_module, func_verify_tests_module): New functions.
8393         (func_get_dependencies): Add implicit dependency for tests modules.
8394         (func_get_tests_module): New function.
8395         (func_modules_transitive_closure): When --with-tests was specified,
8396         include the unit tests as well, unless explicitly avoided.
8397         (func_emit_lib_Makefile_am): Ignore the tests modules here.
8398         (func_emit_tests_Makefile_am): New function.
8399         (func_create_testdir): When --with-tests was specified, emit a
8400         tests/ directory.
8401         * MODULES.html.sh (Future developments): Update.
8402
8403 2005-08-24  Bruno Haible  <bruno@clisp.org>
8404
8405         * modules/tls-tests: New file.
8406         * tests/test-tls.c: New file, from GNU gettext.
8407
8408 2005-08-24  Bruno Haible  <bruno@clisp.org>
8409
8410         * modules/lock-tests: New file.
8411         * tests/test-lock.c: New file, from GNU gettext.
8412
8413 2005-08-24  Bruno Haible  <bruno@clisp.org>
8414
8415         * lib/lock.h: Add multiple inclusion guard.
8416         * lib/tls.h: Add multiple inclusion guard.
8417
8418 2005-08-24  Bruno Haible  <bruno@clisp.org>
8419
8420         * gnulib-tool: Add support for the --aux-dir option to
8421         --create-testdir, --create-megatestdir, --test, --megatest.
8422         (func_create_testdir, func_create_megatestdir): Optionally emit a
8423         AC_CONFIG_AUX_DIR directive.
8424         (create-testdir, create-megatestdir, test, megatest): Provide a
8425         default value for $auxdir.
8426
8427 2005-08-24  Bruno Haible  <bruno@clisp.org>
8428
8429         * gnulib-tool (import): Use compound statement instead of subshell
8430         where possible.
8431
8432 2005-08-24  Bruno Haible  <bruno@clisp.org>
8433
8434         * gnulib-tool (import): Change --aux-dir default to "build-aux".
8435
8436 2005-08-24  Bruno Haible  <bruno@clisp.org>
8437
8438         * gnulib-tool (func_version): Update.
8439
8440 2005-08-24  Bruno Haible  <bruno@clisp.org>
8441
8442         * gnulib-tool (func_import, func_create_testdir,
8443         func_create_megatestdir): Quote all autoconf macro arguments.
8444
8445 2005-08-24  Bruno Haible  <bruno@clisp.org>
8446
8447         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
8448         option --force, because --force causes the aclocal.m4 of each
8449         subdirectory to be newer than the corresponding config.h.in.
8450
8451 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8452
8453         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
8454         All contents moved to gl_REGEX.
8455         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
8456         assume that it does.
8457
8458 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8459
8460         * lib/regex.h (REG_NOSYS)
8461         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
8462         Define, since POSIX requires it as of 2001.
8463         (_REG_ENOSYS)
8464         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
8465         New private symbol, used to keep the enum signed in all cases.
8466         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
8467         Youngman in
8468         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
8469
8470         * lib/regex_internal.c (re_string_skip_chars, register_state):
8471         (calc_state_hash):
8472         Remove forward decls; no longer needed now that we use prototypes.
8473         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
8474         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
8475         (clean_state_log_if_needed): Likewise.
8476
8477 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8478
8479         * config/srclist.txt: Add glibc bugs 1231-1233.
8480
8481 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8482
8483         Fix problems reported by Sam Steingold in
8484         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
8485         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
8486         assumed that reg_errcode_t is a signed type, which is not
8487         necessarily true if _XOPEN_SOURCE is not defined.
8488         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
8489         since some compilers warn about it otherwise.
8490
8491 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8492
8493         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
8494         (init_word_char, create_initial_state, duplicate_node_closure):
8495         (fetch_token, peek_token_bracket, build_range_exp):
8496         (build_collating_symbol): Remove forward decls; no longer needed
8497         now that we use prototypes.
8498
8499         * lib/regcomp.c:
8500         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
8501         (re_compile_fastmap_iter, regcomp, regerror, regfree):
8502         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
8503         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
8504         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
8505         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
8506         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
8507         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
8508         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
8509         (build_range_exp, build_collating_symbol, parse_bracket_exp):
8510         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
8511         (build_charclass, build_charclass_op, fetch_number, create_tree):
8512         (create_token_tree, mark_opt_subexp, duplicate_tree):
8513         Use prototypes rather than old-style definitions.
8514
8515         * lib/regex_internal.c:
8516         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
8517         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
8518         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
8519         (re_string_reconstruct, re_string_peek_byte_case):
8520         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
8521         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
8522         (re_node_set_init_copy, re_node_set_add_intersect):
8523         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
8524         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
8525         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
8526         (re_acquire_state, re_acquire_state_context, register_state):
8527         (create_ci_newstate, create_cd_newstate, free_state):
8528         Likewise.
8529         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
8530         re_search_2):
8531         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
8532         (re_search_internal, prune_impossible_nodes):
8533         (acquire_init_state_context, check_matching, static):
8534         (check_halt_node_context, check_halt_state_context, proceed_next_node):
8535         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
8536         (update_regs, sift_states_backward, build_sifted_states):
8537         (clean_state_log_if_needed, merge_state_array):
8538         (update_cur_sifted_state, add_epsilon_src_nodes):
8539         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
8540         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
8541         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
8542         (find_recover_state, check_subexp_matching_top, transit_state_mb):
8543         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
8544         (check_arrival, check_arrival_add_next_nodes):
8545         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
8546         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
8547         (check_node_accept_bytes, check_node_accept, extend_buffers):
8548         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
8549         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
8550         (sift_ctx_init):
8551         Likewise.
8552
8553         * lib/regex_internal.h:
8554         (re_string_allocate, re_string_construct, re_string_reconstruct):
8555         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
8556         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
8557         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
8558         (re_string_context_at, re_string_peek_byte_case):
8559         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
8560         is defined, since we now use prototypes always.
8561
8562         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
8563         C89 or better.  All uses removed.
8564
8565 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8566
8567         * config/srclist.txt: Add glibc bugs 1220-1227.
8568
8569 2005-08-20  Jim Meyering  <jim@meyering.net>
8570
8571         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
8572         of unused local, dfa.
8573
8574 2005-08-20  Bruno Haible  <bruno@clisp.org>
8575
8576         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
8577
8578 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8579
8580         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
8581         (re_node_set_insert_last, re_dfa_add_node):
8582         Rename local variables to avoid GCC shadowing warnings.
8583
8584 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8585
8586         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
8587         [defined lint]: Suppress bogus uninitialized-variable warnings.
8588
8589         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
8590         and let the caller return REG_ESPACE if out of space.  This
8591         removes an uninitialied-variable warning with GCC 4.0.1, and also
8592         avoids taking the address of a local variable.  All callers
8593         changed.
8594
8595 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8596
8597         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
8598         $LIBCSRC/posix/regexec.c.
8599         Add glibc bug 1217 for regcomp.c.
8600
8601 2005-08-19  Jim Meyering  <jim@meyering.net>
8602
8603         * lib/regexec.c (proceed_next_node): Redo local variables to
8604         avoid GCC shadowing warnings.
8605
8606 2005-08-18  Bruno Haible  <bruno@clisp.org>
8607
8608         * lib/strstr.c (strstr): Fix return value in multibyte case.
8609         * lib/strcasestr.c (strcasestr): Likewise.
8610
8611 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8612
8613         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
8614
8615 2005-08-17  Jim Meyering  <jim@meyering.net>
8616
8617         Make the %s format (seconds since the epoch) work for a negative
8618         number and when used with a zero-padded field width, e.g. %015s.
8619
8620         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
8621         label so that it precedes the code to set `digits'.  Otherwise,
8622         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
8623         print `00-22'.  Now, it prints `-0022', as it should.
8624
8625 2005-08-17  Bruno Haible  <bruno@clisp.org>
8626
8627         * modules/strstr (Files): Add m4/mbrtowc.m4.
8628         (Depends-on): Add mbuiter.
8629
8630 2005-08-17  Bruno Haible  <bruno@clisp.org>
8631
8632         * modules/strcasestr: New file.
8633         * MODULES.html.sh (String handling, based on ANSI C 89): Add
8634         strcasestr.
8635
8636 2005-08-17  Bruno Haible  <bruno@clisp.org>
8637
8638         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
8639
8640 2005-08-17  Bruno Haible  <bruno@clisp.org>
8641
8642         * modules/mbuiter: New file.
8643         * MODULES.html.sh (Extended multibyte and wide character utilities):
8644         Add mbuiter.
8645
8646 2005-08-17  Bruno Haible  <bruno@clisp.org>
8647
8648         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
8649         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
8650
8651 2005-08-17  Bruno Haible  <bruno@clisp.org>
8652
8653         * m4/strcasestr.m4: New file.
8654
8655 2005-08-17  Bruno Haible  <bruno@clisp.org>
8656
8657         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
8658         * lib/strstr.c: Completely rewritten, with multibyte locale support.
8659
8660 2005-08-17  Bruno Haible  <bruno@clisp.org>
8661
8662         * lib/strcasestr.h: New file.
8663         * lib/strcasestr.c: New file.
8664
8665 2005-08-17  Bruno Haible  <bruno@clisp.org>
8666
8667         * lib/strcasecmp.c: Use mbuiter.h.
8668
8669 2005-08-17  Bruno Haible  <bruno@clisp.org>
8670
8671         * lib/mbuiter.h: New file.
8672
8673 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
8674
8675         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
8676         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
8677         and gl_GETOPT are both invoked via different paths (as happens
8678         with GNU tar CVS because it uses both argp and getopt), the former
8679         wins.
8680
8681 2005-08-16  Bruno Haible  <bruno@clisp.org>
8682
8683         * modules/tls: New file.
8684         * MODULES.html.sh (Multithreading): Add tls.
8685
8686 2005-08-16  Bruno Haible  <bruno@clisp.org>
8687
8688         * modules/strnlen1: New file.
8689         * MODULES.html.sh (String handling): Add strnlen1.
8690
8691 2005-08-16  Bruno Haible  <bruno@clisp.org>
8692
8693         * modules/strcase (Files): Add m4/mbrtowc.m4.
8694         (Depends-on): Add strnlen1, mbchar.
8695
8696 2005-08-16  Bruno Haible  <bruno@clisp.org>
8697
8698         * modules/mbiter: New file.
8699         * MODULES.html.sh (Extended multibyte and wide character utilities):
8700         Add mbiter.
8701
8702 2005-08-16  Bruno Haible  <bruno@clisp.org>
8703
8704         * modules/mbfile: New file.
8705         * MODULES.html.sh (Extended multibyte and wide character utilities):
8706         Add mbfile.
8707
8708 2005-08-16  Bruno Haible  <bruno@clisp.org>
8709
8710         * modules/mbchar: New file.
8711         * MODULES.html.sh (Extended multibyte and wide character utilities):
8712         New section.
8713
8714 2005-08-16  Bruno Haible  <bruno@clisp.org>
8715
8716         * m4/tls.m4: New file, from GNU gettext.
8717
8718 2005-08-16  Bruno Haible  <bruno@clisp.org>
8719
8720         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
8721         always.
8722         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
8723
8724 2005-08-16  Bruno Haible  <bruno@clisp.org>
8725
8726         * m4/mbiter.m4: New file.
8727
8728 2005-08-16  Bruno Haible  <bruno@clisp.org>
8729
8730         * m4/mbfile.m4: New file.
8731
8732 2005-08-16  Bruno Haible  <bruno@clisp.org>
8733
8734         * m4/mbchar.m4: New file.
8735
8736 2005-08-16  Bruno Haible  <bruno@clisp.org>
8737
8738         * lib/tls.h: New file, from GNU gettext.
8739         * lib/tls.c: New file, from GNU gettext.
8740
8741 2005-08-16  Bruno Haible  <bruno@clisp.org>
8742
8743         * lib/strnlen1.h: New file.
8744         * lib/strnlen1.c: New file.
8745
8746 2005-08-16  Bruno Haible  <bruno@clisp.org>
8747
8748         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
8749         (mbi_init): Update.
8750         (mbi_avail, mbi_advance): Let the iteration end before the terminating
8751         NUL byte, not after it.
8752
8753 2005-08-16  Bruno Haible  <bruno@clisp.org>
8754
8755         * lib/strcase.h (strcasecmp): Add note in comments.
8756         * lib/strncasecmp.c: Use code from strcasecmp.c.
8757         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
8758         (strcasecmp): Work correctly in multibyte locales.
8759
8760 2005-08-16  Bruno Haible  <bruno@clisp.org>
8761
8762         * lib/mbiter.h: New file.
8763
8764 2005-08-16  Bruno Haible  <bruno@clisp.org>
8765
8766         * lib/mbfile.h: New file.
8767
8768 2005-08-16  Bruno Haible  <bruno@clisp.org>
8769
8770         * lib/mbchar.h: New file.
8771         * lib/mbchar.c: New file.
8772
8773 2005-08-16  Bruno Haible  <bruno@clisp.org>
8774
8775         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
8776         the valid ones. Makes the comparison operations transitive:
8777         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
8778         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
8779
8780 2005-08-15  Simon Josefsson  <jas@extundo.com>
8781
8782         * modules/ssize_t (License): Change to 'unlimited'.
8783
8784         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
8785
8786 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8787
8788         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
8789         Add comments for each pending glibc patch.
8790
8791 2005-08-15  Bruno Haible  <bruno@clisp.org>
8792
8793         * lib/regex.h (__restrict_arr): Don't define to __restrict if
8794         __cplusplus is defined.
8795
8796 2005-08-14  Jim Meyering  <jim@meyering.net>
8797
8798         Sync from coreutils.
8799
8800         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
8801         Use the hash-table-based cycle-detection code not just when
8802         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
8803         Reported by James Youngman in
8804         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
8805         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
8806         FTS_TIGHT_CYCLE_CHECK.
8807         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
8808         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
8809         once again.
8810         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
8811         * lib/fts.c (fd_safer): Remove decl.
8812         Include fcntl--.h rather than unistd-safer.h
8813         (fts_safe_changedir): Don't call fd_safer; no longer needed
8814         now that we include fcntl--.h.
8815
8816 2005-08-12  Simon Josefsson  <jas@extundo.com>
8817
8818         * modules/getndelim2: Use ssize_t module.
8819         * modules/getnline: Likewise.
8820         * modules/safe-read: Likewise.
8821         * modules/xreadlink: Likewise.
8822
8823         * modules/ssize_t: New file.
8824
8825 2005-08-12  Simon Josefsson  <jas@extundo.com>
8826
8827         * m4/readline.m4: Look for termcap, curses or ncurses if required.
8828
8829 2005-08-12  Simon Josefsson  <jas@extundo.com>
8830
8831         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
8832         ssize_t.
8833
8834 2005-08-12  Simon Josefsson  <jas@extundo.com>
8835
8836         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
8837         readline, getdelim and check_version.
8838         (Support for systems lacking ISO C 99: Sizes of integer types):
8839         Add size_max.
8840
8841 2005-08-12  Bruno Haible  <bruno@clisp.org>
8842
8843         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
8844
8845 2005-08-11  Simon Josefsson  <jas@extundo.com>
8846
8847         * modules/readline: New file.
8848
8849         * modules/strnlen (Files): Add strnlen.h.
8850
8851 2005-08-11  Simon Josefsson  <jas@extundo.com>
8852
8853         * m4/readline.m4: New file.
8854
8855 2005-08-11  Simon Josefsson  <jas@extundo.com>
8856
8857         * lib/readline.h, readline.c: New file.
8858
8859 2005-08-11  Simon Josefsson  <jas@extundo.com>
8860
8861         * doc/gnulib.texi (Initial import, Finishing touches): Mention
8862         gl_AVOID.
8863
8864 2005-08-11  Bruno Haible  <bruno@clisp.org>
8865
8866         * lib/strnlen.h (strnlen): Change parameter name to match comment.
8867
8868 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
8869
8870         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
8871
8872 2005-08-10  Simon Josefsson  <jas@extundo.com>
8873
8874         * tests/test-iconvme.c: New file.
8875
8876 2005-08-10  Simon Josefsson  <jas@extundo.com>
8877
8878         * m4/strnlen.m4: New file.
8879
8880         * m4/strndup.m4: Don't check for strnlen declaration, done in
8881         strnlen.m4.
8882
8883 2005-08-10  Simon Josefsson  <jas@extundo.com>
8884
8885         * lib/strndup.c: Use strnlen.h.
8886
8887         * lib/strnlen.h: New file.
8888
8889 2005-08-08  Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8890
8891         * README: Typos.
8892
8893 2005-08-02  Simon Josefsson  <jas@extundo.com>
8894
8895         * modules/readline: New file.
8896
8897 2005-08-02  Simon Josefsson  <jas@extundo.com>
8898
8899         * modules/getdelim: New file.
8900
8901         * modules/getline: Rewrite, don't use getndelim2.
8902
8903 2005-08-02  Simon Josefsson  <jas@extundo.com>
8904
8905         * m4/getline.m4: Separate out getdelim stuff into separate module.
8906
8907         * m4/getdelim.m4: New file.
8908
8909 2005-08-02  Simon Josefsson  <jas@extundo.com>
8910
8911         * lib/getline.h, getline.c: Rewrite.
8912
8913         * lib/getdelim.h, getdelim.c: New files, ported from glibc.
8914
8915 2005-07-31  Bruno Haible  <bruno@clisp.org>
8916
8917         * lib/lock.h (gl_lock_initializer): New macro.
8918         (gl_lock_define_initialized): Use it.
8919         (gl_rwlock_initializer): New macro.
8920         (gl_rwlock_define_initialized): Use it.
8921         (gl_recursive_lock_initializer): New macro.
8922         (gl_recursive_lock_define_initialized): Use it.
8923
8924 2005-07-30  Karl Berry  <karl@gnu.org>
8925
8926         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
8927         Report from Ben Pfaff, regarding getopt.
8928
8929 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
8930
8931         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
8932         normal way.
8933         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
8934         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
8935         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
8936         (gl_GETOPT): Use the new macros.  Most of the implementation
8937         is moved to the new macros.  This is for programs like Emacs
8938         that don't want all the functionality of gl_GETOPT.
8939
8940 2005-07-26  Bruno Haible  <bruno@clisp.org>
8941
8942         * m4/lock.m4: Update from GNU gettext.
8943
8944 2005-07-26  Bruno Haible  <bruno@clisp.org>
8945
8946         * lib/lock.h: Update from GNU gettext.
8947         * lib/lock.c: Update from GNU gettext.
8948
8949 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
8950
8951         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
8952         obsolescent AC_TRY_RUN.  Include the default includes files, for
8953         'exit'.
8954
8955 2005-07-24  Bruno Haible  <bruno@clisp.org>
8956
8957         * modules/visibility: New file.
8958         * MODULES.html.sh (Misc): Add visibility.
8959
8960 2005-07-24  Bruno Haible  <bruno@clisp.org>
8961
8962         * m4/visibility.m4: New file.
8963
8964 2005-07-24  Bruno Haible  <bruno@clisp.org>
8965
8966         * doc/visibility.texi: New file.
8967
8968 2005-07-22  Bruno Haible  <bruno@clisp.org>
8969
8970         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
8971         $(ALLOCA_H), redundant through BUILT_SOURCES.
8972         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
8973         redundant through BUILT_SOURCES.
8974         * modules/byteswap (Makefile.am): Remove explicit dependency on
8975         $(BYTESWAP_H), redundant through BUILT_SOURCES.
8976         * modules/fnmatch (Makefile.am): Remove explicit dependency on
8977         $(FNMATCH_H), redundant through BUILT_SOURCES.
8978         * modules/getopt (Makefile.am): Remove explicit dependency on
8979         $(GETOPT_H), redundant through BUILT_SOURCES.
8980         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
8981         redundant through BUILT_SOURCES.
8982         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
8983         redundant through BUILT_SOURCES.
8984         * modules/stdbool (Makefile.am): Remove explicit dependency on
8985         $(STDBOOL_H), redundant through BUILT_SOURCES.
8986         * modules/stdint (Makefile.am): Remove explicit dependency on
8987         $(STDINT_H), redundant through BUILT_SOURCES.
8988         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
8989         Remove explicit dependency on $(SYSEXITS_H).
8990         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
8991
8992 2005-07-18  Simon Josefsson  <jas@extundo.com>
8993
8994         * lib/check-version.c (check_version): Accept identical versions too.
8995
8996 2005-07-18  Bruno Haible  <bruno@clisp.org>
8997
8998         * modules/lock: New file.
8999         * MODULES.html.sh (Multithreading): New section.
9000
9001 2005-07-18  Bruno Haible  <bruno@clisp.org>
9002
9003         * m4/lock.m4: New file, from GNU gettext.
9004
9005 2005-07-18  Bruno Haible  <bruno@clisp.org>
9006
9007         * lib/lock.h: New file, from GNU gettext.
9008         * lib/lock.c: New file, from GNU gettext.
9009
9010 2005-07-18  Bruno Haible  <bruno@clisp.org>
9011
9012         * lib/lock.h (gl_once_t): New type.
9013         (gl_once_define, gl_once): New macros.
9014         * lib/lock.c (fresh_once): New variable.
9015         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
9016         functions.
9017
9018 2005-07-16  Simon Josefsson  <jas@extundo.com>
9019
9020         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
9021         workaround, suggested by Bruno.
9022
9023 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
9024
9025         * modules/xalloc (Depends-on): Add xalloc-die.
9026         * modules/xvasprintf (Depends-on): Add xalloc-die.
9027
9028 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
9029
9030         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
9031         with a minor change.
9032
9033 2005-07-15  Bruno Haible  <bruno@clisp.org>
9034
9035         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
9036         When using lib/poll.c, define poll as rpl_poll.
9037
9038 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
9039
9040         * modules/argp (Depends-on): Remove unlocked-io.
9041
9042 2005-07-14  Derek Price  <derek@ximbiot.com>
9043
9044         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
9045         for glob symlink bug.
9046
9047 2005-07-14  Bruno Haible  <bruno@clisp.org>
9048
9049         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
9050         Instead, test for *_unlocked function declarations directly.
9051
9052 2005-07-11  Simon Josefsson  <jas@extundo.com>
9053
9054         * modules/size_max: New file.
9055
9056         * modules/xsize: Depend on size_max module for size_max.m4.
9057
9058 2005-07-11  Simon Josefsson  <jas@extundo.com>
9059
9060         * lib/size_max.h: New file.
9061
9062 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
9063
9064         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
9065         copyright symbol and the year.
9066         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
9067         (version_etc_va): Use parameterized copyright notice.
9068         Reword to conform to the current GNU coding standards.
9069
9070 2005-07-11  Karl Berry  <karl@gnu.org>
9071
9072         * doc/gnulib.texi (Quoting): new node.
9073         (Initial import): more info, from Patrice.
9074
9075 2005-07-11  Bruno Haible  <bruno@clisp.org>
9076
9077         * gnulib-tool (func_usage): Document option --avoid.
9078         (Command line options): Handle --avoid.
9079         (func_acceptable): New function.
9080         (func_modules_transitive_closure): Use it.
9081
9082 2005-07-11  Bruno Haible  <bruno@clisp.org>
9083
9084         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
9085         Reported by Jim Meyering.
9086
9087 2005-07-10  Bruno Haible  <bruno@clisp.org>
9088
9089         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
9090         Needed when size_t is smaller than 'unsigned int'.
9091         Reported by Paul Eggert.
9092
9093 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9094
9095         * modules/argp (Depends-on): Add unlocked-io
9096
9097 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9098
9099         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
9100         block of defines.
9101
9102 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
9103
9104         * config/srclist.txt: Comment out regcomp.c, since we have a porting
9105         fix now.
9106
9107 2005-07-08  Eric Blake  <ebb9@byu.net>
9108        and  Paul Eggert  <eggert@cs.ucla.edu>
9109
9110         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
9111         in wint_t, not wchar_t.  Remove now-unnecessary cast.
9112
9113 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
9114
9115         * modules/regex (Files): Add lib/regex_internal.c,
9116         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
9117         (Depends-on): Add extensions.
9118         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
9119
9120 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
9121
9122         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
9123         pathconf.
9124         * m4/same.m4 (gl_SAME): Likewise.
9125         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
9126
9127         * m4/regex.m4: Adjust to new libc regex implementation.
9128         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
9129         all the .c and .h parts of (the new) regex.
9130         Quote the m4 stuff better.
9131         Check for RE_ICASE bug of old gnulib.
9132         Check for REG_STARTEND of recent libc.
9133         Rename local variables from jm_* to gl_*.
9134         Quote operand of "test -f".
9135         Say "recent enough" version of libc, not "version 2".
9136         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
9137         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
9138         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
9139         Remove check for btowc, isascii.
9140         Require AM_LANGINFO_CODESET.
9141
9142 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
9143
9144         * lib/regex.c, regex.h: Sync from libc.
9145         * lib/regcomp.c, regexec_internal.c, regex_internal.h, regexec.c:
9146         New files, synced from libc, except that regex_internal.h
9147         currently has a small porting fix.
9148
9149 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
9150
9151         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
9152         regex_internal.c, regexec.c.
9153         Add regex_internal.h too, but as a comment, since the libc version
9154         is currently broken in gnulib mode.
9155
9156 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9157
9158         Support programs like Emacs that use gnulib but not gettext.
9159         * MODULES.html.sh (Internationalization functions): Add gettext-h.
9160         * modules/gettext-h: New file.
9161         * modules/gettext (Files): Remove lib/gettext.h.
9162         (Depends-on): Add gettext-h.
9163         (Makefile.am): Remove lib_SOURCES.
9164         * modules/argmatch, modules/c-stack, modules/closeout:
9165         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
9166         * modules/execute, modules/file-type, modules/getaddrinfo:
9167         * modules/getopt, modules/human, modules/javacomp:
9168         * modules/javaexec, modules/mkdir-p, modules/obstack:
9169         * modules/openat, modules/pagealign_alloc, modules/pipe:
9170         * modules/quotearg, modules/regex, modules/rpmatch:
9171         * modules/unicodeio, modules/userspec, modules/version-etc:
9172         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
9173         * modules/xsetenv:
9174         Depend on gettext-h, not gettext.
9175
9176 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9177
9178         * gnulib-tool (func_import): Add support for 'public domain' license.
9179         * modules/alloca, modules/atexit, modules/memmove:
9180         Now public domain, not GPL.
9181         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
9182         * modules/realloc, modules/strerror, modules/strtod:
9183         Now LGPL, not GPL.
9184
9185 2005-07-05  Bruno Haible  <bruno@clisp.org>
9186
9187         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
9188         autoconf CVS. Needed for mingw.
9189
9190 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9191
9192         Remove the dependency of the strftime module on the tzset module.
9193         * modules/strftime (Depends-on): Remove dependency on tzset.
9194
9195 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9196
9197         Remove the dependency of the strftime module on the tzset module.
9198         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
9199         gl_FUNC_TZSET_CLOBBER.
9200
9201 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9202
9203         Remove the dependency of the strftime module on the tzset module.
9204         * lib/strftime.c (my_strftime)
9205         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
9206         Copy the input structure, to work around some of the bug with
9207         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
9208         Solaris releases, you should also use the tzset module, but we won't
9209         require it as a dependency any more since we don't want LGPLed code
9210         to depend on GPLed code.
9211
9212 2005-07-02  Jim Meyering  <jim@meyering.net>
9213
9214         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
9215         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
9216         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
9217         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
9218
9219 2005-07-02  Jim Meyering  <jim@meyering.net>
9220
9221         * lib/backupfile.c (backup_args): Change a `0' to NULL.
9222
9223 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
9224
9225         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
9226         declares only 'struct timespec;' (!).
9227
9228 2005-07-01  Jim Meyering  <jim@meyering.net>
9229
9230         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
9231         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
9232         * lib/save-cwd.c, tempname.c:
9233         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
9234         and don't include <sys/file.h>).
9235
9236 2005-06-29  Jim Meyering  <jim@meyering.net>
9237
9238         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
9239         type name.  Use the variable name instead.
9240         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
9241         Likewise.
9242
9243 2005-06-28  Simon Josefsson  <jas@extundo.com>
9244
9245         * modules/check-version (Files): Add check-version.m4.
9246
9247 2005-06-28  Simon Josefsson  <jas@extundo.com>
9248
9249         * m4/check-version.m4: New file, suggested by Jim Meyering
9250         <jim@meyering.net>.
9251
9252 2005-06-28  Simon Josefsson  <jas@extundo.com>
9253
9254         * lib/check-version.h, check-version.c: New files.
9255
9256 2005-06-28  Simon Josefsson  <jas@extundo.com>
9257
9258         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
9259         collision with global variable.  Better indentation.  Don't
9260         increment buffer pointer beyond buffer end.  Based on comments
9261         from Paul Eggert <eggert@cs.ucla.edu>.
9262
9263         * lib/base64.h: Indent.
9264
9265 2005-06-28  Simon Josefsson  <jas@extundo.com>
9266
9267         * doc/gnulib.texi (Library version handling): New section.
9268
9269 2005-06-28  Jim Meyering  <jim@meyering.net>
9270
9271         * check-module (find_included_lib_files): Hard-code another
9272         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
9273         but modules/fts-lgpl (correctly) does not list those files.
9274
9275         * modules/canonicalize (Files): Add lib/pathmax.h.
9276
9277 2005-06-25  Simon Josefsson  <jas@extundo.com>
9278
9279         * modules/check-version: New file.
9280
9281 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
9282
9283         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
9284         initializer of struct addrinfo, as an indication that we don't
9285         care how many members the structure has.
9286
9287 2005-06-24  Derek Price  <derek@ximbiot.com>
9288         and Bruno Haible  <bruno@clisp.org>
9289
9290         Remove stat module & update lstat.
9291         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
9292         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
9293         * m4/stat.m4: Remove this file.
9294
9295 2005-06-24  Derek Price  <derek@ximbiot.com>
9296         and Bruno Haible  <bruno@clisp.org>
9297
9298         Remove stat module & update lstat.
9299         * lib/stat.c: Remove this file...
9300         (slash_aware_lstat): ...moving this content and its support...
9301         * lib/lstat.c (rpl_lstat): ...into here.
9302         * lib/lstat.h: New file.
9303
9304 2005-06-24  Derek Price  <derek@ximbiot.com>
9305         and Bruno Haible  <bruno@clisp.org>
9306
9307         Remove stat module & update lstat.
9308         * config/srclist.txt (libc sources): Remove stat.
9309
9310 2005-06-24  Derek Price  <derek@ximbiot.com>
9311         and Bruno Haible  <bruno@clisp.org>
9312
9313         Remove stat module & update lstat.
9314         * MODULES.html.sh (stat): Remove.
9315         * MODULES.html: Regenerated.
9316         * modules/lstat (Description): Correct function name.
9317         (Files): Add "lstat.h".
9318         (Depends-on): Remove stat, add xalloc, stat-macros.
9319         * modules/stat: Remove this file.
9320         (Include): Add "lstat.h", remove <sys/stat.h>.
9321
9322 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
9323
9324         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
9325         (ranged_convert): Don't save conversion in a temporary struct.
9326         This causes a warning with GCC 4.0.0, and anyway in the typical
9327         case it's not worth the extra 100 bytes or so of code.
9328         (ranged_convert, __mktime_internal): When calling a function via a
9329         pointer P, use P () rather than (*P) (), as we now assume C89 or
9330         better.
9331
9332 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
9333
9334         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
9335         "who -r" failed to give output.  Problem reported by Tim Waugh.
9336
9337         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
9338         (xcalloc): Use it to avoid needless tests.
9339         Problem reported by Jim Meyering.
9340
9341 2005-06-20  Derek Price  <derek@ximbiot.com>
9342
9343         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
9344         unnecessary for Autoconfs > 2.59c.
9345
9346 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
9347
9348         * lib/argp.h (__option_is_short): Check upper limit of
9349         __key. Isprint() requires its argument to have the value
9350         of an unsigned char or EOF.
9351
9352 2005-06-16  Jim Meyering  <jim@meyering.net>
9353
9354         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
9355         when either N or S is zero.
9356
9357 2005-06-16  Derek Price  <derek@ximbiot.com>
9358
9359         * m4/bison.m4: Declare YACC & YFLAGS precious.
9360
9361 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
9362
9363         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
9364         multibyte string or pattern, fall back on unibyte matching.
9365         Problem reported by James Youngman.
9366
9367 2005-06-08  Bruno Haible  <bruno@clisp.org>
9368
9369         * modules/csharpcomp: New file.
9370         * MODULES.html.sh (C#): Add csharpcomp.
9371
9372 2005-06-08  Bruno Haible  <bruno@clisp.org>
9373
9374         * m4/csharpcomp.m4: New file, from GNU gettext.
9375
9376 2005-06-08  Bruno Haible  <bruno@clisp.org>
9377
9378         * lib/csharpcomp.h: New file, from GNU gettext.
9379         * lib/csharpcomp.c: New file, from GNU gettext.
9380         * lib/csharpcomp.sh.in: New file, from GNU gettext.
9381
9382 2005-06-08  Bruno Haible  <bruno@clisp.org>
9383
9384         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
9385         warning on mingw.
9386
9387 2005-06-07  Derek Price  <derek@ximbiot.com>
9388
9389         Sync from CVS.
9390         * lib/glob_.h: Indent nested #ifdef.
9391
9392 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
9393
9394         Sync from coreutils.
9395         Use "file name" when talking about file names, instead of "filename"
9396         or "path", as per the GNU coding standards.
9397         * lib/mkdir-p.c: Renamed from makepath.c.
9398         (make_dir_parents): Renamed from make_path.  All callers changed.
9399         * lib/mkdir-p.h: Likewise.  All includers changed.
9400         * lib/filenamecat.c: Renamed from path-concat.c.
9401         (file_name_concat): Renamed from path_concat.  All callers changed.
9402         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
9403         * lib/filenamecat.h: Likewise.  All includers changed.
9404         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
9405         in comments or local variable names.
9406         * lib/basename.c: Likewise.
9407         * lib/canonicalize.c, canonicalize.h: Likewise.
9408         * lib/dirname.c, dirname.h: Likewise.
9409         * lib/euidaccess.c: Likewise.
9410         * lib/exclude.c: Likewise
9411         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
9412         * lib/fsusage.c, fsuage.h: Likewise.
9413         * lib/fts.c, fts_.h: Likewise.
9414         * lib/getcwd.c: Likewise.
9415         * lib/getloadavg.c: Likewise.
9416         * lib/mkstemp.c: Likewise.
9417         * lib/mountlist.c, mountlist.h: Likewise.
9418         * lib/openat.c, openat.h: Likewise.
9419         * lib/readlink-stub.c: Likewise.
9420         * lib/readutmp.c, readutmp.h: Likewise.
9421         * lib/rename.c: Likewise.
9422         * lib/rmdir.c: Likewise.
9423         * lib/same.c: Likewise.
9424         * lib/savedir.c: Likewise.
9425         * lib/stripslash.c: Likewise.
9426         * lib/tempname.c: Likewise.
9427         * lib/xreadlink.c: Likewise.
9428         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
9429         All uses changed.
9430         * lib/exclude.h: Likewise.
9431
9432         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
9433         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
9434         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
9435         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
9436         * lib/pathmax.h: Include <limits.h> unconditionally, since other
9437         files have been getting away with it for years (MORE/BSD 4.3
9438         is extinct now).
9439         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
9440         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
9441
9442         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
9443         Define to 256, not 255, as per modern POSIX.
9444
9445 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
9446
9447         Sync from coreutils.
9448         Use "file name" when talking about file names, instead of "filename"
9449         or "path", as per the GNU coding standards.
9450         * MODULES.html.sh: mkdir-p renamed from makepath.
9451         filenamecat renamed from path-concat.
9452         * modules/filenamecat: Renamed from modules/path-concat.
9453         (Files): filenamecat.h and filenamecat.c renamed from
9454         path-concat.h and path-concat.c.
9455         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
9456         (Include): filenamecat.h, not path-concat.h.
9457         * modules/mkdir-p: Renamed from modules/makepath.
9458         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
9459         makepath.c.
9460         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
9461         (Include): mkdir-p.h, not makepath.h.
9462
9463 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
9464
9465         Sync from coreutils.
9466         * m4/mkdir-p.m4: Renamed from makepath.m4.
9467         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
9468         Rename files from makepath.c to mkdir-p.c, and from
9469         makepath.h to mkdir-p.h.
9470         * m4/filenamecat.m4: Renamed from path-concat.m4.
9471         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
9472         Rename files from path-concat.c to filenamecat.c,
9473         and from path-concat.h to filenamecat.h.
9474         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
9475         "file name" in local variables or comments.
9476         * m4/rename.m4: Likewise.
9477
9478 2005-06-01  Bruno Haible  <bruno@clisp.org>
9479
9480         * modules/csharpexec: New file.
9481         * MODULES.html.sh (C#): New section.
9482
9483 2005-06-01  Bruno Haible  <bruno@clisp.org>
9484
9485         * m4/csharp.m4: New file, from GNU gettext.
9486         * m4/csharpexec.m4: New file, from GNU gettext.
9487
9488 2005-06-01  Bruno Haible  <bruno@clisp.org>
9489
9490         * lib/csharpexec.h: New file, from GNU gettext.
9491         * lib/csharpexec.c: New file, from GNU gettext.
9492         * lib/csharpexec.sh.in: New file, from GNU gettext.
9493
9494 2005-05-31  Derek Price  <derek@ximbiot.com>
9495             Paul Eggert  <eggert@cs.ucla.edu>
9496
9497         Sync from cvs.
9498         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
9499
9500 2005-05-31  Derek Price  <derek@ximbiot.com>
9501             Paul Eggert  <eggert@cs.ucla.edu>
9502
9503         Sync from cvs.
9504         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
9505
9506 2005-05-29  Derek Price  <derek@ximbiot.com>
9507
9508         * config/srclist.txt (glob_.h, glob.c): Add these files.
9509
9510 2005-05-29  Derek Price  <derek@ximbiot.com>
9511
9512         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
9513         * modules/glob: New file.
9514         * modules/getlogin_r: Add link to POSIX spec in description.
9515
9516 2005-05-29  Derek Price  <derek@ximbiot.com>
9517             Paul Eggert  <eggert@cs.ucla.edu>
9518
9519         * m4/glob.m4: New file.
9520
9521 2005-05-29  Derek Price  <derek@ximbiot.com>
9522             Paul Eggert  <eggert@cs.ucla.edu>
9523
9524         * lib/glob_.h, glob.c: New files.
9525
9526 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
9527
9528         * modules/fts (Files): Remove m4/inttypes-pri.m4.
9529         * modules/fts-lgpl (Depends-on): Remove gettext.
9530
9531 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
9532
9533         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
9534         and don't require gt_INTTYPES_PRI.
9535
9536 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
9537
9538         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
9539
9540         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
9541         the configuration hassle isn't worth it.
9542         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
9543         (LONGEST_MODIFIER, PRIuMAX): Remove.
9544
9545 2005-05-27  Bruno Haible  <bruno@clisp.org>
9546
9547         * lib/getlogin_r.h: Remove second include of <stddef.h>.
9548
9549 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
9550
9551         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
9552         _POSIX_PTHREAD_SEMANTICS for Solaris.
9553
9554 2005-05-25  Derek Price  <derek@ximbiot.com>
9555
9556         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
9557
9558 2005-05-25  Derek Price  <derek@ximbiot.com>
9559             Paul Eggert  <eggert@cs.ucla.edu>
9560
9561         * modules/getlogin_r: New files.
9562
9563 2005-05-25  Derek Price  <derek@ximbiot.com>
9564             Paul Eggert  <eggert@cs.ucla.edu>
9565
9566         * m4/getlogin_r.m4: New files.
9567
9568 2005-05-25  Derek Price  <derek@ximbiot.com>
9569             Paul Eggert  <eggert@cs.ucla.edu>
9570
9571         * lib/getlogin_r.c, getlogin_r.h: New files.
9572
9573 2005-05-25  Bruno Haible  <bruno@clisp.org>
9574             Derek Price  <derek@ximbiot.com>
9575
9576         * lib/getlogin_r.h: Simplify API documentation.
9577
9578 2005-05-23  Derek Price  <derek@ximbiot.com>
9579
9580         * modules/minmax (Files): Add m4/minmax.m4.
9581         (configure.ac): Add gl_MINMAX.
9582
9583 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
9584
9585         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
9586         so that unistd-safer.h (GPL'ed code) need not be included.
9587
9588 2005-05-22  Bruno Haible  <bruno@clisp.org>
9589
9590         * m4/minmax.m4: New file.
9591         Based on a patch by Derek Price <derek@ximbiot.com>.
9592
9593 2005-05-22  Bruno Haible  <bruno@clisp.org>
9594
9595         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
9596         (INT64_MIN): Fix definition.
9597         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
9598
9599         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
9600         NEED_SIGNED_INT_TYPES.
9601
9602         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
9603         HAVE_SYSTEM_INTTYPES.
9604
9605 2005-05-22  Bruno Haible  <bruno@clisp.org>
9606
9607         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
9608         Also include <sys/param.h> if it defines MIN, MAX.
9609         Based on a patch by Derek Price <derek@ximbiot.com>.
9610
9611 2005-05-21  Jim Meyering  <jim@meyering.net>
9612
9613         * modules/fts (Files): Add m4/inttypes-pri.m4.
9614         (Depends-on): Add lstat and remove gettext.  Alphabetize.
9615
9616 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
9617
9618         New fts module.
9619         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
9620         (setup_dir, free_dir): New functions.
9621         (enter_dir, leave_dir): Define trivial
9622         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
9623         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
9624         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
9625         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
9626         Move to fts-cycle.c.
9627         (fts_open): Use setup_dir.
9628         (fts_close): Use free_dir.
9629         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
9630         This adds a label and some gotos, but the alternatives were messier.
9631         Check for memory allocation failure when entering a dir.
9632         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
9633         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
9634         (FTS): New member fts_cycle, that is a union that contains the
9635         old active_dir_ht and cycle_state.  All uses changed to mention
9636         fts_cycle.ht and fts_cycle.state.
9637         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
9638         fts.c, with the following changes:
9639         (setup_dir, free_dir): New functions.
9640         (enter_dir): Now returns bool.  Return true if successful, false
9641         if memory exhausted.  All callers changed.
9642         Do not bother partly cleaning up on
9643         memory allocation failure; that is free_dir's job.
9644         However, free ad if hash_insert fails, to avoid memory leak.
9645         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
9646         fts->fts_options to see which union member to use.
9647
9648 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
9649
9650         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
9651         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
9652
9653 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
9654
9655         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
9656
9657 2005-05-20  Jim Meyering  <jim@meyering.net>
9658
9659         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
9660         Now a macro, to pacify GCC.
9661
9662 2005-05-20  Eric Blake  <ebb9@byu.net>
9663
9664         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
9665         of -1.
9666
9667 2005-05-20  Eric Blake  <ebb9@byu.net>
9668
9669         * lib/chown.c (rpl_chown): Return -1 on failure.
9670
9671 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
9672
9673         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
9674         Don't check for stddef.h.
9675         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
9676         don't use its results.
9677         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
9678         since we include them unconditionally.  Don't require
9679         AM_STDBOOL_H, since stdbool is a prerequisite.
9680         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
9681         since we assume C89 or better.
9682         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
9683         as we don't use their results.
9684         Don't check for fchdir, memmove, memset, strrchr, as we use
9685         them unconditionally.
9686         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
9687         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
9688
9689 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
9690
9691         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
9692         Include <stddef.h> unconditionally, since we assume C89 now.
9693         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
9694         * lib/fts.c: Include fts_.h first, to check interface.
9695         Do not include intprops.h; no longer needed.
9696         Include cycle-check.h and hash.h, since fts_.h no longer does.
9697         Remove unnecessary casts of closedir to void.
9698         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
9699         decide whether to decrement nlinks.
9700         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
9701         (FTS): Use struct hash_table * instead of Hash_table, so that
9702         we no longer need to include hash.h here.
9703
9704 2005-05-18  Jim Meyering  <jim@meyering.net>
9705
9706         * modules/dirfd (License): Change to LGPL.  Most of the code
9707         is already in the public domain.
9708
9709 2005-05-18  Jim Meyering  <jim@meyering.net>
9710
9711         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
9712         Reported by Yoann Vandoorselaere.
9713
9714 2005-05-17  Jim Meyering  <jim@meyering.net>
9715
9716         * m4/fts.m4: New file, from coreutils.
9717
9718 2005-05-17  Jim Meyering  <jim@meyering.net>
9719
9720         * lib/fts.c, fts_.h: New files, from coreutils.
9721
9722 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
9723
9724         Sync from coreutils.
9725         * m4/unlinkdir.m4: New file.
9726
9727 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
9728
9729         Sync from coreutils.
9730         * lib/unlinkdir.c, unlinkdir.h: New files.
9731         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
9732         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
9733         White space changes only.
9734         * lib/makepath.c (make_path): Port to hosts where leading "//" is
9735         special.
9736         * lib/yesno.c: Include getline.h, not ctype.h.
9737         (yesno): Don't remove leading white space; POSIX doesn't allow it.
9738         Use getline to remove arbitrary restriction on response length.
9739
9740 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
9741
9742         * config/srclist-update: Spell out "Street" in FSF postal
9743         mail address; this is the style the FSF seems to prefer.
9744
9745         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
9746         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
9747         this updates FSF postal mail address.
9748
9749         Sync from coreutils.
9750         * modules/unlinkdir: New file.
9751         * modules/yesno (Depends-on): Add getline.
9752         * MODULES.html.sh (File system functions): Add unlinkdir.
9753
9754 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
9755
9756         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
9757         lib/strsep.h:
9758         Change the initial comment to refer to GPL, not LGPL.
9759         gnulib-tool will change it to LGPL as needed.
9760
9761         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
9762         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
9763         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
9764         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
9765         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
9766         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
9767         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
9768         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
9769         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
9770         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
9771         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
9772         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
9773         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
9774         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
9775         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
9776         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
9777         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
9778         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
9779         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
9780         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
9781         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
9782         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
9783         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
9784         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
9785         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
9786         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
9787         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
9788         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
9789         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
9790         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
9791         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
9792         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
9793         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
9794         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
9795         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
9796         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
9797         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
9798         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
9799         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
9800         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
9801         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
9802         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
9803         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
9804         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
9805         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
9806         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
9807         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
9808         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
9809         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
9810         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
9811         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
9812         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
9813         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
9814         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
9815         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
9816         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
9817         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
9818         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
9819         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
9820         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
9821         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
9822         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
9823         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
9824         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
9825         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
9826         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
9827         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
9828         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
9829         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
9830         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
9831         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
9832         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
9833         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
9834         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
9835         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
9836         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
9837         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
9838         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
9839         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
9840         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
9841         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
9842         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
9843         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
9844         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
9845         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
9846         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
9847         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
9848         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
9849         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
9850         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
9851         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
9852         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
9853         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
9854         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
9855         lib/yesno.c, lib/yesno.h:
9856         Update FSF postal mail address.
9857
9858 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
9859
9860         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
9861         tests/test-memmem.c, tests/test-stpncpy.c:
9862         Update FSF postal mail address.
9863
9864 2005-05-13  Bruno Haible  <bruno@clisp.org>
9865
9866         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
9867         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
9868         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
9869         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
9870         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
9871         Add support for 64-bit integers in the MSVC compiler.
9872
9873 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
9874
9875         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
9876
9877 2005-05-12  Eric Blake  <ebb9@byu.net>
9878
9879         * gnulib-tool (func_import): Sort and uniquify recommended includes.
9880
9881 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
9882
9883         * doc/getdate.texi (General date syntax): Don't say that date
9884         date --iso-8601=ns generates acceptable dates; it doesn't yet.
9885         Problem reported by Nic Ferrier.
9886
9887 2005-05-10  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
9888
9889         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
9890         specified in ai_socktype. Fix invalid ai_protocol
9891         check. ai_protocol is usually set to 0 or depending on
9892         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
9893         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
9894         ai_socktype / ai_protocol in the returned addrinfo structure.
9895
9896 2005-05-10  Simon Josefsson  <jas@extundo.com>
9897
9898         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
9899         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
9900
9901 2005-05-10  Karl Berry  <karl@gnu.org>
9902
9903         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
9904         (from http://www.gnu.org/licenses).
9905         * doc/COPYING.LIB: also rename to COPYING.LESSER.
9906         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
9907         fdl.texi suffices.
9908
9909 2005-05-10  Karl Berry  <karl@gnu.org>
9910
9911         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
9912         (COPYING.DOC): remove.
9913
9914         * config/srclist-update: new FSF address.
9915
9916 2005-05-10  Derek Price  <derek@ximbiot.com>
9917
9918         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
9919         possible.
9920
9921 2005-05-09  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
9922             Bruno Haible  <bruno@clisp.org>
9923
9924         * modules/inet_ntop: New file.
9925         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
9926         inet_ntop.
9927
9928 2005-05-09  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
9929             Bruno Haible  <bruno@clisp.org>
9930
9931         * m4/inet_ntop.m4: New file.
9932
9933 2005-05-09  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
9934             Bruno Haible  <bruno@clisp.org>
9935
9936         * lib/inet_ntop.h: New file.
9937         * lib/inet_ntop.c: New file, from glibc with modifications.
9938
9939 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
9940
9941         * modules/time_r (License): Change to LGPL.
9942         * modules/extensions (License): Change to LGPL.  Actually,
9943         the license is more permissive than that, but currently gnulib-tool
9944         doesn't know how to handle more-permissive licenses.
9945
9946         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
9947         Problem reported by Dave Love.
9948
9949 2005-05-08  Jim Meyering  <jim@meyering.net>
9950
9951         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
9952         blank.
9953
9954 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
9955
9956         * modules/argmatch (Depends-on): Add stdbool.
9957         * modules/backupfile (Depends-on): Likewise.
9958         * modules/chdir-long (Depends-on): Likewise.
9959         * modules/closeout (Depends-on): Likewise.
9960         * modules/cycle-check (Depends-on): Likewise.
9961         * modules/dirname (Depends-on): Likewise.
9962         * modules/fnmatch (Depends-on): Likewise.
9963         * modules/fsusage (Depends-on): Likewise.
9964         * modules/fwriteerror (Depends-on): Likewise.
9965         * modules/getcwd (Depends-on): Likewise.
9966         * modules/getloadavg (Depends-on): Likewise.
9967         * modules/hard-locale (Depends-on): Likewise.
9968         * modules/makepath (Depends-on): Likewise.
9969         * modules/mountlist (Depends-on): Likewise.
9970         * modules/nanosleep (Depends-on): Likewise.
9971         * modules/posixtm (Depends-on): Likewise.
9972         * modules/quotearg (Depends-on): Likewise.
9973         * modules/readtokens (Depends-on): Likewise.
9974         * modules/readtokens0 (Depends-on): Likewise.
9975         * modules/readutmp (Depends-on): Likewise.
9976         * modules/save-cwd (Depends-on): Likewise.
9977         * modules/strftime (Depends-on): Likewise.
9978         * modules/userspec (Depends-on): Likewise.
9979         * modules/utimecmp (Depends-on): Likewise.
9980         * modules/xgetcwd (Depends-on): Likewise.
9981         * modules/xnanosleep (Depends-on): Likewise.
9982         * modules/xstrtod (Depends-on): Likewise.
9983         * modules/yesno (Depends-on): Likewise.
9984
9985 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
9986
9987         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
9988         needless checks.
9989
9990 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
9991
9992         Merge from coreutils.  Among other things,
9993         add bulletproofing for cases where stdin, stdout, or stderr are closed.
9994         * lib/fd-safer.c: New file.
9995         * lib/fcntl-safer.h, open-safer.c: Remove.
9996         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
9997         * lib/dup-safer.c: Include unistd-safer.h first.
9998         Don't include errno.h.
9999         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
10000         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
10001         * lib/file-type.c: Rely on file-type.h change.
10002         * lib/getloadavg.c: Include unistd-safer.h.
10003         (getloadavg): Use safer open.
10004         * lib/getusershell.c: Include "stdio-safer.h".
10005         (getusershell): Use safer fopen.
10006         * lib/long-options.c (long_options): Use NULL rather than 0.
10007         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
10008         'free'.
10009         * lib/modechange.c: Likewise.
10010         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
10011         (MODE_DONE): New constant.
10012         (struct mode_change): Remove 'next' member.
10013         (make_node_op_equals): New function; like the old one of the
10014         same name, except it allocates an array.
10015         (mode_compile, mode_create_from_ref): Use it.
10016         (mode_compile): Allocate result as an array, not a linked list.
10017         Parse octal string ourself, so that we catch mistakes like "+0".
10018         (mode_adjust): Arg is an array, not a linked list.
10019         * lib/modechange.c: Include stat-macros.h, xalloc.h.
10020         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
10021         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
10022         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
10023         Remove.  This is now stat-macros.h's job.
10024         (talloc): Remove.  All callers replaced by xalloc, so that
10025         our invokers don't have to worry about reporting memory failures.
10026         (make_node_op_equals): Remove.
10027         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
10028         New constants.
10029         (struct mode_change): Moved here from modechange.h.
10030         (mode_append_entry): Remove.
10031         (mode_compile): Remove MASKED_OPS arg, since it encouraged
10032         apps to have incorrect behavior.  Use simpler algorithm for head
10033         and tail.  Don't futz with umask; that's now the job of mode_adjust.
10034         Detect more invalid usages rather than having somewhat-random behavior.
10035         Don't insert an "a=" action, as that leads to incorrect behavior.
10036         (mode_compile, mode_create_from_ref): Return NULL on error instead
10037         of an enum, since now there's only one way to have an error.  All
10038         callers changed.
10039         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
10040         at the correct time.  Simplify calculation of "+u" and its ilk.
10041         Don't mishandle "+X".
10042         (mode_free): Remove "register" and localize decls.
10043         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
10044         (struct mode_change): Move to modechange.c; callers don't
10045         need to see this stuff.
10046         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
10047         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
10048         (mode_change, mode_adjust): Reflect the new signatures noted above.
10049         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
10050         that might redefine system include files.
10051         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
10052         (my_usleep): Use NULL rather than (void *) 0.
10053         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
10054         Use siginterrupt to specify that system calls should be interrupted.
10055         (rpl_nanosleep): Move initialization of suspended closer to call of
10056         my_usleep.
10057         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
10058         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
10059         (desirable_utmp_entry): New function.
10060         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
10061         using x2nrealloc, to simplify logic.
10062         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
10063         size calculation.  Do not assume utmp file is a regular file.
10064         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
10065         (READ_UTMP_CHECK_PIDS): New constant.
10066         * lib/save-cwd.c: Include unistd-safer.h.
10067         (save_cwd): Use fd_safer.
10068         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
10069         [!_LIBC] Include "stat-macros.h" instead.
10070         * lib/unistd-safer.h (fd_safer): New decl.
10071
10072 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
10073
10074         * modules/getloadavg (Depends-on): Add unistd-safer.
10075         * modules/getusershell (Depends-on): Add stdio-safer.
10076         * modules/lstat (Depends-on): Remove xalloc.
10077         * modules/mkstemp (Depends-on): Add stat-macros.
10078         * modules/modechange (Depends-on): Remove xstrtol.
10079         Add stat-macros, xalloc.
10080         * modules/save-cwd (Depends-on): Add unistd-safer.
10081         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
10082         * modules/unistd-safer (Files): Add lib/fd-safer.c
10083         (Makefile.am): Remove lib_SOURCES.
10084
10085         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
10086         Remove fcntl-safer; unistd-safer supersedes it.
10087
10088 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
10089
10090         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
10091         AC_HEADER_STAT.
10092         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
10093         (gl_PREREQ_CHOWN): Remove.
10094         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
10095         it.  Don't require AC_HEADER_STAT.
10096         (gl_PREREQ_LSTAT): Remove.
10097         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
10098         Don't require AC_HEADER_STAT.
10099         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
10100         (gl_PREREQ_RMDIR): Remove.
10101         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
10102         mention stat-macros.h or AC_HEADER_STAT, since we'll make
10103         the stat-macros module a prerequisite.
10104         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
10105         * m4/filemode.m4 (gl_FILEMODE): Likewise.
10106         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
10107         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
10108         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
10109         variable names.
10110         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
10111         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
10112         variable prefixes.
10113         * m4/fcntl-safer.m4: Remove.
10114         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
10115         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
10116         Invoke gl_PREREQ_FD_SAFER.
10117         (gl_PREREQ_FD_SAFER): New macro.
10118         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
10119         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
10120         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
10121         Remove duplicate call to AC_LIBOBJ(readutmp).
10122         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
10123
10124         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
10125         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
10126
10127 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
10128
10129         * MODULES.html.sh (Misc): Add byteswap.
10130
10131 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
10132
10133         * modules/getcwd (Depends-on): Add extensions.
10134         * modules/openat (Depends-on): Likewise.
10135
10136 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
10137
10138         * modules/byteswap: New file.
10139
10140 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
10141
10142         * m4/byteswap.m4: New file.
10143
10144 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
10145
10146         * lib/byteswap_.h: New file.
10147
10148 2005-04-25  Karl Berry  <karl@gnu.org>
10149
10150         * m4/gettext.m4: Update from GNU gettext 0.14.4.
10151
10152 2005-04-25  Albert Chin  <china@thewrittenword.com>
10153
10154         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
10155         Toolkit C bug.
10156
10157 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
10158
10159         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
10160         (func_ln_if_changed) Remove forcibly for no error message
10161         in case file does not exist.
10162
10163 2005-04-19  Simon Josefsson  <jas@extundo.com>
10164
10165         * gnulib-tool (Options): Make --symlink mean --symbolic.
10166
10167 2005-04-18  Oskar Liljeblad <oskar@osk.mine.nu>
10168
10169         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
10170
10171 2005-04-16  Simon Josefsson  <jas@extundo.com>
10172
10173         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
10174
10175 2005-04-15  Simon Josefsson  <jas@extundo.com>
10176
10177         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
10178
10179 2005-04-15  Simon Josefsson  <jas@extundo.com>
10180
10181         * gnulib-tool: Rename --symlink to --symbolic.
10182
10183 2005-04-15  Oskar Liljeblad <oskar@osk.mine.nu>
10184
10185         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
10186         symbolic links to files instead of copying/moving.  Add --aux-dir,
10187         specifying directory relative --dir where auxiliary build tools
10188         are placed.
10189
10190 2005-04-14  Bruno Haible  <bruno@clisp.org>
10191
10192         * modules/allocsa (License): Change to LGPL.
10193         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
10194
10195 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
10196
10197         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
10198         that "UTC +1 second" continues to work.  Problem reported
10199         by Dmitry V. Levin.
10200         (relunit_snumber): New rule.
10201         (relunit): Use it.
10202
10203 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
10204
10205         * lib/getdate.y (universal_time_zone_table): New constant.
10206         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
10207         universal_time_zone_table.
10208         (lookup_zone): Prefer universal_time_zone_table to
10209         local_time_zone_table, so that "GMT" time stamps are allowed in
10210         London during the summer.  Problem reported by Ian Abbott.
10211
10212 2005-04-12  Jim Meyering  <jim@meyering.net>
10213
10214         * lib/human.c (humblock): Set *options even when returning due to
10215         xstrtoumax conversion failure.  Thanks to a used-uninitialized
10216         warning from gcc-4.
10217
10218 2005-04-09  Jim Meyering  <jim@meyering.net>
10219
10220         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
10221         -Wuninitialized: initialize tm0.tm_year.
10222
10223 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
10224
10225         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
10226         count, since there's no maximum.  All uses changed.
10227         Add member dsts_seen.
10228         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
10229         not being INT_MAX.
10230         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
10231         Use pc_rels_seen to decide whther a date is absolute.
10232
10233         * lib/getdate.y (number): Don't overwrite year.
10234         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
10235         check.
10236
10237 2005-04-02  Simon Josefsson  <jas@extundo.com>
10238
10239         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
10240         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
10241
10242 2005-03-28  Eric Blake  <ebb9@byu.net>
10243
10244         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
10245         where no absolute path name can be longer than PATH_MAX.
10246
10247 2005-03-27  Jim Meyering  <jim@meyering.net>
10248
10249         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
10250
10251 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
10252
10253         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
10254         "one's complement" -> "ones' complement" in comment, as per Knuth.
10255         "value of type" -> "type or expression" in comment.
10256         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
10257
10258 2005-03-26  Jim Meyering  <jim@meyering.net>
10259
10260         Comment nits.
10261         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
10262         Correct typos: s/or/of/.
10263
10264 2005-03-26  Jim Meyering  <jim@meyering.net>
10265
10266         * modules/check-include-files: Move to ../ and rename to...
10267         * check-module: ...this.
10268
10269 2005-03-25  Jim Meyering  <jim@meyering.net>
10270
10271         * modules/xvasprintf (Files): Add xalloc.h.
10272
10273 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
10274
10275         * modules/gettext (Files): config/config.rpath ->
10276         build-aux/config.rpath
10277         * modules/iconv (Files): Likewise.
10278         Problem reported by Oskar Liljeblad.
10279
10280 2005-03-23  Jim Meyering  <jim@meyering.net>
10281
10282         * modules/check-include-files: New script to check for
10283         missing dependencies, multiple includes, etc.
10284
10285         * modules/c-strtold (Depends-on): Add xalloc.
10286         * modules/c-strtod (Depends-on): Add xalloc.
10287         * modules/hash (Depends-on): Add xalloc.
10288         (Files): Remove lib/xalloc.h.
10289
10290         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
10291         * modules/userspec (Files): Add lib/inttostr.h.
10292
10293 2005-03-23  Jim Meyering  <jim@meyering.net>
10294
10295         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
10296
10297 2005-03-22  Jim Meyering  <jim@meyering.net>
10298
10299         * modules/stat-macros: New module.
10300         * modules/canonicalize, modules/euidaccess, modules/file-type,
10301         * modules/filemode, modules/lchown, modules/makepath,
10302         * modules/rmdir, modules/stat: Depend on new stat-macros module
10303         rather than listing lib/stat-macros.h manually.
10304         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
10305
10306 2005-03-22  Jim Meyering  <jim@meyering.net>
10307
10308         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
10309
10310 2005-03-22  Bruno Haible  <bruno@clisp.org>
10311
10312         * config/srclist.txt: Replace target directory 'config' with
10313         'build-aux'.
10314         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
10315         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
10316         ../build-aux/.
10317
10318 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
10319
10320         * modules/chdir-long (Depends-on): Add mempcpy.
10321
10322         * modules/acl, modules/backupfile, modules/c-strtod,
10323         modules/c-strtold, modules/canon-host, modules/canonicalize,
10324         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
10325         modules/exclude, modules/exitfail, modules/file-type,
10326         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
10327         modules/getdate, modules/getline, modules/getpagesize,
10328         modules/getpass, modules/getugroups, modules/group-member,
10329         modules/hard-locale, modules/hash, modules/human, modules/idcache,
10330         modules/inttostr, modules/long-options, modules/makepath,
10331         modules/md5, modules/memcasecmp, modules/memcoll,
10332         modules/modechange, modules/mountlist, modules/path-concat,
10333         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
10334         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
10335         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
10336         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
10337         modules/strftime, modules/strndup, modules/strverscmp,
10338         modules/timespec, modules/unlocked-io, modules/userspec,
10339         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
10340         modules/yesno:
10341         Remove lib_SOURCES line from Makefile.am section, as this is now
10342         done automatically by the corresponding Autoconf macro.
10343
10344 2005-03-21  Jim Meyering  <jim@meyering.net>
10345
10346         Changes imported from coreutils.
10347
10348         * lib/cycle-check.c: Don't include xalloc.h.
10349
10350         * lib/path-concat.c: Don't include assert.h.
10351         (path_concat): Remove assertion that would have triggered
10352         for ABASE starting with more than one slash.
10353         Reported by Andreas Schwab.
10354
10355         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
10356         properly when ABASE is an absolute file name.
10357         Correct the description of this function.
10358         Include <assert.h>.
10359         Add an assertion and a test driver.
10360         This fixes a bug introduced on 2004-07-02.
10361         Andreas Schwab reported the resulting failure of cp --parents:
10362         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
10363
10364 2005-03-21  Jim Meyering  <jim@meyering.net>
10365
10366         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
10367         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
10368
10369 2005-03-21  Jim Meyering  <jim@meyering.net>
10370         and  Paul Eggert  <eggert@cs.ucla.edu>
10371
10372         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
10373         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
10374         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
10375         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
10376         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
10377         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
10378         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
10379         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
10380         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
10381         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
10382         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
10383         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
10384         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
10385         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
10386         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
10387         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
10388         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
10389         for these modules.
10390
10391 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
10392
10393         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
10394         (which shouldn't happen), generate nothing instead of returning 0
10395         immediately, so that nstrftime (NULL, ...) doesn't return 0.
10396
10397 2005-03-16  Bruno Haible  <bruno@clisp.org>
10398
10399         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
10400         HAVE_LONGLONG_64BIT.
10401
10402 2005-03-16  Bruno Haible  <bruno@clisp.org>
10403
10404         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
10405         HAVE_LONGLONG_64BIT.
10406
10407 2005-03-16  Bruno Haible  <bruno@clisp.org>
10408
10409         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
10410         HAVE_LONGLONG_64BIT.
10411
10412 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
10413
10414         * lib/strftime.c (my_strftime): Prepend space to format so that we can
10415         reliably distinguish strftime failure from empty output on POSIX
10416         hosts.
10417
10418 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
10419
10420         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
10421         (iconv_string): Don't guess a size-zero buffer, as that might cause
10422         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
10423         result would be 'too large', where 'too large' is (heuristically)
10424         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
10425         overflow concerns.  This will prevent some unwanted malloc failures
10426         when the inputs are very large.
10427
10428 2005-03-15  Karl Berry  <karl@gnu.org>
10429
10430         * config/srclist.txt (config.rpath): from gettext.
10431         * config/config.rpath: update.
10432
10433 2005-03-15  Bruno Haible  <bruno@clisp.org>
10434
10435         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
10436         to 'negate'.
10437
10438         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
10439         variable.
10440
10441         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
10442         results.
10443
10444 2005-03-14  Simon Josefsson  <jas@extundo.com>
10445
10446         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
10447         <fx@gnu.org>.
10448
10449 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
10450
10451         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
10452         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
10453         intprops.h.
10454         * lib/strtol.c: Likewise.
10455
10456 2005-03-14  Jim Meyering  <jim@meyering.net>
10457
10458         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
10459         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
10460         to be nonzero so that we (and caller) can detect the difference
10461         between a valid zero-length expansion and an error return, even
10462         when the underlying strftime fails before writing anything into
10463         that location.
10464
10465 2005-03-14  Bruno Haible  <bruno@clisp.org>
10466
10467         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
10468         Update from GNU gettext 0.14.3.
10469
10470 2005-03-10  Jim Meyering  <jim@meyering.net>
10471
10472         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
10473
10474 2005-03-10  Jim Meyering  <jim@meyering.net>
10475
10476         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
10477         so that this module works on systems without fchdir.
10478
10479 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
10480
10481         Factor int-properties macros into a single file, except for
10482         glibc-related files.
10483         * lib/intprops.h: New file.
10484         * lib/getloadavg.c: Include it instead of limits.h.
10485         (INT_STRLEN_BOUND): Remove.
10486         * lib/human.c: Include intprops.h.
10487         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
10488         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
10489         302/1000.
10490         * lib/inttostr.h: Include intprops.h instead of limits.h.
10491         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
10492         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
10493         for consistency with intprops.h.
10494         (time_t_is_integer, twos_complement_arithmetic): Use them.
10495         * lib/sig2str.h: Include <signal.h>, intprops.h.
10496         (INT_STRLEN_BOUND): Remove.
10497         * lib/strftime.c (TYPE_SIGNED): Remove.
10498         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
10499         * lib/strtol.c: Adjust comments to match intprops.h.
10500         * lib/userspec.c: Include intprops.h.
10501         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
10502         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
10503         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
10504         instead of rolling our own expressions.
10505         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
10506
10507         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
10508         instead of int.
10509         (my_strftime): Do not mishandle years close to INT_MAX, by doing
10510         the right thing even if adding 1900 would overflow.  Similarly
10511         for tm_mon + 1 and tm_yday + 1.
10512         Make %Y always equivalent to %C%y, and similarly for %G and %g.
10513         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
10514         (DO_SIGNED_NUMBER): New macro.
10515         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
10516
10517 2005-03-07  Bruno Haible  <bruno@clisp.org>
10518
10519         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
10520
10521 2005-03-07  Bruno Haible  <bruno@clisp.org>
10522
10523         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
10524
10525 2005-03-04  Derek R. Price  <derek@ximbiot.com>
10526
10527         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
10528         (func_import): Only replace files via --import when they have actually
10529         changed.
10530
10531 2005-03-03  Derek R. Price  <derek@ximbiot.com>
10532
10533         * m4/mmap-anon.m4: New file.
10534         * m4/pagealign_alloc.m4: New file.
10535
10536 2005-03-03  Derek R. Price  <derek@ximbiot.com>
10537             Bruno Haible  <bruno@clisp.org>
10538
10539         * modules/pagealign_alloc: New file.
10540         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
10541
10542 2005-03-03  Derek R. Price  <derek@ximbiot.com>
10543             Bruno Haible  <bruno@clisp.org>
10544
10545         * lib/pagealign_alloc.h: New file.
10546         * lib/pagealign_alloc.c: New file.
10547
10548 2005-03-03  Bruno Haible  <bruno@clisp.org>
10549
10550         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
10551         Use an all-permissive copyright notice, recommended by RMS.
10552
10553 2005-03-02  Bruno Haible  <bruno@clisp.org>
10554
10555         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
10556         of AIX, the replacement has to be done only after <string.h> is
10557         included, therefore not in config.h. stpncpy.h does the replacement,
10558         and stpncpy.c uses it.
10559
10560 2005-03-02  Bruno Haible  <bruno@clisp.org>
10561
10562         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
10563         stpncpy.c uses it.
10564
10565 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
10566
10567         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
10568         The workaround isn't strictly needed for POSIX conformance, and
10569         it's too much of a pain to configure and maintain.  We'll ask
10570         people to fix their kernels instead.
10571         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
10572         (NANOSLEEP_BUG_WORKAROUND): Remove.
10573         (xnanosleep): Remove the workaround.
10574
10575 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
10576
10577         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
10578         Reported by Derek Price.
10579         (Include): Add "timespec.h".
10580
10581         * modules/xnanosleep (Depends-on): Remove gethrxtime.
10582
10583 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
10584
10585         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
10586         to detect nanosleep bug.
10587
10588 2005-03-01  Bruno Haible  <bruno@clisp.org>
10589
10590         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
10591
10592 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
10593
10594         * modules/gethrxtime: New file.
10595         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
10596         (Depends-on): Add gethrxtime.
10597         (configure.ac): Add gl_XNANOSLEEP.
10598         (Makefile.am): Remove lib_SOURCES line.
10599
10600 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
10601
10602         * m4/gethrxtime.m4, xnanosleep.m4: New files.
10603         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
10604
10605 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
10606
10607         * lib/gethrxtime.h, gethrxtime.c, xtime.h: New files.
10608         * lib/timespec.h (gettime): Return void, since it always
10609         succeeds now.  All uses changed.
10610         * lib/gettime.c (gettime) Likewise.
10611         [HAVE_NANOTIME]: Prefer nanotime.
10612         Assume gettimeofday succeeds, as POSIX requires.
10613         Assime time () succeeds, since other code already does.
10614         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
10615         (timespec_subtract): Remove.
10616         (NANOSLEEP_BUG_WORKAROUND): New constant.
10617         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
10618         things considerably.  Use it only on GNU/Linux hosts, since the
10619         workaround shouldn't be needed elsewhere.
10620
10621 2005-02-24  Bruno Haible  <bruno@clisp.org>
10622
10623         * modules/gettext (Files): Add m4/glibc2.m4.
10624
10625 2005-02-24  Bruno Haible  <bruno@clisp.org>
10626
10627         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
10628         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
10629         * m4/progtest.m4:
10630         Update from GNU gettext 0.14.2.
10631         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
10632
10633 2005-02-24  Bruno Haible  <bruno@clisp.org>
10634
10635         * lib/localcharset.c: Update from GNU gettext 0.14.2.
10636         * lib/config.charset: Update from GNU gettext 0.14.2.
10637
10638 2005-02-24  Bruno Haible  <bruno@clisp.org>
10639
10640         * lib/gettext.h: Update from GNU gettext 0.14.2.
10641
10642 2005-02-23  Simon Josefsson  <jas@extundo.com>
10643
10644         * m4/iconvme.m4: New file.
10645
10646 2005-02-23  Jim Meyering  <jim@meyering.net>
10647
10648         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
10649         change.
10650         Thanks to Bruno Haible for catching it.
10651
10652 2005-02-22  Simon Josefsson  <jas@extundo.com>
10653
10654         * modules/iconvme: New file.
10655
10656         * MODULES.html.sh: Add iconvme.
10657
10658 2005-02-22  Simon Josefsson  <jas@extundo.com>
10659
10660         * lib/iconvme.h, iconvme.c: New files, from libc.
10661
10662 2005-02-22  Simon Josefsson  <jas@extundo.com>
10663
10664         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
10665
10666 2005-02-22  Jim Meyering  <jim@meyering.net>
10667
10668         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
10669         s/ifndef/ifdef/.
10670
10671 2005-02-20  Neil Conway  <neilc@samurai.com>
10672
10673         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
10674         returned by OSX/Darwin if the specified buffer is not large
10675         enough for the hostname.
10676
10677 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
10678
10679         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
10680         pass it to _help, otherwise the latter coredumps trying to
10681         dereference state.root_argp.
10682
10683 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
10684
10685         * modules/chdir-long (Depends-on): Add memrchr.
10686         * modules/memrchr (Files): Add lib/memrchr.h.
10687         (Include): "memrchr.h".
10688
10689 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
10690
10691         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
10692
10693 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
10694
10695         * lib/memrchr.h: New file.
10696         * lib/chdir-long.c: Include it.
10697         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
10698         Don't bother including stddef.h.
10699
10700 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
10701
10702         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
10703         inclusion.
10704         Include <sys/types.h>, for dev_t.
10705         (ME_DUMMY, ME_REMOTE): Move from here....
10706         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
10707         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
10708         Dmitry V. Levin.
10709         Include mountlist.h first, to test the interface.
10710
10711 2005-01-29  Bruno Haible  <bruno@clisp.org>
10712
10713         * lib/progname.c (program_name): Initialize.
10714         Needed when linking statically on MacOS X.
10715
10716 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
10717
10718         Sync from coreutils.
10719         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
10720         (Depends-on): Add c-strtod.
10721         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
10722
10723 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
10724
10725         Sync from coreutils.
10726         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
10727
10728         Remove files that are specific to coreutils.
10729         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
10730
10731 2005-01-28  Bruno Haible  <bruno@clisp.org>
10732
10733         * modules/javacomp: New file.
10734         * MODULES.html.sh (Java): Add javacomp.
10735
10736 2005-01-28  Bruno Haible  <bruno@clisp.org>
10737
10738         * m4/javacomp.m4: New file, from GNU gettext.
10739
10740 2005-01-28  Bruno Haible  <bruno@clisp.org>
10741
10742         * lib/javacomp.sh.in: New file, from GNU gettext.
10743         * lib/javacomp.h: New file, from GNU gettext.
10744         * lib/javacomp.c: New file, from GNU gettext.
10745
10746 2005-01-26  Simon Josefsson  <jas@extundo.com>
10747
10748         * lib/gai_strerror.c: Use GPL in header.
10749
10750 2005-01-26  Bruno Haible  <bruno@clisp.org>
10751
10752         * modules/javaexec: New file.
10753         * MODULES.html.sh (Java): Add javaexec.
10754
10755 2005-01-26  Bruno Haible  <bruno@clisp.org>
10756
10757         * m4/javaexec.m4: New file, from GNU gettext.
10758
10759 2005-01-26  Bruno Haible  <bruno@clisp.org>
10760
10761         * lib/javaexec.sh.in: New file, from GNU gettext.
10762         * lib/javaexec.h: New file, from GNU gettext.
10763         * lib/javaexec.c: New file, from GNU gettext.
10764
10765 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
10766
10767         * modules/lchown (Depends-on): Remove lchown.h
10768
10769 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
10770
10771         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
10772         must be defined if the header file was not found, in order
10773         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
10774
10775 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
10776
10777         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
10778         initializers for struct pentry_state.
10779         (__argp_error): Check return value of __asprintf
10780         (__argp_failure): Translate error message
10781
10782         * lib/argp-parse.c: Removed braces around the expansion of N_()
10783
10784 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
10785
10786         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
10787         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
10788         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
10789         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
10790         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
10791         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
10792         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
10793         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
10794         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
10795         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
10796         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
10797         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
10798         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
10799         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
10800         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
10801         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
10802         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
10803         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
10804         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
10805         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
10806         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
10807         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
10808         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
10809         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
10810         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
10811         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
10812         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
10813         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
10814         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
10815         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
10816         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
10817         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
10818         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
10819         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
10820         xstrtol.m4, xstrtoumax.m4, yesno.m4:
10821         Use an all-permissive copyright notice, recommended by RMS.
10822
10823 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
10824
10825         * modules/chdir-long (Depends-on): Remove mempcpy.
10826
10827 2005-01-21  Jim Meyering  <jim@meyering.net>
10828
10829         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
10830         same value as for Solaris 9.
10831
10832         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
10833         component length.  This included changing the parameter to be
10834         of type `char *' rather than `char const *'.
10835         * lib/chdir-long.h (chdir_long): Update prototype.
10836
10837         * lib/openat.c (fdopendir, fstatat): New functions.
10838         * lib/openat.h: Include headers required for use of DIR and struct
10839         stat.
10840         [AT_SYMLINK_NOFOLLOW]: Define.
10841         (fdopendir, fstatat): Add prototypes.
10842
10843 2005-01-21  Bruno Haible  <bruno@clisp.org>
10844
10845         * modules/classpath: New file.
10846         * MODULES.html.sh (Java): Add classpath.
10847
10848 2005-01-21  Bruno Haible  <bruno@clisp.org>
10849
10850         * lib/classpath.h: New file, from GNU gettext.
10851         * lib/classpath.c: New file, from GNU gettext.
10852
10853 2005-01-20  Simon Josefsson  <jas@extundo.com>
10854
10855         * modules/version-etc-fsf: New file.
10856
10857 2005-01-20  Simon Josefsson  <jas@extundo.com>
10858
10859         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
10860         * lib/version-etc.c: Remove version_etc_copyright.
10861         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
10862         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
10863
10864 2005-01-20  Simon Josefsson  <jas@extundo.com>
10865
10866         * lib/base64.h (isbase64): Add.
10867
10868         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
10869         using a unsigned prototype, don't inline.
10870         (base64_decode): Use it.
10871
10872 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
10873
10874         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
10875         it.
10876
10877 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
10878
10879         * lib/save-cwd.c (save_cwd): Remove code to support the case
10880         where fchdir is missing or flaky.
10881
10882 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
10883
10884         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
10885
10886 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
10887
10888         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
10889         AC_LIBSOURCES now does this.
10890         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
10891         with new ullong_max module.
10892
10893 2005-01-19  Bruno Haible  <bruno@clisp.org>
10894
10895         * modules/sh-quote: New file.
10896         * MODULES.html.sh (Executing programs): Add sh-quote.
10897
10898 2005-01-19  Bruno Haible  <bruno@clisp.org>
10899
10900         * lib/sh-quote.h: New file, from GNU gettext.
10901         * lib/sh-quote.c: New file, from GNU gettext.
10902
10903 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
10904
10905         Merge from coreutils.
10906         * m4/ullong_max.m4: New file.
10907         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
10908         (gl_MACROS): Assume localeconv exists.
10909
10910 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
10911
10912         Merge changes from coreutils, as described below in several
10913         changelogs dated today.
10914
10915         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
10916         (O_DIRECTORY): Remove; not needed here, since "." must be
10917         a directory.  All uses removed.
10918         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
10919         universal on Suns, and we also need to test for IRIX.
10920         Revamp code to use 'if' rather than '#if'.
10921         Avoid unnecessary comparison of cwd->desc to 0.
10922
10923         * lib/utimens.c (futimens): Robustify the previous patch, by checking
10924         for known valid error numbers rather than observed invalid ones.
10925
10926 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
10927
10928         * modules/ullong_max: New file.
10929
10930         * modules/chdir-long, modules/openat: New files.
10931         * modules/save-cwd (Depends-on): Depend on chdir-long.
10932         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
10933
10934 2005-01-18  Jim Meyering  <jim@meyering.net>
10935
10936         Merge from coreutils.
10937         * m4/chdir-long.m4, openat.m4: New files.
10938         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
10939         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
10940         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
10941         is sane and DOES follow symlinks.  Besides, testing 20 different
10942         systems found no broken chown implementations.
10943         Prompted by a change in rsync's copy of this macro.
10944         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
10945
10946         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
10947
10948         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
10949         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
10950         NULL-means-set-to-current-time semantics.
10951         Remove temporary file immediately, rather than waiting
10952         for configure's at-exit trap code to do it.
10953
10954 2005-01-18  Jim Meyering  <jim@meyering.net>
10955
10956         * lib/version-etc.c (version_etc_copyright): Update copyright date.
10957
10958         * lib/utimens.c (futimens): Account for the fact that futimes
10959         can also fail with errno == ENOSYS or errno == ENOENT.
10960         Patch from Dmitry V. Levin.
10961
10962         Change the name of the robust chdir function from chdir to chdir_long.
10963         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
10964         (restore_cwd): Use chdir_long, not chdir.
10965         * lib/chdir-long.c: Renamed from chdir.c.
10966         * lib/chdir-long.h: Renamed from chdir.h.
10967         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
10968         Hurd.
10969
10970 2005-01-18  Bruno Haible  <bruno@clisp.org>
10971
10972         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
10973         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
10974         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
10975         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
10976         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
10977         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
10978         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
10979         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
10980         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
10981         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
10982         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
10983         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
10984         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
10985         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
10986         Use an all-permissive copyright notice, recommended by RMS.
10987
10988 2005-01-18  Bob Proulx  <bob@proulx.com>
10989
10990         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
10991         simplify offsetof() macro construct to avoid compile failure with
10992         native HP-UX 11.0 ANSI C compiler.
10993
10994 2005-01-17  Bruno Haible  <bruno@clisp.org>
10995
10996         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
10997         redundant because stpncpy.m4 takes care of it.
10998
10999 2005-01-17  Bruno Haible  <bruno@clisp.org>
11000
11001         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
11002
11003 2005-01-17  Bruno Haible  <bruno@clisp.org>
11004
11005         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
11006         used.
11007
11008 2005-01-17  Bruno Haible  <bruno@clisp.org>
11009
11010         * lib/fwriteerror.h (fwriteerror): Change specification to include
11011         fclose.
11012         * lib/fwriteerror.c: Include <stdbool.h>.
11013         (fwriteerror): At the end, close the file stream. Record whether
11014         stdout was already closed.
11015
11016 2005-01-17  Bruno Haible  <bruno@clisp.org>
11017
11018         * lib/execute.c (environ): Declare if needed.
11019         * lib/pipe.c (environ): Likewise.
11020         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
11021
11022 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11023
11024         * modules/argp: Depend on vsnprintf
11025
11026 2005-01-10  Jim Meyering  <jim@meyering.net>
11027
11028         * modules/closeout (Depends-on): Add atexit.
11029
11030 2005-01-06  Bruno Haible  <bruno@clisp.org>
11031
11032         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
11033
11034 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
11035
11036         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
11037         definitions to be after all include files, to avoid collisions.
11038         Problem reported by Bob Proulx.
11039
11040 2005-01-04  Jim Meyering  <jim@meyering.net>
11041
11042         Changes imported from coreutils.
11043         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
11044         as the mkstemp template, use a temporary directory and an
11045         8.3-friendly template to avoid trouble on systems like DJGPP.
11046         Reported by Juan M. Guerrero via Stepan Kasal.
11047         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
11048         close. Remove the temporary directory right away, rather than waiting
11049         for configure's at-exit trap code to do it.
11050         Suggestion from Stepan Kasal.
11051
11052 2005-01-01  Simon Josefsson  <jas@extundo.com>
11053
11054         * gnulib-tool: Print #include directives when --import'ing.
11055
11056 2004-12-28  Simon Josefsson  <jas@extundo.com>
11057
11058         * tests/test-base64.c: Include required header files.  Remove
11059         unused variables.
11060
11061 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
11062
11063         * modules/error (Depends-on): Remove gettext.
11064
11065 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
11066
11067         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
11068         not needed.  This removes a dependency on the gettext module.
11069         [defined _LIBC]: Do not include <libintl.h>; not needed.
11070
11071 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
11072
11073         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
11074         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
11075
11076 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
11077
11078         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
11079         HAVE_DECL_STRTOLD.
11080
11081 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
11082
11083         * modules/getdate (Depends-on): Remove alloca-opt.
11084
11085 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
11086
11087         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
11088
11089 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
11090
11091         * lib/argp-parse.c: Include <stddef.h>.
11092         (alignof, alignto): New macros.
11093         (parser_init): Don't assume that void * is aligned sufficiently
11094         for struct option.
11095
11096         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
11097         need to extend the stack.
11098         (YYINITDEPTH): New macro, so that the initial stack isn't overly
11099         large.
11100
11101 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11102
11103         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
11104
11105 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
11106
11107         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
11108         (2004-10-24) change.  Apparently this was a false alarm.
11109
11110         * modules/getdate: Depend on alloca-opt, not alloca.
11111
11112 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
11113
11114         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
11115         Remove now-obsolete comment about AIX.
11116         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
11117         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
11118         (YYMAXDEPTH): New macro.
11119
11120 2004-12-18  Simon Josefsson  <jas@extundo.com>
11121
11122         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
11123
11124 2004-12-18  Bruno Haible  <bruno@clisp.org>
11125
11126         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
11127
11128 2004-12-18  Bruno Haible  <bruno@clisp.org>
11129
11130         * lib/fatal-signal.c (fatal_signals): Make non-const.
11131         (init_fatal_signals): New function.
11132         (uninstall_handlers, install_handlers): Ignore signals that were set to
11133         SIG_IGN.
11134         (at_fatal_signal): Call init_fatal_signals.
11135         (init_fatal_signal_set): Likewise. Ignore signals that were set to
11136         SIG_IGN.
11137         Reported by Paul Eggert.
11138
11139 2004-12-18  Bruno Haible  <bruno@clisp.org>
11140
11141         * doc/alloca.texi: New file.
11142         * doc/alloca-opt.texi: New file.
11143
11144 2004-12-17  Jim Meyering  <jim@meyering.net>
11145
11146         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
11147         Otherwise, install-sh could exit with improper exit status when
11148         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
11149
11150 2004-12-16  Simon Josefsson  <jas@extundo.com>
11151
11152         * tests/test-base64.c: Add license.
11153
11154 2004-12-15  Stepan Kasal  <address@hidden>
11155
11156         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
11157
11158 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
11159
11160         * modules/getcwd (Files): Add m4/d-ino.m4.
11161         Suggested by Mark D. Baushke.
11162
11163 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
11164
11165         * lib/getdate.y (textint): New member "negative".
11166         (time_zone_hhmm): New function.
11167         Expect 14 shift-reduce conflicts, not 13.
11168         (o_colon_minutes): New rule.
11169         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
11170         (yylex): Set the "negative" member of signed numbers.
11171
11172 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
11173
11174         * doc/getdate.texi (Time of day items, Time zone items):
11175         Describe new formats +00:00, UTC+00:00.
11176
11177 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
11178
11179         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
11180         spurious "-l"s.  Problem reported by Stepan Kasal.
11181
11182 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
11183
11184         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
11185         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
11186
11187 2004-12-04  Simon Josefsson  <jas@extundo.com>
11188
11189         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
11190         Vandoorselaere <yoann@prelude-ids.org>.
11191
11192 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
11193
11194         Changes imported from coreutils.
11195         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
11196         exist.
11197         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
11198
11199 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
11200
11201         Changes imported from coreutils.
11202         * lib/hard-locale.c: Assume <locale.h> exists.
11203         Include "strdup.h".
11204         (GLIBC_VERSION): New macro.
11205         (hard_locale): Assume setlocale exists.
11206         Rewrite to avoid #ifdef.
11207         Use strdup rather than malloc + strcpy.
11208         * lib/human.c: Assume <locale.h> exists.
11209         (human_readable): Assume localeconv exists.
11210
11211 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
11212
11213         * modules/hard-locale (Depends-on): Add strdup.
11214
11215 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
11216
11217         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
11218         convert T2, not T.  (Imported from libc.)
11219
11220 2004-11-30  Simon Josefsson  <jas@extundo.com>
11221
11222         * modules/restrict (License): Change to LGPL.
11223
11224 2004-11-30  Simon Josefsson  <jas@extundo.com>
11225
11226         * m4/restrict.m4: Add copyright and copying conditions.
11227
11228 2004-11-30  Simon Josefsson  <jas@extundo.com>
11229
11230         * m4/base64.m4: New file.
11231
11232 2004-11-30  Simon Josefsson  <jas@extundo.com>
11233
11234         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
11235         base64.
11236
11237         * tests/test-base64.c: New file.
11238
11239         * modules/base64: New file.
11240
11241 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
11242
11243         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
11244         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
11245
11246         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
11247
11248 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
11249
11250         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
11251         (__getcwd.c): Don't restore errno; glibc doesn't.
11252         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
11253         first, falling back to our code only if its results look suspicious.
11254         Ensure that the resulting buffer is only as large as necessary.
11255
11256         * lib/readutmp.c: Include readutmp.h first.
11257         Include <errno.h>, since readutmp.h no longer does that.
11258         * lib/readutmp.h: Don't include <errno.h>,
11259         <sys/param.h>, <time.h>; not needed to establish interface.
11260         (errno): Remove decl.
11261         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
11262         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
11263         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
11264
11265 2004-11-28  Simon Josefsson  <jas@extundo.com>
11266
11267         * lib/base64.h, base64.c: New file.
11268
11269 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
11270
11271         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
11272
11273 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
11274
11275         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
11276         (Depends-on): Remove pathmax, same.  Add mempcpy.
11277         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
11278         (Makefile.am): Append getcwd.h to lib_SOURCES.
11279         (Include): Add getcwd.h.
11280         (Maintainer): Change from Jim Meyering to "all, glibc",
11281         since getdate now uses intended-for-glibc code.
11282         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
11283         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
11284
11285 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
11286
11287         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
11288         HP's ANSI C compiler.
11289         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
11290         Declaring int functions causes warnings on some modern systems and
11291         shouldn't be needed to compile on ancient ones.
11292         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
11293         defined.
11294
11295         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
11296         with the following changes.
11297         (__set_errno): Parenthesize properly.
11298         Include <stdbool.h>.
11299         (MIN, MAX, MATCHING_INO): New macros.
11300         (__getcwd): Define with prototype, not K&R form.
11301         Use heuristics to allocate default buffer on stack if possible.
11302         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
11303         behavior, and to avoid the PATH_MAX limit when computing
11304         ../../../../...
11305         Use MATCHING_INO to compare inode number to file.
11306         Check for arithmetic overflow in size calculations.
11307         Fix bug in reallocation of dot array that caused getcwd to fail
11308         on directories nested deeper than 75.
11309         Be more careful about saving errno on error.
11310         Do not use realloc; use only free+malloc, as this is a bit
11311         more flexible and avoids a needless copy operation.
11312         Do not inspect st_dev and st_ino for symbolic links; POSIX
11313         doesn't specify the latter.
11314         Check for closedir errors.
11315         Avoid needless casts.
11316         Use "#ifdef weak_alias" around weak_alias, to be like other
11317         glibc code.
11318         The following changes to getcwd.c have effect only when used in
11319         gnulib; they have no effect inside glibc proper.
11320         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
11321         as alloca isn't used.
11322         (alloca, __alloca): Likewise.
11323         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
11324         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
11325         unconditionally, as gnulib assumes C89 or better.
11326         Do not include <sys/param.h>.
11327         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
11328         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
11329         better.
11330         (NULL) [!defined NULL]: Remove; we assume C89 or better.
11331         Include <dirent.h> in a way that is compatible with modern Autoconf.
11332         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
11333         New macros, if not already defined.
11334         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
11335         Use "_LIBC", not "defined _LIBC", for consistency.
11336         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
11337         a mempcpy module.
11338         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
11339         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
11340         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
11341         credit only to Jim Meyering and adjust the copyright dates.
11342         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
11343         <stdlib.h>, <unistd.h>, "pathmax.h".
11344         Instead, include "xgetcwd.h" (first) and "getcwd.h".
11345         (INITIAL_BUFFER_SIZE): Remove.
11346         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
11347
11348 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
11349
11350         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
11351         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
11352         Use the _ONCE methods, for efficiency.
11353         Check for fcntl.h.  In test program, include <errno.h>
11354         and <fcntl.h> if available.  Remove old K&R cruft from
11355         test program.  Check for common errors in GNU/Linux,
11356         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
11357         don't do AC_LIBOBJ, as that's getcwd.m4's job.
11358         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
11359         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
11360         name accordingly.
11361         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
11362         accommodate new getcwd.c.
11363         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
11364         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
11365         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
11366         that's all we need now.
11367
11368 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11369
11370         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
11371         argp-parse.c depends on getopt internals, that means we should
11372         always use our getopt, to be on the safe side.
11373         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
11374         order not to spoil the result of an eventual previous invocation
11375         of gl_GETOPT_SUBSTITUTE.
11376
11377 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
11378
11379         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
11380         redefinition warnings. To avoid them, include the defines
11381         in `#if !defined __need_getopt ... #endif'. The only place
11382         where __getopt_argv_const is used is in definitions
11383         of getopt_long and getopt_long_only below, which are as well
11384         protected by `#ifndef __need_getopt'.
11385         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
11386         __need_getopt after including <stdio.h> and <unistd.h> These
11387         headers might have defined it.
11388
11389 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
11390
11391         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
11392
11393 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
11394
11395         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
11396         (futimens): New function, which uses futimes if available.
11397         (futimens, utimens): Support timespec==NULL, with same semantics
11398         as utime and utimens.
11399         * lib/utimens.h (futimens): New decl.
11400
11401 2004-11-23  Jim Meyering  <jim@meyering.net>
11402
11403         * lib/getopt_.h: Remove trailing blanks.
11404
11405 2004-11-23  Jim Meyering  <jim@meyering.net>
11406
11407         * lib/__fpending.c: Add comment.
11408
11409 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
11410
11411         * modules/canonicalize (Depends-on): Add xreadlink.
11412         Problem reported by James Youngman.
11413
11414 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
11415
11416         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
11417         New macros.
11418         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
11419         optopt): Use them instead of invoking ## directly; otherwise, the
11420         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
11421
11422 2004-11-19  Bruno Haible  <bruno@clisp.org>
11423
11424         * lib/strtok_r.c: Move comments from here...
11425         * lib/strtok_r.h: ... to here.
11426
11427 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
11428
11429         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
11430         implementations that mishandle size_t overflow.
11431
11432 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
11433
11434         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
11435         might fail.  Problem reported by Yoann Vandoorselaere.
11436         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
11437         implementations that mishandle size_t overflow.
11438
11439 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
11440
11441         * modules/canon-host (Depends-on): Add strdup.
11442
11443 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
11444
11445         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
11446
11447 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
11448
11449         * lib/canon-host.c: Include "strdup.h".
11450         (canon_host): Use getaddrinfo if available, so that IPv6 works.
11451         Use strdup instead of malloc/strcpy to duplicate strings.
11452
11453         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
11454         (human_space_before_unit): New constant.
11455         * lib/human.c (human_readable): Support it.
11456
11457         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
11458         (xgetcwd): Set errno correctly when failing.
11459         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
11460         the failure is actually due to a PATH_MAX problem.
11461
11462         Further getopt changes to make it more likely that glibc will
11463         buy the changes back.
11464         * lib/getopt.c (POSIXLY_CORRECT): New constant.
11465         (getopt): Use it, so to preserve glibc semantic
11466         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
11467         when compiling for libc.
11468         * lib/getopt_.h (__getopt_argv_const): Bring it back.
11469         (getopt_long, getopt_long_only): Use it.
11470
11471         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
11472         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
11473         (getopt): Argv is now char * const *, as per standard.
11474         (_getopt_internal_r, _getopt_internal): Argv is now char **,
11475         not char *__getopt_argv_const *.
11476         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
11477         _getopt_long_only_r): Likewise.
11478         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
11479         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
11480         _getopt_long_r, _getopt_long_only_r): Likewise.
11481         * lib/getopt_.h (__getopt_argv_const): Remove.
11482         (getopt): Argv is now char * const *, as per standard.
11483
11484         * lib/getdate.y (tORDINAL): New token.
11485         (day, relunit): Allow it for relative times.
11486         (relative_time_table): Use tORDINAL for ordinals.
11487
11488 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
11489
11490         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
11491         Document that "second" isn't allowed as an ordinal number.
11492
11493 2004-11-16  Jim Meyering  <jim@meyering.net>
11494
11495         * modules/closeout (Depends-on): Add fpending.
11496
11497 2004-11-15  Jim Meyering  <jim@meyering.net>
11498
11499         * lib/closeout.c: Include "__fpending.h" once again.
11500         Include <stdbool.h>.
11501         (close_stdout): Don't fail just because stdout was closed initially,
11502         since some programs don't write to stdout in the normal course of
11503         operation (other than --version and --help), and we don't want this
11504         function to make e.g. `touch file >&-' fail.
11505         But do fail if it was closed and someone has tried to write to it.
11506         E.g., `printf foo >&-' must fail.
11507
11508 2004-11-13  Jim Meyering  <jim@meyering.net>
11509
11510         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
11511
11512 2004-11-12  Simon Josefsson  <jas@extundo.com>
11513
11514         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
11515         small doc fix is still pending.
11516
11517 2004-11-11  Simon Josefsson  <jas@extundo.com>
11518
11519         * modules/strtok_r: New file.
11520
11521         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11522         strtok_r.
11523
11524 2004-11-11  Simon Josefsson  <jas@extundo.com>
11525
11526         * m4/strtok_r.m4: New file.
11527
11528         * m4/getopt.m4: Replace opterr.
11529
11530 2004-11-11  Simon Josefsson  <jas@extundo.com>
11531
11532         * lib/strtok_r.h, strtok_r.c: New file.
11533
11534 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
11535
11536         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
11537         of replacing opterr, getopt, etc.  This should handle the
11538         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
11539
11540 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
11541
11542         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
11543         we can stop lying to compilers about the constness of argv when we
11544         are compiled outside glibc.
11545         (getopt, getopt_long, getopt_long_only): Use it.
11546         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
11547         _getopt_internal, getopt): Likewise.
11548         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
11549         _getopt_long_only_r): Likewise.
11550         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
11551         _getopt_long_r, _getopt_long_only_r): Likewise.
11552
11553         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
11554         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
11555         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
11556         the other external symbols.
11557         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
11558         declaration, since the above renaming now works around collisions.
11559
11560 2004-11-11  Jim Meyering  <jim@meyering.net>
11561
11562         * lib/linebreak.c: Remove trailing blanks.
11563         * lib/alloca_.h: Likewise.
11564         * lib/acosl.c: Likewise.
11565         * lib/euidaccess.c: Likewise.
11566         * lib/allocsa.h: Likewise.
11567
11568 2004-11-10  Simon Josefsson  <jas@extundo.com>
11569
11570         * m4/getaddrinfo.m4: New file.
11571
11572 2004-11-10  Simon Josefsson  <jas@extundo.com>
11573
11574         * lib/getaddrinfo.h, getaddrinfo.c: New files.
11575
11576 2004-11-10  Simon Josefsson  <jas@extundo.com>
11577
11578         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11579         getaddrinfo.
11580
11581         * modules/getaddrinfo: New file.
11582
11583 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
11584
11585         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
11586
11587 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
11588
11589         * lib/mktime.c (SHR): New macro, which is a portable
11590         substitute for >> that should work even on Crays.
11591         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
11592         Problem reported by Mark D. Baushke in
11593         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
11594         * lib/getdate.y (SHR): Likewise.
11595         (tm_diff): Use it.
11596         * lib/strftime.c (SHR): Likewise.
11597         (tm_diff): Use it.
11598         * lib/quotearg.c (struct quoting_options): Use unsigned int for
11599         quote_these_too, so that right shifts are well defined.  All uses
11600         changed.
11601
11602 2004-11-10  Jim Meyering  <jim@meyering.net>
11603
11604         Ensure that no close failure goes unreported.
11605         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
11606         return early when it seems there's nothing to flush.
11607         Don't include __fpending.h.
11608
11609 2004-11-10  Jim Meyering  <jim@meyering.net>
11610
11611         * modules/closeout (Depends-on): Remove fpending.
11612
11613 2004-11-10  Jim Meyering  <jim@meyering.net>
11614
11615         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
11616
11617 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
11618
11619         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
11620         gl_FUNC_STRFTIME.
11621         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
11622         and AC_REQUIRE when possible, to avoid duplicate checks.
11623         Check for <wchar.h>.
11624
11625 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
11626
11627         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
11628
11629 2004-11-09  Bruno Haible  <bruno@clisp.org>
11630
11631         * m4/sockpfaf.m4: New file.
11632
11633 2004-11-05  Bruno Haible  <bruno@clisp.org>
11634
11635         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
11636         Reported by Mark D. Baushke <mdb@cvshome.org>.
11637
11638 2004-11-04  Bruno Haible  <bruno@clisp.org>
11639
11640         2004-09-11  Bruno Haible  <bruno@clisp.org>
11641                 * allocsa.valgrind: New file.
11642         2004-02-06  Bruno Haible  <bruno@clisp.org>
11643                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
11644                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
11645                 Reported by Christopher Seip <chris.seip@hp.com>.
11646
11647 2004-11-04  Bruno Haible  <bruno@clisp.org>
11648
11649         * modules/allocsa (Files): Add lib/allocsa.valgrind.
11650         (Makefile.am): Distribute it.
11651
11652 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
11653
11654         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
11655         with errno == ERANGE if the buffer is too small.
11656         Problem reported by Mark D. Baushke.
11657
11658 2004-11-03  Albert Chin <china@thewrittenword.com>
11659             Paul Eggert  <eggert@cs.ucla.edu>
11660
11661         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
11662         equivalent, substitute $ac_type for equivalent type rather than
11663         blindly using uint32_t *always* which won't work if uint32_t is not
11664         available.  Define _UINT32_T to work around typedef of uint32_t if
11665         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
11666         2.5.1.
11667
11668 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
11669
11670         * m4/jm-macros.m4: Sync from coreutils.
11671         (gl_MACROS): Check for mbrlen, for pathchk.
11672         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
11673
11674 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
11675
11676         * lib/xreadlink.c (MAXSIZE): New macro.
11677         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
11678         size does not exceed MAXSIZE.  Avoid cast.
11679         As suggested by Mark D. Baushke in
11680         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
11681         if readlink fails with buffer size just under MAXSIZE, try again
11682         with MAXSIZE.
11683
11684 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
11685
11686         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
11687
11688 2004-11-02  Derek R. Price  <derek@ximbiot.com>
11689         and  Paul Eggert  <eggert@cs.ucla.edu>
11690
11691         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
11692         (get_date): Overparenthesize to avoid GCC warning.
11693
11694 2004-11-02  Bruno Haible  <bruno@clisp.org>
11695
11696         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
11697         returns void.
11698
11699 2004-11-02  Bruno Haible  <bruno@clisp.org>
11700
11701         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
11702         function returns void.
11703
11704 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
11705
11706         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
11707         fflush_unlocked, flockfile, funlockfile, funlockfile,
11708         fputs_unlocked, putc_unlocked.
11709
11710 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
11711
11712         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
11713         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
11714         already declared.
11715
11716 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
11717
11718         * modules/getdate (Files): Add doc/getdate.texi.
11719         (Depends-on): Add setenv, xalloc.
11720
11721 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
11722
11723         * lib/getdate.y: Add support for TZ="foo" within a date string.
11724         Fix some bugs near time_t boundaries.  Reject dates with
11725         out-of-range components, e.g., "Sept 31".
11726         Include <stdlib.h>, "setenv.h", "xalloc.h".
11727         (ISDIGIT_LOCALE): Remove; unused.
11728         Note that the TZ and time functions used here are not reentrant.
11729         (mktime_ok, get_tz): New functions.
11730         (TZBUFSIZE): New constant.
11731         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
11732         This requires that we sometimes generate our own TZ="XXX..." setting.
11733
11734 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
11735
11736         * doc/getdate.texi: New file, from coreutils with modifications for
11737         the new TZ parsing.
11738
11739 2004-10-27  Derek R. Price  <derek@ximbiot.com>
11740
11741         * lib/mktime.c (not_equal_tm): Remove redundant check.
11742
11743 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
11744
11745         * modules/regex (lib_SOURCES): Add regex.c.
11746         Reported by James Youngman in
11747         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
11748
11749 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
11750
11751         * lib/getdate.y: Use Bison 1.875 features, and some minor
11752         code cleanups.  This change does not affect semantics.
11753         Don't include <stdlib.h>; no longer needed.
11754         Don't include unlocked-io.h; only the "#if TEST" code uses
11755         stdio, and performance isn't crucial there.
11756         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
11757         Bison 1.875 features as described below.
11758         All uses of "PC." replaced by "pc->".
11759         (YYSTYPE): Add a forward declaration.
11760         (yylex, yyerror): Use full prototypes in forward decls.
11761         Use "%pure-parser" rather than obsolescent "%pure_parser".
11762         Use %parse-param and %lex-param instead of obsolescent
11763         YYPARSE_PARAM and YYLEX_PARAM.
11764         (meridian_table, month_and_day_table, time_units_table,
11765         relative_time_table, time_zone_table, military_table,
11766         lookup_zone, lookup_word, get_date):
11767         Use NULL instead of 0 where appropriate.
11768         (to_hour): Avoid abort (), to avoid a dependency on
11769         stdlib.h.
11770         (yyerror, yylex): Now accepts parser_control * arg.
11771         (main) [TEST]: Use '\0' rather than 0 for char.
11772
11773 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
11774
11775         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
11776
11777 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
11778
11779         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
11780         It's now the caller's responsibility to handle the case where
11781         !HAVE_GETPAGESIZE && !defined getpagesize.
11782
11783         * lib/mktime.c (leapyear): Arg is long int, not int.
11784
11785 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
11786
11787         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
11788
11789 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
11790
11791         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
11792         missing.  Problem reported by James Youngman.
11793
11794 2004-10-16  Simon Josefsson  <jas@extundo.com>
11795
11796         * gnulib-tool: Fix comments.  Fix parse problem.
11797         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
11798
11799 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
11800
11801         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
11802         implementation of getopt_long.  Problem reported by Alexander Taler in:
11803         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
11804
11805 2004-10-15  Bruno Haible  <bruno@clisp.org>
11806
11807         * gnulib-tool: Untabify. Initialize supplied_libname.
11808         (func_usage): More homogenous output.
11809         (func_modules_transitive_closure, func_modules_to_filelist,
11810         func_emit_lib_Makefile_am): New functions.
11811         (func_import): New function, extracted from big case statement. Use
11812         func_get_license, func_modules_transitive_closure,
11813         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
11814         opt_lgpl. Don't use test -a, as it's not portable.
11815         (func_create_testdir): Use func_modules_transitive_closure,
11816         func_modules_to_filelist, func_emit_lib_Makefile_am.
11817
11818 2004-10-15  Bruno Haible  <bruno@clisp.org>
11819
11820         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
11821
11822 2004-10-15  Bruno Haible  <bruno@clisp.org>
11823
11824         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
11825         the portions belonging to each module.
11826         Suggested by Derek Robert Price <derek@ximbiot.com>.
11827
11828 2004-10-12  Simon Josefsson  <jas@extundo.com>
11829
11830         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
11831         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
11832         to real functions.
11833
11834 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
11835
11836         * modules/vsnprintf: New file.
11837
11838 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
11839
11840         * m4/vsnprintf.m4: New file.
11841
11842 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
11843
11844         * lib/vsnprintf.h: New file.
11845         * lib/vsnprintf.c: New file.
11846
11847 2004-10-11  Bruno Haible  <bruno@clisp.org>
11848
11849         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
11850         vsnprintf.
11851
11852 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
11853
11854         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
11855
11856 2004-10-07  Bruno Haible  <bruno@clisp.org>
11857
11858         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
11859         fits into the provided buffer.
11860
11861 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
11862
11863         * lib/diacrit.c, diacrit.h: Add GPL notice.
11864
11865         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
11866         notice.
11867         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
11868         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
11869         This avoids a potential constant-folding bug.
11870
11871 2004-10-05  Bruno Haible  <bruno@clisp.org>
11872
11873         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
11874         for the declaration of strsep.
11875
11876 2004-10-05  Bruno Haible  <bruno@clisp.org>
11877
11878         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
11879
11880 2004-10-04  Simon Josefsson  <jas@extundo.com>
11881
11882         * modules/memmem: New file.
11883         * tests/test-memmem.c: New file.
11884         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
11885
11886 2004-10-04  Simon Josefsson  <jas@extundo.com>
11887
11888         * m4/memmem.m4: New file.
11889
11890 2004-10-04  Simon Josefsson  <jas@extundo.com>
11891
11892         * lib/memmem.h: New file.
11893         * lib/memmem.c: New file, taken from glibc.
11894
11895 2004-10-04  Simon Josefsson  <jas@extundo.com>
11896
11897         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
11898         '#ifdef USE_UNLOCKED_IO'.
11899
11900 2004-10-04  Simon Josefsson  <jas@extundo.com>
11901
11902         * config/srclist.txt: Add memmem from glibc.
11903
11904 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
11905
11906         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
11907
11908         * modules/argmatch, modules/argp, modules/closeout, modules/error,
11909         modules/exclude, modules/getdate, modules/getline,
11910         modules/getndelim2, modules/getpass, modules/getpass-gnu,
11911         modules/getusershell, modules/linebuffer, modules/md5,
11912         modules/mountlist, modules/posixtm, modules/readtokens,
11913         modules/readutmp, modules/regex, modules/sha1,
11914         modules/version-etc, modules/yesno:
11915         Remove dependency on unlocked-io.
11916
11917 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
11918
11919         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
11920
11921         * m4/unlocked-io.m4: Add copyright notice.
11922         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
11923
11924 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
11925
11926         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
11927         * lib/xmalloc.c (xmemdup): Likewise.
11928         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
11929         XFREE): Remove these long-obsolescent macros.
11930         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
11931         * lib/xstrdup.c: Remove.
11932
11933         * lib/regex.c (re_comp): Cast gettext return value to char *,
11934         Problem reported by Martin Neitzel via Mark D. Baushke.
11935
11936 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
11937
11938         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
11939         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
11940         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
11941         regex.c, sha1.c, version-etc.c, yesno.c:
11942         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
11943         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
11944         the includer's responsibility.
11945
11946         Sync from coreutils.
11947
11948         * lib/modechange.c (mode_compile): Don't decrement a pointer that
11949         points to the start of a string, as the C Standard says the
11950         resulting behavior is undefined.
11951
11952         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
11953         simple -> simple_backups, numbered_existing ->
11954         numbered_existing_backups, numbered -> numbered_backups
11955         to avoid shadowing problems.  All uses changed.
11956         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
11957         * lib/backupfile.c (check_extension, numbered_backup):
11958         Rename locals to avoid shadowing 'basename'.
11959         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
11960         once.
11961
11962         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
11963         * lib/.cvsignore: Add getopt.h.
11964
11965 2004-10-04  Bruno Haible  <bruno@clisp.org>
11966
11967         * modules/README: New file.
11968         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
11969         not a module.
11970
11971 2004-10-02  Jim Meyering  <jim@meyering.net>
11972
11973         * lib/dirfd.h, getpagesize.h: Add copyright notice.
11974
11975 2004-10-01  Yoann Vandoorselaere <yoann@prelude-ids.org>
11976
11977         * modules/strsep: New file.
11978
11979 2004-10-01  Yoann Vandoorselaere <yoann@prelude-ids.org>
11980
11981         * m4/strsep.m4: New file.
11982
11983 2004-10-01  Yoann Vandoorselaere <yoann@prelude-ids.org>
11984
11985         * lib/strsep.h: New file.
11986         * lib/strsep.c: New file.
11987
11988 2004-10-01  Simon Josefsson  <jas@extundo.com>
11989
11990         * lib/snprintf.c (snprintf): Handle size==0.
11991
11992 2004-10-01  Simon Josefsson  <jas@extundo.com>
11993             Bruno Haible  <bruno@clisp.org>
11994
11995         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
11996         (snprintf): Declare 'args'.
11997
11998 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
11999
12000         * lib/snprintf.c: Remove comments as to why each header is needed.
12001
12002 2004-10-01  Bruno Haible  <bruno@clisp.org>
12003
12004         * MODULES.html.sh: Add strsep.
12005
12006 2004-09-30  Simon Josefsson  <jas@extundo.com>
12007
12008         * modules/snprintf: New file.
12009
12010 2004-09-30  Simon Josefsson  <jas@extundo.com>
12011
12012         * m4/snprintf.m4: New file.
12013
12014 2004-09-30  Simon Josefsson  <jas@extundo.com>
12015
12016         * lib/snprintf.h, snprintf.c: New files.
12017
12018 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12019
12020         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
12021         (hol_entry_help): Never translate an empty string.
12022         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
12023         * lib/argp.h (OPTION_NO_TRANS): New option.
12024
12025 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
12026
12027         * modules/argp (Maintainer): Replace Simon Josefsson
12028         by Sergey Poznyakoff.
12029
12030 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
12031
12032         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
12033         changes merged back into glibc.
12034
12035 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
12036
12037         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
12038
12039 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
12040
12041         * lib/xvasprintf.c: Include xalloc.h.
12042         (xvasprintf): Use xalloc_die, not xmalloc_die.
12043
12044 2004-09-29  Bruno Haible  <bruno@clisp.org>
12045
12046         * modules/alloca-opt: New file, derived from modules/alloca.
12047         * modules/allocsa: Depend on alloca-opt instead of alloca.
12048         * modules/setenv: Likewise.
12049         * modules/vasnprintf: Likewise.
12050         * MODULES.html.sh: Add alloca-opt.
12051
12052 2004-09-28  Simon Josefsson  <jas@extundo.com>
12053
12054         * gnulib-tool: New parameter --lgpl, to asseert that modules are
12055         LGPL, and to replace license template from GPL to LGPL.
12056
12057 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
12058
12059         * modules/dummy: Change license to LGPL.
12060
12061 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
12062
12063         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
12064
12065 2004-09-24  Simon Josefsson  <jas@extundo.com>
12066
12067         * modules/minmax (License): Change from GPL to LGPL.
12068
12069 2004-09-23  Simon Josefsson  <jas@extundo.com>
12070
12071         * gnulib-tool (--import): Typo.
12072
12073 2004-09-23  Simon Josefsson  <jas@extundo.com>
12074
12075         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
12076
12077 2004-09-22  Bruno Haible  <bruno@clisp.org>
12078
12079         * modules/*: Add 'License' field.
12080         * gnulib-tool: Accept --extract-license option.
12081         (func_get_license): New function.
12082
12083 2004-09-21  Bruno Haible  <bruno@clisp.org>
12084
12085         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
12086         Reported by Simon Josefsson.
12087
12088 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
12089
12090         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
12091         gl_AC_TYPE_LONG_LONG.
12092
12093 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
12094
12095         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
12096
12097 2004-09-18  Simon Josefsson  <jas@extundo.com>
12098         and  Paul Eggert  <eggert@cs.ucla.edu>
12099
12100         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
12101         calls with autoreconf.  Define GL_LIB.
12102
12103 2004-09-14  Karl Berry  <karl@gnu.org>
12104
12105         * config/srclist.txt: unsync setenv.c, sigh.
12106
12107 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
12108
12109         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
12110         Problem reported by Bruno Haible in:
12111         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
12112
12113 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
12114
12115         * config/srclist.txt: Comment out argp-pvh.c.
12116
12117 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
12118
12119         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
12120         in case some system header has #define'd it.  Problem reported by
12121         Soeren D. Schulze in
12122         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
12123
12124 2004-09-09  Karl Berry  <karl@gnu.org>
12125
12126         * regex.[ch]: delete from the root.  These were supposed to be
12127                 synced with emacs cvs, but this has not happened for about
12128                 a year, and anyway nothing else uses emacs regex.[ch].
12129                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
12130                 lib/regex[.ch] is untouched.
12131
12132 2004-09-09  Bruno Haible  <bruno@clisp.org>
12133
12134         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
12135
12136 2004-09-09  Bruno Haible  <bruno@clisp.org>
12137
12138         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
12139         modifications.
12140         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
12141
12142 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
12143
12144         * modules/xvasprintf: New file.
12145         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
12146
12147 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
12148
12149         * lib/xvasprintf.h: New file.
12150         * lib/xvasprintf.c: New file.
12151         * lib/xasprintf.c: New file.
12152
12153 2004-09-08  Bruno Haible  <bruno@clisp.org>
12154
12155         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
12156
12157 2004-09-08  Bruno Haible  <bruno@clisp.org>
12158
12159         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
12160         length is > INT_MAX.
12161         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
12162         more.
12163
12164 2004-09-08  Bruno Haible  <bruno@clisp.org>
12165
12166         * lib/stdint_.h: New file, taken from GNU clisp.
12167
12168 2004-09-08  Bruno Haible  <bruno@clisp.org>
12169             Oskar Liljeblad  <oskar@osk.mine.nu>
12170
12171         * modules/stdint: New file.
12172         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
12173
12174 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12175
12176         Import from coreutils.
12177         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
12178         strings on unbounded length.  alloca's performance benefits aren't
12179         that important here.
12180         (V_STRDUP): Remove.
12181         (parse_with_separator): New function, with most of the internals
12182         of the old parse_user_spec.  Allow user to omit both user and group,
12183         for compatibility with FreeBSD.
12184         Clone only the user name, not the entire spec.
12185         Do not set *uid, *gid unless entirely successful.
12186         Avoid memory leak in some failing cases.
12187         Fix regression for USER.GROUP reported by Dmitry V. Levin in
12188         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
12189         (parse_user_spec): Rewrite to use parse_with_separator.
12190
12191 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12192
12193         * modules/userspec: Don't depend on alloca.
12194
12195 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12196
12197         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
12198
12199 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12200
12201         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
12202         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
12203         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
12204
12205 2004-08-16  Simon Josefsson  <jas@extundo.com>
12206
12207         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
12208         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
12209         Add --dry-run for --import.
12210         Let user provided command line parameters override configure.ac
12211         settings.
12212
12213 2004-08-12  Simon Josefsson  <jas@extundo.com>
12214
12215         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
12216         as discussed with Paul Eggert in threads rooted at
12217         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
12218         and
12219         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
12220         Before, the test was empty, and relied on ELIDE_CODE in source
12221         code.)
12222         (gl_PREREQ_GETOPT): New macro.
12223         (gl_GETOPT): Use them.
12224
12225 2004-08-12  Simon Josefsson  <jas@extundo.com>
12226
12227         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
12228         * lib/getopt_.h: Renamed from getopt.h.
12229
12230 2004-08-12  Simon Josefsson  <jas@extundo.com>
12231
12232         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
12233         Change default library name from libfoo to libgnu.
12234         Now, if you have a configure.ac that says:
12235                 gl_SOURCE_BASE(gl)
12236                 gl_M4_BASE(gl/m4)
12237                 gl_MODULES(error getopt etcetera)
12238                 gl_INIT
12239         you can import all you need by running:
12240                 ../gnulib/gnulib-tool --import
12241
12242         * modules/getopt (Files): Rename getopt.h to getopt_.h.
12243         (Makefile.am): Rewrite, use logic from argz.
12244         (Include): Use <getopt.h> instead of "getopt.h".
12245
12246 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
12247
12248         * modules/argp (Files): Add m4/unlocked-io.m4.
12249         (Depends-on): Add extensions.
12250
12251 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
12252
12253         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
12254         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
12255         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
12256         Check for program_invocation_name, program_invocation_short_name,
12257         flockfile, funlockfile, features.h, _getopt_long_only_r.
12258
12259 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
12260
12261         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
12262         its complicated substitute.
12263         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
12264         and program_invocation_name.
12265         (__argp_basename) [!_LIBC]: Remove; the only use was
12266         replaced by its body.
12267         (__argp_short_program_name): Change condition from
12268         !defined __argp_short_program_name to
12269         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
12270         to match argp-namefrob.h.
12271         (__argp_failure): Don't assume strerror_r returns char *.
12272         * lib/argp-parse.c (N_): Define unconditionally.
12273         (argp_default_options): Fill out initializers with 0 to avoid
12274         gcc warnings.
12275
12276 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
12277
12278         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
12279         getopt1.c.
12280
12281 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12282
12283         Merge from coreutils.
12284
12285         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
12286
12287         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
12288         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
12289
12290 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12291
12292         Merge from coreutils.
12293
12294         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
12295         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
12296         for Reliant Unix 5.43.
12297
12298         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
12299         (union fooround): Use uintmax_t, not long int.
12300         The rest is a merge from libc:
12301         [defined _LIBC]: Include <shlib-compat.h>.
12302         (_obstack) [defined _LIBC]: Remove after 2.3.4.
12303
12304         * lib/settime.c (settime): Recode to avoid warning with
12305         Sun Forte C 6U2.
12306
12307         * lib/strverscmp.c: Convert to UTF-8.
12308
12309 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12310
12311         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
12312         m4/uintmax_t.m4.
12313
12314 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12315
12316         * modules/xalloc-die: New file.
12317         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
12318
12319         * modules/md5 (Files): Add m4/uint32_t.m4.
12320         * modules/sha1: Renamed from modules/sha.
12321         (Files):
12322         Rename lib/sha.h to lib/sha1.h.
12323         Rename lib/sha.c to lib/sha1.c.
12324         Rename m4/sha.m4 to m4/sha1.m4.
12325         (lib_SOURCES): Likewise.
12326         (configure.ac): Rename gl_SHA to gl_SHA1.
12327         (Include): sha.h -> sha1.h.
12328
12329 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12330
12331         * m4/uint32_t.m4, uintptr_t.m4: New files.
12332         * m4/sha1.m4: Renamed from sha.m4.
12333         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
12334
12335 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12336
12337         * lib/obstack.h (obstack_empty_p):
12338         Don't assume that chunk->contents is suitably aligned.
12339         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
12340         Likewise. Problem reported by Benno in
12341         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
12342
12343         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
12344         readable.  This could be improved further but it'd take some work.
12345
12346 2004-08-08  Simon Josefsson  <jas@extundo.com>
12347
12348         * modules/xgethostname (Depends-on): Remove exit and error (not
12349         used).
12350
12351         * modules/getpass-gnu: Add getpass.h.
12352         (Depends-on): Add stdbool.
12353         * modules/getpass: Add getpass.h.
12354
12355 2004-08-08  Simon Josefsson  <jas@extundo.com>
12356
12357         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
12358         Check getpass declaration.
12359
12360 2004-08-08  Simon Josefsson  <jas@extundo.com>
12361
12362         * lib/xgethostname.c: Don't include error.h (not used).
12363
12364         * lib/getpass.h: Add.
12365         * lib/getpass.c: Include getpass.h first.
12366
12367 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
12368
12369         * lib/xalloc-die.c: New files.
12370         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
12371         All uses removed.
12372         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
12373         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
12374         xalloc-die.c.
12375         (_, N_, xalloc_die): Move to xalloc-die.c.
12376         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
12377         so that we needn't mess with xalloc_msg_memory_exhausted.
12378
12379         * lib/sha1.h: Renamed from sha.h.
12380         (SHA1_H): Renamed from _SHA_H.
12381         (sha1_ctx): Renamed from sha_ctx.
12382         (sha1_init_ctx): Renamed from sha_init_ctx.
12383         (sha1_process_block): Renamed from sha_process_block.
12384         (sha1_process_bytes): Renamed from sha_process_bytes.
12385         (sha1_finish_ctx): Renamed from sha_finish_ctx.
12386         (sha1_read_ctx): Renamed from sha_read_ctx.
12387         (sha1_stream): Renamed from sha_stream.
12388         (sha1_buffer): Renamed from sha_buffer.
12389         * lib/sha1.c: Likewise; renamed from sha.c.
12390         Do not include <sys/types.h>.
12391         Include <stddef.h> rather than <stdlib.h>.
12392
12393 2004-08-08  Bruno Haible  <bruno@clisp.org>
12394
12395         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
12396         FILESYSTEM_PREFIX_LEN.
12397         * lib/progreloc.c: Likewise.
12398         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
12399
12400 2004-08-06  Simon Josefsson  <jas@extundo.com>
12401
12402         * modules/progname (Depends-on): Don't depend on stdbool.
12403
12404 2004-08-06  Simon Josefsson  <jas@extundo.com>
12405
12406         * modules/getsubopt: New file.
12407         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12408         getsubopt.
12409
12410 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
12411
12412         More merge from coreutils.
12413
12414         * m4/utimens.m4, utimecmp.m4: New files.
12415         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
12416         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
12417         prereq.m4, sha.m4: Import changes from coreutils.
12418
12419 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
12420
12421         More merge from coreutils.
12422         * modules/raise, modules/readtokens0, modules/utimens,
12423         modules/utimecmp, module/xnanosleep: New files.
12424         * modules/strftime: Add lib/strftime.h.
12425         Change include from <time.h> to "strftime.h".
12426         * modules/yesno: Add lib/yesno.h.
12427         * modules/backupfile: Remove lib/addext.c.
12428         * modules/euidaccess: Add stat-macros.h.
12429         * modules/canonicalize, modules/euidaccess,
12430         modules/filemode, modules/lchown, modules/makepath,
12431         modules/rmdir, modules/stat: Likewise.
12432
12433 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
12434
12435         Merge from tar.
12436         * lib/argp-help.c (make_hol, hol_append): Don't assume that
12437         SIZE_MAX is a valid preprocessor constant.
12438         (__argp_basename): Change from "#ifndef _LIBC"
12439         to "#ifndef __argp_short_program_name", so that
12440         we don't compile these functions for tar.
12441
12442         More merges from coreutils.
12443         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h,
12444         lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c,
12445         lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
12446         * lib/addext.c: Remove; no longer needed.
12447         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
12448         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
12449         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
12450         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
12451         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
12452         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
12453         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
12454         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
12455         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
12456         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12457         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
12458         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
12459         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
12460         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
12461         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
12462         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
12463         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
12464         Import changes from coreutils.
12465
12466 2004-08-05  Simon Josefsson  <jas@extundo.com>
12467
12468         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
12469
12470 2004-08-05  Simon Josefsson  <jas@extundo.com>
12471
12472         * m4/getsubopt.m4: New file.
12473
12474 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
12475
12476         Merge from coreutils.
12477
12478         * m4/c-strtod.m4, canonicalize.m4, fcntl-safer.m4, getcwd-path-max.m4:
12479         New files.
12480
12481         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
12482         FILESYSTEM_PREFIX_LEN ->
12483         FILE_SYSTEM_PREFIX_LEN.
12484         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
12485         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
12486         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
12487         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
12488
12489         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
12490         prerequisite modules now handle the DOS stuff.
12491         Don't check for unistd.h.
12492
12493 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
12494
12495         Merge from coreutils.
12496
12497         * lib/.gdb-history: Remove; this doesn't belong here.
12498
12499         * lib/c-strtod.c, c-strtod.h, c-strtold.c, cycle-check.c,
12500         cycle-check.h, dev-ino.h, canonicalize.h, canonicalize.c,
12501         fcntl-safer.h, fcntl-safer.c, getcwd.c: New files.
12502
12503         * lib/dirname.h: Include <stdbool.h>.
12504         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
12505         for consistency with POSIX terminology.  All uses changed.
12506         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
12507         (strip_trailing_slashes): Use bool for booleans.
12508         * lib/stripslash.c (strip_trailing_slashes): Likewise.
12509
12510         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
12511         sometimes returns a positive errno value even when it succeeds.
12512         (print_errno_message) [!LIBC]: Fall back on strerror if
12513         __strerror_r fails.
12514
12515         * lib/path-concat.c (mempcpy): Don't define if a system header defines
12516         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
12517         (longest_relative_suffix): New function.
12518         (path_concat): Use it.  Assume first argument is not NULL.
12519         Port to DOS.  Omit redundant separators.
12520         Report an error instead of returning NULL.
12521         Use mempcpy instead of memcpy.
12522         (xpath_concat): Remove: not declared or used.
12523
12524         * lib/same.h: Include <stdbool.h>
12525         (same_name): Return bool, not int.
12526         * lib/same.c (same_name): Likewise.
12527         (errno): Don't declare; we assume C89 or better now.
12528
12529         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
12530         if not already defined.
12531
12532         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
12533         * lib/dup-safer.c (errno): Likewise.
12534
12535 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
12536
12537         Merge from coreutils.
12538         * modules/c-strtod, modules/c-strtold, modules/canonicalize,
12539         modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
12540         * modules/path-concat: Don't depend on strdup.
12541
12542 2004-08-03  Simon Josefsson  <jas@extundo.com>
12543
12544         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
12545         * lib/progname.h: Don't include stdbool.h.
12546
12547 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
12548
12549         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
12550         * MODULES.html.sh (func_all_modules): Remove fatal.
12551
12552 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
12553
12554         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
12555
12556 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
12557
12558         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
12559         working.
12560
12561 2004-08-02  Simon Josefsson  <jas@extundo.com>
12562
12563         * lib/getsubopt.h: New file, with comments from Bruno Haible.
12564         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
12565         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
12566
12567 2004-08-01  Simon Josefsson  <jas@extundo.com>
12568
12569         * lib/xgetdomainname.c: Include stdlib.h, for free().
12570
12571 2004-07-19  Bruno Haible  <bruno@clisp.org>
12572
12573         * MODULES.html.sh (func_all_modules): Add dummy.
12574
12575 2004-07-16  Simon Josefsson  <jas@extundo.com>
12576
12577         * modules/dummy: New file.
12578
12579 2004-07-16  Simon Josefsson  <jas@extundo.com>
12580
12581         * lib/dummy.c: New file.
12582
12583 2004-07-16  Bruno Haible  <bruno@clisp.org>
12584
12585         * lib/backupfile.h: Add extern "C" for C++.
12586         * lib/closeout.h: Likewise.
12587         * lib/copy-file.h: Likewise.
12588         * lib/findprog.h: Likewise.
12589         * lib/full-write.h: Likewise.
12590         * lib/pathname.h: Likewise.
12591         * lib/progname.h: Likewise.
12592         * lib/stpcpy.h: Likewise.
12593         * lib/stpncpy.h: Likewise.
12594         * lib/strcase.h: Likewise.
12595         * lib/strstr.h: Likewise.
12596         * lib/xalloc.h: Likewise.
12597
12598         * lib/mbswidth.h: Add extern "C" for C++.
12599         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
12600
12601 2004-07-13  Robert Millan  <robertmh@gnu.org>
12602
12603         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
12604
12605 2004-07-09  Simon Josefsson  <jas@extundo.com>
12606
12607         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
12608         failed without this.)
12609
12610 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12611
12612         * modules/chown (Files): Add lib/fchown-stub.c, since
12613         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
12614
12615 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12616
12617         * lib/fchown-stub.c: New file.
12618
12619 2004-06-24  Jim Meyering  <jim@meyering.net>
12620
12621         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
12622
12623 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12624
12625         * modules/argz: Omit "#include".
12626
12627         * MODULES.html.sh (func_all_modules): Add calloc, to match
12628         2004-06-01 addition of calloc module.
12629
12630 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12631
12632         * m4/argz.m4: New file, which is autoupdated from libtool.
12633
12634 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12635
12636         * lib/argz.c, argz_.h: New files, which are autoupdated from libtool.
12637
12638 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12639
12640         * config/srclist-update: Don't insist on "USA." before the
12641         close-comment, as libtool omits the period and puts the */ on a
12642         separate line.
12643         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
12644         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
12645
12646 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
12647
12648         * modules/argz: New file.
12649         * MODULES.html.sh (func_all_modules): Add argz.
12650
12651 2004-06-12  Jim Meyering  <jim@meyering.net>
12652         and  Paul Eggert  <eggert@cs.ucla.edu>
12653
12654         * modules/hash (Files): Add lib/xalloc.h.
12655         * modules/pipe (Depends-on): Add wait-process.
12656         * modules/stat (Depends-on): Add xalloc.
12657         * modules/userspec (Files): Add lib/userspec.h.
12658         * modules/xstrto
12659
12660         Upgrade from gettext-0.13.
12661         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
12662         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
12663         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
12664
12665 2004-06-10  Jim Meyering  <jim@meyering.net>
12666
12667         * lib/calloc.c: New file.
12668
12669 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
12670
12671         * lib/getdate.y (yylex): Allow space between sign and number.
12672         Problem reported by Dan Jacobson.
12673
12674 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
12675
12676         Merge from coreutils CVS.
12677
12678         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
12679         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
12680         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
12681         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
12682         xstrtol.m4: Fix copyright date and/or serial number.
12683
12684         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
12685         See if we need an fchown replacement.
12686         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
12687         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
12688         and use the replacement function if we detect either defect.
12689
12690         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
12691         gl_UTIMECMP.
12692
12693 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
12694         and  Jim Meyering  <jim@meyering.net>
12695
12696         Merge from coreutils CVS.
12697
12698         * lib/stat-macros.h: New file, with contents from file-type.h
12699         and coreutils' system.h.
12700         * lib/file-type.c: Include "stat-macros.h".
12701         * lib/file-type.h (file_type): Move all macro definitions to new file,
12702         stat-macros.h.
12703
12704         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
12705         Wrap old code with this conditional.
12706         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
12707         function that does not dereference symlinks.
12708         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
12709
12710         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
12711         dependency problems.
12712         (xreadlink): Accept new arg SIZE, for efficiency.
12713         All decls and uses changed.
12714         * lib/xreadlink.h: Include <stddef.h>, for size_t.
12715
12716         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
12717         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
12718
12719         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
12720         sysexits.h.
12721
12722 2004-06-01  Jim Meyering  <jim@meyering.net>
12723
12724         * m4/calloc.m4: New file.
12725
12726 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
12727
12728         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
12729         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
12730         Also, fix a typo in a diagnostic.
12731
12732 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
12733
12734         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
12735         or AC_FUNC_REALLOC.
12736
12737 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
12738
12739         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
12740         macros to be defined.
12741         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
12742         the allocator returns NULL because the requested size is zero.
12743
12744 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12745
12746         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
12747         var.  Add comment explaining why libc still defines it.  This
12748         merges the following patch from glibc:
12749         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
12750
12751 2004-05-20  Andreas Schwab  <schwab@suse.de>
12752
12753         * m4/free.m4: Replace free if it not known to work, not the other
12754         way round.
12755
12756 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
12757
12758         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
12759         present in glibc since revision 1.1 of this file.
12760         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
12761         obstack_alignment_mask, obstack_alloc, obstack_base,
12762         obstack_blank, obstack_blank_fast, obstack_chunk_size,
12763         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
12764         obstack_grow0, obstack_init, obstack_int_grow,
12765         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
12766         obstack_next_free, obstack_object_size, obstack_ptr_grow,
12767         obstack_ptr_grow_fast, obstack_room): Remove declarations of
12768         nonexistent functions.
12769
12770 2004-05-18  Karl Berry  <karl@gnu.org>
12771
12772         * config/srclist.txt: break link for vasnprintf.c.
12773
12774 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
12775
12776         Port obstack to the AS/400, where pointers are 16 bytes wide and
12777         you cannot cast an integer to a valid pointer.  This patch is
12778         currently waiting to be integrated into glibc; see
12779         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
12780
12781         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
12782         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
12783         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
12784         (struct obstack): temp member is now a union of a pointer and
12785         an integer, instead of an integer.  All integer uses changed.
12786         This does not affect the physical layout of struct obstack,
12787         except on hosts (like the AS/400) where the size or alignment of
12788         void * is greater than that of ptrdiff_t.
12789         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
12790         __STDC__)]: Store temporary in pointer member of union, not
12791         integer member.
12792         * lib/obstack.c: Include <stddef.h>, for offsetof.
12793         (struct fooalign): Remove; it doesn't need a name.
12794         (union fooround): Change double to long double, and add void *.
12795         (DEFAULT_ALIGNMENT): Use offsetof to compute.
12796         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
12797         not a macro.  Hence the values are always int; so remove all
12798         casts-to-int in uses.
12799
12800 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
12801
12802         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
12803         we can get this patch merged into glibc.
12804
12805 2004-05-17  Derek R. Price  <derek@ximbiot.com>
12806             Paul Eggert  <eggert@cs.ucla.edu>
12807
12808         * m4/argp: Depend on alloca.
12809
12810 2004-05-17  Derek R. Price  <derek@ximbiot.com>
12811             Paul Eggert  <eggert@cs.ucla.edu>
12812
12813         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
12814         freecoding.
12815
12816 2004-05-17  Bruno Haible  <bruno@clisp.org>
12817
12818         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
12819         precision that consists of a '.' followed by an empty digit string.
12820         Patch by Tor Lillqvist <tml@iki.fi>.
12821
12822 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
12823
12824         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
12825         for backward compatibility with older code.  We need our own
12826         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
12827         it under some other name, and our alloca.h will define it.
12828
12829 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
12830             Derek Price  <derek@ximbiot.com>
12831
12832         * lib/alloca.c: Include <alloca.h>, to get our interface.
12833         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
12834         include <alloca.h> first.  Use C89 prototype for alloca; this
12835         requires including <stddef.h> for size_t.  Use extern "C" if C++.
12836         Use #elif for simplicity, since we can assume C89 now.
12837         Don't try to source the system alloca.h since it will not be found
12838         and to prevent recursively including its replacement.
12839         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
12840         * lib/regex.c: Likewise.
12841
12842 2004-05-16  Derek Price  <derek@ximbiot.com>
12843             Paul Eggert  <eggert@cs.ucla.edu>
12844
12845         getline cleanup.  This changes the getndelim2 API: both order of
12846         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
12847         no delimiter).
12848
12849         * lib/getline.c: Don't include stddef.h or stdio.h, since our
12850         interface does that.
12851         (getline): Always use getdelim, so that we don't have two
12852         copies of this code.
12853         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
12854         if available.
12855         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
12856         (GETNDELIM2_MAXIMUM): New macro.
12857         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
12858         instead of the old practice of delim2==0.  All callers changed.
12859         Return -1 on overflow, instead of returning junk.
12860         Do not set *linesize unless allocation succeeds.
12861         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
12862         that we include sys/types.h.
12863         * lib/getnline.h: Likewise.
12864         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
12865         (getndelim2): Reorder arguments.
12866         * lib/getnline.c (getnline, getndelim):
12867         Don't discard the NMAX argument.
12868         (getnline): Invoke getndelim, to avoid code duplication.
12869         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
12870         of (size_t) -1 by callers of the getnline family.
12871
12872 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12873
12874         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
12875         Check for gettimeofday.
12876         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
12877         Check for settimeofday, stime.
12878
12879 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12880
12881         * lib/nanosleep.c (suspended): Change its type from int to
12882         sig_atomic_t volatile.
12883         (first_call): Make it private to rpl_nanosleep, and have it
12884         be zero initially as that's a bit faster.
12885         (my_usleep): Round up fractional times instead of truncating them,
12886         as this is the usual meaning for 'sleep'.
12887
12888         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
12889         doesn't work.
12890         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
12891         (ENOSYS): Define if not defined.
12892         (settime): Fall back on stime if it exists and settimeofday fails.
12893         But don't bother with fallbacks if a method fails with errno == EPERM.
12894
12895 2004-05-11  Jim Meyering  <jim@meyering.net>
12896
12897         Prior to this change, the save_cwd caller required read access to the
12898         current directory on most systems (ones with the fchdir function).
12899
12900         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
12901         fails, try write-only, and finally, resort to using xgetcwd.
12902
12903 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12904
12905         * lib/obstack.c, obstack.h: Import changes from libc.
12906
12907 2004-04-28  Bruno Haible  <bruno@clisp.org>
12908
12909         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
12910         also implicitly appends .exe to executables.
12911         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
12912         accepts Windows pathnames.
12913         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
12914         Treat Cygwin like Windows, since it now accepts Windows pathnames.
12915         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
12916         Treat Cygwin like Windows, since it now accepts Windows pathnames.
12917         Reported by Derek Robert Price <derek@ximbiot.com>.
12918
12919 2004-04-21  Karl Berry  <karl@gnu.org>
12920
12921         * config/srclist.txt (localcharset.c): break sync.
12922
12923 2004-04-20  Paul Eggert  <eggert@twinsun.com>
12924
12925         * m4/host-os.m4: Add a copyright notice.
12926
12927 2004-04-20  Jim Meyering  <jim@meyering.net>
12928
12929         Change UTILS_ to gl_ in AC_DEFINE'd names.
12930         Change utils_- and jm_-prefixed variables, too.
12931         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
12932         UTILS_FUNC_MKDIR_TRAILING_SLASH.
12933         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
12934
12935         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
12936         Don't emit trailing blanks.
12937         Also rename jm_-prefixed variables to have gl_ prefix.
12938
12939         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
12940         Also rename jm_-prefixed variables to have gl_ prefix.
12941
12942         * m4/jm-macros.m4: Reflect the renamings.
12943         * m4/prereq.m4: Likewise.
12944
12945 2004-04-20  Jim Meyering  <jim@meyering.net>
12946
12947         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
12948         memory.
12949
12950 2004-04-20  Jim Meyering  <jim@meyering.net>
12951             Bruno Haible  <bruno@clisp.org>
12952
12953         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
12954         memory when realloc fails.
12955
12956 2004-04-19  Jim Meyering  <jim@meyering.net>
12957
12958         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
12959         now that readutmp.c may call `free (0)'.
12960
12961 2004-04-19  Bruno Haible  <bruno@clisp.org>
12962
12963         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
12964         * m4/inttypes_h.m4: Likewise.
12965         * m4/stdint_h.m4: Likewise.
12966         * m4/intmax_t.m4: Likewise.
12967         * m4/uintmax_t.m4: Likewise.
12968
12969 2004-04-18  Jim Meyering  <jim@meyering.net>
12970
12971         * m4/prereq.m4: Don't forbid jm_ prefix.
12972
12973         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
12974         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
12975         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
12976         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
12977         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
12978         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
12979         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
12980         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
12981         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
12982         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
12983         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
12984         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
12985         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
12986         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
12987         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
12988         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
12989         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
12990         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
12991         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
12992
12993 2004-04-18  Jim Meyering  <jim@meyering.net>
12994
12995         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
12996         failure, don't leak memory and do call END_UTMP_ENT.
12997
12998 2004-04-16  Jim Meyering  <jim@meyering.net>
12999
13000         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
13001         coreutils' stat program.
13002         (gl_PREREQ): Don't require jm_PREREQ_STAT.
13003
13004 2004-04-11  Paul Eggert  <eggert@twinsun.com>
13005
13006         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
13007         C89.
13008         (CHAR_BIT): Remove, since we assume C89.
13009         Include <stdint.h> if available, as per current Autoconf CVS advice.
13010
13011 2004-03-31  Jim Meyering  <jim@meyering.net>
13012
13013         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
13014         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
13015         * m4/xalloc.m4: Likewise.
13016
13017 2004-03-30  Paul Eggert  <eggert@twinsun.com>
13018
13019         Merge from coreutils.
13020
13021         * m4/inttostr.m4: New file.
13022         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
13023         Require AM_STDBOOL_H and gl_TIMESPEC instead.
13024         Require gl_CLOCK_TIME.
13025         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
13026
13027 2004-03-30  Paul Eggert  <eggert@twinsun.com>
13028
13029         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
13030         not bool, to be more consistent with Unix conventions.
13031         Suggested by Bruno Haible.
13032
13033         Merge from coreutils.
13034
13035         * lib/imaxtostr.c, inttostr.c, inttostr.h, offtostr.c, umaxtostr.c:
13036         New files.
13037
13038         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
13039         the usual <time.h> dance.
13040         (get_date): Change signature to support fractional time stamps.
13041         All callers changed.
13042         * lib/getdate.y: Include "getdate.h" first, as we can now
13043         assume C89 and don't need to worry about 'const'.
13044         Similarly, include "unlocked-io.h" near start, not in middle.
13045         Include <limits.h>.
13046         (textint.value): Use long int rather than int.
13047         (textint.digits): Use size_t rather than int.
13048         (BILLION, LOG10_BILLION): New constants.
13049         (parser_control): New member rel_ns.  Members day_ordinal,
13050         time_zone, month, day, hour, minutes, rel_year, rel_month,
13051         rel_day, rel_hour, rel_minutes, rel_seconds
13052         are now long int, not int.  Member seconds is now struct timespec,
13053         not int.  New member timespec_seen.  Members dates_seen, days_seen,
13054         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
13055         not int.
13056         (%union.intval): Now long int, not int.
13057         New member timespec.
13058         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
13059         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
13060         (spec): Now is a timespec or an item list.
13061         (timespec, items): New nonterminals.
13062         (time, rel, relunit, number, get_date):
13063         Add support for fractional seconds.
13064         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
13065         (gmtime, localtime, mktime): Remove decls; not needed with C89.
13066         (to_hour): First arg is now long int, not int.
13067         (to_year): Returns long int, not int.
13068         Don't treat year -70 like 70.
13069         (tm_diff): Returns long int, not int.
13070         (lookup_word): Use bool instead of int when appropriate.
13071         (yylex): Use size_t for count, not int.
13072         Detect overflow when parsing large integer constants.
13073         Add support for fractions.
13074         (get_date): Make pointers 'const' if possible.
13075         Use more-portable code to detect integer overflow.
13076         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
13077         Don't use ctime; it's not reliable if the year has >4 digits.
13078
13079         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
13080         This is for compatibility with BSD.
13081
13082         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
13083         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
13084         From coreutils' system.h.
13085
13086         * lib/userspec.c: Don't include "posixver.h".
13087         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
13088         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
13089         compatible extension.  Simplify code by removing a boolean int
13090         that was always nonzero if a string was nonnull.
13091
13092 2004-03-30  Jim Meyering  <jim@meyering.net>
13093
13094         Merge from coreutils.
13095
13096         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
13097         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
13098         on some systems one must include <grp.h> before it.
13099         Reported by Christian Krackowizer.
13100
13101 2004-03-30  Jim Meyering  <jim@meyering.net>
13102
13103         Merge from coreutils.
13104
13105         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
13106
13107         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
13108         an empty input stream.
13109
13110         * lib/readtokens.c: Include <stdbool.h>.
13111         (readtoken): Use `size_t' rather than int/long.
13112         All callers adjusted.
13113         Use `bool' rather than `int' where appropriate.
13114         Use memset rather than an explicit loop.
13115         Use x2nrealloc rather than xrealloc.
13116         Allow the use of `\0' as a delimiter.
13117         (readtokens): Likewise.
13118         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
13119
13120 2004-03-30  Jim Meyering  <jim@meyering.net>
13121
13122         * m4/realloc.m4: Remove file, since now it does no more than
13123         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
13124         the `configure.ac' section of module/realloc.
13125         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
13126
13127 2004-03-30  Bruno Haible  <bruno@clisp.org>
13128
13129         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
13130         nonnull.
13131
13132 2004-03-29  Paul Eggert  <eggert@twinsun.com>
13133
13134         Merge changes to getloadavg.c from coreutils and Emacs.
13135
13136         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
13137         Define to an expression, not to the empty string.
13138         Include cloexec.h and xalloc.h.
13139         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
13140         Use set_cloexec_flag rather than rolling our own.
13141         * lib/cloexec.c, cloexec.h: New files.
13142
13143 2004-03-29  Paul Eggert  <eggert@twinsun.com>
13144
13145         * m4/cloexec.m4: New file.
13146
13147 2004-03-18  Paul Eggert  <eggert@twinsun.com>
13148
13149         * lib/getopt.h: Sync with libc CVS.
13150
13151 2004-03-18  Paul Eggert  <eggert@twinsun.com>
13152             Bruno Haible  <bruno@clisp.org>
13153
13154         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
13155         mbswidth.
13156
13157 2004-03-18  Paul Eggert  <eggert@twinsun.com>
13158             Bruno Haible  <bruno@clisp.org>
13159
13160         * lib/mbswidth.h: Include <wchar.h> only if
13161         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
13162         <wchar.h>.
13163         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
13164
13165 2004-03-09  Paul Eggert  <eggert@twinsun.com>
13166
13167         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
13168         Sync with libc CVS.
13169         * lib/getopt_int.h: New file, also synced from libc.
13170
13171 2004-03-09  Paul Eggert  <eggert@twinsun.com>
13172
13173         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
13174         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
13175         Bring back getopt.c, getopt.h, getopt1.c.
13176
13177 2004-03-07  Paul Eggert  <eggert@twinsun.com>
13178
13179         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
13180         All uses changed.  Check for sa_sigaction member; this fixes
13181         a bug first reported by Jason Andrade in
13182         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
13183
13184 2004-03-07  Paul Eggert  <eggert@twinsun.com>
13185
13186         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
13187         '#if' expressions.  Unlike the code it replaces, it does not
13188         depend on (defined _SC_PAGESIZE).  However, it does depend on
13189         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
13190         first reported by Jason Andrade in
13191         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
13192
13193 2004-02-25  Simon Josefsson  <jas@extundo.com>
13194
13195         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
13196
13197 2004-02-25  Simon Josefsson  <jas@extundo.com>
13198
13199         * lib/strdup.h: New file.
13200         * lib/strdup.c: Include it.
13201         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
13202         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
13203
13204 2004-02-23  Karl Berry  <karl@gnu.org>
13205
13206         * doc/maintain.texi, standards.texi, make-stds.texi: new files
13207         (from fencepost.gnu.org:/gd/gnuorg).
13208
13209 2004-02-23  Karl Berry  <karl@gnu.org>
13210
13211         * config/srclistvars.sh (GNUORG) [karl]: redefine.
13212         * config/srclist.txt: add maintain/standards documents.
13213
13214 2004-02-18  Bruno Haible  <bruno@clisp.org>
13215
13216         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
13217         Reported by Derek Robert Price <derek@ximbiot.com>.
13218
13219 2004-02-16  Karl Berry  <karl@gnu.org>
13220
13221         * config/mkinstalldirs, install-sh: update from automake.
13222
13223 2004-02-06  Karl Berry  <karl@gnu.org>
13224
13225         * m4/po.m4: update from gettext 0.14.1.
13226
13227 2004-02-06  Karl Berry  <karl@gnu.org>
13228
13229         * lib/config.charset: update from gettext 0.14.1.
13230
13231 2004-02-05  Paul Eggert  <eggert@twinsun.com>
13232
13233         Add comments and code, prompted by suggestions from Bruno Haible
13234         for sh-quote.
13235         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
13236         describing the enum quoting_style values.
13237         * lib/quotearg.c (quotearg_alloc): New function.
13238         (quotearg_buffer_restyled): Treat lone { and } as special.
13239         Treat = as special.  Work around bug with older shells
13240         that "see" a '\' that is really the 2nd byte of a multibyte char.
13241         Quote empty string with shell_quoting_style.
13242
13243 2004-02-03  Bruno Haible  <bruno@clisp.org>
13244
13245         * m4/pipe.m4: New file, from GNU gettext.
13246
13247 2004-02-03  Bruno Haible  <bruno@clisp.org>
13248
13249         * lib/pipe.h: New file, from GNU gettext.
13250         * lib/pipe.c: New file, from GNU gettext.
13251
13252 2004-01-27  Bruno Haible  <bruno@clisp.org>
13253
13254         * m4/execute.m4: New file, from GNU gettext.
13255
13256 2004-01-27  Bruno Haible  <bruno@clisp.org>
13257
13258         * lib/execute.h: New file, from GNU gettext.
13259         * lib/execute.c: New file, from GNU gettext.
13260         * lib/w32spawn.h: New file, from GNU gettext.
13261
13262 2004-01-24  Paul Eggert  <eggert@twinsun.com>
13263
13264         Merge from diffutils.
13265
13266         * lib/file-type.c (file_type): Add typed memory objects.
13267         * lib/file-type.h (S_TYPEISTMO): New macro.
13268
13269         * lib/c-stack.h (c_stack_action): Remove argv argument.
13270         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
13271         (die): Don't calculate message unless segv_action returns.
13272         (get_stack_location, min_address_from_argv, max_address_from_argv,
13273         volatile stack_base, volatile_stack_size): Remove.
13274         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
13275         that every segmentation violation is a stack overflow.  (Ouch!)
13276         See Debian bug 136249 (still outstanding) for more info about why
13277         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
13278
13279 2004-01-24  Paul Eggert  <eggert@twinsun.com>
13280
13281         Exit-status fix from coreutils.
13282
13283         Use exit_failure consistently in place of EXIT_FAILURE,
13284         so that program exit statuses are consistent on failure.
13285
13286         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
13287         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
13288         * lib/argmatch.h: Comment fix to match the above.
13289         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
13290         Now a macro referring to exit_failure, instead of a separate
13291         variable.  Include "exitfail.h" to get it.
13292         * lib/xstrtol.h: Include "exitfail.h".
13293         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
13294
13295         * lib/long-options.c (parse_long_options): Use prototype
13296         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
13297         for clarity.
13298
13299 2004-01-21  Jim Meyering  <jim@meyering.net>
13300
13301         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
13302         so as not to conflict with a different-sized __mktime_internal
13303         function in GNU libc.
13304         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
13305         Problem building statically-linked `ls' reported by Michael Brunnbauer.
13306
13307 2004-01-20  Karl Berry  <karl@gnu.org>
13308
13309         * config/config.guess: update from config.
13310
13311         * config/srclistvars.sh: GNUWWWLICENSES for karl.
13312
13313 2004-01-20  Bruno Haible  <bruno@clisp.org>
13314
13315         Safer stack allocation.
13316         * lib/setenv.c: Include allocsa.h.
13317         (alloca): Remove fallback definition.
13318         (freea): Remove macro.
13319         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
13320         instead of freea.
13321
13322 2004-01-20  Bruno Haible  <bruno@clisp.org>
13323
13324         * m4/eealloc.m4: New file, from GNU gettext.
13325
13326 2004-01-20  Bruno Haible  <bruno@clisp.org>
13327
13328         * m4/allocsa.m4: New file, from GNU gettext.
13329
13330 2004-01-20  Bruno Haible  <bruno@clisp.org>
13331
13332         * lib/xallocsa.h: New file, from GNU gettext.
13333         * lib/xallocsa.c: New file, from GNU gettext.
13334
13335 2004-01-20  Bruno Haible  <bruno@clisp.org>
13336
13337         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
13338
13339 2004-01-20  Bruno Haible  <bruno@clisp.org>
13340
13341         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
13342         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
13343         specially.
13344
13345 2004-01-20  Bruno Haible  <bruno@clisp.org>
13346
13347         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
13348         patch.
13349
13350 2004-01-20  Bruno Haible  <bruno@clisp.org>
13351
13352         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
13353
13354 2004-01-20  Bruno Haible  <bruno@clisp.org>
13355
13356         * lib/eealloc.h: New file.
13357
13358 2004-01-20  Bruno Haible  <bruno@clisp.org>
13359
13360         * lib/binary-io.h: Avoid warnings on Cygwin.
13361
13362 2004-01-20  Bruno Haible  <bruno@clisp.org>
13363
13364         * lib/allocsa.h: New file, from GNU gettext.
13365         * lib/allocsa.c: New file, from GNU gettext.
13366
13367 2004-01-18  Karl Berry  <karl@gnu.org>
13368
13369         * doc/gpl.texi, lgpl.texi: new files.
13370
13371 2004-01-18  Karl Berry  <karl@gnu.org>
13372
13373         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
13374         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
13375
13376 2004-01-15  Paul Eggert  <eggert@twinsun.com>
13377
13378         Merge from coreutils.
13379
13380         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
13381         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
13382         (gl_DEFAULT_POSIX2_VERSION): Move
13383         the documentation from 'configure' into 'config.hin',
13384         so that 'configure --help' isn't burdened by it and
13385         we don't have to worry about its formatting there.
13386         Reword the documentation so that it's more succinct
13387         and can be run together into a single paragraph.
13388         * m4/same.m4 (gl_SAME): Check for pathconf.
13389
13390 2004-01-15  Paul Eggert  <eggert@twinsun.com>
13391
13392         Merge from coreutils.
13393
13394         * lib/posixver.c: Include posixver.h.
13395
13396         * lib/same.c: Include <stdbool.h>, <limits.h>.
13397         (_POSIX_NAME_MAX): Define if not defined.
13398         (MIN): New macro.
13399         (same_name): If file names are silently truncated, report
13400         that the file names are the same if they are the same after
13401         the silent truncation.
13402
13403         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
13404         conversion function.
13405         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
13406         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
13407         longer needed.
13408
13409 2004-01-15  Jim Meyering  <jim@meyering.net>
13410
13411         Merge from coreutils.
13412
13413         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
13414         if no library is required.
13415         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
13416         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
13417         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
13418         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
13419         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
13420         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
13421         value, $ac_cv_search_crypt, if it's "none required".
13422         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
13423         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
13424         not gl_FUNC_GETLOADAVG.
13425         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
13426         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
13427
13428 2004-01-15  Jim Meyering  <jim@meyering.net>
13429
13430         Merge from coreutils.
13431
13432         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
13433         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
13434         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
13435
13436         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
13437         optional configure-time default.
13438
13439         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13440
13441         * lib/xreadlink.c (xreadlink): Correct outdated comment.
13442
13443 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
13444
13445         Merge from coreutils.
13446
13447         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
13448         value, $ac_cv_search_nanosleep, if it's "none required".
13449
13450 2004-01-14  Paul Eggert  <eggert@twinsun.com>
13451
13452         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
13453         with like-named macro in fnmatch.c.
13454         (EXT): Use an internal constant instead.
13455
13456         Merge fnmatch patches from glibc.
13457         * lib/fnmatch.c (mbsinit): Remove define.
13458         Add libc_hidden_ver (__fnmatch, fnmatch).
13459         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
13460         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
13461
13462 2004-01-14  Karl Berry  <karl@gnu.org>
13463
13464         * config/install-sh: update from automake.
13465
13466 2004-01-13  Karl Berry  <karl@gnu.org>
13467
13468         * config/install-sh: update from automake.
13469
13470 2004-01-09  Karl Berry  <karl@gnu.org>
13471
13472         * config/install-sh: update from automake.
13473
13474 2004-01-05  Karl Berry  <karl@gnu.org>
13475
13476         * config/config.{sub,guess}: update from config.
13477
13478 2003-12-31  Karl Berry  <karl@gnu.org>
13479
13480         * config/depcomp: update from automake.
13481
13482 2003-12-14  Karl Berry  <karl@gnu.org>
13483
13484         * lib/config.charset: update from gettext-runtime.
13485
13486 2003-12-03  Paul Eggert  <eggert@twinsun.com>
13487
13488         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
13489         Bug reported by Alfred M. Szmidt.
13490
13491 2003-12-03  Bruno Haible  <bruno@clisp.org>
13492
13493         * m4/gettext.m4: Upgrade from gettext-0.13.
13494         * m4/po.m4: Upgrade from gettext-0.13.
13495         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
13496         * m4/intmax.m4: New file, from gettext-0.13.
13497         * m4/printf-posix.m4: New file, from gettext-0.13.
13498
13499 2003-11-29  Karl Berry  <karl@gnu.org>
13500
13501         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
13502
13503 2003-11-25  Paul Eggert  <eggert@twinsun.com>
13504             Bruno Haible  <bruno@clisp.org>
13505
13506         * lib/printf-parse.h: Don't include sys/types.h.
13507         (ARG_NONE): New macro.
13508         (char_directive): Change type of *arg_index fields to size_t.
13509         * lib/printf-parse.c: Don't include sys/types.h.
13510         (SSIZE_MAX): Remove macro.
13511         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
13512         Remove unnecessary overflow check.
13513         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
13514         fields.
13515
13516 2003-11-25  Bruno Haible  <bruno@clisp.org>
13517
13518         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
13519
13520 2003-11-25  Bruno Haible  <bruno@clisp.org>
13521
13522         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
13523         gt_TYPE_SSIZE_T.
13524
13525 2003-11-24  Paul Eggert  <eggert@twinsun.com>
13526
13527         * modules/alloca: Remove dependency on xalloc.
13528
13529 2003-11-24  Paul Eggert  <eggert@twinsun.com>
13530
13531         * lib/alloca.c: Remove dependency on xalloc module.
13532         (xalloc_die): Remove.
13533         (memory_full) [!defined emacs]: New macro.
13534         [!defined emacs]: Don't include xalloc.h.
13535         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
13536         address arithmetic overflows.  Change datatypes a bit to avoid
13537         unnecessary casts.
13538
13539 2003-11-22  Jim Meyering  <jim@meyering.net>
13540
13541         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
13542         s/size/size_t/.
13543
13544 2003-11-21  Karl Berry  <karl@gnu.org>
13545
13546         * config/config.{sub,guess}: update from config.
13547
13548 2003-11-18  Karl Berry  <karl@gnu.org>
13549
13550         * config/config.{sub,guess}: update from config.
13551
13552         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
13553
13554 2003-11-17  Paul Eggert  <eggert@twinsun.com>
13555
13556         * README: Mention that S+T cannot overflow if S is the size of
13557         an existing object and T is sufficiently small.
13558
13559 2003-11-17  Jim Meyering  <jim@meyering.net>
13560
13561         On systems without utime and without a utimes function capable of
13562         dealing with a NULL struct utimbuf* argument, this utime replacement
13563         could -- in unusual circumstances -- leak a file descriptor.
13564         * lib/utime.c: Include <unistd.h> and <errno.h>.
13565         (utime_null): Be sure to close `fd' and to preserve errno.
13566         Reported by Geoff Collyer via Arnold Robbins.
13567
13568 2003-11-17  Bruno Haible  <bruno@clisp.org>
13569
13570         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
13571         (Depends-on): Add xsize.
13572
13573 2003-11-17  Bruno Haible  <bruno@clisp.org>
13574
13575         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
13576
13577 2003-11-17  Bruno Haible  <bruno@clisp.org>
13578
13579         * lib/vasnprintf.c (alloca): Remove fallback definition.
13580         (freea): Remove definition.
13581         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
13582         Reported by Paul Eggert.
13583
13584 2003-11-16  Paul Eggert  <eggert@twinsun.com>
13585             Bruno Haible  <bruno@clisp.org>
13586
13587         Protect against address arithmetic overflow.
13588         * lib/printf-args.h: Include stddef.h.
13589         (arguments): Change type of field 'count' to size_t.
13590         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
13591         'unsigned int' where appropriate.
13592         * lib/printf-parse.h: Include sys/types.h.
13593         (char_directive): Change type of *arg_index fields to ssize_t.
13594         (char_directives): Change type of fields 'count', max_*_length to
13595         size_t.
13596         * lib/printf-parse.c: Include sys/types.h and xsize.h.
13597         (SSIZE_MAX): Define fallback value.
13598         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
13599         instead of 'int' where appropriate. Check a_allocated, d_allocated
13600         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
13601         * lib/vasnprintf.c: Include xsize.h.
13602         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
13603         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
13604         overflow. Avoid wraparound when converting a width or precision from
13605         decimal to binary.
13606
13607 2003-11-16  Bruno Haible  <bruno@clisp.org>
13608
13609         Update from GNU gettext.
13610         * lib/printf-parse.c: Generalize to it can be compiled for wide
13611         strings.
13612         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
13613         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
13614         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
13615         SNPRINTF): New macros.
13616         Don't include <alloca.h> if the file is used inside libintl.
13617         (local_wcslen): New function, for Solaris 2.5.1.
13618         (VASNPRINTF): Use it instead of wcslen.
13619
13620 2003-11-16  Bruno Haible  <bruno@clisp.org>
13621
13622         * lib/xsize.h (xmax): New function.
13623         (xsum, xsum3, xsum4): Declare as "pure" functions.
13624
13625 2003-11-12  Paul Eggert  <eggert@twinsun.com>
13626
13627         * modules/xalloc (Files): Undo latest change, since xalloc.h
13628         no longer needs SIZE_MAX or PTRDIFF_MAX.
13629
13630 2003-11-12  Paul Eggert  <eggert@twinsun.com>
13631
13632         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
13633         gl_PTRDIFF_MAX.
13634
13635 2003-11-12  Paul Eggert  <eggert@twinsun.com>
13636
13637         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
13638         "return", to pacify some unknown compiler.  Problem reported
13639         by Joerg Schilling.
13640
13641 2003-11-12  Paul Eggert  <eggert@twinsun.com>
13642
13643         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
13644         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
13645         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
13646         heuristic is just as accurate as far as we know, and it removes a
13647         dependency on size_max.m4 and ptrdiff_max.m4.
13648
13649 2003-11-11  Bruno Haible  <bruno@clisp.org>
13650
13651         * modules/xsize (Files): Add m4/size_max.m4.
13652         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
13653
13654 2003-11-11  Bruno Haible  <bruno@clisp.org>
13655
13656         * m4/size_max.m4: New file.
13657         * m4/ptrdiff_max.m4: New file.
13658         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
13659         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
13660         (gl_XALLOC): Invoke it.
13661
13662 2003-11-11  Bruno Haible  <bruno@clisp.org>
13663
13664         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
13665         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
13666         defined.
13667
13668 2003-11-10  Paul Eggert  <eggert@twinsun.com>
13669
13670         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
13671         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
13672         rejected some allocations of exactly SIZE_MAX - 2 bytes.
13673         From Bruno Haible.
13674         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
13675         not (size_t) -1, since it's defined here.
13676
13677 2003-11-09  Karl Berry  <karl@gnu.org>
13678
13679         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
13680
13681 2003-11-06  Paul Eggert  <eggert@twinsun.com>
13682
13683         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
13684         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
13685         Reject sizes of exactly SIZE_MAX bytes.
13686         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
13687         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
13688
13689 2003-11-05  Bruno Haible  <bruno@clisp.org>
13690
13691         * lib/xsize.h: Include limits.h, to avoid a possible collision with
13692         SIZE_MAX defined in <limits.h> on Solaris.
13693
13694 2003-11-04  Jim Meyering  <jim@meyering.net>
13695
13696         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
13697         variable names, rather than @VAR@.
13698         * modules/poll: Likewise.
13699
13700 2003-11-04  Bruno Haible  <bruno@clisp.org>
13701
13702         * modules/xsize: New file.
13703         * modules/linebreak: Depend on xsize.
13704         * MODULES.html.sh (func_all_modules): Add xsize.
13705
13706 2003-11-04  Bruno Haible  <bruno@clisp.org>
13707
13708         * m4/xsize.m4: New file.
13709
13710 2003-11-04  Bruno Haible  <bruno@clisp.org>
13711
13712         * lib/xsize.h: New file.
13713         * lib/linebreak.c: Include xsize.h.
13714         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
13715         argument for overflow.
13716         Suggested by Paul Eggert.
13717
13718 2003-11-03  Karl Berry  <karl@gnu.org>
13719
13720         * config/config.{guess,sub}: update from config.
13721
13722 2003-11-03  Jim Meyering  <jim@meyering.net>
13723
13724         * modules/userspec (lib_SOURCES): Add userspec.h.
13725         (Include): Add "userspec.h".
13726         Improve description.
13727
13728 2003-11-03  Jim Meyering  <jim@meyering.net>
13729
13730         * lib/userspec.c: Include "userspec.h".
13731         * lib/userspec.h: New file.
13732
13733 2003-11-03  Bruno Haible  <bruno@clisp.org>
13734
13735         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
13736
13737 2003-11-03  Bruno Haible  <bruno@clisp.org>
13738
13739         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
13740         available, to avoid (extremely rare) race condition.
13741         Suggested by Paul Eggert.
13742
13743 2003-11-02  Karl Berry  <karl@gnu.org>
13744
13745         * config/srclist.txt (vasprintf.c): sync broken, sigh.
13746
13747 2003-10-31  Paul Eggert  <eggert@twinsun.com>
13748
13749         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
13750         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
13751         (read_filesystem_list): Set and use me_type_malloced.
13752         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
13753         whatever the type happens to be), for brevity and consistency.
13754         Check for size calculation overflow on Alphas running OSF/1.
13755
13756 2003-10-31  Jim Meyering  <jim@meyering.net>
13757
13758         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
13759
13760         * lib/linebuffer.c: Include <string.h> for declaration of memset.
13761
13762 2003-10-30  Paul Eggert  <eggert@twinsun.com>
13763             Bruno Haible  <bruno@clisp.org>
13764
13765         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
13766         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
13767
13768 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
13769
13770         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
13771         netbsd*-gnu*.  Suggested by Robert Millan.
13772
13773 2003-10-29  Paul Eggert  <eggert@twinsun.com>
13774
13775         * modules/group-member: Depend on stdbool.
13776
13777 2003-10-29  Paul Eggert  <eggert@twinsun.com>
13778
13779         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
13780
13781 2003-10-29  Paul Eggert  <eggert@twinsun.com>
13782
13783         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
13784         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
13785         after the 'gnu' in these cases.  This fixes some bugs in the
13786         previous change, and is based on suggestions by Robert Millan.
13787
13788 2003-10-29  Paul Eggert  <eggert@twinsun.com>
13789
13790         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
13791         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
13792         no longer needed.
13793         * lib/quotearg.c (quotearg_n_options): Use it.
13794         * lib/group-member.c: Include <stdbool.h>.
13795         (free_group_info): Arg is now const *; don't free arg.
13796         (get_group_info): Now returns bool and accepts struct group_info *,
13797         rather than returning a malloc'ed struct group_info *.
13798         All uses changed.  Check for overflow in internal size calculation.
13799
13800         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
13801         rather than xmalloc/xrealloc.
13802         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
13803         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
13804         conformance bug: the old code used a pointer after freeing the
13805         storage that it addressed.
13806         * lib/hash.c (hash_initialize): Simplify the code by using
13807         xalloc_oversized rather than doing it by hand.
13808         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
13809         the buffer preserved.  Use free and xmalloc instead.
13810         * lib/quotearg.c (quotearg_n_options): Likewise.
13811         Use a simpler test for size overflow.  Don't use xalloc_oversized
13812         because unsigned int might be wider than size_t (!); this suggests
13813         that we should switch from unsigned int to size_t for slot numbers.
13814
13815 2003-10-28  Paul Eggert  <eggert@twinsun.com>
13816
13817         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
13818         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
13819         NetBSD kernels.  Requested by Richard Stallman.
13820
13821 2003-10-27  Paul Eggert  <eggert@twinsun.com>
13822
13823         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
13824         to allocate the returned structure.  Do not allocate a subarray,
13825         as x2nrealloc will do that.
13826         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
13827         instead of xnrealloc.
13828         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
13829
13830 2003-10-27  Bruno Haible  <bruno@clisp.org>
13831
13832         * lib/stdbool_.h: Better support for BeOS.
13833
13834 2003-10-26  Paul Eggert  <eggert@twinsun.com>
13835
13836         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
13837         now uses inline.
13838
13839 2003-10-26  Paul Eggert  <eggert@twinsun.com>
13840
13841         * lib/xalloc.h (xalloc_oversized): New static inline function, for
13842         callers that want to do their own size-overflow checking.  Include
13843         <stdbool.h>, since xalloc_oversized returns bool.
13844         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
13845         to use xalloc_oversized.
13846
13847         Add two functions x2realloc, x2nrealloc, for programs that grow
13848         arrays dynamically by doubling their sizes.
13849         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
13850         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
13851         New functions.
13852
13853         Port to C99 semantics for 'inline' of external functions.
13854         Bug reported by Bruno Haible.
13855         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
13856         with the old contents of xnmalloc.
13857         (xnmalloc, xmalloc): Use it.
13858         (xnrealloc_inline): New static inline function,
13859         with the old contents of xnrealloc.
13860         (xnrealloc, xrealloc): Use it.
13861
13862         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
13863         that.
13864
13865 2003-10-26  Karl Berry  <karl@gnu.org>
13866
13867         * config/srclist.txt (COPYING.DOC): no longer available from
13868         /gd/gnuorg; don't know where the ultimate source is.
13869
13870 2003-10-25  Paul Eggert  <eggert@twinsun.com>
13871
13872         Fix several address-calculation bugs in the hash modules,
13873         plus some minor code cleanup.
13874
13875         * lib/hash.h: Include <stdbool.h>, for bool.
13876         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
13877         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
13878         hash_get_n_entries, hash_get_max_bucket_length,
13879         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
13880         hash_rehash): Use size_t rather than unsigned.
13881         * lib/hash.c (struct hash_table, hash_get_n_buckets,
13882         hash_get_n_buckets_used, hash_get_n_entries,
13883         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
13884         hash_get_entries, hash_do_for_each, hash_string, is_prime,
13885         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
13886         Likewise.
13887         (SIZE_MAX): Define if not defined.
13888         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
13889         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
13890         hash_print):
13891         Use const * when possible.
13892         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
13893         (check_tuning): Fix bug: if tuning parameters were very close to
13894         0 or 1, rounding errors could have caused subscript violations.
13895         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
13896         (hash_initialize): Add 'fail:' label
13897         to free table and return NULL, and use it to simplify code.
13898         Use calloc rather than clearing the storage ourself.
13899         (hash_initialize, hash_rehash): Check for arithmetic overflow in
13900         buffer size calculations.
13901         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
13902         Include <stddef.h>, for size_t.
13903         * lib/hash-pjw.c (hash_pjw): Likewise.
13904         Switch to method described by Bruno Haible.
13905         Include <limits.h>, for CHAR_BIT.
13906         (SIZE_BITS): New macro.
13907
13908 2003-10-23  Paul Eggert  <eggert@twinsun.com>
13909
13910         * m4/getline.m4 (AM_FUNC_GETLINE):
13911         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
13912         hosts.  Problem reported by Derek Robert Price in
13913         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
13914         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
13915         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
13916
13917 2003-10-21  Paul Eggert  <eggert@twinsun.com>
13918
13919         * lib/getndelim2.c (getndelim2): When size calculation overflows,
13920         ceiling the allocation at NMAX bytes rather than silently
13921         discarding input bytes before NMAX is reached.  This makes
13922         a difference only if NMAX exceeds SIZE_MAX / 2.
13923
13924         * lib/obstack.c: Merge from glibc.
13925         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
13926         Add libc_hidden_def (_obstack_newchunk).
13927         (_obstack_free) [! defined _LIBC]: Remove.
13928         [defined _LIBC]: Make a strong alias from obstack_free, rather than
13929         a clone of the function body.
13930         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
13931         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
13932
13933         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
13934         glibc.
13935         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
13936         arg to memcpy.
13937
13938         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
13939         (obstack_ptr_grow_fast, obstack_int_grow_fast):
13940         Don't use lvalue casts, as GCC plans to remove support for them
13941         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
13942         was also present in the non-GCC version, indicating that this
13943         code had always been buggy and had never been widely used.
13944         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
13945         Use the fast variant of each macro, rather than copying the
13946         definiens of the fast variant; that way, we'll be more likely to
13947         catch future bugs in the fast variants.
13948
13949 2003-10-20  Bruno Haible  <bruno@clisp.org>
13950
13951         * modules/wait-process: New file.
13952         * MODULES.html.sh (func_all_modules): Add wait-process.
13953
13954 2003-10-20  Bruno Haible  <bruno@clisp.org>
13955
13956         * m4/wait-process.m4: New file.
13957
13958 2003-10-20  Bruno Haible  <bruno@clisp.org>
13959
13960         * lib/wait-process.h: New file, from GNU gettext.
13961         * lib/wait-process.c: New file, from GNU gettext.
13962
13963 2003-10-19  Jim Meyering  <jim@meyering.net>
13964
13965         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
13966         HPUX 10.20.
13967
13968 2003-10-18  Karl Berry  <karl@gnu.org>
13969
13970         * config/config.guess: update from config.
13971
13972 2003-10-16  Paul Eggert  <eggert@twinsun.com>
13973
13974         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
13975         (getgroups): First arg is int, not size_t.
13976         Don't let 'free' mangle errno.
13977
13978 2003-10-16  Paul Eggert  <eggert@twinsun.com>
13979
13980         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
13981
13982 2003-10-16  Karl Berry  <karl@gnu.org>
13983
13984         * config/config.{guess,sub}: update from config.
13985
13986 2003-10-16  Jim Meyering  <jim@meyering.net>
13987
13988         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
13989         memcpy.
13990
13991 2003-10-15  Paul Eggert  <eggert@twinsun.com>
13992
13993         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
13994         (SIZE_MAX): Remove.
13995         (new_exclude, add_exclude_file): Initial size no longer needs to
13996         be a power of 2.
13997         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
13998         our own address arithmetic overflow checking.
13999
14000         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
14001         (fnmatch): Do not alloca more than 2000 wide characters;
14002         instead, use malloc for large buffers.
14003         Check for address arithmetic overflow, and return -1
14004         with errno set to ENOMEM in that case.
14005         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
14006         (NEW_PATTERN): Do not alloca more than 8000 bytes;
14007         instead, return -1.  Check for address arithmetic overflow.
14008
14009 2003-10-14  Paul Eggert  <eggert@twinsun.com>
14010
14011         Handle invalid suffixes and overflow independently, so that
14012         callers can treat them independently as needed.  Fix some bugs in
14013         suffix handling, e.g., "100k@" was not diagnosed as an invalid
14014         suffix for a human-readable blocksize.  The major caller-visible
14015         change is the addition of a new
14016         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
14017         that both overflow and suffix chars were found.
14018
14019         * lib/human.c (humblock): Don't check separately for invalid suffix
14020         char; that is xstrtoumax's job (now that its bug is fixed).
14021         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
14022         INTMAX_MAX]: New macros.
14023         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
14024         TYPE_MAXIMUM): New macros.
14025         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
14026         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
14027         if overflow occurs, as it's what __strtol does and it's more useful
14028         in practice.
14029         (__xstrtol): If __strtol reports some error other than ERANGE,
14030         reflect it to the caller as LONGINT_INVALID.  If it reports
14031         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
14032         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
14033         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
14034         value.
14035         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
14036         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
14037         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
14038         [defined UINTMAX_MAX]: New macros.
14039
14040 2003-10-14  Bruno Haible  <bruno@clisp.org>
14041
14042         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
14043
14044 2003-10-14  Bruno Haible  <bruno@clisp.org>
14045
14046         * m4/sig_atomic_t: New file, from GNU gettext.
14047         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
14048
14049 2003-10-14  Bruno Haible  <bruno@clisp.org>
14050
14051         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
14052         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
14053         Also use volatile where needed.
14054
14055 2003-10-12  Paul Eggert  <eggert@twinsun.com>
14056
14057         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
14058         Change maintainer from Bruno Haible to 'all'.
14059
14060 2003-10-12  Paul Eggert  <eggert@twinsun.com>
14061
14062         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
14063
14064 2003-10-12  Paul Eggert  <eggert@twinsun.com>
14065
14066         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
14067         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
14068         and define in terms of the other primitives.
14069         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
14070         (SIZE_MAX): Define if not already defined.
14071         (array_size_overflow): New function.
14072         (xalloc_die): Abort instead of exiting if 'error' returns.
14073         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
14074         (xmalloc, xrealloc): Use them.
14075         (xcalloc): Check for address arithmetic overflow.
14076         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
14077         a bit faster than strcpy.
14078
14079 2003-10-10  Simon Josefsson  <jas@extundo.com>
14080
14081         * modules/argp (Depends-on): Add restrict and strcase.
14082
14083 2003-10-10  Simon Josefsson  <jas@extundo.com>
14084
14085         * m4/argp.m4: Add AC_C_INLINE.
14086
14087 2003-10-08  Paul Eggert  <eggert@twinsun.com>
14088
14089         Merge getpass from libc, plus a few fixes.
14090
14091         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
14092         Include <stdbool.h>.
14093         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
14094         __fsetlocking to empty.
14095         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
14096         do include <bits/libc-lock.h>.
14097         Do not include <fcntl.h>; not needed.
14098         [_LIBC]: Include <wchar.h>.
14099         (NOTCANCEL_MODE): New macro.
14100         (flockfile, funlockfile) [_LIBC]: New macros.
14101         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
14102         [!_LIBC]: New macros.
14103         (call_fclose): New function.
14104         (getpass): Use it.  Save tty stream separately; this simplifies the
14105         code and makes it more reliable if stdin happens to equal stdout.
14106         Invoke __fsetlocking on tty.
14107         Handle thread cancellation if needed.
14108         Namespace cleanup (use __tcgetattr, __getline).
14109         Use bool for Booleans.
14110         [USE_IN_LIBIO]: Handle wide streams.
14111         [!_LIBC]: Unconditionally do the fseek, since we don't know what
14112         stream might go where.
14113
14114         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
14115         doesn't have to include <stdio.h> before us.
14116         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
14117         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
14118         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
14119         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
14120         if not declared, so that we can use getpass.c code from libc without
14121         rewriting it.
14122         (flockfile, ftrylockfile, funlockfile): New macros.
14123
14124 2003-10-08  Paul Eggert  <eggert@twinsun.com>
14125
14126         * modules/getpass: Depend on stdbool.
14127
14128 2003-10-08  Paul Eggert  <eggert@twinsun.com>
14129
14130         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
14131
14132 2003-10-07  Karl Berry  <karl@gnu.org>
14133
14134         * config/config.{guess,sub}: update from config.
14135
14136 2003-10-06  Jim Meyering  <jim@meyering.net>
14137             Bruno Haible  <bruno@clisp.org>
14138
14139         This lets translators provide better translations for the
14140         "Written by ..." part of --version output.
14141         * lib/version-etc.h: Include stdarg.h.
14142         (version_etc_copyright): Declare as readonly.
14143         (version_etc): Make this function variadic with a NULL-terminated list
14144         of author name strings.
14145         (version_etc_va): New declaration.
14146         * lib/version-etc.c: Include stdarg.h, stdlib.h.
14147         (version_etc_copyright): Declare as readonly.
14148         (version_etc_va): New function. Provide a different translatable string
14149         for each possible number of authors < 10. Abbreviate when there are 10
14150         authors or more.
14151         (version_etc): Make this function variadic. Call version_etc_va.
14152         Suggestion from Gary V. Vaughan.
14153
14154         * lib/long-options.h (parse_long_options): Change prototype: the
14155         authors string is moved to the end and becomes variadic.
14156         * lib/long-options.c: Include stdarg.h.
14157         (parse_long_options): Make this function variadic, too.
14158         Call version_etc_va, not version_etc.
14159
14160 2003-10-06  Bruno Haible  <bruno@clisp.org>
14161
14162         * modules/version-etc-2: Remove file.
14163         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
14164
14165 2003-10-06  Bruno Haible  <bruno@clisp.org>
14166
14167         * modules/fatal-signal: New file.
14168         * MODULES.html.sh (func_all_modules): Add fatal-signal.
14169
14170 2003-10-06  Bruno Haible  <bruno@clisp.org>
14171
14172         * m4/fatal-signal.m4: New file.
14173         * m4/signalblocking.m4: New file, from GNU gettext.
14174
14175 2003-10-06  Bruno Haible  <bruno@clisp.org>
14176
14177         * lib/version-etc-2.h: Remove file.
14178         * lib/version-etc-2.c: Remove file.
14179
14180 2003-10-06  Bruno Haible  <bruno@clisp.org>
14181
14182         * lib/fatal-signal.h: New file, from GNU gettext.
14183         * lib/fatal-signal.c: New file, from GNU gettext.
14184
14185 2003-10-05  Paul Eggert  <eggert@twinsun.com>
14186
14187         * README: Rework advice for preventing empty .o files.
14188         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
14189         not <sys/types.h>.
14190
14191 2003-10-04  Karl Berry  <karl@gnu.org>
14192
14193         * lib/argp*: update from libc.
14194
14195 2003-10-04  Karl Berry  <karl@gnu.org>
14196
14197         * config/config.{guess,sub}: update from config.
14198
14199 2003-10-02  Bruno Haible  <bruno@clisp.org>
14200
14201         * modules/lchown (Include): Add lchown.h.
14202         * modules/time_r (Include): Use "..." syntax.
14203         * modules/xgetdomainname (Include): Add xgetdomainname.h.
14204
14205 2003-10-01  Simon Josefsson  <jas@extundo.com>
14206
14207         * MODULES.html.sh (func_all_modules): Move gethostname from section
14208         'based on' to section 'lacking' POSIX:2001.
14209
14210 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
14211
14212         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
14213         to output mode on the same stream.
14214
14215 2003-09-29  Paul Eggert  <eggert@twinsun.com>
14216
14217         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
14218         Fix arg typo in previous patch.
14219
14220 2003-09-28  Jim Meyering  <jim@meyering.net>
14221
14222         * lib/error.c: Correct cpp indentation.
14223
14224 2003-09-27  Paul Eggert  <eggert@twinsun.com>
14225
14226         * modules/free: New file.
14227
14228 2003-09-27  Paul Eggert  <eggert@twinsun.com>
14229
14230         * m4/free.m4: New file.
14231
14232 2003-09-27  Paul Eggert  <eggert@twinsun.com>
14233
14234         * lib/minmax.h (MIN, MAX)
14235         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
14236         Omit the special code that used __typeof__, since we worry that
14237         it could be more trouble than it's worth.  See:
14238         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
14239         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
14240
14241         * lib/free.c: New file.
14242
14243 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
14244
14245         Trivial fixes to Makefile.am parts of module listings.
14246         * modules/strstr: Append strstr.h to lib_SOURCES.
14247         * modules/strcase: Likewise, for strcase.h.
14248
14249 2003-09-27  Karl Berry  <karl@gnu.org>
14250
14251         * config/mkinstalldirs: update from automake.
14252
14253 2003-09-26  Paul Eggert  <eggert@twinsun.com>
14254
14255         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
14256         (error_tail): Do not loop, reallocating temporary buffer, since
14257         the output cannot contain more wide characters than the input
14258         contains bytes, the size must be big enough already.  This avoids
14259         one potential size overflow calculation.  Check for size overflow
14260         when calculating temporary buffer size.  Free temporary buffer
14261         when done, if it was allocated with malloc; this plugs a memory
14262         leak.  Remove casts from void * to pointers, that are no longer
14263         needed now that we're assuming C89 or better.
14264
14265         Merge error changes from glibc.
14266
14267         * lib/error.c, error.h: Update copyright notice header to match glibc.
14268         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
14269         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
14270         Disable cancellation while printing error.
14271         * lib/error.h: Prepend __ to parameter names.
14272
14273 2003-09-26  Jim Meyering  <jim@meyering.net>
14274
14275         * lib/error.c (error_tail): Move some declarations
14276         into inner scope where the local variables are used.
14277
14278 2003-09-26  Bruno Haible  <bruno@clisp.org>
14279
14280         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
14281         stpncpy().
14282         Don't define stpncpy through config.h; it's now done through stpncpy.h.
14283
14284 2003-09-26  Bruno Haible  <bruno@clisp.org>
14285
14286         * lib/stpncpy.h (gnu_stpncpy): New declaration.
14287         (stpncpy): Define as alias for gnu_stpncpy.
14288         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
14289
14290 2003-09-25  Simon Josefsson  <jas@extundo.com>
14291
14292         * lib/xgetdomainname.h: New file.
14293         * lib/xgetdomainname.c: New file.
14294
14295 2003-09-25  Simon Josefsson  <jas@extundo.com>
14296             Bruno Haible  <bruno@clisp.org>
14297
14298         * modules/getdomainname: New file.
14299         * modules/xgetdomainname: New file.
14300         * MODULES.html.sh (func_all_modules): Add getdomainname,
14301         xgetdomainname.
14302
14303 2003-09-25  Simon Josefsson  <jas@extundo.com>
14304             Bruno Haible  <bruno@clisp.org>
14305
14306         * m4/getdomainname.m4: New file.
14307
14308 2003-09-25  Simon Josefsson  <jas@extundo.com>
14309             Bruno Haible  <bruno@clisp.org>
14310
14311         * lib/getdomainname.h: New file.
14312         * lib/getdomainname.c: New file.
14313
14314 2003-09-25  Karl Berry  <karl@gnu.org>
14315
14316         * lib/argp-fmtstream.c, argp-help.c: update from libc.
14317
14318 2003-09-25  Karl Berry  <karl@gnu.org>
14319
14320         * config/install-sh: update from automake.
14321
14322 2003-09-25  Bruno Haible  <bruno@clisp.org>
14323
14324         * modules/version-etc-2: New file, from modules/version-etc with
14325         modifications.
14326         * MODULES.html.sh (func_all_modules): Add version-etc-2.
14327
14328 2003-09-25  Bruno Haible  <bruno@clisp.org>
14329
14330         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
14331         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
14332
14333 2003-09-24  Simon Josefsson  <jas@extundo.com>
14334
14335         * modules/xgethostname: Add xgethostname.h.
14336
14337 2003-09-24  Paul Eggert  <eggert@twinsun.com>
14338
14339         * lib/linebuffer.c (freebuffer): Don't free the argument, just
14340         the buffer associated with the argument.  Bug reported by
14341         Simon Josefsson.
14342
14343 2003-09-24  Paul Eggert  <eggert@twinsun.com>
14344
14345         * README: Document assumptions that 'int' is at least 32 bits
14346         wide, that integer arithmetic is 2's complement without overflow,
14347         that there are no holes in integer values, that adding sizes of
14348         two nonoverlapping objects can't overflow, and that all-bits-zero
14349         yields scalar zero.  Fix spelling and capitalization typos.
14350
14351 2003-09-19  Karl Berry  <karl@gnu.org>
14352
14353         * lib/argp.h: update from libc.
14354
14355 2003-09-17  Paul Eggert  <eggert@twinsun.com>
14356
14357         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
14358         to avoid spurious warnings like "AC_RUN_IFELSE was called before
14359         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
14360
14361 2003-09-17  Paul Eggert  <eggert@twinsun.com>
14362
14363         * gnulib-tool: Use "test -h", not "test -L", for portability
14364         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
14365         (tags_regexp): Remove, since \| doesn't conform to POSIX.
14366         (sed_extract_prog): Issue s commands one-by-one, rather than
14367         using \| in one s command.
14368
14369 2003-09-16  Paul Eggert  <eggert@twinsun.com>
14370
14371         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
14372         input error, instead of returning NULL the next time we are called
14373         (and therefore losing track of errno).
14374
14375 2003-09-16  Bruno Haible  <bruno@clisp.org>
14376
14377         * gnulib-tool (func_create_testdir): Warn about duplicated
14378         dependencies.
14379
14380 2003-09-15  Paul Eggert  <eggert@twinsun.com>
14381
14382         * modules/argmatch, modules/fatal, modules/obstack,
14383         modules/xalloc, modules/xgethostname: Sort dependencies by
14384         importance, not alphabetically.
14385
14386 2003-09-15  Paul Eggert  <eggert@twinsun.com>
14387
14388         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
14389         fails, so that the caller gets the proper errno.
14390
14391         * lib/readutmp.c (read_utmp): Likewise.
14392         Check for fstat error.  Close stream and free storage
14393         when failing.
14394
14395 2003-09-14  Karl Berry  <karl@gnu.org>
14396
14397         * config/srclist.txt (strdup.c): disable for c89 changes.
14398
14399 2003-09-14  Jim Meyering  <jim@meyering.net>
14400
14401         * lib/getloadavg.c: Correct cpp indentation.
14402         * lib/strdup.c: Likewise.
14403         * lib/vasnprintf.c: Likewise.
14404
14405 2003-09-14  Bruno Haible  <bruno@clisp.org>
14406
14407         * modules/fwriteerror: New file.
14408         * MODULES.html.sh (func_all_modules): Add fwriteerror.
14409
14410 2003-09-14  Bruno Haible  <bruno@clisp.org>
14411
14412         * lib/fwriteerror.h: New file.
14413         * lib/fwriteerror.c: New file.
14414
14415 2003-09-12  Paul Eggert  <eggert@twinsun.com>
14416
14417         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
14418         modules/xgethostname, modules/xalloc: Depend on exit.
14419
14420 2003-09-12  Paul Eggert  <eggert@twinsun.com>
14421
14422         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
14423
14424         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
14425         and AC_MINIX, too, so that their extensions are available.
14426
14427         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
14428         This macro has been superseded by gl_BACKUPFILE.
14429
14430         More patches to assume C89 or better.
14431
14432         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
14433
14434         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
14435         unconditionally.
14436         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
14437         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
14438         Include <string.h>, <stdlib.h> unconditionally.
14439         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
14440         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
14441         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
14442         headers or for string.h.
14443         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
14444         or strtoul.
14445
14446         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
14447         headers.
14448         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
14449         * m4/userspec.m4 (gl_USERSPEC): Likewise.
14450         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
14451         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
14452         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
14453         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
14454         memcpy, memset.
14455         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
14456         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
14457         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
14458         strtol.
14459         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
14460         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
14461         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
14462         strtoul.
14463
14464 2003-09-12  Paul Eggert  <eggert@twinsun.com>
14465
14466         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
14467         * lib/obstack.c [!defined _LIBC]: Likewise.
14468         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
14469         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
14470         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
14471
14472         More changes to assume C89 or better.
14473
14474         * lib/error.c (error_tail): Assume vprintf.
14475
14476         * lib/argmatch.c (getenv): Remove decl.
14477         * lib/progreloc.c (get_full_program_name): Define via prototype.
14478         * lib/setenv.c (clearenv): Likewise.
14479         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
14480         needed.
14481         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
14482         (malloc, memcpy): Remove decls.
14483         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
14484         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
14485         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
14486         (memcpy): Remove macro.
14487         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
14488         (__P): Remove.  All uses removed.
14489         (PTR): Remove.  All uses changed to void *.
14490         (CHAR_BIT, NULL): Remove.
14491         (spaces, zeros, memset_space, memset_zero)
14492         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
14493         Remove.
14494         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
14495         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
14496         Define with prototype.
14497         Remove now-unnecessary prototype decl.
14498         (extra_args_spec): Assume ANSI C.  All uses changed.
14499         (extra_args_spec_iso): Remove.
14500         (my_strftime, emacs_strftimeu): Define via prototype.
14501         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
14502         unconditionally.
14503         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
14504         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
14505         (strtoul, strtol): Remove decls.
14506         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
14507         LONG_MAX): Remove.
14508         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
14509         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
14510         (LOCALE_PARAM_PROTO): New macro.
14511         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
14512         (INTERNAL (strtol), strtol): Define with a prototype.
14513         (PARAMS): Remove.  All uses removed.
14514         * lib/tempname.c: Include <string.h> unconditionally.
14515         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
14516         * lib/xgethostname.c (main): Define with a prototype.
14517         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
14518         Include <stdlib.h> unconditionally.
14519         (calloc, malloc, realloc, free): Remove decls.
14520         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
14521         Include <stdlib.h> unconditionally.  Sort include file names.
14522         (strtod): Remove.
14523         (xstrtod): Define with a prototype.
14524         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
14525         (strtol, strtoul): Remove decls.
14526
14527 2003-09-11  Paul Eggert  <eggert@twinsun.com>
14528
14529         More patches to assume C89 or better.
14530         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
14531         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
14532         string.h, memchr, STDC_HEADERS.
14533
14534 2003-09-11  Paul Eggert  <eggert@twinsun.com>
14535
14536         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
14537         Include <stdlib.h>, <string.h> unconditionally.
14538         Remove now-unnecessary cast to char *.
14539         * lib/strnlen.c: Include <string.h> unconditionally.
14540         * lib/yesno.c (yesno): Define with a prototype.
14541
14542 2003-09-11  Bruno Haible  <bruno@clisp.org>
14543
14544         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
14545
14546 2003-09-10  Jim Meyering  <jim@meyering.net>
14547
14548         * lib/error.c: Correct indentation of cpp directives.
14549
14550 2003-09-10  Bruno Haible  <bruno@clisp.org>
14551
14552         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
14553         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
14554         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
14555         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
14556         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
14557         <stdlib.h> and <string.h> checks.
14558         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
14559         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
14560
14561 2003-09-10  Bruno Haible  <bruno@clisp.org>
14562
14563         * lib/strcspn.c: Include <string.h> unconditionally.
14564         * lib/strpbrk.c: Include <string.h> unconditionally.
14565         * lib/strstr.c: Include <string.h> unconditionally.
14566         * lib/unicodeio.c: Include <string.h> unconditionally.
14567         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
14568         * lib/unsetenv.c: Likewise.
14569         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
14570         * lib/yesno.c: Include <stdlib.h> unconditionally.
14571         (rpmatch): Add prototype.
14572
14573 2003-09-09  Paul Eggert  <eggert@twinsun.com>
14574
14575         More patches to assume C89 or better.
14576         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
14577         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
14578         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
14579         or for string.h.
14580         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
14581         stdlib.h.
14582         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
14583         C headers.
14584         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
14585         string.h.
14586         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
14587         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
14588         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
14589         or for string.h.
14590         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
14591         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
14592         C headers.
14593         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
14594         memcpy.
14595         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
14596         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
14597         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
14598         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
14599         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
14600         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
14601         string.h, free.
14602         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
14603         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
14604         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
14605         C headers, or for string.h.
14606         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
14607         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
14608         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
14609         headers, memory.h, stdlib.h, string.h, strings.h.
14610         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
14611         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
14612         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
14613         strchr.
14614         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
14615         headers, memory.h, string.h.
14616         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
14617         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
14618         free.
14619         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
14620         headers.
14621         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
14622         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
14623         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
14624         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
14625         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
14626
14627 2003-09-09  Paul Eggert  <eggert@twinsun.com>
14628
14629         More K&R removal.
14630
14631         * lib/acosl.c (main): Use a prototype.
14632         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
14633         tanl.c: Likewise.
14634
14635         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
14636
14637         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
14638         (getopt, etopt_long, getopt_long_only, _getopt_internal)
14639         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
14640         with a prototype.
14641         * lib/getopt.c (const): Remove macro.
14642         Include <string.h> unconditionally.
14643         (my_index): Remove; all uses changed to strchr.
14644         (strlen): Remove decl.
14645         (exchange): Remove forward decl; no longer needed.
14646         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
14647         Define with prototype.
14648         * lib/getopt1.c (const): Remove macro.
14649         (getopt_long, getopt_long_only, main): Define with prototype.
14650
14651         * lib/getugroups.c: Include <string.h> unconditionally.
14652
14653         * lib/getusershell.c: Include <stdlib.h> unconditionally.
14654         (getusershell, setusershell, endusershell, readname, main):
14655         Define with prototypes.
14656
14657         * lib/group-member.c: Include group-member.h first.
14658         Include <stdlib.h> unconditionally.
14659
14660         * lib/hard-locale.c: Include hard-locale.h first.
14661         Include <stdlib.h>, <string.h> unconditionally.
14662
14663         * lib/hash.c (free, malloc): Remove decls.
14664         Include <stdlib.h> unconditionally.
14665
14666         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
14667         (getenv): Do not declare.
14668
14669         * lib/idcache.c: Include <string.h> unconditionally.
14670
14671         * lib/long-options.c: Include long-options.h first, to test interface.
14672         Include <stdlib.h> unconditionally.
14673
14674         * lib/makepath.c: Include makepath.h first, to test interface.
14675         Include <stdlib.h> and <string.h> unconditionally.
14676
14677         * lib/linebuffer.c: Include <stdlib.h>.
14678         (free): Remove decl.
14679
14680         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
14681         stddef.h. rpl_malloc returns void *, not char *.
14682         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
14683         prototype.
14684
14685         * lib/md5.h: Include <limits.h> unconditionally.
14686         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
14687         (__P): Remove; all uses removed.
14688         * lib/md5.c: Include "md5.h" first.
14689         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
14690         md5_buffer, md5_process_bytes, md5_process_block):
14691         Define with prototypes.
14692         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
14693         * lib/sha.c: Include "sha.h" first.
14694         Include <stdlib.h>, <string.h> unconditionally.
14695
14696         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
14697         * lib/memcmp.c (__ptr_t): Likewise.
14698         * lib/memrchr.c (__ptr_t): Likewise.
14699         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
14700         Include <string.h> unconditionally.
14701         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
14702         * lib/memchr.c: Include <stdlib.h> unconditionally.
14703         * lib/memchr.c (LONG_MAX): Remove.
14704         * lib/memrchr.c (LONG_MAX): Likewise.
14705         * lib/memchr.c (__memchr): Define via a prototype.
14706         * lib/memrchr.c (__memrchr): Likewise.
14707         * lib/memcmp.c (__P): Remove, and remove all uses.
14708         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
14709         Remove forward decls; no longer needed.
14710         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
14711         Use types required by C89 in prototype.
14712
14713         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
14714         * lib/savedir.c: Likewise.
14715         * lib/mkdir.c (free): Remove decl.
14716         * lib/rmdir.c (rmdir): Define with a prototype.
14717         * lib/savedir.c: Include savedir.h first, to test interface.
14718
14719         * lib/mktime.c (STDC_HEADERS): Remove.
14720         Include <stdlib.h>, <string.h> unconditionally.
14721
14722         * lib/modechange.c: Include <stdlib.h> unconditionally.
14723         (malloc): Remove decl.
14724
14725         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
14726         (free): Remove decl.
14727
14728         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
14729         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
14730         (This type really should be intptr_t, but that's a C99ism.)
14731         (_obstack_memcpy): Remove: all uses changed to memcpy.
14732         Include <string.h> unconditionally.
14733         (struct obstack): Assume __STDC__ for types of members
14734         chunkfun, freefun, extra_arg.
14735         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
14736         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
14737         obstack_begin, obstack_specify_allocation,
14738         obstack_specify_allocation_with_arg, obstack_chunkfun,
14739         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
14740         Remove unprototyped decls and the macros that use them.
14741         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
14742         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
14743         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
14744         (defined __STDC__ && __STDC__)]:
14745         Remove nonprototyped code.
14746         Include <stdlib.h> unconditionally.
14747         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
14748         _obstack_allocated_p, _obstack_free, obstack_free,
14749         _obstack_memory_used, print_and_abort):
14750         Define using prototypes.
14751         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
14752         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
14753         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
14754         obstack_next_free, obstack_object_size, obstack_room) [0]:
14755         Remove unused, unprototyped code.
14756
14757         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
14758
14759         * lib/physmem.c (physmem_total, physmem_available, main): Define
14760         with prototypes.
14761
14762         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
14763         (main): Define with a prototype.
14764
14765         * lib/posixver.c (getenv): Remove decl.
14766
14767         * lib/putenv.c (malloc): Returns void *, not char *.
14768         Include <string.h> unconditionally.
14769         (strchr, memcpy, NULL): Do not define.
14770
14771         * lib/readtokens.c: Include readtokens.h first, to test interface.
14772         Include <stdlib.h>, <string.h> unconditionally.
14773         (init_tokenbuffer): Define with a prototype.
14774
14775         * lib/regex.c (PARAMS): Remove.  All uses removed.
14776         All uses of _RE_ARGS removed, too.
14777         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
14778         unconditionally.
14779         (bzero): Assume memset exists.
14780         (memcmp, memcpy, NULL): Remove.
14781         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
14782         char, or assignments to local vars of type signed char.
14783         (init_syntax_once, PREFIX(extract_number_and_incr),
14784         PREFIX(print_partial_compiled_pattern),
14785         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
14786         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
14787         PREFIX(regex_grow_registers), PREFIX(regex_compile),
14788         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
14789         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
14790         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
14791         wcs_compile_range, byte_compile_range, truncate_wchar,
14792         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
14793         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
14794         count_mbs_length, wcs_re_match_2_internal,
14795         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
14796         PREFIX(alt_match_null_string_p),
14797         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
14798         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
14799         regfree, PREFIX(extract_number)): Define with prototype.  Remove
14800         now-unnecessary declaration, if any.
14801         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
14802         regcomp, regexec):
14803         Remove now-unnecessary casts among pointer types.
14804         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
14805
14806         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
14807         (free): Remove decl.
14808
14809         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
14810
14811         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
14812         (free): Remove decl.
14813
14814         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
14815         * lib/xgetcwd.c: Likewise.
14816
14817         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
14818         (free): Remove decl.
14819
14820         * lib/strchrnul.c (strchrnul): Define with a prototype.
14821         Fix bug: c_in was not converted to char before searching.
14822
14823         The following changes are not K&R related:
14824
14825         * lib/group-member.h: Include <sys/types.h>, so that this file is
14826         self-contained.
14827         * lib/makepath.h: Likewise.
14828
14829         * lib/getusershell.c (readname, default_index, line_size, readname):
14830         Use size_t, not int, for sizes.
14831         (readname): If the size overflows, report an error instead of
14832         looping forever.
14833
14834 2003-09-09  Paul Eggert  <eggert@twinsun.com>
14835
14836         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
14837         libc.
14838
14839 2003-09-09  Paul Eggert  <eggert@twinsun.com>
14840
14841         * README: New section: portability guidelines.
14842
14843 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
14844
14845         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
14846         C89 spec.
14847
14848 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
14849
14850         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
14851
14852 2003-09-08  Paul Eggert  <eggert@twinsun.com>
14853
14854         Assume C89 or better; remove K&R cruft.
14855         A few of these changes were first proposed by Derek Robert Price
14856         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
14857
14858         * lib/addext.c: Include <string.h> unconditionally.
14859         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
14860         Don't declare getenv or malloc.
14861
14862         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
14863         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
14864         (NULL): Remove.
14865         (find_stack_direction, alloca): Use prototypes.
14866
14867         * lib/atexit.c (atexit): Define using a prototype.
14868
14869         * lib/basename.c, dirname.c, stripslash.c:
14870         Include <string.h> unconditionally.
14871
14872         * lib/bcopy.c: Include <stddef.h>.
14873         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
14874
14875         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
14876
14877         * lib/error.h (error, error_at_line, error_print_progname)
14878         [! (defined (__STDC__) && __STDC__)]: Remove decls.
14879         * lib/error.c: Include error.h first, to check interface.
14880         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
14881         (VA_START): Remove; all uses changeed to va_start.
14882         (exit, strerror): Remove decls.
14883         (error_print_progname): Prototype uncondionally.
14884         Don't include <errno.h>; no longer needed.
14885         (private_strerror): Remove.
14886         (error_tail): Always define.
14887         (error, error_at_line): Assume C89 or better; always use prototypes.
14888         * lib/fatal.c: Include "fatal.h" first, to test interface.
14889         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
14890         (VA_START): Remove; all uses changed to va_start.
14891         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
14892         this case.
14893         (exit): Remove decl.
14894         (fatal): Prototype unconditionally.  Assume va_start works.
14895         Abort at end, to pacify gcc.
14896
14897         * lib/euidaccess.c (main): Define with a prototype.
14898
14899         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
14900
14901         * lib/exitfail.c: Include <stdlib.h> unconditionally.
14902
14903         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
14904         prototypes.
14905         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
14906         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
14907         (getenv): Remove decl.
14908         (fnmatch): Define using a prototype.
14909         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
14910         (FCT): Define using a prototype.
14911
14912         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
14913
14914         * lib/gethostname.c: Include <stddef.h>.
14915         (gethostname): Define with prototype.  Length is size_t, not int.
14916
14917 2003-09-08  Paul Eggert  <eggert@twinsun.com>
14918
14919         Assume C89 or better; remove K&R cruft.
14920         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
14921         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
14922         string.h, getenv, malloc.
14923         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
14924         headers.
14925         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
14926         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
14927         do not check for strerror.
14928         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
14929         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
14930         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
14931         do not check for doprnt or vprintf.
14932         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
14933         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
14934
14935 2003-09-08  Paul Eggert  <eggert@twinsun.com>
14936
14937         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
14938         getversion.c should have been removed then, but was accidentally
14939         preserved.
14940
14941         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
14942         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
14943
14944 2003-09-08  Karl Berry  <karl@gnu.org>
14945
14946         * config/config.sub, config.guess, srclistvars.sh: update from savannah
14947                 config, forget about prep.
14948
14949         * config/depcomp, missing: update from automake.
14950
14951 2003-09-07  Paul Eggert  <eggert@twinsun.com>
14952
14953         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
14954         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
14955
14956 2003-09-07  Paul Eggert  <eggert@twinsun.com>
14957
14958         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
14959         copy_tm_result.  Bug reported by Simon Josefsson in
14960         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
14961
14962 2003-09-06  Paul Eggert  <eggert@twinsun.com>
14963
14964         * m4/time_r.m4: New file.
14965         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
14966         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
14967         is. Check for timegm declaration.
14968         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
14969         Do not check for gmtime_r.
14970         Replace mktime if __mktime_internal does not exist and if mktime
14971         hasn't been replaced already.
14972
14973 2003-09-06  Paul Eggert  <eggert@twinsun.com>
14974
14975         * lib/time_r.c, time_r.h: New files.
14976
14977         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
14978         __localtime_r.
14979         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
14980         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
14981
14982         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
14983         __gmtime_r.
14984         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
14985         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
14986         Include <time_r.h>.
14987
14988         * lib/timegm.c: Switch to glibc implementation, with the following
14989         changes:
14990         [defined HAVE_CONFIG_H]: Include <config.h>.
14991         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
14992         (__mktime_internal) [!defined _LIBC]: New decl.
14993         (__gmtime_r) [!defined _LIBC]: New macro and function.
14994         (timegm): Use a prototype, since gnulib assumes C89.
14995         Do not bother declaring tmp to be const, as it's not really usefu.
14996         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
14997         (timegm): Declare only if HAVE_DECL_TIMEGM.
14998
14999 2003-09-06  Paul Eggert  <eggert@twinsun.com>
15000
15001         * MODULES.html.sh (func_all_modules): Add time_r.
15002         * modules/time_r: New file.
15003         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
15004         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
15005
15006 2003-09-03  Paul Eggert  <eggert@twinsun.com>
15007
15008         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
15009         Bug reported by Lute Kamstra in
15010         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
15011
15012         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
15013         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
15014         course with correspondingly smaller numbers for tomorrow and
15015         yesterday.  From Tadayoshi Funaba.  Originally installed into
15016         sh-utils on 1999-08-07, but the patch got lost (I guess during the
15017         coreutils merge?).
15018
15019 2003-08-31  Simon Josefsson  <jas@extundo.com>
15020
15021         * modules/timegm: New file.
15022         * MODULES.html.sh (func_all_modules): Add timegm.
15023
15024 2003-08-31  Simon Josefsson  <jas@extundo.com>
15025
15026         * m4/timegm.m4: New file.
15027
15028 2003-08-31  Simon Josefsson  <jas@extundo.com>
15029
15030         * lib/timegm.h: New file.
15031         * lib/timegm.c: New file.  Based on
15032         wget-1.8.2/src/http.c:mktime_from_utc.
15033
15034 2003-08-31  Karl Berry  <karl@gnu.org>
15035
15036         * lib/argp.h: update from libc.
15037
15038 2003-08-28  Bruno Haible  <bruno@clisp.org>
15039
15040         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
15041         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
15042         followed by '#define fnmatch fnmatch_posix' gives an error.
15043
15044 2003-08-28  Bruno Haible  <bruno@clisp.org>
15045
15046         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
15047         warning on QNX, which defines O_BINARY to 000000.
15048
15049 2003-08-27  Jim Meyering  <jim@meyering.net>
15050
15051         * m4/mkstemp.m4: Require that the system mkstemp be able to create
15052         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
15053         would fail after 32.  Reported by Danny Levinson.  Details here:
15054         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
15055
15056 2003-08-24  Bruno Haible  <bruno@clisp.org>
15057
15058         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
15059         MSVC7 <stdio.h> is included later.
15060
15061 2003-08-22  Simon Josefsson  <jas@extundo.com>
15062
15063         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
15064
15065 2003-08-20  Karl Berry  <karl@gnu.org>
15066
15067         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
15068
15069 2003-08-20  Bruno Haible  <bruno@clisp.org>
15070
15071         * modules/progname: New file.
15072         * MODULES.html.sh (func_all_modules): Add progname.
15073
15074 2003-08-20  Bruno Haible  <bruno@clisp.org>
15075
15076         * lib/progname.h: New file, from GNU gettext.
15077         * lib/progname.c: New file, from GNU gettext.
15078         * lib/progreloc.c: New file, from GNU gettext.
15079
15080 2003-08-19  Jim Meyering  <jim@meyering.net>
15081
15082         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
15083         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
15084
15085 2003-08-19  Bruno Haible  <bruno@clisp.org>
15086
15087         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
15088         more.
15089
15090 2003-08-19  Bruno Haible  <bruno@clisp.org>
15091
15092         * lib/xstrdup.c: Assume <string.h> exists.
15093
15094 2003-08-18  Paul Eggert  <eggert@twinsun.com>
15095
15096         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
15097         in makefile rules.
15098
15099 2003-08-18  Jim Meyering  <jim@meyering.net>
15100
15101         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
15102         * m4/lib-ld.m4: Likewise.
15103
15104 2003-08-18  Jim Meyering  <jim@meyering.net>
15105
15106         * lib/setenv.h: Indent nested cpp directive.
15107         * lib/vasnprintf.c: Remove trailing blanks.
15108
15109 2003-08-17  Simon Josefsson  <jas@extundo.com>
15110
15111         * modules/xstrndup: New file.
15112         * MODULES.html.sh (func_all_modules): Add xstrndup.
15113
15114 2003-08-17  Simon Josefsson  <jas@extundo.com>
15115
15116         * modules/argp: Fix autoconf macro name. Add more dependencies.
15117
15118 2003-08-17  Simon Josefsson  <jas@extundo.com>
15119
15120         * m4/xstrndup.m4: New file.
15121
15122 2003-08-17  Simon Josefsson  <jas@extundo.com>
15123
15124         * m4/argp.m4: New file.
15125
15126 2003-08-17  Simon Josefsson  <jas@extundo.com>
15127             Bruno Haible  <bruno@clisp.org>
15128
15129         * lib/xstrndup.h: New file.
15130         * lib/xstrndup.c: New file.
15131
15132 2003-08-17  Bruno Haible  <bruno@clisp.org>
15133
15134         * modules/strndup (Files, Include): Add lib/strndup.h.
15135
15136 2003-08-17  Bruno Haible  <bruno@clisp.org>
15137
15138         * modules/euidaccess (Files): Add lib/euidaccess.h.
15139
15140 2003-08-17  Bruno Haible  <bruno@clisp.org>
15141
15142         * lib/strndup.h: New file.
15143
15144 2003-08-17  Bruno Haible  <bruno@clisp.org>
15145
15146         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
15147         like AC_GNU_SOURCE.
15148         * modules/extensions (configure.ac): Comment out the invocation of
15149         gl_USE_SYSTEM_EXTENSIONS.
15150
15151 2003-08-16  Paul Eggert  <eggert@twinsun.com>
15152
15153         Merges from coreutils, etc.
15154         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
15155         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
15156         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
15157         fixing a typo.
15158         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
15159         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
15160
15161 2003-08-16  Paul Eggert  <eggert@twinsun.com>
15162
15163         Document merge from coreutils.
15164         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
15165         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
15166         * modules/utime: Add m4/utimes-null.m4.
15167
15168 2003-08-16  Paul Eggert  <eggert@twinsun.com>
15169
15170         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
15171         space, undoing this 2003-08-12 change:
15172         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
15173
15174 2003-08-16  Paul Eggert  <eggert@twinsun.com>
15175
15176         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
15177         strtoul.c from libc, undoing this 2003-08-12 change:
15178         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
15179
15180 2003-08-16  Jim Meyering  <jim@meyering.net>
15181
15182         Merges from coreutils.
15183         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
15184         prefix.  Adjust cache variables similarly.  Create 500 rather than
15185         just 300 files, to exercise bug on Darwin6.5, too.
15186         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
15187         $missing_dir.
15188         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
15189         AM_SYS_POSIX_TERMIOS.
15190         Reported by mkc@mathdogs.com.
15191         Also change use of $am_cv_sys_posix_termios
15192         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
15193         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
15194         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
15195         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
15196         in /proc/mounts until it finds one with matching device number.  This
15197         is unnecessary when the FILE argument *is* a mount point.  No stat call
15198         is necessary in that case.  So, disable the statvfs-testing code on
15199         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
15200         as RedHat bug# 84846.
15201         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
15202         to 1MB, so as not to render systems with no stack size limit (e.g.,
15203         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
15204         Include <unistd.h>.  On some systems,
15205         it is required for the definition of _SC_PAGESIZE.
15206
15207 2003-08-16  Jim Meyering  <jim@meyering.net>
15208
15209         Merge from coreutils.
15210         * lib/xstrtoimax.c: #else #if -> #elif.
15211         * lib/xstrtoumax.c: Likewise.
15212
15213 2003-08-16  Jim Meyering  <jim@meyering.net>
15214
15215         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
15216         * m4/utimes.m4: Removed.
15217         * m4/utimes-null.m4: Renamed from utimes.m4.
15218
15219         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
15220         to 1MB, so as not to render systems with no stack size limit (e.g.,
15221         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
15222         Include <unistd.h>.  On some systems,
15223         it is required for the definition of _SC_PAGESIZE.
15224
15225 2003-08-16  Jim Meyering  <jim@meyering.net>
15226         and Paul Eggert  <eggert@cs.ucla.edu>
15227
15228         Merges from coreutils, etc.
15229
15230         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
15231         using the latest version from cvs.  This avoids problems with #line
15232         directives using a vendor (Sun) compiler.
15233         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
15234         Don't set GETGROUPS_LIB here; now it's
15235         done via getgroups.m4's wrapper function.
15236         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
15237         rather than just in sh-util/configure.in, so that the
15238         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
15239         same.
15240         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
15241         AC_FUNC_GETLOADAVG where to find getloadavg.c.
15242         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
15243         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
15244         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
15245         Remove code that is now done by the newly-required macros.
15246         Append $(EXEEXT) to DF_PROG.
15247         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
15248         Do not invoke or require the following here,
15249         since prereq.m4 or some gnulib .m4 now does this for us:
15250         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
15251         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
15252         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
15253         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
15254         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
15255         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
15256         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
15257         AC_FUNC_OBSTACK.
15258         Do not replace the following functions, as this is now the job
15259         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
15260         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
15261         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
15262         atexit getpass, strdup, getpagesize.
15263         Replace 'raise'.
15264         Do not check for the following functions, as this is now the job
15265         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
15266         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
15267         setregid.
15268         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
15269         Check for sys/sysctl.h.
15270         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
15271         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
15272         of checking for ssize_t ourselves.
15273
15274         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
15275         Require every macro that gnulib/modules/* suggests for us.
15276         (jm_PREREQ_ADDEXT): New macro.
15277         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
15278         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
15279
15280         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
15281         (gl_PHYSMEM): Use it.
15282         Also check for `table' function.
15283         Check for new headers and functions.
15284         Add check for sys/sysmp.h.
15285         With suggestions from Kaveh Ghazi.
15286         Ignore headers that are present but cannot be compiled.  This
15287         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
15288         C 5.4.
15289
15290 2003-08-15  Paul Eggert  <eggert@twinsun.com>
15291
15292         Document merge from coreutils.
15293         * modules/userspec: Depend on posixver.
15294         * modules/strftime: Depend on tzset.
15295
15296 2003-08-15  Paul Eggert  <eggert@twinsun.com>
15297
15298         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
15299         rather than tab, after '#' in shell-script copyright notices.
15300         Suggested by Bruno Haible.
15301
15302 2003-08-15  Paul Eggert  <eggert@twinsun.com>
15303
15304         * config/srclist-update: Use three spaces, rather than tab, after '#'
15305         in shell-script copyright notices.  Suggested by Bruno Haible.
15306         Remove unnecessary parenthesization in regular expression.
15307
15308 2003-08-15  Jim Meyering  <jim@meyering.net>
15309
15310         Merge from coreutils.
15311         * lib/xgethostname.c: Include <stdlib.h>.
15312         (xghostname): Don't exit for anything other than memory-related
15313         failure; just return NULL.
15314         * lib/userspec.c: Include "posixver.h".
15315         (parse_user_spec): Accept `.' as a separator only
15316         in pre-POSIX-200112 mode.
15317         * lib/strtoimax.c: Use #elif rather than #else #if.
15318         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
15319         Remove function, now that we can rely on a working tzset function.
15320         [!_LIBC]: Ensure that the required autoconf test has been run.
15321         [!defined _NL_CURRENT && HAVE_STRFTIME]:
15322         Use underlying_strftime for %r.
15323         * lib/sha.c: Merge in some clean-up and optimization changes from
15324         glibc.
15325         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
15326         Ensure that it is a multiple of 64.
15327         Rearrange loop exit tests so as to avoid performing an
15328         additional fread after encountering an error or EOF.
15329         * lib/realloc.c: Update copyright date.
15330
15331 2003-08-15  Jim Meyering  <jim@meyering.net>
15332         and Paul Eggert  <eggert@twinsun.com>
15333
15334         Merge from coreutils.
15335         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
15336         member but strut utmpx does not.  Needed for AIX 4.3.3.
15337         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
15338
15339 2003-08-15  Jim Meyering  <jim@meyering.net>
15340         and Paul Eggert  <eggert@cs.ucla.edu>
15341
15342         Merges from coreutils, etc.
15343         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
15344         Require gl_FUNC_TZSET_CLOBBER.
15345         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
15346         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
15347         members.
15348
15349 2003-08-14  Paul Eggert  <eggert@twinsun.com>
15350
15351         Help the merge from coreutils.
15352         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
15353         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
15354         * m4/tzset.m4: Use it too.
15355
15356 2003-08-14  Paul Eggert  <eggert@twinsun.com>
15357
15358         * modules/tzset: New file.
15359
15360 2003-08-14  Jim Meyering  <jim@meyering.net>
15361
15362         Merges from coreutils.
15363         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
15364         variable names, rather than @FNMATCH_H@.
15365         * modules/alloca: Likewise for $(ALLOCA_H).
15366
15367         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
15368         the three copies of the literal target, `fnmatch.h'.
15369         * modules/alloca (alloca.h): Likewise.
15370
15371 2003-08-14  Jim Meyering  <jim@meyering.net>
15372
15373         Merge from coreutils.
15374         * m4/tzset.m4: New file.
15375         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
15376         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
15377         otherwise, AIX 5.1 systems would end up using the latter.
15378         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
15379         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
15380         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
15381         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
15382
15383 2003-08-14  Jim Meyering  <jim@meyering.net>
15384
15385         Merge from coreutils.
15386         * lib/obstack.h: Whitespace changes.
15387         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
15388         and xcalloc return values.
15389         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
15390         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
15391         hang on OSF/1 5.1 for DIR on both local and remote file systems.
15392         Reported by (and fix confirmed by) Nelson H. F. Beebe.
15393         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
15394         error from mntctl.
15395         Use mntctl's return value to drive the entry-processing loop, since
15396         we can't rely on the value of the vmt_length member in the last
15397         entry.  On some systems doing so could result in exhausting
15398         virtual memory.  Based in part on a patch from Mike Jetzer.
15399
15400 2003-08-14  Jim Meyering  <jim@meyering.net>
15401         and Paul Eggert  <eggert@twinsun.com>
15402
15403         Merges from coreutils, plus other fixes.
15404         * lib/physmem.c: Merge in portability changes from gcc/libiberty
15405         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
15406         for credits and details.  Thanks to Kaveh Ghazi for helping
15407         to keep these files in sync.
15408         (ARRAY_SIZE): Define it.
15409         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
15410         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
15411         (memcasecmp): Don't assume size_t fits in unsigned int.
15412         Remove casts and duplicate code.
15413         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
15414         (memcpy): Remove definition.
15415         Merge in some clean-up and optimization changes from glibc.
15416         [BLOCKSIZE]: Move definition to top of file.
15417         Ensure that it is a multiple of 64.
15418         Rearrange loop exit tests so as to avoid performing an
15419         additional fread after encountering an error or EOF.
15420         * lib/md5.h (md5_uintptr): Define.
15421         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
15422         return to the initial working directory.  Preserve errno
15423         for caller.
15424         * lib/idcache.c: Include "xalloc.h".
15425         (xmalloc, xrealloc): Remove decls.
15426         (getuser): Remove casts no longer required in C89.
15427         * lib/human.c: Include stdio.h, for sprintf.
15428         * lib/group-member.c: Include "xalloc.h".
15429         (xmalloc, xrealloc): Remove decls.
15430         (get_group_info): Remove casts no longer required in C89.
15431         * lib/getusershell.c (readname): Remove casts no longer required in
15432         C89.
15433         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
15434         * lib/getline.c: Whitespace fix, from coreutils.
15435
15436 2003-08-13  Paul Eggert  <eggert@twinsun.com>
15437
15438         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
15439         Check for isascii.
15440
15441         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
15442         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
15443         Undo previous (whitespace-only) change.
15444
15445 2003-08-13  Paul Eggert  <eggert@twinsun.com>
15446
15447         * lib/exclude.c: Include <ctype.h>
15448         (IN_CTYPE_DOMAIN): New macro.
15449         (is_space): New fn.
15450         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
15451         and empty lines.
15452
15453         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
15454         Undo previous (whitespace-only) change.
15455
15456 2003-08-13  Paul Eggert  <eggert@twinsun.com>
15457
15458         * config/srclist-update: Change update back to the old behavior,
15459         leaving whitespace alone.  Use one 'sed' command rather than a
15460         pipeline.
15461         (fixlicense): Now a variable, not a function.
15462         (remove_trailing_blanks): Remove.
15463         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
15464         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
15465         Undo previous (whitespace-only) change.
15466
15467 2003-08-12  Paul Eggert  <eggert@twinsun.com>
15468
15469         Merge from coreutils.
15470         * modules/euidaccess: Add lib_SOURCES, include for new
15471         file euidaccess.h
15472
15473 2003-08-12  Paul Eggert  <eggert@twinsun.com>
15474
15475         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
15476         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
15477         Normalize leading white space and remove trailing white space.
15478
15479         Merge from coreutils
15480         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
15481
15482         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
15483         0.12.1.  These files are now being upgraded automatically by
15484         ../config/srclist-update.
15485
15486 2003-08-12  Paul Eggert  <eggert@twinsun.com>
15487
15488         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
15489         Normalize leading white space and remove trailing white space.
15490         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
15491         notice, as per ../config/srclist-update.
15492
15493         Merge from coreutils.
15494         * lib/euidaccess.h: New file.
15495         * lib/euidaccess.c: Include it.
15496         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
15497         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
15498         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
15499
15500 2003-08-12  Paul Eggert  <eggert@twinsun.com>
15501
15502         * config/srclist-update: Add copyright notice.
15503         (remove_id_lines, remove_trailing_blanks): New constants.
15504         (fixfile): Use them to normalize spacing a bit in copied files.
15505         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
15506         Normalize leading white space and remove trailing white space.
15507
15508         * config/texinfo.tex: Sync with texinfo.
15509
15510         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
15511         strtoul.c from libc, to merge coreutils whitespace changes.
15512
15513         * config/srclist.txt: Get the following m4 files from gettext:
15514         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
15515         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
15516         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
15517         wint_t.m4.
15518
15519 2003-08-12  Karl Berry  <karl@gnu.org>
15520
15521         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
15522         been made.
15523
15524 2003-08-11  Paul Eggert  <eggert@twinsun.com>
15525
15526         * modules/gnu-source, m4/gnu-source.m4:
15527         Remove; we're assuming Autoconf 2.54 or later now.
15528         Suggested by Bruno Haible.
15529         * MODULES.html.sh (func_all_modules): Remove gnu-source.
15530
15531 2003-08-11  Bruno Haible  <bruno@clisp.org>
15532
15533         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
15534
15535 2003-08-11  Bruno Haible  <bruno@clisp.org>
15536
15537         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
15538         (vasnprintf): Use it instead of wcslen.
15539
15540 2003-08-11  Bruno Haible  <bruno@clisp.org>
15541
15542         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
15543         value to ensure that _Bool promotes to int. Use #define for _Bool when
15544         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
15545
15546 2003-08-10  Karl Berry  <karl@gnu.org>
15547
15548         * lib/regex.h: update from libc (whitespace fix).
15549
15550 2003-08-09  Paul Eggert  <eggert@twinsun.com>
15551
15552         Merge some files from coreutils.  These changes were
15553         originally made by Jim Meyering.
15554         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
15555         many older Unixes require this.
15556         * lib/alloca.c (alloca): Remove cast to argument of free;
15557         no longer needed in C89.
15558         * lib/alloca_.h, regex.h: Fix white space to match
15559         what GNU indent does.
15560
15561 2003-08-09  Paul Eggert  <eggert@twinsun.com>
15562
15563         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
15564         apparently Emacs's Unicode mode got confused before my 2003-08-05
15565         checkin.
15566
15567 2003-08-08  Paul Eggert  <eggert@twinsun.com>
15568
15569         * m4/extensions.m4: New file.
15570         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
15571         Require gl_USE_SYSTEM_EXTENSIONS.
15572         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
15573         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
15574
15575 2003-08-08  Paul Eggert  <eggert@twinsun.com>
15576
15577         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
15578         * modules/extensions, modules/gnu-source: New files.
15579         * modules/timespec, modules/unlocked-io: Depend on extensions.
15580
15581 2003-08-07 Paul Eggert  <eggert@twinsun.com>
15582
15583         * modules/restrict: New file.
15584         * MODULES.html.sh (func_all_modules): Add restrict.
15585         * modules/regex: Depend on restrict.
15586
15587 2003-08-07  Paul Eggert  <eggert@twinsun.com>
15588
15589         * m4/restrict.m4: New file.
15590         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
15591
15592 2003-08-07  Bruno Haible  <bruno@clisp.org>
15593
15594         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
15595         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
15596
15597 2003-08-07  Bruno Haible  <bruno@clisp.org>
15598
15599         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
15600         makes the module 'getndelim2' compatible with the module 'getline'.
15601
15602 2003-08-05  Paul Eggert  <eggert@twinsun.com>
15603
15604         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
15605         byte with "\201" to avoid glitches when editing that source file
15606         with multi-gnome-terminal.
15607
15608 2003-08-05  Paul Eggert  <eggert@twinsun.com>
15609
15610         * lib/bumpalloc.h: Remove.
15611
15612 2003-08-05  Paul Eggert  <eggert@twinsun.com>
15613
15614         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
15615         * modules/bumpalloc: Remove.
15616
15617 2003-08-04  Paul Eggert  <eggert@twinsun.com>
15618
15619         * lib/getloadavg.c: Change copyright notice and spacing to conform to
15620         GNU coding style.
15621
15622         Merge from coreutils.
15623         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
15624         1. From glibc.
15625         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
15626         from Karl Berry, implemented by Jim Meyering.
15627         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
15628         from Dmitry V. Levin.
15629         Remove anachronistic cast of xrealloc.
15630         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
15631         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
15632         type. Otherwise, it wouldn't compile with at least /bin/cc on
15633         ymp-cray-unicos9.0.2.X.
15634         Combine two mostly-identical uses of alloca into one.
15635         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
15636
15637 2003-08-04  Dave Love <d.love@dl.ac.uk>
15638
15639         [From Emacs.]
15640
15641         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
15642         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
15643         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
15644         obsolete NLIST_NAME_UNION.
15645         [__GNU__]: Undef BSD and FSCALE.
15646         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
15647
15648 2003-08-03  Paul Eggert  <eggert@twinsun.com>
15649
15650         * lib/stdbool_.h (_Bool): Make it signed char, instead of
15651         an enum type, so that it's guaranteed to promote to int.  See:
15652         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
15653
15654 2003-08-03  Karl Berry  <karl@gnu.org>
15655
15656         * config/depcomp: update from automake.
15657
15658 2003-07-31  Paul Eggert  <eggert@twinsun.com>
15659
15660         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
15661         (strerror): Don't assume that a printable int fits in 14 bytes.
15662
15663 2003-07-31  Bruno Haible  <bruno@clisp.org>
15664
15665         * modules/getpass-gnu: New file.
15666         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
15667
15668 2003-07-31  Bruno Haible  <bruno@clisp.org>
15669
15670         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
15671
15672 2003-07-24  Karl Berry  <karl@gnu.org>
15673
15674         * config/missing: update from automake.
15675
15676 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
15677             Bruno Haible  <bruno@clisp.org>
15678
15679         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
15680         * lib/getline.c (getline, getdelim): Likewise.
15681         Remove _GNU_SOURCE define; now it's defined in config.h through
15682         m4/getline.m4.
15683
15684 2003-07-23  Karl Berry  <karl@gnu.org>
15685
15686         * config/config.sub: update from prep.
15687
15688 2003-07-22  Paul Eggert  <eggert@twinsun.com>
15689
15690         * modules/xalloc (Depends-on): Add exitfail.
15691         * modules/xmemcoll: Likewise.
15692
15693 2003-07-22  Paul Eggert  <eggert@twinsun.com>
15694
15695         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
15696         over-parenthesization in macros.
15697
15698         Sync with coreutils.
15699
15700         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
15701         required by C99.
15702
15703         Use `exit_failure' for xalloc and xmemcoll instead of their own
15704         private exit-failure variables.
15705         * lib/xalloc.h (xalloc_exit_failure): Remove.
15706         * lib/xmalloc.c: Likewise.  Include exitfail.h.
15707         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
15708         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
15709         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
15710         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
15711
15712 2003-07-20  Jim Meyering  <jim@meyering.net>
15713
15714         * modules/closeout (Depends-on): Add exitfail.
15715         Suggestion from Bruno Haible.
15716
15717 2003-07-19  Karl Berry  <karl@gnu.org>
15718
15719         * config/config.sub: update from prep.
15720
15721 2003-07-18  Paul Eggert  <eggert@twinsun.com>
15722
15723         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
15724         Remove.
15725         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
15726         to test that it can stand by itself.  Include "exitfail.h".
15727         Clients should set exit_failure instead.
15728         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
15729
15730 2003-07-18  Bruno Haible  <bruno@clisp.org>
15731
15732         * modules/getndelim2: New file.
15733         * modules/getline: Share files with module getndelim2.
15734         * modules/getnline: Depend on getndelim2 instead of sharing files with
15735         it. Add getnline.c to lib_SOURCES.
15736         * MODULES.html.sh (func_all_modules): Add getndelim2.
15737
15738 2003-07-18  Bruno Haible  <bruno@clisp.org>
15739
15740         * m4/getndelim2.m4: New file.
15741         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
15742         invoke gl_PREREQ_GETNDELIM2.
15743         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
15744         gl_PREREQ_GETNDELIM2.
15745         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
15746         gl_GETNDELIM2.
15747
15748 2003-07-18  Bruno Haible  <bruno@clisp.org>
15749
15750         * lib/getndelim2.h: New file.
15751         * lib/getndelim2.c: Make into a module of its own. Include config.h,
15752         getndelim2.h.
15753         (getndelim2): Make non-static. Change return type to ssize_t.
15754         * lib/getline.h: Change argument names.
15755         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
15756         * lib/getnline.c: Include getndelim2.h.
15757
15758 2003-07-18  Andreas Schwab  <schwab@suse.de>
15759
15760         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
15761
15762 2003-07-17  Karl Berry  <karl@gnu.org>
15763
15764         * config/config.sub: update from prep.
15765
15766 2003-07-17  Bruno Haible  <bruno@clisp.org>
15767
15768         * modules/getnline: New file.
15769         * modules/getline: Add lib/getndelim2.c to source file list.
15770         * MODULES.html.sh (func_all_modules): Add getnline.
15771
15772 2003-07-17  Bruno Haible  <bruno@clisp.org>
15773
15774         * m4/getnline.m4: New file.
15775
15776 2003-07-17  Bruno Haible  <bruno@clisp.org>
15777
15778         * m4/Makefile.am.in: Remove file.
15779         * m4/Makefile.am: Remove file.
15780         * m4/Makefile.in: Remove file.
15781
15782 2003-07-17  Bruno Haible  <bruno@clisp.org>
15783
15784         * lib/getnline.h: New file.
15785         * lib/getnline.c: New file.
15786         * lib/getndelim2.c: New file, extracted from getline.c.
15787         (getndelim2): Renamed from getdelim2, with added nmax argument.
15788         * lib/getline.c: Include getndelim2.c.
15789         (getdelim2): Moved out to getndelim2.c.
15790         (getline, getdelim): Update.
15791
15792 2003-07-17  Bruno Haible  <bruno@clisp.org>
15793
15794         * lib/Makefile.am: Remove file.
15795         * lib/Makefile.in: Remove file.
15796
15797 2003-07-17  Bruno Haible  <bruno@clisp.org>
15798
15799         * configure.in: Remove file.
15800         * Makefile.in: Remove file.
15801
15802 2003-07-17  Bruno Haible  <bruno@clisp.org>
15803
15804         * MODULES.html.sh: Put the </BODY> right before </HTML>.
15805
15806 2003-07-16  Karl Berry  <karl@gnu.org>
15807
15808         * config/srclist-update: was running fixlicense twice, which caused
15809                 texinfo.tex to be nullified for some reason.  Simplify,
15810                 $gplsrc is no longer needed as far as I can see?
15811
15812 2003-07-16  Jim Meyering  <jim@meyering.net>
15813
15814         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
15815
15816 2003-07-15  Paul Eggert  <eggert@twinsun.com>
15817
15818         * config/srclist.txt: Get the following files from gettext-runtime/intl
15819         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
15820         ref-del.sin.  From Bruno Haible.
15821         * config/srclist-update (fixfile): Change grep pattern again, since the
15822         previous fix didn't work (there was another trailing $).  Use
15823         '[$]' to escape the $s.
15824
15825 2003-07-15  Karl Berry  <karl@gnu.org>
15826
15827         * lib/vasnprintf.c: update from gettext.
15828
15829 2003-07-15  Karl Berry  <karl@gnu.org>
15830
15831         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
15832         gets expanded when surrounded by '$'.
15833
15834 2003-07-15  Jim Meyering  <jim@meyering.net>
15835
15836         * modules/save-cwd: Don't depend on error.  From Derek Price.
15837
15838 2003-07-15  Jim Meyering  <jim@meyering.net>
15839
15840         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
15841
15842 2003-07-14  Simon Josefsson  <jas@extundo.com>
15843
15844         * modules/mempcpy: New file.
15845         * MODULES.html.sh (func_all_modules): Add mempcpy.
15846
15847 2003-07-14  Simon Josefsson  <jas@extundo.com>
15848
15849         * m4/mempcpy.m4: New file.
15850
15851 2003-07-14  Simon Josefsson  <jas@extundo.com>
15852
15853         * lib/mempcpy.h: New file.
15854         * lib/mempcpy.c: New file.
15855
15856 2003-07-14  Paul Eggert  <eggert@twinsun.com>
15857
15858         * modules/getdate, modules/posixtm: Depend on mktime.
15859
15860 2003-07-14  Paul Eggert  <eggert@twinsun.com>
15861
15862         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
15863         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
15864         unicodeio.c, unicodeio.h, unlocked-io.h:
15865         Switch from LGPL to GPL.
15866
15867 2003-07-14  Paul Eggert  <eggert@twinsun.com>
15868
15869         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
15870         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
15871         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
15872         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
15873         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
15874         updated automatically by ../config/srclist-update.  This changes
15875         their license from LPGL to GPL.
15876
15877 2003-07-14  Paul Eggert  <eggert@twinsun.com>
15878
15879         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
15880         assumed to refer to the root of the most recent stable gettext version.
15881         * config/srclistvars.sh: Add defaults for eggert.
15882         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
15883         Match "This program" as well as "The program".  This is needed
15884         for gettext.
15885
15886 2003-07-14  Jim Meyering  <jim@meyering.net>
15887
15888         Don't emit diagnostics.  Let callers do that.
15889         * lib/save-cwd.c: Don't include "error.h".
15890         (save_cwd): Don't call error.  Ensure that errno is valid
15891         when returning nonzero.
15892
15893         * lib/save-cwd.h (restore_cwd): Update prototype.
15894         * lib/save-cwd.c (restore_cwd): Remove two parameters.
15895         Simplify.  Don't call error upon failure.  Let callers do that.
15896         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
15897         when auditing is enabled.  But don't bother updating the #if.
15898
15899 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
15900
15901         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
15902         it breaks C++ compilation.
15903         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
15904
15905 2003-07-10  Simon Josefsson  <jas@extundo.com>
15906
15907         * modules/strchrnul (Makefile.am): Add strchrnul.h.
15908
15909 2003-07-10  Jim Meyering  <jim@meyering.net>
15910
15911         * m4/clock_time.m4: Remove trailing blank.
15912         * m4/intmax_t.m4: Likewise.
15913
15914 2003-07-10  Jim Meyering  <jim@meyering.net>
15915
15916         * lib/vasnprintf.c: Remove trailing blanks.
15917         Make cpp indentation consistent.
15918
15919 2003-07-09  Paul Eggert  <eggert@twinsun.com>
15920
15921         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
15922         posixver.c, strftime.c, strnlen.c, strverscmp.c:
15923         Switch from LGPL to GPL.
15924
15925 2003-07-09  Paul Eggert  <eggert@twinsun.com>
15926
15927         * config/srclist.txt: Sort sublists.  Add
15928         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
15929         that differ from gnulib for one reason or another; we'd like this list
15930         to be smaller but for now let's document what we have.
15931
15932 2003-07-08  Paul Eggert  <eggert@twinsun.com>
15933
15934         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
15935         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
15936         and sweeter "eval x=$x".
15937         * config/srclist.txt: Get lib/argp* from glibc.
15938
15939 2003-07-07  Paul Eggert  <eggert@twinsun.com>
15940
15941         * lib/mktime.c: Fix some boundary cases and remove need for floating
15942         point.
15943
15944         Issue a compile-time diagnostic if time_t is floating point, or if
15945         two's complement arithmetic is not in effect, or if arithmetic
15946         right shift does not propagate the sign.  These assumptions were
15947         all in the original code but they weren't checked.
15948
15949         (TIME_T_MIDPOINT, verify): New macros.
15950         (__isleap): Remove; it has integer overflow problems.
15951         (leapyear): New function, without those problems.
15952         (ydhms_tm_diff): Remove; splitting into two parts.
15953         (ydhms_diff): New function, containing the arithmetic part of
15954         the old ydhms_tm_diff function.  Issue a compile-time
15955         diagnostic if we are not using C99 integer division.
15956         Avoid casts when possible.
15957         (guess_time_tm): New function, containing the checking part of
15958         the old ydhms_tm_diff function.  Return the new value, rather than
15959         the difference between it and the old.  Accept a new argument T
15960         so that *T specifies the old value.  Check for overflow in the result.
15961
15962         (__mktime_internal): Use a time_t offset, not a long int offset.
15963         This undoes the 2003-06-04 change, which is no longer needed now
15964         that we have better overflow checking.
15965         (localtime_offset): Likewise.
15966
15967         (__mktime_internal): Avoid harmful overflow on hosts where time_t
15968         and long are 64-bit but int is only 32-bit.
15969         (ydhms_diff): Use long int to store year1 and yday1.
15970         Issue a compile-time diagnostic if long int is not wide enough.
15971
15972         (__mktime_internal): Use long int to store adjusted year and yday.
15973         Use plain C rather than preprocessor commands, if that doesn't
15974         affect efficiency.
15975         Check for overflow (and try to repair) after each probe
15976         rather than checking only at the very end.  This avoids some bugs
15977         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
15978         does not equal GMT offset at maximum time).
15979         Use integer to check for overflow rather than floating point; this
15980         is more portable to non-IEEE hosts, and is a tad faster.
15981         When we detect that we are oscillating between two values,
15982         don't check whether tm_isdst has the requested value, since
15983         we already know the answer.  When tm_isdst has the wrong value,
15984         use a different heuristic to find the right one, based on the
15985         extreme values actually observed in practice in tz2003a,
15986         rather than the (overly optimistic) "previous 3 calendar quarters".
15987
15988         (not_equal_tm, print_tm, check_result): Use "const T" rather than
15989         "T const" to accommodate glibc style.
15990         (check_result): Use less-confusing report format.  "long" -> "long int.
15991         (main): Likewise.
15992         Don't loop if the iteration overflows time_t.
15993         Allow a negative step in the iteration.
15994
15995 2003-07-06  Karl Berry  <karl@gnu.org>
15996
15997         * config/depcomp: update from automake.
15998         * config/config.sub: update from prep.
15999
16000 2003-07-03  Karl Berry  <karl@gnu.org>
16001
16002         * config/config.guess: update from prep.
16003
16004 2003-07-01  Paul Eggert  <eggert@twinsun.com>
16005
16006         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
16007         xreadlink.c now includes it unconditionally.
16008
16009 2003-07-01  Paul Eggert  <eggert@twinsun.com>
16010
16011         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
16012         having it depend on HAVE_SYS_TYPES_H.
16013
16014 2003-07-01  Bruno Haible  <bruno@clisp.org>
16015
16016         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
16017         <sys/types.h> should be sufficient.
16018         Reported by Paul Eggert.
16019
16020 2003-06-26  Karl Berry  <karl@gnu.org>
16021
16022         * config/depcomp: update from automake.
16023
16024 2003-06-26  Bruno Haible  <bruno@clisp.org>
16025
16026         * modules/human: Depend on module stdbool.
16027
16028 2003-06-25  Bruno Haible  <bruno@clisp.org>
16029
16030         * modules/readlink: New file.
16031         * modules/xreadlink: Depend on it.
16032         * MODULES.html.sh (func_all_modules): Add readlink.
16033
16034 2003-06-25  Bruno Haible  <bruno@clisp.org>
16035
16036         * m4/readlink.m4: New file.
16037
16038 2003-06-25  Bruno Haible  <bruno@clisp.org>
16039
16040         * lib/readlink.c: New file.
16041
16042 2003-06-22  Karl Berry  <karl@gnu.org>
16043
16044         * config/srclist.txt: update mkinstalldirs from automake.
16045         * config/mkinstalldirs: update.
16046
16047 2003-06-22  Bruno Haible  <bruno@clisp.org>
16048
16049         Portability to mingw32.
16050         * m4/ssize_t.m4: New file, from GNU gettext.
16051         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
16052         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
16053
16054 2003-06-22  Bruno Haible  <bruno@clisp.org>
16055
16056         * modules/safe-read: Add m4/ssize_t.m4.
16057         * modules/xreadlink: Add m4/ssize_t.m4.
16058
16059 2003-06-20  Bruno Haible  <bruno@clisp.org>
16060
16061         Assume C89, so PARAMS isn't needed.
16062         * lib/unicodeio.h (PARAMS): Remove.
16063         * lib/unicodeio.c: Don't use PARAMS.
16064
16065 2003-06-18  Karl Berry  <karl@gnu.org>
16066
16067         * config/config.{guess,sub}: update from prep.
16068
16069 2003-06-18  Jim Meyering  <jim@meyering.net>
16070
16071         Merge changes from coreutils.
16072         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
16073         Remove explicit declarations of xmalloc and realloc.
16074         Include xalloc.h.
16075         (read_utmp): Remove anachronistic cast of xmalloc.
16076
16077 2003-06-17  Paul Eggert  <eggert@twinsun.com>
16078
16079         Assume C89, so PARAMS isn't needed.
16080         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
16081         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
16082         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
16083         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
16084         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
16085         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
16086         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
16087         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
16088         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
16089         lib/xstrtod.h, lib/xstrtol.h: Likewise.
16090         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
16091         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
16092         no longer needed. Anyway, config.h should always be included before any
16093         other file.
16094
16095 2003-06-11  Simon Josefsson  <jas@extundo.com>
16096
16097         * modules/sysexits: New file.
16098         * MODULES.html.sh (func_all_modules): Add sysexits.
16099
16100 2003-06-11  Simon Josefsson  <jas@extundo.com>
16101
16102         * lib/sysexit_.h: New file.
16103
16104 2003-06-11  Derek Price  <derek@ximbiot.com>
16105
16106         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
16107         necessary.
16108
16109 2003-06-11  Bruno Haible  <bruno@clisp.org>
16110
16111         * m4/sysexits.m4: New file.
16112
16113 2003-06-10  Simon Josefsson <jas@extundo.com>
16114
16115         * lib/argp.h: New file, from glibc.
16116         * lib/argp-ba.c: New file, from glibc.
16117         * lib/argp-eexst.c: New file, from glibc.
16118         * lib/argp-fmtstream.c: New file, from glibc.
16119         * lib/argp-fmtstream.h: New file, from glibc.
16120         * lib/argp-fs-xinl.c: New file, from glibc.
16121         * lib/argp-help.c: New file, from glibc.
16122         * lib/argp-namefrob.h: New file, from glibc.
16123         * lib/argp-parse.c: New file, from glibc.
16124         * lib/argp-pv.c: New file, from glibc.
16125         * lib/argp-pvh.c: New file, from glibc.
16126         * lib/argp-xinl.c: New file, from glibc.
16127
16128 2003-06-10  Simon Josefsson  <jas@extundo.com>
16129
16130         * modules/strchrnul: New file.
16131
16132 2003-06-10  Simon Josefsson  <jas@extundo.com>
16133
16134         * modules/argp: New file.
16135
16136 2003-06-10  Simon Josefsson  <jas@extundo.com>
16137
16138         * m4/strchrnul.m4: New file.
16139
16140 2003-06-10  Simon Josefsson  <jas@extundo.com>
16141
16142         * lib/strchrnul.h: New file.
16143         * lib/strchrnul.c: New file.
16144
16145 2003-06-10  Bruno Haible  <bruno@clisp.org>
16146
16147         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
16148
16149 2003-06-07  Karl Berry  <karl@gnu.org>
16150
16151         * config/config.{guess,sub}: update from prep.
16152
16153 2003-06-07  Jim Meyering  <jim@meyering.net>
16154
16155         * modules/strtod: Use $(...) notation, not @...@ for
16156         AC_REPLACE'd variables.
16157         * modules/localcharset: Likewise.
16158
16159 2003-06-07  Jim Meyering  <jim@meyering.net>
16160
16161         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
16162         in place of my name in the copyright comment.
16163         Remove definition and uses of __P.
16164
16165         From coreutils.
16166         * lib/stat.c: Don't declare xmalloc explicitly.
16167         Instead, include "xalloc.h".
16168         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
16169         xrealloc, and xcalloc return values.
16170         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
16171         Improve comment.
16172         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
16173
16174 2003-06-07  Bruno Haible  <bruno@clisp.org>
16175
16176         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
16177         avoid AC_CONFIG_LINKS.
16178         * modules/fnmatch (Makefile.am): Use explicit creation rule for
16179         fnmatch.h, to avoid AC_CONFIG_LINKS.
16180         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
16181
16182 2003-06-07  Bruno Haible  <bruno@clisp.org>
16183
16184         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
16185         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
16186         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
16187         directory.
16188         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
16189         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
16190         directory.
16191
16192 2003-06-06  Jim Meyering  <jim@meyering.net>
16193
16194         Merge from coreutils.
16195         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
16196         Consolidate declarations and initializations of *_base* locals.
16197
16198         Merge from coreutils.
16199         This avoids a core dump on systems without GNU putenv,
16200         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
16201         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
16202         (unsetenv): New static function, from GNU libc.
16203         (rpl_putenv): Use it.
16204
16205         * lib/modechange.c: Remove trailing blanks.
16206
16207         Merge from coreutils.
16208         * lib/fsusage.c: Remove declaration of statfs.
16209         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
16210
16211         * lib/posixtm.c: Include <stdbool.h> unconditionally.
16212
16213 2003-06-06  Jim Meyering  <jim@meyering.net>
16214
16215         * lib/stdbool_.h: Renamed from stdbool.h.in.
16216
16217 2003-06-06  Jim Meyering  <jim@meyering.net>
16218             Bruno Haible  <bruno@clisp.org>
16219
16220         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
16221         Adjust Makefile.am snippet not to redirect directly to target.
16222         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
16223
16224 2003-06-05  Paul Eggert  <eggert@twinsun.com>
16225
16226         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
16227         mismatch, look in future quarters as well as past.  This fixes a
16228         bug when processing fall-backwards gaps immediately after a long
16229         period of daylight-saving time.
16230
16231         * lib/mktime.c: Assume freestanding C89 or better.
16232         (HAVE_LIMITS_H): Remove.  Assume it's 1.
16233         (__P): Remove; not used.
16234         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
16235         (mktime, not_equal_tm, print_tm, check_result,
16236         main): Use prototypes.  Use const * where appropriate.
16237         (main): Fix typo in testing code that uncovered by above changes.
16238         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
16239
16240 2003-06-04  Paul Eggert  <eggert@twinsun.com>
16241
16242         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
16243         locale.h, localeconv.  This merges changes from coreutils.
16244
16245         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
16246         It can be removed after the next Autoconf is released.
16247         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
16248         needed.
16249
16250 2003-06-04  Paul Eggert  <eggert@twinsun.com>
16251
16252         * lib/mktime.c: Fix Debian bug 177940
16253         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
16254         (localtime_offset): Now long int, not time_t, because we want it
16255         to be guaranteed to be signed.  All uses changed.
16256         (__mktime_internal): If overflow would occur when adding offset,
16257         don't add it.
16258
16259         Merge 'human' changes from coreutils.  Rewrite to support
16260         locale-specific notations like thousands separators.
16261         * lib/human.c: Simplify authorship notice.
16262         Include human.h immediately after config.h.
16263         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
16264         <limits.h>: Do not include, since human.h does.
16265         (SIZE_MAX, UINTMAX_MAX): New macros.
16266         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
16267         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
16268         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
16269         (power_letter): Renamed from suffixes.
16270         (generate_suffix_backwards): Remove.
16271         (adjust_value): Now takes int style (because of human.h changes)
16272         and long double value (for greater precision on some platforms).
16273         (group_number): New function.
16274         (human_readable): Use it.  Use integer options, not enum.
16275         Put the options before the sizes in the arg list.
16276         Support all the new options.
16277         The old human_readable function has been removed;
16278         use inttostr.h instead.
16279         (human_readable, default_block_size, humblock):
16280         Use uintmax_t, not int, for block sizes.
16281         (human_readable_inexact, block_size_types): Remove.
16282         (block_size_opts): New constant.
16283         (human_options): Renamed from human_block_size, with new signature
16284         that allows block sizes up to UINTMAX_MAX.  All callers changed.
16285         * lib/human.h: Add copyright and authorship notice.
16286         Include <limits.h> and <stdbool.h> unconditionally.
16287         (PARAMS): Remove.  All uses removed.
16288         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
16289         (enum human_inexact_style): Remove tag; now a nameless enum.
16290         (human_floor, human_ceiling, human_round_to_even): Now have
16291         values 2, 0, 1 rather than -1, 1, 0.
16292         (human_group_digits, human_suppress_point_zero, human_autoscale,
16293         human_base_1024, human_SI, human_B): New constants.
16294         (human_readable_inexact, human_block_size): Remove.
16295         (human_readable): Size args are now uintmax_t, not int.
16296         (human_options): New decl.
16297
16298         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
16299         unnecessary now that we assume C89 or better.  This change
16300         imported from coreutils.
16301
16302         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
16303         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
16304         in the 2003-05-30 sync from glibc.
16305
16306         .h files should stand alone, but we shouldn't include <sys/types.h>
16307         if we can get away with just <stddef.h>.
16308
16309         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
16310         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
16311         rather than <sys/types.h>, as we merely need size_t.
16312         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
16313         to get size_t.
16314         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
16315         Include <stdio.h>, to get FILE.
16316         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
16317         memcasecmp.h has included <stddef.h> and all we need is size_t.
16318         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
16319         our interface, instead of including <sys/types.h>
16320
16321 2003-06-04  Paul Eggert  <eggert@twinsun.com>
16322
16323         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
16324         now, as glibc mktime is buggy on non-glibc systems.
16325
16326 2003-06-03  Karl Berry  <karl@gnu.org>
16327
16328         * config/config.sub: update from prep.
16329
16330 2003-06-02  Paul Eggert  <eggert@twinsun.com>
16331
16332         [from coreutils]
16333         Fix some minor time-related bugs with POSIX time arguments.
16334         Some valid time stamps were being rejected (notably -1, and
16335         time stamps before 1900 on 64-bit hosts).  And some invalid
16336         time stamps were being accepted, e.g. September 31.
16337
16338         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
16339         that we can return (time_t) -1 successfully.
16340         * lib/posixtm.c: Likewise.
16341         [HAVE_STDBOOL_H]: Include <stdbool.h>.
16342         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
16343         (t): Remove static var.
16344         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
16345         of static var.  All uses changed.
16346         (year): Do not reject years before 1900; they can occur with
16347         64-bit time_t.
16348         (posix_time_parse): Do not check for out-of-range components;
16349         that is now the caller's responsibility, since our checks were
16350         only approximations.
16351         (posixtime): Use mktime to check for out-of-range components,
16352         since it knows them exactly.
16353         If mktime returns (time_t) -1, check whether an error actually occurred
16354         by invoking localtime on -1.
16355         (main) [TEST_POSIXTIME]: Check for input data errors, and report
16356         posixtime failures better.
16357         Improve the test data (in comments only).
16358
16359 2003-06-02  Karl Berry  <karl@gnu.org>
16360
16361         * config/mkinstalldirs (version): new variable.
16362         (--version): new option.
16363         (usage): improve message.
16364
16365 2003-05-30  Karl Berry  <karl@gnu.org>
16366
16367         * lib/mktime.c: update from libc.
16368
16369 2003-05-30  Bruno Haible  <bruno@clisp.org>
16370
16371         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
16372         * config/config.rpath: Upgrade to gettext-0.12.1.
16373
16374 2003-05-30  Bruno Haible  <bruno@clisp.org>
16375
16376         * m4/gettext.m4: Upgrade to gettext-0.12.1.
16377         * m4/nls.m4: New file, from gettext-0.12.1.
16378         * m4/po.m4: New file, from gettext-0.12.1.
16379         * m4/progtest.m4: Upgrade to gettext-0.12.1.
16380
16381 2003-05-30  Bruno Haible  <bruno@clisp.org>
16382
16383         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
16384         * lib/localcharset.h: Likewise.
16385         * lib/localcharset.c: Likewise.
16386
16387 2003-05-29  Karl Berry  <karl@gnu.org>
16388
16389         * config/config.rpath: update from gettext.
16390
16391 2003-05-28  Paul Eggert  <eggert@twinsun.com>
16392
16393         Assume the headers required for C89 freestanding compilers.
16394         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
16395         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
16396         * m4/human.m4 (gl_HUMAN): Likewise.
16397         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
16398         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
16399         * m4/userspec.m4 (gl_USERSPEC): Likewise.
16400         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
16401         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
16402         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
16403
16404 2003-05-28  Paul Eggert  <eggert@twinsun.com>
16405
16406         Assume the headers required for C89 freestanding compilers.
16407         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
16408         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
16409         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
16410         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
16411         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
16412         define, since <limits.h> is guaranteed to do that.
16413         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
16414         * lib/exclude.c: Include <stdbool.h> unconditionally.
16415         * lib/tempname.c: Include <stddef.h> unconditionally.
16416         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
16417         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
16418         <stddef.h> does that.
16419         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
16420         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
16421         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
16422         needed.
16423         * lib/xstrtol.c: Likewise.
16424         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
16425         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
16426
16427         * lib/addext.c (addext): Use assignment rather than cast, to avoid
16428         warnings on some platforms.
16429
16430         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
16431         arbitrarily.
16432
16433 2003-05-26  Jim Meyering  <jim@meyering.net>
16434
16435         Merge in a change from coreutils:
16436         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
16437         that is guaranteed to be `no'.  Use `no_such_member' to indicate
16438         that condition, rather than `-1' which is slightly misleading.
16439         Change the name of the cache variable to have the gl_ prefix.
16440         Prompted by a patch from Richard Dawe for DJGPP.
16441
16442 2003-05-24  Karl Berry  <karl@gnu.org>
16443
16444         * config/config.guess: update from prep.
16445
16446 2003-05-22  Karl Berry  <karl@gnu.org>
16447
16448         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
16449
16450 2003-05-20  Karl Berry  <karl@gnu.org>
16451
16452         * config/config.guess: update from prep.
16453
16454 2003-05-18  Karl Berry  <karl@gnu.org>
16455
16456         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
16457         might actually be set by the user.
16458
16459         * config/depcomp, install-sh, mdate-sh: update from automake.
16460
16461 2003-05-17  Bruno Haible  <bruno@clisp.org>
16462
16463         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
16464         invalid expansion for AC_EGREP_CPP.
16465         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
16466         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
16467         Suggested by Akim Demaille <akim@epita.fr> in
16468         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
16469
16470 2003-05-12  Jim Meyering  <jim@meyering.net>
16471
16472         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
16473         the space-padded-by-default conversion specifiers, %e, %k, %l.
16474
16475 2003-05-12  Bruno Haible  <bruno@clisp.org>
16476
16477         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
16478         the string is longer than 4 KB.
16479
16480 2003-05-11  Karl Berry  <karl@gnu.org>
16481
16482         * config/config.{guess,sub}: update from prep.
16483
16484 2003-05-09  Bruno Haible  <bruno@clisp.org>
16485
16486         * modules/error: Add m4/strerror_r.m4 to file list.
16487
16488 2003-05-03  Bruno Haible  <bruno@clisp.org>
16489
16490         Upgrade to Unicode-4.0.
16491         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
16492         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
16493         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
16494         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
16495         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
16496         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
16497         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
16498         Change width of U+E0100..U+E01EF from 1 to 0.
16499
16500 2003-04-25  Jim Meyering  <jim@meyering.net>
16501
16502         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
16503         of type size_t, not int.
16504
16505 2003-04-25  Bruno Haible  <bruno@clisp.org>
16506
16507         * lib/copy-file.c: Include <stddef.h>, for size_t.
16508
16509 2003-04-21  Paul Eggert  <eggert@twinsun.com>
16510
16511         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
16512         code which expansion is under static control.  Patch imported from
16513         Akim Demaille's patch to Bison; see
16514         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
16515
16516 2003-04-14  Bruno Haible  <bruno@clisp.org>
16517
16518         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
16519
16520 2003-04-11  Jim Meyering  <jim@meyering.net>
16521
16522         Merge changes from Coreutils.
16523
16524         2003-03-22  Jim Meyering  <jim@meyering.net>
16525
16526         * lib/strftime.c (widen): Cast alloca return value to proper type.
16527
16528         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
16529
16530         From GNU libc.
16531         * lib/strftime.c (my_strftime): Handle very large width
16532         specifications for numeric values correctly.  Improve checks for
16533         overflow.
16534
16535         2003-01-19  Jim Meyering  <jim@meyering.net>
16536
16537         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
16538         definitions.
16539         (nl_get_alt_digit) [! defined my_strftime]: Define.
16540         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
16541         _nl_get_alt_digit and _nl_get_walt_digit.
16542
16543         * lib/strftime.c (my_strftime): Merge in locale-related changes from
16544         libc. These changes have no effect outside of _LIBC.
16545
16546 2003-04-10  Bruno Haible  <bruno@clisp.org>
16547
16548         * modules/findprog: New file.
16549         * MODULES.html.sh (func_all_modules): Add it.
16550
16551 2003-04-10  Bruno Haible  <bruno@clisp.org>
16552
16553         * m4/findprog.m4: New file.
16554         * m4/eaccess.m4: New file.
16555
16556 2003-04-10  Bruno Haible  <bruno@clisp.org>
16557
16558         * lib/findprog.h: New file, from GNU gettext.
16559         * lib/findprog.c: New file, from GNU gettext.
16560
16561 2003-04-05  Jim Meyering  <jim@meyering.net>
16562
16563         Merge changes from Coreutils.
16564
16565         * lib/exclude.h (PARAMS): Remove definition and uses.
16566         * lib/exclude.c: Remove uses of `PARAMS'.
16567
16568         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
16569         Add test-cases for DOS filenames. Declare program_name.
16570         (main): Set up program_name.  Patch by Rich Dawe.
16571
16572         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
16573         error from mntctl.
16574         Use mntctl's return value to drive the entry-processing loop, since
16575         we can't rely on the value of the vmt_length member in the last
16576         entry.  On some systems doing so could result in exhausting
16577         virtual memory.  Based in part on a patch from Mike Jetzer.
16578
16579 2003-04-04  Bruno Haible  <bruno@clisp.org>
16580
16581         * modules/linebreak: New file.
16582         * MODULES.html.sh (func_all_modules): Add it.
16583
16584 2003-04-04  Bruno Haible  <bruno@clisp.org>
16585
16586         * m4/linebreak.m4: New file.
16587
16588 2003-04-04  Bruno Haible  <bruno@clisp.org>
16589
16590         * lib/linebreak.h: New file, from GNU gettext.
16591         * lib/linebreak.c: New file, from GNU gettext with slight
16592         modifications.
16593         * lib/lbrkprop.h: New file, from GNU gettext.
16594
16595 2003-04-03  Bruno Haible  <bruno@clisp.org>
16596
16597         * modules/utf8-ucs4: New file.
16598         * modules/utf16-ucs4: New file.
16599         * modules/ucs4-utf8: New file.
16600         * modules/ucs4-utf16: New file.
16601         * MODULES.html.sh (func_all_modules): Add them.
16602
16603 2003-04-03  Bruno Haible  <bruno@clisp.org>
16604
16605         * m4/utf-ucs4.m4: New file.
16606         * m4/ucs4-utf.m4: New file.
16607
16608 2003-04-03  Bruno Haible  <bruno@clisp.org>
16609
16610         * lib/utf8-ucs4.h: New file, from GNU gettext.
16611         * lib/utf16-ucs4.h: New file, from GNU gettext.
16612         * lib/ucs4-utf8.h: New file, from GNU gettext.
16613         * lib/ucs4-utf16.h: New file, from GNU gettext.
16614
16615 2003-04-02  Bruno Haible  <bruno@clisp.org>
16616
16617         * modules/binary-io: New file.
16618         * MODULES.html.sh (func_all_modules): Add it.
16619
16620 2003-04-02  Bruno Haible  <bruno@clisp.org>
16621
16622         * lib/binary-io.h: New file, from GNU gettext.
16623
16624 2003-04-01  Bruno Haible  <bruno@clisp.org>
16625
16626         * modules/pathname: New file.
16627         * MODULES.html.sh (func_all_modules): Add it.
16628
16629 2003-04-01  Bruno Haible  <bruno@clisp.org>
16630
16631         * lib/pathname.h: New file, from GNU gettext.
16632         * lib/concatpath.c: New file, from GNU gettext.
16633
16634 2003-03-30  Bruno Haible  <bruno@clisp.org>
16635
16636         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
16637
16638 2003-03-30  Bruno Haible  <bruno@clisp.org>
16639
16640         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
16641         function chown() doesn't exist.
16642
16643 2003-03-28  Bruno Haible  <bruno@clisp.org>
16644
16645         * modules/copy-file: New file.
16646         * MODULES.html.sh (func_all_modules): Add it.
16647
16648 2003-03-28  Bruno Haible  <bruno@clisp.org>
16649
16650         * m4/copy-file.m4: New file.
16651
16652 2003-03-28  Bruno Haible  <bruno@clisp.org>
16653
16654         * lib/copy-file.h: New file, from GNU gettext.
16655         * lib/copy-file.c: New file, from GNU gettext.
16656
16657 2003-03-18  Jim Meyering  <jim@meyering.net>
16658
16659         * lib/quote.c (quote_n): Fix typo in comment.
16660
16661 2003-03-18  Bruno Haible  <bruno@clisp.org>
16662
16663         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
16664         checking.
16665         * m4/onceonly_2_57.m4: Likewise.
16666
16667 2003-03-17  Bruno Haible  <bruno@clisp.org>
16668
16669         * m4/onceonly.m4: Require autoconf 2.54 or newer.
16670         (m4_quote): Remove macro.
16671         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
16672
16673 2003-03-14  Jim Meyering  <jim@meyering.net>
16674
16675         Merge changes from Coreutils.
16676         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
16677         to be const, in order to avoid warnings.
16678         (obstack_room): Likewise.
16679         (obstack_empty_p): Likewise.
16680
16681 2003-03-14  Bruno Haible  <bruno@clisp.org>
16682
16683         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
16684         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
16685
16686 2003-03-13  Paul Eggert  <eggert@twinsun.com>
16687
16688         Merge changes from Bison.
16689         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
16690         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
16691         when compiling Bison 1.875's `bitset bset = obstack_alloc
16692         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
16693         * lib/hash.c: Include <stdbool.h> unconditionally.
16694
16695 2003-03-13  Paul Eggert  <eggert@twinsun.com>
16696
16697         * m4/onceonly.m4 (m4_quote): New macro.
16698         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
16699         Quote AC_FOREACH variable-expansions properly.
16700
16701 2003-03-13  Paul Eggert  <eggert@twinsun.com>
16702
16703         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
16704
16705 2003-03-09  Paul Eggert  <eggert@twinsun.com>
16706
16707         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
16708         Reported by Bruce Becker; see:
16709         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
16710
16711 2003-03-03  Paul Eggert  <eggert@twinsun.com>
16712             Bruno Haible  <bruno@clisp.org>
16713
16714         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
16715         Reported by John Hughes, see
16716         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
16717
16718 2003-02-20  Bruno Haible  <bruno@clisp.org>
16719
16720         * MODULES.html.sh (func_all_modules): Add poll.
16721
16722 2003-02-19  Paolo Bonzino  <bonzini@gnu.org>
16723
16724         * modules/poll: New file.
16725
16726 2003-02-19  Paolo Bonzino  <bonzini@gnu.org>
16727
16728         * lib/poll_.h: New file.
16729         * lib/poll.c: New file.
16730
16731 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
16732
16733         * m4/poll.m4: New file.
16734
16735 2003-02-18  Paolo Bonzino  <bonzini@gnu.org>
16736
16737         * modules/mathl: New file.
16738
16739 2003-02-18  Paolo Bonzino  <bonzini@gnu.org>
16740
16741         * lib/mathl.h: New file.
16742         * lib/acosl.c: New file.
16743         * lib/asinl.c: New file.
16744         * lib/atanl.c: New file.
16745         * lib/ceill.c: New file.
16746         * lib/cosl.c: New file.
16747         * lib/expl.c: New file.
16748         * lib/floorl.c: New file.
16749         * lib/frexpl.c: New file.
16750         * lib/ldexpl.c: New file.
16751         * lib/logl.c: New file.
16752         * lib/sincosl.c: New file.
16753         * lib/sinl.c: New file.
16754         * lib/sqrtl.c: New file.
16755         * lib/tanl.c: New file.
16756         * lib/trigl.c: New file.
16757         * lib/trigl.h: New file.
16758
16759 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
16760
16761         * m4/mathl.m4: New file.
16762
16763 2003-02-18  Bruno Haible  <bruno@clisp.org>
16764
16765         * MODULES.html.sh (func_all_modules): Add mathl.
16766
16767 2003-02-17  Bruno Haible  <bruno@clisp.org>
16768
16769         * modules/mkdtemp: New module.
16770         * MODULES.html.sh (func_all_modules): Add it.
16771
16772 2003-02-17  Bruno Haible  <bruno@clisp.org>
16773
16774         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
16775
16776 2003-02-17  Bruno Haible  <bruno@clisp.org>
16777
16778         * lib/mkdtemp.h: New file, from GNU gettext.
16779         * lib/mkdtemp.c: New file, from GNU gettext.
16780
16781 2003-02-02  Jim Meyering  <jim@meyering.net>
16782
16783         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
16784         e.g. glibc-2.2.93.
16785
16786 2003-01-31  Bruno Haible  <bruno@clisp.org>
16787
16788         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
16789         'rpl_rename'.
16790         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
16791         'rpl_strnlen'.
16792         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
16793         'rpl_strtod'.
16794         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
16795         'rpl_utime'.
16796
16797 2003-01-31  Bruno Haible  <bruno@clisp.org>
16798
16799         * lib/rename.c: #undef rename before defining rpl_rename.
16800         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
16801
16802 2003-01-30  Bruno Haible  <bruno@clisp.org>
16803
16804         * modules/vasnprintf, modules/vasprintf: New modules.
16805         * MODULES.html.sh (func_all_modules): Add them.
16806
16807 2003-01-30  Bruno Haible  <bruno@clisp.org>
16808
16809         * m4/signed.m4: New file, from GNU gettext.
16810         * m4/longdouble.m4: New file, from GNU gettext.
16811         * m4/wchar_t.m4: New file, from GNU gettext.
16812         * m4/wint_t.m4: New file, from GNU gettext.
16813         * m4/vasnprintf.m4: New file.
16814         * m4/vasprintf.m4: New file.
16815
16816 2003-01-30  Bruno Haible  <bruno@clisp.org>
16817
16818         * lib/printf-args.h: New file, from GNU gettext.
16819         * lib/printf-args.c: New file, from GNU gettext.
16820         * lib/printf-parse.h: New file, from GNU gettext.
16821         * lib/printf-parse.c: New file, from GNU gettext.
16822         * lib/vasnprintf.h: New file, from GNU gettext.
16823         * lib/vasnprintf.c: New file, from GNU gettext.
16824         * lib/asnprintf.c: New file, from GNU gettext.
16825         * lib/vasprintf.h: New file, from GNU gettext with modifications.
16826         * lib/vasprintf.c: New file, from GNU gettext.
16827         * lib/asprintf.c: New file, from GNU gettext.
16828
16829 2003-01-29  Bruno Haible  <bruno@clisp.org>
16830
16831         * modules/stpncpy: New module.
16832         * MODULES.html.sh (func_all_modules): Add it.
16833
16834 2003-01-29  Bruno Haible  <bruno@clisp.org>
16835
16836         * m4/stpncpy.m4: New file.
16837
16838 2003-01-29  Bruno Haible  <bruno@clisp.org>
16839
16840         * lib/stpncpy.h: New file, from GNU gettext with modifications.
16841         * lib/stpncpy.c: New file, from GNU gettext with modifications.
16842
16843 2003-01-28  Bruno Haible  <bruno@clisp.org>
16844
16845         * modules/c-ctype: New module.
16846         * MODULES.html.sh (func_all_modules): Add it.
16847
16848 2003-01-28  Bruno Haible  <bruno@clisp.org>
16849
16850         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
16851         Paul Eggert.
16852         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
16853         Paul Eggert.
16854
16855 2003-01-27  Bruno Haible  <bruno@clisp.org>
16856
16857         * modules/xsetenv: New module.
16858         * MODULES.html.sh (func_all_modules): Add it.
16859
16860 2003-01-27  Bruno Haible  <bruno@clisp.org>
16861
16862         * lib/xsetenv.h: New file, from GNU gettext.
16863         * lib/xsetenv.c: New file, from GNU gettext.
16864
16865 2003-01-23  Jim Meyering  <jim@meyering.net>
16866
16867         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
16868         from working on systems without dirfd (at least Irix and OSF1/Tru64).
16869
16870 2003-01-23  Bruno Haible  <bruno@clisp.org>
16871
16872         * modules/minmax: New module.
16873         * MODULES.html.sh (func_all_modules): Add it.
16874
16875 2003-01-23  Bruno Haible  <bruno@clisp.org>
16876
16877         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
16878         Eggert.
16879
16880 2003-01-22  Bruno Haible  <bruno@clisp.org>
16881
16882         * modules/exit: New module.
16883         * MODULES.html.sh (func_all_modules): Add it.
16884
16885 2003-01-22  Bruno Haible  <bruno@clisp.org>
16886
16887         * lib/exit.h: New file, from GNU gettext.
16888
16889 2003-01-19  Bruno Haible  <bruno@clisp.org>
16890
16891         * gnulib-tool: Recognize option --extract-maintainer.
16892         (func_get_maintainer): New function.
16893         * modules/*: Add Maintainer entry.
16894
16895 2003-01-16  Jim Meyering  <jim@meyering.net>
16896
16897         * m4/regex.m4: The `regex' struct is both input and output.
16898         Initialize it before each use.  Patch by Tim Waugh.
16899
16900 2003-01-16  Bruno Haible  <bruno@clisp.org>
16901
16902         * MODULES.html.sh: Add a table of contents. Add the module name as
16903         leftmost column. Add hyperlinks.
16904
16905 2003-01-15  Bruno Haible  <bruno@clisp.org>
16906
16907         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
16908
16909 2003-01-15  Bruno Haible  <bruno@clisp.org>
16910
16911         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
16912         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
16913         suffix.
16914
16915 2003-01-15  Bruno Haible  <bruno@clisp.org>
16916
16917         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
16918
16919 2003-01-15  Bruno Haible  <bruno@clisp.org>
16920
16921         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
16922         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
16923
16924 2003-01-14  Jim Meyering  <jim@meyering.net>
16925
16926         * lib/same.c (same_name): Tweak a comment.
16927
16928 2003-01-14  Bruno Haible  <bruno@clisp.org>
16929
16930         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
16931         when a string comparison is sufficient.
16932
16933 2003-01-14  Bruno Haible  <bruno@clisp.org>
16934
16935         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
16936         'unsigned int'.
16937
16938 2003-01-14  Bruno Haible  <bruno@clisp.org>
16939
16940         * lib/hash-pjw.c: Add comment about low quality of this function.
16941
16942 2003-01-13  Bruno Haible  <bruno@clisp.org>
16943
16944         * modules/stpcpy: Distribute lib/stpcpy.h.
16945         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
16946
16947 2003-01-13  Bruno Haible  <bruno@clisp.org>
16948
16949         * modules/*: Add a description.
16950         * modules/strpbrk: Fix Makefile.am snippet.
16951         * modules/strtoimax: Fix dependencies.
16952         * modules/strtoumax: Likewise.
16953
16954 2003-01-13  Bruno Haible  <bruno@clisp.org>
16955
16956         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
16957         * modules/alloca (Makefile.am): All object files depend on alloca.h.
16958         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
16959
16960 2003-01-13  Bruno Haible  <bruno@clisp.org>
16961
16962         * gnulib-tool (func_create_testdir): Store config/* files in the main
16963         directory.
16964         * config.rpath: Move to ...
16965         * config/config.rpath: ... here.
16966         * modules/gettext: Contains config/config.rpath, not config.rpath.
16967         * modules/iconv: Likewise.
16968
16969 2003-01-12  Paul Eggert  <eggert@twinsun.com>
16970
16971         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
16972         to avoid collisions with libcurses and libreadline.
16973
16974         * m4/getstr.m4: Remove.
16975         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
16976
16977 2003-01-12  Paul Eggert  <eggert@twinsun.com>
16978
16979         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
16980         to avoid collisions with libcurses and libreadline.
16981
16982         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
16983         * lib/getstr.h, getstr.c: Remove.
16984         * lib/getline.c: Include "getline.h", to check interface.
16985         Move body of old getstr.c here: this defines MIN_CHUNK and
16986         declares getdelim2, which is renamed from getstr.
16987         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
16988
16989         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
16990         All uses changed.
16991         * lib/linebuffer.h: Likewise.
16992         (readline): Remove backward-compatibility macro.
16993
16994 2003-01-12  Paul Eggert  <eggert@twinsun.com>
16995
16996         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
16997         to avoid collisions with libcurses and libreadline.
16998         * getstr: Remove.
16999         * MODULES.html.sh: Remove getstr.
17000         * modules/getline: Depend on unlocked-io, not getstr.
17001
17002 2003-01-12  Jim Meyering  <jim@meyering.net>
17003
17004         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
17005
17006 2003-01-10  Bruno Haible  <bruno@clisp.org>
17007
17008         * modules/alloca: Change Makefile.am requirements. Simplify Include
17009         requirements. Add lib/alloca_.h to file list.
17010
17011 2003-01-10  Bruno Haible  <bruno@clisp.org>
17012
17013         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
17014
17015 2003-01-10  Bruno Haible  <bruno@clisp.org>
17016
17017         * lib/alloca_.h: New file.
17018         * lib/getdate.y: Unconditionally include alloca.h.
17019         * lib/makepath.c: Likewise.
17020         * lib/setenv.c: Likewise.
17021         * lib/userspec.c: Likewise.
17022
17023 2003-01-09  Karl Berry  <karl@gnu.org>
17024
17025         * MODULES.html.sh: include `dirname $0` in PATH, to find
17026         gnulib-tool.
17027
17028 2003-01-09  Bruno Haible  <bruno@clisp.org>
17029
17030         * modules/stdbool: Change configure.ac, Makefile.am requirements.
17031         Simplify Include requirements. Add lib/stdbool.h.in to file list.
17032
17033 2003-01-09  Bruno Haible  <bruno@clisp.org>
17034
17035         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
17036
17037 2003-01-09  Bruno Haible  <bruno@clisp.org>
17038
17039         * lib/stdbool.h.in: New file.
17040
17041 2003-01-09  Bruno Haible  <bruno@clisp.org>
17042
17043         * gnulib-tool (func_all_modules): Ignore files ending in ~.
17044         * MODULES.html.sh: Likewise.
17045
17046 2003-01-08  Jim Meyering  <jim@meyering.net>
17047
17048         * lib/full-write.c: Undefine and define-away `const' after inclusion
17049         of errno.h, not before.  Suggestion from Bruno Haible.
17050
17051 2003-01-08  Bruno Haible  <bruno@clisp.org>
17052
17053         * modules/full-read: Depend on full-write.
17054
17055 2003-01-08  Bruno Haible  <bruno@clisp.org>
17056
17057         * lib/safe-read.c: Include specification header first, to ensure its
17058         selfcontainedness.
17059         * lib/full-write.c: Likewise.
17060
17061 2003-01-07  Jim Meyering  <jim@meyering.net>
17062
17063         * lib/full-write.c: Rework so that it may serve to define full_read,
17064         too.
17065         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
17066
17067 2003-01-07  Bruno Haible  <bruno@clisp.org>
17068
17069         * lib/strtoimax.c: Include <stdint.h> as an alternative to
17070         <inttypes.h>.
17071         * lib/xstrtol.h: Likewise.
17072         * lib/xstrtoimax.c: Likewise.
17073         * lib/xstrtoumax.c: Likewise.
17074         * lib/human.h: Likewise.
17075
17076         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
17077         on systems that have <inttypes.h> but not <stdint.h>.
17078
17079 2003-01-07  Bruno Haible  <bruno@clisp.org>
17080
17081         * MODULES.html.sh: Add copyright notice.
17082         (missed_files): Omit CVS directory entries.
17083         (func_module): Make it work with sed-3.02.
17084         * MODULES.txt: Remove file.
17085
17086 2003-01-06  Jim Meyering  <jim@meyering.net>
17087
17088         * lib/version-etc.c: Update year in translatable copyright string.
17089
17090 2003-01-03  Karl Berry  <karl@gnu.org>
17091
17092         * config/config.{guess,sub}: update from prep.
17093
17094 2003-01-02  Karl Berry  <karl@gnu.org>
17095
17096         * doc/COPYING.DOC: belatedly updated to 1.2.
17097
17098 2003-01-01  Karl Berry  <karl@gnu.org>
17099
17100         * gnulib-tool (func_verify_module): report module name $module in
17101         error message, not $1.
17102         * gnulib-tool (create-testdir): don't complain if destdir couldn't
17103         be created, only if it doesn't exist.
17104         * gnulib-tool (last_checkin_date): don't expand the $Date here.
17105
17106 2002-12-31  Paul Eggert  <eggert@twinsun.com>
17107
17108         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
17109
17110 2002-12-31  Paul Eggert  <eggert@twinsun.com>
17111
17112         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
17113         memcmp if strcoll doesn't work.
17114
17115 2002-12-31  Bruno Haible  <bruno@clisp.org>
17116
17117         * lib/utime.c (utime_null): No need to call ftruncate if the file was
17118         nonempty.
17119
17120 2002-12-31  Bruno Haible  <bruno@clisp.org>
17121
17122         * lib/memcoll.c (STRCOLL): New macro.
17123         (memcoll): Use it.
17124
17125 2002-12-31  Bruno Haible  <bruno@clisp.org>
17126
17127         * lib/localcharset.h: New file.
17128         * lib/localcharset.c: Include it.
17129         * lib/unicodeio.c: Likewise.
17130
17131 2002-12-31  Bruno Haible  <bruno@clisp.org>
17132
17133         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
17134         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
17135
17136 2002-12-31  Bruno Haible  <bruno@clisp.org>
17137
17138         * lib/getline.h: Include <stddef.h>, for size_t.
17139
17140         * lib/unicodeio.h: Include <stddef.h>, for size_t.
17141         * lib/unicodeio.c: Don't include <stddef.h>.
17142
17143 2002-12-31  Bruno Haible  <bruno@clisp.org>
17144
17145         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
17146         HAVE_TM_ZONE.
17147
17148 2002-12-24  Karl Berry  <karl@gnu.org>
17149
17150         * config/config.guess: update from prep.
17151
17152 2002-12-24  Bruno Haible  <bruno@clisp.org>
17153
17154         General infrasructure.
17155         * m4/README: Rewritten.
17156         * m4/onceonly.m4: New file.
17157         * m4/onceonly_2_57.m4: New file.
17158
17159         Module atexit.
17160         * m4/atexit.m4: New file.
17161
17162         Module strtod.
17163         * m4/strtod.m4: New file.
17164
17165         Module strtol.
17166         * m4/strtol.m4: New file.
17167
17168         Module strtoul.
17169         * m4/strtoul.m4: New file.
17170
17171         Module memchr.
17172         * m4/memchr.m4: New file.
17173
17174         Module memcmp.
17175         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
17176         (jm_FUNC_MEMCMP): Invoke it.
17177
17178         Module memcpy.
17179         * m4/memcpy.m4: New file.
17180
17181         Module memmove.
17182         * m4/memmove.m4: New file.
17183
17184         Module memset.
17185         * m4/memset.m4: New file.
17186
17187         Module strcspn.
17188         * m4/strcspn.m4: New file.
17189
17190         Module strpbrk.
17191         * m4/strpbrk.m4: New file.
17192
17193         Module strstr.
17194         * m4/strstr.m4: New file.
17195
17196         Module strerror.
17197         * m4/strerror.m4: New file.
17198
17199         Module mktime.
17200         * m4/mktime.m4: Renamed from jm-mktime.m4.
17201         (gl_PREREQ_MKTIME): New macro.
17202         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
17203
17204         Module malloc.
17205         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
17206         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
17207         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
17208
17209         Module realloc.
17210         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
17211         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
17212         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
17213
17214         Module strftime.
17215         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
17216         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
17217         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
17218         gl_TM_GMTOFF.
17219         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
17220
17221         Module xalloc.
17222         * m4/xalloc.m4: New file.
17223
17224         Module alloca.
17225         * m4/alloca.m4: New file.
17226
17227         Module putenv.
17228         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
17229         (jm_FUNC_PUTENV): Invoke it.
17230
17231         Module setenv.
17232         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
17233         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
17234         when invoked twice.
17235         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
17236         gt_FUNC_SETENV.
17237
17238         Module memrchr.
17239         * m4/memrchr.m4: New file.
17240
17241         Module stpcpy.
17242         * m4/stpcpy.m4: New file.
17243
17244         Module strcase.
17245         * m4/strcase.m4: New file.
17246
17247         Module strdup.
17248         * m4/strdup.m4: New file.
17249
17250         Module strnlen.
17251         * m4/strnlen.m4: New file.
17252
17253         Module strndup.
17254         * m4/strndup.m4: New file.
17255
17256         Module xstrtod.
17257         * m4/xstrtod.m4: New file.
17258
17259         Module xstrtol.
17260         * m4/xstrtol.m4: New file.
17261
17262         Module getdate.
17263         * m4/getdate.m4: New file.
17264
17265         Module unlocked-io.
17266         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
17267         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
17268         * m4/jm-glibc-io.m4n: Remove file.
17269
17270         Module long-options.
17271         * m4/long-options.m4: New file.
17272
17273         Module md5.
17274         * m4/md5.m4: New file.
17275
17276         Module sha.
17277         * m4/sha.m4: New file.
17278
17279         Module getstr.
17280         * m4/getstr.m4: New file.
17281
17282         Module getline.
17283         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
17284         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
17285         <sys/types.h>, for size_t. Use the function name gnu_getline, not
17286         simply getline. Infoke gl_PREREQ_GETLINE.
17287
17288         Module obstack.
17289         * m4/obstack.m4: New file.
17290
17291         Module hash.
17292         * m4/hash.m4: New file.
17293
17294         Module readtokens.
17295         * m4/readtokens.m4: New file.
17296
17297         Module strverscmp.
17298         * m4/strverscmp.m4: New file.
17299
17300         Module stdbool.
17301         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
17302         OSF/1.
17303
17304         Module strtoll.
17305         * m4/strtoll.m4: New file.
17306
17307         Module strtoull.
17308         * m4/strtoull.m4: New file.
17309
17310         Module strtoimax.
17311         * m4/strtoimax.m4: New file.
17312
17313         Module strtoumax.
17314         * m4/strtoumax.m4: New file.
17315
17316         Module xstrtoimax.
17317         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
17318         jm_AC_PREREQ_XSTRTOIMAX.
17319         Moved the strtol prerequisites to strtol.m4.
17320         Moved the strtoll prerequisites to strtoll.m4.
17321         Moved the strtoimax prerequisites to strtoimax.m4.
17322
17323         Module xstrtoumax.
17324         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
17325         jm_AC_PREREQ_XSTRTOUMAX.
17326         Moved the strtoul prerequisites to strtoul.m4.
17327         Moved the strtoull prerequisites to strtoull.m4.
17328         Moved the strtoumax prerequisites to strtoumax.m4.
17329
17330         Module chown.
17331         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
17332         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
17333
17334         Module dup2.
17335         * m4/dup2.m4: New file.
17336
17337         Module ftruncate.
17338         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
17339         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
17340
17341         Module getgroups.
17342         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
17343         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
17344
17345         Module gettimeofday.
17346         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
17347         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
17348         gl_PREREQ_GETTIMEOFDAY.
17349
17350         Module mkdir.
17351         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
17352         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
17353
17354         Module mkstemp.
17355         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
17356         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
17357         jm_AC_TYPE_UINTMAX_T.
17358         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
17359
17360         Module stat.
17361         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
17362         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
17363
17364         Module lstat.
17365         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
17366         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
17367
17368         Module timespec.
17369         * m4/timespec.m4 (gl_TIMESPEC): New macro.
17370         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
17371         * m4/st_mtim.m4: Indentation.
17372
17373         Module nanosleep.
17374         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
17375         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
17376         gl_PREREQ_NANOSLEEP.
17377
17378         Module regex.
17379         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
17380         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
17381         (gl_REGEX): New macro.
17382
17383         Module rename.
17384         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
17385         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
17386
17387         Module rmdir.
17388         * m4/rmdir.m4: New file.
17389
17390         Module utime.
17391         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
17392         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
17393         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
17394
17395         Module dirname.
17396         * m4/dirname.m4: New file.
17397
17398         Module getopt.
17399         * m4/getopt.m4: New file.
17400
17401         Module unistd-safer.
17402         * m4/unistd-safer.m4: New file.
17403
17404         Module fnmatch.
17405         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
17406         declaration.
17407         (gl_PREREQ_FNMATCH_EXTRA): New macro.
17408         (gl_FUNC_FNMATCH_POSIX): New macro.
17409         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
17410         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
17411         simply fnmatch.
17412
17413         Module exclude.
17414         * m4/exclude.m4: New file.
17415
17416         Module human.
17417         * m4/human.m4: New file.
17418
17419         Module acl.
17420         * m4/acl.m4: Nop.
17421
17422         Module backupfile.
17423         * m4/backupfile.m4: New file.
17424         * m4/d-ino.m4: Indentation.
17425
17426         Module fsusage.
17427         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
17428         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
17429         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
17430
17431         Module dirfd.
17432         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
17433         requirements.
17434
17435         Module euidaccess.
17436         * m4/euidaccess.m4: New file.
17437
17438         Module file-type.
17439         * m4/file-type.m4: New file.
17440
17441         Module fileblocks.
17442         * m4/fileblocks.m4: New file.
17443
17444         Module filemode.
17445         * m4/filemode.m4: New file.
17446
17447         Module isdir.
17448         * m4/isdir.m4: New file.
17449
17450         Module lchown.
17451         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
17452         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
17453
17454         Module makepath.
17455         * m4/makepath.m4: New file.
17456
17457         Module modechange.
17458         * m4/modechange.m4: New file.
17459
17460         Module mountlist.
17461         * m4/mountlist.m4: New file.
17462         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
17463         Indentation.
17464
17465         Module path-concat.
17466         * m4/path-concat.m4: New file.
17467
17468         Module pathmax.
17469         * m4/pathmax.m4: New file.
17470
17471         Module same.
17472         * m4/same.m4: New file.
17473
17474         Module save-cwd.
17475         * m4/save-cwd.m4: New file.
17476
17477         Module savedir.
17478         * m4/savedir.m4: New file.
17479
17480         Module xgetcwd.
17481         * m4/xgetcwd.m4: New file.
17482         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
17483
17484         Module xreadlink.
17485         * m4/xreadlink.m4: New file.
17486
17487         Module safe-read.
17488         * m4/safe-read.m4: New file.
17489
17490         Module safe-write.
17491         * m4/safe-write.m4: New file.
17492
17493         Module closeout.
17494         * m4/closeout.m4: New file.
17495
17496         Module stdio-safer.
17497         * m4/stdio-safer.m4: New file.
17498
17499         Module getpass.
17500         * m4/getpass.m4: New file.
17501
17502         Module getugroups.
17503         * m4/getugroups.m4: New file.
17504
17505         Module group-member.
17506         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
17507         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
17508
17509         Module idcache.
17510         * m4/idcache.m4: New file.
17511
17512         Module userspec.
17513         * m4/userspec.m4: New file.
17514
17515         Module gettime.
17516         * m4/clock_time.m4: New file.
17517         * m4/gettime.m4: New file.
17518
17519         Module settime.
17520         * m4/settime.m4: New file.
17521
17522         Module posixtm.
17523         * m4/posixtm.m4: New file.
17524
17525         Module gethostname.
17526         * m4/gethostname.m4: New file.
17527
17528         Module canon-host.
17529         * m4/canon-host.m4: New file.
17530
17531         Module gettext.
17532         * m4/codeset.m4: New file, from gettext-0.11.5.
17533         * m4/gettext.m4: New file, from gettext-0.11.5.
17534         * m4/glibc21.m4: New file, from gettext-0.11.5.
17535         * m4/iconv.m4: New file, from gettext-0.11.5.
17536         * m4/intdiv0.m4: New file, from gettext-0.11.5.
17537         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
17538         * m4/inttypes.m4: New file, from gettext-0.11.5.
17539         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
17540         * m4/isc-posix.m4: New file, from gettext-0.11.5.
17541         * m4/lcmessage.m4: New file, from gettext-0.11.5.
17542         * m4/lib-ld.m4: New file, from gettext-0.11.5.
17543         * m4/lib-link.m4: New file, from gettext-0.11.5.
17544         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
17545         * m4/progtest.m4: New file, from gettext-0.11.5.
17546         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
17547         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
17548         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
17549
17550         Module localcharset.
17551         * m4/localcharset.m4: New file.
17552
17553         Module hard-locale.
17554         * m4/hard-locale.m4: New file.
17555
17556         Module mbswidth.
17557         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
17558         onceonly macros.
17559         * m4/mbrtowc.m4: Add comment.
17560
17561         Module memcasecmp.
17562         * m4/memcasecmp.m4: New file.
17563
17564         Module memcoll.
17565         * m4/memcoll.m4: New file.
17566
17567         Module unicodeio.
17568         * m4/unicodeio.m4: New file.
17569
17570         Module rpmatch.
17571         * m4/rpmatch.m4: New file.
17572
17573         Module yesno.
17574         * m4/yesno.m4: New file.
17575
17576         Module exitfail.
17577         * m4/exitfail.m4: New file.
17578
17579         Module c-stack.
17580         * m4/c-stack.m4 (gl_C_STACK): New macro.
17581         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
17582
17583         Module error.
17584         * m4/error.m4 (gl_ERROR): New macro.
17585         (jm_PREREQ_ERROR): Use onceonly macros.
17586
17587         Module fatal.
17588         * m4/fatal.m4: New file.
17589
17590         Module getloadavg.
17591         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
17592         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
17593
17594         Module getpagesize.
17595         * m4/getpagesize.m4: New file.
17596
17597         Module getusershell.
17598         * m4/getusershell.m4: New file.
17599
17600         Module physmem.
17601         * m4/physmem.m4: New file.
17602
17603         Module posixver.
17604         * m4/posixver.m4: New file.
17605
17606         Module quotearg.
17607         * m4/quotearg.m4: New file.
17608
17609         Module quote.
17610         * m4/quote.m4: New file.
17611
17612         Module readutmp.
17613         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
17614
17615         Module sig2str.
17616         * m4/sig2str.m4: New file.
17617
17618         Other.
17619         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
17620         ulonglong.m4.
17621         * m4/intmax_t.m4: New file.
17622         * m4/d-type.m4: Indentation.
17623         * m4/jm-macros.m4: Update.
17624         * m4/prereq.m4 (jm_PREREQ): Update.
17625         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
17626         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
17627         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
17628         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
17629         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
17630         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
17631         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
17632         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
17633         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
17634         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
17635         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
17636         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
17637         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
17638         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
17639         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
17640         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
17641         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
17642         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
17643         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
17644
17645 2002-12-24  Bruno Haible  <bruno@clisp.org>
17646
17647         * MODULES.txt: Update according to m4/ changes.
17648
17649         Module gettext.
17650         * config.rpath: New file, from gettext-0.11.5.
17651
17652         * modules/*: New module descriptions.
17653         * gnulib-tool: New file.
17654         * MODULES.html.sh: New file.
17655
17656 2002-12-21  Karl Berry  <karl@gnu.org>
17657
17658         * doc/fdl.texi: update to version 1.2.
17659
17660 2002-12-19  Karl Berry  <karl@gnu.org>
17661
17662         * config/config.guess: update from prep.
17663
17664 2002-12-18  Bruno Haible  <bruno@clisp.org>
17665
17666         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
17667         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
17668
17669 2002-12-17  Bruno Haible  <bruno@clisp.org>
17670
17671         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
17672         stdlib.h, string.h.
17673
17674 2002-12-17  Bruno Haible  <bruno@clisp.org>
17675
17676         * lib/canon-host.c (strdup): Remove unused declaration.
17677
17678         * lib/fsusage.c: Include full_read.h.
17679         (get_fs_usage): Use full_read instead of safe_read.
17680
17681         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
17682
17683 2002-12-12  Karl Berry  <karl@gnu.org>
17684
17685         * config/config.guess: update from prep.
17686
17687 2002-12-11  Bruno Haible  <bruno@clisp.org>
17688
17689         * m4/setenv.m4: New file, from gettext-0.11.5.
17690
17691 2002-12-11  Bruno Haible  <bruno@clisp.org>
17692
17693         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
17694         not unsetenv().
17695         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
17696         modifications:
17697
17698         2002-12-11  Bruno Haible  <bruno@clisp.org>
17699
17700                 * setenv.c (alloca): Fall back to malloc.
17701                 (freea): New macro.
17702                 (setenv): Use freea() to free memory allocated with alloca().
17703
17704         2002-11-13  Bruno Haible  <bruno@clisp.org>
17705
17706                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
17707                 function declarations.
17708                 * unsetenv.c (unsetenv): Likewise.
17709
17710         2002-03-04  Bruno Haible  <bruno@clisp.org>
17711
17712                 Portability to AIX 4.3.3.
17713                 * unsetenv.c: New file, extracted from setenv.c.
17714                 * setenv.c: Move the unsetenv() function to unsetenv.c.
17715
17716         2001-12-20  Bruno Haible  <bruno@clisp.org>
17717
17718                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
17719                 use malloc instead. For SunOS 4.
17720
17721         2001-12-11  Bruno Haible  <bruno@clisp.org>
17722
17723                 * setenv.c: Declare alloca.
17724                 (compar_fn_t): New typedef.
17725                 (KNOWN_VALUE, STORE_VALUE): Use it.
17726
17727         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
17728         setenv.h.
17729
17730 2002-12-10  Paul Eggert  <eggert@twinsun.com>
17731
17732         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
17733         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
17734         Choose values that are less likely to collide with system fnmatch
17735         options.
17736         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
17737         defined (e.g., a pure POSIX system).
17738         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
17739         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
17740
17741 2002-12-06  Paul Eggert  <eggert@twinsun.com>
17742
17743         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
17744         a pain in practice to deal with generated m4 files.  This change
17745         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
17746
17747         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
17748         and jm-glibc-io.m4, as they are no longer a special case.
17749         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
17750         kludge and the auto-generation stuff.  Check only whether the
17751         functions are declared, not whether they exist, since older hosts
17752         that don't declare the functions can't use the optimization anyway.
17753
17754 2002-12-06  Jim Meyering  <jim@meyering.net>
17755
17756         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
17757
17758         Merge in changes from libc's misc/error.c, in preparation
17759         for the merge of gnulib's changes back into libc.
17760
17761         * lib/error.c (_): Define only if not already defined.
17762         Move definition to follow all #include directives.
17763         Include unlocked-io.h only if !_LIBC.
17764         [_LIBC]: Include <libio/libioP.h>.
17765         [USE_IN_LIBIO]: Include <libio/iolibio.h>
17766         (fflush): Tweak definition to use INTUSE.
17767         (putc): Define.
17768
17769 2002-12-05  Paul Eggert  <eggert@twinsun.com>
17770
17771         * lib/alloca.c [defined emacs]: Include "lisp.h".
17772         (xalloc_die) [defined emacs]: New macro.
17773         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
17774         [! defined emacs]: Include <xalloc.h>.
17775         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
17776         (pointer): Typedef to POINTER_TYPE *.
17777         (malloc): Remove decl; we now always use xmalloc.
17778         (alloca): Use old-style definition, since Emacs needs this.
17779         Check for arithmetic overflow when computing combined size.
17780
17781 2002-12-04  Paul Eggert  <eggert@twinsun.com>
17782
17783         Do not generate unlocked-io.h automatically, since it's easier to
17784         maintain it by hand.
17785
17786         * lib/unlocked-io.h: New file, from GNU diffutils,
17787         but with proper copyright notice and attribution.
17788         * lib/gen-uio: Remove.
17789         * lib/Makefile.am: Add copyright notice.
17790         (libfetish_a_SOURCES): Add unlocked-io.h.
17791         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
17792         (DISTCLEANFILES, io_functions): Remove macros.
17793         (EXTRA_DIST): Remove gen_uio.
17794         (unlocked-io.h): Remove rule.
17795
17796 2002-12-04  Jim Meyering  <jim@meyering.net>
17797
17798         Reflect the fact that stat.c and lstat.c are no longer generated.
17799         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
17800         (DISTCLEANFILES): Likewise.
17801         (EXTRA_DIST): Likewise.
17802         (all_local): Don't depend on stat.c or lstat.c.
17803         (stat.c, lstat.c): Remove rules.
17804         (EXTRA_DIST): Remove xstat.in.
17805
17806         * lib/xstat.in: Remove file.  Contents moved into stat.c.
17807         * lib/stat.c: New file.  Contents mostly from xstat.in.
17808         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
17809         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
17810
17811         * lib/safe-read.c: Rework so that it may serve to define safe_write,
17812         too.
17813         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
17814
17815 2002-12-03  Jim Meyering  <jim@meyering.net>
17816
17817         * lib/safe-read.c, safe-write.c: Change variable names and comments,
17818         but not semantics, to minimize the differences between these two files.
17819         (safe_read): Change comment to mention SAFE_READ_ERROR.
17820
17821         * lib/safe-read.c (IS_EINTR): Define.
17822         (safe_read): Use IS_EINTR in place of in-function cpp directives.
17823
17824 2002-12-02  Jim Meyering  <jim@meyering.net>
17825
17826         * lib/safe-read.c (EINTR): Define.
17827         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
17828         (INT_MAX): Provide fallback.
17829         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
17830
17831         * lib/safe-read.h (SAFE_READ_ERROR): Define.
17832
17833 2002-12-02  Bruno Haible  <bruno@clisp.org>
17834
17835         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
17836         Define, taken from safe-read.c.
17837         (INT_MAX): Provide fallback.
17838         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
17839         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
17840
17841         * lib/safe-read.c (EINTR): Remove definition.
17842         (safe_read): Don't use EINTR if it is absent.
17843
17844 2002-12-01  Jim Meyering  <jim@meyering.net>
17845
17846         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
17847         zero.
17848         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
17849
17850 2002-11-27  Paul Eggert  <eggert@twinsun.com>
17851
17852         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
17853         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
17854         with `if (! (value < limit)) abort ();', for readability.
17855
17856 2002-11-26  Karl Berry  <karl@gnu.org>
17857
17858         * lib/strdup.c: copy from libc again, with jim's ok.
17859         * lib/.cppi-disable: re-add strdup.c
17860
17861 2002-11-25  Karl Berry  <karl@gnu.org>
17862
17863         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
17864         instead of "strtol.c".
17865
17866 2002-11-25  Karl Berry  <karl@gnu.org>
17867
17868         * config/install-sh: update from automake for variable quoting, $0 in
17869         error msgs, etc.
17870
17871         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
17872         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
17873         entry.
17874
17875 2002-11-25  Jim Meyering  <jim@meyering.net>
17876
17877         * lib/mktime.c: Sync from libc, now that it has the latest fix.
17878
17879 2002-11-24  Karl Berry  <karl@gnu.org>
17880
17881         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
17882         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
17883
17884 2002-11-24  Jim Meyering  <jim@meyering.net>
17885
17886         Update from coreutils:
17887
17888         * lib/mktime.c: Merge in changes from libc.
17889
17890         Avoid a link-time failure on some Linux systems.
17891         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
17892         (otherwise).
17893         (__mon_yday): Declare with the STATIC attribute.
17894         (__mktime_internal): Likewise.
17895         Based on a report from Greg Schafer.
17896
17897 2002-11-23  Jim Meyering  <jim@meyering.net>
17898
17899         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
17900         Use `unsigned', not `int', as type of index.
17901
17902         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
17903
17904         * lib/fsusage.c: Remove unneeded parentheses around operands of
17905         `defined'.
17906
17907 2002-11-22  Paul Eggert  <eggert@twinsun.com>
17908
17909         * lib/quotearg.h: Allow multiple inclusion by surrounding with
17910         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
17911         so that we can be included first.
17912         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
17913         * lib/quotearg.c: Include quotearg.h immediately after config.h.
17914         No need to include stddef.h or sys/types.h any more.
17915         Surround local include files with "", not "<>".
17916         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
17917         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
17918         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
17919         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
17920         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
17921         (ISPRINT): Remove; no longer needed now that we assume C89.
17922
17923         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
17924         Preserve errno.
17925
17926         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
17927         quotearg_char): Use SIZE_MAX rather than
17928         (size_t) -1 when we are talking about "infinity".
17929
17930         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
17931
17932 2002-11-22  Paul Eggert  <eggert@twinsun.com>
17933
17934         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
17935         hint that one should use `if (! x) abort ();' rather than `assert
17936         (x);', and anyway it's one less thing to worry about configuring.
17937         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
17938         hash_rehash, hash_insert): Use abort rather than assert.
17939
17940 2002-11-22  Bruno Haible  <bruno@clisp.org>
17941
17942         * lib/safe-read.h: Assume C89. Add comments.
17943         (safe_read): Change return type to size_t.
17944         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
17945         byte counts > SSIZE_MAX correctly.
17946         * lib/safe-write.h: New file.
17947         * lib/safe-write.c: New file.
17948         * lib/full-read.h: New file.
17949         * lib/full-read.c: New file.
17950         * lib/full-write.h: Assume C89. Add comments.
17951         * lib/full-write.c: Include safe-write.h.
17952         (full_write): Rewritten to use safe_write.
17953         Suggested by Jim Meyering and Paul Eggert.
17954
17955 2002-11-21  Jim Meyering  <jim@meyering.net>
17956
17957         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
17958
17959         Merge in changes from the coreutils.
17960
17961         2002-09-25  Paul Eggert  <eggert@twinsun.com>
17962         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
17963         <stdint.h>.
17964         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
17965         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
17966         int.  Work more efficiently if X is the same width as uintmax_t.
17967         Do not compare X to -1, to avoid bogus compiler warning.
17968         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
17969         Don't assume that f_frsize and f_bsize are the same type.
17970
17971         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
17972         warning on FreeBSD.
17973
17974         * lib/makepath.c (make_path): Restore umask *before* creating the final
17975         component.
17976         (make_path): Minor reformatting.
17977
17978         * lib/xmalloc.c: Adjust to work with new autoconf macros,
17979         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
17980         HAVE_MALLOC/HAVE_REALLOC.
17981
17982         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
17983         dummy ones.  At least on GNU/Linux systems, `auto' means something
17984         else.
17985         From Michael Stone.
17986
17987 2002-11-21  Bruno Haible  <bruno@clisp.org>
17988
17989         Remove case insensitive option matching.
17990         * lib/argmatch.h (argcasematch): Remove declaration.
17991         (ARGCASEMATCH): Remove macro.
17992         (__xargmatch_internal): Remove case_sensitive argument.
17993         (XARGMATCH): Update.
17994         (XARGCASEMATCH): Remove macro.
17995         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
17996         case_sensitive argument.
17997         (argcasematch): Remove function.
17998         (__xargmatch_internal): Remove case_sensitive argument.
17999         (main): Use XARGMATCH instead of XARGCASEMATCH.
18000
18001         * lib/xmalloc.c: Change compile-time error message. Add comment about
18002         required autoconf version.
18003
18004 2002-11-20  Paul Eggert  <eggert@twinsun.com>
18005
18006         Merge argmatch cleanups from Bison.  Assume C89.
18007
18008         * lib/argmatch.c: Include config.h here, not in argmatch.h.
18009         Include stdlib.h, for EXIT_FAILURE.
18010         Always include <string.h>, since we assume C89.
18011         (EXIT_FAILURE): Remove pre-C89 bug workaround.
18012         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
18013         Include <stddef.h> instead, since it's all we need for size_t.
18014         (PARAMS): Remove.  All uses removed.
18015         (ARRAY_CARDINALITY): Do not bother to #undef.
18016         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
18017         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
18018         Remove unnecessary parentheses.
18019         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
18020         Insert necessary parentheses.
18021         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
18022         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
18023
18024 2002-11-19  Bruno Haible  <bruno@clisp.org>
18025
18026         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
18027         * lib/mbswidth.h: Include <stddef.h>, for size_t.
18028
18029         * lib/mbswidth.h (PARAMS): Remove macro.
18030         (mbswidth, mbsnwidth): Use ANSI C function declarations.
18031         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
18032
18033         * lib/gcd.h (PARAMS): Remove macro.
18034         (gcd): Use ANSI C function declarations.
18035         * lib/gcd.c (gcd): Likewise.
18036
18037 2002-11-15  Bruno Haible  <bruno@clisp.org>
18038
18039         * lib/strcspn.c: Include <stddef.h>.
18040         (strcspn): Use ANSI C function declaration. Change return type to
18041         size_t. Use NULL.
18042         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
18043         (strpbrk): Use NULL.
18044         * lib/strpbrk.h (PARAMS): Remove macro.
18045         (strpbrk): Use ANSI C function declaration.
18046         * lib/strstr.c: Don't include <sys/types.h>.
18047         * lib/strstr.h (PARAMS): Remove macro.
18048         (strstr): Use ANSI C function declarations.
18049
18050 2002-11-14  Karl Berry  <karl@gnu.org>
18051
18052         * config/mkinstalldirs: `do' on separate line, instead of
18053         `for var; do'.
18054
18055 2002-11-06  Bruno Haible  <bruno@clisp.org>
18056
18057         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
18058         * lib/gcd.c (gcd): Likewise.
18059
18060 2002-11-05  Bruno Haible  <bruno@clisp.org>
18061
18062         * lib/gcd.h: New file, from gettext-0.11.5.
18063         * lib/gcd.c: New file, from gettext-0.11.5.
18064
18065 2002-11-05  Bruno Haible  <bruno@clisp.org>
18066
18067         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
18068         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
18069         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
18070         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
18071
18072         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
18073         <libintl.h>.
18074         * lib/makepath.c: Include gettext.h instead of <locale.h> and
18075         <libintl.h>.
18076
18077         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
18078         * lib/human.c: Include gettext.h instead of <libintl.h>.
18079         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
18080         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
18081         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
18082         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
18083         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
18084         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
18085         (textdomain): Remove definition.
18086         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
18087
18088         * lib/long-options.c: Remove include of <libintl.h> and definition of
18089         _.
18090         * lib/same.c: Remove include of <libintl.h> and definition of _.
18091
18092 2002-11-04  Owen Taylor  <otaylor@redhat.com>
18093
18094         * lib/config.charset: A few additions for Solaris.
18095
18096 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
18097
18098         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
18099         * lib/localcharset.c (locale_charset): Declare as extern "C".
18100
18101 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
18102
18103         * lib/config.charset: msdos in uk_UA uses CP1125.
18104
18105 2002-11-04  Bruno Haible  <bruno@clisp.org>
18106
18107         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
18108         * lib/strcase.h: New file, from GNU gettext-0.11.5.
18109         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
18110         * lib/strstr.h: New file, from GNU gettext-0.11.5.
18111         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
18112
18113 2002-11-04  Bruno Haible  <bruno@clisp.org>
18114
18115         * lib/localcharset.c (locale_charset): Don't return an empty string.
18116
18117 2002-11-04  Bruno Haible  <bruno@clisp.org>
18118
18119         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
18120         aliases.
18121
18122 2002-11-04  Bruno Haible  <bruno@clisp.org>
18123
18124         * lib/config.charset: Update for newest glibc. Add canonical names
18125         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
18126
18127 2002-11-04  Bruno Haible  <bruno@clisp.org>
18128
18129         * lib/config.charset: Add support for NetBSD.
18130
18131 2002-11-04  Bruno Haible  <bruno@clisp.org>
18132
18133         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
18134
18135 2002-11-01  Bruno Haible  <bruno@clisp.org>
18136
18137         * configure.in: Add AC_CONFIG_AUX_DIR call.
18138         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
18139         test/Makefile.
18140         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
18141
18142 2002-09-28  Karl Berry  <karl@gnu.org>
18143
18144         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
18145         installed automake until the next release, since changes have been
18146         made.
18147
18148 2002-09-25  Karl Berry  <karl@gnu.org>
18149
18150         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
18151         * lib/getopt*: copy from libc/posix.
18152         * lib/gettext.h: copy from gettext.
18153         * lib/.cppi-disable: add strdup.c, gettext.h.
18154
18155 2002-09-25  Karl Berry  <karl@gnu.org>
18156
18157         * config/srclist.txt: enable gettext.h check.
18158         * config/config.{guess,sub}: update from prep.
18159         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
18160                 from automake 1.6.3.
18161         See srclist*.
18162
18163 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
18164
18165         * regex.c (PATFETCH): Remove the translating fetch.
18166         (PATFETCH_RAW): Rename to PATFETCH.
18167         (set_image_of_range): New fun.
18168         (SET_RANGE_TABLE_WORK_AREA): Use it.
18169         (regex_compile): Don't translate the pattern chars so eagerly.
18170         Only do it when inserting an `exactn' bytecode or when handling
18171         a char-range.
18172         (mutually_exclusive_p): Avoid empty statement.
18173
18174 2002-07-06  Jim Meyering  <meyering@lucent.com>
18175
18176         * m4/README: Don't mention Makefile.am.in.
18177         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
18178
18179 2002-07-01  Jim Meyering  <meyering@lucent.com>
18180
18181         * lib/c-stack.c: Include sys/time.h.
18182         From Volker Borchert.
18183
18184 2002-06-26  Paul Eggert  <eggert@twinsun.com>
18185
18186         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
18187
18188 2002-06-26  Paul Eggert  <eggert@twinsun.com>
18189
18190         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
18191         New macro.  Use it uniformly instead of
18192         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
18193         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
18194         reported by Vin Shelton.
18195
18196 2002-06-22  Paul Eggert  <eggert@twinsun.com>
18197
18198         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
18199         Do not assume SA_SIGINFO behavior.
18200         Bug reported by Jim Meyering on NetBSD 1.5.2.
18201
18202 2002-06-22  Jim Meyering  <meyering@lucent.com>
18203
18204         * m4/c-stack.m4: New file, from diffutils-2.8.2.
18205         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
18206
18207         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
18208         now that configure.ac uses AC_GNU_SOURCE.
18209         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
18210         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
18211
18212         Update to latest tools.  Suggestions from Paul Eggert.
18213         * m4/stdbool.m4: New file, from diffutils-2.8.2.
18214         * m4/gnu-source.m4: Update from diffutils-2.8.2.
18215         * m4/fnmatch.m4: Likewise.
18216         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
18217         to AC_HEADER_STDBOOL
18218
18219 2002-06-22  Jim Meyering  <meyering@lucent.com>
18220
18221         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
18222         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
18223
18224 2002-06-22  Jim Meyering  <meyering@lucent.com>
18225
18226         * lib/c-stack.c, c-stack.h: New files, from diffutils-2.8.2.
18227
18228         * lib/exitfail.c, exitfail.h: Likewise.
18229         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
18230
18231         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
18232         of fnmatch.h.
18233         (EXTRA_DIST): Add fnmatch_loop.c.
18234         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
18235
18236         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
18237         * lib/fnmatch.c: Update from diffutils-2.8.2.
18238         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
18239         * lib/fnmatch.h: Remove file.
18240
18241 2002-06-21  Jim Meyering  <meyering@lucent.com>
18242
18243         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
18244         * m4/mbrtowc.m4: Likewise.
18245
18246         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
18247         * m4/mbswidth.m4: Reflect name change:
18248         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
18249         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
18250
18251         * m4/lib-link.m4: Update from gettext-0.11.2.
18252         * m4/gettext.m4: Likewise.
18253
18254         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
18255         From Alfred M. Szmidt.
18256
18257 2002-06-18  Paul Eggert  <eggert@twinsun.com>
18258
18259         * lib/file-type.h: Report an error if neither S_ISREG nor
18260         S_IFREG is defined, instead of using a test specific to glibc
18261         2.2.  This should be safe, since POSIX requires S_ISREG and
18262         Unix Version 7 had S_IFREG.  We don't need to check for
18263         <sys/types.h> since we don't use any symbols that it defines.
18264
18265 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
18266
18267         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
18268         $@-t, so that each temporary file name is unique and valid in the first
18269         8 characters, for operation under DOS.
18270
18271 2002-06-15  Paul Eggert  <eggert@twinsun.com>
18272
18273         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
18274
18275 2002-06-15  Jim Meyering  <meyering@lucent.com>
18276
18277         Work even with DJGPP 2.03, which lacks support for symlinks.
18278         From Richard Dawe.
18279         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
18280         is defined.
18281         * lib/lchown.c (S_ISLNK): Likewise.
18282
18283 2002-06-15  Jim Meyering  <meyering@lucent.com>
18284
18285         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
18286         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
18287         have been included before this file.
18288
18289 2002-06-14  Jim Meyering  <meyering@lucent.com>
18290
18291         * lib/file-type.h: Use the version from diffutils-2.8.2.
18292         * lib/file-type.c: Likewise.
18293
18294 2002-06-07  Jim Meyering  <meyering@lucent.com>
18295
18296         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
18297         They're needed at least for NetBSD 1.5.2.
18298         ($statxfs_includes): Include those same headers.
18299         ($statxfs_includes): Include sys/vfs.h if available.
18300         ($statxfs_includes): Likewise for sys/statvfs.h.
18301         Check for the following members in both structs statfs and statvfs:
18302         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
18303
18304 2002-06-01  Jim Meyering  <meyering@lucent.com>
18305
18306         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
18307         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
18308
18309 2002-05-28  Jim Meyering  <meyering@lucent.com>
18310
18311         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
18312         Reported by Volker Borchert.
18313
18314 2002-05-27  Jim Meyering  <meyering@lucent.com>
18315
18316         Fix a problem seen only on nonconforming systems whereby ls.c's
18317         use of localtime, and then of gettimeofday would cause trouble:
18318         the localtime call used to initialize rpl_gettimeofday's save
18319         mechanism would clobber ls's current local time information so
18320         that in any long listing the first file would always be listed
18321         with date 1970-01-01.  Analysis by Volker Borchert.
18322
18323         * lib/gettimeofday.c (localtime): Undefine.
18324         (rpl_localtime): New function.
18325
18326 2002-05-27  Jim Meyering  <meyering@lucent.com>
18327
18328         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
18329         localtime.
18330
18331         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
18332         use the replacement function; it wouldn't resolve at link time.
18333         Reported by Volker Borchert.
18334
18335 2002-05-22  Jim Meyering  <meyering@lucent.com>
18336
18337         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
18338         file-type.h.
18339         * lib/file-type.h: New file.
18340         * lib/file-type.c (file_type): New file/function.  Extracted from
18341         diffutils.
18342
18343 2002-04-30  Jim Meyering  <meyering@lucent.com>
18344
18345         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
18346
18347 2002-04-29  Paul Eggert  <eggert@twinsun.com>
18348
18349         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
18350
18351 2002-04-29  Paul Eggert  <eggert@twinsun.com>
18352
18353         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
18354         Do not check for alloca.h (no longer used) or stdbool.h (was never
18355         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
18356
18357 2002-04-29  Paul Eggert  <eggert@twinsun.com>
18358
18359         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
18360
18361 2002-04-29  Jim Meyering  <meyering@lucent.com>
18362
18363         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
18364         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
18365         Use AC_FUNC_STRNLEN here instead.
18366
18367         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
18368         With autoconf-2.53a, it's part of AC_PROG_CC.
18369
18370 2002-04-28  Paul Eggert  <eggert@twinsun.com>
18371
18372         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
18373         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
18374
18375 2002-04-28  Paul Eggert  <eggert@twinsun.com>
18376
18377         * lib/sig2str.h, sig2str.c: New files.
18378         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
18379
18380 2002-04-28  Paul Eggert  <eggert@twinsun.com>
18381
18382         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
18383         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
18384         of 127, since 64 is the largest conceivable number for ancient
18385         nonstandard hosts.
18386         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
18387
18388 2002-04-28  Jim Meyering  <meyering@lucent.com>
18389
18390         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
18391
18392 2002-04-24  Jim Meyering  <meyering@lucent.com>
18393
18394         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
18395         (jm_PREREQ): Use it.
18396
18397         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
18398         mach/mach.h fcntl.h.
18399         Check for this function: setlocale.
18400
18401 2002-04-24  Jim Meyering  <meyering@lucent.com>
18402
18403         * lib/gettext.h: New file, from Gettext.
18404         * lib/Makefile.am (INCLUDES): Remove -I../intl.
18405         (libfetish_a_SOURCES): Add gettext.h.
18406
18407 2002-04-16  Jim Meyering  <meyering@lucent.com>
18408
18409         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
18410         ut_pid, ut_id, ut_exit.
18411
18412 2002-04-16  Jim Meyering  <meyering@lucent.com>
18413
18414         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
18415         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
18416         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
18417
18418 2002-04-12  Jim Meyering  <meyering@lucent.com>
18419
18420         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
18421         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
18422         existence of the getmntinfo function.  Needed for Darwin 5.3.
18423
18424         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
18425         This is necessary at least on Darwin 5.3.
18426
18427         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
18428         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
18429         strnlen.o in the library, and that makes some versions of ranlib
18430         object.
18431
18432 2002-04-12  Jim Meyering  <meyering@lucent.com>
18433
18434         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
18435
18436 2002-04-09  Jim Meyering  <meyering@lucent.com>
18437
18438         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
18439         to be more precise.  Rather than saying we're checking whether the
18440         function `works', say what we're testing.
18441         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
18442         Reported by Bruno Haible.
18443
18444 2002-03-10  Jim Meyering  <meyering@lucent.com>
18445
18446         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
18447         Suggestion from Santiago Vila.
18448
18449 2002-03-08  Jim Meyering  <meyering@lucent.com>
18450
18451         * lib/rename.c: Mention that this wrapper is needed also on
18452         mips-dec-ultrix4.4 systems.
18453
18454 2002-03-02  Jim Meyering  <meyering@lucent.com>
18455
18456         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
18457         not HAVE_CLOCK_SETTIME.
18458
18459 2002-02-27  Paul Eggert  <eggert@twinsun.com>
18460
18461         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
18462         Check for clock_settime.
18463
18464 2002-02-27  Paul Eggert  <eggert@twinsun.com>
18465
18466         * lib/nanosleep.h: Rename to....
18467         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
18468
18469         * lib/gettime.c: New file.
18470         * lib/settime.c: New file.
18471         * lib/stime.c: Remove.
18472
18473         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
18474         timespec.h.  Remove nanosleep.h.
18475
18476 2002-02-25  Paul Eggert  <eggert@twinsun.com>
18477
18478         * m4/acl.m4: New file.
18479         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
18480         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
18481
18482 2002-02-25  Paul Eggert  <eggert@twinsun.com>
18483
18484         * lib/acl.c, acl.h: New files.
18485         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
18486
18487 2002-02-24  Jim Meyering  <meyering@lucent.com>
18488
18489         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
18490         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
18491         cause trouble.  Reported by Nelson Beebe.
18492
18493 2002-02-23  Paul Eggert  <eggert@twinsun.com>
18494
18495         * lib/path-concat.c (xpath_concat): Reorder code to pacify
18496         compilers that don't know that xalloc_die never returns.
18497
18498 2002-02-20  Jim Meyering  <meyering@lucent.com>
18499
18500         * lib/getdate.c: Regenerate using bison-1.33.
18501
18502 2002-02-17  Jim Meyering  <meyering@lucent.com>
18503
18504         * config/config.guess (main): Don't use `head -1'; it's no longer
18505         portable. Use `sed 1q' instead.
18506
18507 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
18508
18509         * m4/codeset.m4: Upgrade to gettext-0.11.
18510         * m4/gettext.m4: Upgrade to gettext-0.11.
18511         * m4/glibc21.m4: Upgrade to gettext-0.11.
18512         * m4/iconv.m4: Upgrade to gettext-0.11.
18513         * m4/isc-posix.m4: Upgrade to gettext-0.11.
18514         * m4/lcmessage.m4: Upgrade to gettext-0.11.
18515         * m4/lib-ld.m4: New file, from gettext-0.11.
18516         * m4/lib-link.m4: New file, from gettext-0.11.
18517         * m4/lib-prefix.m4: New file, from gettext-0.11.
18518         * m4/progtest.m4: Upgrade to gettext-0.11.
18519
18520 2002-02-15  Paul Eggert  <eggert@twinsun.com>
18521
18522         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
18523         (jm_PREREQ): Use it.
18524
18525 2002-02-15  Paul Eggert  <eggert@twinsun.com>
18526
18527         * lib/posixver.c, posixver.h: New files.
18528         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
18529
18530 2002-02-02  Paul Eggert  <eggert@twinsun.com>
18531             Bruno Haible  <bruno@clisp.org>
18532
18533         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
18534         (fwrite_success_callback): New declaration.
18535         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
18536         print_unicode_char. Call failure callback instead of error.
18537         (fwrite_success_callback): New function.
18538         (exit_failure_callback): New function.
18539         (fallback_failure_callback): New function.
18540         (print_unicode_char): Call unicode_to_mb.
18541
18542 2002-01-26  Jim Meyering  <meyering@lucent.com>
18543
18544         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
18545         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
18546
18547 2002-01-26  Jim Meyering  <meyering@lucent.com>
18548
18549         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
18550
18551 2002-01-22  Paul Eggert  <eggert@twinsun.com>
18552
18553         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
18554
18555 2002-01-22  Jim Meyering  <meyering@lucent.com>
18556
18557         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
18558         Otherwise, some versions of automake would omit the rule that makes
18559         Makefile from Makefile.in.
18560
18561 2002-01-21  Paul Eggert  <eggert@twinsun.com>
18562
18563         * lib/xmemcoll.h, xmemcoll.c: New files.
18564         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
18565         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
18566         (memcoll): Set errno to zero if there is no error.
18567
18568         * lib/quotearg.c (quotearg_buffer_restyled):
18569         Fix bug with quoting buffers containing NUL when backslashing escapes.
18570         This bug was exposed by the other changes in this patch.
18571         (quotearg_n_options): New arg ARGSIZE.
18572         All callers changed.
18573         (quoting_options_from_style): New function.
18574         (quotearg_n_style): Use it.
18575         (quotearg_n_style_mem): New function.
18576
18577         * lib/quotearg.h (quotearg_n_style_mem): New function.
18578
18579 2002-01-19  Jim Meyering  <meyering@lucent.com>
18580
18581         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
18582         Remove useless quotes: DF_PROG="df".
18583         * m4/strnlen.m4: New file.
18584
18585 2002-01-16  Paul Eggert  <eggert@twinsun.com>
18586
18587         * lib/backupfile.c (ISDIGIT): Comment fix.
18588         * lib/getdate.y (ISDIGIT): Likewise.
18589         * lib/posixtm.c (ISDIGIT, year): Likewise.
18590         * lib/strverscmp.c (ISDIGIT): Likewise.
18591         * lib/userspec.c (ISDIGIT): Likewise.
18592
18593 2002-01-16  Jim Meyering  <meyering@lucent.com>
18594
18595         * lib/getdate.y: Add three semicolons, each just before a closing
18596         brace. Bison (as of version 1.31) no longer papers over that mistake.
18597
18598 2002-01-05  Jim Meyering  <meyering@lucent.com>
18599
18600         * lib/version-etc.c (version_etc_copyright): Update copyright year.
18601
18602 2001-12-19  Paul Eggert  <eggert@twinsun.com>
18603
18604         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
18605         not silently exit merely because the output buffer happens to
18606         have nothing pending.
18607
18608 2001-12-18  Paul Eggert  <eggert@twinsun.com>
18609
18610         See the big note in ../ChangeLog.
18611         * lib/human.c (suffixes): Prefer K to k for 1024.
18612         (generate_suffix_backwards): New function.
18613         (human_readable_inexact): Use it.
18614         * lib/xstrtol.c (__xstrtol): If there is no number but there
18615         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
18616         Accept 'K' as well as 'k'.
18617
18618 2001-12-15  Jim Meyering  <meyering@lucent.com>
18619
18620         * lib/regex.h (__restrict_arr): Update from libc.
18621
18622         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
18623         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
18624         (STREQ): Define.
18625
18626 2001-12-14  Jim Meyering  <meyering@lucent.com>
18627
18628         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
18629         Suggestion from Bruno Haible.
18630
18631 2001-12-10  Jim Meyering  <meyering@lucent.com>
18632
18633         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
18634         xrealloc, Instead, include "xalloc.h".
18635         (initbuffer): Don't cast xmalloc return value to char*.
18636         (readline): Reword comment.
18637         Don't cast xrealloc return value to char*
18638         Return NULL, not 0.
18639
18640 2001-12-09  Jim Meyering  <meyering@lucent.com>
18641
18642         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
18643         about `signed and unsigned type in conditional expression'.
18644         * lib/posixtm.c (posix_time_parse): Likewise.
18645
18646         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
18647
18648         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
18649         to avoid a pedantic warning.
18650
18651         * lib/getstr.c: Don't include assert.h.
18652         (getstr): Remove warning-evoking assertions.
18653         Return -1 if offset parameter is out of bounds.
18654         Change the type of a local from int to size_t.
18655
18656         * lib/strftime.c (my_strftime_localtime_r): Include this function
18657         definition in the `#if ! HAVE_TM_GMTOFF' block.
18658
18659         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
18660         Include xalloc.h instead.
18661
18662 2001-12-02  Jim Meyering  <meyering@lucent.com>
18663
18664         * lib/tempname.c: Don't declare getenv, thus reverting the change of
18665         2001-11-18.  It's no longer necessary, now that stdlib.h is always
18666         included.
18667
18668         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
18669         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
18670
18671 2001-11-30  Akim Demaille  <akim@epita.fr>
18672
18673         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
18674         before being defined.
18675
18676 2001-11-27  Paul Eggert  <eggert@twinsun.com>
18677
18678         * lib/quotearg.h (quotearg_n, quotearg_n_style):
18679         First arg is int, not unsigned.
18680         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
18681         (SIZE_MAX, UINT_MAX): New macros.
18682         (quotearg_n_options): Abort if N is negative.
18683         Avoid overflow check on hosts where size_t is 64 bits and int
18684         is 32 bits, as overflow is impossible there.
18685         Fix off-by-one typo that caused unnecessary reallocation.
18686
18687 2001-11-27  Jim Meyering  <meyering@lucent.com>
18688
18689         * lib/tempname.c: Merge with version from libc.
18690         * lib/regex.c: Likewise.
18691
18692         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
18693         systems for which STDC_HEADERS is 0, it was not included, resulting in
18694         a warning about an integer-to-pointer conversion problem with getenv.
18695         Reported by Volker Borchert.
18696
18697 2001-11-26  Jim Meyering  <meyering@lucent.com>
18698
18699         * lib/gtod.h: Remove file.
18700         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
18701         * lib/gettimeofday.c: Don't include gtod.h.
18702         (GTOD_init): Remove function.
18703         (rpl_gettimeofday): Do its job here instead, rather than aborting.
18704         Suggestion from Volker Borchert.
18705
18706 2001-11-23  Jim Meyering  <meyering@lucent.com>
18707
18708         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
18709         it.
18710         * lib/hash.c (struct hash_table): Define it here instead.
18711
18712 2001-11-22  Jim Meyering  <meyering@lucent.com>
18713
18714         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
18715
18716 2001-11-20  Jim Meyering  <meyering@lucent.com>
18717
18718         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
18719         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
18720
18721 2001-11-19  Jim Meyering  <meyering@lucent.com>
18722
18723         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
18724         directory.  Use "conftestXXXXXX" as the template.
18725         Suggestion from Paul Eggert.
18726
18727         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
18728         immediately, so the test doesn't mistakenly hit the max-open-files
18729         limit.
18730
18731 2001-11-18  Paul Eggert  <eggert@twinsun.com>
18732
18733         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
18734         (TEMPORARIES): New macro.
18735         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
18736         removes an artificial limitation (e.g. HP-UX 10.20, where
18737         TMP_MAX is 17576).
18738
18739 2001-11-18  Jim Meyering  <meyering@lucent.com>
18740
18741         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
18742
18743 2001-11-18  Jim Meyering  <meyering@lucent.com>
18744
18745         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
18746         on SunOS 4.
18747
18748         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
18749         files will be created before anything else.
18750
18751 2001-11-17 Paul Eggert  <eggert@twinsun.com>
18752
18753         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
18754         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
18755
18756 2001-11-17  Jim Meyering  <meyering@lucent.com>
18757
18758         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
18759         Prompted by a report from Bob Proulx.
18760
18761         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
18762         Instead, require UTILS_FUNC_MKSTEMP.
18763
18764 2001-11-17  Jim Meyering  <meyering@lucent.com>
18765
18766         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
18767         Now, that's done as part of AC_FUNC_STRTOD.
18768
18769 2001-11-17  Jim Meyering  <meyering@lucent.com>
18770
18771         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
18772         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
18773         rather than group writable.  Patch by Juan F. Codagnone.
18774
18775         * lib/readtokens.c: Remove explicit declarations of xmalloc and
18776         xrealloc, Instead, include "xalloc.h".
18777
18778         * lib/mountlist.c: Include unlocked-io.h after all system headers.
18779         Remove explicit declarations of xmalloc, xrealloc,
18780         and xstrdup.  Instead, include "xalloc.h".
18781
18782         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
18783         unlocked-io.h.
18784         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
18785         Likewise.
18786         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
18787
18788         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
18789         Reported by Padraig Brady.
18790
18791         * lib/mkstemp.c: #undef mkstemp.
18792         Include config.h.
18793         (rpl_mkstemp): Rename from mkstemp.
18794         Protoize.
18795
18796 2001-11-16  Jim Meyering  <meyering@lucent.com>
18797
18798         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
18799         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
18800         determine the amount of total physical memory, use pstat_getstatic.
18801         HPUX-11 doesn't define _SC_PHYS_PAGES.
18802         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
18803         If sysconf couldn't be used to determine the amount of available
18804         physical memory, use both pstat_getstatic and pstat_getdynamic.
18805         Based on a patch from Bob Proulx.
18806
18807 2001-11-10  Jim Meyering  <meyering@lucent.com>
18808
18809         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
18810         (jm_PREREQ): Use it.
18811
18812 2001-11-09  Jim Meyering  <meyering@lucent.com>
18813
18814         * m4/jm-macros.m4: Require autoconf-2.52f.
18815         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
18816         Use these AC_-prefixed names, not the AM_-prefixed ones.
18817
18818         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
18819
18820 2001-11-05  Jim Meyering  <meyering@lucent.com>
18821
18822         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
18823
18824 2001-11-04  Jim Meyering  <meyering@lucent.com>
18825
18826         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
18827         $DEFS.
18828
18829 2001-11-03  Jim Meyering  <meyering@lucent.com>
18830
18831         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
18832         of AC_DEFUN.
18833
18834         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
18835         know the name of the variable in the macro definition.
18836
18837 2001-11-03  Jim Meyering  <meyering@lucent.com>
18838
18839         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
18840         in argmatch_to_argument call.
18841
18842         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
18843         argument.
18844
18845         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
18846         e.g., a fault due to an attempt to free a NULL pointer.
18847
18848 2001-11-01  Jim Meyering  <meyering@lucent.com>
18849
18850         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
18851         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
18852
18853 2001-11-01  Jim Meyering  <meyering@lucent.com>
18854
18855         * lib/dirfd.c, dirfd.h: New files.
18856         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
18857
18858         * lib/hash.c (hash_print) [TESTING]: Clean up.
18859
18860 2001-10-22  Paul Eggert  <eggert@twinsun.com>
18861
18862         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
18863         to avoid a warning if -Wall.
18864
18865 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
18866
18867         * README: New file
18868         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
18869         (per RMS's instructions, this is now the canonical source)
18870         * lgpl/, gpl/: New directories.
18871
18872 2001-10-21  Paul Eggert  <eggert@twinsun.com>
18873
18874         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
18875
18876 2001-10-21  Jim Meyering  <meyering@lucent.com>
18877
18878         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
18879         this code would end up calling gettext even in packages built
18880         with --disable-nls.
18881         * lib/getopt.c (_): Likewise.
18882         * lib/regex.c (_): Likewise.
18883
18884 2001-10-20  Paul Eggert  <eggert@twinsun.com>
18885
18886         * m4/error.m4 (jm_PREREQ_ERROR):
18887         Do not invoke AC_CHECK_FUNCS with strerror_r, as
18888         AC_FUNC_STRERROR_R does that.
18889         Check for strerror declaration.
18890
18891         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
18892         are supposed to have them these days.
18893         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
18894         Merge changes from latest Autoconf CVS.
18895         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
18896         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
18897         POSIX decided to standardize on the int flavor of strerror_r.
18898
18899 2001-10-20  Paul Eggert  <eggert@twinsun.com>
18900
18901         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
18902         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
18903         Use strerror_r that is only a macro, even if it is not a function.
18904         (strerror): Check for HAVE_DECL_STRERROR before declaring.
18905         (private_strerror): Use prototypes, not old-style function definition.
18906         (print_errno_message): New function.
18907         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
18908         char*-flavored one.
18909         (error_tail, error, error_at_line): Use it.
18910
18911 2001-10-11  Jim Meyering  <meyering@lucent.com>
18912
18913         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
18914         and quote_n (1, ... to avoid clobbering a buffer.
18915
18916 2001-10-05  Jim Meyering  <meyering@lucent.com>
18917
18918         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
18919         hash-pjw.h.
18920         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
18921         * lib/hash-pjw.h: New file.
18922
18923 2001-09-30  Jim Meyering  <meyering@lucent.com>
18924
18925         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
18926         `struct fsstat' has the `f_fstypename' member.
18927         Use that to define FS_TYPE, which is now used to make
18928         the getfsstat link test tighter.
18929
18930 2001-09-30  Jim Meyering  <meyering@lucent.com>
18931
18932         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
18933         Include <sys/ucred.h>, for Apple Darwin.
18934         Include sys/mount.h and sys/fs_types.h only if available.
18935         (FS_TYPE): Define.
18936         (read_filesystem_list): Use FS_TYPE.
18937
18938 2001-09-29  Paul Eggert  <eggert@twinsun.com>
18939
18940         * lib/exclude.c (excluded_filename): 0 -> false, since it's
18941         a boolean context.
18942
18943 2001-09-29  Jim Meyering  <meyering@lucent.com>
18944
18945         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
18946         [one-argument getmntent function]): Include stdio.h before mntent.h.
18947         SunOS 4.1.x needs it for the declaration of `FILE'.
18948         Patch by Volker Borchert.
18949
18950         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
18951         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
18952         sys/fs_types.h, and make the link-test for getfsstat guard #include
18953         directives with appropriate #if HAVE_*_H tests so that we can
18954         detect getfsstat on Apple Darwin1.3.7 systems.
18955         Reported by Nelson Beebe.
18956         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
18957
18958 2001-09-28  Paul Eggert  <eggert@twinsun.com>
18959
18960         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
18961         #defines strtoimax.  Also treat the other strto* functions
18962         like strtoimax.
18963
18964         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
18965         Check for strtoul and strtoumax,
18966         as those declarations are made even in the signed case.
18967         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
18968         Likewise, for strtol and strtoimax.
18969
18970 2001-09-28  Paul Eggert  <eggert@twinsun.com>
18971
18972         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
18973         #defines strtoimax.  Also treat the other strto* functions
18974         like strtoimax.
18975
18976         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
18977         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
18978         (strtoimax, strtoumax): Do not declare if already defined as a macro.
18979
18980 2001-09-26  Jim Meyering  <meyering@lucent.com>
18981
18982         Most macros in unlocked-io.h had the wrong number of arguments.
18983         * lib/gen-uio: New script.
18984         (USE_UNLOCKED_IO): Define to 1 if not already defined.
18985         * lib/unlocked-io.hin: Remove file.
18986         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
18987         rather than trying to embed it here.
18988         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
18989         Reported by Padraig Brady.
18990
18991 2001-09-25  Volker Borchert  <bt@teknon.de>
18992
18993         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
18994         `result'.
18995
18996 2001-09-24  Jim Meyering  <meyering@lucent.com>
18997
18998         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
18999
19000 2001-09-23  Jim Meyering  <meyering@lucent.com>
19001
19002         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
19003         instead of the mere test for existence of mntent.h.  The latter
19004         would get a false-positive on AIX 3.4 systems.
19005         In the outer getmntent if-block, don't die if neither of the getmntent
19006         tests succeeds.  Instead, just fall through and continue with the
19007         remaining tests.
19008
19009 2001-09-23  Jim Meyering  <meyering@lucent.com>
19010
19011         * lib/mountlist.c: Remove useless parentheses in #if directives.
19012         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
19013         the deprecated MOUNTED symbol is no longer defined in mntent.h.
19014
19015 2001-09-22  Jim Meyering  <meyering@lucent.com>
19016
19017         * m4/gettext.m4: New file.  From gettext.
19018         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
19019         * m4/progtest.m4: Likewise
19020         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
19021         * m4/glibc21.m4: Likewise.
19022
19023         * m4/libintl.m4: Remove.  No longer used.
19024
19025 2001-09-22  Jim Meyering  <meyering@lucent.com>
19026
19027         * lib/localcharset.c: Update from latest gettext.
19028         * lib/config.charset: Likewise.
19029
19030 2001-09-20  Jim Meyering  <meyering@lucent.com>
19031
19032         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
19033         strtoimax.
19034         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
19035         strtoumax.
19036
19037 2001-09-20  Jim Meyering  <meyering@lucent.com>
19038
19039         * lib/xstrtol.c (strtoimax): Guard declaration with
19040         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
19041         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
19042         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
19043         (strtoumax): Likewise, for completeness (it wasn't necessary).
19044
19045 2001-09-17  Paul Eggert  <eggert@twinsun.com>
19046
19047         * lib/strtoimax.c (HAVE_LONG_LONG):
19048         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
19049         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
19050         to work around bug in IBM C compiler.
19051
19052 2001-09-17  Jim Meyering  <meyering@lucent.com>
19053
19054         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
19055         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
19056         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
19057         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
19058         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
19059         whenever the right hand side need not be expanded by the shell.
19060
19061 2001-09-16  Paul Eggert  <eggert@twinsun.com>
19062
19063         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
19064         library.  It's not correct, as some older glibcs are buggy.
19065         fnmatch wasn't fixed until glibc 2.2.
19066
19067         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
19068         special shell magic here.
19069
19070 2001-09-16  Jim Meyering  <meyering@lucent.com>
19071
19072         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
19073         * m4/jm-macros.m4: Require it.
19074
19075 2001-09-16  Jim Meyering  <meyering@lucent.com>
19076
19077         * lib/mkdir.c: New file.
19078
19079 2001-09-15  Jim Meyering  <meyering@lucent.com>
19080
19081         * m4/jm-macros.m4: Check for help2man.
19082
19083 2001-09-11  Jim Meyering  <meyering@lucent.com>
19084
19085         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
19086         The body, by Paul Eggert, was moved here from configure.in.
19087         * m4/jm-macros.m4: Require UTILS_HOST_OS.
19088
19089 2001-09-04  Paul Eggert  <eggert@twinsun.com>
19090
19091         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
19092         (jm_PREREQ): Use it.
19093
19094 2001-09-04  Paul Eggert  <eggert@twinsun.com>
19095
19096         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
19097         Use ssize_t, not int, to store result of readlink.
19098         Check for ssize_t overflow as well as size_t overflow,
19099         as POSIX says the result of readlink is implementation-defined
19100         when ssize_t overflows.
19101         Remove unnecessary cast to char*.
19102         Use free+malloc instead of realloc, as the storage doesn't need
19103         to be preserved and it's clearer and can be more efficient that way.
19104         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
19105         * lib/xreadlink.h (xreadlink): Update prototype.
19106
19107 2001-09-04  Paul Eggert  <eggert@twinsun.com>
19108
19109         * lib/xgetcwd.c: Revert some of the previous change; intead,
19110         fix the HAVE_GETCWD_NULL code to behave more like the
19111         !HAVE_GETCWD_NULL code used to.
19112
19113         Include "xalloc.h".
19114         (xgetcwd): Do not return NULL when memory is exhausted; instead,
19115         invoke xalloc_die.
19116
19117 2001-09-03  Paul Eggert  <eggert@twinsun.com>
19118
19119         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
19120         sys/param.h, as pathmax.h includes them.
19121
19122 2001-09-03  Paul Eggert  <eggert@twinsun.com>
19123
19124         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
19125         (jm_PREREQ_XGETCWD): New macro.
19126
19127         * m4/getcwd.m4: New file.
19128
19129 2001-09-03  Paul Eggert  <eggert@twinsun.com>
19130
19131         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
19132         like the HAVE_GETCWD_NULL code.
19133         Include pathmax.h if not HAVE_GETCWD.
19134         Do not include xalloc.h.
19135         (INITIAL_BUFFER_SIZE): New symbol.
19136         Do not use xmalloc / xrealloc, since the caller is responsible for
19137         handling errors.  Preserve errno around `free' during failure.
19138         Do not overrun buffer when using getwd.
19139
19140 2001-09-03  Paul Eggert  <eggert@twinsun.com>
19141
19142         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
19143         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
19144         getcwd (NULL, 0).
19145
19146 2001-09-03  Paul Eggert  <eggert@twinsun.com>
19147
19148         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
19149         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
19150         spotted by Jim Meyering.
19151
19152 2001-09-03  Jim Meyering  <meyering@lucent.com>
19153
19154         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
19155         failure.
19156
19157 2001-09-02  Jim Meyering  <meyering@lucent.com>
19158
19159         * lib/error.c: Update from GNU libc.
19160
19161 2001-09-01  Jim Meyering  <meyering@lucent.com>
19162
19163         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
19164         Used by df.
19165
19166 2001-09-01  Jim Meyering  <meyering@lucent.com>
19167
19168         * lib/xreadlink.c: New file.
19169         * lib/xreadlink.h: New file.
19170         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
19171         xreadlink.h.
19172
19173         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
19174         doesn't conflict with sparc Solaris 7's definition in
19175         /usr/include/sys/int_types.h.
19176
19177         * lib/exclude.c: Use `""', not `<>' to #include non-system header
19178         files.
19179         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
19180         and strncasecmp as r-values.  Unixware didn't have declarations.
19181
19182 2001-08-31  Paul Eggert  <eggert@twinsun.com>
19183
19184         * lib/xstrtol.h: Add copyright notice.
19185         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
19186         LONGINT_INVALID_SUFFIX_CHAR.
19187
19188 2001-08-31  Paul Eggert  <eggert@twinsun.com>
19189
19190         * lib/xstrtol.c (strtoimax): New decl.
19191
19192 2001-08-31  Paul Eggert  <eggert@twinsun.com>
19193
19194         * lib/xgetcwd.c: Don't include pathmax.h.
19195         Include stdlib.h and unistd.h if available.
19196         Include xalloc.h.
19197         (xmalloc, xstrdup, free): Remove decls.
19198         (xgetcwd): Don't assume sizes fit in unsigned.
19199         Check for overflow when computing sizes.
19200         Simplify reallocation code.
19201
19202 2001-08-31  Paul Eggert  <eggert@twinsun.com>
19203
19204         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
19205         a directory's st_size can have an arbitrary value, so the old
19206         usage could waste an arbitrary amount of memory.  All uses
19207         changed.
19208         * lib/savedir.h: Update prototype.
19209
19210 2001-08-31  Paul Eggert  <eggert@twinsun.com>
19211
19212         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
19213
19214         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
19215         old strtoimax.c.
19216
19217         Also, make the following further changes to make this file's
19218         configuration more similar to that of strtol.c:
19219         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
19220         (strtoumax, uintmax_t, strtoull, strtol): Remove.
19221         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
19222         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
19223         changed to signed values.
19224
19225         And make the following changes as well:
19226         Fix copyright notice, as 1999 was missing.
19227         (verify): New macro.
19228         (strtoimax): Check sizes at compile-time, not run-time.
19229         Prefer strtol to strtoll if both work.
19230         (main): Remove; it was not that useful and was a pain to maintain.
19231
19232         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
19233
19234 2001-08-31  Jim Meyering  <meyering@lucent.com>
19235
19236         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
19237         Use an initial, malloc'd, buffer of length 128 rather than
19238         a statically allocated one of length 1024.
19239
19240 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19241
19242         Simplify code, partly by assuming autoconf 2.52 semantics.
19243
19244         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
19245
19246         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
19247         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
19248         All uses removed.
19249         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
19250         Move AC_REQUIRE to next-to-top level, to avoid confusion.
19251         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
19252         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
19253         jm_AC_HEADER_INTTYPES_H.
19254         * m4/jm-macros.m4 (jm_MACROS): Likewise.
19255
19256         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
19257
19258         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
19259         Quote first arg of AC_DEFUN.
19260         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
19261         since they are needed to parse the include file even if we need
19262         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
19263         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
19264         but with opposite signedness.
19265
19266 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19267
19268         Merge 'exclude' changes from tar 1.13.22.
19269         This fixes one or two unlikely storage allocation overflow bugs,
19270         but doesn't change user-visible behavior otherwise.
19271
19272 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19273
19274         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
19275         (jm_PREREQ_EXCLUDE): New macro.
19276
19277 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19278
19279         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
19280         tm to be declared.
19281
19282 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19283
19284         * lib/hash.c: Remove '2001' from copyright notice.
19285
19286 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19287
19288         * lib/full-write.h: New file.
19289         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
19290         * lib/full-write.c: Correct credits, as cccp.c no longer
19291         exists and anyway it was so heavily changed from the old cccp
19292         code as to be unrecognizable.  Include full-write.h.
19293         (full_write) Return size_t, with short writes meaning failure.
19294         All callers changed.  This fixes a bug with large buffers
19295         on 64-bit hosts.
19296         * lib/utime.c: Include full-write.h.
19297
19298 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19299
19300         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
19301         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
19302         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
19303         Include if available.
19304         (<xalloc.h>): Include
19305         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
19306         (verify): New macro.  Use it to verify that EXCLUDE macros do not
19307         collide with FNM macros.
19308         (struct patopts): New struct.
19309         (struct exclude): Use it, as exclude patterns now come with options.
19310         (new_exclude): Support above changes.
19311         (new_exclude, add_exclude_file):
19312         Initial size must now be a power of two to simplify overflow checking.
19313         (free_exclude, fnmatch_no_wildcards): New function.
19314         (excluded_filename): No longer requires options arg, as the options
19315         are determined by add_exclude.  Now returns bool, not int.
19316         (excluded_filename, add_exclude):
19317         Add support for the fancy new exclusion options.
19318         (add_exclude, add_exclude_file): Now takes int options arg.
19319         Check for arithmetic overflow when computing sizes.
19320         (add_exclude_file): xrealloc might modify errno, so don't
19321         realloc until after errno might be used.
19322
19323         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
19324         New macros.
19325         (free_exclude): New decl.
19326         (add_exclude, add_exclude_file): Now takes int options arg.
19327         (excluded_filename): No longer requires options arg, as the options
19328         are determined by add_exclude.  Now returns bool, not int.
19329
19330 2001-08-30  Paul Eggert  <eggert@twinsun.com>
19331
19332         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
19333
19334 2001-08-27  Jim Meyering  <meyering@lucent.com>
19335
19336         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
19337
19338         * lib/version-etc.c (N_): Remove definition.
19339         Revert most of last change.
19340         Instead, simply don't mark the `Copyright...' string for translation.
19341         Based on advice from Paul Eggert.
19342
19343         * lib/strtoxmax.c: Tweak comment.
19344
19345 2001-08-26  Jim Meyering  <meyering@lucent.com>
19346
19347         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
19348
19349         * m4/xstrtoimax.m4: New file.
19350         * m4/xstrtoumax.m4: Add comments explaining why we
19351         AC_REPLACE_FUNCS(strtol).
19352
19353 2001-08-26  Jim Meyering  <meyering@lucent.com>
19354
19355         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
19356         of copyright with `%s' so translators don't get an untranslated
19357         message in 2002.
19358         (COPYRIGHT_YEAR): Define.
19359         (version_etc): Use fprintf rather than fputs.
19360         Suggestion from Ulrich Drepper.
19361
19362         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
19363
19364         * lib/strtoll.c: New file, from GNU libc.
19365         * lib/xstrtoimax.c: New file.
19366
19367         * lib/xstrtol.h: Add xstrtoimax.
19368         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
19369         * lib/strtoimax.c: New file.  Likewise, but first define
19370         STRTOUXMAX_SIGNED.
19371
19372         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
19373         ...
19374         * lib/strtoxmax.c: ... then renamed to this.
19375
19376 2001-08-18  Paul Eggert  <eggert@twinsun.com>
19377
19378         * m4/inttypes.m4: Add AC_PREREQ(2.13).
19379         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
19380         (jm_AC_TYPE_INTMAX_T): New macro.
19381         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
19382
19383         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
19384
19385         * m4/longlong.m4: Renamed from ulonglong.m4.
19386         * m4/inttypes.m4: Renamed from inttypes_h.m4.
19387         * m4/uintmax_t.m4: Removed.
19388
19389 2001-08-13  Paul Eggert  <eggert@twinsun.com>
19390
19391         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
19392         Port to Solaris 8, where 'sed' requires a space after the 'r'
19393         command, and where sh dislikes "$/".  Clean up the spacing a bit.
19394         Redirect output to $tmp just once.
19395
19396 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
19397
19398         * lib/addext.c (<errno.h>): Include.
19399         (errno): Declare if not defined.
19400         (addext): Work correctly when pathconf returns -1 and leaves
19401         errno alone because there is no limit.  Also, work even if
19402         pathconf returns a value greater than SIZE_MAX.
19403
19404 2001-08-12  Jim Meyering  <meyering@lucent.com>
19405
19406         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
19407         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
19408         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
19409         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
19410         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
19411         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
19412         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
19413         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
19414         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
19415         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
19416         utime.m4, utimes.m4, xstrtoumax.m4:
19417         Quote the first argument in each use of AC_DEFUN.
19418
19419 2001-08-12  Jim Meyering  <meyering@lucent.com>
19420
19421         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
19422         Simply `return getcwd (NULL, 0);'.
19423         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
19424         Use 1300 as initial value for length, not PATH_MAX.
19425
19426         * lib/pathmax.h: Clean up cpp syntax.
19427
19428 2001-08-12  Jim Meyering  <meyering@lucent.com>
19429
19430         * lib/gettimeofday.c: New file.
19431         * lib/gtod.h: New file.
19432         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
19433
19434 2001-08-05  Jim Meyering  <meyering@lucent.com>
19435
19436         * m4/jm-macros.m4: Require autoconf-2.52.
19437
19438 2001-08-04  Jim Meyering  <meyering@lucent.com>
19439
19440         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
19441         stmt, to get in sync with glibc.
19442
19443 2001-08-03  Paul Eggert  <eggert@twinsun.com>
19444
19445         The following changes are from gettext 0.10.39 as maintained by
19446         Bruno Haible.
19447
19448         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
19449         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
19450         with inverted sense.  All uses changed.
19451
19452         * lib/mbswidth.c: Don't include <limits.h>.
19453         Include <stdlib.h> and <string.h> unconditionally.
19454         (iswcntrl, mbsinit, ISCNTRL): New macros.
19455         (mbsnwidth): Use K&R style function declarations.
19456         Don't bother checking for MB_LEN_MAX == 1, since the compiler
19457         can optimize it when MB_CUR_MAX == 1.
19458         The width of control characters is zero, not 1.
19459
19460 2001-08-03  Paul Eggert  <eggert@twinsun.com>
19461
19462         The following changes are from gettext 0.10.39 as maintained by
19463         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
19464
19465         * m4/codeset.m4: Upgrade to serial AM1.
19466         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
19467         all uses changed.  Quote first arg of AC_DEFUN.
19468         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
19469
19470         * m4/iconv.m4: Upgrade to serial AM2.
19471         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
19472         Add --with-libconv-prefix.
19473         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
19474         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
19475         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
19476         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
19477         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
19478
19479         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
19480         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
19481         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
19482         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
19483         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
19484         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
19485         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
19486         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
19487         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
19488
19489         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
19490         string.h any more.
19491
19492         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
19493         not the default value.
19494
19495         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
19496         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
19497         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
19498         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
19499         Also check for iswcntrl, used for wcwidth fallback.
19500         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
19501         to Autoconf 2.13.
19502
19503 2001-08-03  Jim Meyering  <meyering@lucent.com>
19504
19505         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
19506         as it was in the original.  Reported by Paul Eggert.
19507
19508 2001-07-16  Jim Meyering  <meyering@lucent.com>
19509
19510         * m4/gettimeofday.m4: New file.
19511         Prompted by a report from Bernhard Baehr.
19512
19513 2001-07-15  Jim Meyering  <meyering@lucent.com>
19514
19515         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
19516         stuff. Now it's in ../Makefile.cfg.
19517
19518 2001-07-15  Jim Meyering  <meyering@lucent.com>
19519
19520         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
19521         (BUILT_SOURCES): Add unlocked-io.h.
19522         (io_functions): Define.
19523         (unlocked-io.h): New rule.
19524         (DISTCLEANFILES): Add unlocked-io.h.
19525         (all-local): Depend on unlocked-io.h, to ensure it is created.
19526
19527         * lib/unlocked-io.hin: New file
19528
19529         * lib/regex.c: Update from glibc.
19530
19531 2001-07-05  Jim Meyering  <meyering@lucent.com>
19532
19533         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
19534         recommendation.
19535         (libfetish_a_SOURCES): Put all .h files here instead.
19536         Remove a thus-exposed (better checks in automake) duplicate and
19537         two unnecessary .h files.
19538
19539 2001-07-04  Jim Meyering  <meyering@lucent.com>
19540
19541         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
19542         that generates jm-glibc-io.m4 so that it doesn't trigger any make
19543         distcheck failure.
19544
19545 2001-07-02  Jim Meyering  <meyering@lucent.com>
19546
19547         The following changes were prompted by suggestions from Bruno Haible.
19548
19549         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
19550         is now generated.
19551         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
19552         definition of EXTRA_DIST.
19553         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
19554         ensure that the generated file is created/updated whenever the list
19555         of $(unlocked_functions) is changed.
19556         (jm-glibc-io.m4): New rule.
19557         (unlocked-io.h): New rule -- currently unused.
19558
19559 2001-06-24  Jim Meyering  <meyering@lucent.com>
19560
19561         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
19562         unmatched right bracket, rather than kludging it with an extra,
19563         falsely-matching quote in a comment.  Patch by Akim Demaille.
19564
19565 2001-06-11  Jim Meyering  <meyering@lucent.com>
19566
19567         * lib/regex.c: Update from GNU libc.
19568
19569 2001-05-27  Jim Meyering  <meyering@lucent.com>
19570
19571         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
19572         Check for ut_type in struct utmp.
19573
19574 2001-05-27  Jim Meyering  <meyering@lucent.com>
19575
19576         * lib/readutmp.h (UT_TYPE): Define.
19577
19578 2001-05-24  Jim Meyering  <meyering@lucent.com>
19579
19580         * lib/argmatch.c: Include "quote.h".
19581         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
19582         quote function.  Reported by Göran Uddeborg.
19583
19584 2001-05-22  Jim Meyering  <meyering@lucent.com>
19585
19586         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
19587         now that we use the package-supplied version unconditionally.
19588         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
19589
19590 2001-05-21  Jim Meyering  <meyering@lucent.com>
19591
19592         * m4/regex.m4: Change a couple backticks to single quotes to avoid
19593         shell syntax errors.
19594
19595 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
19596
19597         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
19598
19599 2001-05-20  Paul Eggert  <eggert@twinsun.com>
19600
19601         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
19602         Don't bother to check library strftime, since
19603         we'll be using our own my_strftime function anyway.
19604         Define my_strftime instead of strftime.
19605
19606 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
19607
19608         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
19609         which is not yet declared.
19610
19611 2001-05-15  Jim Meyering  <meyering@lucent.com>
19612
19613         * m4/regex.m4: Use proper quoting so brackets appear in the test
19614         program.
19615         Reported by, and with help from, Bruno Haible.
19616
19617 2001-05-13  Jim Meyering  <meyering@lucent.com>
19618
19619         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
19620         undefined.
19621
19622 2001-05-11  Paul Eggert  <eggert@twinsun.com>
19623
19624         dirname code cleanup.  base_name now behaves more compatibly
19625         with POSIX basename when given file names that have trailing
19626         slashes, and similarly for dir_name.  Add new primitives
19627         base_len and dir_len.  Put the directory-name-related decls
19628         into dirname.h.
19629
19630         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
19631         * lib/backupfile.c (base_name): Likewise.
19632         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
19633         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
19634         * lib/makepath.c (strip_trailing_slashes): Likewise.
19635         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
19636         ISSLASH): Likewise.
19637         * lib/rename.c (strip_trailing_slashes): Likewise.
19638         * lib/same.c (base_name): Likewise.
19639         * lib/stripslash.c (ISSLASH): Likewise.
19640
19641         * lib/addext.c: Include <dirname.h> after size_t is defined.
19642         * lib/backupfile.c: Likewise.
19643
19644         * lib/addext.c (addext): Use base_len to trim redundant
19645         trailing slashes instead of doing it ourselves.
19646         But do not trim the last slash if it is not redundant.
19647
19648         * lib/backupfile.c (find_backup_file_name,
19649         max_backup_version): Use base_len instead of rolling it ourselves.
19650         Handle the case of "" and (on DOS) "C:" correctly.
19651
19652         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
19653         needed. Include <string.h>, <dirname.h>.
19654         (base_name): Allow file names ending in slashes, other than names
19655         that are all slashes.  In this case, return the basename followed
19656         by the slashes.  This is more general, and can be used in places
19657         where the original base_name purposely had an assertion failure.
19658         (base_len): New function.
19659
19660         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
19661         Do not include <assert.h>; no longer needed.
19662         Include xalloc.h.
19663         (memrchr): Remove decl.
19664         (dir_name_r): Remove.
19665         (dir_len): Renamed from dirlen.  All callers changed.
19666         Rewrite in terms of base_name, for simplicity and consistency.
19667         (dir_name): Never return NULL.  All callers changed.
19668         Do not include <stdlib.h> in test program; no longer needed.
19669         return 0; is fine for test program.
19670
19671         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
19672         New macros.
19673         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
19674
19675         * lib/path-concat.c (path_concat): Use base_len to compute
19676         base length, not strlen; this means we cannot rely on memcpy
19677         to null-terminate.
19678
19679         * lib/same.c (STREQ): Remove.
19680         (same_name): Handle the case where the basename ends in trailing '/'.
19681
19682         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
19683         a slash was stripped.  Do not strip the last slash after a
19684         file system prefix.
19685
19686 2001-05-11  Paul Eggert  <eggert@twinsun.com>
19687
19688         * lib/Makefile.am (libfetish_a_SOURCES):
19689         Add strftime.c, since we now compile it on all hosts.
19690
19691         * lib/strftime.c (my_strftime):
19692         Define to nstrftime if emacs, but only if my_strftime is not defined.
19693         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
19694         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
19695         Add one more extra argument: a nanoseconds value.
19696         All uses changed.
19697         (ns): New macro.
19698         (my_strftime function): Add %N format.
19699         (emacs_strftimeu): Renamed from emacs_strftime,
19700         with extra ut argument.
19701
19702 2001-05-09  Paul Eggert  <eggert@twinsun.com>
19703
19704         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
19705
19706 2001-04-21  Jim Meyering  <meyering@lucent.com>
19707
19708         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
19709         doesn't interfere.
19710
19711 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
19712
19713         * m4/ftruncate.m4: Check for chsize.
19714         Link with ftruncate.o unconditionally if ftruncate is missing.
19715         This was required when cross-compiling to i586-mingw32msvc.
19716
19717 2001-04-08  Jim Meyering  <meyering@lucent.com>
19718
19719         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
19720         recomputed; that's necessary when the offset spans a DST transition.
19721         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
19722
19723 2001-04-02  Jim Meyering  <meyering@lucent.com>
19724
19725         * lib/regex.h, regex.c: Update from GNU libc.
19726
19727 2001-03-24  Jim Meyering  <meyering@lucent.com>
19728
19729         * m4/jm-macros.m4: Require autoconf-2.49d.
19730
19731 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
19732
19733         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
19734
19735 2001-03-19  Paul Eggert  <eggert@twinsun.com>
19736
19737         * lib/version-etc.c (version_etc_copyright): Update to 2001.
19738
19739 2001-03-17  Jim Meyering  <meyering@lucent.com>
19740
19741         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
19742         now that the version in autoconf is equivalent.
19743         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
19744
19745         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
19746         Suggestion from Akim Demaille.
19747
19748         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
19749         (jm_PREREQ_TEMPNAME): New function.
19750
19751 2001-03-16  Paul Eggert  <eggert@twinsun.com>
19752
19753         * lib/tempname.c (uint64_t): Define to uintmax_t if
19754         not defined, and if UINT64_MAX is not defined.
19755         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
19756         Reported by John David Anglin.
19757
19758 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
19759
19760         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
19761         resolve alias if codeset is empty.
19762         * lib/config.charset (BeOS): Use wildcard syntax.
19763
19764 2001-03-13  Jim Meyering  <meyering@lucent.com>
19765
19766         * lib/path-concat.c (path_concat)
19767         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
19768         concatenating e.g., `C:' and `foo'.
19769         From Bruno Haible.
19770
19771 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
19772
19773         * lib/localcharset.c (locale_charset): Don't use
19774         setlocale(LC_CTYPE,NULL). Don't return NULL.
19775         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
19776
19777 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
19778
19779         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
19780         support for DOS/DJGPP.
19781
19782 2001-03-01  Paul Eggert  <eggert@twinsun.com>
19783
19784         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
19785         lacks mkstemp.  Compile our own tempname.c if we compile our own
19786         mkstemp.c, as mkstemp relies on tempname.
19787
19788 2001-03-01  Jim Meyering  <meyering@lucent.com>
19789
19790         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
19791         AH_VERBATIM really does output its argument verbatim.
19792
19793 2001-02-28  Paul Eggert  <eggert@twinsun.com>
19794
19795         * lib/Makefile.am (libfetish_a_SOURCES):
19796         Add dup-safer.c, fopen-safer.c.
19797         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
19798
19799         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h,
19800         lib/unistd-safer.h: New files.
19801
19802 2001-02-25  Paul Eggert  <eggert@twinsun.com>
19803
19804         The mkstemp replacement is taken from glibc 2.2.2, with some
19805         portability fixes for use outside glibc, as follows:
19806
19807         * lib/tempname.c (struct_stat64): New macro.
19808         (direxists, __gen_tempname): Use it.
19809         This avoids a portability problem with Solaris 8.
19810
19811         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
19812         (<stddef.h>, <stdint.h>, <string.h>):
19813         Include only if STDC_HEADERS || _LIBC.
19814         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
19815         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
19816         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
19817         (__set_errno): Define this macro if <errno.h> doesn't.
19818         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
19819         Define these macros if <stdio.h> doesn't.
19820         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
19821         Define these macros if <sys/stat.h>
19822         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
19823         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
19824         __xstat64): Define if not _LIBC.
19825         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
19826         (__gen_tempname): Invoke gettimeofday only if
19827         HAVE_GETTIMEOFDAY || _LIBC;
19828         otherwise, fall back on plain "time".
19829         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
19830
19831         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
19832
19833         * lib/mkstemp.c, tempname.c: New files, taken from glibc 2.2.2.
19834
19835 2001-02-18  Paul Eggert  <eggert@twinsun.com>
19836
19837         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
19838
19839 2001-02-17  Paul Eggert  <eggert@twinsun.com>
19840
19841         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
19842         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
19843         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
19844         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
19845
19846 2001-02-17  Paul Eggert  <eggert@twinsun.com>
19847
19848         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
19849         Remove workaround macros for hosts that have mbrtowc but not
19850         mbstate_t, as we now insist on proper declarations for both
19851         before using mbrtowc.
19852
19853 2001-02-17  Jim Meyering  <meyering@lucent.com>
19854
19855         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
19856         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
19857         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
19858         UnixWare 7.1.1.
19859
19860         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
19861         rather than AC_CACHE_VAL.
19862
19863 2001-02-17  Jim Meyering  <meyering@lucent.com>
19864
19865         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
19866         around included file name.
19867
19868         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
19869
19870         * lib/strftime.c: Update from GNU libc (the only changes were to
19871         comments).
19872
19873 2001-02-17  Jim Meyering  <meyering@lucent.com>
19874
19875         * lib/regex.c: Update from libc.
19876
19877 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
19878
19879         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
19880         clash.
19881
19882 2001-02-16  Paul Eggert  <eggert@twinsun.com>
19883
19884         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
19885         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
19886         Reported by Mark Hounschell via Paul Eggert.
19887
19888 2001-02-07  Jim Meyering  <meyering@lucent.com>
19889
19890         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
19891
19892 2001-02-05  Jim Meyering  <meyering@lucent.com>
19893
19894         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
19895         it includes the patch required for `large file' support with at least
19896         HP-UX's 10.20 /bin/cc.
19897
19898 2001-02-03  Jim Meyering  <meyering@lucent.com>
19899
19900         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
19901         AS_IF, now that it works once again (mysteriously).
19902         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
19903
19904 2001-01-30  Jim Meyering  <meyering@lucent.com>
19905
19906         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
19907         * m4/chown.m4: Rename conftestchown to conftest.chown.
19908         * m4/rename.m4: s/conftestdir/conftest.d1/ and
19909         s/conftestdir2/conftest.d2/.
19910         * m4/utimes.m4: s/conftestdata/conftest.data/
19911         Inspired by Pavel Roskin's change in autoconf.
19912
19913 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
19914
19915         * lib/config.charset: Update for FreeBSD 4.2.
19916
19917 2001-01-27  Jim Meyering  <meyering@lucent.com>
19918
19919         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
19920         a use of AS_IF.
19921         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
19922
19923 2001-01-26  Jim Meyering  <meyering@lucent.com>
19924
19925         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
19926         quotearg.c includes it.
19927
19928 2001-01-26  Jim Meyering  <meyering@lucent.com>
19929
19930         * lib/quotearg.c: Include stddef.h.
19931         * lib/quote.c: Include stddef.h.
19932         Reported by Axel Kittenberger.
19933
19934         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
19935         line in double quotes so that it evokes a better diagnostic.
19936         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
19937         Reported by Axel Kittenberger.
19938
19939 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
19940
19941         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
19942         as if it was a `charset'.
19943
19944 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
19945
19946         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
19947         has const.
19948
19949 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
19950
19951         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
19952         to avoid a warning.  Add back 'const' to inptr.
19953
19954 2001-01-20  Jim Meyering  <meyering@lucent.com>
19955
19956         Be sure that headers are checked before used in code compiled
19957         for the type checks.
19958         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
19959         In place of that, invoke jm_CHECK_ALL_TYPES.
19960         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
19961         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
19962         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
19963         The check for ssize_t was mistakenly run before the test for unistd.h.
19964
19965         The configure-time check for stdbool.h was missing.
19966         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
19967         (jm_PREREQ_HASH): New function.
19968
19969 2001-01-17  Jim Meyering  <meyering@lucent.com>
19970
19971         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
19972         for autoconf-2.49c.
19973         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
19974
19975 2001-01-16  Jim Meyering  <meyering@lucent.com>
19976
19977         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
19978         From Bruno Haible.
19979
19980 2001-01-14  Jim Meyering  <meyering@lucent.com>
19981
19982         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
19983         foo and bar.  Create conftestdir/ in the script, not in the C code.
19984         Remove directories in the script, not in the C code.
19985         Remove conftestdir{,2} before trying to create the directory.
19986         Make the entire configure script fail if the mkdir fails.
19987
19988 2001-01-14  Jim Meyering  <meyering@lucent.com>
19989
19990         * lib/rename.c: New file.  From Volker Borchert.
19991         Include stdlib.h, string.h or strings.h, and xalloc.h.
19992         Use strip_trailing_slashes rather than open-coding it.
19993
19994 2001-01-03  Paul Eggert  <eggert@twinsun.com>
19995
19996         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
19997
19998 2001-01-03  Jim Meyering  <meyering@lucent.com>
19999
20000         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
20001         of local `inptr' to avoid warning with some system declarations of
20002         iconv.
20003
20004 2001-01-02  Volker Borchert  <bt@teknon.de>
20005
20006         * m4/rename.m4: New file.
20007         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
20008
20009 2001-01-01  Jim Meyering  <meyering@lucent.com>
20010
20011         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
20012         even on systems with utmpx.h.  It's necessary for the declaration of
20013         utmp's ut_user member.  Reported by Andreas Jaeger.
20014
20015         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
20016         available. They are required for the declarations of getgrgid and
20017         getpwuid resp.
20018         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
20019         Reported by Andreas Jaeger.
20020
20021 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
20022
20023         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
20024         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
20025         so `make install' also works in VPATH builds.
20026
20027 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
20028
20029         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
20030         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
20031         can be used in subdirectories.
20032
20033 2000-12-29  Paul Eggert  <eggert@twinsun.com>
20034
20035         * lib/modechange.c: Do not assume that mode_t uses the
20036         traditional octal encoding.  E.g. "chmod 1 FOO" should set
20037         the other-execute bit of FOO even if S_IXOTH != 1.
20038
20039         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
20040         WOTH, XOTH, ALLM): New macros.
20041         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
20042          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
20043         Use them.
20044         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
20045         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
20046         (mode_compile):
20047         No need to use uintmax_t; unsigned long is long enough.
20048         Don't bother to get suffix since we don't use it.
20049
20050 2000-12-26  Jim Meyering  <meyering@lucent.com>
20051
20052         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
20053         better with autoheader.
20054
20055 2000-12-24  Jim Meyering  <meyering@lucent.com>
20056
20057         * lib/hash.c (is_prime): Return explicit boolean values.
20058         (hash_get_first): Return NULL to appease Irix5.6's 89.
20059         Reported by Nelson Beebe.
20060
20061 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
20062
20063         * lib/localcharset.c (locale_charset): Add support for Win32.
20064
20065 2000-12-18  Paul Eggert  <eggert@twinsun.com>
20066
20067         * lib/physmem.h, physmem.c: New files.
20068
20069         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
20070         (noinst_HEADERS): Add physmem.h.
20071
20072         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
20073         't' for compatibility with Solaris 8 sort.
20074
20075 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
20076
20077         * lib/config.charset: Add support for BeOS.
20078
20079 2000-12-17  Jim Meyering  <meyering@lucent.com>
20080
20081         * m4/dos.m4 (jm_AC_DOS): New file and macro.
20082         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
20083
20084 2000-12-16  Jim Meyering  <meyering@lucent.com>
20085
20086         This bug had a serious impact on chown: `chown N:M FILE' (for integer
20087         N and M) would have treated it like `chown N:N FILE'.
20088
20089         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
20090
20091 2000-12-16  Jim Meyering  <meyering@lucent.com>
20092
20093         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
20094         SHELLS_FILE to a file name that's useful on djgpp systems.
20095         Include stdlib.h.
20096         (ADDITIONAL_DEFAULT_SHELLS): Define.
20097         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
20098         Based mostly on a patch from Prashant TR.
20099
20100 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
20101
20102         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
20103         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
20104         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
20105
20106 2000-12-08  Andreas Schwab  <schwab@suse.de>
20107
20108         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
20109         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
20110
20111 2000-12-07  Jim Meyering  <meyering@lucent.com>
20112
20113         * lib/stripslash.c (ISSLASH): Define.
20114         (strip_trailing_slashes): Use ISSLASH rather than comparing against
20115         `/'.
20116         From Prashant TR.
20117
20118         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
20119         (dir_name_r): Declare this function as static.
20120         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
20121         manifest itself on a name containing a mix of slashes and
20122         backslashes.
20123         Make this function work with names starting with a DOS-style
20124         drive letter and colon prefix.
20125         (dir_name): Append `.' if necessary.
20126         Based mostly on patches from Prashant TR and Eli Zaretskii.
20127
20128         * lib/dirname.h (dir_name_r): Remove prototype.
20129
20130 2000-12-06  Paul Eggert  <eggert@twinsun.com>
20131
20132         * m4/off_t-format.m4: Remove this file.
20133         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
20134
20135 2000-12-06  Jim Meyering  <meyering@lucent.com>
20136
20137         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
20138         replacement strtoull, we may well need the replacement strtoul, too.
20139         Check for declarations of strtoul and strtoull.
20140         Check for strtol.  Mainly as a cue to cause automake to include
20141         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
20142         Check for limits.h -- strtol.c needs it.
20143
20144 2000-12-05  Jim Meyering  <meyering@lucent.com>
20145
20146         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
20147
20148 2000-12-04  Jim Meyering  <meyering@lucent.com>
20149
20150         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
20151         Also include memory.h, stdlib.h, unistd.h if appropriate.
20152         Reported by Andreas Jaeger (conflicting declaration of malloc).
20153
20154 2000-12-02  Jim Meyering  <meyering@lucent.com>
20155
20156         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
20157         * m4/jm-macros.m4 (jm_MACROS): require it.
20158
20159 2000-12-02  Jim Meyering  <meyering@lucent.com>
20160
20161         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
20162
20163 2000-12-01  Paul Eggert  <eggert@twinsun.com>
20164
20165         * lib/memrchr.c: Include <config.h> before any system include file.
20166
20167 2000-11-30  Jim Meyering  <meyering@lucent.com>
20168
20169         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
20170
20171 2000-11-30  Jim Meyering  <meyering@lucent.com>
20172
20173         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
20174
20175 2000-11-29  Paul Eggert  <eggert@twinsun.com>
20176
20177         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
20178
20179 2000-11-26  Jim Meyering  <meyering@lucent.com>
20180
20181         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
20182
20183 2000-11-22  Paul Eggert  <eggert@twinsun.com>
20184
20185         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
20186         size of (size_t) -1; it's not portable.
20187
20188 2000-11-17  Jim Meyering  <meyering@lucent.com>
20189
20190         * lib/strstr.c: Update from GNU libc.
20191
20192 2000-11-17  Akim Demaille  <akim@epita.fr>
20193
20194         * lib/obstack.h: Formatting changes.
20195         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
20196         prevent type checking.
20197         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
20198         cast the value to (void *): assigning a `foo *' to a `void *'
20199         variable is valid.
20200         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
20201
20202 2000-11-16  Jim Meyering  <meyering@lucent.com>
20203
20204         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
20205
20206 2000-11-11  Jim Meyering  <meyering@lucent.com>
20207
20208         * lib/error.c: Add a couple #includes, merging from GNU libc version.
20209
20210 2000-11-10  Jim Meyering  <meyering@lucent.com>
20211
20212         * lib/obstack.h: Update from GNU libc.
20213         * lib/obstack.c: Likewise.
20214
20215 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
20216
20217         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
20218
20219 2000-11-06  Paul Eggert  <eggert@twinsun.com>
20220
20221         * lib/getusershell.c (setusershell): Use rewind rather than
20222         fseek/fseeko, to avoid configuration hassles with fseeko.
20223         Don't bother opening SHELLS_FILE if shellstream is NULL;
20224         it's not necessary.
20225
20226 2000-11-05  Jim Meyering  <meyering@lucent.com>
20227
20228         * lib/makepath.h (make_dir): Declare.
20229         * lib/makepath.c (make_dir): Remove `static' attribute.
20230         Tweak a comment.
20231
20232 2000-11-04  Jim Meyering  <meyering@lucent.com>
20233
20234         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
20235
20236 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
20237
20238         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
20239         last one in a bucket, advance to the next bucket.
20240
20241 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
20242
20243         * lib/fnmatch.c: Do not comment out all the code if we are using
20244         the GNU C library, because in some cases we are replacing buggy
20245         code in the GNU C library itself.
20246
20247 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
20248
20249         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
20250         (regex_compile): Catch bogus \(\1\).
20251
20252 2000-10-30  Paul Eggert  <eggert@twinsun.com>
20253
20254         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
20255         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
20256         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
20257
20258 2000-10-30  Paul Eggert  <eggert@twinsun.com>
20259
20260         * lib/error.h, getline.h, modechange.h:
20261         Remove "2000" from Copyright line, as the file hasn't been
20262         changed this year other than in the copyright notice.
20263
20264         * lib/xalloc.h: Add "2000" to Copyright line, as this file
20265         was changed this year.
20266
20267 2000-10-29  Jim Meyering  <meyering@lucent.com>
20268
20269         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
20270         renaming.
20271         * m4/ls-mntd-fs.m4: Likewise
20272
20273 2000-10-29  Jim Meyering  <meyering@lucent.com>
20274
20275         * lib/xstat.in: Fix grammar in comment.
20276
20277 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
20278
20279         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
20280         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
20281         doesn't define __restrict_arr.
20282
20283 2000-10-28  Jim Meyering  <meyering@lucent.com>
20284
20285         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
20286         (jm_PREREQ_MEMCHR): New function.
20287
20288 2000-10-28  Jim Meyering  <meyering@lucent.com>
20289
20290         * lib/memchr.c: Update from libc.
20291         Adjust for portability:
20292         [HAVE_STDLIB_H]: Include stdlib.h.
20293         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
20294         Undef __memchr, too.
20295         [!weak_alias]: Define __memchr to memchr.
20296
20297         * lib/regex.c: Update from libc.
20298         * lib/regex.h: Likewise.
20299         * lib/getopt1.c: Likewise.
20300         * lib/memcmp.c: Likewise.
20301
20302         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
20303         Avoid using fseek, when possible -- it's broken by design.
20304         Patch by Ulrich Drepper.
20305
20306 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
20307
20308         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
20309         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
20310         Giving in to popular pressure to shut up the compiler with casts.
20311
20312 2000-10-26  Jim Meyering  <meyering@lucent.com>
20313
20314         * lib/strftime.c: Update from libc.
20315
20316 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
20317
20318         * regex.c: More `unsigned char' -> `re_char' changes.
20319         Also change several `int' into `re_wchar_t'.
20320         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
20321         (PUSH_FAILURE_POINTER): Don't cast any more.
20322         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
20323         We want GCC to complain, since this piece of code makes
20324         re_match non-reentrant, which *should* be fixed.
20325         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
20326         (EXTEND_BUFFER): Use RETALLOC.
20327         (SET_LIST_BIT): Don't cast.
20328         (re_wchar_t): New type.
20329         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
20330         that those two functions will always properly return.
20331         (IMMEDIATE_QUIT_CHECK): Cast to void.
20332         (analyse_first): Use recursion rather than an explicit stack.
20333         (re_compile_fastmap): Can't fail anymore.
20334         (re_search_2): Don't check re_compile_fastmap for failure.
20335         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
20336         Now also sets the new value (passed in a new argument).
20337         (re_match_2_internal): Use it.
20338         Also, use a new var `reg' of type size_t when looping through regs
20339         rather than reuse the inappropriate `mcnt'.
20340
20341 2000-10-25  Jim Meyering  <meyering@lucent.com>
20342
20343         * lib/obstack.c: Update from libc.
20344
20345 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
20346
20347         * regex.c (regex_compile): Change the way of handling a range from
20348         a char less than 256 to a char not less than 256.
20349
20350 2000-10-24  Andrew Innes  <andrewi@gnu.org>
20351
20352         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
20353         NT-Emacs only.
20354         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
20355         so that re_search functions only quit when callers expect them to.
20356
20357 2000-10-23  Jim Meyering  <meyering@lucent.com>
20358
20359         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
20360         wrong.  That set_locale call must not have any side effects.
20361         From Paul Eggert.
20362
20363 2000-10-22  Jim Meyering  <meyering@lucent.com>
20364
20365         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
20366         [CYCLIC]: Remove now-unused definition.
20367
20368         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
20369         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
20370         Suggestion from Ulrich Drepper.
20371
20372 2000-10-21  Jim Meyering  <meyering@lucent.com>
20373
20374         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
20375         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
20376         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
20377
20378 2000-10-21  Jim Meyering  <meyering@lucent.com>
20379
20380         * lib/dirname.c (memrchr): Declare if necessary.
20381         (dir_name): Remove the restriction that there be no
20382         trailing slashes.  Now, this code skips past them, effectively
20383         ignoring them.
20384         [TEST_DIRNAME] (main): New unit tests.
20385
20386         * lib/memrchr.c: New file from GNU libc.
20387         Undef __memrchr, too.
20388         [!weak_alias]: Define __memrchr to memrchr.
20389         Guard weak_alias use with `#ifdef weak_alias'.
20390
20391 2000-10-21  Jim Meyering  <meyering@lucent.com>
20392
20393         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
20394         (dir_name): Use dir_name_r.
20395         * lib/dirname.h (dir_name_r): Declare it.
20396
20397 2000-10-17  Jim Meyering  <meyering@lucent.com>
20398
20399         * lib/quote.h (PARAMS): Define and use.
20400         Reported by Akim Demaille.
20401
20402         * lib/getopt.c: Update from libc.
20403
20404 2000-10-16  Jim Meyering  <meyering@lucent.com>
20405
20406         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
20407         setlocale.
20408         From Jan Fedak.
20409
20410 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
20411
20412         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
20413
20414 2000-09-25  Jim Meyering  <meyering@lucent.com>
20415
20416         * lib/md5.h (rol): Define (from GnuPG).
20417
20418         * lib/sha.c: Give credit (GnuPG) where due.
20419         (M): Use rol rather than open-coding it.
20420         Add a FIXME comment.
20421
20422 2000-09-21  Jim Meyering  <meyering@lucent.com>
20423
20424         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
20425         Reported by Michael Stone.
20426
20427 2000-09-20  Jim Meyering  <meyering@lucent.com>
20428
20429         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
20430         (noinst_HEADERS): Add sha.h.
20431         Based on code from Scott G. Miller and from GnuPG.
20432
20433 2000-09-18  Jim Meyering  <meyering@lucent.com>
20434
20435         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
20436         LIBS. Otherwise, everyone ends up linking with -lelf for some
20437         configurations.
20438         Reported by Mike Stone.
20439
20440 2000-09-15  Jim Meyering  <meyering@lucent.com>
20441
20442         * lib/regex.c: Update from libc.
20443
20444 2000-09-10  Jim Meyering  <meyering@lucent.com>
20445
20446         * lib/getopt.c (_getopt_internal): Update from glibc.
20447
20448 2000-09-09  Jim Meyering  <meyering@lucent.com>
20449
20450         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
20451         think it should be used as a general replacement for isascii.
20452         * lib/fnmatch.c: Likewise.
20453         * lib/mbswidth.c: Likewise
20454         * lib/regex.c: Likewise.
20455
20456         Don't use atoi.
20457         * lib/userspec.c: Include sys/param.h and limits.h.
20458         Include xstrtol.h.
20459         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20460         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
20461         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
20462         UID, GID.  Check range.
20463
20464 2000-09-06  Jim Meyering  <meyering@lucent.com>
20465
20466         * lib/getopt.c (_getopt_internal): Update from glibc.
20467
20468 2000-08-30  Jim Meyering  <meyering@lucent.com>
20469
20470         * lib/strftime.c: Merge in changes from GNU libc.
20471
20472 2000-08-26  Jim Meyering  <meyering@lucent.com>
20473
20474         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
20475         * m4/fpending.m4: New file.
20476
20477 2000-08-26  Jim Meyering  <meyering@lucent.com>
20478
20479         * lib/closeout.c: Include "__fpending.h".
20480         (close_stdout_status): Return right away if there's nothing to flush.
20481
20482         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
20483         * lib/__fpending.c: New file.
20484         * lib/__fpending.h: New file.
20485
20486 2000-08-20  Jim Meyering  <meyering@lucent.com>
20487
20488         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
20489         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
20490         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
20491
20492 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
20493
20494         Improve fileutils installation on systems where running
20495         programs (like install) can't be unlinked.
20496         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
20497         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
20498
20499 2000-08-07  Paul Eggert  <eggert@twinsun.com>
20500
20501         Standardize on "memory exhausted" instead of "Memory exhausted"
20502         or "virtual memory exhausted".
20503         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
20504         "virtual memory exhausted".
20505         * lib/same.c (same_name): Invoke xalloc_die instead of printing
20506         our own message.
20507         * lib/userspec.c (parse_user_spec): Likewise.
20508         * lib/bumpalloc.h: comment fix
20509         * lib/same.c, userspec.c: Include xalloc.h.
20510
20511         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
20512         not char *const and pointing to a constant array.
20513         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
20514         (xrealloc): Comment fix.
20515
20516         * lib/userspec.c (parse_user_spec):
20517         Don't translate a message until just before returning,
20518         to avoid unnecessary translation.
20519
20520 2000-08-07  Jim Meyering  <meyering@lucent.com>
20521
20522         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
20523         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
20524         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
20525         getgroups.c, gethostname.c, getopt.h, group-member.c,
20526         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
20527         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
20528         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
20529         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
20530         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
20531         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
20532         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
20533         yesno.c: Back out Copyright date changes for each file with no change
20534         this year.  This eases coordination with other programs using the same
20535         source code modules.  From Paul Eggert.
20536
20537 2000-08-06  Paul Eggert  <eggert@twinsun.com>
20538
20539         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
20540         not char, for compatibility with glibc 2.1.3 strftime.c.
20541
20542 2000-08-03  Greg McGary  <greg@mcgary.org>
20543
20544         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
20545         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
20546         (EXTEND_BUFFER): Use them.
20547
20548 2000-08-01  Jim Meyering  <meyering@lucent.com>
20549
20550         * lib/dirname.c (ISSLASH): Define.
20551         (BACKSLASH_IS_PATH_SEPARATOR): Define.
20552         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
20553         both `\' and `/' may be use as path separators.
20554         Based on a patch from Prashant TR.
20555
20556 2000-07-31  Paul Eggert  <eggert@twinsun.com>
20557
20558         * lib/quotearg.c (quotearg_n_options): Don't make the initial
20559         slot vector a constant, since it might get modified.
20560
20561 2000-07-31  Jim Meyering  <meyering@lucent.com>
20562
20563         * lib/xmalloc.c: Use `virtual memory exhausted', not
20564         `Memory exhausted'.
20565         * lib/obstack.c (print_and_abort): Likewise.
20566
20567 2000-07-30  Paul Eggert  <eggert@twinsun.com>
20568
20569         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
20570         buffer, so that the caller can always quote one small
20571         component of a "memory exhausted" message in slot 0.
20572         From a suggestion by Jim Meyering.
20573
20574 2000-07-30  Jim Meyering  <meyering@lucent.com>
20575
20576         * lib/makepath.c (make_path): Quote the other instance, too.
20577
20578         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
20579         (STATIC_BUF_SIZE): Define.
20580         (quotearg_n_options): Use only statically allocated storage when
20581         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
20582         than STATIC_BUF_SIZE.
20583
20584 2000-07-29  Jim Meyering  <meyering@lucent.com>
20585
20586         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
20587         * lib/dirname.c (dir_name): Likewise.
20588
20589         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
20590         `/'.
20591
20592         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
20593         (dir_name): Assert that there are no trailing slashes.
20594
20595 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
20596
20597         * lib/mbswidth.h (mbswidth): Add a flags argument.
20598         (mbswidth): New declaration.
20599         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
20600         * lib/mbswidth.c (mbswidth): Add a flags argument.
20601         (mbsnwidth): New function.
20602
20603 2000-07-24  Jim Meyering  <meyering@lucent.com>
20604
20605         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
20606
20607 2000-07-23  Paul Eggert  <eggert@twinsun.com>
20608
20609         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
20610
20611 2000-07-23  Paul Eggert  <eggert@twinsun.com>
20612
20613         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
20614         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
20615         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
20616         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
20617         invoke multibyte primitives.
20618
20619 2000-07-23  Paul Eggert  <eggert@twinsun.com>
20620
20621         * lib/quotearg.c:
20622         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
20623         so that mbstate_t is always defined.
20624
20625         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
20626         be 1 in at least one GCC installation, and this configuration
20627         error is likely to be common.  Ignoring MB_LEN_MAX hurts
20628         performance on hosts that have mbrtowc but have only unibyte
20629         locales, but I assume these hosts are rare.
20630
20631 2000-07-23  Paul Eggert  <eggert@twinsun.com>
20632
20633         * lib/mbswidth.c (_XOPEN_SOURCE):
20634         Don't define; this causes problems on Solaris 7.
20635         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
20636
20637 2000-07-23  Jim Meyering  <meyering@lucent.com>
20638
20639         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
20640         too: getgrgid, getpwuid, getuid.
20641
20642 2000-07-23  Jim Meyering  <meyering@lucent.com>
20643
20644         * lib/basename.c (base_name): Add an assertion.
20645
20646 2000-07-23  Bruno Haible  <clisp.cons.org>
20647
20648         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
20649         shadow its mbsinit function.
20650
20651 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
20652
20653         * lib/mbswidth.h: New file.
20654         * lib/mbswidth.c: New file.
20655         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
20656         (noinst_HEADERS): Add mbswidth.h.
20657
20658 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
20659
20660         * lib/config.charset: Add support for FreeBSD. Improve support for
20661         HP-UX and IRIX 6.
20662
20663 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
20664
20665         * m4/mbswidth.m4: New file.
20666         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
20667
20668 2000-07-15  Jim Meyering  <meyering@lucent.com>
20669
20670         * lib/makepath.c: Include quote.h.
20671         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
20672         corresponding argument in a `quote (...)' call.
20673         Give better diagnostics.
20674
20675         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
20676         (noinst_HEADERS): Add quote.h.
20677
20678         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
20679         from tar's src/misc.c.
20680         * lib/quote.h: New file.  Prototypes for same.
20681
20682 2000-07-14  Paul Eggert  <eggert@twinsun.com>
20683
20684         From a suggestion by Bruno Haible.
20685         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
20686         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
20687         to decide whether to define the BeOS workaround macro;
20688         this adjusts to the change to AC_MBSTATE_T.
20689
20690 2000-07-14  Jim Meyering  <meyering@lucent.com>
20691
20692         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
20693         jm_AC_TYPE_UINTMAX_T.
20694
20695 2000-07-13  Paul Eggert  <eggert@twinsun.com>
20696
20697         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
20698
20699         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
20700         quotearg_buffer_restyled): Add support for
20701         clocale_quoting_style.  Undo previous change to
20702         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
20703         and "{RIGHT QUOTATION MARK}" msgids.
20704
20705 2000-07-10  Paul Eggert  <eggert@twinsun.com>
20706
20707         From a suggestion by Bruno Haible.
20708         * m4/mbstate_t.m4 (AC_MBSTATE_T):
20709         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
20710         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
20711         and mbstate_t, to a single-part test that simply defines mbstate_t.
20712         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
20713         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
20714
20715 2000-07-10  Jim Meyering  <meyering@lucent.com>
20716
20717         * m4/strerror_r.m4: Mirror the correction made in autoconf.
20718
20719         * m4/gnu-source.m4: Output to confdefs.h directly.
20720         Suggestion from Akim Demaille.
20721
20722 2000-07-09  Paul Eggert  <eggert@twinsun.com>
20723
20724         The old behavior of quoting `like this' doesn't look good with
20725         newer, ISO-style fonts.  See:
20726         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
20727
20728         Instead, quote "like this" by default.  Let the translator
20729         tailor the locale-specific quoting behavior by providing
20730         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
20731
20732         * lib/quotearg.c (N_): New macro.
20733         (gettext_default): New function.
20734         (quotearg_buffer_restyled): Use
20735         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
20736         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
20737
20738 2000-07-09  Jim Meyering  <meyering@lucent.com>
20739
20740         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
20741         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
20742
20743         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
20744         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
20745
20746 2000-07-09  Jim Meyering  <meyering@lucent.com>
20747
20748         * lib/Most files: Update copyright dates to include 2000.
20749
20750 2000-07-08  Jim Meyering  <meyering@lucent.com>
20751
20752         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
20753         if not defined.
20754         (xgethostname): Remove now-unnecessary #ifdef.
20755         Move declaration of `err' into loop where it's used.
20756
20757 2000-07-05  Paul Eggert  <eggert@twinsun.com>
20758         and Bruno Haible  <haible@clisp.cons.org>
20759
20760         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
20761         only if the test for an object-type mbstate_t fails.  This
20762         prevents us from mistakenly reporting that mbstate_t is a
20763         system object type after we "#define mbstate_t int" to work
20764         around its lack.
20765
20766 2000-07-05  Paul Eggert  <eggert@twinsun.com>
20767         and Bruno Haible  <haible@clisp.cons.org>
20768
20769         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
20770
20771 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
20772
20773         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
20774         to strerror_r.
20775         Include <ctype.h> for use of isalpha.
20776
20777 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
20778
20779         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
20780         by allocating a larger buffer. Test the gethostname return value for
20781         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
20782         returns an error and ENAMETOOLONG isn't defined.
20783
20784 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
20785
20786         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
20787         dimension.
20788
20789 2000-07-04  Jim Meyering  <meyering@lucent.com>
20790
20791         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
20792         of the deprecated AC_CHECKING.
20793
20794 2000-07-04  Jim Meyering  <meyering@lucent.com>
20795
20796         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
20797         Reported by Bruno Haible.
20798
20799 2000-07-04  Jim Meyering  <meyering@lucent.com>
20800
20801         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
20802         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
20803         lacks mbrtowc.
20804
20805 2000-07-03  Paul Eggert  <eggert@twinsun.com>
20806
20807         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
20808         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
20809
20810 2000-07-03  Paul Eggert  <eggert@twinsun.com>
20811         and Bruno Haible  <haible@clisp.cons.org>
20812
20813         * lib/quotearg.c (mbrtowc):
20814         Assign to *pwc, and return 1 only if result is nonzero.
20815         (iswprint): Use ISPRINT when substituting our own mbrtowc.
20816
20817 2000-07-03  Jim Meyering  <meyering@lucent.com>
20818
20819         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
20820
20821 2000-07-03  Jim Meyering  <meyering@lucent.com>
20822
20823         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
20824         This is necessary to get a definition of e.g., UTMP_FILE on
20825         HP-UX 10.20.
20826         From Bob Proulx.
20827
20828 2000-07-02  Jim Meyering  <meyering@lucent.com>
20829
20830         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
20831
20832         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
20833         AC_LIBOBJ(function_name).
20834         * m4/chown.m4: Likewise.
20835         * m4/fnmatch.m4: Likewise.
20836         * m4/ftruncate.m4: Likewise.
20837         * m4/getgroups.m4: Likewise.
20838         * m4/getline.m4: Likewise.
20839         * m4/group-member.m4: Likewise.
20840         * m4/jm-macros.m4: Likewise.
20841         * m4/lstat.m4: Likewise.
20842         * m4/malloc.m4: Likewise.
20843         * m4/memcmp.m4: Likewise.
20844         * m4/nanosleep.m4: Likewise.
20845         * m4/putenv.m4: Likewise.
20846         * m4/realloc.m4: Likewise.
20847         * m4/regex.m4: Likewise.
20848         * m4/stat.m4: Likewise.
20849         * m4/strftime.m4: Likewise.
20850
20851 2000-07-02  Jim Meyering  <meyering@lucent.com>
20852
20853         * lib/quotearg.c (mbstate_t): Don't define here.
20854
20855 2000-07-02  Jim Meyering  <meyering@lucent.com>
20856
20857         * lib/nanosleep.c (SIGCONT): Define if not already defined.
20858
20859 2000-07-01  Jim Meyering  <meyering@lucent.com>
20860
20861         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
20862
20863 2000-07-01  Jim Meyering  <meyering@lucent.com>
20864
20865         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
20866         problem.
20867
20868 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
20869
20870         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
20871         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
20872
20873 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
20874
20875         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
20876         per change in ../m4/ls-mntd-fs.m4.
20877         (read_filesystem_list): Ignore symbolic links.
20878
20879 2000-06-29  Jim Meyering  <meyering@lucent.com>
20880
20881         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
20882         for declaration of strcmp.
20883
20884         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
20885
20886         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
20887         Avoid warning by casting result to `char *' to remove `const'.
20888
20889 2000-06-28  Jim Meyering  <meyering@lucent.com>
20890
20891         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
20892         included by quotearg.c, for which we perform this test.  From
20893         Bruno Haible.
20894
20895 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
20896
20897         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
20898         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
20899         <utmpx.h> exists, put readutmp.o into LIBOBJS.
20900
20901 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
20902
20903         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
20904
20905 2000-06-26  Paul Eggert  <eggert@twinsun.com>
20906
20907         savedir now sets errno on failure and invokes xmalloc to get memory.
20908         Fix a couple of other minor bugs while we're at it.
20909
20910         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
20911         (NAMLEN): Remove macro.
20912         (malloc, realloc): Remove decls.
20913         (stpcpy): Likewise.
20914         ("xalloc.h"): Include.
20915         (NAME_SIZE_DEFAULT): New macro.
20916         (savedir): Use xmalloc / xrealloc to allocate memory.
20917         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
20918         Skip "" directory entries.
20919         Use strlen to calculate directory entry length, since the old method
20920         is rarely used these days and isn't worth supporting.
20921         Don't use a pointer after freeing it.
20922         Check for integer overflow when calculating allocation size.
20923         Use memcpy to copy entries, instead of stpcpy.
20924         Set errno properly when returning NULL.
20925         Check for readdir error.
20926
20927 2000-06-26  Jim Meyering  <meyering@lucent.com>
20928
20929         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
20930
20931 2000-06-25  Jim Meyering  <meyering@lucent.com>
20932
20933         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
20934         Linux header bug when _XOPEN_SOURCE is defined to 500.
20935
20936 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
20937
20938         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
20939         deficiency.
20940
20941 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
20942
20943         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
20944         Include xalloc.h.
20945         Don't include <stdlib.h>.  Don't declare malloc, realloc.
20946
20947 2000-06-24  Jim Meyering  <meyering@lucent.com>
20948
20949         * m4/strerror_r.m4: Revive this file -- to try out an experimental
20950         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
20951         for which strerror does return char*, but which lacks a conveniently
20952         accessible declaration of the function.  If the compile-test says
20953         strerror_r doesn't work, then resort to a `run'-test that works on
20954         BeOS and segfaults on DEC Unix.
20955
20956 2000-06-24  Jim Meyering  <meyering@lucent.com>
20957
20958         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
20959
20960 2000-06-23  Paul Eggert  <eggert@twinsun.com>
20961
20962         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
20963         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
20964
20965 2000-06-23  Paul Eggert  <eggert@twinsun.com>
20966
20967         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
20968         (mbrtowc, mbstate_t): Define substitutes if
20969         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
20970         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
20971         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
20972
20973 2000-06-23  Jim Meyering  <meyering@lucent.com>
20974
20975         * m4/afs.m4: Add missing AC_MSG_RESULT.
20976         Reported by Bruno Haible.
20977
20978         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
20979         Suggestion from Bruno Haible.
20980
20981 2000-06-23  Jim Meyering  <meyering@lucent.com>
20982
20983         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
20984
20985 2000-06-21  Jim Meyering  <meyering@lucent.com>
20986
20987         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
20988
20989 2000-06-21  Jim Meyering  <meyering@lucent.com>
20990
20991         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
20992         (noinst_HEADERS): Add getstr.h.
20993
20994         * lib/getline.c (getstr): Move into a separate file.
20995         * lib/getstr.c (getstr): New file, extracted from getline.c, with
20996         the following changes: new parameter, delim2; both delim[12]
20997         parameters have type `int', not `char'.  The latter would lose
20998         with 8-bit delimiters.
20999         * lib/getstr.h: New file.
21000
21001 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
21002
21003         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
21004         than 1024, return a memory chunk of least possible size, instead
21005         of size PATH_MAX + 2. In the loop, increment the size proportionally.
21006         Use free/xmalloc instead of xrealloc to avoid copying for very long
21007         paths.
21008
21009 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
21010
21011         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
21012         the empty string.
21013
21014 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
21015
21016         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
21017         address, not strdup.  Include <stdlib.h> and don't declare free().
21018
21019 2000-06-19  Jim Meyering  <meyering@lucent.com>
21020
21021         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
21022
21023 2000-06-18  Jim Meyering  <meyering@lucent.com>
21024
21025         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
21026
21027         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
21028         `checking whether...' message to be consistent with that of the
21029         lstat test.
21030
21031 2000-06-18  Jim Meyering  <meyering@lucent.com>
21032
21033         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
21034         Besides, these days every porting target provides a mkdir function.
21035
21036         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
21037         needed. (this snippet comes from src/system.h).
21038
21039 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
21040
21041         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
21042
21043 2000-06-15  Paul Eggert  <eggert@twinsun.com>
21044
21045         * lib/human.c (adjust_value): New function.
21046         (human_readable_inexact): Apply rounding style even when
21047         printing approximate values.
21048
21049 2000-06-14  Paul Eggert  <eggert@twinsun.com>
21050
21051         * lib/human.c (human_readable_inexact): Allow an input block
21052         size that is not a multiple of the output block size, and vice versa.
21053         Reported by Piergiorgio Sartor.
21054
21055 2000-06-14  Paul Eggert  <eggert@twinsun.com>
21056
21057         * lib/getdate.y (get_date): Apply relative times after time
21058         zone indicator, not before.  Reported by Todd A. Jacobs.
21059
21060 2000-06-13  Jim Meyering  <meyering@lucent.com>
21061
21062         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
21063
21064         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
21065
21066 2000-06-12  Paul Eggert  <eggert@twinsun.com>
21067
21068         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
21069
21070 2000-06-12  Jim Meyering  <meyering@lucent.com>
21071
21072         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
21073         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
21074         optional argument.
21075         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
21076         the optional argument, `lib'.
21077
21078 2000-06-08  Jim Meyering  <meyering@lucent.com>
21079
21080         * m4/largefile.m4: Remove file (now that it's part of autoconf).
21081
21082 2000-06-04  Paul Eggert  <eggert@twinsun.com>
21083
21084         Rewrite largefile configuration so that we don't need to run
21085         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
21086         AC_CANONICAL_HOST in configure.in -- jmm]
21087
21088         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
21089         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
21090         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
21091         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
21092         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
21093         All uses changed.
21094         Instead of inspecting the output of getconf, try to compile the
21095         test program without and with the macro definition.
21096         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
21097         for getconf.  Instead, check for the needed flags by compiling
21098         test programs.
21099
21100 2000-06-04  Paul Eggert  <eggert@twinsun.com>
21101
21102         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
21103
21104 2000-06-04  Jim Meyering  <meyering@lucent.com>
21105
21106         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
21107         SunOS 4.1.4 for which gid_t is an unsigned type.
21108
21109 2000-06-03  Jim Meyering  <meyering@lucent.com>
21110
21111         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
21112         now that autoconf requires that.
21113
21114         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
21115         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
21116         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
21117
21118 2000-06-03  Jim Meyering  <meyering@lucent.com>
21119
21120         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
21121
21122 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
21123
21124         * m4/glibc21.m4: New file.
21125         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
21126
21127 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
21128
21129         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
21130         newer, don't install charset.alias.
21131         * lib/config.charset: Change the Linux/glibc rules so they become empty
21132         on glibc-2.1 or newer.
21133
21134 2000-06-02  Jim Meyering  <meyering@lucent.com>
21135
21136         * lib/mountlist.c: Back out last change.  Instead, do this...
21137         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
21138         me_dummy member using the same `ignore'-testing code.
21139         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
21140         fs_type strings.
21141         From Mark D. Roth.
21142
21143 2000-05-29  Jim Meyering  <meyering@lucent.com>
21144
21145         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
21146         mounts with the `ignore' attribute.  Based on a patch from
21147         Mark D. Roth.
21148
21149 2000-05-28  Jim Meyering  <meyering@lucent.com>
21150
21151         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
21152         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
21153         * m4/stat.m4: Likewise.
21154         * m4/lstat.m4: Likewise.
21155         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
21156
21157         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
21158         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
21159
21160 2000-05-26  Jim Meyering  <meyering@lucent.com>
21161
21162         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
21163
21164 2000-05-24  Jim Meyering  <meyering@lucent.com>
21165
21166         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
21167         autoconf requires that.
21168         * m4/lib-check.m4: Likewise.
21169         * m4/jm-macros.m4: Likewise.
21170         * m4/strftime.m4: Likewise.
21171
21172         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
21173         AC_CHECK_DECLS, now that autoconf requires that.
21174
21175 2000-05-22  Jim Meyering  <meyering@lucent.com>
21176
21177         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
21178         * m4/lstat.m4: Likewise.
21179
21180 2000-05-22  Jim Meyering  <meyering@lucent.com>
21181
21182         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
21183
21184 2000-05-20  Jim Meyering  <meyering@lucent.com>
21185
21186         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
21187         (jm_PREREQ): Use it.
21188
21189 2000-05-18  Jim Meyering  <meyering@lucent.com>
21190
21191         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
21192         back, too, since it may have been modified by allocate_entry.
21193         (hash_delete): Rewrite to use neither the assignment operator
21194         nor the comma operator in an if-expression.
21195
21196 2000-05-15  Paul Eggert  <eggert@twinsun.com>
21197
21198         * lib/closeout.c:
21199         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
21200         Remove; no longer needed.
21201         "quotearg.h": Add include.
21202         (file_name): Do not bother to explicitly initialize to NULL; it's less
21203         efficient on some hosts.
21204         (close_stdout_status): Remove test as to whether stdout was already
21205         closed; it breaks for the case "echo x | sort >&-".
21206         Quote file name colons.
21207         Do not assume that _("write error") lacks format strings.
21208
21209 2000-05-15  Jim Meyering  <meyering@lucent.com>
21210
21211         * lib/version-etc.c (version_etc_copyright): Update the copyright
21212         string used in all --version output.
21213
21214 2000-05-14  Jim Meyering  <meyering@lucent.com>
21215
21216         * lib/closeout.c (close_stdout_set_file_name): New function.
21217         (close_stdout_status): Use new file-scoped global.
21218         Return right away if fstat says the stdout file descriptor is invalid.
21219         * lib/closeout.h (close_stdout_set_file_name): Declare.
21220
21221 2000-05-10  Jim Meyering  <meyering@lucent.com>
21222
21223         * lib/closeout.c [default_exit_status]: New file-scoped variable.
21224         (close_stdout_set_status): New function.
21225         * lib/closeout.h (close_stdout_set_status): Declare.
21226
21227 2000-05-09  Jim Meyering  <meyering@lucent.com>
21228
21229         * m4/gettext.m4: Rename this...
21230         * m4/libintl.m4: ...to this.
21231
21232 2000-05-08  Jim Meyering  <meyering@lucent.com>
21233
21234         * lib/long-options.c: Don't include closeout.h.
21235         (parse_long_options): Don't call close_stdout for --version.
21236
21237 2000-05-06  Paul Eggert  <eggert@twinsun.com>
21238
21239         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
21240         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
21241         2.1.3 bug.  This avoids a clash when files like regex.c define
21242         _GNU_SOURCE.
21243
21244 2000-05-06  Jim Meyering  <meyering@lucent.com>
21245
21246         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
21247         (AC_REPLACE_FUNCS): Add strnlen.
21248
21249         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
21250         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
21251
21252         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
21253         AC_SEARCH_LIBS call for nanosleep.
21254         (LIB_NANOSLEEP): Set and AC_SUBST.
21255
21256 2000-05-06  Jim Meyering  <meyering@lucent.com>
21257
21258         * lib/strnlen.c: Undefine __strnlen and strnlen.
21259         [!weak_alias]: Define __strnlen to strnlen.
21260
21261         * lib/atexit.c: New file, from libiberty.
21262
21263 2000-05-06  Jim Meyering  <meyering@lucent.com>
21264
21265         * lib/closeout.c (close_stdout_status): Also check for errors on the
21266         stderr stream.
21267
21268 2000-05-05  Jim Meyering  <meyering@lucent.com>
21269
21270         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
21271         AC_SEARCH_LIBS call for clock_gettime.
21272         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
21273
21274         * m4/search-libs.m4: Update from autoconf.
21275
21276         su doesn't work on Solaris 2.6.
21277         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
21278         <shadow.h>.  Reported by Dragos Harabor.
21279
21280 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
21281
21282         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
21283         memcpy instead of xmalloc, xrealloc, path_concat.
21284         (locale_charset): Treat empty environment variables as absent.
21285         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
21286
21287 2000-05-04  Jim Meyering  <meyering@lucent.com>
21288
21289         * lib/getopt.c: Update from glibc.
21290         * lib/obstack.c: Likewise.
21291         * lib/obstack.h: Likewise.
21292         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
21293         file
21294
21295         * lib/regex.h: Likewise.
21296         * lib/strndup.c: Likewise.
21297         * lib/strnlen.c: New file, from glibc.
21298
21299 2000-05-03  Jim Meyering  <meyering@lucent.com>
21300
21301         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
21302
21303 2000-05-02  Paul Eggert  <eggert@twinsun.com>
21304
21305         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
21306         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
21307         compile-time test, rather than inspecting host and OS, to
21308         decide whether to define _LARGEFILE_SOURCE.
21309
21310 2000-05-01  Jim Meyering  <meyering@lucent.com>
21311
21312         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
21313
21314         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
21315         Based on a patch from Bruno Haible.
21316
21317 2000-05-01  Jim Meyering  <meyering@lucent.com>
21318
21319         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
21320
21321 2000-04-29  Jim Meyering  <meyering@lucent.com>
21322
21323         * lib/path-concat.c: Declare strdup only if it's not defined.
21324         * lib/canon-host.c: Likewise.
21325
21326 2000-04-28  Jim Meyering  <meyering@lucent.com>
21327
21328         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
21329         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
21330         is included first, then limits.h is included by locale.h by libintl.h.
21331         From John David Anglin.
21332
21333 2000-04-25  Jim Meyering  <meyering@lucent.com>
21334
21335         * lib/makepath.c (S_IRWXUGO): Define.
21336         (make_path): Always perform explicit chmod if MODE specifies any
21337         of the `special' permission bits.  Prompted by a bug report against
21338         install from Mate Wierdl and Joost van Baal.
21339
21340 2000-04-18  Jim Meyering  <meyering@lucent.com>
21341
21342         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
21343         (jm_PREREQ): Use it.
21344
21345 2000-04-18  Jim Meyering  <meyering@lucent.com>
21346
21347         * lib/README: New file.
21348
21349         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
21350         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
21351
21352 2000-04-17  Jim Meyering  <meyering@lucent.com>
21353
21354         Get it right :-)
21355         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
21356         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
21357         Suggestion from Akim Demaille.
21358
21359 2000-04-17  Jim Meyering  <meyering@lucent.com>
21360
21361         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
21362         the definition of it to rpl_strftime also defined-away the system's
21363         declaration.
21364
21365 2000-04-15  Jim Meyering  <meyering@lucent.com>
21366
21367         Use `C' to denote so-called `contiguous' files, the same way
21368         that tar does.
21369         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
21370         (ftypelet): Use S_ISCTG.
21371         From Michael Deutschmann.
21372
21373 2000-04-14  Jim Meyering  <meyering@lucent.com>
21374
21375         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
21376         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
21377         clobbered.
21378
21379 2000-04-14  Jim Meyering  <meyering@lucent.com>
21380
21381         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
21382
21383 2000-04-13  Jim Meyering  <meyering@lucent.com>
21384
21385         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
21386         AH_VERBATIM to insert required #ifndef into config.h.in.
21387         Suggestion from Akim Demaille.
21388
21389 2000-04-12  Jim Meyering  <meyering@lucent.com>
21390
21391         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
21392         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
21393         Christian Krackowizer.
21394
21395         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
21396         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
21397         (AC_SYS_LARGEFILE): Require.
21398         (AM_C_PROTOTYPES): Require.
21399
21400 2000-04-08  Jim Meyering  <meyering@lucent.com>
21401
21402         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
21403         names don't conflict.  Reported by Eli Zaretskii.
21404
21405 2000-04-07  Jim Meyering  <meyering@lucent.com>
21406
21407         * lib/putenv.c: Move inclusion of errno.h so it follows that of
21408         sys/types.h, to work around system header problems on AIX 3.2.5.
21409         From Bruno Haible.
21410
21411 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
21412
21413         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
21414         bug.  Deal with the different error behavior of Irix iconv.
21415
21416 2000-04-05  Paul Eggert  <eggert@twinsun.com>
21417
21418         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
21419         IRIX if the installer said otherwise.
21420
21421 2000-04-05  Jim Meyering  <meyering@lucent.com>
21422
21423         Portability tweaks required for ultrix4.3.
21424         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
21425         (jm_CHECK_DECLS): Add getutent to the list of functions.
21426         (_jm_DECL_HEADERS): Add utmpx.h.
21427         From John David Anglin.
21428
21429         * m4/strftime.m4: Back out the 2000-04-02 change.
21430         Instead of that change, simply undefine putenv in the test program.
21431
21432 2000-04-05  Jim Meyering  <meyering@lucent.com>
21433
21434         Portability tweaks required for ultrix4.3.
21435         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
21436         getutent.
21437         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
21438         * lib/canon-host.c: Declare strdup.
21439         * lib/path-concat.c: Likewise.
21440         From John David Anglin.
21441
21442 2000-04-04  Jim Meyering  <meyering@lucent.com>
21443
21444         Be more DOS 8.3-friendly.
21445         * lib/ref-add.sin: Renamed from ref-add.sed.in.
21446         * lib/ref-del.sin: Renamed from ref-del.sed.in.
21447         * lib/Makefile.am: Reflect renaming.
21448         Reported by Eli Zaretskii.
21449
21450         Use a temporary file name that won't clash with `charset.alias'
21451         in the DOS 8.3 name space.
21452         * lib/Makefile.am (charset_tmp): Define.
21453         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
21454         (uninstall-local): Likewise.
21455         Reported by Eli Zaretskii.
21456
21457 2000-04-03  Jim Meyering  <meyering@lucent.com>
21458
21459         * m4/gettext.m4: Fix typo in comment.
21460
21461         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
21462         textutils/configure.in).  Suggestion from Paul Eggert.
21463         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
21464
21465 2000-04-02  Paul Eggert  <eggert@twinsun.com>
21466
21467         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
21468         variable in the shell rather than using putenv, which isn't
21469         portable.  This avoids the configure-time inter-test dependency
21470         on the potentially-renamed putenv function.
21471
21472 2000-03-30  Paul Eggert  <eggert@twinsun.com>
21473
21474         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
21475         before checking struct stat.st_blksize, so that
21476         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
21477
21478 2000-03-29  Paul Eggert  <eggert@twinsun.com>
21479
21480         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
21481         since strftime.c uses HAVE_STRFTIME to decide whether to use
21482         the underlying strftime.
21483
21484 2000-03-29  Paul Eggert  <eggert@twinsun.com>
21485
21486         * lib/time/strftime.c (my_strftime): Make sure we call the system
21487         strftime, not ourselves, when invoking the underlying strftime.
21488
21489 2000-03-24  Jim Meyering  <meyering@lucent.com>
21490
21491         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
21492         (charset_alias): Define.
21493         (install-exec-local): Factor out common code.
21494         (uninstall-local): Split lines longer than 80.
21495         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
21496         (SUFFIXES): Define.
21497         (.sed.in.sed): New rule.  Don't redirect directly to $@.
21498         (CLEANFILES): Add ref-add.sed and ref-del.sed.
21499
21500 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
21501
21502         * lib/config.charset: Output a line containing "Packages using this
21503         file".
21504         * lib/ref-add.sed.in, ref-del.sed.in: New files.
21505         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
21506         ref-del.sed): New rules.
21507
21508 2000-03-17  Jim Meyering  <meyering@lucent.com>
21509
21510         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
21511         Otherwise, include <strings.h>
21512
21513 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
21514
21515         * lib/unicodeio.c (utf8_wctomb): New function.
21516         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
21517         format instead of in UCS-4 with platform dependent endianness.
21518
21519 2000-03-10  Jim Meyering  <meyering@lucent.com>
21520
21521         * m4/lib-check.m4: Look for getspnam in -lgen, too.
21522         From Marco Franzen.
21523
21524 2000-03-07  Paul Eggert  <eggert@twinsun.com>
21525
21526         * lib/savedir.c (savedir): Work even if directory size is
21527         negative; this can happen with some screwy NFS configurations.
21528
21529 2000-03-06  Jim Meyering  <meyering@lucent.com>
21530
21531         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
21532         if it's NULL (because we ran out of memory).  From Bruno Haible.
21533
21534 2000-03-05  Jim Meyering  <meyering@lucent.com>
21535
21536         * lib/localcharset.c ("path-concat.h"): Include.
21537         (get_charset_aliases): Use path_concat instead of ANSI string
21538         concatenation.
21539
21540         * lib/unicodeio.h (PARAMS): Define.
21541         Use it to guard prototype.
21542
21543 2000-03-04  Jim Meyering  <meyering@lucent.com>
21544
21545         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
21546         for lib/localcharset.c.
21547
21548 2000-03-04  Jim Meyering  <meyering@lucent.com>
21549
21550         * lib/Makefile.am (install-exec-local): Create $(libdir) before
21551         installing into it.
21552         (uninstall-local): Uncomment this rule so `make distcheck' works
21553         once again.
21554
21555         * lib/unicodeio.c (<errno.h>): Include it.
21556         (errno): Declare if not defined.
21557
21558         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
21559
21560         * lib/config.charset: New version, incorporating remarks from a linux
21561         i18n mailing list.  From Bruno Haible.
21562
21563 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
21564
21565         * m4/codeset.m4: New file.
21566         * m4/iconv.m4: New file.
21567         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
21568
21569 2000-03-03  Jim Meyering  <meyering@lucent.com>
21570
21571         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
21572
21573 2000-03-02  Jim Meyering  <meyering@lucent.com>
21574
21575         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
21576         the messages come out on separate lines.
21577
21578         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
21579         rather than jm_CHECK_DECLARATIONS.
21580         * m4/decl.m4: Remove now-unused file.
21581
21582         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
21583         geteuid.
21584
21585 2000-03-02  Jim Meyering  <meyering@lucent.com>
21586
21587         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
21588
21589 2000-03-01  Jim Meyering  <meyering@lucent.com>
21590
21591         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
21592         * lib/unicodeio.c: Likewise.
21593
21594 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
21595
21596         * lib/config.charset: New file.
21597         * lib/localcharset.c: New file.
21598         * lib/unicodeio.h, unicodeio.c: New files.
21599         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
21600         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
21601         (noinst_HEADERS): Add unicodeio.h.
21602         (all-local, install-exec-local, charset.alias): New targets.
21603
21604 2000-02-28  Paul Eggert  <eggert@twinsun.com>
21605
21606         * lib/quotearg.c (ALERT_CHAR): New macro.
21607         (quotearg_buffer_restyled): Use it.
21608
21609 2000-02-27  Jim Meyering  <meyering@lucent.com>
21610
21611         * m4/check-decl.m4: Add getenv to the list.
21612
21613 2000-02-27  Jim Meyering  <meyering@lucent.com>
21614
21615         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
21616         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
21617
21618         * lib/backupfile.c: Guard inclusion of stdlib.h with
21619         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
21620         Declare malloc if needed.
21621
21622         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
21623         `#ifndef HAVE_DECL..'
21624         now that autoconf always defines the HAVE_DECL_ symbols.
21625         * lib/human.c: Likewise.
21626         * lib/same.c: Likewise.
21627         * lib/strtoumax.c: Likewise.
21628
21629         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
21630         declaration check was not run.
21631         * lib/hash.c: Likewise.
21632         * lib/human.c: Likewise.
21633         * lib/same.c: Likewise.
21634         * lib/strtoumax.c: Likewise.
21635
21636         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
21637         `.', then first look up the entire `.'-containing string as a login
21638         name.
21639
21640 2000-02-23  Jim Meyering  <meyering@lucent.com>
21641
21642         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
21643         in place of my hack.
21644
21645 2000-02-18  Paul Eggert  <eggert@twinsun.com>
21646
21647         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
21648         (textint): New typedef.
21649         (parser_control): Member year changed from int to textint.
21650         All uses changed.
21651         (YYSTYPE): Removed; replaced by %union with int and textint members.
21652         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
21653         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
21654         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
21655         (tSNUMBER, tUNUMBER): Now of type <textintval>.
21656         (date, number, to_year): Use width of number in digits, not its value,
21657         to determine whether it's a 2-digit year, or a 2-digit time.
21658         (yylex): Store number of digits of numeric tokens.
21659         Reported by John Kendall.
21660
21661         (parser_control): Changed from struct parser_control to typedef (for
21662         consistency).  All uses changed.
21663
21664         (tID): Removed; not used.
21665         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
21666
21667 2000-02-14  Paul Eggert  <eggert@twinsun.com>
21668
21669         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
21670         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
21671
21672 2000-02-12  Jim Meyering  <meyering@lucent.com>
21673
21674         * lib/userspec.c (ISDIGIT): Define it.
21675         (isdigit): Remove definition.
21676         (is_number): Use ISDIGIT, not isdigit.
21677         <libintl.h>: Include.
21678         (_ and N_): Define.
21679         (parse_user_spec): Mark translatable strings.
21680
21681 2000-02-10  Jim Meyering  <meyering@lucent.com>
21682
21683         With these changes, nanosleep.[ch] are finally enough like the other
21684         lib/* replacement files to compile on a few more losing systems.
21685
21686         * lib/nanosleep.h: Don't include config.h.
21687         Remove prototype from declaration of nanosleep.
21688         (PARAMS): Remove now-unneeded definition.
21689         * lib/nanosleep.c: #undef nanosleep.
21690         (rpl_nanosleep): Rename from nanosleep.
21691
21692 2000-02-10  Jim Meyering  <meyering@lucent.com>
21693
21694         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
21695         gnu_nanosleep to rpl_nanosleep.
21696
21697 2000-02-09  Jim Meyering  <meyering@lucent.com>
21698
21699         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
21700         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
21701
21702 2000-02-08  Akim Demaille  <akim@epita.fr>
21703
21704         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
21705         `[' and `]' and remove uses of `changequote'.
21706         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
21707         (AC_SYS_LARGEFILE): Likewise.
21708         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
21709         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
21710         of changequote.
21711         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
21712         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
21713         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
21714         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
21715
21716 2000-02-05  Jim Meyering  <meyering@lucent.com>
21717
21718         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
21719         Remove explicit use of AC_HEADER_TIME.  It is required by
21720         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
21721         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
21722         in autoconf whereby the expansion of the latter ended up preceding
21723         the expansion of its prerequisite, AC_HEADER_TIME.
21724         Reported by Volker Borchert.
21725
21726 2000-02-03  Jim Meyering  <meyering@lucent.com>
21727
21728         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
21729
21730 2000-02-03  Jim Meyering  <meyering@lucent.com>
21731
21732         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
21733         rather than with `#if HAVE_UTMPNAME'.
21734
21735 2000-02-02  Jim Meyering  <meyering@lucent.com>
21736
21737         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
21738         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
21739         Reported by Eli Zaretskii.
21740
21741 2000-02-01  Jim Meyering  <meyering@lucent.com>
21742
21743         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
21744
21745 2000-01-31  Jim Meyering  <meyering@lucent.com>
21746
21747         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
21748         functions.  Add the time.h and sys/time.h headers along with the
21749         AC_REQUIRE'ment of AC_HEADER_TIME.
21750
21751 2000-01-31  Jim Meyering  <meyering@lucent.com>
21752
21753         * lib/nanosleep.h (nanosleep): Guard declaration with
21754         `#if ! HAVE_DECL_NANOSLEEP'.
21755         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
21756         the declaration in that vendor's sys/timers.h.
21757         Reported by Christian Krackowizer.
21758
21759         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
21760         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
21761         (ISPRINT): Likewise.
21762         Reported by Tom Tromey.
21763
21764 2000-01-30  Jim Meyering  <meyering@lucent.com>
21765
21766         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
21767
21768         * m4/prereq.m4 (utmp_includes): Define.
21769         Check for ut_user and ut_name members in both struct utmpx
21770         and struct utmp.
21771
21772 2000-01-30  Jim Meyering  <meyering@lucent.com>
21773
21774         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
21775         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
21776         header files where only utmpx.ut_user is declared.
21777
21778         * lib/readutmp.h (UT_USER): Define.
21779
21780 2000-01-29  Jim Meyering  <meyering@lucent.com>
21781
21782         * m4/lib-check.m4: New file containing library-related checks from
21783         fileutils and sh-utils (textutils had none).
21784
21785 2000-01-28  Jim Meyering  <meyering@lucent.com>
21786
21787         * m4/perl.m4: Change format of warning message to look more like that
21788         from the missing script.  Suggestion from François Pinard.
21789
21790 2000-01-25  Jim Meyering  <meyering@lucent.com>
21791
21792         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
21793         well as time.h in the compile check.
21794         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
21795         Fix typo in cross-compiling case: s/yes/no/.
21796
21797 2000-01-23  Jim Meyering  <meyering@lucent.com>
21798
21799         * m4/jm-macros.m4: Move df-related tests here from
21800         fileutils/configure.in
21801
21802         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
21803         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
21804
21805         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
21806         s/space/ac_fsusage_space/.
21807         (jm_FILE_SYSTEM_USAGE): Take two parameters.
21808
21809         * m4/ftruncate.m4: New file (derived from part of
21810         fileutils/configure.in).
21811         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
21812         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
21813
21814         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
21815         AC_SUBST these here, rather than just in sh-util/configure.in, so
21816         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
21817         all the same.
21818         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
21819         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
21820         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
21821         (AC_SUBST(POW_LIBM)): Likewise.
21822         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
21823
21824 2000-01-23  Jim Meyering  <meyering@lucent.com>
21825
21826         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
21827         obstack.c.
21828
21829 2000-01-22  Jim Meyering  <meyering@lucent.com>
21830
21831         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
21832
21833         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
21834
21835         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
21836         configure.in
21837         (AC_CHECK_HEADERS): Likewise for sh-utils.
21838         (AC_CHECK_HEADERS): Likewise for textutils.
21839         Merge the three lists of headers.
21840
21841         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
21842         from fileutils' configure.in.
21843
21844         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
21845         code. Moved tests into their own function (_jm_DECL_HEADERS) in
21846         check-decl.m4.
21847
21848         * m4/check-decl.m4: Use #if rather than #ifdef.
21849         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
21850         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
21851         (_jm_DECL_HEADERS): Define new function.
21852         (jm_CHECK_DECLARATIONS): Require it.
21853
21854 2000-01-22  Jim Meyering  <meyering@lucent.com>
21855
21856         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
21857         [! HAVE_DECL_STRTOULL]: Declare strtoull.
21858         Required for some AIX systems.  Reported by Christian Krackowizer.
21859         [TESTING] (main): New function.
21860
21861         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
21862         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
21863         letters.
21864
21865         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
21866         iswprint.
21867
21868         * lib/strverscmp.c (ISDIGIT): Define.
21869         (strverscmp): Use ISDIGIT, not isdigit.
21870
21871 2000-01-19  Jim Meyering  <meyering@lucent.com>
21872
21873         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
21874         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
21875         defines `struct timespec' in <sys/time.h>
21876
21877         * m4/c-bs-a.m4: Remove uses of changequote altogether.
21878         Thanks to Akim for explaining.
21879
21880 2000-01-17  Paul Eggert  <eggert@twinsun.com>
21881
21882         * lib/nanosleep.c (nanosleep):
21883         Don't use SA_INTERRUPT to decide whether to call sigaction, as
21884         POSIX.1 doesn't require SA_INTERRUPT and some systems
21885         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
21886         it's been part of POSIX.1 since day 1 (in 1988).
21887
21888 2000-01-17  Jim Meyering  <meyering@lucent.com>
21889
21890         * lib/interlock: Remove unused file.  Reported by François Pinard.
21891
21892 2000-01-16  Paul Eggert  <eggert@twinsun.com>
21893
21894         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
21895         alert, backslash, formfeed, and vertical tab unnecessarily in
21896         shell quoting style.
21897
21898 2000-01-16  Jim Meyering  <meyering@lucent.com>
21899
21900         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
21901         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
21902         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
21903         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
21904
21905 2000-01-16  Jim Meyering  <meyering@lucent.com>
21906
21907         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
21908         because the latter didn't work.
21909
21910 2000-01-15  Jim Meyering  <meyering@lucent.com>
21911
21912         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
21913         (AC_REPLACE_FUNCS): Add memcpy and memset.
21914         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
21915         Add strpbrk.
21916         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
21917
21918 2000-01-12  Jim Meyering  <meyering@lucent.com>
21919
21920         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
21921         (jm_PREREQ): Use it.
21922         (jm_PREREQ_READUTMP): New macro.
21923         (jm_PREREQ): Use it.
21924
21925 2000-01-11  Paul Eggert  <eggert@twinsun.com>
21926
21927         Quote multibyte characters correctly.
21928         * m4/c-bs-a.m4: New file.
21929         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
21930         (jm_PREREQ): Use it.
21931
21932 2000-01-11  Paul Eggert  <eggert@twinsun.com>
21933
21934         * m4/uintmax_t.m4: Port to autoconf 2.13.
21935
21936 2000-01-08  Jim Meyering  <meyering@ascend.com>
21937
21938         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
21939         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
21940
21941 2000-01-04  Jim Meyering  <meyering@ascend.com>
21942
21943         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
21944         jm_STRUCT_DIRENT_D_TYPE.
21945         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
21946         jm_STRUCT_DIRENT_D_INO.
21947         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
21948         jm_STRUCT_UTIMBUF.
21949         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
21950         renamings.
21951         * m4/utime.m4: Likewise.
21952
21953         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
21954         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
21955
21956 2000-01-03  Paul Eggert  <eggert@twinsun.com>
21957
21958         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
21959         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
21960
21961 2000-01-02  Jim Meyering  <meyering@ascend.com>
21962
21963         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
21964         remember if this is necessary.
21965
21966 1999-12-26  Jim Meyering  <meyering@ascend.com>
21967
21968         * m4/jm-macros.m4: Use it here.
21969         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
21970
21971 1999-12-23  Jim Meyering  <meyering@ascend.com>
21972
21973         * m4/jm-macros.m4: Check for clock_gettime (moved from
21974         fileutils/configure.in)
21975         Check for gettimeofday.
21976
21977 1999-12-20  Jim Meyering  <meyering@ascend.com>
21978
21979         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
21980         autoconf-2.14a-1999-12-20.
21981
21982 1999-12-19  Jim Meyering  <meyering@ascend.com>
21983
21984         * m4/lstat-slash.m4: New file.
21985         * m4/jm-macros.m4: Use the new macro:
21986         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
21987
21988 1999-12-07  Jim Meyering  <meyering@ascend.com>
21989
21990         * m4/perl.m4: Require that File::Compare be available, too.
21991         Too many systems seem to lack it.
21992
21993         * m4/strftime.m4: Add checks for most of the cpp macros tested in
21994         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
21995
21996 1999-11-18  Paul Eggert  <eggert@twinsun.com>
21997
21998         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
21999         problem with the QNX 4.25 shell, which doesn't propagate exit
22000         status of failed commands inside shell assignments.
22001
22002 1999-11-17  Jim Meyering  <meyering@ascend.com>
22003
22004         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
22005
22006 1999-11-07  Jim Meyering  <meyering@ascend.com>
22007
22008         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
22009
22010 1999-11-06  Jim Meyering  <meyering@ascend.com>
22011
22012         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
22013         * m4/jm-macros.m4 (jm_MACROS): Use it here.
22014
22015 1999-11-05  Jim Meyering  <meyering@ascend.com>
22016
22017         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
22018         configure.in of textutils, fileutils, and sh-utils into this one
22019         (shared between those packages) file.
22020         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
22021         AC_STRUCT_ST_BLKSIZE.
22022
22023 1999-11-03  Jim Meyering  <meyering@ascend.com>
22024
22025         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
22026         of AC_CHECK_TYPE checks includes unistd.h.
22027         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
22028         Suggestion from Akim Demaille.
22029
22030 1999-10-30  Jim Meyering  <meyering@ascend.com>
22031
22032         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
22033         m4-quoted string.
22034         * m4/ls-mntd-fs.m4: Likewise.
22035         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
22036         * m4/jm-winsz1.m4: Likewise.
22037
22038         * m4/const.m4: Remove file, since the fix made it into the experimental
22039         version of autoconf.
22040         * m4/mktime.m4: Likewise.
22041
22042         * m4/check-type.m4: Remove file, now that the latest version of
22043         AC_CHECK_TYPE takes a third arg to specify additional #includes.
22044
22045         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
22046         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
22047         AC_CHECK_TYPE.
22048
22049 1999-10-04  Jim Meyering  <meyering@ascend.com>
22050
22051         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
22052
22053 1999-09-22  Paul Eggert  <eggert@twinsun.com>
22054
22055         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
22056         2.95.1 bug with HP-UX 10.20.
22057
22058 1999-09-17  Jim Meyering  <meyering@ascend.com>
22059
22060         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
22061         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
22062         due to missing strdup (against sh-utils-2.0).
22063
22064 1999-08-29  Jim Meyering  <meyering@ascend.com>
22065
22066         * m4/jm-macros.m4: Require jm_BISON.
22067         * m4/bison.m4: New file.
22068
22069 1999-08-17  Paul Eggert  <eggert@twinsun.com>
22070
22071         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
22072         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
22073
22074 1999-08-05  Jim Meyering  <meyering@ascend.com>
22075
22076         * m4/getline.m4: Rename test file from conftestdata to conftest.data
22077         to avoid conflicts with `conftest' on 8+3 filesystems.
22078         Suggestion from Eli Zaretskii.
22079
22080 1999-08-04  Jim Meyering  <meyering@ascend.com>
22081
22082         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
22083         fileutils and sh-utils (textutils's getline test was inadequate).
22084         (AM_FUNC_GETLINE): Run this test.
22085         (AC_CHECK_FUNCS): Check for getdelim.
22086         Reported by Bob Proulx.
22087
22088 1999-08-02  Jim Meyering  <meyering@ascend.com>
22089
22090         * m4/jm-macros.m4: Add a comment.
22091
22092 1999-08-01  Paul Eggert  <eggert@twinsun.com>
22093
22094         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
22095         <inttypes.h> defines strtoumax as a macro (and not as a
22096         function).
22097
22098 1999-08-01  Paul Eggert  <eggert@twinsun.com>
22099
22100         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
22101         that we can shift, multiply and divide unsigned long long
22102         values; Ultrix cc can't do it.
22103
22104 1999-08-01  Paul Eggert  <eggert@twinsun.com>
22105
22106         * m4/mktime.m4: New file, which is a preview of what should appear
22107         in the next public autoconf release.
22108
22109 1999-08-01  Paul Eggert  <eggert@twinsun.com>
22110
22111         * m4/lfs.m4: Remove this file.
22112         * m4/largefile.m4: New file.  It contains the old contents of
22113         lfs.m4, except that all names with prefix AC_LFS have been
22114         changed to use the prefix AC_SYS_LARGEFILE instead, to be
22115         compatible with future autoconf versions.  Also, some minor m4
22116         quoting problems have been fixed.
22117
22118 1999-08-01  Paul Eggert  <eggert@twinsun.com>
22119
22120         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
22121         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
22122         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
22123         and simplify the shell code.
22124
22125 1999-08-01  Jim Meyering  <meyering@ascend.com>
22126
22127         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
22128         m4.
22129
22130 1999-07-20  Jim Meyering  <meyering@ascend.com>
22131
22132         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
22133
22134 1999-07-15  Jim Meyering  <meyering@ascend.com>
22135
22136         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
22137
22138 1999-05-22  Jim Meyering  <meyering@ascend.com>
22139
22140         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
22141
22142 1999-05-20  Jim Meyering  <meyering@ascend.com>
22143
22144         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
22145         Add a colon after each `then' in case $4 is empty.
22146
22147 1999-05-16  Jim Meyering  <meyering@ascend.com>
22148
22149         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
22150
22151 1999-05-10  Jim Meyering  <meyering@ascend.com>
22152
22153         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
22154
22155         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
22156         AC_FUNC_MKTIME.
22157
22158 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
22159
22160         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
22161
22162 1999-05-04  Paul Eggert  <eggert@twinsun.com>
22163
22164         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
22165         not CPPFLAGS, so that linking works correctly in IRIX.
22166
22167 1999-04-30  Paul Eggert  <eggert@twinsun.com>
22168
22169         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
22170
22171 1999-04-20  Paul Eggert  <eggert@twinsun.com>
22172
22173         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
22174         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
22175         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
22176         jm_AC_TYPE_UNSIGNED_LONG_LONG.
22177         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
22178
22179         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
22180
22181 1999-04-20  Jim Meyering  <meyering@ascend.com>
22182
22183         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
22184         AC_REPLACE xstroull if necessary.  From Paul Eggert.
22185         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
22186
22187 1999-04-18  Jim Meyering  <meyering@ascend.com>
22188
22189         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
22190         * m4/jm-macros.m4: Use it.
22191
22192 1999-04-06  Jim Meyering  <meyering@ascend.com>
22193
22194         * m4/strftime.m4: Remove test for %f.
22195
22196 1999-03-29  Jim Meyering  <meyering@ascend.com>
22197
22198         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
22199         superset of the AC_TYPE_* checks in the textutils, fileutils,
22200         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
22201         AC_TYPE_PID_T.
22202
22203 1999-03-28  Jim Meyering  <meyering@ascend.com>
22204
22205         * m4/jm-macros.m4: Define GNU_PACKAGE here.
22206         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
22207         replaced e.g., in the *.sh files of the sh-utils.
22208
22209 1999-03-20  Jim Meyering  <meyering@ascend.com>
22210
22211         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
22212         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
22213         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
22214
22215 1999-03-19  Jim Meyering  <meyering@ascend.com>
22216
22217         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
22218
22219 1999-03-12  Jim Meyering  <meyering@ascend.com>
22220
22221         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
22222
22223 1999-03-07  Jim Meyering  <meyering@ascend.com>
22224
22225         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
22226         declared.
22227
22228 1999-02-17  Jim Meyering  <meyering@ascend.com>
22229
22230         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
22231         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
22232
22233 1999-02-07  Jim Meyering  <meyering@ascend.com>
22234
22235         * m4/group-member.m4: New file -- extracted from sh-utils'
22236         configure.in.
22237
22238         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
22239         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
22240
22241 1999-02-06  Jim Meyering  <meyering@ascend.com>
22242
22243         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
22244         * m4/fnmatch.m4: Likewise.
22245         * m4/getgroups.m4: Likewise.
22246         * m4/lstat.m4: Likewise.
22247         * m4/malloc.m4: Likewise.
22248         * m4/putenv.m4: Likewise.
22249         * m4/realloc.m4: Likewise.
22250         * m4/regex.m4: Likewise.
22251         * m4/stat.m4: Likewise.
22252         * m4/strftime.m4: Likewise.
22253         Suggestion from Alain Magloire.
22254
22255         * m4/chown.m4: Use `.$ac_objext', not `.o'.
22256         * m4/fnmatch.m4: Likewise.
22257         * m4/getgroups.m4: Likewise.
22258         * m4/getline.m4: Likewise.
22259         * m4/lstat.m4: Likewise.
22260         * m4/malloc.m4: Likewise.
22261         * m4/memcmp.m4: Likewise.
22262         * m4/putenv.m4: Likewise.
22263         * m4/realloc.m4: Likewise.
22264         * m4/regex.m4: Likewise.
22265         * m4/stat.m4: Likewise.
22266         * m4/strftime.m4: Likewise.
22267         Suggestion from Alain Magloire.
22268
22269         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
22270         an argument.
22271
22272         * m4/regex.m4: Add a run-time Test for proper operation of
22273         re_compile_pattern.
22274
22275 1999-01-31  Jim Meyering  <meyering@ascend.com>
22276
22277         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
22278
22279 1999-01-30  Jim Meyering  <meyering@ascend.com>
22280
22281         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
22282
22283         * m4/jm-mktime.m4: Make this a wrapper around the official
22284         AM_FUNC_MKTIME rather than my private copy, now that the official one
22285         is up to date.
22286         * m4/mktime.m4: Remove file.
22287
22288         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
22289         * m4/uptime.m4: Likewise.
22290         * m4/uintmax_t.m4: Likewise.
22291
22292 1999-01-28  Jim Meyering  <meyering@ascend.com>
22293
22294         * m4/jm-macros.m4: Use jm_AFS.
22295         * m4/afs.m4: New file (from fileutils' configure.in).
22296
22297         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
22298         * m4/chown.m4: Likewise.
22299         * m4/d-ino.m4: Likewise.
22300         * m4/d-type.m4: Likewise.
22301         * m4/fnmatch.m4: Likewise.
22302         * m4/getgroups.m4: Likewise.
22303         * m4/gettext.m4: Likewise.
22304         * m4/jm-mktime.m4: Likewise.
22305         * m4/jm-winsz2.m4: Likewise.
22306         * m4/lcmessage.m4: Likewise.
22307         * m4/ls-mntd-fs.m4: Likewise.
22308         * m4/malloc.m4: Likewise.
22309         * m4/memcmp.m4: Likewise.
22310         * m4/putenv.m4: Likewise.
22311         * m4/realloc.m4: Likewise.
22312         * m4/st_mtim.m4: Likewise.
22313         * m4/strftime.m4: Likewise.
22314
22315 1999-01-16  Jim Meyering  <meyering@ascend.com>
22316
22317         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
22318         (ARGMATCH_DIE_DECL): Define.
22319
22320 1999-01-12  Jim Meyering  <meyering@ascend.com>
22321
22322         * m4/Makefile.am.in: Rewrite to avoid using fmt.
22323         Reported by Lars Hecking.
22324
22325 1999-01-10  Jim Meyering  <meyering@ascend.com>
22326
22327         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
22328         gross kludge.
22329         * m4/inttypes_h.m4: Likewise.
22330         * m4/lstat.m4: Likewise.
22331         * m4/malloc.m4: Likewise.
22332         * m4/readdir.m4: Likewise.
22333         * m4/realloc.m4: Likewise.
22334         * m4/st_dm_mode.m4: Likewise.
22335         * m4/stat.m4: Likewise.
22336         * m4/utimbuf.m4: Likewise.
22337         * m4/utimes.m4: Likewise.
22338
22339         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
22340         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
22341         comments in config.h.in are meaningful.
22342
22343         * m4/jm-macros.m4: Require autoconf-2.13 here.
22344
22345         * m4/regex.m4: By default, don't use the included regex.c on systems
22346         with glibc 2.  Suggestion from Uli Drepper.
22347
22348 1999-01-02  Jim Meyering  <meyering@ascend.com>
22349
22350         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
22351
22352 1998-12-18  Jim Meyering  <meyering@ascend.com>
22353
22354         * m4/Makefile.am.in (Makefile.am): Simplify rule.
22355         Based on a suggestion from Lars Hecking.
22356
22357 1998-11-16  Paul Eggert  <eggert@twinsun.com>
22358
22359         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
22360
22361 1998-11-16  Jim Meyering  <meyering@ascend.com>
22362
22363         * m4/lfs.m4: Double-quote the `uname...` expression.
22364
22365 1998-11-14  Jim Meyering  <meyering@ascend.com>
22366
22367         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
22368         * m4/stat.m4: Likewise.
22369
22370 1998-11-03  Jim Meyering  <meyering@ascend.com>
22371
22372         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
22373         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
22374
22375 1998-10-18  Jim Meyering  <meyering@ascend.com>
22376
22377         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
22378
22379 1998-10-17  Jim Meyering  <meyering@ascend.com>
22380
22381         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
22382         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
22383         calls for those previously hard-coded headers.  Instead, take a new
22384         parameter.
22385         (jm_CHECK_DECLARATIONS): Reflect interface change.
22386         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
22387         (jm_CHECK_DECL_LOCALTIME_R): New macro.
22388
22389         * m4/mktime.m4: Test for spring-forward gap before long-running test.
22390
22391 1998-10-14  Jim Meyering  <meyering@ascend.com>
22392
22393         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
22394         instead of "TZ=America/Vancouver".  From Paul Eggert.
22395
22396 1998-10-11  Jim Meyering  <meyering@ascend.com>
22397
22398         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
22399         This adds a test for a recently added compatibility fix for mktime.c.
22400         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
22401
22402 1998-09-27  Jim Meyering  <meyering@ascend.com>
22403
22404         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
22405
22406         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
22407         ../configure.in, including a change from Gordon Matzigkeit to allow
22408         cross-compiling for the Hurd.
22409
22410         * m4/glibc.m4: New file/macro to test for the GNU C Library
22411         versions 1 and 2.  From Gordon Matzigkeit.
22412         Indent.
22413
22414 1998-09-21  Jim Meyering  <meyering@ascend.com>
22415
22416         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
22417
22418 1998-08-18  Paul Eggert  <eggert@twinsun.com>
22419
22420         Port nanosecond-resolution times to UnixWare 2.1.2 and
22421         pedantic Solaris 2.6.
22422
22423         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
22424         AC_STRUCT_ST_MTIM.
22425         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
22426         Generate name of ns member, instead of just 1 or undef.
22427         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
22428
22429 1998-08-15  Jim Meyering  <meyering@ascend.com>
22430
22431         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
22432         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
22433         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
22434         instead of jm_TYPE_SSIZE_T.
22435
22436 1998-08-12  Jim Meyering  <meyering@ascend.com>
22437
22438         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
22439
22440 1998-08-02  Jim Meyering  <meyering@ascend.com>
22441
22442         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
22443         in acconfig.h manually.
22444
22445 1998-07-31  Paul Eggert  <eggert@twinsun.com>
22446
22447         * m4/st_mtim.m4: New file.
22448
22449 1998-07-28  Jim Meyering  <meyering@ascend.com>
22450
22451         * m4/utimes.m4: Undef stat.
22452
22453 1998-07-25  Jim Meyering  <meyering@ascend.com>
22454
22455         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
22456         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
22457
22458 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
22459
22460         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
22461         uid and gid actually remain unchanged.
22462
22463 1998-07-07  Jim Meyering  <meyering@ascend.com>
22464
22465         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
22466
22467 1998-07-04  Jim Meyering  <meyering@ascend.com>
22468
22469         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
22470         to prove that this macro can be used in packages without regex.c.
22471
22472 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
22473
22474         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
22475         is to be used.
22476
22477 1998-07-03  Jim Meyering  <meyering@ascend.com>
22478
22479         * m4/gettext.m4: Add -lintl if it's found to be necessary.
22480
22481         * m4/gettext.m4: New file -- from gettext-0.10.35.
22482         * m4/lcmessage.m4: Likewise.
22483         * m4/progtest.m4: Likewise.
22484
22485         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
22486         * m4/jm-macros.m4: Require the new macro.
22487
22488 1998-06-29  Jim Meyering  <meyering@ascend.com>
22489
22490         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
22491         for the definition of NGROUPS (used in a system header included
22492         by sys/mount.h).
22493
22494 1998-06-28  Jim Meyering  <meyering@ascend.com>
22495
22496         * m4/ls-mntd-fs.m4: New file.
22497         * m4/fstypename.m4: New file.
22498
22499         * m4/jm-macros.m4: Require the new macro.
22500         * m4/jm-glibc-io.m4: New file.
22501
22502 1998-05-19  Jim Meyering  <meyering@ascend.com>
22503
22504         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
22505         * m4/lchown.m4: New file.
22506
22507         * m4/Makefile.am.in: New file.
22508         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
22509
22510 1998-05-14  Jim Meyering  <meyering@ascend.com>
22511
22512         * m4/Makefile.am (EXTRA_DIST): Add them.
22513         * m4/jm-macros.m4: New file.
22514         * m4/utimbuf.m4: New file.
22515
22516 1998-05-12  Jim Meyering  <meyering@ascend.com>
22517
22518         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
22519
22520 1998-05-11  Jim Meyering  <meyering@ascend.com>
22521
22522         * m4/isc-posix.m4: New file.
22523
22524 1998-05-10  Jim Meyering  <meyering@ascend.com>
22525
22526         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
22527
22528 1998-05-09  Jim Meyering  <meyering@ascend.com>
22529
22530         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
22531         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
22532         with automake.
22533
22534         * m4/ssize_t.m4: New file.
22535         * m4/mktime.m4: Remove file -- the new automake has this now.
22536
22537 1998-04-26  Jim Meyering  <meyering@ascend.com>
22538
22539         * m4/assert.m4: New file.
22540         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
22541
22542 1998-04-05  Jim Meyering  <meyering@ascend.com>
22543
22544         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
22545         (jm_PREREQ): Use it here.
22546
22547 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
22548
22549         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
22550         in acconfig.h.
22551
22552 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
22553
22554         * m4/prereq.m4: New file.
22555         * m4/error.m4: New file.
22556         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
22557
22558 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
22559
22560         * m4/getline.m4: Don't set am_cv_func_working_getline before the
22561         cache-check for the same variable -- that defeated the purpose of
22562         the test; the test program was never run.  This was a problem only
22563         on systems with losing getline functions -- HP-UX 10.20 is one.
22564         Reported by Bjorn Helgaas.
22565
22566 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
22567
22568         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
22569
22570 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
22571
22572         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
22573
22574         * m4/const.m4: New file.  Use an initializer in this declaration
22575         typedef int charset[2]; const charset x;
22576         Reported by Bob Glickstein.
22577
22578 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
22579
22580         * m4/chown.m4: Fix reversed types on -1 args to chown.
22581         From Kaveh Ghazi.
22582
22583 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
22584
22585         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
22586         Add lseek and memchr.
22587
22588         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
22589         T.E.Dickey <dickey@clark.net> said that some older preprocessors
22590         have a 20-character limit on names.
22591
22592 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
22593
22594         * m4/inttypes_h.m4: New file.
22595         * m4/uintmax_t.m4: New file.
22596         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
22597
22598 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
22599   Free Software Foundation, Inc.
22600 Copying and distribution of this file, with or without modification,
22601 are permitted provided the copyright notice and this notice are preserved.