b04a86c08992874bba8ce68452eb53c2495cad09
[gnulib.git] / ChangeLog
1 2007-02-05  Bruno Haible  <bruno@clisp.org>
2
3         New module mbssep.
4         * modules/mbssep: New file.
5         * lib/mbssep.c: New file.
6         * lib/string_.h (strsep): Add a conditional link warning.
7         (mbssep): New declaration.
8         * m4/mbssep.m4: New file.
9         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
10         GNULIB_MBSSEP.
11         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
12         * MODULES.html.sh (Internationalization functions): Add mbssep.
13
14 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
15
16         * lib/acl.h: Include sys/types.h before sys/acl.h.
17
18 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
19
20         Merge upstream fix for glibc bugzilla #3957:
21
22         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
23
24         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
25         bit for RE_HAT_LISTS_NOT_NEWLINE.
26         (build_charclass_op): Remove bogus comment.
27
28 2007-02-05  Simon Josefsson  <simon@josefsson.org>
29
30         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
31
32 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
33
34         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
35         * lib/memmem.c [!defined _LIBC]: Include config.h.
36
37 2007-02-04  Bruno Haible  <bruno@clisp.org>
38
39         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
40         warning message.
41
42 2007-02-04  Bruno Haible  <bruno@clisp.org>
43
44         New module mbstok_r.
45         * modules/mbstok_r: New file.
46         * lib/mbstok_r.c: New file.
47         * lib/string_.h (strtok_r): Change argument names to match the
48         comments. Add a conditional link warning.
49         (mbstok_r): New declaration.
50         * m4/mbstok_r.m4: New file.
51         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
52         GNULIB_MBSTOK_R.
53         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
54         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
55
56 2007-02-04  Bruno Haible  <bruno@clisp.org>
57
58         New module mbsspn.
59         * modules/mbsspn: New file.
60         * lib/mbsspn.c: New file.
61         * lib/string_.h (strspn): Add a conditional link warning.
62         (mbsspn): New declaration.
63         * m4/mbsspn.m4: New file.
64         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
65         GNULIB_MBSSPN.
66         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
67         * MODULES.html.sh (Internationalization functions): Add mbsspn.
68
69 2007-02-04  Bruno Haible  <bruno@clisp.org>
70
71         New module mbspbrk.
72         * modules/mbspbrk: New file.
73         * lib/mbspbrk.c: New file.
74         * lib/string_.h (strpbrk): Add a conditional link warning.
75         (mbspbrk): New declaration.
76         * m4/mbspbrk.m4: New file.
77         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
78         GNULIB_MBSPBRK.
79         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
80         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
81
82 2007-02-04  Bruno Haible  <bruno@clisp.org>
83
84         New module mbscspn.
85         * modules/mbscspn: New file.
86         * lib/mbscspn.c: New file.
87         * lib/string_.h (strcspn): Add a conditional link warning.
88         (mbscspn): New declaration.
89         * m4/mbscspn.m4: New file.
90         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
91         GNULIB_MBSCSPN.
92         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
93         * MODULES.html.sh (Internationalization functions): Add mbscspn.
94
95 2007-02-04  Bruno Haible  <bruno@clisp.org>
96
97         New module mbscasestr, reduced goal of strcasestr.
98         * modules/mbscasestr: New file.
99         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
100         (mbscasestr): Renamed from strcasestr.
101         * lib/strcasestr.c: Don't include mbuiter.h.
102         (strcasestr): Remove support for multibyte locales.
103         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
104         Change the conditional link warning.
105         (mbscasestr): New declaration.
106         * m4/mbscasestr.m4: New file.
107         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
108         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
109         REPLACE_STRCASESTR.
110         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
111         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
112         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
113         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
114         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
115         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
116         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
117         (Depends-on): Remove mbuiter.
118         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
119
120 2007-02-04  Bruno Haible  <bruno@clisp.org>
121
122         Simplify handling of strncasecmp.
123         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
124         the conditional link warning.
125         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
126         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
127         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
128         * modules/strcase (configure.ac): Don't invoke
129         gl_STRING_MODULE_INDICATOR.
130         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
131
132 2007-02-04  Bruno Haible  <bruno@clisp.org>
133
134         New module mbscasecmp, reduced goal of strcasecmp.
135         * modules/mbscasecmp: New file.
136         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
137         (mbscasecmp): Renamed from strcasecmp.
138         * lib/strcasecmp.c: Don't include mbuiter.h.
139         (strcasecmp): Remove support for multibyte locales.
140         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
141         Change the conditional link warning.
142         (mbscasecmp): New declaration.
143         * m4/mbscasecmp.m4: New file.
144         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
145         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
146         REPLACE_STRCASECMP.
147         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
148         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
149         GNULIB_MBSCASECMP.
150         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
151         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
152         * modules/strcase (Files): Remove m4/mbrtowc.m4.
153         (Depends-on): Remove mbuiter.
154         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
155
156 2007-02-04  Bruno Haible  <bruno@clisp.org>
157
158         New module mbsstr. Remove module strstr.
159         * modules/mbsstr: New file.
160         * modules/strstr: Remove file.
161         * lib/mbsstr.c: Renamed from lib/strstr.c.
162         (mbsstr): Renamed from strstr.
163         * lib/string_.h (strstr): Remove declaration. Change the conditional
164         link warning.
165         (mbsstr): New declaration.
166         * m4/mbsstr.m4: New file.
167         * m4/strstr.m4: Remove file.
168         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
169         REPLACE_STRSTR.
170         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
171         Don't initialize GNULIB_STRSTR.
172         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
173         substitute GNULIB_STRSTR and REPLACE_STRSTR.
174         * MODULES.html.sh (Internationalization functions): Add mbsstr.
175         (Support for systems lacking ANSI C 89): Remove strstr.
176
177 2007-02-04  Bruno Haible  <bruno@clisp.org>
178
179         New module mbsrchr.
180         * modules/mbsrchr: New file.
181         * lib/mbsrchr.c: New file.
182         * lib/string_.h (strrchr): Add a conditional link warning.
183         (mbsrchr): New declaration.
184         * m4/mbsrchr.m4: New file.
185         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
186         GNULIB_MBSRCHR.
187         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
188         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
189
190 2007-02-04  Bruno Haible  <bruno@clisp.org>
191
192         New module mbschr.
193         * modules/mbschr: New file.
194         * lib/mbschr.c: New file.
195         * lib/string_.h (strchr): Add a conditional link warning.
196         (mbschr): New declaration.
197         * m4/mbschr.m4: New file.
198         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
199         GNULIB_MBSCHR.
200         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
201         * MODULES.html.sh (Internationalization functions): Add mbschr.
202
203 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
204
205         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
206
207         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
208
209 2007-02-04  Bruno Haible  <bruno@clisp.org>
210
211         New module description section 'configure.ac-early'.
212         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
213         (func_get_autoconf_early_snippet): New function.
214         (func_import, func_create_testdir): Use it. Remove special cases for
215         modules 'extensions' and 'lock'.
216         * modules/extensions (configure.ac-early): Require
217         gl_USE_SYSTEM_EXTENSIONS.
218         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
219
220 2007-02-04  Bruno Haible  <bruno@clisp.org>
221
222         Make use of gcj-4.3's -fsource and -ftarget option.
223         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
224         and if so try the options -fsource and -ftarget.
225         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
226         source_version, ftarget_option, target_version arguments.
227         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
228         (is_envjavac_oldgcj_14_14_usable): Renamed from
229         is_envjavac_gcj_14_14_usable.
230         (is_envjavac_oldgcj_14_13_usable): Renamed from
231         is_envjavac_gcj_14_13_usable.
232         (is_gcj_present): Update.
233         (is_gcj_43, is_gcj43_usable): New functions.
234         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
235         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
236         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
237         try the options -fsource and -ftarget.
238
239 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
240
241         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
242         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
243         larger value.
244
245 2007-02-03  Jim Meyering  <jim@meyering.net>
246
247         Give tools a better chance to allocate space for very large buffers.
248         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
249
250         Make pwd and readlink work also when run with an unreadable parent dir
251         on systems with openat support.
252         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
253         provided getcwd function, even when we have openat support.
254         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
255
256 2007-02-02  Bruno Haible  <bruno@clisp.org>
257
258         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
259         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
260         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
261         portability problems if one of these functions is only used on specific
262         platforms.
263         Reported by Paul Eggert.
264
265 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
266
267         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
268         is causing more trouble than it's curing.
269         * lib/regex_internal.h (__mempcpy): Remove.
270         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
271         (and make the code a tad smaller to boot).
272         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
273
274 2007-02-02  Jim Meyering  <jim@meyering.net>
275
276         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
277         section, not in the Makefile.am: one.
278
279 2007-02-02  Eric Blake  <ebb9@byu.net>
280
281         * lib/strchrnul.c: Always include config.h first.
282
283         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
284         gnulib strstr is not necessary here.
285
286 2007-02-02  Simon Josefsson  <simon@josefsson.org>
287
288         * m4/socklen.m4: Fix typo.
289
290 2007-02-02  Eric Blake  <ebb9@byu.net>
291
292         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
293         * modules/netinet_in (Makefile.am): Likewise.
294
295 2007-02-01  Bruno Haible  <bruno@clisp.org>
296
297         * lib/string_.h (GL_LINK_WARNING): New macro.
298         (strcasecmp, strstr, strcasestr): If provided by the system,
299         conditionally define as a macro that leads to a warning instead of to
300         an error.
301         (strncasecmp): Conditionally define as a macro that leads to a warning.
302
303 2007-02-01  Jim Meyering  <jim@meyering.net>
304
305         Give tools a better chance to allocate space for very large buffers.
306         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
307
308 2007-02-01  Karl Berry  <karl@gnu.org>
309
310         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
311
312 2007-02-01  Bruno Haible  <bruno@clisp.org>
313
314         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
315         renamings.
316
317 2007-02-01  Eric Blake  <ebb9@byu.net>
318
319         * modules/regex (Depends-on): Revert dependence on mempcpy.
320         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
321         module's definition of mempcpy.
322         Reported by Paul Eggert.
323
324 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
325
326         * lib/string_.h: If the gnulib module XYZ is not present, undefine
327         the symbol XYZ before redefining it.  This fixes a problem with
328         programs that don't use XYZ, when compiled on systems that define
329         XYZ to something else.
330
331 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
332
333         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
334         occurs when "mkdir -m foo" creates a setgid directory that is (1)
335         writeable to group or other and (2) is intended to have a special
336         mode bit that is set or cleared.  In such a case, the directory
337         should be neither group- nor other-writeable until the special
338         mode bits are right.
339
340 2007-01-31  Eric Blake  <ebb9@byu.net>
341
342         * modules/mountlist (Depends-on): Add strstr.
343
344         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
345         bug.
346         * modules/string (Makefile.am): Remove redundant replacement.
347         * modules/regex (Depends-on): Add mempcpy.
348
349 2007-01-31  Bruno Haible  <bruno@clisp.org>
350
351         New module description field 'Link'.
352         * gnulib-tool (func_usage): Document --extract-link-directive.
353         (sed_extract_prog): Recognize 'Link' directive.
354         (func_get_link_directive): New function.
355         (func_import): Show summary of link directives.
356         Handle --extract-link-directive option.
357         * modules/acl (Link): New section.
358         * modules/clock-time (Link): New section.
359         * modules/euidaccess (Link): New section.
360         * modules/gettext (Link): New section.
361         * modules/iconv (Link): New section.
362         * modules/lock (Link): New section.
363         * modules/nanosleep (Link): New section.
364         * modules/readline (Link): New section.
365
366 2007-01-27  Bruno Haible  <bruno@clisp.org>
367
368         Enforce the use of gnulib modules for unportable <string.h> functions.
369         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
370         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
371         (gl_HEADER_STRING_H_BODY): Require it.
372         * lib/string_.h: If the gnulib module XYZ is not present, redefine
373         the symbol XYZ to one that gives a link error.
374         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
375         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
376         * modules/mempcpy (configure.ac): Likewise.
377         * modules/memrchr (configure.ac): Likewise.
378         * modules/stpcpy (configure.ac): Likewise.
379         * modules/stpncpy (configure.ac): Likewise.
380         * modules/strcase (configure.ac): Likewise.
381         * modules/strcasestr (configure.ac): Likewise.
382         * modules/strchrnul (configure.ac): Likewise.
383         * modules/strdup (configure.ac): Likewise.
384         * modules/strndup (configure.ac): Likewise.
385         * modules/strnlen (configure.ac): Likewise.
386         * modules/strpbrk (configure.ac): Likewise.
387         * modules/strsep (configure.ac): Likewise.
388         * modules/strstr (configure.ac): Likewise.
389         * modules/strtok_r (configure.ac): Likewise.
390
391 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
392
393         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
394
395 2007-01-30  Jim Meyering  <jim@meyering.net>
396
397         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
398
399 2007-01-29  Bruno Haible  <bruno@clisp.org>
400
401         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
402         * lib/execute.c: Likewise.
403         * lib/pipe.c: Likewise.
404         * lib/printf-args.h: Likewise.
405         * lib/printf-args.c: Likewise.
406         * lib/printf-parse.c: Likewise.
407         * lib/vasnprintf.c: Likewise.
408
409 2007-01-29  Eric Blake  <ebb9@byu.net>
410
411         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
412         declaration.
413
414 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
415
416         * lib/strptime.h (strptime): Use 'restrict' for args where
417         POSIX requires this.
418         * lib/strptime.c (strptime): Likewise.
419         Change license notice from LGPL to GPL, since gnulib-tool will
420         change this as needed.
421         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
422         defined.
423         Include "strptime.h" first, to check interface.
424         Do not #undef _LIBC and _NL_CURRENT.
425         Do not include <stdlib.h>; no longer needed.
426         Include "time_r.h" and declare ptime_locale_status
427         only if _LIBC is not defined.
428         (__P): Remove unused macro.
429         (match_string): Bring back glibc version, but use it only if _LIBC
430         is defined.
431         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
432         Remove unnecessary assertion and abort() call.
433         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
434         * m4/strptime.m4: Fix serial number comment.
435         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
436         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
437         (Depends-on): Add time_r.
438
439 2007-01-29  Bruno Haible  <bruno@clisp.org>
440
441         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
442         strptime.
443         * modules/strptime (Depends-on): Add stdbool.
444         * lib/strptime.h: Include <time.h> always. Add comments.
445
446 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
447
448         * modules/strptime: New file.
449         * lib/strptime.h: New file.
450         * lib/strptime.c: New file.
451         * m4/strptime.m4: New file.
452
453 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
454
455         * MODULES.html.sh: New module mpsort.
456         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
457
458         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
459         a circularity problem with HP-UX ia64 reported by Bob Proulx in
460         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
461         All uses changed.
462         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
463         All uses changed.
464         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
465         to _Restrict_.
466         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
467         the parameter matches the prototype.
468
469 2007-01-28  Jim Meyering  <jim@meyering.net>
470
471         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
472         sys/time.h here, reverting that part of the previous patch:
473         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
474
475 2007-01-28  Bruno Haible  <bruno@clisp.org>
476
477         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
478         value of $(SYS_TIME_H).
479         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
480         remove it conditionally, too. [added by Jim Meyering]
481         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
482         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
483         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
484         GETTIMEOFDAY_REPLACEMENT to 1.
485
486 2007-01-28  Bruno Haible  <bruno@clisp.org>
487
488         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
489         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
490         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
491         Set UNISTD_H instead of UNISTD_H2.
492         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
493
494 2007-01-28  Bruno Haible  <bruno@clisp.org>
495
496         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
497         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
498
499 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
500
501         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
502         (func_create_testdir): Ensure C locale for `grep' and `tr'
503         character ranges.
504         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
505         ACLOCAL_AMFLAGS parsing state machine.
506
507 2007-01-27  Bruno Haible  <bruno@clisp.org>
508
509         * modules/unistr/base: Update.
510
511 2007-01-27  Bruno Haible  <bruno@clisp.org>
512
513         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
514         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
515         * modules/unistr/u32-mbtouc-unsafe: Renamed from
516         modules/unistr/u32-mbtouc.
517         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
518         * lib/unistr.h: Update.
519         * lib/linebreak.c: Update.
520         * modules/unistr/u32-mbtouc: Renamed from
521         modules/unistr/u32-mbtouc-safe.
522         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
523         * lib/unistr.h: Update.
524         * lib/unistr/u32-to-u8.c: Update.
525         * lib/unistr/u32-to-u16.c: Update.
526
527 2007-01-27  Bruno Haible  <bruno@clisp.org>
528
529         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
530         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
531         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
532         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
533         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
534         * modules/unistr/u16-mbtouc-unsafe: Renamed from
535         modules/unistr/u16-mbtouc.
536         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
537         * lib/unistr.h: Update.
538         * lib/linebreak.c: Update.
539         * modules/linebreak: Update.
540         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
541         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
542         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
543         * modules/unistr/u16-mbtouc: Renamed from
544         modules/unistr/u16-mbtouc-safe.
545         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
546         * lib/unistr.h: Update.
547         * lib/unistr/u16-to-u8.c: Update.
548         * modules/unistr/u16-to-u8: Update.
549         * lib/unistr/u16-to-u32.c: Update.
550         * modules/unistr/u16-to-u32: Update.
551
552 2007-01-27  Bruno Haible  <bruno@clisp.org>
553
554         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
555         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
556         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
557         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
558         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
559         * modules/unistr/u8-mbtouc-unsafe: Renamed from
560         modules/unistr/u8-mbtouc.
561         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
562         * lib/unistr.h: Update.
563         * lib/striconveh.c: Update.
564         * modules/striconveh: Update.
565         * lib/linebreak.c: Update.
566         * modules/linebreak: Update.
567         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
568         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
569         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
570         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
571         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
572         * lib/unistr.h: Update.
573         * lib/striconveh.c: Update.
574         * modules/striconveh: Update.
575         * lib/unistr/u8-to-u16.c: Update.
576         * modules/unistr/u8-to-u16: Update.
577         * lib/unistr/u8-to-u32.c: Update.
578         * modules/unistr/u8-to-u32: Update.
579
580 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
581
582         Sync from Libtool.
583         * lib/argz.c: Do not include strings.h nor memory.h, include
584         string.h unconditionally.  Patch by Simon Josefsson.
585
586 2007-01-27  Bruno Haible  <bruno@clisp.org>
587
588         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
589         from gl_HEADER_STRING_H_BODY.
590         (gl_HEADER_STRING_H_BODY): Require it.
591         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
592         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
593         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
594         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
595         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
596         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
597         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
598         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
599         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
600         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
601         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
602         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
603         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
604         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
605         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
606
607 2007-01-27  Bruno Haible  <bruno@clisp.org>
608
609         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
610         check_PROGRAMS into noinst_PROGRAMS.
611         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
612         check_PROGRAMS in this case.
613         (func_import): Set for_test to false.
614         (func_create_testdir): Set for_test to true.
615
616 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
617             Bruno Haible  <bruno@clisp.org>
618
619         * modules/strcasestr (Files): Remove lib/strcasestr.h.
620         (Depends-on): Add string.
621         (Includes): Use <string.h> instead of strcasestr.h.
622         * modules/string (Makefile.am): Also substitute the value of
623         REPLACE_STRCASESTR.
624         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
625         assume strcasestr is declared in <string.h> not <strings.h>. Also
626         set REPLACE_STRCASESTR.
627         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
628         REPLACE_STRCASESTR.
629         * lib/strcasestr.h: Remove file.
630         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
631         * lib/string_.h (strcasestr): New declaration.
632
633 2007-01-27  Bruno Haible  <bruno@clisp.org>
634
635         * lib/string_.h: Use 'extern'.
636
637 2007-01-27  Jim Meyering  <jim@meyering.net>
638
639         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
640         of set-but-not-used local, "q".
641
642         * lib/mempcpy.c: Include <config.h> before <string.h>.
643         This fixes a compilation error on HP-UX, due to the system's
644         "restrict"-using mempcpy prototype.
645
646 2007-01-26  Bruno Haible  <bruno@clisp.org>
647
648         Small optimization.
649         * lib/javacomp.c: Include c-strstr.h.
650          (is_envjavac_gcj): Use c_strstr instead of strstr.
651         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
652
653 2007-01-26  Bruno Haible  <bruno@clisp.org>
654
655         * MODULES.html.sh (Unicode string functions): Add the new modules.
656
657         * modules/uniconv/u32-strconv-to-locale: New file.
658         * lib/uniconv/u32-strconv-to-locale.c: New file.
659
660         * modules/uniconv/u16-strconv-to-locale: New file.
661         * lib/uniconv/u16-strconv-to-locale.c: New file.
662
663         * modules/uniconv/u8-strconv-to-locale: New file.
664         * lib/uniconv/u8-strconv-to-locale.c: New file.
665
666         * modules/uniconv/u32-strconv-from-locale: New file.
667         * lib/uniconv/u32-strconv-from-locale.c: New file.
668
669         * modules/uniconv/u16-strconv-from-locale: New file.
670         * lib/uniconv/u16-strconv-from-locale.c: New file.
671
672         * modules/uniconv/u8-strconv-from-locale: New file.
673         * lib/uniconv/u8-strconv-from-locale.c: New file.
674
675         * modules/uniconv/u32-strconv-to-enc: New file.
676         * lib/uniconv/u32-strconv-to-enc.c: New file.
677         * modules/uniconv/u32-strconv-to-enc-tests: New file.
678         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
679
680         * modules/uniconv/u16-strconv-to-enc: New file.
681         * lib/uniconv/u16-strconv-to-enc.c: New file.
682         * lib/uniconv/u-strconv-to-enc.h: New file.
683         * modules/uniconv/u16-strconv-to-enc-tests: New file.
684         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
685
686         * modules/uniconv/u8-strconv-to-enc: New file.
687         * lib/uniconv/u8-strconv-to-enc.c: New file.
688         * modules/uniconv/u8-strconv-to-enc-tests: New file.
689         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
690
691         * modules/uniconv/u32-strconv-from-enc: New file.
692         * lib/uniconv/u32-strconv-from-enc.c: New file.
693         * modules/uniconv/u32-strconv-from-enc-tests: New file.
694         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
695
696         * modules/uniconv/u16-strconv-from-enc: New file.
697         * lib/uniconv/u16-strconv-from-enc.c: New file.
698         * modules/uniconv/u16-strconv-from-enc-tests: New file.
699         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
700
701         * modules/uniconv/u8-strconv-from-enc: New file.
702         * lib/uniconv/u8-strconv-from-enc.c: New file.
703         * lib/uniconv/u-strconv-from-enc.h: New file.
704         * modules/uniconv/u8-strconv-from-enc-tests: New file.
705         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
706
707         * modules/uniconv/u32-conv-from-enc: New file.
708         * lib/uniconv/u32-conv-from-enc.c: New file.
709         * modules/uniconv/u32-conv-from-enc-tests: New file.
710         * tests/uniconv/test-u32-conv-from-enc.c: New file.
711
712         * modules/uniconv/u16-conv-from-enc: New file.
713         * lib/uniconv/u16-conv-from-enc.c: New file.
714         * lib/uniconv/u-conv-from-enc.h: New file.
715         * modules/uniconv/u16-conv-from-enc-tests: New file.
716         * tests/uniconv/test-u16-conv-from-enc.c: New file.
717
718         * modules/uniconv/u8-conv-from-enc: New file.
719         * lib/uniconv/u8-conv-from-enc.c: New file.
720         * modules/uniconv/u8-conv-from-enc-tests: New file.
721         * tests/uniconv/test-u8-conv-from-enc.c: New file.
722
723         * modules/uniconv/base: New file.
724         * lib/uniconv.h: New file.
725
726 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
727
728         * doc/gnulib-tool.texi (Initial import): Update to match current
729         behavior with strdup module.
730         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
731         * lib/memmem.h: Remove; all uses removed.  This is now done
732         by <string.h>.
733         * lib/mempcpy.h: Likewise.
734         * lib/memrchr.h: Likewise.
735         * lib/stpcpy.h: Likewise.
736         * lib/stpncpy.h: Likewise.
737         * lib/strcase.h: Likewise.
738         * lib/strchrnul.h: Likewise.
739         * lib/strdup.h: Likewise.
740         * lib/strndup.h: Likewise.
741         * lib/strnlen.h: Likewise.
742         * lib/strpbrk.h: Likewise.
743         * lib/strsep.h: Likewise.
744         * lib/strstr.h: Likewise.
745         * lib/strtok_r.h: Likewise.
746         * lib/string_.h: New file.
747         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
748         Rely on <string.h> instead.
749         * lib/canon-host.c: Likewise.
750         * lib/chdir-long.c: Likewise.
751         * lib/concatpath.c: Likewise.
752         * lib/exclude.c: Likewise.
753         * lib/fchdir.c: Likewise.
754         * lib/getaddrinfo.c: Likewise.
755         * lib/getcwd.c: Likewise.
756         * lib/getsubopt.c: Likewise.
757         * lib/glob.c: Likewise.
758         * lib/hard-locale.c: Likewise.
759         * lib/iconvme.c: Likewise.
760         * lib/javacomp.c: Likewise.
761         * lib/mempcpy.c: Likewise.
762         * lib/memrchr.c: Likewise.
763         * lib/regex_internal.h: Likewise.
764         * lib/stpncpy.c: Likewise.
765         * lib/strcasecmp.c: Likewise.
766         * lib/strchrnul.c: Likewise.
767         * lib/strdup.c: Likewise.
768         * lib/striconv.c: Likewise.
769         * lib/striconveh.c: Likewise.
770         * lib/striconveha.c: Likewise.
771         * lib/strncasecmp.c: Likewise.
772         * lib/strndup.c: Likewise.
773         * lib/strnlen.c: Likewise.
774         * lib/strsep.c: Likewise.
775         * lib/strstr.c: Likewise.
776         * lib/strtok_r.c: Likewise.
777         * lib/userspec.c: Likewise.
778         * lib/w32spawn.h: Likewise.
779         * lib/xstrndup.c: Likewise.
780         * lib/mountlist.c (strstr): Remove decl.
781         * m4/string_h.m4: New file.
782         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
783         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
784         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
785         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
786         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
787         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
788         Set REPLACE_STRCASECMP if necessary.
789         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
790         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
791         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
792         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
793         HAVE_DECL_STRDUP if necessary.
794         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
795         since gl_FUNC_STRNDUP does that now.
796         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
797         Check for decl here...
798         (gl_PREREQ_STRNLEN): ... not here.
799         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
800         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
801         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
802         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
803         necessary.
804         * modules/string: New file.
805         * modules/memmem (Files): Remove special-purpose include file.
806         (Depends-on): Add string.
807         (Include): Include <string.h>, not the removed file.
808         * modules/mempcpy: Likewise.
809         * modules/memrchr: Likewise.
810         * modules/stpcpy: Likewise.
811         * modules/stpncpy: Likewise.
812         * modules/strcase: Likewise.
813         * modules/strchrnul: Likewise.
814         * modules/strdup: Likewise.
815         * modules/strndup: Likewise.
816         * modules/strnlen: Likewise.
817         * modules/strpbrk: Likewise.
818         * modules/strsep: Likewise.
819         * modules/strstr: Likewise.
820         * modules/strtok_r: Likewise.
821         * tests/test-dirname.c: Don't include "strdup.h", since
822         <string.h> now suffices.
823         * tests/test-memmem.c: Don't include "memmem.h", since
824         <string.h> now suffices.
825
826 2007-01-25  Bruno Haible  <bruno@clisp.org>
827
828         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
829         *resultp is 0.
830
831         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
832         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
833         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
834         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
835
836         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
837         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
838         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
839         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
840         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
841         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
842
843 2007-01-24  Bruno Haible  <bruno@clisp.org>
844
845         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
846         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
847         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
848         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
849         gl_FUNC_FTS_CORE.
850         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
851         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
852         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
853         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
854         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
855         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
856         gl_FUNC_FCHOWNAT.
857         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
858         gl_FUNC_STRFTIME.
859         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
860         Reported by Ralf Wildenhues.
861
862 2007-01-24  Bruno Haible  <bruno@clisp.org>
863
864         Drop AC_REQUIRE calls that are redundant with the module dependencies.
865         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
866         gl_GETADDRINFO.
867         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
868         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
869         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
870
871 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
872
873         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
874         Don't use 'exit'; just return from 'main'.
875         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
876
877         * lib/fnmatch_.h: Readjust white space and comments to match
878         glibc, to avoid spurious diffs.
879
880 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
881
882         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
883         2004-12-01 change by Jakub Jelinek, since this code won't compile
884         if !LIBC.  Problem reported by Bob Proulx.
885
886 2007-01-23  Bruno Haible  <bruno@clisp.org>
887
888         * lib/striconveh.c: Include c-strcaseeq.h.
889         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
890         * modules/striconveh (Depends-on): Add c-strcaseeq.
891
892 2007-01-23  Bruno Haible  <bruno@clisp.org>
893
894         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
895
896         * modules/c-strcaseeq: New file.
897         * lib/c-strcaseeq.h: New file.
898
899         * modules/streq: New file.
900         * lib/streq.h: New file.
901
902 2007-01-23  Bruno Haible  <bruno@clisp.org>
903
904         * modules/striconveha-tests: New file.
905         * tests/test-striconveha.c: New file.
906
907         * lib/striconveha.h: Include <stdbool.h>.
908         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
909         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
910         (mem_iconveha_notranslit): Renamed from mem_iconveha.
911         (mem_iconveha): New function.
912         (str_iconveha_notranslit): Renamed from str_iconveha.
913         (str_iconveha): New function.
914         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
915         c-strcase.
916
917 2007-01-23  Bruno Haible  <bruno@clisp.org>
918
919         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
920         encodings without forgiving before trying any encoding with handler.
921         (str_iconveha): Try all encodings without forgiving before trying any
922         encoding with handler.
923
924 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
925
926         Import the following changes from libc.
927
928         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
929
930         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
931
932         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
933
934         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
935         normal_bracket label.
936
937         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
938
939         [BZ #361]
940         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
941         to normal_bracket after fetching the next character.
942
943 2007-01-22  Bruno Haible  <bruno@clisp.org>
944
945         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
946         argument.
947         * lib/striconveh.c (iconv_carefully_1): New function.
948         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
949         argument.
950         (str_cd_iconveh): Update.
951         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
952         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
953         * tests/test-striconveh.c (MAGIC): New macro.
954         (new_offsets): New function.
955         (main): Test call with and without offsets.
956
957 2007-01-22  Bruno Haible  <bruno@clisp.org>
958
959         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
960         * modules/sys_select (Makefile.am): Likewise.
961         * modules/sys_socket (Makefile.am): Likewise.
962         * modules/sys_time (Makefile.am): Likewise.
963
964 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
965
966         * modules/gettimeofday (License): Change from GPL to LGPL, since
967         gettimeofday is a library function.
968
969 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
970
971         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
972
973 2007-01-21  Bruno Haible  <bruno@clisp.org>
974
975         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
976
977 2007-01-21  Bruno Haible  <bruno@clisp.org>
978
979         * modules/striconveha: New file.
980         * lib/striconveha.h: New file.
981         * lib/striconveha.c: New file.
982         * MODULES.html.sh (Internationalization functions): Add striconveha.
983         * lib/striconv.c (str_iconv): Optimize the case of an empty input
984         string.
985         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
986
987 2007-01-21  Bruno Haible  <bruno@clisp.org>
988
989         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
990         * lib/striconveh.c (str_iconveh): Likewise.
991
992 2007-01-21  Bruno Haible  <bruno@clisp.org>
993
994         * lib/striconveh.h (mem_iconveh): New declaration.
995         * lib/striconveh.c (mem_iconveh): New function.
996         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
997
998 2007-01-21  Bruno Haible  <bruno@clisp.org>
999
1000         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
1001
1002         * lib/striconveh.h (mem_cd_iconveh): Change specification.
1003         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
1004         original result buffer.
1005         (str_cd_iconveh): Update.
1006         * tests/test-striconveh.c (main): Update.
1007
1008         * lib/striconv.h (mem_cd_iconv): Change specification.
1009         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
1010         result buffer.
1011         (str_cd_iconv): Update.
1012         * tests/test-striconv.c (main): Update.
1013
1014 2007-01-21  Bruno Haible  <bruno@clisp.org>
1015
1016         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
1017
1018 2007-01-20  Jim Meyering  <jim@meyering.net>
1019
1020         * lib/userspec.c (parse_with_separator): If a user or group string
1021         starts with "+", skip the corresponding name-to-ID look-up, since
1022         such a look-up must fail: user and group names may not include "+".
1023
1024 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
1025
1026         * lib/poll.c: Include sys/time.h and time.h unconditionally,
1027         since we now assume the sys_time module.
1028         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
1029         check for sys/time.h; no longer needed.
1030         * modules/poll (Depends-on): Depend on sys_time.
1031
1032 2007-01-18  Bruno Haible  <bruno@clisp.org>
1033
1034         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
1035         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
1036
1037         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
1038         gettimeofday.
1039
1040         * tests/test-gettimeofday.c: Include <time.h>.
1041         (dummy): Remove variable.
1042
1043         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
1044         gl_HEADER_SYS_TIME_H.
1045         (gl_HEADER_SYS_TIME_H): New macro.
1046
1047         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
1048         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1049         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
1050         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
1051         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1052         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
1053         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
1054         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1055         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
1056         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
1057         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1058
1059         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
1060         last change; it caused a compilation error when cross-compiling to
1061         Cygwin.
1062
1063 2007-01-18  Jim Meyering  <jim@meyering.net>
1064
1065         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
1066         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
1067         than the race-prone "test -d sys || mkdir sys".
1068         (configure.ac): Use AC_PROG_MKDIR_P.
1069         * modules/sys_select: Likewise.
1070         * modules/sys_socket: Likewise.
1071         * modules/sys_time: Likewise.
1072
1073 2007-01-18  Eric Blake  <ebb9@byu.net>
1074
1075         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
1076         replace gettimeofday.
1077         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
1078         name, to avoid infinite recursion.
1079
1080 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
1081
1082         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
1083         module sys_time.
1084         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
1085         assume timespec.h defines struct timeval.
1086         * lib/settime.c: Likewise.
1087         * lib/utimens.c: Likewise.
1088         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
1089         since we now assume the gettimeofday module.
1090         * lib/tempname.c (__gen_tempname): Likewise.
1091         * lib/gettimeofday.h: Remove.
1092         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
1093         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
1094         Include <time.h>, for 'time()'.
1095         (localtime_buffer_addr): Also use this workaround if
1096         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
1097         to simplify the uses.  All uses changed.
1098         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
1099         that #undef is inside {}, and 'const' follows type name consistently.
1100         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
1101         (gettimeofday): Do not use the maximum possible value for
1102         tv->tv_usec, since that might break usages other than ls.c.
1103         Instead, we'll leave ls.c alone.  This undoes today's patch
1104         by Bruno.  Add a compile-time warning for 1s-clock resolution;
1105         we've never observed the problem but might as well keep the
1106         canary.
1107         * lib/nanosleep.c: Include timespec.h first, for interface check.
1108         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
1109         now assume the sys_time module.
1110         * lib/tempname.c: Likewise.
1111         * lib/timespec.h: Likewise.
1112         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
1113         needed.
1114         * lib/strftime.c: Likewise.
1115         * lib/timespec.h: Likewise.
1116         * lib/posixtm.c: Include posixtm.h first, for interface check.
1117         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
1118         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
1119         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
1120         * lib/sys_time_.h: New file.
1121         * lib/timespec.h (struct timespec): Use long int, not long.
1122         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
1123         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
1124         Remove obsolescent call to AC_HEADER_TIME.
1125         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
1126         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
1127         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
1128         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
1129         Likewise.
1130         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
1131         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
1132         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
1133         into the sys_time module.  Check for gettimeofday just once.
1134         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
1135         for gettimeofday signature to just check the signature.  Merely
1136         compile it, since linking doesn't test signature.  Improve test for
1137         whether gettimeofday.o is actually needed.
1138         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
1139         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
1140         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
1141         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1142         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
1143         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
1144         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
1145         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
1146         than worrying about sys/time.h.
1147         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
1148         Don't bother worrying about TIME_WITH_SYS_TIME.
1149         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
1150         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
1151         * m4/sys_time_h.m4: New file.
1152         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
1153         Don't include sys/time.h.  Return from main rather than exiting.
1154         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
1155         all uses changed.
1156         * modules/gethrxtime (Depends-on): Add sys_time.
1157         * modules/gettime (Depends-on): Likewise.
1158         * modules/gettimeofday (Depends-on): Likewise.
1159         * modules/nanosleep (Depends-on): Likewise.
1160         * modules/settime (Depends-on): Likewise.
1161         * modules/tempname (Depends-on): Likewise.
1162         * modules/utimens (Depends-on): Likewise.
1163         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
1164         (Include:) Change back to <sys/time.h>.
1165         (Maintainer:) Add self.
1166         * modules/sys_time: New file.
1167         * modules/tempname (Depends-on): Add gettimeofday.
1168         * tests/test-gettimeofday.c: Include <sys/time.h>
1169         rather than gettimeofday.h.
1170
1171 2007-01-17  Bruno Haible  <bruno@clisp.org>
1172
1173         * gnulib-tool (func_get_license): Revert last patch. Instead, let
1174         the license default to GPL.
1175         (func_create_testdir): Don't complain if a module is LGPL and its
1176         tests module depends on GPLed modules.
1177
1178 2007-01-17  Bruno Haible  <bruno@clisp.org>
1179
1180         * lib/gettimeofday.c (gettimeofday): Add code for the case
1181         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
1182         maximum possible value for tv->tv_usec, rather than the minimum one.
1183
1184 2005-10-08  Martin Lambers  <marlam@marlam.de>
1185 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
1186 2007-01-16  Bruno Haible  <bruno@clisp.org>
1187
1188         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
1189         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
1190         gl_FUNC_GETTIMEOFDAY.
1191         (Include): Add gettimeofday.h.
1192         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
1193         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
1194         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
1195         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
1196         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
1197         * lib/gettimeofday.h: New file.
1198         * lib/gettimeofday.c: Include <sys/timeb.h>.
1199         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
1200         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
1201         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
1202         fall back on time().
1203
1204         * tests/test-gettimeofday.c: New file.
1205         * modules/gettimeofday-tests: New file.
1206
1207 2007-01-16  Eric Blake  <ebb9@byu.net>
1208
1209         * modules/fnmatch (Depends-on): Depend on wchar.
1210         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
1211         * m4/fnmatch.m4: Likewise.
1212         * modules/mbchar (Makefile.am): Assume <wchar.h>.
1213         * m4/mbchar.m4: Likewise.
1214         * modules/mbswidth (Depends-on): Depend on wchar.
1215         * lib/mbswidth.c: Assume <wchar.h>.
1216         * m4/mbswidth.m4: Likewise.
1217         * modules/quotearg (Depends-on): Depend on wchar.
1218         * lib/quotearg.c: Assume <wchar.h>.
1219         * m4/quotearg.m4: Likewise.
1220         * modules/regex (Depends-on): Depend on wchar.
1221         * lib/regex_internal.h: Assume <wchar.h>.
1222         * m4/regex.m4: Likewise.
1223         * modules/stdint (Depends-on): Depend on wchar.
1224         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
1225         * m4/stdint.m4: Likewise.
1226         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
1227         * modules/strftime (Depends-on): Depend on wchar.
1228         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
1229         * modules/strtol (Depends-on): Depend on wchar.
1230         * lib/strtol.c: Assume <wchar.h>.
1231         * modules/wcwidth (Depends-on): Depend on wchar.
1232         * lib/wcwidth.h: Assume <wchar.h>.
1233         * m4/wcwidth.m4: Likewise.
1234
1235 2007-01-16  Bruno Haible  <bruno@clisp.org>
1236
1237         * modules/csharpexec-script: New, created from...
1238         * modules/csharpexec: ... this.
1239
1240 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
1241
1242         * modules/javaexec-script: New, created from...
1243         * modules/javaexec: ... this.
1244
1245 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1246
1247         * modules/poll (Dependencies): Add sys_select.
1248
1249 2007-01-15  Jim Meyering  <jim@meyering.net>
1250
1251         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
1252         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
1253         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
1254         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
1255
1256 2007-01-15  Bruno Haible  <bruno@clisp.org>
1257
1258         * modules/striconveh: New file.
1259         * lib/striconveh.h: New file.
1260         * lib/striconveh.c: New file.
1261         * MODULES.html.sh (Internationalization functions): Add striconveh.
1262
1263         * modules/striconveh-tests: New file.
1264         * tests/test-striconveh.c: New file.
1265
1266 2007-01-15  Bruno Haible  <bruno@clisp.org>
1267
1268         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
1269         not from GNU libiconv or GNU libc.
1270
1271 2007-01-15  Bruno Haible  <bruno@clisp.org>
1272
1273         * doc/gnulib-intro.texi (Copyright): Explain the different license
1274         terms for module descriptions, autoconf macros, tests, documentation.
1275
1276 2007-01-14  Bruno Haible  <bruno@clisp.org>
1277
1278         * modules/striconv-tests: New file.
1279         * tests/test-striconv.c: New file.
1280
1281 2007-01-14  Bruno Haible  <bruno@clisp.org>
1282
1283         * modules/iconv-tests: New file.
1284         * tests/test-iconv.c: New file.
1285
1286 2007-01-14  Bruno Haible  <bruno@clisp.org>
1287
1288         * gnulib-tool (func_get_license): For test modules, use the license of
1289         the main module.
1290
1291 2007-01-14  Bruno Haible  <bruno@clisp.org>
1292
1293         * modules/iconv (Include): Clarify that <iconv.h> can only be included
1294         if iconv is found to exist.
1295
1296 2007-01-14  Bruno Haible  <bruno@clisp.org>
1297
1298         * modules/c-ctype-tests: New file.
1299         * tests/test-c-ctype.c: New file.
1300
1301 2007-01-14  Bruno Haible  <bruno@clisp.org>
1302
1303         * modules/binary-io-tests: New file.
1304         * tests/test-binary-io.sh: New file.
1305         * tests/test-binary-io.c: New file.
1306
1307 2007-01-14  Bruno Haible  <bruno@clisp.org>
1308
1309         * modules/array-oset-tests: New file.
1310         * tests/test-array_oset.c: New file.
1311
1312 2007-01-14  Bruno Haible  <bruno@clisp.org>
1313
1314         * modules/array-list-tests: New file.
1315         * tests/test-array_list.c: New file.
1316
1317 2007-01-14  Bruno Haible  <bruno@clisp.org>
1318
1319         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
1320         and make.
1321         Reported by Simon Josefsson in
1322         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
1323
1324 2007-01-14  Bruno Haible  <bruno@clisp.org>
1325
1326         * modules/allocsa-tests: New file.
1327         * tests/test-allocsa.c: New file.
1328
1329 2007-01-14  Bruno Haible  <bruno@clisp.org>
1330
1331         * modules/fchdir (Depends-on): Add absolute-header.
1332         * modules/unistd (Depends-on): Likewise.
1333
1334 2006-12-30  Bruno Haible  <bruno@clisp.org>
1335
1336         * modules/fchdir: New file.
1337         * modules/unistd (Files): Add lib/unistd_.h.
1338         (Makefile.am): Generate unistd.h from unistd_.h.
1339         * lib/fchdir.c: New file.
1340         * lib/dirent_.h: New file.
1341         * lib/unistd_.h: New file.
1342         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
1343         * m4/fchdir.m4: New file.
1344         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
1345         (gl_HEADER_UNISTD): Invoke it.
1346         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
1347         function.
1348         * lib/backupfile.c (opendir, closedir): Undefine.
1349         * lib/chown.c (open, close): Undefine.
1350         * lib/clean-temp.c (open, close): Undefine.
1351         * lib/copy-file.c (open, close): Undefine.
1352         * lib/execute.c (open, close): Undefine.
1353         * lib/fsusage.c (open, close): Undefine.
1354         * lib/gc-gnulib.c (open, close): Undefine.
1355         * lib/getcwd.c (opendir, closedir): Undefine.
1356         * lib/glob.c (opendir, closedir): Undefine.
1357         * lib/javacomp.c (open, close): Undefine.
1358         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
1359         * lib/openat-proc.c (open, close): Undefine.
1360         * lib/pagealign_alloc.c (open, close): Undefine.
1361         * lib/pipe.c (open, close): Undefine.
1362         * lib/progreloc.c (open, close): Undefine.
1363         * lib/savedir.c (opendir, closedir): Undefine.
1364         * lib/utime.c (open, close): Undefine.
1365         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
1366
1367 2007-01-10  Bruno Haible  <bruno@clisp.org>
1368
1369         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
1370
1371 2007-01-12  Eric Blake  <ebb9@byu.net>
1372
1373         Provide a robust <wchar.h>.  Further simplifications are now
1374         possible in other modules, but not included here.
1375         * modules/wchar: New module.
1376         * m4/wchar.m4: New file.
1377         * lib/wchar_.h: Likewise.
1378         * modules/mbchar (Depends-on): Depend on wchar, as the first use
1379         of the new module.
1380         * MODULES.html.sh (Extended multibyte and wide character utilities):
1381         New section.
1382
1383 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
1384
1385         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
1386         to a reasonable default for memory allocation.
1387         (xreadlink): Don't allocate a huge buffer, to work around a buggy
1388         file system that reports garbage st_size values for symlinks.
1389         Problem reported by Liyang Hu.
1390
1391 2007-01-11  Simon Josefsson  <simon@josefsson.org>
1392
1393         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
1394         Emacs .#* auto-save files).
1395
1396 2007-01-11  Bruno Haible  <bruno@clisp.org>
1397
1398         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
1399         directory.
1400
1401 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
1402
1403         Use @...@ consistently in lib/wctype_.h.
1404         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
1405         on it being set to 1 or 0.
1406         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
1407         go back to AC_SUBSTing it.
1408         * modules/wctype (Makefile.am): Undo previous change.
1409
1410 2007-01-10  Eric Blake  <ebb9@byu.net>
1411
1412         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
1413         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
1414         * modules/wctype (Makefile.am): Likewise.
1415         Reported by Chris McGuire.
1416
1417 2007-01-10  Jim Meyering  <jim@meyering.net>
1418
1419         fts.c: a small readability/maintainability improvement
1420         * lib/fts.c (fts_read): Make this code slightly more readable and
1421         maintainable by hoisting the "sp->fts_cur = p" assignments to
1422         immediately follow the statements that set P.  Derived from
1423         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
1424
1425 2007-01-10  Eric Blake  <ebb9@byu.net>
1426
1427         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
1428         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
1429         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
1430         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
1431         Reported by Chris McGuire.
1432
1433 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1434
1435         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
1436         in sed script.
1437
1438 2007-01-09  Bruno Haible  <bruno@clisp.org>
1439
1440         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
1441         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
1442         variables.
1443         (func_module): Use them.
1444
1445 2007-01-09  Bruno Haible  <bruno@clisp.org>
1446
1447         * modules/unistr/base: New file.
1448         * lib/unistr.h: New file.
1449
1450         * modules/unistr/u8-to-u16: New file.
1451         * lib/unistr/u8-to-u16.c: New file.
1452
1453         * modules/unistr/u8-to-u32: New file.
1454         * lib/unistr/u8-to-u32.c: New file.
1455
1456         * modules/unistr/u16-to-u8: New file.
1457         * lib/unistr/u16-to-u8.c: New file.
1458
1459         * modules/unistr/u16-to-u32: New file.
1460         * lib/unistr/u16-to-u32.c: New file.
1461
1462         * modules/unistr/u32-to-u8: New file.
1463         * lib/unistr/u32-to-u8.c: New file.
1464
1465         * modules/unistr/u32-to-u16: New file.
1466         * lib/unistr/u32-to-u16.c: New file.
1467
1468         * modules/unistr/u8-check: New file.
1469         * modules/unistr/u16-check: New file.
1470         * modules/unistr/u32-check: New file.
1471         * lib/unistr/u8-check.c: New file.
1472         * lib/unistr/u16-check.c: New file.
1473         * lib/unistr/u32-check.c: New file.
1474
1475         * modules/unistr/u8-chr: New file.
1476         * modules/unistr/u16-chr: New file.
1477         * modules/unistr/u32-chr: New file.
1478         * lib/unistr/u8-chr.c: New file.
1479         * lib/unistr/u16-chr.c: New file.
1480         * lib/unistr/u32-chr.c: New file.
1481
1482         * modules/unistr/u8-cmp: New file.
1483         * modules/unistr/u16-cmp: New file.
1484         * modules/unistr/u32-cmp: New file.
1485         * lib/unistr/u8-cmp.c: New file.
1486         * lib/unistr/u16-cmp.c: New file.
1487         * lib/unistr/u32-cmp.c: New file.
1488
1489         * modules/unistr/u8-cpy: New file.
1490         * modules/unistr/u16-cpy: New file.
1491         * modules/unistr/u32-cpy: New file.
1492         * lib/unistr/u8-cpy.c: New file.
1493         * lib/unistr/u16-cpy.c: New file.
1494         * lib/unistr/u32-cpy.c: New file.
1495         * lib/unistr/u-cpy.h: New file.
1496
1497         * modules/unistr/u8-cpy-alloc: New file.
1498         * modules/unistr/u16-cpy-alloc: New file.
1499         * modules/unistr/u32-cpy-alloc: New file.
1500         * lib/unistr/u8-cpy-alloc.c: New file.
1501         * lib/unistr/u16-cpy-alloc.c: New file.
1502         * lib/unistr/u32-cpy-alloc.c: New file.
1503         * lib/unistr/u-cpy-alloc.h: New file.
1504
1505         * modules/unistr/u8-endswith: New file.
1506         * modules/unistr/u16-endswith: New file.
1507         * modules/unistr/u32-endswith: New file.
1508         * lib/unistr/u8-endswith.c: New file.
1509         * lib/unistr/u16-endswith.c: New file.
1510         * lib/unistr/u32-endswith.c: New file.
1511         * lib/unistr/u-endswith.h: New file.
1512
1513         * modules/unistr/u8-mblen: New file.
1514         * modules/unistr/u16-mblen: New file.
1515         * modules/unistr/u32-mblen: New file.
1516         * lib/unistr/u8-mblen.c: New file.
1517         * lib/unistr/u16-mblen.c: New file.
1518         * lib/unistr/u32-mblen.c: New file.
1519
1520         * modules/unistr/u8-mbtouc: New file.
1521         * modules/unistr/u16-mbtouc: New file.
1522         * modules/unistr/u32-mbtouc: New file.
1523         * lib/unistr/u8-mbtouc.c: New file.
1524         * lib/unistr/u16-mbtouc.c: New file.
1525         * lib/unistr/u32-mbtouc.c: New file.
1526
1527         * modules/unistr/u8-mbtouc-safe: New file.
1528         * modules/unistr/u16-mbtouc-safe: New file.
1529         * modules/unistr/u32-mbtouc-safe: New file.
1530         * lib/unistr/u8-mbtouc-safe.c: New file.
1531         * lib/unistr/u16-mbtouc-safe.c: New file.
1532         * lib/unistr/u32-mbtouc-safe.c: New file.
1533
1534         * modules/unistr/u8-move: New file.
1535         * modules/unistr/u16-move: New file.
1536         * modules/unistr/u32-move: New file.
1537         * lib/unistr/u8-move.c: New file.
1538         * lib/unistr/u16-move.c: New file.
1539         * lib/unistr/u32-move.c: New file.
1540         * lib/unistr/u-move.h: New file.
1541
1542         * modules/unistr/u8-next: New file.
1543         * modules/unistr/u16-next: New file.
1544         * modules/unistr/u32-next: New file.
1545         * lib/unistr/u8-next.c: New file.
1546         * lib/unistr/u16-next.c: New file.
1547         * lib/unistr/u32-next.c: New file.
1548
1549         * modules/unistr/u8-prev: New file.
1550         * modules/unistr/u16-prev: New file.
1551         * modules/unistr/u32-prev: New file.
1552         * lib/unistr/u8-prev.c: New file.
1553         * lib/unistr/u16-prev.c: New file.
1554         * lib/unistr/u32-prev.c: New file.
1555
1556         * modules/unistr/u8-set: New file.
1557         * modules/unistr/u16-set: New file.
1558         * modules/unistr/u32-set: New file.
1559         * lib/unistr/u8-set.c: New file.
1560         * lib/unistr/u16-set.c: New file.
1561         * lib/unistr/u32-set.c: New file.
1562         * lib/unistr/u-set.h: New file.
1563
1564         * modules/unistr/u8-startswith: New file.
1565         * modules/unistr/u16-startswith: New file.
1566         * modules/unistr/u32-startswith: New file.
1567         * lib/unistr/u8-startswith.c: New file.
1568         * lib/unistr/u16-startswith.c: New file.
1569         * lib/unistr/u32-startswith.c: New file.
1570         * lib/unistr/u-startswith.h: New file.
1571
1572         * modules/unistr/u8-stpcpy: New file.
1573         * modules/unistr/u16-stpcpy: New file.
1574         * modules/unistr/u32-stpcpy: New file.
1575         * lib/unistr/u8-stpcpy.c: New file.
1576         * lib/unistr/u16-stpcpy.c: New file.
1577         * lib/unistr/u32-stpcpy.c: New file.
1578         * lib/unistr/u-stpcpy.h: New file.
1579
1580         * modules/unistr/u8-stpncpy: New file.
1581         * modules/unistr/u16-stpncpy: New file.
1582         * modules/unistr/u32-stpncpy: New file.
1583         * lib/unistr/u8-stpncpy.c: New file.
1584         * lib/unistr/u16-stpncpy.c: New file.
1585         * lib/unistr/u32-stpncpy.c: New file.
1586         * lib/unistr/u-stpncpy.h: New file.
1587
1588         * modules/unistr/u8-strcat: New file.
1589         * modules/unistr/u16-strcat: New file.
1590         * modules/unistr/u32-strcat: New file.
1591         * lib/unistr/u8-strcat.c: New file.
1592         * lib/unistr/u16-strcat.c: New file.
1593         * lib/unistr/u32-strcat.c: New file.
1594         * lib/unistr/u-strcat.h: New file.
1595
1596         * modules/unistr/u8-strchr: New file.
1597         * modules/unistr/u16-strchr: New file.
1598         * modules/unistr/u32-strchr: New file.
1599         * lib/unistr/u8-strchr.c: New file.
1600         * lib/unistr/u16-strchr.c: New file.
1601         * lib/unistr/u32-strchr.c: New file.
1602
1603         * modules/unistr/u8-strcmp: New file.
1604         * modules/unistr/u16-strcmp: New file.
1605         * modules/unistr/u32-strcmp: New file.
1606         * lib/unistr/u8-strcmp.c: New file.
1607         * lib/unistr/u16-strcmp.c: New file.
1608         * lib/unistr/u32-strcmp.c: New file.
1609
1610         * modules/unistr/u8-strcpy: New file.
1611         * modules/unistr/u16-strcpy: New file.
1612         * modules/unistr/u32-strcpy: New file.
1613         * lib/unistr/u8-strcpy.c: New file.
1614         * lib/unistr/u16-strcpy.c: New file.
1615         * lib/unistr/u32-strcpy.c: New file.
1616         * lib/unistr/u-strcpy.h: New file.
1617
1618         * modules/unistr/u8-strcspn: New file.
1619         * modules/unistr/u16-strcspn: New file.
1620         * modules/unistr/u32-strcspn: New file.
1621         * lib/unistr/u8-strcspn.c: New file.
1622         * lib/unistr/u16-strcspn.c: New file.
1623         * lib/unistr/u32-strcspn.c: New file.
1624         * lib/unistr/u-strcspn.h: New file.
1625
1626         * modules/unistr/u8-strdup: New file.
1627         * modules/unistr/u16-strdup: New file.
1628         * modules/unistr/u32-strdup: New file.
1629         * lib/unistr/u8-strdup.c: New file.
1630         * lib/unistr/u16-strdup.c: New file.
1631         * lib/unistr/u32-strdup.c: New file.
1632         * lib/unistr/u-strdup.h: New file.
1633
1634         * modules/unistr/u8-strlen: New file.
1635         * modules/unistr/u16-strlen: New file.
1636         * modules/unistr/u32-strlen: New file.
1637         * lib/unistr/u8-strlen.c: New file.
1638         * lib/unistr/u16-strlen.c: New file.
1639         * lib/unistr/u32-strlen.c: New file.
1640         * lib/unistr/u-strlen.h: New file.
1641
1642         * modules/unistr/u8-strmblen: New file.
1643         * modules/unistr/u16-strmblen: New file.
1644         * modules/unistr/u32-strmblen: New file.
1645         * lib/unistr/u8-strmblen.c: New file.
1646         * lib/unistr/u16-strmblen.c: New file.
1647         * lib/unistr/u32-strmblen.c: New file.
1648
1649         * modules/unistr/u8-strmbtouc: New file.
1650         * modules/unistr/u16-strmbtouc: New file.
1651         * modules/unistr/u32-strmbtouc: New file.
1652         * lib/unistr/u8-strmbtouc.c: New file.
1653         * lib/unistr/u16-strmbtouc.c: New file.
1654         * lib/unistr/u32-strmbtouc.c: New file.
1655
1656         * modules/unistr/u8-strncat: New file.
1657         * modules/unistr/u16-strncat: New file.
1658         * modules/unistr/u32-strncat: New file.
1659         * lib/unistr/u8-strncat.c: New file.
1660         * lib/unistr/u16-strncat.c: New file.
1661         * lib/unistr/u32-strncat.c: New file.
1662         * lib/unistr/u-strncat.h: New file.
1663
1664         * modules/unistr/u8-strncmp: New file.
1665         * modules/unistr/u16-strncmp: New file.
1666         * modules/unistr/u32-strncmp: New file.
1667         * lib/unistr/u8-strncmp.c: New file.
1668         * lib/unistr/u16-strncmp.c: New file.
1669         * lib/unistr/u32-strncmp.c: New file.
1670
1671         * modules/unistr/u8-strncpy: New file.
1672         * modules/unistr/u16-strncpy: New file.
1673         * modules/unistr/u32-strncpy: New file.
1674         * lib/unistr/u8-strncpy.c: New file.
1675         * lib/unistr/u16-strncpy.c: New file.
1676         * lib/unistr/u32-strncpy.c: New file.
1677         * lib/unistr/u-strncpy.h: New file.
1678
1679         * modules/unistr/u8-strnlen: New file.
1680         * modules/unistr/u16-strnlen: New file.
1681         * modules/unistr/u32-strnlen: New file.
1682         * lib/unistr/u8-strnlen.c: New file.
1683         * lib/unistr/u16-strnlen.c: New file.
1684         * lib/unistr/u32-strnlen.c: New file.
1685         * lib/unistr/u-strnlen.h: New file.
1686
1687         * modules/unistr/u8-strpbrk: New file.
1688         * modules/unistr/u16-strpbrk: New file.
1689         * modules/unistr/u32-strpbrk: New file.
1690         * lib/unistr/u8-strpbrk.c: New file.
1691         * lib/unistr/u16-strpbrk.c: New file.
1692         * lib/unistr/u32-strpbrk.c: New file.
1693         * lib/unistr/u-strpbrk.h: New file.
1694
1695         * modules/unistr/u8-strrchr: New file.
1696         * modules/unistr/u16-strrchr: New file.
1697         * modules/unistr/u32-strrchr: New file.
1698         * lib/unistr/u8-strrchr.c: New file.
1699         * lib/unistr/u16-strrchr.c: New file.
1700         * lib/unistr/u32-strrchr.c: New file.
1701
1702         * modules/unistr/u8-strspn: New file.
1703         * modules/unistr/u16-strspn: New file.
1704         * modules/unistr/u32-strspn: New file.
1705         * lib/unistr/u8-strspn.c: New file.
1706         * lib/unistr/u16-strspn.c: New file.
1707         * lib/unistr/u32-strspn.c: New file.
1708         * lib/unistr/u-strspn.h: New file.
1709
1710         * modules/unistr/u8-strstr: New file.
1711         * modules/unistr/u16-strstr: New file.
1712         * modules/unistr/u32-strstr: New file.
1713         * lib/unistr/u8-strstr.c: New file.
1714         * lib/unistr/u16-strstr.c: New file.
1715         * lib/unistr/u32-strstr.c: New file.
1716         * lib/unistr/u-strstr.h: New file.
1717
1718         * modules/unistr/u8-strtok: New file.
1719         * modules/unistr/u16-strtok: New file.
1720         * modules/unistr/u32-strtok: New file.
1721         * lib/unistr/u8-strtok.c: New file.
1722         * lib/unistr/u16-strtok.c: New file.
1723         * lib/unistr/u32-strtok.c: New file.
1724         * lib/unistr/u-strtok.h: New file.
1725
1726         * modules/unistr/u8-uctomb: New file.
1727         * modules/unistr/u16-uctomb: New file.
1728         * modules/unistr/u32-uctomb: New file.
1729         * lib/unistr/u8-uctomb.c: New file.
1730         * lib/unistr/u16-uctomb.c: New file.
1731         * lib/unistr/u32-uctomb.c: New file.
1732
1733         * MODULES.html.sh (Unicode string functions): Add the new modules.
1734
1735 2007-01-08  Bruno Haible  <bruno@clisp.org>
1736
1737         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
1738         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
1739         subdirectories.
1740
1741 2007-01-08  Karl Berry  <karl@gnu.org>
1742
1743         * doc/error.texi: mention that main() fns must set program_name
1744         when progname is used.
1745
1746 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
1747
1748         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
1749         WCTYPE_H is empty, for the benefit of builds from non-distclean
1750         directories.  Problem reported by Eric Blake in
1751         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
1752
1753 2007-01-08  Bruno Haible  <bruno@clisp.org>
1754
1755         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
1756         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
1757         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
1758         PROVIDE_CANONICALIZE_FILENAME_MODE.
1759         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
1760
1761 2007-01-08  Bruno Haible  <bruno@clisp.org>
1762
1763         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
1764         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
1765         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
1766         * lib/fts.c: Likewise.
1767         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
1768
1769 2006-12-25  Bruno Haible  <bruno@clisp.org>
1770
1771         * modules/utf8-ucs4-safe: New file.
1772         * lib/utf8-ucs4-safe.h: New file.
1773         * lib/unistr/utf8-ucs4-safe.c: New file.
1774
1775         * modules/utf16-ucs4-safe: New file.
1776         * lib/utf16-ucs4-safe.h: New file.
1777         * lib/unistr/utf16-ucs4-safe.c: New file.
1778
1779         * MODULES.html.sh (Unicode string functions): Add the new modules.
1780
1781 2007-01-08  Bruno Haible  <bruno@clisp.org>
1782
1783         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
1784         (Depends-on): Add unitypes.
1785         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
1786         (u8_mbtouc_aux): Move out to separate file.
1787         (u8_mbtouc): Use ucs4_t, uint8_t types.
1788         * lib/unistr/utf8-ucs4.c: New file.
1789
1790         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
1791         (Depends-on): Add unitypes.
1792         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
1793         (u16_mbtouc_aux): Move out to separate file.
1794         (u16_mbtouc): Use ucs4_t, uint16_t types.
1795         * lib/unistr/utf16-ucs4.c: New file.
1796
1797         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
1798         (Depends-on): Add unitypes.
1799         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
1800         (u8_uctomb_aux): Move out to separate file.
1801         (u8_uctomb): Use ucs4_t, uint8_t types.
1802         * lib/unistr/ucs4-utf8.c: New file.
1803
1804         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
1805         (Depends-on): Add unitypes.
1806         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
1807         (u16_uctomb_aux): Move out to separate file.
1808         (u16_uctomb): Use ucs4_t, uint16_t types.
1809         * lib/unistr/ucs4-utf16.c: New file.
1810
1811 2006-12-25  Bruno Haible  <bruno@clisp.org>
1812
1813         * modules/unitypes: New file.
1814         * lib/unitypes.h: New file.
1815         * MODULES.html.sh (func_all_modules): New section "Unicode string
1816         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
1817         this section. Add unitypes.
1818
1819 2007-01-08  Bruno Haible  <bruno@clisp.org>
1820
1821         Avoid variable names that conflict with those from libtool.
1822         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
1823         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
1824         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
1825         library_names_spec to acl_library_names_spec, hardcode_* to
1826         acl_hardcode_*.
1827         Reported by Ralf Wildenhues.
1828
1829 2007-01-08  Bruno Haible  <bruno@clisp.org>
1830
1831         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
1832         definition.
1833         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
1834         definition.
1835         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
1836         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
1837         definition.
1838         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
1839         definition.
1840         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
1841         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
1842         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
1843         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
1844         definition.
1845         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
1846         definition.
1847         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
1848         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
1849         GC_USE_<algorithm>.
1850         * lib/gc-libgcrypt.c: Likewise.
1851         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
1852         * modules/gc-arctwo (configure.ac): Likewise.
1853         * modules/gc-des (configure.ac): Likewise.
1854         * modules/gc-hmac-md5 (configure.ac): Likewise.
1855         * modules/gc-hmac-sha1 (configure.ac): Likewise.
1856         * modules/gc-md2 (configure.ac): Likewise.
1857         * modules/gc-md4 (configure.ac): Likewise.
1858         * modules/gc-md5 (configure.ac): Likewise.
1859         * modules/gc-random (configure.ac): Likewise.
1860         * modules/gc-rijndael (configure.ac): Likewise.
1861         * modules/gc-sha1 (configure.ac): Likewise.
1862
1863 2007-01-08  Bruno Haible  <bruno@clisp.org>
1864
1865         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
1866         macro definition.
1867         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
1868         definition.
1869         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
1870         definition.
1871         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
1872         * modules/fcntl-safer (configure.ac): Likewise.
1873         * modules/fopen-safer (configure.ac): Likewise.
1874         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
1875         GNULIB_FWRITEERROR macro definition.
1876
1877 2007-01-08  Bruno Haible  <bruno@clisp.org>
1878
1879         * m4/gnulib-common.m4: New file.
1880         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
1881         (func_get_filelist): Add m4/gnulib-common.m4.
1882
1883 2007-01-08  Bruno Haible  <bruno@clisp.org>
1884
1885         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
1886         command.
1887
1888 2007-01-08  Jim Meyering  <jim@meyering.net>
1889
1890         Use a more robust test for a "can't happen" condition.
1891         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
1892         narrowed the st_size value.  Presuming the "can't happen" condition
1893         is true, that narrowing could conceivably convert an invalid st_size
1894         value into a valid one.  Instead, use a change based on Matthew
1895         Woehlke's original patch.
1896
1897         Slight readability improvement: use an assert-like macro
1898         in place of literal "abort ()" uses.
1899         * lib/fts.c (fts_assert): Define.
1900         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
1901         Use this macro instead of a bare 'abort'.
1902
1903 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
1904
1905         Don't worry about using IRIX 5.3's wctype.h broken definitions;
1906         simply work around them.
1907         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
1908         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
1909         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
1910         Don't bother to define as macros, since the standard doesn't require it.
1911         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
1912         longer worry about IRIX 5.3.
1913         (HAVE_WCTYPE_CTMP_BUG): Remove.
1914
1915 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
1916
1917         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
1918         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
1919         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1920         Problems reported by Georg Schwarz for IRIX 5.3.
1921
1922         * gnulib-tool (autoconf_minversion): Take the maximum version number
1923         found, not the minimum.  Problem reported by James Youngman.
1924
1925 2007-01-03  Karl Berry  <karl@gnu.org>
1926
1927         * doc/error.texi: new file, explaining interaction with progname.
1928         * doc/gnulib.texi: include it.  Update copyright.
1929
1930 2007-01-03  Simon Josefsson  <simon@josefsson.org>
1931
1932         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
1933         AC_CANONICAL_HOST, to improve autobuild outputs.
1934
1935 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
1936             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
1937
1938         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
1939         sockets, server sockets, and other file descriptors.  Count errors
1940         to compute the return value.  Reorder the code a bit to be easier
1941         to follow.  Don't set event bits that were not requested (except
1942         POLLERR and POLLHUP).
1943
1944 2007-01-01  Bruno Haible  <bruno@clisp.org>
1945
1946         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
1947
1948 2007-01-03  Jim Meyering  <jim@meyering.net>
1949
1950         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
1951
1952 2007-01-02  Bruno Haible  <bruno@clisp.org>
1953
1954         * modules/settime (Include): Require timespec.h.
1955         * modules/nanosleep (Include): Likewise.
1956
1957 2007-01-01  Bruno Haible  <bruno@clisp.org>
1958
1959         * gnulib-tool (func_emit_copyright_notice): Bump year.
1960         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
1961
1962 2007-01-01  Bruno Haible  <bruno@clisp.org>
1963
1964         Improve support for OpenBSD.
1965         * build-aux/config.rpath (libname_spec): Export.
1966         (library_names_spec): New variable. Export.
1967         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
1968         library_names_spec from the config.rpath output. Locate shared library
1969         through the name pattern in library_names_spec.
1970
1971 2007-01-01  Eric Blake  <ebb9@byu.net>
1972
1973         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
1974
1975 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
1976
1977         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
1978         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
1979         assume the C locale, and avoid an "eval" that could cause trouble.
1980         Problem with SORT reported by Bob Proulx.
1981
1982         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
1983         Define.  Trivial patch from Henning Nielsen Lund, originally
1984         sent to bug-grep@gnu.org today.
1985
1986 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
1987
1988         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
1989         struct stat.  Problem reported by Henning Nielsen Lund.
1990         * lib/acl.c: Include acl.h first, to check interface.  Don't
1991         bother to include sys/types.h and sys/stat.h again.
1992
1993 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
1994
1995         Import the following change from libc; problem reported by
1996         Sven Verdoolaege.
1997
1998         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
1999
2000         [BZ #1373]
2001         * lib/argp.h: Remove __NTH for __argp_usage inline function.
2002
2003 2006-12-28  Jim Meyering  <jim@meyering.net>
2004
2005         * build-aux/announce-gen: Do not assume that the package
2006         builds any of tar.gz, tar.bz2, and .xdelta files.
2007         Suggestion from Simon Josefsson.
2008
2009 2006-12-28  Simon Josefsson  <simon@josefsson.org>
2010
2011         * modules/announce-gen: New file.
2012
2013 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
2014
2015         * lib/mbchar.h: Just include <wctype.h>; the wctype module
2016         handles its gotchas now.
2017         * lib/mbswidth.c: Likewise.
2018         * lib/wcwidth.h: Likewise.
2019         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
2020         and iswcntrl; the wctype module does this stuff now.
2021         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
2022         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
2023         * modules/mbchar (Depends-on): Add wctype.
2024         * modules/mbswidth (Depends-on): Likewise.
2025         * modules/wcwidth (Depends-on): Likewise.
2026
2027 2006-12-27  Eric Blake  <ebb9@byu.net>
2028
2029         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
2030         module uses more than what <wctype.h> is required to provide.
2031
2032 2006-12-26  Eric Blake  <ebb9@byu.net>
2033
2034         * gnulib-tool (sed_extract_prog): Avoid space-tab.
2035
2036 2006-12-26  Eric Blake  <ebb9@byu.net>
2037
2038         * modules/absolute-header: New module.
2039         * modules/fcntl (Depends-on): Depend on it.
2040         * modules/inttypes (Depends-on): Likewise.
2041         * modules/stdint (Depends-on): Likewise.
2042         * modules/sys_stat (Depends-on): Likewise.
2043         * modules/wctype (Depends-on): Likewise.
2044         * MODULES.html.sh (Support for building libraries and
2045         executables): Document it.
2046
2047 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
2048
2049         * gnulib-tool (SED): Remove, undoing previous change.
2050         The problem was that it broke coreutils on Solaris, because
2051         "sed --posix" leaked into a makefile.
2052         (sed): New alias, if 'alias' and GNU sed.
2053
2054 2006-12-24  Jim Meyering  <jim@meyering.net>
2055
2056         Work around an fchownat bug in glibc-2.4:
2057         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
2058         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
2059         in spite of the -P option.
2060         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
2061         New macros.
2062         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
2063         * modules/openat (Files): Add lib/fchownat.c.
2064         * lib/openat.c (fchownat): Don't define here.  Move to...
2065         * lib/fchownat.c: ...this new file.
2066
2067 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
2068
2069         Fix bug reported by Bruno Haible in
2070         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
2071         where quotearg.c didn't compile on Mac OS X 10.2 because it
2072         lacks <wchar.h> and wint_t.
2073         * lib/wctype_.h (__wctype_wint_t): New type.
2074         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
2075         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
2076         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
2077         Arg is now of type __wctype_wint_t, not wint_t.
2078         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
2079         substitute HAVE_WINT_T.
2080         * modules/wctype (Files): Add m4/wint_t.m4.
2081         (wctype.h): Substitute HAVE_WINT_T.
2082
2083 2006-12-23  Bruno Haible  <bruno@clisp.org>
2084
2085         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
2086
2087 2006-12-23  Bruno Haible  <bruno@clisp.org>
2088
2089         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
2090         S_ISLNK.
2091         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
2092         mingw.
2093
2094 2006-12-22  Bruno Haible  <bruno@clisp.org>
2095
2096         * lib/copy-file.c: Include acl.h.
2097         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
2098         Close the file descriptors only after being done with copy_acl.
2099         * modules/copy-file (Depends-on): Add acl.
2100
2101 2006-12-22  Bruno Haible  <bruno@clisp.org>
2102
2103         * gnulib-tool (SED): New variable.
2104         Use $SED instead of sed everywhere.
2105
2106 2006-12-22  Bruno Haible  <bruno@clisp.org>
2107
2108         * modules/no-c++: New file.
2109         * m4/no-c++.m4: New file.
2110         * MODULES.html.sh (Support for building libraries and executables):
2111         Add no-c++.
2112
2113 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
2114
2115         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
2116         Include <limits.h>, and use its INT_MAX to rewrite the
2117         j loop so that it does not overflow 'int'.  Problem reported by
2118         Ralf Wildenhues in
2119         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
2120         Play it safe by shifting left by 1 rather than multiplying by 2,
2121         as GCC is less likely to optimize this away when the value
2122         is signed (when it assumes overflow leads to undefined behavior).
2123         Also, don't assume time_t uses two's complement.
2124
2125 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
2126
2127         * MODULES.html.sh: New module wctype.
2128         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
2129         * lib/fnmatch.c: Don't bother to include <wchar.h> before
2130         <wctype.h>, since the new wctype module should fix this.
2131         * lib/quotearg.c: Include <wctype.h> unconditionally, since
2132         the wctype module should arrange for it.
2133         * lib/regex_internal.h: Likewise.
2134         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
2135         since the wctype module should handle this now.
2136         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
2137         * modules/fnmatch (Depends-on): Add wctype.
2138         * modules/quotearg (Depends-on): Likewise.
2139         * modules/regex (Depends-on): Likewise.
2140
2141 2006-12-19  Bruno Haible  <bruno@clisp.org>
2142
2143         * lib/strdup.h [C++]: Wrap definitions in extern "C".
2144         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
2145
2146 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2147
2148         * modules/savewd (Depends-on): Fix dependency on fcntl.
2149
2150 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
2151
2152         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
2153         conforms to C99, rather than relying on the user's environment
2154         setting of STDINT_H.
2155
2156 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
2157         and Eric Blake  <ebb9@byu.net>
2158
2159         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
2160         This is more consistent with the other defines here.
2161         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
2162         Port to z/OS.  Problem reported by Paul Gilmartin.
2163         Change local vars to use gl_ prefix rather than ac_.
2164         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
2165         with other defines.
2166         * modules/double-slash-root: New module.
2167         * modules/dirname (Files): Remove m4/double-slash-root.m4.
2168         (Depends-on): Add double-slash-root.
2169         * MODULES.html.sh (File system functions): Mention new module.
2170
2171 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
2172
2173         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
2174         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
2175         This is for the benefit of gzip, which doesn't do i18n.
2176
2177 2006-12-12  Jim Meyering  <jim@meyering.net>
2178
2179         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
2180         Reported by Andreas Schwab <schwab@suse.de>.
2181
2182 2006-12-12  Bruno Haible  <bruno@clisp.org>
2183
2184         Merge these changes.
2185         2006-09-05  Bruno Haible  <bruno@clisp.org>
2186         * lib/iconvme.c (iconv_string): No need to save and restore errno when
2187         iconv_alloc succeeded.
2188         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
2189         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
2190         test for " && dest " at the end - dest is always != NULL there. Call
2191         iconv with 4xNULL arguments initially, to reset the state. Call iconv
2192         with 2xNULL arguments, also to flush the state storage. Handle the
2193         IRIX iconv behaviour. Realloc the final result, to throw away unused
2194         memory.
2195
2196 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
2197
2198         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
2199         and fchmodat unconditionally, since glibc 2.4 has them.
2200         Problem reported by Arkadiusz Miskiewicz.
2201
2202 2006-12-10  Bruno Haible  <bruno@clisp.org>
2203
2204         * gnulib-tool (func_import): Show the include files only for those
2205         modules that are copied and specified.
2206         Reported by Karl Berry.
2207
2208 2006-12-08  Jim Meyering  <jim@meyering.net>
2209
2210         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
2211         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
2212
2213         * build-aux/announce-gen: Add two new options, both optional:
2214         --bootstrap-tools=TOOL_LIST
2215               a comma-separated list of tools, e.g.,
2216               autoconf,automake,bison,gnulib
2217         --gnulib-snapshot-date=DATE
2218               if gnulib is in the bootstrap tool list,
2219               then report this as the snapshot date.
2220               If not specified, use the current date/time.
2221               If you specify a date here, be sure it's UTC.
2222
2223 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2224
2225         * tests/test-argp-2.sh: Fix test to match actual output.
2226         (func_compare): Fix sed script to be portable.
2227
2228 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
2229
2230         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
2231         workaround for this case.  It is not autoconfigured now; offhand
2232         it's hard to see how to autoconfigure it.
2233
2234 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
2235
2236         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
2237         a directory that is about to be chowned.  Such a directory's
2238         initial file permissions should permit the owner only and this
2239         should not be changed until after the chown, since the group and
2240         other bits would be incorrect if they granted permission before
2241         the chown.
2242
2243         Fix porting problem for iswctype reported by Georg Schwarz in:
2244         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
2245         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
2246         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
2247         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
2248         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
2249
2250 2006-12-03  Jim Meyering  <jim@meyering.net>
2251
2252         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
2253         p->fts_statp may not yet be defined.
2254         (fts_read): Instead, set it in the caller, once p->fts_statp is
2255         sure to be defined, and corresponds to a top-level directory.
2256         This bug made du -x fail.  Here's the coreutils test case:
2257         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
2258         Reported by Mike Frysinger.
2259
2260 2006-12-01  Jim Meyering  <jim@meyering.net>
2261
2262         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
2263         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
2264         Reported by Simon Josefsson.
2265
2266 2006-11-30  Jim Meyering  <jim@meyering.net>
2267
2268         * m4/warning.m4: Use the all-permissive copyright notice
2269         recommended by RMS (rather than LGPL).
2270         * m4/vararrays.m4: Likewise.
2271         * m4/flexmember.m4: Likewise.
2272
2273 2006-11-29  Bruno Haible  <bruno@clisp.org>
2274
2275         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
2276         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
2277         using +=.
2278         Reported by Simon Josefsson <simon@josefsson.org>.
2279
2280 2006-11-28  James Youngman <jay@gnu.org>
2281
2282         * README: Advise users that they might find the bug-gnulib@gnu.org
2283         and autotools-announce@gnu.org mailing lists useful.
2284
2285 2006-11-28  Bruno Haible  <bruno@clisp.org>
2286
2287         * m4/ptrdiff_max.m4: Remove file.
2288
2289 2006-11-21  Bruno Haible  <bruno@clisp.org>
2290
2291         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
2292         _AC_COMPUTE_INT.
2293         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
2294         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
2295         _AC_COMPUTE_INT.
2296         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
2297         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
2298         _AC_COMPUTE_INT.
2299         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
2300
2301 2006-11-28  Jim Meyering  <jim@meyering.net>
2302
2303         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
2304         warning from "gcc -Wshadow" about shadowing the builtin.
2305
2306 2006-11-27  Bruno Haible  <bruno@clisp.org>
2307
2308         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
2309         _AC_COMPUTE_INT.
2310         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
2311
2312 2006-11-27  Bruno Haible  <bruno@clisp.org>
2313             Paul Eggert  <eggert@cs.ucla.edu>
2314
2315         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
2316
2317 2006-11-26  Bruno Haible  <bruno@clisp.org>
2318
2319         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
2320         noinst_LTLIBRARIES.
2321
2322 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
2323             Bruno Haible  <bruno@clisp.org>
2324
2325         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
2326         if compiling with "gcc -ansi".
2327
2328 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
2329
2330         Fix some incompatibilities with gcc -ansi -pedantic.
2331         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
2332         if compiling pedantically with GCC, unless it's C99 or later.
2333         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
2334         it mishandles gcc -ansi -pedantic as well.
2335         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
2336         if gcc -pedantic.
2337         * lib/regexec.c (check_node_accept_bytes): Don't use auto
2338         initializers for struct if -pedantic, unless it's C99 or later.
2339
2340 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
2341
2342         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
2343         Don't close an fd more than once. Identical atimes indicate
2344         success, not failure.
2345
2346 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
2347
2348         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
2349
2350 2006-11-23  Jim Meyering  <jim@meyering.net>
2351
2352         * build-aux/announce-gen: New file.  From coreutils.
2353
2354 2006-11-22  Jim Meyering  <jim@meyering.net>
2355
2356         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
2357         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
2358         (fts_read): Use a temporary to narrow the overused st_size member
2359         before using it in a switch statement.  Reported by Matthew Woehlke.
2360
2361         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
2362         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
2363
2364 2006-11-20  Bruno Haible  <bruno@clisp.org>
2365
2366         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
2367         changequote instead of pairs of brackets.
2368         Reported by Andreas Schwab <schwab@suse.de>.
2369
2370 2006-11-21  Jim Meyering  <jim@meyering.net>
2371
2372         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
2373         so as to remain compatible with older compilers.
2374         Patch from Michael Deutschmann.
2375
2376 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
2377
2378         * MODULES.html.sh (File system functions): Add openat.
2379
2380         * lib/openat.h (rpl_fstatat): New macro, if
2381         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
2382         (fstatat): Define to rpl_fstatat under the same conditions,
2383         unless COMPILING_FSTATAT.
2384         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
2385         seems to have the bug.
2386         * lib/fstatat.c: New file.
2387         * modules/openat (Files): Add it.
2388
2389 2006-11-20  Bruno Haible  <bruno@clisp.org>
2390
2391         * Makefile: New file.
2392
2393 2006-11-20  Jim Meyering  <jim@meyering.net>
2394
2395         The beginnings of syntax-related checks for gnulib.
2396         * lib/Makefile: New file.
2397         * lib/t-idcache: New script.  Ensure that the two halves of
2398         idcache.c stay in sync.
2399
2400         * lib/idcache.c: Adjust comments in user- and group- portions to
2401         be more accurate, and to be consistent with one another.
2402
2403 2006-11-20  Jim Meyering  <jim@meyering.net>
2404
2405         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
2406         continue using the flexible array member (thus, this module performs
2407         half as many malloc calls), with the addition that...
2408         (getgroup, getuser): Consistently record a non-match via an empty
2409         "name" string, and map an empty string match to a NULL return value.
2410         * modules/idcache (Depends-on): Re-add flexmember.
2411
2412         * lib/idcache.c (getuser): Remove all uses of the register keyword.
2413         (getuidbyname, getgroup, getgidbyname): Likewise.
2414
2415         Use cleaner syntax: NULL rather than 0.
2416         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
2417
2418 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
2419
2420         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
2421         It mishandled the case where the group was missing.
2422         Problem reported by Greg Schafer.
2423         * modules/idcache: Likewise.
2424
2425 2006-11-18  Jim Meyering  <jim@meyering.net>
2426
2427         * check-module (%exempt_header): Add exception for some
2428         conditionally-included headers.
2429
2430         * modules/i-ring (Depends-on): Add verify.
2431         (License): Change to LGPL.
2432
2433 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
2434
2435         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
2436         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
2437         and inttostr.h.  Use snprintf rather than uinttostr, so that
2438         LGPLed code doesn't depend on GPLed.
2439
2440 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
2441
2442         * modules/inline (License): Change from GPL to LGPL.
2443
2444 2006-11-17  Jim Meyering  <jim@meyering.net>
2445
2446         * modules/d-type (License): Switch to LGPL.
2447
2448 2006-11-15  Bruno Haible  <bruno@clisp.org>
2449
2450         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
2451
2452 2006-11-15  Eric Blake  <ebb9@byu.net>
2453
2454         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
2455         the module dependency.
2456
2457 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
2458             Bruno Haible  <bruno@clisp.org>
2459
2460         * gnulib-tool (func_create_testdir): Add license consistency check.
2461
2462 2006-11-15  Eric Blake  <ebb9@byu.net>
2463
2464         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
2465         random "(cached)" in configure output.
2466
2467 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2468
2469         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
2470         test for conforming inttypes.h is both announced and cached.
2471
2472         * MODULES.html.sh (seen_modules, seen_files): New variables.
2473         (func_module): Rewrite to use a few less gnulib-tool and sed
2474         invocations.  Avoid a couple of quadratic algorithms for ...
2475         (missed_modules, missed_files): ... these, with ...
2476         (func_append, func_tmpdir): ... these new functions, from
2477         gnulib-tool.  Analogously, install traps for cleanup.
2478
2479         * tests/test-gc.c (main): Remove unused variables.
2480         * tests/test-read-file.c: Include stdlib.h, for 'free'.
2481
2482 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
2483
2484         * modules/inttostr (License): Change to LGPL.
2485
2486 2006-11-14  Eric Blake  <ebb9@byu.net>
2487
2488         * modules/tempname (License): Change to LGPL.
2489
2490 2006-11-14  Eric Blake  <ebb9@byu.net>
2491
2492         * doc/functions.texi (Function Portability): *printf functions on
2493         Cygwin now understand all POSIX size specifiers.
2494
2495 2006-11-14  Bruno Haible  <bruno@clisp.org>
2496
2497         * modules/c-ctype (License): Change to LGPL.
2498
2499 2006-11-12  Bruno Haible  <bruno@clisp.org>
2500
2501         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
2502         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
2503         for GNOME libraries, for which the include files are installed in
2504         subdirectories of $prefix/include.
2505
2506 2006-11-12  Bruno Haible  <bruno@clisp.org>
2507
2508         * m4/lib-link.m4: Require at least autoconf-2.54.
2509         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
2510         name to underscores for the --with option.
2511
2512 2006-11-13  Bruno Haible  <bruno@clisp.org>
2513
2514         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
2515         the tests directory.
2516         Reported by Ralf Wildenhues.
2517
2518 2006-11-13  Bruno Haible  <bruno@clisp.org>
2519
2520         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
2521         (func_emit_initmacro_end): Undo the override here.
2522         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
2523         Works around the famous automake error in coreutils.
2524
2525 2006-11-13  Eric Blake  <ebb9@byu.net>
2526
2527         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
2528         element, not its node.
2529
2530 2006-11-12  Bruno Haible  <bruno@clisp.org>
2531
2532         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
2533         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
2534
2535 2006-11-12  Bruno Haible  <bruno@clisp.org>
2536
2537         * gnulib-tool: New option --local-symlink.
2538         (func_usage): Document it.
2539         (lsymbolic): New variable.
2540         (func_import, func_create_testdir): If --symlink was not specified,
2541         test whether --local-symlink was specified and the file comes from
2542         the local_gnulib_dir.
2543
2544 2006-11-12  Bruno Haible  <bruno@clisp.org>
2545
2546         * gnulib-tool (func_ln): New function.
2547         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
2548
2549 2006-11-12  Bruno Haible  <bruno@clisp.org>
2550
2551         Finish support for source files in subdirectories.
2552         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
2553         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
2554         AUTOMAKE_OPTIONS.
2555         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
2556
2557 2006-11-12  Bruno Haible  <bruno@clisp.org>
2558
2559         * gnulib-tool (func_get_automake_snippet): Synthesize also an
2560         EXTRA_lib_SOURCES augmentation.
2561         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
2562
2563 2006-11-12  Jim Meyering  <jim@meyering.net>
2564
2565         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
2566         file descriptors.  This also averts a failure on systems with
2567         native openat support when a traversed directory lacks "x" access.
2568         * lib/fts_.h: Include "i-ring.h"
2569         (struct FTS) [fts_fd_ring]: New member.
2570         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
2571         (FCHDIR): Add parentheses.
2572         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
2573         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
2574         When descending, rather than simply closing the previous
2575         fts_cwd_fd value, push that file descriptor onto the ring.
2576         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
2577         (fts_open): Initialize the new fd_ring member.
2578         (fts_close): Clear the ring.
2579         (fts_safe_changedir): When possible, use our new fd_ring to skip
2580         the diropen and fstat and dev/ino comparison that would normally
2581         accompany a virtual `chdir ("..")'.
2582
2583         * modules/fts (Depends-on): Add i-ring.
2584         * modules/i-ring: New module.
2585         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
2586         * m4/i-ring.m4: New file.
2587
2588 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2589
2590         * gnulib-tool (func_create_testdir): Fix replacement of
2591         `build-aux' in configure.ac.  Run autotools in gltests
2592         subdirectory.
2593         (func_create_testdir, func_create_megatestdir, test): There is
2594         no need for '--force' in most autotool invocations in a new
2595         tree.  Actually fail the whole test if any of the tools, or the
2596         configure or make stages fail.
2597
2598         Sync from Automake.
2599         * build-aux/gnupload: Revert last change.  Add pointer to upload
2600         instructions of the GNU Maintenance Instructions.
2601         Suggestion by Karl Berry.
2602
2603 2006-11-10  Jim Meyering  <jim@meyering.net>
2604
2605         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
2606
2607 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
2608
2609         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
2610         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
2611         (bind_textdomain_codeset) [! ENABLE_NLS]:
2612         Evaluate all the arguments.  That way, callers get compatible behavior
2613         if the arguments have side effects.  Also, it avoids some GCC
2614         diagnostics in some cases; Joel E. Denny reported problems when Bison
2615         was configured with --enable-gcc-warnigs.
2616
2617 2006-11-10  Jim Meyering  <jim@meyering.net>
2618
2619         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
2620         relevant options in CFLAGS (like -O, -fno-inline) are taken into
2621         account.
2622
2623 2006-11-10  Jim Meyering  <jim@meyering.net>
2624
2625         * modules/inline: New file/module.
2626         * modules/xalloc (Files): Remove m4/inline.m4.
2627         (Depends-on): Add inline, instead.
2628         * modules/oset: Likewise.
2629         * modules/list: Likewise.
2630
2631 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
2632
2633         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
2634         Problem reported by Matthew Woehlke.
2635
2636 2006-11-09  Bruno Haible  <bruno@clisp.org>
2637
2638         * lib/tempname.c (gen_tempname): Remove variant that invokes
2639         __gen_tempname.
2640         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
2641         __gen_tempname.
2642
2643 2006-11-08  Bruno Haible  <bruno@clisp.org>
2644
2645         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
2646         to 'yes' instead of 'cross-compiling'.
2647
2648 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
2649
2650         * lib/quotearg.h (quotearg_free): New decl.
2651         * lib/quotearg.c (quotearg_free): New function.
2652         (slot0, nslots, slotvec0, slotvec):
2653         Now file-scope so that quotearg_free can get at them.
2654
2655 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2656
2657         Sync from Automake.
2658         * build-aux/gnupload: Add missing 'gnu' to example URL.
2659         Report by Karl Berry.
2660
2661 2006-11-08  Bruno Haible  <bruno@clisp.org>
2662
2663         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
2664         Suggested by Paul Eggert.
2665
2666 2006-11-08  Jim Meyering  <jim@meyering.net>
2667
2668         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
2669         It's already included if !_LIBC.
2670         (fts_safe_changedir): Add a comment.
2671
2672 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
2673
2674         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
2675         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
2676         Matthew Woehlke.
2677
2678         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
2679         definitions up, to avoid colliding with change below.
2680         (static_inline) [HAVE_INLINE]: New macro.
2681         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
2682         Provide extern decls when !HAVE_INLINE.  Do not define unless
2683         static_inline is defined, either by us or by xmalloc.c.  Use
2684         static_inline rather than static inline.
2685         (XCALLOC): Optimize sizeof(T) = 1 case.
2686         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
2687
2688 2006-11-07  Bruno Haible  <bruno@clisp.org>
2689
2690         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
2691         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
2692         AC_C_INLINE.
2693         * modules/xalloc (Files): Add m4/inline.m4.
2694
2695 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2696
2697         * README: Fix typo.
2698         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
2699         (Miscellanous Notes): ...from this.
2700
2701 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
2702
2703         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
2704         Mention that offsetof should be used instead of sizeof.
2705         From Bruno Haible.
2706
2707 2006-11-07  Bruno Haible  <bruno@clisp.org>
2708
2709         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
2710
2711 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
2712
2713         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
2714         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
2715         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
2716         (gl_tree_add_before, gl_tree_add_after):
2717         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
2718         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
2719         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
2720         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
2721         (gl_linked_add_after, gl_linked_add_at): Likewise.
2722         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
2723         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
2724         (gl_tree_add_before, gl_tree_add_after): Likewise.
2725         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
2726         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
2727         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
2728
2729 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2730
2731         * lib/gl_oset.h: Use C comment style, not C++ comment style.
2732
2733 2006-11-06  Bruno Haible  <bruno@clisp.org>
2734
2735         * m4/inline.m4: New file.
2736         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
2737         * modules/list (Files): Add m4/inline.m4.
2738         * modules/oset (Files): Likewise.
2739
2740 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
2741
2742         * lib/idcache.c: Include <stddef.h>, for offsetof.
2743         (struct userid.name): Change from char * to a flexible array member.
2744         All uses changed.
2745         * modules/idcache (Depends-on): Add flexmember.
2746
2747         * MODULES.html.sh (Core language properties): New module flexmember.
2748         * modules/flexmember, m4/flexmember.m4: New files.
2749
2750         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
2751         inline functions that are identical with the old xnmalloc_inline,
2752         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
2753         that we can avoid some unnecessary integer multiplications and
2754         divisions in the common case where the element size is known at
2755         compile time.
2756         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
2757         needed.
2758         (xnboundedmalloc): Remove.
2759         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
2760         arguments, for consistency with rest of this header.
2761         (xcharalloc): Rewrite using XNMALLOC.
2762         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
2763         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
2764         versions have been moved to lib/xalloc.h and renamed to be the
2765         non-*_inline versions.
2766         (xmalloc, xrealloc): Implement without reference to the xnmalloc
2767         and xnrealloc functions, since those functions are now inline and
2768         now call us.
2769         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
2770         renaming described above.
2771         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
2772         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
2773         captures the dependency in AC_C_INLINE.
2774
2775         New module canonicalize-lgpl, proposed by Charles Wilson in
2776         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
2777         with a few small changes afterwards.
2778         * MODULES.html.sh (File system functions): New module
2779         canonicalize-lgpl.
2780         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
2781         and canonicalize_file_name.
2782         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
2783         * modules/canonicalize-lgpl: New files.
2784
2785 2006-11-05  Bruno Haible  <bruno@clisp.org>
2786
2787         * gnulib-tool (func_import, func_create_testdir): Create directories
2788         also for files in subdirectories of lib/.
2789
2790 2006-11-05  Bruno Haible  <bruno@clisp.org>
2791
2792         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
2793         ANSI C compliant.
2794
2795 2006-11-03  Bruno Haible  <bruno@clisp.org>
2796
2797         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
2798         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
2799         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
2800         (xnboundedmalloc): New inline function.
2801         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
2802         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
2803         xmalloc.
2804         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
2805         xmalloc.
2806         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
2807         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
2808         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
2809         xmalloc.
2810         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
2811         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
2812         xmalloc.
2813         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
2814         gl_tree_add_after): Use XMALLOC instead of xmalloc.
2815         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
2816         xmalloc.
2817         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
2818         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
2819         gl_tree_add_after): Use XMALLOC instead of xmalloc.
2820         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
2821         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
2822         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
2823         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
2824
2825 2006-11-03  Bruno Haible  <bruno@clisp.org>
2826
2827         * lib/c-ctype.h [C++]: Define functions without name mangling.
2828         * lib/fwriteerror.h [C++]: Likewise.
2829         * lib/gcd.h [C++]: Likewise.
2830         * lib/linebreak.h [C++]: Likewise.
2831
2832 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
2833
2834         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
2835         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
2836         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
2837         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
2838         Check for functions and headers just once.
2839         Check for declaration of canonicalize_file_name.
2840         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
2841
2842 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
2843
2844         * gnulib-tool (func_import): Fix typo in actioncmd.
2845
2846 2006-11-02  Bruno Haible  <bruno@clisp.org>
2847
2848         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
2849         newline sequence in the Makefile.am snippet as a space, like "make"
2850         does.
2851         Reported by Roger Persson <perrog@gmail.com>.
2852
2853 2006-11-01  Bruno Haible  <bruno@clisp.org>
2854
2855         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
2856         already declared in <string.h>.
2857         * lib/strcase.h (strncasecmp): Don't declare it if yes.
2858
2859 2006-11-01  Bruno Haible  <bruno@clisp.org>
2860
2861         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
2862         * lib/strcase.h: Include <string.h>.
2863         (strcasecmp): Define to rpl_strcasecmp here.
2864
2865 2006-11-01  Bruno Haible  <bruno@clisp.org>
2866
2867         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
2868
2869 2006-11-01  Eric Blake  <ebb9@byu.net>
2870
2871         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
2872
2873         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
2874
2875 2006-10-29  Bruno Haible  <bruno@clisp.org>
2876
2877         Make it compile in C++ mode.
2878         * lib/full-write.c (full_rw): Add a cast.
2879
2880 2006-11-01  Bruno Haible  <bruno@clisp.org>
2881
2882         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
2883         be POSIX compliant.
2884         Reported by Roger Persson <perrog@gmail.com>.
2885
2886 2006-11-01  Eric Blake  <ebb9@byu.net>
2887
2888         * lib/getopt_.h: Fix comments.
2889
2890 2006-10-31  Eric Blake  <ebb9@byu.net>
2891
2892         * modules/tmpdir (Depends-on): Add sys_stat.
2893         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
2894         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
2895         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
2896         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
2897         tempname.
2898
2899 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
2900
2901         Avoid some C++ diagnostics reported by Bruno Haible.
2902         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
2903         xmalloc.
2904         (quotearg_alloc): Use xcharalloc rather than xmalloc.
2905         (struct slotvec): Move to top level.
2906         (quotearg_n_options): Rewrite to avoid xmalloc.
2907         * lib/xalloc.h (xcharalloc): New function.
2908         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
2909         [defined __cplusplus]: Add function template that provides result
2910         type propagation.  This part of the change is from Bruno Haible.
2911
2912 2006-10-29  Bruno Haible  <bruno@clisp.org>
2913
2914         Make it compile in C++ mode.
2915         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
2916         * lib/strnlen1.c (strnlen1): Cast memchr result.
2917         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
2918         * lib/clean-temp.c (string_equals, string_hash): Add casts.
2919         (create_temp_dir): Rename local variable 'template'.
2920         (compile_csharp_using_sscli): Add cast.
2921         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
2922         * lib/findprog.c (find_in_path): Likewise.
2923         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
2924         * lib/wait-process.c (register_slave_subprocess): Likewise.
2925
2926 2006-10-22  Bruno Haible  <bruno@clisp.org>
2927
2928         * modules/tsearch: New file.
2929         * lib/tsearch.h: New file.
2930         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
2931         * m4/tsearch.m4: New file.
2932         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
2933
2934 2006-10-29  Eric Blake  <ebb9@byu.net>
2935
2936         * lib/arcfour.c: Assume config.h.
2937         * lib/arctwo.c: Likewise.
2938         * lib/base64.c: Likewise.
2939         * lib/check-version.c: Likewise.
2940         * lib/crc.c: Likewise.
2941         * lib/des.c: Likewise.
2942         * lib/gc-gnulib.c: Likewise.
2943         * lib/gc-libgcrypt.c: Likewise.
2944         * lib/gc-pbkdf2-sha1.c: Likewise.
2945         * lib/getaddrinfo.c: Likewise.
2946         * lib/getdelim.c: Likewise.
2947         * lib/getline.c: Likewise.
2948         * lib/hmac-md5.c: Likewise.
2949         * lib/hmac-sha1.c: Likewise.
2950         * lib/iconvme.c: Likewise.
2951         * lib/md2.c: Likewise.
2952         * lib/md4.c: Likewise.
2953         * lib/memxor.c: Likewise.
2954         * lib/read-file.c: Likewise.
2955         * lib/readline.c: Likewise.
2956         * lib/rijndael-alg-fst.c: Likewise.
2957         * lib/rijndael-api-fst.c: Likewise.
2958         * lib/xgetdomainname.c: Likewise.
2959
2960 2006-10-28  Eric Blake  <ebb9@byu.net>
2961
2962         * lib/xstrndup.c: Assume config.h.
2963
2964 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
2965
2966         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
2967         stat-macros.h is now for our own macros, whereas stat_h is for
2968         macros in the <sys/stat.h> name space.
2969         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
2970         (STAT_MACROS_H): Remove.
2971         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
2972         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
2973         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
2974         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
2975         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
2976         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
2977         Move these macros to ...
2978         * lib/stat_.h: here.  Don't include stat-macros.h.
2979         * lib/canonicalize.c: Don't include stat-macros.h.
2980         * lib/chown.c: Likewise.
2981         * lib/euidaccess.c: Likewise.
2982         * lib/file-type.c: Likewise.
2983         * lib/filemode.c: Likewise.
2984         * lib/glob.c: Likewise.
2985         * lib/isapipe.c: Likewise.
2986         * lib/lchown.c: Likewise.
2987         * lib/lstat.c: Likewise.
2988         * lib/mkdir-p.c: Likewise.
2989         * lib/rmdir.c: Likewise.
2990         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
2991         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
2992         unless mkdir isn't declared, to speed up 'configure'.
2993         Always create sys/stat.h, since it's unlikely any real sys/stat.h
2994         would define all the S_* symbols.
2995         * modules/canonicalize (Depends-on):
2996         Depend on sys_stat, not stat-macros.
2997         * modules/chown: Likewise.
2998         * modules/euidaccess: Likewise.
2999         * modules/filemode: Likewise.
3000         * modules/file-type: Likewise.
3001         * modules/glob: Likewise.
3002         * modules/isapipe: Likewise.
3003         * modules/lchown: Likewise.
3004         * modules/lstat: Likewise.
3005         * modules/mkancesdirs: Likewise.
3006         * modules/rmdir: Likewise.
3007         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
3008         * modules/modechange: Likewise.
3009         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
3010         (configure.ac): Remove gl_STAT_MACROS.
3011         * modules/sys_stat (Depends-on): Remove stat-macros.
3012
3013 2006-10-27  Bruno Haible  <bruno@clisp.org>
3014
3015         * m4/signed.m4: Remove file.
3016         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
3017         invocation.
3018         * modules/vasnprintf (Files): Remove m4/signed.m4.
3019
3020 2006-10-27  Bruno Haible  <bruno@clisp.org>
3021
3022         Update to GNU gettext 0.16.
3023         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
3024         m4/inttypes-h.m4, m4/signed.m4.
3025         * m4/gettext.m4: Update to GNU gettext 0.16.
3026         * m4/intl.m4: New file, from GNU gettext.
3027         * m4/intldir.m4: New file, from GNU gettext.
3028         * config/srclist.txt: Update
3029
3030 2006-10-27  Eric Blake  <ebb9@byu.net>
3031
3032         * MODULES.html.sh: Document tempname.
3033         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
3034         dependencies.
3035         (Files): Move lib/tempname.c...
3036         * modules/tempname: ...to this new module.
3037         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
3038         (gl_PREREQ_TEMPNAME): Move...
3039         * m4/tempname.m4: ...to this new file.
3040         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
3041         * modules/sys_stat (Depends-on): Add stat-macros.
3042         * lib/stat_.h (includes): Pick up stat macros.
3043         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
3044         if stat macros are broken.
3045         * lib/tempname.c (includes): No need to include "stat-macros.h".
3046         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
3047         (direxists, __path_search) [!_LIBC]: Don't compile these in
3048         gnulib; the tmpdir module covers that.
3049         * lib/tempname.h: New file.
3050
3051 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
3052
3053         * COPYING: Explain how gnulib-tool converts licence headers.
3054         Almost all wording by Eric Blake.
3055
3056 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
3057
3058         * lib/mbchar.h (is_basic_table): Make read-only.
3059         * lib/mbchar.c (is_basic_table): Likewise.
3060         Reported by John Darrington.
3061
3062 2006-10-25  Bruno Haible  <bruno@clisp.org>
3063
3064         * lib/progname.h (set_program_name): Undefine before defining.
3065
3066 2006-10-25  Bruno Haible  <bruno@clisp.org>
3067
3068         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
3069         false for non-gcc C++ compilers.
3070         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
3071
3072 2006-10-24  Bruno Haible  <bruno@clisp.org>
3073
3074         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
3075         iconv implementations like Irix iconv.
3076
3077 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
3078
3079         * modules/vararrays: New file.
3080         * m4/vararrays.m4: New file, taken from diffutils.
3081         * MODULES.html.sh: New module vararrays.
3082
3083 2006-10-24  Karl Berry  <karl@gnu.org>
3084
3085         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
3086         Don't call GNU Unix.
3087
3088 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3089
3090         * users.txt: Add Libtool.
3091
3092         Sync from Libtool:
3093
3094         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
3095
3096         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
3097         to gnulib's policy of including config.h unconditionally.
3098
3099 2006-10-24  Bruno Haible  <bruno@clisp.org>
3100
3101         * modules/wcwidth (Files): Add m4/wint_t.m4.
3102         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
3103         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
3104
3105 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
3106
3107         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
3108         to pacify GCC with some -W flags enabled.  Problem reported by
3109         Bruno Haible.
3110
3111 2006-10-24  Jim Meyering  <jim@meyering.net>
3112
3113         * MODULES.html.sh: Remove uinttostr.  It's not a module.
3114         Reported by Karl Berry.
3115
3116 2006-10-23  Bruno Haible  <bruno@clisp.org>
3117
3118         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
3119
3120 2006-10-24  Bruno Haible  <bruno@clisp.org>
3121
3122         * lib/gl_list.h: Use C comment style, not C++ comment style.
3123
3124 2006-10-23  Eric Blake  <ebb9@byu.net>
3125
3126         * lib/getaddrinfo.c (includes): Add missing include.
3127
3128 2006-10-23  Bruno Haible  <bruno@clisp.org>
3129             Paul Eggert  <eggert@cs.ucla.edu>
3130
3131         Ability to rename obstack_free.
3132         * lib/obstack.h (__obstack_free): New macro. Declare instead of
3133         obstack_free.
3134         (obstack_free): Invoke the __obstack_free macro.
3135         * lib/obstack.c (obstack_free): Use __obstack_free macro.
3136
3137 2006-10-23  Bruno Haible  <bruno@clisp.org>
3138             Paul Eggert  <eggert@cs.ucla.edu>
3139
3140         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
3141         __argc, __argv from the declaration. (They are defined as macros on
3142         mingw.)
3143
3144 2006-10-22  Bruno Haible  <bruno@clisp.org>
3145
3146         * doc/gnulib-intro.texi: New file.
3147         * doc/gnulib.texi: Include it.
3148
3149 2006-10-21  Bruno Haible  <bruno@clisp.org>
3150
3151         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
3152         "Introduction", "Miscellanous Notes", "Particular Modules".
3153
3154 2006-10-21  Bruno Haible  <bruno@clisp.org>
3155
3156         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
3157         Change mostlyclean-local rule to avoid sh syntax error from bash
3158         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
3159
3160 2006-10-23  Jim Meyering  <jim@meyering.net>
3161
3162         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
3163         in place of snprintf.
3164
3165         * modules/inttostr (Files): Add lib/uinttostr.c.
3166         * lib/uinttostr.c (inttostr): New file/function.
3167         * lib/inttostr.h (uinttostr): Declare.
3168         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
3169         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
3170         Add uinttostr.
3171         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
3172
3173 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
3174
3175         * lib/canonicalize.c (ELOOP): Define if not already defined.
3176         Problem reported by Bruno Haible in
3177         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
3178
3179 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
3180
3181         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
3182         Problem reported by Perry Smith and Ville Laurikari.
3183
3184         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
3185         uses.
3186
3187 2006-10-19  Bruno Haible  <bruno@clisp.org>
3188
3189         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
3190         for mingw.
3191
3192 2006-10-19  Bruno Haible  <bruno@clisp.org>
3193
3194         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
3195         Needed for mingw.
3196
3197 2006-10-19  Bruno Haible  <bruno@clisp.org>
3198
3199         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
3200
3201 2006-10-19  Bruno Haible  <bruno@clisp.org>
3202
3203         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
3204         it.
3205
3206 2006-10-19  Bruno Haible  <bruno@clisp.org>
3207
3208         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
3209         invocation.
3210
3211 2006-10-19  Bruno Haible  <bruno@clisp.org>
3212
3213         * gnulib-tool (func_create_testdir): Don't include ftruncate and
3214         mountlist by default.
3215
3216 2006-10-16  Bruno Haible  <bruno@clisp.org>
3217
3218         * lib/c-strstr.c: Include c-strstr.h.
3219
3220 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
3221
3222         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
3223         in a slash.
3224
3225 2006-10-18  Bruno Haible  <bruno@clisp.org>
3226
3227         * lib/lock.h [C++]: Wrap definitions in extern "C".
3228
3229 2006-10-18  Bruno Haible  <bruno@clisp.org>
3230
3231         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
3232         gl_LIBOBJS list.
3233
3234 2006-10-18  Bruno Haible  <bruno@clisp.org>
3235
3236         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
3237
3238 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
3239
3240         * lib/xstrtol.h: Include gettext.h.
3241         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
3242         Problem reported by Eric Blake.
3243         * modules/xstrtol (Depends-on): Add gettext-h.
3244
3245 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
3246
3247         * lib/strftime.c (advance): New macro.
3248         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
3249         incomplete type, so you can't add 0 to it.  Problem and patch
3250         reported by Eelco Dolstra for dietlibc.
3251
3252 2006-10-18  Jim Meyering  <jim@meyering.net>
3253
3254         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
3255         type for a local, and rename it: s/up/user_proc/.
3256
3257 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
3258
3259         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
3260         READ_UTMP_USER_PROCESS.
3261         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
3262
3263 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
3264
3265         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
3266         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
3267
3268 2006-10-17  Eric Blake  <ebb9@byu.net>
3269
3270         * lib/sigprocmask.c (sigprocmask): Fix typo.
3271
3272         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
3273
3274         * modules/clean-temp (Makefile.am): Don't add to make output...
3275         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
3276         config.h.
3277
3278 2006-10-17  Bruno Haible  <bruno@clisp.org>
3279
3280         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
3281         differently if DEFAULT_TEXT_DOMAIN is set.
3282
3283 2006-10-16  Bruno Haible  <bruno@clisp.org>
3284
3285         * lib/clean-temp.c: Include fwriteerror.h.
3286
3287 2006-10-16  Bruno Haible  <bruno@clisp.org>
3288
3289         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
3290
3291 2006-10-16  Bruno Haible  <bruno@clisp.org>
3292
3293         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
3294         * lib/sigprocmask.h: Include <sys/types.h>.
3295         (sigset_t): Use the system's definition if present.
3296
3297 2006-10-17  Eric Blake  <ebb9@byu.net>
3298
3299         * lib/xvasprintf.c (includes): Assume config.h.
3300         * lib/xasprintf.c (includes): Likewise.
3301
3302 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
3303
3304         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
3305         at least as wide as intmax_t.
3306
3307 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
3308
3309         (Imported from Automake.)
3310         * build-aux/gnupload: Update to version 1.1 of directive file.
3311
3312 2006-10-16  Eric Blake  <ebb9@byu.net>
3313
3314         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
3315         match Automake 1.10a.
3316
3317 2006-10-14  Bruno Haible  <bruno@clisp.org>
3318
3319         * modules/sigprocmask: New file.
3320         * lib/sigprocmask.h: New file.
3321         * lib/sigprocmask.c: New file.
3322         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
3323         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
3324         request sigprocmask.o.
3325         (gl_PREREQ_SIGPROCMASK): New macro.
3326         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
3327         (Depends-on): Add sigprocmask.
3328         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
3329         gt_SIGNALBLOCKING. Test for 'raise' only once.
3330         * lib/fatal-signal.c: Include sigprocmask.h.
3331         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
3332         unblock_fatal_signals): Define always.
3333         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
3334         sigprocmask.
3335
3336 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
3337
3338         Sync from Automake.
3339         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
3340         which incorrectly sets the mode of an existing destination
3341         directory.  In some cases the unpatched install-sh could do the
3342         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
3343         system.  We hope this is rare in practice, but it's clearly worth
3344         fixing.  Problem reported by Alex Unleashed in
3345         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
3346         Also, don't bother to check for -m bugs unless we're using -m;
3347         suggested by Stepan Kasal.
3348
3349 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3350
3351         Sync from Automake.
3352         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
3353         `-c' flag, so they appear at the same position as in %FASTDEP%
3354         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
3355         which ignores unknown options only after the first non-option.
3356         Bug report against M4 by Nelson H. F. Beebe.
3357
3358 2006-10-13  Jim Meyering  <jim@meyering.net>
3359
3360         Fix a bug in yesterday's change.
3361         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
3362         p->fts_statp->st_dev would be used uninitialized.
3363         Ensures that we always call fts_stat on the very first entry.
3364         Miklos Szeredi reported that find -xdev stopped working.
3365
3366 2006-10-12  Bruno Haible  <bruno@clisp.org>
3367
3368         * gnulib-tool (func_get_automake_snippet): Append an automatically
3369         computed EXTRA_DIST augmentation.
3370         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
3371         * modules/alloca-opt (Makefile.am): Likewise.
3372         * modules/allocsa (Makefile.am): Likewise.
3373         * modules/arcfour (Makefile.am): Likewise.
3374         * modules/arctwo (Makefile.am): Likewise.
3375         * modules/argmatch (Makefile.am): Likewise.
3376         * modules/argz (Makefile.am): Likewise.
3377         * modules/atexit (Makefile.am): Likewise.
3378         * modules/backupfile (Makefile.am): Likewise.
3379         * modules/byteswap (Makefile.am): Likewise.
3380         * modules/c-strtod (Makefile.am): Likewise.
3381         * modules/c-strtold (Makefile.am): Likewise.
3382         * modules/calloc (Makefile.am): Likewise.
3383         * modules/canon-host (Makefile.am): Likewise.
3384         * modules/canonicalize (Makefile.am): Likewise.
3385         * modules/chdir-long (Makefile.am): Likewise.
3386         * modules/chdir-safer (Makefile.am): Likewise.
3387         * modules/check-version (Makefile.am): Likewise.
3388         * modules/chown (Makefile.am): Likewise.
3389         * modules/cloexec (Makefile.am): Likewise.
3390         * modules/close-stream (Makefile.am): Likewise.
3391         * modules/closeout (Makefile.am): Likewise.
3392         * modules/crc (Makefile.am): Likewise.
3393         * modules/csharpexec (Makefile.am): Likewise.
3394         * modules/cycle-check (Makefile.am): Likewise.
3395         * modules/des (Makefile.am): Likewise.
3396         * modules/dev-ino (Makefile.am): Likewise.
3397         * modules/dirfd (Makefile.am): Likewise.
3398         * modules/dirname (Makefile.am): Likewise.
3399         * modules/dup2 (Makefile.am): Likewise.
3400         * modules/eealloc (Makefile.am): Likewise.
3401         * modules/error (Makefile.am): Likewise.
3402         * modules/euidaccess (Makefile.am): Likewise.
3403         * modules/exclude (Makefile.am): Likewise.
3404         * modules/exitfail (Makefile.am): Likewise.
3405         * modules/fcntl-safer (Makefile.am): Likewise.
3406         * modules/fcntl (Makefile.am): Likewise.
3407         * modules/file-type (Makefile.am): Likewise.
3408         * modules/fileblocks (Makefile.am): Likewise.
3409         * modules/filemode (Makefile.am): Likewise.
3410         * modules/filenamecat (Makefile.am): Likewise.
3411         * modules/fnmatch (Makefile.am): Likewise.
3412         * modules/fopen-safer (Makefile.am): Likewise.
3413         * modules/fpending (Makefile.am): Likewise.
3414         * modules/fprintftime (Makefile.am): Likewise.
3415         * modules/free (Makefile.am): Likewise.
3416         * modules/fsusage (Makefile.am): Likewise.
3417         * modules/ftruncate (Makefile.am): Likewise.
3418         * modules/fts (Makefile.am): Likewise.
3419         * modules/gc-arcfour (Makefile.am): Likewise.
3420         * modules/gc-des (Makefile.am): Likewise.
3421         * modules/gc-hmac-md5 (Makefile.am): Likewise.
3422         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
3423         * modules/gc-md4 (Makefile.am): Likewise.
3424         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
3425         * modules/gc-sha1 (Makefile.am): Likewise.
3426         * modules/gc (Makefile.am): Likewise.
3427         * modules/getaddrinfo (Makefile.am): Likewise.
3428         * modules/getcwd (Makefile.am): Likewise.
3429         * modules/getdelim (Makefile.am): Likewise.
3430         * modules/getdomainname (Makefile.am): Likewise.
3431         * modules/getgroups (Makefile.am): Likewise.
3432         * modules/gethostname (Makefile.am): Likewise.
3433         * modules/gethrxtime (Makefile.am): Likewise.
3434         * modules/getline (Makefile.am): Likewise.
3435         * modules/getloadavg (Makefile.am): Likewise.
3436         * modules/getlogin_r (Makefile.am): Likewise.
3437         * modules/getndelim2 (Makefile.am): Likewise.
3438         * modules/getopt (Makefile.am): Likewise.
3439         * modules/getpagesize (Makefile.am): Likewise.
3440         * modules/getpass-gnu (Makefile.am): Likewise.
3441         * modules/getpass (Makefile.am): Likewise.
3442         * modules/getsubopt (Makefile.am): Likewise.
3443         * modules/gettime (Makefile.am): Likewise.
3444         * modules/gettimeofday (Makefile.am): Likewise.
3445         * modules/getugroups (Makefile.am): Likewise.
3446         * modules/getusershell (Makefile.am): Likewise.
3447         * modules/glob (Makefile.am): Likewise.
3448         * modules/group-member (Makefile.am): Likewise.
3449         * modules/hard-locale (Makefile.am): Likewise.
3450         * modules/hash (Makefile.am): Likewise.
3451         * modules/hmac-md5 (Makefile.am): Likewise.
3452         * modules/hmac-sha1 (Makefile.am): Likewise.
3453         * modules/human (Makefile.am): Likewise.
3454         * modules/idcache (Makefile.am): Likewise.
3455         * modules/imaxabs (Makefile.am): Likewise.
3456         * modules/imaxdiv (Makefile.am): Likewise.
3457         * modules/inet_ntop (Makefile.am): Likewise.
3458         * modules/inet_pton (Makefile.am): Likewise.
3459         * modules/intprops (Makefile.am): Likewise.
3460         * modules/inttostr (Makefile.am): Likewise.
3461         * modules/inttypes (Makefile.am): Likewise.
3462         * modules/isapipe (Makefile.am): Likewise.
3463         * modules/javaversion (Makefile.am): Likewise.
3464         * modules/lchmod (Makefile.am): Likewise.
3465         * modules/lchown (Makefile.am): Likewise.
3466         * modules/localcharset (Makefile.am): Likewise.
3467         * modules/long-options (Makefile.am): Likewise.
3468         * modules/lstat (Makefile.am): Likewise.
3469         * modules/malloc (Makefile.am): Likewise.
3470         * modules/mathl (Makefile.am): Likewise.
3471         * modules/mbchar (Makefile.am): Likewise.
3472         * modules/md2 (Makefile.am): Likewise.
3473         * modules/md4 (Makefile.am): Likewise.
3474         * modules/md5 (Makefile.am): Likewise.
3475         * modules/memcasecmp (Makefile.am): Likewise.
3476         * modules/memchr (Makefile.am): Likewise.
3477         * modules/memcmp (Makefile.am): Likewise.
3478         * modules/memcoll (Makefile.am): Likewise.
3479         * modules/memcpy (Makefile.am): Likewise.
3480         * modules/memmem (Makefile.am): Likewise.
3481         * modules/memmove (Makefile.am): Likewise.
3482         * modules/mempcpy (Makefile.am): Likewise.
3483         * modules/memrchr (Makefile.am): Likewise.
3484         * modules/memset (Makefile.am): Likewise.
3485         * modules/memxor (Makefile.am): Likewise.
3486         * modules/mkancesdirs (Makefile.am): Likewise.
3487         * modules/mkdir-p (Makefile.am): Likewise.
3488         * modules/mkdir (Makefile.am): Likewise.
3489         * modules/mkdtemp (Makefile.am): Likewise.
3490         * modules/mkstemp (Makefile.am): Likewise.
3491         * modules/mktime (Makefile.am): Likewise.
3492         * modules/modechange (Makefile.am): Likewise.
3493         * modules/mountlist (Makefile.am): Likewise.
3494         * modules/nanosleep (Makefile.am): Likewise.
3495         * modules/obstack (Makefile.am): Likewise.
3496         * modules/openat (Makefile.am): Likewise.
3497         * modules/pagealign_alloc (Makefile.am): Likewise.
3498         * modules/pathmax (Makefile.am): Likewise.
3499         * modules/physmem (Makefile.am): Likewise.
3500         * modules/poll (Makefile.am): Likewise.
3501         * modules/posixtm (Makefile.am): Likewise.
3502         * modules/posixver (Makefile.am): Likewise.
3503         * modules/putenv (Makefile.am): Likewise.
3504         * modules/quote (Makefile.am): Likewise.
3505         * modules/quotearg (Makefile.am): Likewise.
3506         * modules/raise (Makefile.am): Likewise.
3507         * modules/read-file (Makefile.am): Likewise.
3508         * modules/readline (Makefile.am): Likewise.
3509         * modules/readlink (Makefile.am): Likewise.
3510         * modules/readtokens (Makefile.am): Likewise.
3511         * modules/readutmp (Makefile.am): Likewise.
3512         * modules/realloc (Makefile.am): Likewise.
3513         * modules/regex (Makefile.am): Likewise.
3514         * modules/rename-dest-slash (Makefile.am): Likewise.
3515         * modules/rename (Makefile.am): Likewise.
3516         * modules/rijndael (Makefile.am): Likewise.
3517         * modules/rmdir (Makefile.am): Likewise.
3518         * modules/rpmatch (Makefile.am): Likewise.
3519         * modules/safe-read (Makefile.am): Likewise.
3520         * modules/safe-write (Makefile.am): Likewise.
3521         * modules/same-inode (Makefile.am): Likewise.
3522         * modules/same (Makefile.am): Likewise.
3523         * modules/save-cwd (Makefile.am): Likewise.
3524         * modules/savedir (Makefile.am): Likewise.
3525         * modules/setenv (Makefile.am): Likewise.
3526         * modules/settime (Makefile.am): Likewise.
3527         * modules/sha1 (Makefile.am): Likewise.
3528         * modules/sig2str (Makefile.am): Likewise.
3529         * modules/snprintf (Makefile.am): Likewise.
3530         * modules/stat-macros (Makefile.am): Likewise.
3531         * modules/stat-time (Makefile.am): Likewise.
3532         * modules/stdbool (Makefile.am): Likewise.
3533         * modules/stdint (Makefile.am): Likewise.
3534         * modules/stdlib-safer (Makefile.am): Likewise.
3535         * modules/stpcpy (Makefile.am): Likewise.
3536         * modules/stpncpy (Makefile.am): Likewise.
3537         * modules/strcase (Makefile.am): Likewise.
3538         * modules/strcasestr (Makefile.am): Likewise.
3539         * modules/strchrnul (Makefile.am): Likewise.
3540         * modules/strcspn (Makefile.am): Likewise.
3541         * modules/strdup (Makefile.am): Likewise.
3542         * modules/strerror (Makefile.am): Likewise.
3543         * modules/strftime (Makefile.am): Likewise.
3544         * modules/strndup (Makefile.am): Likewise.
3545         * modules/strnlen (Makefile.am): Likewise.
3546         * modules/strpbrk (Makefile.am): Likewise.
3547         * modules/strsep (Makefile.am): Likewise.
3548         * modules/strstr (Makefile.am): Likewise.
3549         * modules/strtod (Makefile.am): Likewise.
3550         * modules/strtoimax (Makefile.am): Likewise.
3551         * modules/strtok_r (Makefile.am): Likewise.
3552         * modules/strtol (Makefile.am): Likewise.
3553         * modules/strtoll (Makefile.am): Likewise.
3554         * modules/strtoul (Makefile.am): Likewise.
3555         * modules/strtoull (Makefile.am): Likewise.
3556         * modules/strtoumax (Makefile.am): Likewise.
3557         * modules/strverscmp (Makefile.am): Likewise.
3558         * modules/sys_socket (Makefile.am): Likewise.
3559         * modules/sys_stat (Makefile.am): Likewise.
3560         * modules/sysexits (Makefile.am): Likewise.
3561         * modules/time_r (Makefile.am): Likewise.
3562         * modules/timegm (Makefile.am): Likewise.
3563         * modules/timespec (Makefile.am): Likewise.
3564         * modules/tmpfile-safer (Makefile.am): Likewise.
3565         * modules/trim (Makefile.am): Likewise.
3566         * modules/unistd-safer (Makefile.am): Likewise.
3567         * modules/unlinkdir (Makefile.am): Likewise.
3568         * modules/unlocked-io (Makefile.am): Likewise.
3569         * modules/userspec (Makefile.am): Likewise.
3570         * modules/utime (Makefile.am): Likewise.
3571         * modules/utimecmp (Makefile.am): Likewise.
3572         * modules/utimens (Makefile.am): Likewise.
3573         * modules/vasnprintf (Makefile.am): Likewise.
3574         * modules/vasprintf (Makefile.am): Likewise.
3575         * modules/vsnprintf (Makefile.am): Likewise.
3576         * modules/xalloc (Makefile.am): Likewise.
3577         * modules/xgetcwd (Makefile.am): Likewise.
3578         * modules/xnanosleep (Makefile.am): Likewise.
3579         * modules/xreadlink (Makefile.am): Likewise.
3580         * modules/xstrtod (Makefile.am): Likewise.
3581         * modules/xstrtol (Makefile.am): Likewise.
3582         * modules/xstrtold (Makefile.am): Likewise.
3583         * modules/yesno (Makefile.am): Likewise.
3584         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
3585
3586 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
3587
3588         * modules/error (Makefile.am): Distribute files through
3589         EXTRA_DIST, not lib_SOURCES.
3590
3591 2006-10-12  Eric Blake  <ebb9@byu.net>
3592
3593         * modules/error (Makefile.am): Distribute files in /lib.
3594         * modules/obstack (Makefile.am): Likewise.
3595
3596 2006-10-12  Bruno Haible  <bruno@clisp.org>
3597
3598         * modules/acl (Makefile.am): Distribute all files in lib/ through
3599         EXTRA_DIST.
3600         * modules/arcfour (Makefile.am): Likewise.
3601         * modules/arctwo (Makefile.am): Likewise.
3602         * modules/argmatch (Makefile.am): Likewise.
3603         * modules/argz (Makefile.am): Likewise.
3604         * modules/atexit (Makefile.am): Likewise.
3605         * modules/backupfile (Makefile.am): Likewise.
3606         * modules/c-strtod (Makefile.am): Likewise.
3607         * modules/c-strtold (Makefile.am): Likewise.
3608         * modules/calloc (Makefile.am): Likewise.
3609         * modules/canon-host (Makefile.am): Likewise.
3610         * modules/canonicalize (Makefile.am): Likewise.
3611         * modules/chdir-long (Makefile.am): Likewise.
3612         * modules/chdir-safer (Makefile.am): Likewise.
3613         * modules/check-version (Makefile.am): Likewise.
3614         * modules/chown (Makefile.am): Likewise.
3615         * modules/cloexec (Makefile.am): Likewise.
3616         * modules/close-stream (Makefile.am): Likewise.
3617         * modules/closeout (Makefile.am): Likewise.
3618         * modules/crc (Makefile.am): Likewise.
3619         * modules/cycle-check (Makefile.am): Likewise.
3620         * modules/des (Makefile.am): Likewise.
3621         * modules/dirfd (Makefile.am): Likewise.
3622         * modules/dirname (Makefile.am): Likewise.
3623         * modules/dup2 (Makefile.am): Likewise.
3624         * modules/euidaccess (Makefile.am): Likewise.
3625         * modules/exclude (Makefile.am): Likewise.
3626         * modules/exitfail (Makefile.am): Likewise.
3627         * modules/fcntl-safer (Makefile.am): Likewise.
3628         * modules/file-type (Makefile.am): Likewise.
3629         * modules/fileblocks (Makefile.am): Likewise.
3630         * modules/filemode (Makefile.am): Likewise.
3631         * modules/filenamecat (Makefile.am): Likewise.
3632         * modules/fnmatch (Makefile.am): Likewise.
3633         * modules/fopen-safer (Makefile.am): Likewise.
3634         * modules/fpending (Makefile.am): Likewise.
3635         * modules/fprintftime (Makefile.am): Likewise.
3636         * modules/free (Makefile.am): Likewise.
3637         * modules/fsusage (Makefile.am): Likewise.
3638         * modules/ftruncate (Makefile.am): Likewise.
3639         * modules/fts (Makefile.am): Likewise.
3640         * modules/gc (Makefile.am): Likewise.
3641         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
3642         * modules/getaddrinfo (Makefile.am): Likewise.
3643         * modules/getcwd (Makefile.am): Likewise.
3644         * modules/getdelim (Makefile.am): Likewise.
3645         * modules/getdomainname (Makefile.am): Likewise.
3646         * modules/getgroups (Makefile.am): Likewise.
3647         * modules/gethostname (Makefile.am): Likewise.
3648         * modules/gethrxtime (Makefile.am): Likewise.
3649         * modules/getline (Makefile.am): Likewise.
3650         * modules/getloadavg (Makefile.am): Likewise.
3651         * modules/getlogin_r (Makefile.am): Likewise.
3652         * modules/getopt (Makefile.am): Likewise.
3653         * modules/getpass (Makefile.am): Likewise.
3654         * modules/getpass-gnu (Makefile.am): Likewise.
3655         * modules/getsubopt (Makefile.am): Likewise.
3656         * modules/gettime (Makefile.am): Likewise.
3657         * modules/gettimeofday (Makefile.am): Likewise.
3658         * modules/getugroups (Makefile.am): Likewise.
3659         * modules/getusershell (Makefile.am): Likewise.
3660         * modules/glob (Makefile.am): Likewise.
3661         * modules/group-member (Makefile.am): Likewise.
3662         * modules/hard-locale (Makefile.am): Likewise.
3663         * modules/hash (Makefile.am): Likewise.
3664         * modules/hmac-md5 (Makefile.am): Likewise.
3665         * modules/hmac-sha1 (Makefile.am): Likewise.
3666         * modules/human (Makefile.am): Likewise.
3667         * modules/idcache (Makefile.am): Likewise.
3668         * modules/imaxabs (Makefile.am): Likewise.
3669         * modules/imaxdiv (Makefile.am): Likewise.
3670         * modules/inet_ntop (Makefile.am): Likewise.
3671         * modules/inet_pton (Makefile.am): Likewise.
3672         * modules/inttostr (Makefile.am): Likewise.
3673         * modules/isapipe (Makefile.am): Likewise.
3674         * modules/lchown (Makefile.am): Likewise.
3675         * modules/long-options (Makefile.am): Likewise.
3676         * modules/lstat (Makefile.am): Likewise.
3677         * modules/malloc (Makefile.am): Likewise.
3678         * modules/mathl (Makefile.am): Likewise.
3679         * modules/mbchar (Makefile.am): Likewise.
3680         * modules/md2 (Makefile.am): Likewise.
3681         * modules/md4 (Makefile.am): Likewise.
3682         * modules/md5 (Makefile.am): Likewise.
3683         * modules/memcasecmp (Makefile.am): Likewise.
3684         * modules/memchr (Makefile.am): Likewise.
3685         * modules/memcmp (Makefile.am): Likewise.
3686         * modules/memcoll (Makefile.am): Likewise.
3687         * modules/memcpy (Makefile.am): Likewise.
3688         * modules/memmem (Makefile.am): Likewise.
3689         * modules/memmove (Makefile.am): Likewise.
3690         * modules/mempcpy (Makefile.am): Likewise.
3691         * modules/memrchr (Makefile.am): Likewise.
3692         * modules/memset (Makefile.am): Likewise.
3693         * modules/memxor (Makefile.am): Likewise.
3694         * modules/mkancesdirs (Makefile.am): Likewise.
3695         * modules/mkdir (Makefile.am): Likewise.
3696         * modules/mkdir-p (Makefile.am): Likewise.
3697         * modules/mkdtemp (Makefile.am): Likewise.
3698         * modules/mkstemp (Makefile.am): Likewise.
3699         * modules/mktime (Makefile.am): Likewise.
3700         * modules/modechange (Makefile.am): Likewise.
3701         * modules/mountlist (Makefile.am): Likewise.
3702         * modules/nanosleep (Makefile.am): Likewise.
3703         * modules/openat (Makefile.am): Likewise.
3704         * modules/pagealign_alloc (Makefile.am): Likewise.
3705         * modules/physmem (Makefile.am): Likewise.
3706         * modules/poll (Makefile.am): Likewise.
3707         * modules/posixtm (Makefile.am): Likewise.
3708         * modules/posixver (Makefile.am): Likewise.
3709         * modules/putenv (Makefile.am): Likewise.
3710         * modules/quote (Makefile.am): Likewise.
3711         * modules/quotearg (Makefile.am): Likewise.
3712         * modules/raise (Makefile.am): Likewise.
3713         * modules/read-file (Makefile.am): Likewise.
3714         * modules/readline (Makefile.am): Likewise.
3715         * modules/readlink (Makefile.am): Likewise.
3716         * modules/readtokens (Makefile.am): Likewise.
3717         * modules/readutmp (Makefile.am): Likewise.
3718         * modules/realloc (Makefile.am): Likewise.
3719         * modules/regex (Makefile.am): Likewise.
3720         * modules/rename (Makefile.am): Likewise.
3721         * modules/rename-dest-slash (Makefile.am): Likewise.
3722         * modules/rijndael (Makefile.am): Likewise.
3723         * modules/rmdir (Makefile.am): Likewise.
3724         * modules/rpmatch (Makefile.am): Likewise.
3725         * modules/safe-read (Makefile.am): Likewise.
3726         * modules/safe-write (Makefile.am): Likewise.
3727         * modules/same (Makefile.am): Likewise.
3728         * modules/save-cwd (Makefile.am): Likewise.
3729         * modules/savedir (Makefile.am): Likewise.
3730         * modules/setenv (Makefile.am): Likewise.
3731         * modules/settime (Makefile.am): Likewise.
3732         * modules/sha1 (Makefile.am): Likewise.
3733         * modules/sig2str (Makefile.am): Likewise.
3734         * modules/snprintf (Makefile.am): Likewise.
3735         * modules/stdlib-safer (Makefile.am): Likewise.
3736         * modules/stpcpy (Makefile.am): Likewise.
3737         * modules/stpncpy (Makefile.am): Likewise.
3738         * modules/strcase (Makefile.am): Likewise.
3739         * modules/strcasestr (Makefile.am): Likewise.
3740         * modules/strchrnul (Makefile.am): Likewise.
3741         * modules/strcspn (Makefile.am): Likewise.
3742         * modules/strdup (Makefile.am): Likewise.
3743         * modules/strerror (Makefile.am): Likewise.
3744         * modules/strftime (Makefile.am): Likewise.
3745         * modules/strndup (Makefile.am): Likewise.
3746         * modules/strnlen (Makefile.am): Likewise.
3747         * modules/strpbrk (Makefile.am): Likewise.
3748         * modules/strsep (Makefile.am): Likewise.
3749         * modules/strstr (Makefile.am): Likewise.
3750         * modules/strtod (Makefile.am): Likewise.
3751         * modules/strtoimax (Makefile.am): Likewise.
3752         * modules/strtok_r (Makefile.am): Likewise.
3753         * modules/strtol (Makefile.am): Likewise.
3754         * modules/strtoll (Makefile.am): Likewise.
3755         * modules/strtoul (Makefile.am): Likewise.
3756         * modules/strtoull (Makefile.am): Likewise.
3757         * modules/strtoumax (Makefile.am): Likewise.
3758         * modules/strverscmp (Makefile.am): Likewise.
3759         * modules/time_r (Makefile.am): Likewise.
3760         * modules/timegm (Makefile.am): Likewise.
3761         * modules/tmpfile-safer (Makefile.am): Likewise.
3762         * modules/unistd-safer (Makefile.am): Likewise.
3763         * modules/unlinkdir (Makefile.am): Likewise.
3764         * modules/userspec (Makefile.am): Likewise.
3765         * modules/utime (Makefile.am): Likewise.
3766         * modules/utimecmp (Makefile.am): Likewise.
3767         * modules/utimens (Makefile.am): Likewise.
3768         * modules/vasnprintf (Makefile.am): Likewise.
3769         * modules/vasprintf (Makefile.am): Likewise.
3770         * modules/vsnprintf (Makefile.am): Likewise.
3771         * modules/xalloc (Makefile.am): Likewise.
3772         * modules/xgetcwd (Makefile.am): Likewise.
3773         * modules/xnanosleep (Makefile.am): Likewise.
3774         * modules/xreadlink (Makefile.am): Likewise.
3775         * modules/xstrtod (Makefile.am): Likewise.
3776         * modules/xstrtol (Makefile.am): Likewise.
3777         * modules/xstrtold (Makefile.am): Likewise.
3778         * modules/yesno (Makefile.am): Likewise.
3779
3780 2006-10-12  Jim Meyering  <jim@meyering.net>
3781
3782         * m4/getloadavg.m4: Revert the change below.
3783
3784         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
3785         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
3786         fail with a symlink, which is what coreutils' ./bootstrap now
3787         creates by default.
3788
3789 2006-10-12  Bruno Haible  <bruno@clisp.org>
3790
3791         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
3792         mingw.
3793         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
3794         MSVC and mingw explicitly.
3795
3796 2006-10-11  Simon Josefsson  <jas@extundo.com>
3797             Bruno Haible  <bruno@clisp.org>
3798
3799         Add support for multiple gnulib-tool invocations in the scope of a
3800         single configure.ac file.
3801         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
3802         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
3803         with the same contents as the _LIBADD variable.
3804         (func_emit_initmacro_start, func_emit_initmacro_end,
3805         func_emit_initmacro_done): New functions.
3806         (func_import, func_create_testdir): Invoke them. Allow the identifiers
3807         gl_LIBOBJS and gl_LTLIBOBJS.
3808
3809 2006-10-11  Bruno Haible  <bruno@clisp.org>
3810
3811         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
3812         (func_create_testdir): Don't create po/Makefile.am, don't invoke
3813         autoreconf. Instead, invoke autopoint explicitly but move back the
3814         *.m4 files from gnulib.
3815
3816 2006-10-11  Bruno Haible  <bruno@clisp.org>
3817
3818         * gnulib-tool (func_usage): Make module names after --create-testdir
3819         optional.
3820         (func_create_testdir): If no module was specified, use nearly all
3821         modules.
3822
3823 2006-10-12  Jim Meyering  <jim@meyering.net>
3824
3825         Big performance improvement for fts-based tools that use FTS_NOSTAT.
3826         Avoid spurious inode-mismatch problems on non-POSIX file systems.
3827         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
3828         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
3829         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
3830         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
3831         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
3832         (fts_set_stat_required): New function.
3833         (fts_open): Defer the calls to fts_stat, if possible or requested.
3834         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
3835         into fts_stat itself.
3836         (fts_read): Perform any required (deferred) fts_stat call.
3837         (fts_build): Likewise, for the directory we're about to open and read.
3838         In the readdir loop, carefully decide whether each entry will require
3839         an eventual call to fts_stat, using dirent.d_type info if available.
3840         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
3841         a command line argument into this function.  Update all callers.
3842         Map a return value of FTS_DOT to FTS_D for a command line argument.
3843         * modules/fts (Depends-on): Add d-type.  Alphabetize.
3844         Thanks to Miklos Szeredi for his tenacity and for the initial
3845         bug report about "find" failing on a FUSE-based file system.
3846
3847         * lib/fts.c (fts_open): Use consistent indentation.
3848
3849 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
3850
3851         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
3852         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
3853         reported by Jim Meyering.  All uses of cache variables renamed
3854         to match Autoconf's.
3855         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
3856         the other one.
3857
3858         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
3859         Fix misspelling in diagnostic.
3860
3861 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
3862
3863         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
3864         defined.  Problem reported by Matthew Woehlke.
3865
3866         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
3867         Add support for Tandem NonStop R series.
3868         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
3869         Use new macro.
3870
3871         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
3872         (has_trailing_slash): Omit size arg; all callers changed.
3873         Omit 'inline', since it doesn't help performance and we'd
3874         need to configure it.
3875         Don't count //, ///, etc. as having a trailing slash.
3876         As a side effect, this removes a C99ism reported by Matthew Woehlke.
3877         (rpl_rename_dest_slash): On failure, use rename's errno rather
3878         than (in some cases) an incorrect or junk errno.
3879         Simplify code by removing need to compute length; this does
3880         cause it to make two passes instead of one over the file name,
3881         but it's worth it.
3882
3883         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
3884         change, since Autoconf's version may no longer be appropriate now
3885         that we are using CVS Autoconf's version.  Add support for Tandem.
3886
3887 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
3888             Bruno Haible  <bruno@clisp.org>
3889
3890         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
3891         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
3892         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
3893         gl_AC_TYPE_LONG_LONG.
3894
3895         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
3896         instead of HAVE_LONG_LONG.
3897         * lib/printf-args.c (printf_fetchargs): Likewise.
3898         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
3899         * lib/vasnprintf.c (VASNPRINTF): Likewise.
3900         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
3901         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
3902         gl_AC_TYPE_LONG_LONG.
3903
3904 2006-10-11  Bruno Haible  <bruno@clisp.org>
3905
3906         * m4/longlong.m4: Add comments.
3907         * m4/ulonglong.m4: Likewise.
3908
3909 2006-10-10  Bruno Haible  <bruno@clisp.org>
3910
3911         Make it possible to #define stpcpy, strdup to aliases.
3912         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
3913         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
3914
3915 2006-10-10  Bruno Haible  <bruno@clisp.org>
3916
3917         Make it possible to #define gcd to an alias.
3918         * lib/gcd.c: Include config.h.
3919
3920 2006-10-10  Bruno Haible  <bruno@clisp.org>
3921
3922         Make it possible to #define c_isascii to an alias.
3923         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
3924         defined. Undefine the macros before defining them, to avoid gcc
3925         warnings.
3926         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
3927         define NO_C_CTYPE_MACROS early.
3928
3929 2006-10-10  Bruno Haible  <bruno@clisp.org>
3930
3931         Make it possible to #define set_program_name to an alias.
3932         * lib/progname.c: Don't undefine set_program_name; instead, undefine
3933         ENABLE_RELOCATABLE early.
3934
3935 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
3936
3937         Port to Tandem NSK OSS, which has 64-bit signed int but at most
3938         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
3939         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
3940         More generally, don't assume that 64-bit signed int is available
3941         if unsigned int is, and vice versa.
3942         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
3943         unsigned symbols, not on their signed counterparts.
3944         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
3945         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
3946         (UINT64_C, UINTMAX_C):
3947         Likewise.
3948         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
3949         unsigned counterparts.
3950         (Have_long_long, Unsigned): New macros.
3951         (Int): Renamed from INT.
3952         (strtoimax): Use the new macros.
3953         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
3954         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
3955         * modules/inttypes (inttypes.h): Substitute
3956         HAVE_UNSIGNED_LONG_LONG_INT.
3957         * modules/stdint (stdint.h): Likewise.
3958         (Files): Add m4/ulonglong.m4.
3959
3960 2006-10-10  Bruno Haible  <bruno@clisp.org>
3961
3962         Fix a gcc -Wshadow warning.
3963         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
3964         to 'bucket'.
3965         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
3966         gl_linked_indexof_from_to): Likewise.
3967         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
3968         Likewise.
3969         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
3970         Likewise.
3971         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
3972         Reported by Eric Blake.
3973
3974 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
3975
3976         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
3977         for NetBSD.  Problem reported by Bruno Haible.
3978
3979 2006-10-09  Jim Meyering  <jim@meyering.net>
3980
3981         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
3982         Patch from Bruno Haible.
3983
3984 2006-10-09  Jim Meyering  <jim@meyering.net>
3985
3986         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
3987         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
3988         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
3989
3990 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
3991
3992         Don't include <config.h> twice; this doesn't work in some cases,
3993         e.g., when config.h has "#define intmax_t long long int" and
3994         we include <config.h>, <inttypes.h>, <config.h> in that order.
3995         Problem reported by Matthew Woehlke in:
3996         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
3997         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
3998         * lib/fts-cycle.c: Don't include config.h.
3999         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
4000         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
4001         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
4002         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
4003         inttypes.h.
4004         * lib/xstrtoumax.c: Likewise.
4005         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
4006         __strtol and the like, so that this module is more like its siblings.
4007         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
4008         Remove; no longer needed now that we assume gnulib inttypes.h.
4009
4010 2006-10-08  Bruno Haible  <bruno@clisp.org>
4011
4012         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
4013         option.
4014
4015 2006-10-07  Jim Meyering  <jim@meyering.net>
4016
4017         * modules/inttypes (inttypes.h): Revert what seems to have been
4018         an inadvertent part of today's change: use "|", not "/" in the
4019         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
4020
4021 2006-10-07  Bruno Haible  <bruno@clisp.org>
4022
4023         * modules/sublist: New file.
4024
4025 2006-10-07  Bruno Haible  <bruno@clisp.org>
4026
4027         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
4028         * modules/argz (argz.h): Likewise.
4029         * modules/arpa_inet (arpa/inet.h): Likewise.
4030         * modules/byteswap (byteswap.h): Likewise.
4031         * modules/configmake (configmake.h): Likewise.
4032         * modules/fcntl (fcntl.h): Likewise.
4033         * modules/fnmatch (fnmatch.h): Likewise.
4034         * modules/getopt (getopt.h): Likewise.
4035         * modules/glob (glob.h): Likewise.
4036         * modules/inttypes (inttypes.h): Likewise.
4037         * modules/netinet_in (netinet/in.h): Likewise.
4038         * modules/poll (poll.h): Likewise.
4039         * modules/stdbool (stdbool.h): Likewise.
4040         * modules/stdint (stdint.h): Likewise.
4041         * modules/sys_select (sys/select.h): Likewise.
4042         * modules/sys_socket (sys/socket.h): Likewise.
4043         * modules/sys_stat (sys/stat.h): Likewise.
4044         * modules/sysexits (sysexits.h): Likewise.
4045         * modules/unistd (unistd.h): Likewise.
4046         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4047         Add a "DO NOT EDIT" comment to the generated file.
4048         (func_import): Likewise for gnulib-comp.m4.
4049
4050 2006-10-07  Bruno Haible  <bruno@clisp.org>
4051
4052         * lib/gl_sublist.h: New file.
4053         * lib/gl_sublist.c: New file.
4054
4055 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
4056
4057         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
4058         name (relative to the original working directory) and the file
4059         name component (relative to the temporary working directory).  All
4060         callers changed.
4061         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
4062         * lib/mkdir-p.c (make_dir_parents): Likewise.
4063         * lib/mkdir-p.h (make_dir_parents): Likewise.
4064
4065 2006-10-06  Eric Blake  <ebb9@byu.net>
4066
4067         Define several macros for use by the clean-temp module.
4068         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
4069         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
4070         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
4071
4072         * lib/clean-temp.h (close_stream_temp): New declaration.
4073         * lib/clean-temp.c (includes): Pull in headers according to what
4074         other modules are in use.
4075         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
4076
4077 2006-10-06  Bruno Haible  <bruno@clisp.org>
4078
4079         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
4080         instead of fopen, fwriteerror.
4081
4082 2006-10-06  Bruno Haible  <bruno@clisp.org>
4083
4084         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
4085         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
4086         int.
4087         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
4088         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
4089         Return an error indicator.
4090         Suggested by Eric Blake.
4091
4092 2006-10-06  Bruno Haible  <bruno@clisp.org>
4093
4094         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
4095         Reported by Eric Blake.
4096
4097 2006-10-06  Bruno Haible  <bruno@clisp.org>
4098
4099         * modules/closeout (Description): Mention stderr too.
4100
4101 2006-10-06  Bruno Haible  <bruno@clisp.org>
4102         and Paul Eggert  <eggert@cs.ucla.edu>
4103
4104         * lib/closeout.c (close_stdout): Also close stderr.
4105         * lib/closeout.h: Update comment.
4106
4107 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
4108
4109         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
4110         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
4111         * lib/dirchownmod.c: Include lchown.h.
4112         * lib/lchown.c: Don't include files that lchown.h now includes.
4113         Don't declare chown, since lchown.h now does that.
4114         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
4115         (lchown): Define to rpl_chown if lchown is declared but
4116         does not exist.  Declare using a prototype if lchown is not
4117         declared.  Add a copyright notice.
4118         * lib/mkstemp.h: Include <unistd.h>.
4119         * lib/openat.c: Include lchown.h.
4120
4121         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
4122         we now test for that separately.
4123         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
4124         rather than O_NOFOLLOW, when testing whether it's possible to
4125         avoid a race condition reliably.
4126         * lib/savewd.c (savewd_chdir): Likewise.
4127
4128         Remove macros that are no longer needed now that stdint.h is
4129         reliable.
4130         * lib/fsusage.c (UINTMAX_MAX): Remove.
4131         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
4132         * lib/utimecmp.c (SIZE_MAX): Remove.
4133
4134         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
4135
4136         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
4137         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
4138         O_NOATIME works.
4139
4140 2006-10-05  Bruno Haible  <bruno@clisp.org>
4141
4142         * lib/gl_list.h (gl_sortedlist_search_from_to,
4143         gl_sortedlist_indexof_from_to): New declarations.
4144         (gl_list_implementation): New fields sortedlist_search_from_to,
4145         sortedlist_indexof_from_to.
4146         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
4147         inline functions.
4148         * lib/gl_list.c (gl_sortedlist_search_from_to,
4149         gl_sortedlist_indexof_from_to): New functions.
4150         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
4151         function.
4152         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
4153         (gl_array_sortedlist_search_from_to): New function.
4154         (gl_array_list_implementation): Update.
4155         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
4156         function.
4157         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
4158         (gl_carray_sortedlist_search_from_to): New function.
4159         (gl_carray_list_implementation): Update.
4160         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
4161         gl_linked_sortedlist_indexof_from_to): New functions.
4162         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
4163         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
4164         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
4165         gl_tree_sortedlist_indexof_from_to): New functions.
4166         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
4167         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
4168         Update.
4169         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
4170         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
4171         Update.
4172
4173 2006-10-05  Bruno Haible  <bruno@clisp.org>
4174
4175         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
4176         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
4177         (struct gl_list_implementation): Add fields search_from_to,
4178         indexof_from_to. Remove fields search, indexof.
4179         (gl_list_search): Use the search_from_to method.
4180         (gl_list_search_from, gl_list_search_from_to): New functions.
4181         (gl_list_indexof): Use the indexof_from_to method.
4182         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
4183         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
4184         (gl_list_search_from, gl_list_search_from_to): New functions.
4185         (gl_list_indexof): Use the indexof_from_to method.
4186         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
4187         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
4188         gl_array_indexof. Add start_index, end_index arguments.
4189         (gl_array_search_from_to): Renamed from gl_array_search. Add
4190         start_index, end_index arguments.
4191         (gl_array_remove, gl_array_list_implementation): Update.
4192         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
4193         gl_carray_indexof. Add start_index, end_index arguments.
4194         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
4195         start_index, end_index arguments.
4196         (gl_carray_remove, gl_carray_list_implementation): Update.
4197         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
4198         gl_linked_search. Add start_index, end_index arguments.
4199         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
4200         start_index, end_index arguments.
4201         (gl_linked_remove): Update.
4202         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
4203         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
4204         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
4205         field to 'size_t'.
4206         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
4207         gl_tree_search. Add start_index, end_index arguments.
4208         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
4209         start_index, end_index arguments.
4210         (gl_tree_remove): Update.
4211         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
4212         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
4213         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
4214         function.
4215         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
4216         gl_tree_search. Add start_index, end_index arguments.
4217         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
4218         start_index, end_index arguments.
4219         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
4220         Update.
4221         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
4222
4223 2006-10-05  Bruno Haible  <bruno@clisp.org>
4224
4225         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
4226
4227         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
4228         fwriteerror_temp): New declarations.
4229         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
4230         (descriptors): New variable.
4231         (cleanup): First, close the descriptors.
4232         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
4233         fclose_temp, fwriteerror_temp): New functions.
4234
4235 2006-10-04  Jim Meyering  <jim@meyering.net>
4236
4237         * lib/fts.c (fts_open): Tiny comment change.
4238
4239 2006-10-04  Bruno Haible  <bruno@clisp.org>
4240
4241         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
4242         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
4243         gl_LOCK_BODY.
4244         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
4245         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
4246         gl_LOCK_EARLY_BODY.
4247         (gl_LOCK): Require gl_LOCK_BODY.
4248
4249 2006-10-04  Bruno Haible  <bruno@clisp.org>
4250
4251         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
4252         (gl_oset_search_atleast): New declaration.
4253         (struct gl_oset_implementation): Add field 'search_atleast'.
4254         (gl_oset_search_atleast): New inline function.
4255         * lib/gl_oset.c (gl_oset_search_atleast): New function.
4256         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
4257         (gl_array_oset_implementation): Update.
4258         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
4259         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
4260         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
4261
4262 2006-10-04  Bruno Haible  <bruno@clisp.org>
4263
4264         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
4265
4266 2006-10-03  Bruno Haible  <bruno@clisp.org>
4267
4268         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
4269         from gl_avltreehash_list_implementation.
4270
4271 2006-10-03  Bruno Haible  <bruno@clisp.org>
4272
4273         * lib/gl_oset.c (gl_oset_add): Fix return type.
4274
4275 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
4276
4277         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
4278
4279 2006-10-02  Eric Blake  <ebb9@byu.net>
4280
4281         * modules/strnlen (Depends-on): Add extensions.
4282
4283 2006-10-02  Eric Blake  <ebb9@byu.net>
4284
4285         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
4286         definition in 2.60+.
4287
4288 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
4289
4290         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
4291         checks.
4292
4293 2006-10-02  Bruno Haible  <bruno@clisp.org>
4294
4295         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
4296         to the AUTOMAKE_OPTIONS.
4297         Reported by Jim Meyering.
4298
4299 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
4300
4301         Work around bug in Solaris 10 /proc file system:
4302         /proc/self/fd/NNN/.. isn't the parent directory of
4303         the directory whose file descriptor is NNN.  This needs to
4304         be worked around at run time, not compile time, since a
4305         program might be built on Solaris 8, where things work, and
4306         run on Solaris 10.
4307         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
4308         to use the following interface instead:
4309         (OPENAT_BUFFER_SIZE): New macro.
4310         (openat_proc_name): New function.
4311         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
4312         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
4313         Likewise.
4314         * lib/openat-proc.c: New file.
4315         * modules/openat (Files): Add lib/openat-proc.c.
4316         (Depends-on): Add same-inode, stdbool.
4317         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
4318
4319 2006-09-29  Bruno Haible  <bruno@clisp.org>
4320
4321         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
4322         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
4323         argument. Set stdout_closed before testing for ferror, not after.
4324         (fwriteerror, fwriteerror_no_ebadf): New functions.
4325
4326 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4327
4328         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
4329
4330 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
4331
4332         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
4333         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
4334
4335 2006-09-28  Jim Meyering  <jim@meyering.net>
4336
4337         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
4338         Include <unistd.h>.
4339
4340 2006-09-28  Bruno Haible  <bruno@clisp.org>
4341
4342         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
4343         * modules/linkedhash-list (Depends-on): Likewise.
4344         * modules/rbtreehash-list (Depends-on): Likewise.
4345
4346 2006-09-28  Bruno Haible  <bruno@clisp.org>
4347
4348         * lib/strndup.h: Simplify the redefinition of strndup.
4349         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
4350         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
4351
4352 2006-09-28  Bruno Haible  <bruno@clisp.org>
4353
4354         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
4355         * lib/gl_linkedhash_list.c: Likewise.
4356         * lib/gl_rbtreehash_list.c: Likewise.
4357
4358 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
4359
4360         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
4361         getaddrinfo.
4362
4363         * lib/__fpending.h: Don't include <stdio_ext.h> unless
4364         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
4365         it causes <stdio_ext.h> to cause a compile-time error.
4366         Problem reported by Nelson H. F. Beebe.
4367         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
4368         of HAVE_DECL___PENDING.
4369
4370         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
4371         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
4372         declaration.
4373
4374 2006-09-27  Jim Meyering  <jim@meyering.net>
4375
4376         This file could end up with a definition for a function
4377         named __strndup, rather than rpl_strndup on a system with
4378         incomplete weak_alias support.
4379         * lib/strndup.c (strndup): Rename from __strndup.
4380         Remove #defines that used to map __strndup to strndup.
4381         Don't use K&R prototypes.
4382         Remove LIBC-related code, since this file is not sync'd with glibc.
4383         * lib/strndup.h: Revamp, accordingly.
4384         * m4/strndup.m4: Modernize.
4385
4386 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
4387
4388         * modules/savewd (Depends-on): Add 'raise'.
4389         * lib/savewd.c: Include <signal.h>, for 'raise'.
4390
4391 2006-09-26  Jim Meyering  <jim@meyering.net>
4392
4393         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
4394         when we detect Darwin 8.7.0's acl_get_file bug.
4395         Rearrange to perform the new (below) run-test while $LIBS
4396         contains any acl-related library.  Set USE_ACL at the end.
4397         (gl_ACL_GET_FILE): New function.
4398
4399 2006-09-26  Eric Blake  <ebb9@byu.net>
4400
4401         * lib/verror.c: Include <config.h> unconditionally.
4402
4403 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
4404
4405         * modules/clock-time (Maintainer): Add self.
4406         * modules/getlogin_r (Depends-on): Add extensions.
4407
4408 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4409
4410         * modules/clock-time: New module.
4411         * modules/nanosleep (Depends-on): Add clock-time.
4412         * modules/gethrxtime (Depends-on): Likewise.
4413         * modules/gettime (Depends-on): Likewise.
4414         * modules/settime (Depends-on): Likewise.
4415
4416         * modules/fts-lgpl: Depend on openat.
4417         * modules/mkancesdirs: Depend on savewd.
4418         * modules/mkdir-p: Likewise.
4419
4420 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4421
4422         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
4423
4424         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
4425         `gl_have_arbitrary_file_name_length_limit' to
4426         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
4427         actually works between configure runs.
4428
4429 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4430             Bruno Haible  <bruno@clisp.org>
4431
4432         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
4433
4434 2006-09-25  Jim Meyering  <jim@meyering.net>
4435
4436         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
4437         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
4438
4439 2006-09-25  Eric Blake  <ebb9@byu.net>
4440
4441         * gnulib-tool (func_import, func_create_testdir): Fix typos in
4442         exec's in 2006-09-18 patch when shuffling fds.
4443
4444 2006-09-25  Bruno Haible  <bruno@clisp.org>
4445
4446         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
4447         Reported by Jim Meyering.
4448
4449 2006-09-24  Jim Meyering  <jim@meyering.net>
4450
4451         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
4452         compare a pointer against a literal "0".  That caused failures with
4453         at least HP-UX's hpcc.
4454
4455 2006-09-22  Simon Josefsson  <jas@extundo.com>
4456
4457         * modules/gc-sha1:
4458         * modules/gc-md4:
4459         * modules/gc-hmac-sha1:
4460         * modules/gc-hmac-md5:
4461         * modules/gc-des:
4462         * modules/gc-arcfour: Distribute more files.
4463
4464 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4465
4466         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
4467         (gl_linked_iterator_from_to): Initialize struct completely.
4468         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
4469         (gl_tree_iterator_from_to): Likewise
4470         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
4471         * lib/gl_array_list.c [lint] (gl_array_iterator)
4472         (gl_array_iterator_from_to): Likewise.
4473         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
4474         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
4475         (gl_carray_iterator_from_to): Likewise.
4476
4477         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
4478         * lib/md4.c (md4_process_block): Remove unused variable.
4479         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
4480         parentheses for clarity.
4481
4482 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4483
4484         * modules/bison-i18n (Depends-on): Add gettext.
4485
4486 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4487
4488         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
4489         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
4490         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
4491         also add missing comma that caused broken test.
4492         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
4493         stdlib.h, for `abort'.
4494         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
4495         variables.
4496         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
4497         include unistd.h if present, for `rmdir'.
4498         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
4499         variables.
4500         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
4501         in the process include standard headers for prototypes.
4502         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
4503         gets declared on GNU/Linux.
4504         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
4505         unistd.h, for `rmdir'.
4506         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
4507
4508         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
4509         always true.
4510         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
4511
4512         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
4513
4514 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4515
4516         * gnulib-tool (func_version): Create output all at once.  This
4517         may help avoid triggering unnecessary SIGPIPEs, and at any
4518         rate it doesn't hurt.
4519
4520 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4521             Bruno Haible  <bruno@clisp.org>
4522
4523         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
4524         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
4525         * m4/signed.m4 (bh_C_SIGNED): Likewise.
4526
4527         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
4528         (gl_FUNC_VASPRINTF): Invoke it.
4529
4530 2006-09-22  Bruno Haible  <bruno@clisp.org>
4531
4532         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
4533         getloadavg.c as first argument.
4534
4535 2006-09-22  Bruno Haible  <bruno@clisp.org>
4536
4537         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
4538         at the beginning of the gl_INIT macro.
4539         * modules/getloadavg (configure.ac): Pass $gl_source_base to
4540         gl_GETLOADAVG.
4541
4542 2006-09-22  Bruno Haible  <bruno@clisp.org>
4543
4544         * gnulib-tool (func_create_megatestdir): Don't include the config-h
4545         module.
4546         Suggested by Ralf Wildenhues.
4547
4548 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
4549
4550         Import this patch from libc:
4551
4552         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
4553
4554         * lib/regex_internal.c (re_string_reconstruct): Handle
4555         offset < pstr->valid_raw_len && pstr->offsets_needed case.
4556         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
4557         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
4558         re_string_context_at.
4559
4560         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
4561         now requires it.
4562         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
4563         gl_REGEX now does it for us.
4564         (gl_REGEX): Add test taken from
4565         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
4566
4567         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
4568         Check that large offsets work.  Modernize Autoconf usages.
4569         Prefer "yes" to mean a good thing rather than a bad.
4570         Don't put "#define mkstemp" in config.h, as this might interfere
4571         with standard system headers that "#define mkstemp mkstemp64".
4572
4573         * modules/mkstemp (Depends-on): Add extensions, so that
4574         mkstemp is visible on some platforms.
4575         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
4576         (Include): Change to "mkstemp.h" from <stdlib.h>.
4577         (Files): Add mkstemp.h.
4578
4579         * lib/mkstemp.h: New file, since some standard headers
4580         #define mkstemp.
4581         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
4582         Include "mkstemp.h".
4583         Make the _LIBC code resemble glibc original more,
4584         e.g., use K&R style.
4585         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
4586         (mkstemp): Remove, since mkstemp.h does this for us.
4587         * lib/stdlib--.h: Include mkstemp.h.
4588
4589         Import this patch from libc:
4590
4591         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
4592
4593         * lib/tempname.c (__gen_tempname): Change attempts_min
4594         into a macro.  Use preprocessor to decide how to initialize
4595         attempts [Coverity CID 67].
4596
4597 2006-09-20  Bruno Haible  <bruno@clisp.org>
4598
4599         * lib/mkdtemp.c: Import from libc.
4600         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
4601                 * sysdeps/posix/tempname.c (__gen_tempname): Change
4602                 attempts_min into a macro.  Use preprocessor to decide how to
4603                 initialize attempts [Coverity CID 67].
4604         2001-11-27  Paul Eggert  <eggert@twinsun.com>
4605                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
4606                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
4607
4608 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4609
4610         * gnulib-tool (func_exit): New function, to allow to pass the
4611         exit status portably through the trap.  Use everywhere.
4612         (--help, --version): Signal a write error.
4613         (trap): catch SIGPIPE, for write errors.
4614         Exit at the end of the trap, with the correct exit status.
4615
4616 2006-09-19  Karl Berry  <karl@gnu.org>
4617
4618         * doc/gnulib.texi: note about the license texinfo files.
4619
4620 2006-09-19  Eric Blake  <ebb9@byu.net>
4621
4622         * gnulib-tool: Avoid space-tab.
4623
4624 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
4625
4626         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
4627         that prevented coreutils 6.1 from building.  Problem reported
4628         by Petter Reinholdtsen.
4629
4630 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
4631
4632         * gnulib-tool (avoidlist): Fix typo that broke options like
4633         --avoid=lock that are used by coreutils bootstrap.
4634
4635 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
4636
4637         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
4638         more systematically.
4639
4640 2006-09-18  Jim Meyering  <jim@meyering.net>
4641
4642         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
4643
4644 2006-09-18  Bruno Haible  <bruno@clisp.org>
4645
4646         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
4647
4648 2006-09-18  Bruno Haible  <bruno@clisp.org>
4649
4650         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
4651         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
4652         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
4653         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
4654         * m4/gettext.m4: Require autoconf >= 2.52.
4655         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
4656         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
4657         of gl_cv_header_inttypes_h.
4658
4659 2006-09-18  Bruno Haible  <bruno@clisp.org>
4660
4661         * lib/javaversion.c: Include configmake.h.
4662
4663 2006-09-18  Bruno Haible  <bruno@clisp.org>
4664
4665         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
4666         avoid that the while loops be executed in a subshell.
4667
4668 2006-09-18  Bruno Haible  <bruno@clisp.org>
4669
4670         * MODULES.html.sh (func_module): Break long lines.
4671         Suggested by Bruce Korb <bkorb@gnu.org>.
4672
4673 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4674
4675         Speed up by a factor of 1.12.
4676         * gnulib-tool (nl): New variable.
4677         (func_import): Rewrite include directive extraction to only read each
4678         directive once.
4679
4680 2006-09-17  Bruno Haible  <bruno@clisp.org>
4681
4682         * modules/javaversion (Makefile.am): Remove DEFS setting.
4683         (Depends-on): Add configmake, for PKGDATADIR definition.
4684
4685 2006-09-17  Bruno Haible  <bruno@clisp.org>
4686
4687         * gnulib-tool (func_create_testdir): Rewrite all files at once.
4688
4689 2006-09-17  Bruno Haible  <bruno@clisp.org>
4690
4691         * gnulib-tool (func_append): New function, stolen from libtool.m4.
4692         (func_modules_transitive_closure, func_modules_add_dummy,
4693         func_modules_to_filelist, func_import, func_create_testdir,
4694         func_create_megatestdir, ...): Use it wherever possible.
4695         Suggested by Ralf Wildenhues.
4696
4697 2006-09-16  Karl Berry  <karl@gnu.org>
4698
4699         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
4700         to avoid sectioning errors.
4701         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
4702         [ifinfo]: blank line after @center-ed titles.
4703         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
4704         Spell FSF address consistently with others.
4705         (These changes approved by rms.)
4706
4707 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4708
4709         Speed up by a factor of 1.61.
4710         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
4711         already checked module names again.
4712
4713 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4714
4715         Speed up by a factor of 1.13.
4716         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
4717         for new_files, and the input to func_add_or_update.
4718
4719 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4720
4721         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
4722         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
4723
4724 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4725
4726         * modules/mkancesdirs (Depends-on): Add fcntl.
4727         * modules/savewd: New file.
4728         * MODULES.html.sh (File system functions): Add savewd.
4729
4730         * modules/configmake (Makefile.am): Add support for the
4731         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
4732
4733 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4734
4735         * m4/savewd.m4: New file.
4736
4737 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4738
4739         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
4740         (dirchownmod): New arg FD.  All callers changed.
4741         Use FD rather than opening the directory ourself, as opening is
4742         now the caller's responsibility.
4743         * lib/dirchownmod.h: Likewise.
4744         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
4745         hosts that require <sys/types.h> before <sys/stat.h>.  Include
4746         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
4747         (test_dir): Remove.
4748         (mkancesdirs): Return length of prefix of FILE that has already
4749         been made, or -2 if there is a child doing the work.  Redo
4750         algorithm so that it is O(N) rather than O(N**2).  Optimize away
4751         ".", and treat ".." specially since it might stray back into
4752         already-created areas.  Use a subprocess if necessary.  New arg
4753         WD; all users changed.  MAKE_DIR function should now return 1
4754         if it creates a directory that is not readable.  Return -2 if
4755         a child process is spun off.
4756         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
4757         Adjust signature to match code.
4758         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
4759         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
4760         all users changed.
4761         * lib/savewd.c, lib/savewd.h: New files.
4762
4763 2006-09-15  Jim Meyering  <jim@meyering.net>
4764
4765         * modules/rename-dest-slash: New module.
4766         * MODULES.html.sh (posix_compat): Add it here.
4767
4768         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
4769
4770 2006-09-15  Jim Meyering  <jim@meyering.net>
4771
4772         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
4773         file.
4774
4775         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
4776
4777 2006-09-15  Jim Meyering  <jim@meyering.net>
4778
4779         * lib/rename-dest-slash.c (has_trailing_slash): Use
4780         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
4781         (rpl_rename_dest_slash): Perform the cheaper trailing slash
4782         test before testing whether SRC is a directory.
4783         Suggestions from Bruno Haible.
4784
4785         Avoid a warning about an unused variable.
4786         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
4787         into the #ifdef block where it's used.
4788
4789         * lib/rename-dest-slash.c: New file.
4790
4791 2006-09-14  Bruno Haible  <bruno@clisp.org>
4792
4793         * lib/allocsa.c: Include <config.h> unconditionally.
4794         * lib/asnprintf.c: Likewise.
4795         * lib/asprintf.c: Likewise.
4796         * lib/c-strcasecmp.c: Likewise.
4797         * lib/c-strcasestr.c: Likewise.
4798         * lib/c-strncasecmp.c: Likewise.
4799         * lib/c-strstr.c: Likewise.
4800         * lib/classpath.c: Likewise.
4801         * lib/clean-temp.c: Likewise.
4802         * lib/concatpath.c: Likewise.
4803         * lib/copy-file.c: Likewise.
4804         * lib/csharpcomp.c: Likewise.
4805         * lib/csharpexec.c: Likewise.
4806         * lib/execute.c: Likewise.
4807         * lib/fatal-signal.c: Likewise.
4808         * lib/findprog.c: Likewise.
4809         * lib/fwriteerror.c: Likewise.
4810         * lib/gl_array_list.c: Likewise.
4811         * lib/gl_array_oset.c: Likewise.
4812         * lib/gl_avltree_list.c: Likewise.
4813         * lib/gl_avltree_oset.c: Likewise.
4814         * lib/gl_avltreehash_list.c: Likewise.
4815         * lib/gl_carray_list.c: Likewise.
4816         * lib/gl_linked_list.c: Likewise.
4817         * lib/gl_linkedhash_list.c: Likewise.
4818         * lib/gl_list.c: Likewise.
4819         * lib/gl_oset.c: Likewise.
4820         * lib/gl_rbtree_list.c: Likewise.
4821         * lib/gl_rbtree_oset.c: Likewise.
4822         * lib/gl_rbtreehash_list.c: Likewise.
4823         * lib/imaxabs.c: Likewise.
4824         * lib/imaxdiv.c: Likewise.
4825         * lib/javacomp.c: Likewise.
4826         * lib/javaexec.c: Likewise.
4827         * lib/javaversion.c: Likewise.
4828         * lib/linebreak.c: Likewise.
4829         * lib/localcharset.c: Likewise.
4830         * lib/lock.c: Likewise.
4831         * lib/mbchar.c: Likewise.
4832         * lib/mbswidth.c: Likewise.
4833         * lib/mkdtemp.c: Likewise.
4834         * lib/pipe.c: Likewise.
4835         * lib/printf-args.c: Likewise.
4836         * lib/printf-parse.c: Likewise.
4837         * lib/progname.c: Likewise.
4838         * lib/progreloc.c: Likewise.
4839         * lib/readlink.c: Likewise.
4840         * lib/sh-quote.c: Likewise.
4841         * lib/stpcpy.c: Likewise.
4842         * lib/stpncpy.c: Likewise.
4843         * lib/strcasecmp.c: Likewise.
4844         * lib/strcasestr.c: Likewise.
4845         * lib/strcspn.c: Likewise.
4846         * lib/striconv.c: Likewise.
4847         * lib/strncasecmp.c: Likewise.
4848         * lib/strnlen1.c: Likewise.
4849         * lib/strstr.c: Likewise.
4850         * lib/strtok_r.c: Likewise.
4851         * lib/tls.c: Likewise.
4852         * lib/tmpdir.c: Likewise.
4853         * lib/unicodeio.c: Likewise.
4854         * lib/unsetenv.c: Likewise.
4855         * lib/vasnprintf.c: Likewise.
4856         * lib/vasprintf.c: Likewise.
4857         * lib/wait-process.c: Likewise.
4858         * lib/xallocsa.c: Likewise.
4859         * lib/xsetenv.c: Likewise.
4860         * lib/xstriconv.c: Likewise.
4861
4862 2006-09-13  Simon Josefsson  <jas@extundo.com>
4863
4864         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
4865         that internally, suggested by Ralf Wildenhues
4866         <Ralf.Wildenhues@gmx.de>.
4867
4868 2006-09-13  Simon Josefsson  <jas@extundo.com>
4869
4870         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
4871         @LIBOBJS@.
4872         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4873
4874 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
4875
4876         * lib/_fpending.c: Include <config.h> unconditionally, since we no
4877         longer worry about uses that don't define HAVE_CONFIG_H.
4878         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
4879         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
4880         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
4881         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
4882         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
4883         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
4884         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
4885         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
4886         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
4887         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
4888         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
4889         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
4890         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
4891         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
4892         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
4893         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
4894         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
4895         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
4896         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
4897         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
4898         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
4899         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
4900         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
4901         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
4902         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
4903         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
4904         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
4905         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
4906         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
4907         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
4908         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
4909         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
4910         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
4911         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
4912         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
4913         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
4914         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
4915         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
4916         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
4917         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
4918         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
4919         Likewise.
4920
4921 2006-09-13  Eric Blake  <ebb9@byu.net>
4922
4923         * lib/getopt.c: Fix typo in last commit.
4924
4925 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
4926
4927         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
4928         dgettext.
4929
4930 2006-09-12  Jim Meyering  <jim@meyering.net>
4931
4932         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
4933         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
4934         Reported by Nelson H. F. Beebe.
4935
4936 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
4937
4938         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
4939         program_invocation_name and program_invocation_short_name are
4940         initialized.
4941         * lib/argp-namefrob.h: Move declarations of program_invocation_name
4942         and program_invocation_short_name to argp.h, so they are visible
4943         to user programs.
4944         * lib/argp.h: Likewise
4945
4946 2006-09-10  Bruno Haible  <bruno@clisp.org>
4947
4948         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4949         m4/inttypes_h.m4, m4/uintmax_t.m4.
4950
4951 2006-09-10  Bruno Haible  <bruno@clisp.org>
4952
4953         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
4954         gl_AC_TYPE_UINTMAX_T.
4955
4956 2006-09-10  Bruno Haible  <bruno@clisp.org>
4957
4958         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
4959
4960 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
4961
4962         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
4963         convention.  Text proposed by Bruno Haible.
4964         (struct argp_option): Document the use of N_() wrappers.
4965
4966         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
4967         '\v', and translate the two parts separately, instead of feeding
4968         the whole string to gettext.  This allows to exclude
4969         '\v' from the strings visible to the translator by writing doc
4970         strings as N_("..") "\v" N_("..").
4971
4972 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
4973
4974         * config/srclist.txt: Undo latest change; the bug was fixed.
4975
4976 2006-09-09  Bruno Haible  <bruno@clisp.org>
4977
4978         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
4979         assignments if building a library without libtool.
4980         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
4981         in func_emit_lib_Makefile_am.
4982         (func_import): When building a static library libfoo.a, arrange to
4983         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
4984         (func_create_testdir): Likewise.
4985         * modules/gc (configure.ac, Makefile.am): If building statically,
4986         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
4987         * modules/iconvme (configure.ac, Makefile.am): Likewise.
4988         * modules/striconv (configure.ac, Makefile.am): Likewise.
4989         Based on a suggestion by Ralf Wildenhues.
4990
4991 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4992
4993         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
4994         Check for unistd.h too, since Autoconf doesn't assume POSIX.
4995         Also:
4996
4997         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4998         Add year_2050_test to catch glibc bug 2821
4999         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
5000
5001         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5002         Prefer #ifdef to #if.
5003
5004         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
5005         Return from 'main' instead of calling 'exit'.
5006
5007 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
5008
5009         * lib/mktime.c (guess_time_tm): Fix bug where mktime
5010         returned the maximum time_t value rather than (time_t) -1.
5011         Problem originally reported by William Bardwell
5012         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
5013
5014         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
5015         Moved to here ...
5016         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
5017         ... from here.
5018
5019 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
5020
5021         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
5022         2821 is fixed.
5023
5024 2006-09-08  Jim Meyering  <jim@meyering.net>
5025
5026         Don't make generated files read-only.  That would bother too many
5027         people.  However, do retain the ability to work when targets are
5028         read-only: remove the destination and temporary files before writing
5029         them (when generated via sed or echo), or by using the -f option for
5030         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
5031         * modules/alloca-opt, modules/argz, modules/arpa_inet:
5032         * modules/byteswap, modules/configmake, modules/fcntl:
5033         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
5034         * modules/localcharset, modules/netinet_in, modules/poll:
5035         * modules/stdbool, modules/stdint, modules/sys_select:
5036         * modules/sys_socket, modules/sys_stat, modules/sysexits:
5037
5038 2006-09-08  Jim Meyering  <jim@meyering.net>
5039
5040         Avoid new build failure on FreeBSD 6.0.
5041         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
5042         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
5043         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
5044
5045 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5046
5047         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
5048
5049 2006-09-07  Jim Meyering  <jim@meyering.net>
5050
5051         Fix global typo in last change: use chmod u-w, not chmod u-x.
5052         Spotted by Paul Eggert and Bruce Korb.
5053         * modules/alloca-opt, modules/argz, modules/arpa_inet:
5054         * modules/byteswap, modules/configmake, modules/fcntl:
5055         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
5056         * modules/localcharset, modules/netinet_in, modules/poll:
5057         * modules/stdbool, modules/stdint, modules/sys_select:
5058         * modules/sys_socket, modules/sys_stat, modules/sysexits:
5059
5060 2006-09-06  Jim Meyering  <jim@meyering.net>
5061
5062         Make generated files be read-only.
5063         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
5064         Ensure that each generated file is now read-only.
5065         * modules/argz: Likewise.
5066         * modules/arpa_inet: Likewise.
5067         * modules/byteswap: Likewise.
5068         * modules/configmake: Likewise.
5069         * modules/fcntl: Likewise.
5070         * modules/fnmatch: Likewise.
5071         * modules/getopt: Likewise.
5072         * modules/glob: Likewise.
5073         * modules/inttypes: Likewise.
5074         * modules/netinet_in: Likewise.
5075         * modules/poll: Likewise.
5076         * modules/stdbool: Likewise.
5077         * modules/stdint: Likewise.
5078         * modules/sys_select: Likewise.
5079         * modules/sys_socket: Likewise.
5080         * modules/sys_stat: Likewise.
5081         * modules/sysexits: Likewise.
5082         * modules/localcharset: Same as above, but continue using temporary
5083         file named "t-$@" (why different?) rather than the "$@-t" used
5084         everywhere else.
5085
5086         * modules/sysexits (Makefile.am): Replace literal occurrences
5087         of "sysexit.h" more readable, and more consistent, "$@".
5088
5089 2006-09-06  Bruno Haible  <bruno@clisp.org>
5090
5091         * modules/striconv: New file.
5092         * modules/xstriconv: New file.
5093         * MODULES.html.sh (Internationalization functions): Add striconv,
5094         xstriconv.
5095
5096 2006-09-06  Bruno Haible  <bruno@clisp.org>
5097
5098         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
5099         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
5100         not using libtool correctly.
5101
5102 2006-09-06  Bruno Haible  <bruno@clisp.org>
5103
5104         * lib/striconv.h: New file.
5105         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
5106         iconvstring.c.
5107         * lib/xstriconv.h: New file.
5108         * lib/xstriconv.c: New file.
5109
5110 2006-09-06  Bruno Haible  <bruno@clisp.org>
5111
5112         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
5113         lib_..._LDFLAGS.
5114
5115 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5116
5117         * lib/argz_.h: Sync from Libtool.
5118
5119         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
5120                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
5121
5122         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
5123
5124 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
5125
5126         * modules/trim: New file.
5127
5128 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
5129
5130         * lib/trim.h: New file.
5131         * lib/trim.c: New file.
5132
5133 2006-09-05  Bruno Haible  <bruno@clisp.org>
5134
5135         * MODULES.html.sh (String handling): Add trim.
5136
5137 2006-09-04  Karl Berry  <karl@gnu.org>
5138
5139         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
5140         until next release.
5141
5142 2006-09-03  Bruno Haible  <bruno@clisp.org>
5143
5144         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
5145         correctly.
5146
5147 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
5148
5149         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
5150         not gl_GETLOADAVG.  Omit unneeded semicolons.
5151         Problems reported by Ralf Wildenhues in
5152         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
5153         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
5154         at the end, which is the usual gnulib style.
5155
5156         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
5157         of doing all the work ourselves.
5158         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
5159         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
5160
5161 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
5162
5163         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
5164         Problem reported by Ralf Wildenhues in
5165         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
5166
5167         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
5168         HAVE_STRUCT_STATFS_F_FSTYPENAME.
5169
5170 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
5171
5172         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
5173         yesterday's patch by changing test -n to test -z.
5174
5175 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
5176
5177         * modules/getloadavg (Files): Add m4/getloadavg.m4.
5178         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
5179         the former is now obsolescent.
5180
5181         * modules/chdir-long (Depends-on): Add fcntl.
5182
5183 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
5184
5185         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
5186         obsolescent, and programs should use gnulib instead.
5187         * m4/getloadavg.m4: New file, with contents taken from Autoconf
5188         but with prefixes changed.
5189
5190 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
5191
5192         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
5193         or stdbool.h, because they might not exist while configuring.
5194
5195         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
5196         Don't include unistd.h or limits.h; not needed, since chdir-long.h
5197         does that for us.
5198         (O_DIRECTORY): Remove.
5199
5200 2006-08-31  Eric Blake  <ebb9@byu.net>
5201
5202         * gnulib-tool: Don't let emacs change spaces to TAB.
5203
5204 2006-08-31  Bruno Haible  <bruno@clisp.org>
5205
5206         * gnulib-tool: When calling func_import more than once, do it in a
5207         subshell.
5208         Reported by Eric Blake <ebb9@byu.net>.
5209
5210 2006-08-31  Bruno Haible  <bruno@clisp.org>
5211
5212         * gnulib-tool (nl): Remove variable.
5213         (sed_transform_lib_file): Use more robust test for config-h module.
5214         (func_import): Fix typo in 2006-08-25 patch.
5215
5216 2006-08-31  Bruno Haible  <bruno@clisp.org>
5217
5218         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
5219         specified, augment Makefile.am variables instead of assigning them.
5220
5221 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
5222
5223         Work around a bug in both the Linux and SunOS 64-bit kernels:
5224         nanosleep mishandles sleeps for longer than 2**31 seconds.
5225         Problem reported by Frank v Waveren in
5226         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
5227         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
5228         Check for nanosleep bug.
5229         (LIB_NANOSLEEP): Append clock_gettime library if needed.
5230
5231 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
5232
5233         Work around a bug in both the Linux and SunOS 64-bit kernels:
5234         nanosleep mishandles sleeps for longer than 2**31 seconds.
5235         Problem reported by Frank v Waveren in
5236         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
5237         * lib/nanosleep.c (BILLION): New constant.
5238         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
5239         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
5240         implementation.
5241
5242 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
5243
5244         * modules/nanosleep (Depends-on): Add gettime.
5245
5246 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
5247         and Simon Josefsson  <jas@extundo.com>
5248         and Oskar Liljeblad  <oskar@osk.mine.nu>
5249
5250         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
5251         * gnulib-tool (func_import): New license type 'unmodifiable license
5252         text'.
5253         * modules/fdl: Use it.  Longer description.
5254         * module/gpl, module/lgpl: New files.
5255
5256 2006-08-30  Jim Meyering  <jim@meyering.net>
5257
5258         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
5259         shadowing the parameter.
5260
5261 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5262
5263         Sync from Libtool:
5264
5265         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5266
5267         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
5268         sharing with gnulib.  Report by Eric Blake.
5269
5270 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
5271
5272         * modules/isapipe: New file.
5273         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
5274
5275 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
5276
5277         * modules/configmake (Makefile.am): Add a comment, and omit
5278         the CONFIGMAKE_ prefix from generated macro names.  Suggested
5279         by Bruno Haible.
5280
5281 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
5282
5283         * m4/isapipe.m4: New file.
5284
5285 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
5286
5287         * lib/isapipe.c, lib/isapipe.h: New files.
5288
5289 2006-08-29  Jim Meyering  <jim@meyering.net>
5290
5291         * modules/configmake (Makefile.am): Make configmake.h depend on
5292         Makefile.  Otherwise, a stale configmake.h could hang around.
5293
5294 2006-08-29  Eric Blake  <ebb9@byu.net>
5295
5296         * lib/error.c (error_at_line, print_errno_message): Match libc, after
5297         resolution of upstream bug 3044.
5298
5299 2006-08-29  Bruno Haible  <bruno@clisp.org>
5300
5301         * modules/localcharset (Depends-on): Add configmake.
5302         (Makefile.am): Remove setting of LIBDIR through DEFS.
5303
5304 2006-08-29  Bruno Haible  <bruno@clisp.org>
5305
5306         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
5307         defined.
5308
5309 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5310
5311         * modules/fcntl: New file.
5312         * modules/chdir-safer (Depends-on): Add fcntl.
5313         * modules/fts: Likewise.
5314         * modules/mkdir-p: Likewise.
5315
5316         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
5317         This undoes the most recent change, since we're now addressing the
5318         problem in a different way.
5319
5320         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
5321         into output, since the output might be called Makefile.am even
5322         if $makefile_name is something different.
5323         (func_import): Use $makefile_am rather than
5324         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
5325         empty.
5326
5327         * modules/inttypes (Files): Add m4/inttypes-h.m4.
5328
5329 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5330
5331         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
5332         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
5333         recent change to stdint.m4, since we're now addressing the problem in a
5334         different way.
5335
5336 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5337
5338         * m4/fcntl_h.m4: New file.
5339
5340 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5341
5342         * lib/fcntl_.h: New file.
5343         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
5344         the fcntl module.
5345         * lib/dirchownmod.c: Likewise.
5346         * lib/fts.c: Likewise.
5347
5348         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
5349         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
5350         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
5351         just before including <inttypes.h>, to avoid circular inclusion.
5352
5353 2006-08-28  Jim Meyering  <jim@meyering.net>
5354
5355         * doc/visibility.texi: Actually read and correct the grammar of the
5356         sentence affected by yesterday's change.
5357
5358 2006-08-28  Eric Blake  <ebb9@byu.net>
5359
5360         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
5361         needs wrapper.
5362
5363 2006-08-28  Eric Blake  <ebb9@byu.net>
5364
5365         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
5366
5367 2006-08-28  Eric Blake  <ebb9@byu.net>
5368
5369         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
5370
5371 2006-08-28  Bruno Haible  <bruno@clisp.org>
5372
5373         * modules/c-strstr: New file, from GNU gettext.
5374         * MODULES.html.sh (String handling): Add c-strstr.
5375
5376 2006-08-28  Bruno Haible  <bruno@clisp.org>
5377
5378         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
5379         macros.
5380         Reported by Eric Blake.
5381
5382 2006-08-28  Bruno Haible  <bruno@clisp.org>
5383
5384         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
5385         (VASNPRINTF): Return a string of length > INT_MAX without failing.
5386         * lib/vasprintf.c: Include errno.h, limits.h.
5387         (EOVERFLOW): New fallback definition.
5388         (vasprintf): Test here whether the string length is > INT_MAX.
5389         * lib/vsnprintf.c: Include errno.h, limits.h.
5390         (EOVERFLOW): New fallback definition.
5391         (vsnprintf): Fix bug when generated string was too long for the buffer.
5392         Test here whether the string length is > INT_MAX.
5393
5394 2006-08-28  Bruno Haible  <bruno@clisp.org>
5395
5396         * lib/inttypes_.h (SCNX*): Remove definitions.
5397         Reported by Eric Blake.
5398
5399 2006-08-28  Bruno Haible  <bruno@clisp.org>
5400
5401         * lib/c-strstr.h: New file, from GNU gettext.
5402         * lib/c-strstr.c: New file, from GNU gettext.
5403
5404 2006-08-28  Bruno Haible  <bruno@clisp.org>
5405
5406         * gnulib-tool: Reorder some statements.
5407
5408 2006-08-28  Bruno Haible  <bruno@clisp.org>
5409
5410         * gnulib-tool: New option --makefile-name.
5411         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
5412         $makefile_name.
5413         (func_import): Write $makefile_name to the cache file, and read it from
5414         there unless explicitly specified. Use $makefile_name as file name
5415         instead of Makefile.am. Adjust the recommendations accordingly.
5416
5417 2006-08-28  Bruno Haible  <bruno@clisp.org>
5418
5419         * gnulib-tool (func_verify_module): Check against misapplying patch.
5420
5421 2006-08-28  Bruno Haible  <bruno@clisp.org>
5422
5423         * gnulib-tool (func_relativize, func_relconcat): New functions.
5424         Give an error if --local-dir is given with --update.
5425         Remove trailing slashes from $local_gnulib_dir.
5426         (func_import): Store the relativized $local_gnulib_dir in
5427         gnulib-cache.m4, and read it from there if not specified explicitly.
5428
5429 2006-08-28  Bruno Haible  <bruno@clisp.org>
5430
5431         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
5432         is the current directory. Respect also $local_gnulib_dir.
5433
5434 2006-08-28  Bruno Haible  <bruno@clisp.org>
5435             Simon Josefsson  <jas@extundo.com>
5436
5437         BeOS portability.
5438         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
5439
5440 2006-08-27  Jim Meyering  <jim@meyering.net>
5441
5442         * doc/visibility.texi: Remove duplicate word: "pointer".
5443
5444 2006-08-26  Bruno Haible  <bruno@clisp.org>
5445
5446         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
5447         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
5448         (Makefile.am): Create inttypes.h from inttypes_.h.
5449         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
5450
5451         * modules/imaxabs: New file.
5452
5453         * modules/imaxdiv: New file.
5454
5455 2006-08-26  Bruno Haible  <bruno@clisp.org>
5456
5457         * m4/inttypes.m4: New file.
5458         * m4/_inttypes_h.m4: Remove file.
5459         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
5460         PRI_MACROS_BROKEN.
5461         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
5462
5463         * m4/imaxabs.m4: New file.
5464
5465         * m4/imaxdiv.m4: New file.
5466
5467 2006-08-26  Bruno Haible  <bruno@clisp.org>
5468
5469         * lib/inttypes_.h: New file.
5470         * lib/inttypes.h: Remove file.
5471         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
5472
5473         * lib/imaxabs.c: New file.
5474
5475         * lib/imaxdiv.c: New file.
5476
5477 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
5478
5479         New config-h module, so that "make" output needn't be cluttered
5480         by -DHAVE_CONFIG_H.
5481         * MODULES.html.sh (Support for building libraries and executables):
5482         Add config-h.
5483         * modules/config-h: New file.
5484         * gnulib-tool (nl, sed_transform_lib_file): New vars.
5485         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
5486         the config-h module is used.
5487
5488         New configmake module, so that "make" output needn't be cluttered
5489         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
5490         * MODULES.html.sh (Support for building libraries and executables):
5491         Add configmake.
5492         * modules/configmake: New file.
5493
5494 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
5495
5496         * m4/config-h.m4: New file.
5497
5498 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
5499
5500         * config/srclist.txt: Add elisp-comp.
5501
5502 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
5503
5504         * MODULES.html.sh (Support for building libraries and executables):
5505         Add elisp-comp.
5506         * build-aux/elisp-comp: New file.
5507         * modules/elisp-comp: New file.
5508
5509 2006-08-24  Bruno Haible  <bruno@clisp.org>
5510
5511         * gnulib-tool (func_create_testdir): Use non-default values of
5512         sourcebase and m4base.
5513
5514 2006-08-24  Bruno Haible  <bruno@clisp.org>
5515
5516         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
5517         HTML structure.
5518
5519 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
5520
5521         * modules/openat (Depends-on): Add lchown.
5522
5523 2006-08-23  Bruno Haible  <bruno@clisp.org>
5524
5525         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
5526         of gl_LOCK_EARLY instead of gl_LOCK.
5527
5528 2006-08-23  Bruno Haible  <bruno@clisp.org>
5529
5530         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
5531         on OSF/1 to no.
5532         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
5533
5534 2006-08-23  Bruno Haible  <bruno@clisp.org>
5535
5536         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
5537         as unusable.
5538
5539         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
5540         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
5541         (gl_LOCK): New macro.
5542
5543 2006-08-22  Simon Josefsson  <jas@extundo.com>
5544
5545         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
5546         to md5 module.
5547
5548 2006-08-22  Simon Josefsson  <jas@extundo.com>
5549
5550         * MODULES.html.sh: Add "Support for maintaining and release
5551         projects".
5552
5553         * build-aux/gnupload: New file, from coreutils.
5554
5555 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5556
5557         Avoid the need for AC_LIBSOURCES in m4 macros.
5558         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
5559         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
5560         * modules/check-version (EXTRA_DIST): Add check-version.h.
5561         * modules/crc (EXTRA_DIST): Add crc.h.
5562         * modules/des (EXTRA_DIST): Add des.h.
5563         * modules/gc (EXTRA_DIST): Add gc.h.
5564         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
5565         * modules/getline (EXTRA_DIST): Add getline.h.
5566         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
5567         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
5568         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
5569         * modules/md2 (EXTRA_DIST): Add md2.h.
5570         * modules/md4 (EXTRA_DIST): Add md4.h.
5571         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
5572         * modules/read-file (EXTRA_DIST): Add read-file.h.
5573         * modules/readline (EXTRA_DIST): Add readline.h.
5574         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
5575         rijndael-api-fst.h.
5576
5577 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5578
5579         * m4/rijndael.m4 (gl_ARCFOUR):
5580         * m4/arctwo.m4 (gl_ARCTWO):
5581         * m4/check-version.m4 (gl_CHECK_VERSION):
5582         * m4/crc.m4 (gl_CRC):
5583         * m4/des.m4 (gl_DES):
5584         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
5585         * m4/gc.m4 (gl_GC):
5586         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
5587         * m4/getline.m4 (gl_FUNC_GETLINE):
5588         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
5589         * m4/hmac-md5.m4 (gl_HMAC_MD5):
5590         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
5591         * m4/md2.m4 (gl_MD2):
5592         * m4/md4.m4 (gl_MD4):
5593         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
5594         * m4/read-file.m4 (gl_FUNC_READ_FILE):
5595         * m4/readline.m4 (gl_FUNC_READLINE):
5596         * m4/rijndael.m4 (gl_RIJNDAEL):
5597         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
5598         to get the necessary .h files and whatnot.
5599
5600 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5601
5602         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
5603         gnulib rather than the other way around.
5604         * config/srclistvars.sh (COREUTILS): Remove.
5605
5606 2006-08-22  Jim Meyering  <jim@meyering.net>
5607
5608         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
5609
5610         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
5611
5612 2006-08-22  Eric Blake  <ebb9@byu.net>
5613
5614         * modules/regexprops-generic: New file.
5615         * MODULES.html.sh (Support for building documentation): List it.
5616
5617 2006-08-22  Eric Blake  <ebb9@byu.net>
5618
5619         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
5620         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
5621         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
5622         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
5623
5624 2006-08-22  Bruno Haible  <bruno@clisp.org>
5625
5626         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
5627         and lib_LTLIBRARIES like the other lib_* variables.
5628
5629 2006-08-22  Bruno Haible  <bruno@clisp.org>
5630
5631         * build-aux/x-to-1.in: New file, from GNU gettext.
5632
5633 2006-08-22  Bruno Haible  <bruno@clisp.org>
5634
5635         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
5636         <utmpx.h> exists.
5637
5638 2006-08-22  Bruno Haible  <bruno@clisp.org>
5639
5640         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
5641         <utmpx.h> exists.
5642
5643 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5644
5645         BeOS portability.
5646         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
5647         exist.
5648         Problem reported by Bruno Haible.
5649
5650 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5651
5652         Avoid the need for AC_LIBSOURCES in m4 macros.
5653         * modules/acl (EXTRA_DIST): Add acl.h.
5654         * modules/argmatch (Files): Add m4/argmatch.m4.
5655         (configure.ac): Add gl_ARGMATCH.
5656         (EXTRA_DIST): Renamed from lib_SOURCES, for
5657         consistency with the other modules.  Remove argmatch.c.
5658         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
5659         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
5660         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
5661         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
5662         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
5663         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
5664         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
5665         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
5666         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
5667         * modules/closeout (EXTRA_DIST): Add closeout.h.
5668         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
5669         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
5670         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
5671         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
5672         dirname.h; remove basename.c and stripslash.c.
5673         * modules/exclude (EXTRA_DIST): Add exclude.h.
5674         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
5675         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
5676         * modules/file-type (EXTRA_DIST): Add file-type.h.
5677         * modules/filemode (EXTRA_DIST): Add filemode.h.
5678         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
5679         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
5680         * modules/fpending (EXTRA_DIST): Add __fpending.h.
5681         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
5682         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
5683         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
5684         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
5685         * modules/getdate (EXTRA_DIST): Add getdate.c.
5686         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
5687         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
5688         * modules/getpass (EXTRA_DIST): Add getpass.h.
5689         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
5690         * modules/group-member (EXTRA_DIST): Add group-member.h.
5691         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
5692         * modules/hash (EXTRA_DIST): Add hash.h.
5693         * modules/human (EXTRA_DIST): Add human.h.
5694         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
5695         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
5696         * modules/lchown (EXTRA_DIST): Add lchown.h.
5697         * modules/long-options (EXTRA_DIST): Add long-options.h.
5698         * modules/lstat (EXTRA_DIST): Add lstat.h.
5699         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
5700         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
5701         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
5702         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
5703         * modules/memxor (EXTRA_DIST): Add memxor.h.
5704         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
5705         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
5706         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
5707         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
5708         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
5709         * modules/physmem (EXTRA_DIST): Add physmem.h.
5710         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
5711         * modules/posixver (EXTRA_DIST): Add posixver.h.
5712         * modules/quote (EXTRA_DIST): Add quote.h.
5713         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
5714         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
5715         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
5716         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
5717         regex_internal.h regexec.c.
5718         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
5719         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
5720         * modules/same (EXTRA_DIST): Add same.h.
5721         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
5722         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
5723         * modules/savedir (EXTRA_DIST): Add savedir.h.
5724         * modules/sha1 (EXTRA_DIST): Add sha1.h.
5725         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
5726         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
5727         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
5728         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
5729         * modules/strdup (EXTRA_DIST): Add strdup.h.
5730         * modules/strftime (EXTRA_DIST): Add strftime.h.
5731         * modules/strndup (EXTRA_DIST): Add strndup.h.
5732         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
5733         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
5734         * modules/time_r (EXTRA_DIST): Add time_r.h.
5735         * modules/timespec (EXTRA_DIST): Add timespec.h.
5736         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
5737         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
5738         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
5739         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
5740         * modules/userspec (EXTRA_DIST): Add userspec.h.
5741         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
5742         * modules/utimens (EXTRA_DIST): Add utimens.h.
5743         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
5744         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
5745         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
5746         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
5747         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
5748         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
5749         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
5750         * modules/yesno (EXTRA_DIST): Add yesno.h.
5751
5752 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5753
5754         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
5755
5756         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
5757         * m4/dev-ino.m4, same-inode.m4: Remove.
5758
5759         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
5760         * m4/acl.m4 (AC_FUNC_ACL):
5761         * m4/backupfile.m4 (gl_BACKUPFILE):
5762         * m4/c-strtod.m4 (gl_C99_STRTOLD):
5763         * m4/canon-host.m4 (gl_CANON_HOST):
5764         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
5765         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
5766         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
5767         * m4/cloexec.m4 (gl_CLOEXEC):
5768         * m4/close-stream.m4 (gl_CLOSE_STREAM):
5769         * m4/closeout.m4 (gl_CLOSEOUT):
5770         * m4/dirfd.m4 (gl_FUNC_DIRFD):
5771         * m4/dirname.m4 (gl_DIRNAME):
5772         * m4/exclude.m4 (gl_EXCLUDE):
5773         * m4/exitfail.m4 (gl_EXITFAIL):
5774         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
5775         * m4/file-type.m4 (gl_FILE_TYPE):
5776         * m4/filemode.m4 (gl_FILEMODE):
5777         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
5778         * m4/fpending.m4 (gl_FUNC_FPENDING):
5779         * m4/fprintftime.m4 (gl_FPRINTFTIME):
5780         * m4/fts.m4 (gl_FUNC_FTS):
5781         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
5782         * m4/getdate.m4 (gl_GETDATE):
5783         * m4/gethrxtime.m4 (gl_GETHRXTIME):
5784         * m4/getpagesize.m4 (gl_GETPAGESIZE):
5785         * m4/getpass.m4 (gl_FUNC_GETPASS):
5786         * m4/gettime.m4 (gl_GETTIME):
5787         * m4/getugroups.m4 (gl_GETUGROUPS):
5788         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
5789         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
5790         * m4/hard-locale.m4 (gl_HARD_LOCALE):
5791         * m4/hash.m4 (gl_HASH):
5792         * m4/idcache.m4 (gl_IDCACHE):
5793         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
5794         * m4/lchown.m4 (gl_FUNC_LCHOWN):
5795         * m4/long-options.m4 (gl_LONG_OPTIONS):
5796         * m4/lstat.m4 (gl_FUNC_LSTAT):
5797         * m4/md5.m4 (gl_MD5):
5798         * m4/memcasecmp.m4 (gl_MEMCASECMP):
5799         * m4/memcoll.m4 (gl_MEMCOLL):
5800         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
5801         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
5802         * m4/memxor.m4 (gl_MEMXOR):
5803         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
5804         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
5805         * m4/modechange.m4 (gl_MODECHANGE):
5806         * m4/mountlist.m4 (gl_MOUNTLIST):
5807         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5808         * m4/openat.m4 (gl_FUNC_OPENAT):
5809         * m4/pathmax.m4 (gl_PATHMAX):
5810         * m4/physmem.m4 (gl_PHYSMEM):
5811         * m4/posixtm.m4 (gl_POSIXTM):
5812         * m4/posixver.m4 (gl_POSIXVER):
5813         * m4/quote.m4 (gl_QUOTE):
5814         * m4/quotearg.m4 (gl_QUOTEARG):
5815         * m4/readtokens.m4 (gl_READTOKENS):
5816         * m4/readutmp.m4 (gl_READUTMP):
5817         * m4/regex.m4 (gl_REGEX):
5818         * m4/safe-read.m4 (gl_SAFE_READ):
5819         * m4/safe-write.m4 (gl_SAFE_WRITE):
5820         * m4/same.m4 (gl_SAME):
5821         * m4/save-cwd.m4 (gl_SAVE_CWD):
5822         * m4/savedir.m4 (gl_SAVEDIR):
5823         * m4/settime.m4 (gl_SETTIME):
5824         * m4/sha1.m4 (gl_SHA1):
5825         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
5826         * m4/stat-macros.m4 (gl_STAT_MACROS):
5827         * m4/stat-time.m4 (gl_STAT_TIME):
5828         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
5829         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
5830         * m4/strdup.m4 (gl_FUNC_STRDUP):
5831         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
5832         * m4/strndup.m4 (gl_FUNC_STRNDUP):
5833         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
5834         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
5835         * m4/time_r.m4 (gl_TIME_R):
5836         * m4/timespec.m4 (gl_TIMESPEC):
5837         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
5838         * m4/unlinkdir.m4 (gl_UNLINKDIR):
5839         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
5840         * m4/userspec.m4 (gl_USERSPEC):
5841         * m4/utimecmp.m4 (gl_UTIMECMP):
5842         * m4/utimens.m4 (gl_UTIMENS):
5843         * m4/xalloc.m4 (gl_XALLOC):
5844         * m4/xgetcwd.m4 (gl_XGETCWD):
5845         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
5846         * m4/xreadlink.m4 (gl_XREADLINK):
5847         * m4/xstrtod.m4 (gl_XSTRTOD):
5848         * m4/yesno.m4 (gl_YESNO):
5849         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
5850         to get the necessary .h files and whatnot.
5851
5852 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
5853             Bruno Haible  <bruno@clisp.org>
5854
5855         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
5856         /bin/sh understanding of '!' conditional negation.
5857
5858 2006-08-21  Jim Meyering  <jim@meyering.net>
5859
5860         * modules/openat (Depends-on): Really alphabetize.
5861
5862         * modules/acl (Depends-on): Add error and quote.
5863
5864         * check-module (find_included_lib_files): Add at-func.c to the
5865         ok-to-include-more-than-once white list.
5866
5867         * modules/openat (Depends-on): Add lstat.  Alphabetize.
5868
5869 2006-08-21  Bruno Haible  <bruno@clisp.org>
5870
5871         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5872         Emit a pkgdata_DATA variable only if some snippets add contents to it.
5873         Reported by Martin Lambers <marlam@marlam.de>.
5874
5875 2006-08-21  Bruno Haible  <bruno@clisp.org>
5876
5877         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
5878         specify an installation location, don't emit a noinst_LIBRARIES or
5879         noinst_LTLIBRARIES assignment.
5880
5881 2006-08-21  Bruno Haible  <bruno@clisp.org>
5882
5883         BeOS portability.
5884         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
5885         BeOS has mbrtowc() but no <wctype.h>.
5886
5887 2006-08-21  Bruno Haible  <bruno@clisp.org>
5888
5889         BeOS portability.
5890         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
5891         exist.
5892
5893 2006-08-21  Bruno Haible  <bruno@clisp.org>
5894
5895         BeOS portability.
5896         * lib/mbchar.h: Include <wctype.h> only if it exists.
5897
5898 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
5899
5900         Remove files that are no longer needed by their respective modules.
5901         * m4/obstack.m4: Remove.
5902         * m4/strerror_r.m4: Remove.
5903         * m4/uint32_t.m4: Remove.
5904         * m4/uintptr_t.m4: Remove.
5905         * m4/ullong_max.m4: Remove.
5906         * m4/xstrtoimax.m4: Remove.
5907         * m4/xstrtoumax.m4: Remove.
5908
5909         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
5910         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
5911         dependencies now capture this.
5912
5913         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
5914         Do not use AC_LIBSOURCES, since gnulib modules now do this.
5915         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
5916         * m4/human.m4 (gl_HUMAN): Likewise.
5917         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
5918         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
5919
5920         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
5921
5922         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
5923         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
5924         stdint.
5925         * m4/human.m4 (gl_HUMAN): Likewise.
5926         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
5927         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
5928         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
5929         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
5930         * m4/xstrtol (gl_XSTRTOL): Likewise.
5931
5932         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
5933         AC_TYPE_LONG_LONG_INT.
5934         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
5935         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
5936         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
5937         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
5938
5939         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
5940         on stdbool.
5941
5942         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
5943         (gl_PREREQ_XSTRTOUL): Remove.
5944
5945         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
5946
5947         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
5948         mode.
5949
5950 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
5951
5952         Add and change modules to make it easier for coreutils to use
5953         gnulib-tool.
5954         * modules/backupfile (Files): Remove m4/d-ino.m4.
5955         (Depends-on): Add d-ino.
5956         * modules/cycle-check (Depends-on): Add stdint.
5957         (lib_SOURCES): Add cycle-check.h.
5958         * modules/d-ino: New module.
5959         * modules/d-type: New module.
5960         * modules/error (Files): Remove m4/strerror_r.m4.
5961         * modules/filemode (Files): Add m4/st_dm_mode.m4.
5962         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
5963         m4/inttypes_h.m4, m4/uintmax_t.m4.
5964         (Depends-on): Add stdint.
5965         (lib_SOURCES): Add fsusage.h.
5966         * modules/getcwd (Files): Remove d-ino.m4.
5967         (Depends-on): Add d-ino.
5968         * modules/getndelim2 (Depends-on): Add stdint.
5969         * modules/glob (Files): Remove m4/d-type.m4.
5970         (Depends-on): Add d-type.
5971         * modules/host-os: New module.
5972         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
5973         m4/inttypes_h.m4, m4/uintmax_t.m4.
5974         * Depends-on: Add stdint.
5975         (lib_SOURCES): Add human.h.
5976         * modules/inttostr (Files): Remove m4/intmax_t.m4,
5977         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
5978         m4/uintmax_t.m4, m4/ulonglong.m4.
5979         (Depends-on): Add stdint.
5980         (EXTRA_DIST): Add inttostr.h.
5981         * modules/lchmod: New module.
5982         * modules/link-follow: New module.
5983         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
5984         (Depends-on): Add lchmod.
5985         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
5986         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
5987         (Depends-on): Add stdint.
5988         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
5989         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
5990         (Depends-on): Add stdint.
5991         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
5992         * modules/perl: New module.
5993         * modules/regex (Depends-on): Add stdint.
5994         * modules/rmdir-errno: New module.
5995         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
5996         m4/intmax_t.m4.
5997         (Depends-on): Add stdint.
5998         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
5999         m4/uintmax_t.m4.
6000         (Depends-on): Add stdint.
6001         * modules/unlink-busy: New module.
6002         * modules/utimecmp (Depends-on): Add stdint.
6003         * modules/uptime: New module.
6004         * modules/winsz-ioctl: New module.
6005         * modules/winsz-termios: New module.
6006         * modules/xnanosleep (Depends-on): Add nanosleep.
6007         * modules/ullong_max: Remove.
6008         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
6009         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
6010         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
6011         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
6012         (Depends-on): Add inttypes.
6013         (lib_SOURCES): Add xstrtol.h.
6014         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
6015         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
6016         * MODULES.html.sh: Move 'assert' into the assert section.
6017         Move 'dummy' into the linking section.
6018         Remove ullong_max.
6019         Add section for compatibility checks for POSIX:2001 functions,
6020         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
6021         winsz-ioctl, and winsz-termios into it.
6022         Add lchmod.
6023         Add top-level Misc section and put host-os, perl, and uptime
6024         into it.
6025
6026 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
6027
6028         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
6029         now assume the stdint module.  Do not include inttypes.h.
6030         * lib/fsusage.h: Likewise.
6031         * lib/getndelim2.c: Likewise.
6032         * lib/human.h: Likewise.
6033         * lib/inttostr.h: Likewise.
6034         * lib/obstack.c: Likewise.
6035         * lib/regex_internal.h: Likewise.
6036         * lib/tempname.c: Likewise.
6037         * lib/utimecmp.c: Likewise.
6038         * lib/xstrtol.h: Likewise.
6039
6040         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
6041
6042         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
6043         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
6044         * lib/xtime.h: Likewise.
6045
6046 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
6047
6048         * modules/openat (Files): Add lib/fchmodat.c.
6049         Fixes problem reported by Jay Youngman.
6050
6051 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
6052
6053         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
6054         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
6055
6056 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
6057             Bruno Haible  <bruno@clisp.org>
6058
6059         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
6060         and is a script that invokes bison. Tighten the code. Add comments.
6061
6062 2006-08-18  Jim Meyering  <jim@meyering.net>
6063
6064         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
6065         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
6066         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
6067         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
6068
6069 2006-08-18  Bruno Haible  <bruno@clisp.org>
6070
6071         * modules/bison-i18n: New file.
6072         * MODULES.html.sh (Internationalization functions): Add it.
6073
6074 2006-08-18  Bruno Haible  <bruno@clisp.org>
6075
6076         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
6077         sys/statvfs.h. When getmntinfo was found, check its declaration and
6078         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
6079
6080 2006-08-18  Bruno Haible  <bruno@clisp.org>
6081
6082         * m4/bison-i18n.m4: New file, from bison.
6083
6084 2006-08-18  Bruno Haible  <bruno@clisp.org>
6085
6086         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
6087         (ME_DUMMY): Treat "kernfs" as a dummy.
6088         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
6089
6090 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
6091
6092         Update from coreutils.
6093
6094         2006-08-15  Jim Meyering  <jim@meyering.net>
6095
6096         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
6097
6098         2006-01-17  Jim Meyering  <jim@meyering.net>
6099
6100         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
6101
6102         2006-01-11  Jim Meyering  <jim@meyering.net>
6103
6104         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
6105         Check for the lchmod function.
6106
6107 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
6108
6109         Update from coreutils.
6110
6111         * lib/__fpending.h: Add copyright notice.
6112         * lib/fprintftime.h: Likewise.
6113         * lib/savedir.c: Use (C) in copyright notice.
6114         * lib/savedir.h: Likewise.
6115
6116         2006-08-15  Jim Meyering  <jim@meyering.net>
6117
6118         * lib/at-func.c: New file, with the logic of all emulated at-functions.
6119         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
6120         in support of the EXPECTED_ERRNO macro.
6121         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
6122         definitions.  Instead, define the appropriate symbols and include
6123         "at-func.c".
6124         * lib/mkdirat.c (mkdirat): Likewise.
6125         * lib/fchmodat.c (fchmodat): Likewise.
6126         (ENOSYS): Remove definition.
6127         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
6128         it.  Don't include "unistd--.h" -- it wasn't ever used.
6129
6130         2006-01-17  Jim Meyering  <jim@meyering.net>
6131
6132         Rewrite fts.c not to change the current working directory,
6133         by using openat, fstatat, fdopendir, etc..
6134
6135         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
6136         (HAVE_OPENAT_SUPPORT): Define.
6137         [_LIBC] (fchdir): Don't undef or define; no longer used.
6138         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
6139         Now, this `function' always succeeds, and consumes its file descriptor
6140         parameter -- so callers must not close such FDs.  Update callers.
6141         (diropen_fd, opendirat, cwd_advance_fd): New functions.
6142         (diropen): Add parameter, SP.  Adjust all callers.
6143         Implement using diropen_fd, rather than open.
6144         (fts_open): Initialize new member, fts_cwd_fd.
6145         Remove fts_rft-setting code.
6146         (fts_close): Close fts_cwd_fd, if necessary.
6147         (__opendir2): Define in terms of opendir or opendirat,
6148         depending on whether the FST_NOCHDIR flag is set.
6149         (fts_build): Since fts_safe_changedir consumes its FD, and since
6150         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
6151         and close the dup'd file descriptor upon failure.
6152         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
6153         (fts_safe_changedir): Tweak semantics to reflect that this function
6154         now calls cwd_advance_fd and hence consumes its FD argument.
6155         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
6156         [struct FTS] (fts_rft): Remove now-unused member.
6157         [struct FTS] (fts_cycle.state): Improve comment.
6158
6159         * lib/openat.c (openat_needs_fchdir): New function.
6160         * lib/openat.h (openat_needs_fchdir): Declare it.
6161
6162 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
6163
6164         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
6165         Problem and fix reported by Pádraig Brady in
6166         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
6167
6168 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
6169
6170         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
6171
6172 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
6173
6174         * lib/memcoll.c (memcoll): Optimize for the common case where the
6175         arguments are bytewise equal.
6176
6177 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
6178
6179         * doc/regexprops-generic.texi: Add a copyright notice.
6180
6181 2006-08-15  Bruno Haible  <bruno@clisp.org>
6182
6183         * modules/tmpdir (License): Change to LGPL.
6184
6185 2006-08-15  Bruno Haible  <bruno@clisp.org>
6186
6187         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
6188         module.
6189
6190 2006-08-14  Simon Josefsson  <jas@extundo.com>
6191
6192         * config/srclist.txt: Add gnupload.
6193
6194 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
6195
6196         Change copyright notice from LGPL 2 to GPL 2, since that's the
6197         standard form used in the gnulib repository.
6198         * tests/test-lock.c: Likewise.
6199         * tests/test-stdint.c: Likewise.
6200         * tests/test-tls.c: Likewise.
6201
6202         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
6203         prelude-manager.  User shorter URLs for GNU projects, without '?'.
6204         Add copyright notice.
6205
6206         * check-module: Add copyright notice.  Output a copyright
6207         notice if "--version" is specified.
6208         * modules/COPYING: New file.
6209         * tests/test-getaddrinfo.c: Add copyright notice.
6210         * tests/test-verify.c: Likewise.
6211
6212 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
6213
6214         Change copyright notice from LGPL 2 to GPL 2, since that's the
6215         standard form used in the gnulib repository.
6216         * lib/lock.c: LGPL -> GPL.
6217         * lib/lock.h: Likewise.
6218         * lib/strnlen1.c: Likewise.
6219         * lib/strnlen1.h: Likewise.
6220         * lib/tls.c: Likewise.
6221         * lib/tls.h: Likewise.
6222         * lib/tmpdir.c: Likewise.
6223
6224         * lib/TODO: Remove; this belongs only in coreutils.
6225
6226 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
6227
6228         Add copyright notices to long-enough files that lack them, since
6229         otherwise the files aren't clearly free.  Use the same notice that
6230         getdate.texi already uses.
6231         * doc/alloca-opt.texi: Add copyright notice.
6232         * doc/alloca.texi: Likewise.
6233         * doc/ctime.texi: Likewise.
6234         * doc/functions.texi: Likewise.
6235         * doc/gcd.texi: Likewise.
6236         * doc/gnulib-tool.texi: Likewise.
6237         * doc/inet_ntoa.texi: Likewise.
6238         * doc/visibility.texi: Likewise.
6239
6240         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
6241         * doc/quote.texi: Add copyright notice.
6242
6243         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
6244         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
6245         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
6246         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
6247         is now obsolete, and give a pointer to the Sun list.
6248         Add copyright notice.
6249
6250 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
6251
6252         * config/srclistvars.sh: Add copyright notice.
6253
6254 2006-08-14  Eric Blake  <ebb9@byu.net>
6255
6256         Import the following change from libc:
6257
6258         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
6259
6260         Upstream bug 2997.
6261         * lib/misc/error.c: Add space between program name and message if file
6262         name is missing.
6263
6264 2006-08-12  Karl Berry  <karl@gnu.org>
6265
6266         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
6267         remove, these originate in gnulib now.
6268
6269 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6270
6271         * doc/Makefile (standards.info standards.html standards.dvi):
6272         Also depend on make-stds.texi.
6273
6274 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
6275
6276         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
6277         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
6278
6279         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
6280         in wchar_t.  Problem reported by Eric Blake.
6281
6282         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
6283         LEN is smaller than SIZE.  Suggested by Bruno Haible.
6284         Also, help the compiler to keep LEN in a register.
6285
6286 2006-08-11  Eric Blake  <ebb9@byu.net>
6287
6288         * users.txt: Sort.  Add tar.
6289
6290 2006-08-11  Bruno Haible  <bruno@clisp.org>
6291
6292         * users.txt: New file.
6293
6294 2006-08-11  Bruno Haible  <bruno@clisp.org>
6295
6296         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
6297         before <wchar.h>. Needed for OSF/1 and BSD/OS.
6298
6299 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
6300
6301         * modules/snprintf (Depends-on): Remove minmax.
6302         (Maintainer): Add self and Bruno.
6303
6304 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
6305
6306         * lib/.cppi-disable: Add snprintf.h, socket_.h.
6307         * lib/snprintf.c: Include <errno.h> and <limits.h>.
6308         (EOVERFLOW): Define if the system does not.
6309         Do not include "minmax.h"; it wasn't used.
6310         (snprintf): Don't assume size_t promotes to an unsigned type.
6311         Fix bug when generated string was too long for the buffer: the
6312         buffer's contents are supposed to be the initial prefix of the
6313         output.  Don't assume vasnprintf returns EOVERFLOW if the size
6314         exceeds INT_MAX; do the check ourselves.
6315
6316         Import the following changes from libc:
6317
6318         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
6319
6320         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
6321         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
6322         set wc to the byte which couldn't be converted.
6323         (re_string_reconstruct): Don't clear valid_raw_len before calling
6324         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
6325         tip_context using re_string_context_at.
6326
6327         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
6328
6329         * lib/posix/regex.h: g++ still cannot handled [restrict].
6330
6331         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
6332
6333         * lib/posix/regex.h: Remove special handling for VMS.
6334
6335 2006-08-10  Jim Meyering  <jim@meyering.net>
6336
6337         * modules/same-inode: New module.
6338         * modules/dev-ino: New module.
6339         * modules/cycle-check: Depend on these modules, rather than simply
6340         including their .h files.
6341         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
6342         required via m4/cycle-check.m4.
6343         * modules/same: Depend on new same-inode module, rather than
6344         including same-inode.h.
6345         * modules/chdir-safer: New file.
6346
6347         * modules/chown (Depends-on): Add stat-macros.
6348
6349 2006-08-10  Jim Meyering  <jim@meyering.net>
6350
6351         * m4/cycle-check.m4: New file.
6352         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
6353         * m4/dev-ino.m4, m4/same-inode.m4: New files.
6354
6355 2006-08-10  Eric Blake  <ebb9@byu.net>
6356
6357         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
6358         in from original proposal.
6359
6360 2006-08-10  Eric Blake  <ebb9@byu.net>
6361         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
6362
6363         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
6364         namespace.
6365
6366 2006-08-10  Bruno Haible  <bruno@clisp.org>
6367
6368         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
6369         as well.
6370
6371 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6372
6373         Sync from coreutils.
6374
6375         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
6376
6377         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
6378         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
6379
6380 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6381
6382         * modules/restrict: Remove; no longer needed now that we assume
6383         Autoconf 2.59 or later.
6384         * MODULES.html.sh: Remove 'restrict'.
6385         * modules/argp (Depends-on): Remove 'restrict'.
6386         * modules/base64 (Depends-on): Likewise.
6387         * modules/gc (Depends-on): Likewise.
6388         * modules/getaddrinfo (Depends-on): Likewise.
6389         * modules/glob (Depends-on): Likewise.
6390         * modules/inet_ntop (Depends-on): Likewise.
6391         * modules/inet_pton (Depends-on): Likewise.
6392         * modules/memxor (Depends-on): Likewise.
6393         * modules/regex (Depends-on): Likewise.
6394         * modules/strtok_r (Depends-on): Likewise.
6395         * modules/time_r (Depends-on): Likewise.
6396
6397 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6398
6399         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
6400         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
6401         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6402         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
6403         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
6404         * m4/memxor.m4 (gl_MEMXOR): Likewise.
6405         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
6406         gl_C_RESTRICT replaced by AC_C_RESTRICT.
6407
6408         Merge from coreutils.
6409         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
6410         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
6411         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6412         * m4/time_r.m4 (gl_TIME_R): Likewise.
6413
6414 2006-08-09  Karl Berry  <karl@gnu.org>
6415
6416         * config/srclist.txt: no more gettext-tools, per Bruno.
6417
6418 2006-08-08  Eric Blake  <ebb9@byu.net>
6419
6420         * modules/verror: New module.
6421         * MODULES.html.sh: Document it.
6422
6423 2006-08-08  Eric Blake  <ebb9@byu.net>
6424
6425         * lib/verror.h, lib/verror.c: New files.
6426
6427 2006-08-08  Eric Blake  <ebb9@byu.net>
6428
6429         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
6430         verror_at_line output complies with GNU Coding Standards even when
6431         file is NULL.
6432
6433 2006-08-07  Bruno Haible  <bruno@clisp.org>
6434
6435         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
6436         versions of AIX.
6437         Reported by Ralf Wildenhues.
6438
6439 2006-08-07  Bruno Haible  <bruno@clisp.org>
6440
6441         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
6442         in an AC_DEFUN. Needed so that the autoconf snippets can use
6443         AC_REQUIRE.
6444
6445 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6446
6447         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6448         Initialize pkgdata_DATA.
6449         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
6450         overriding it.
6451
6452 2006-08-06  Eric Blake  <ebb9@byu.net>
6453
6454         * lib/error.h: Fold in some upstream changes from glibc.
6455         * lib/error.c: Likewise.
6456
6457 2006-08-04  Bruno Haible  <bruno@clisp.org>
6458
6459         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6460         Make the mostlyclean-local rule depend on mostlyclean-generic.
6461         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
6462
6463 2006-07-31  Bruno Haible  <bruno@clisp.org>
6464
6465         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
6466         <stdlib.h>, <string.h>.
6467
6468 2006-07-30  Bruno Haible  <bruno@clisp.org>
6469
6470         * modules/readlink (License): Change to LGPL.
6471
6472 2006-07-30  Bruno Haible  <bruno@clisp.org>
6473
6474         * modules/javaversion (Makefile.am): Distribute javaversion.java and
6475         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
6476         set PKGDATADIR to point to it.
6477
6478 2006-07-30  Bruno Haible  <bruno@clisp.org>
6479
6480         * modules/csharpexec (configure.ac): Comment out macro invocation.
6481         * modules/javaexec (configure.ac): Likewise.
6482         * modules/javacomp-script (configure.ac): Likewise.
6483
6484         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
6485
6486 2006-07-30  Bruno Haible  <bruno@clisp.org>
6487
6488         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
6489         linked-list.
6490
6491 2006-07-30  Bruno Haible  <bruno@clisp.org>
6492
6493         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
6494
6495 2006-07-30  Bruno Haible  <bruno@clisp.org>
6496
6497         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6498         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
6499         get removed.
6500
6501 2006-07-29  Bruno Haible  <bruno@clisp.org>
6502
6503         Make it possible for gnulib-tool to work with locally modified or
6504         augmented gnulib repositories.
6505         * gnulib-tool (func_usage): Document --local-dir option.
6506         (local_gnulib_dir): New variable.
6507         Handle --local-dir option.
6508         (func_lookup_file): New function.
6509         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
6510         (func_get_description, func_get_filelist, func_get_description,
6511         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
6512         func_get_automake_snippet, func_get_include_directive,
6513         func_get_license, func_get_maintainer): Use func_lookup_file.
6514         (func_import, func_create_testdir): Use func_lookup_file.
6515
6516 2006-07-29  Bruno Haible  <bruno@clisp.org>
6517
6518         * modules/setenv (Depends-on): Add unistd.
6519
6520 2006-07-29  Bruno Haible  <bruno@clisp.org>
6521
6522         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
6523
6524 2006-07-29  Bruno Haible  <bruno@clisp.org>
6525
6526         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
6527
6528 2006-07-29  Bruno Haible  <bruno@clisp.org>
6529
6530         * gnulib-tool (import, update): If there is no Makefile.am, look at
6531         aclocal.m4, instead of bailing out.
6532
6533 2006-07-29  Bruno Haible  <bruno@clisp.org>
6534
6535         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
6536         Categorize the options by when they are useful.
6537
6538 2006-07-29  Bruno Haible  <bruno@clisp.org>
6539
6540         * gnulib-tool (func_usage): Document option --no-libtool.
6541         Handle option --no-libtool.
6542         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
6543         for changed semantics of $libtool variable.
6544         (func_import): Likewise. If libtool is not used, show this through
6545         an option --no-libtool.
6546         (func_create_testdir): Update.
6547
6548 2006-07-29  Bruno Haible  <bruno@clisp.org>
6549
6550         * gnulib-tool (func_import): Extend error message about missing
6551         --doc-base.
6552
6553 2006-07-29  Bruno Haible  <bruno@clisp.org>
6554
6555         * gnulib-tool (func_import): Don't create the $docbase directory if
6556         there is no file to store there.
6557
6558 2006-07-29  Bruno Haible  <bruno@clisp.org>
6559
6560         * gnulib-tool (autoconf_minversion): If a --dir option is given and
6561         relevant, look for configure.ac there, not in the current directory.
6562         Also use a simple search for AC_PREREQ, not "autoconf --trace".
6563
6564 2006-07-29  Bruno Haible  <bruno@clisp.org>
6565
6566         * gnulib-tool (SORT): New variable.
6567         (func_usage): Undocument --assume-autoconf option.
6568         Remove --assume-autoconf option handling.
6569         (autoconf_minversion): Determine from the contents of configure.ac.
6570         (func_import): Remove autoconf_minversion handling.
6571         Suggested by Eric Blake.
6572
6573 2006-07-29  Bruno Haible  <bruno@clisp.org>
6574
6575         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
6576
6577 2006-07-29  Bruno Haible  <bruno@clisp.org>
6578
6579         * config/srclist.txt (*setenv.[ch]): Remove rules.
6580
6581 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6582
6583         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
6584
6585 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6586
6587         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
6588         arpa/inet.h.
6589
6590 2006-07-28  Simon Josefsson  <jas@extundo.com>
6591
6592         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
6593         * modules/inet_pton (Depends-on): Likewise.
6594
6595 2006-07-28  Simon Josefsson  <jas@extundo.com>
6596
6597         * m4/netinet_in_h.m4: New file.
6598
6599 2006-07-28  Simon Josefsson  <jas@extundo.com>
6600
6601         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
6602         #include's.
6603
6604 2006-07-28  Simon Josefsson  <jas@extundo.com>
6605
6606         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
6607         #include's.
6608
6609 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
6610
6611         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
6612         setgid on directories only if they set these bits.
6613         * lib/modechange.h: Remove obsolete comment about masks.
6614
6615 2006-07-28  Eric Blake  <ebb9@byu.net>
6616
6617         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
6618         macro expansion.
6619
6620 2006-07-28  Bruno Haible  <bruno@clisp.org>
6621
6622         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
6623
6624 2006-07-28  Bruno Haible  <bruno@clisp.org>
6625
6626         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
6627
6628 2006-07-28  Bruno Haible  <bruno@clisp.org>
6629
6630         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
6631         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
6632         Define fallbacks.
6633         Avoids link error on FreeBSD 4.x.
6634         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
6635
6636         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
6637         encoding.
6638         * lib/mbswidth.c (iswcntrl): Likewise.
6639
6640 2006-07-27  Bruno Haible  <bruno@clisp.org>
6641
6642         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
6643         test.
6644
6645 2006-07-27  Bruno Haible  <bruno@clisp.org>
6646
6647         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
6648         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
6649         defined.
6650
6651 2006-07-26  Eric Blake  <ebb9@byu.net>
6652
6653         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
6654
6655 2006-07-26  Eric Blake  <ebb9@byu.net>
6656
6657         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
6658         like mingw that lack mkstemp.
6659         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
6660         avoid compilation warning on mingw.
6661
6662 2006-07-26  Bruno Haible  <bruno@clisp.org>
6663
6664         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
6665         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
6666         INT_FAST*_MIN, INTPTR_MIN.
6667
6668 2006-07-25  Bruno Haible  <bruno@clisp.org>
6669
6670         * modules/version-etc (Depends-on): Add stdarg.
6671
6672 2006-07-25  Bruno Haible  <bruno@clisp.org>
6673
6674         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
6675         complex commands.
6676
6677 2006-07-25  Bruno Haible  <bruno@clisp.org>
6678
6679         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
6680         defined in <stdarg.h> or config.h.
6681
6682 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
6683
6684         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
6685         (gl_STDIO_SAFER): Remove.
6686
6687 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
6688
6689         * MODULES.html.sh (File stream based Input/Output):
6690         Add fopen-safer, tmpfile-safer; remove stdio-safer.
6691         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
6692         * modules/fopen-safer, modules/tmpfile-safer: New files.
6693         * modules/stdio-safer: Remove.
6694
6695 2006-07-24  Bruno Haible  <bruno@clisp.org>
6696
6697         * modules/tmpdir: New file.
6698         * MODULES.html.sh (File system functions): Add it.
6699
6700 2006-07-24  Bruno Haible  <bruno@clisp.org>
6701
6702         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
6703         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
6704
6705 2006-07-24  Bruno Haible  <bruno@clisp.org>
6706
6707         * modules/clean-temp: New file.
6708
6709 2006-07-24  Bruno Haible  <bruno@clisp.org>
6710
6711         * m4/tmpdir.m4: New file, from GNU gettext.
6712
6713 2006-07-24  Bruno Haible  <bruno@clisp.org>
6714
6715         * lib/tmpdir.h: New file, from GNU gettext.
6716         * lib/tmpdir.c: New file, from GNU gettext.
6717
6718 2006-07-24  Bruno Haible  <bruno@clisp.org>
6719
6720         * lib/clean-temp.h: New file, from GNU gettext.
6721         * lib/clean-temp.c: New file, from GNU gettext.
6722
6723 2006-07-23  Eric Blake  <ebb9@byu.net>
6724
6725         * modules/stdio-safer (Files): Add tmpfile-safer.c.
6726         (Depends-on): Add binary-io.
6727
6728 2006-07-23  Eric Blake  <ebb9@byu.net>
6729
6730         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
6731
6732 2006-07-23  Eric Blake  <ebb9@byu.net>
6733
6734         * lib/tmpfile-safer.c: New file.
6735         * lib/stdio-safer.h (fopen_safer): Add prototype.
6736         * lib/stdio--.h (tmpfile): Make safer.
6737
6738 2006-07-23  Bruno Haible  <bruno@clisp.org>
6739
6740         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
6741         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
6742         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
6743         gl_linked_remove_at): Use it.
6744
6745 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6746         and Simon Josefsson <jas@extundo.com>
6747
6748         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
6749
6750         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
6751
6752 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6753
6754         * modules/close-stream: New file.
6755         * modules/closeout (Description): Make it clear that it exits
6756         with a diagnostic on error.
6757         (Depends-on): Add close-stream.  Remove fpending, stdbool.
6758         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
6759
6760 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6761
6762         * m4/close-stream.m4: New file.
6763
6764 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6765
6766         * lib/close-stream.c, lib/close-stream.h: New files.
6767
6768 2006-07-22  Bruno Haible  <bruno@clisp.org>
6769
6770         Merge from GNU gettext 0.15.
6771
6772         2006-05-01  Bruno Haible  <bruno@clisp.org>
6773
6774                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
6775
6776         2006-07-22  Bruno Haible  <bruno@clisp.org>
6777
6778                 * modules/javaversion: New file.
6779                 * MODULES.html.sh (Java): Add javaversion.
6780
6781         2006-03-12  Bruno Haible  <bruno@clisp.org>
6782
6783                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
6784
6785         2005-12-04  Bruno Haible  <bruno@clisp.org>
6786
6787                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
6788                 (untested).
6789
6790         2006-06-21  Bruno Haible  <bruno@clisp.org>
6791
6792                 Avoid warnings from recent versions of mcs.
6793                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
6794                 -o, -L, -r any more. Use options documented since mcs-1.0
6795                 instead. Similarly for -g.
6796
6797         2005-12-04  Bruno Haible  <bruno@clisp.org>
6798
6799                 * build-aux/csharpcomp.sh.in: Suffix for resources is
6800                 .resources, not .resource.
6801
6802         2005-07-09  Bruno Haible  <bruno@clisp.org>
6803
6804                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
6805                 add a .dll suffix.
6806                 Reported by Mark Junker <mjscod@gmx.de>.
6807
6808         2006-07-22  Bruno Haible  <bruno@clisp.org>
6809
6810                 * modules/gettext: Upgrade to gettext-0.15.
6811                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
6812                 m4/visibility.m4.
6813                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
6814
6815 2006-07-22  Bruno Haible  <bruno@clisp.org>
6816
6817         Merge from GNU gettext 0.15.
6818
6819         2006-03-25  Bruno Haible  <bruno@clisp.org>
6820
6821                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
6822
6823         2006-07-21  Bruno Haible  <bruno@clisp.org>
6824
6825                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
6826                 "1.1".
6827
6828         2006-05-09  Bruno Haible  <bruno@clisp.org>
6829
6830                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
6831                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
6832                 for the conftestver execution.
6833
6834         2006-05-01  Bruno Haible  <bruno@clisp.org>
6835
6836                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
6837                 optional target-version argument. Verify that the compiler
6838                 groks source of the specified source-version, or add -source
6839                 option as necessary. Verify that the compiler produces
6840                 bytecode in the specified target-version, or add -target and
6841                 -source options as necessary. Make the result of the test
6842                 available as variable CONF_JAVAC. Also log error output in
6843                 config.log.
6844
6845         2006-03-11  Bruno Haible  <bruno@clisp.org>
6846
6847                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
6848
6849         2006-05-09  Bruno Haible  <bruno@clisp.org>
6850
6851                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
6852                 CLASSPATH_SEPARATOR to a semicolon.
6853
6854         2006-03-12  Bruno Haible  <bruno@clisp.org>
6855
6856                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
6857                 available as variable CONF_JAVA, for subsequent autoconf
6858                 tests. Also log error output in config.log.
6859
6860         2006-07-19  Bruno Haible  <bruno@clisp.org>
6861
6862                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
6863                 that getline works on glibc2 systems. Needed to avoid trouble
6864                 in relocatable.c.
6865                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
6866
6867         2005-12-04  Bruno Haible  <bruno@clisp.org>
6868
6869                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
6870                 launcher (untested).
6871
6872         2005-12-04  Bruno Haible  <bruno@clisp.org>
6873
6874                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
6875
6876         2006-07-22  Bruno Haible  <bruno@clisp.org>
6877
6878                 * gettext.m4: Update from GNU gettext-0.15.
6879                 * nls.m4: Likewise.
6880                 * po.m4: Likewise.
6881                 * inttypes-pri.m4: Likewise.
6882                 * inttypes-h.m4: Renamed from inttypes.m4.
6883                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
6884
6885 2006-07-22  Bruno Haible  <bruno@clisp.org>
6886
6887         Merge from GNU gettext 0.15.
6888
6889         2005-07-05  Bruno Haible  <bruno@clisp.org>
6890
6891                 * printf-args.c (printf_fetchargs): Work around broken
6892                 definition of wint_t on mingw.
6893
6894         2005-02-12  Bruno Haible  <bruno@clisp.org>
6895
6896                 * xallocsa.h: Add extern "C" for C++.
6897
6898         2006-05-17  Bruno Haible  <bruno@clisp.org>
6899
6900                 Cygwin portability.
6901                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
6902
6903         2006-04-30  Bruno Haible  <bruno@clisp.org>
6904
6905                 * progreloc.c: Include <mach-o/dyld.h> if available.
6906                 (find_executable): Use _NSGetExecutablePath when possible.
6907
6908         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6909
6910                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
6911                 function.
6912
6913         2005-12-29  Bruno Haible  <bruno@clisp.org>
6914
6915                 * progreloc.c (set_program_name_and_installdir): Fix
6916                 compilation error.
6917
6918         2005-12-04  Bruno Haible  <bruno@clisp.org>
6919
6920                 Cygwin portability.
6921                 * progreloc.c: Include <windows.h> also on Cygwin.
6922                 (find_executable): Add support for Cygwin.
6923                 (set_program_name_and_installdir): Handle also platforms with
6924                 nonempty EXEEXT.
6925
6926         2006-07-11  Bruno Haible  <bruno@clisp.org>
6927
6928                 * javacomp.c: Fix a comment.
6929                 Reported by Jim Meyering.
6930
6931         2006-04-30  Bruno Haible  <bruno@clisp.org>
6932
6933                 * javacomp.h (compile_java_class): Add source_version,
6934                 target_version arguments.
6935                 * javacomp.c: Rewritten to choose only a compiler that
6936                 respects the specified source_version and target_version.
6937
6938         2006-06-27  Bruno Haible  <bruno@clisp.org>
6939
6940                 Assume correct S_ISDIR macro.
6941                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
6942
6943         2006-07-22  Bruno Haible  <bruno@clisp.org>
6944
6945                 * javaversion.h: New file, from GNU gettext.
6946                 * javaversion.c: New file, from GNU gettext.
6947                 * javaversion.java: New file, from GNU gettext.
6948                 * javaversion.class: New file, from GNU gettext.
6949
6950         2006-05-17  Bruno Haible  <bruno@clisp.org>
6951
6952                 Cygwin portability.
6953                 * javaexec.c (execute_java_class): Test for jview program
6954                 also on Cygwin.
6955
6956         2006-04-09  Bruno Haible  <bruno@clisp.org>
6957
6958                 * fatal-signal.c: Don't include string.h.
6959                 (at_fatal_signal): Use a copying loop instead of memcpy.
6960
6961         2005-12-04  Bruno Haible  <bruno@clisp.org>
6962
6963                 * csharpexec.c: Add support for 'clix' launcher (untested).
6964                 (execute_csharp_using_sscli): New function.
6965                 (execute_csharp_program): Call it.
6966
6967         2006-06-21  Bruno Haible  <bruno@clisp.org>
6968
6969                 Avoid warnings from recent versions of mcs.
6970                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
6971                 -o, -L, -r any more. Use options documented since mcs-1.0
6972                 instead. Similarly for -g.
6973
6974         2005-07-09  Bruno Haible  <bruno@clisp.org>
6975
6976                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
6977                 add a .dll suffix.
6978                 Reported by Mark Junker <mjscod@gmx.de>.
6979
6980         2006-06-17  Bruno Haible  <bruno@clisp.org>
6981
6982                 * config.charset: Update for NetBSD 3.0.
6983
6984         2006-05-17  Bruno Haible  <bruno@clisp.org>
6985
6986                 Cygwin portability.
6987                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
6988
6989         2006-05-16  Bruno Haible  <bruno@clisp.org>
6990
6991                 * localcharset.c [CYGWIN]: Include <windows.h>.
6992                 (get_charset_aliases): For Cygwin, return the same CPxxx
6993                 aliases list as under WIN32.
6994                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
6995                 the environment variables. Fall back to GetACP().
6996
6997         2006-04-05  Bruno Haible  <bruno@clisp.org>
6998
6999                 * config.charset: Update Juan Manuel Guerrero's address.
7000
7001         2005-02-12  Bruno Haible  <bruno@clisp.org>
7002
7003                 * allocsa.h: Add extern "C" for C++.
7004
7005         2005-02-10  Bruno Haible  <bruno@clisp.org>
7006
7007                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
7008                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
7009
7010         2006-07-22  Bruno Haible  <bruno@clisp.org>
7011
7012                 * gettext.h: Update to GNU gettext-0.15.
7013
7014 2006-07-22  Bruno Haible  <bruno@clisp.org>
7015
7016         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
7017         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
7018         lib-prefix.m4, longdouble.m4, ssize_t.m4.
7019
7020 2006-07-21  Eric Blake  <ebb9@byu.net>
7021
7022         * modules/stdlib-safer: New file.
7023         * MODULES.html.sh (File stream based Input/Output): Add
7024         stdlib-safer.
7025
7026 2006-07-21  Eric Blake  <ebb9@byu.net>
7027
7028         * lib/stdlib-safer.h: New file from coreutils, required by
7029         stdlib--.h.
7030
7031 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
7032
7033         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
7034
7035 2006-07-20  Bruno Haible  <bruno@clisp.org>
7036
7037         * gnulib-tool: Recognize new option --assume-autoconf.
7038         (autoconf_minversion): New variable.
7039         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
7040
7041 2006-07-20  Bruno Haible  <bruno@clisp.org>
7042
7043         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
7044
7045 2006-07-19  Derek R. Price  <derek@ximbiot.com>
7046
7047         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
7048         Reindent and repaginate.
7049
7050 2006-07-19  Derek Price  <derek@ximbiot.com>
7051
7052         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
7053         Correct grammar.
7054
7055 2006-07-17  Bruno Haible  <bruno@clisp.org>
7056
7057         * modules/list: New file.
7058         * modules/array-list: New file.
7059         * modules/carray-list, modules/carray-list-tests: New files.
7060         * modules/linked-list, modules/linked-list-tests: New files.
7061         * modules/avltree-list, modules/avltree-list-tests: New files.
7062         * modules/rbtree-list, modules/rbtree-list-tests: New files.
7063         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
7064         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
7065         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
7066         * modules/oset: New file.
7067         * modules/array-oset: New file.
7068         * modules/avltree-oset, modules/avltree-oset-tests: New files.
7069         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
7070         * tests/test-carray_list.c: New file.
7071         * tests/test-linked_list.c: New file.
7072         * tests/test-avltree_list.c: New file.
7073         * tests/test-rbtree_list.c: New file.
7074         * tests/test-linkedhash_list.c: New file.
7075         * tests/test-avltreehash_list.c: New file.
7076         * tests/test-rbtreehash_list.c: New file.
7077         * tests/test-avltree_oset.c: New file.
7078         * tests/test-rbtree_oset.c: New file.
7079         * MODULES.html.sh (Container data structures): New section.
7080
7081 2006-07-17  Bruno Haible  <bruno@clisp.org>
7082
7083         * m4/gl_list.m4: New file.
7084
7085 2006-07-17  Bruno Haible  <bruno@clisp.org>
7086
7087         * lib/gl_list.h: New file.
7088         * lib/gl_list.c: New file.
7089         * lib/gl_array_list.h: New file.
7090         * lib/gl_array_list.c: New file.
7091         * lib/gl_carray_list.h: New file.
7092         * lib/gl_carray_list.c: New file.
7093         * lib/gl_linked_list.h: New file.
7094         * lib/gl_linked_list.c: New file.
7095         * lib/gl_anylinked_list1.h: New file.
7096         * lib/gl_anylinked_list2.h: New file.
7097         * lib/gl_avltree_list.h: New file.
7098         * lib/gl_avltree_list.c: New file.
7099         * lib/gl_anyavltree_list1.h: New file.
7100         * lib/gl_anyavltree_list2.h: New file.
7101         * lib/gl_rbtree_list.h: New file.
7102         * lib/gl_rbtree_list.c: New file.
7103         * lib/gl_anyrbtree_list1.h: New file.
7104         * lib/gl_anyrbtree_list2.h: New file.
7105         * lib/gl_anytree_list1.h: New file.
7106         * lib/gl_anytree_list2.h: New file.
7107         * lib/gl_linkedhash_list.h: New file.
7108         * lib/gl_linkedhash_list.c: New file.
7109         * lib/gl_anyhash_list1.h: New file.
7110         * lib/gl_anyhash_list2.h: New file.
7111         * lib/gl_avltreehash_list.h: New file.
7112         * lib/gl_avltreehash_list.c: New file.
7113         * lib/gl_rbtreehash_list.h: New file.
7114         * lib/gl_rbtreehash_list.c: New file.
7115         * lib/gl_anytreehash_list1.h: New file.
7116         * lib/gl_anytreehash_list2.h: New file.
7117
7118         * lib/gl_oset.h: New file.
7119         * lib/gl_oset.c: New file.
7120         * lib/gl_array_oset.h: New file.
7121         * lib/gl_array_oset.c: New file.
7122         * lib/gl_avltree_oset.h: New file.
7123         * lib/gl_avltree_oset.c: New file.
7124         * lib/gl_rbtree_oset.h: New file.
7125         * lib/gl_rbtree_oset.c: New file.
7126         * lib/gl_anytree_oset.h: New file.
7127
7128 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
7129
7130         * m4/mkancesdirs.m4: New file.
7131         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
7132         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
7133         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
7134         it.
7135
7136 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
7137
7138         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
7139         * lib/mkancesdirs.h: New files.
7140         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
7141         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
7142         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
7143         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
7144         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
7145         callers changed.  Revamp internals significantly, by not
7146         attempting to create directories that are temporarily more
7147         permissive than the final results.  Do not attempt to use
7148         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
7149         This removes some race conditions, fixes some bugs, and simplifies
7150         things.  Use new dirchownmod function to do owner and mode changes.
7151         * lib/mkdir-p.h: Likewise.
7152         * lib/modechange.c (octal_to_mode): New function.
7153         (struct mode_change): New member mentioned.
7154         (make_node_op_equals): New arg mentioned.  All callers changed.
7155         (mode_compile): Keep track of which mode bits the user has explicitly
7156         mentioned.
7157         (mode_adjust): New arg DIR, so that we implement the X op correctly.
7158         New arg PMODE_BITS, to keep track of which mode bits the user
7159         mentioned; it treats S_ISUID and S_ISGID speciall.
7160         All callers changed.
7161         * lib/modechange.h: Likewise.
7162
7163 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
7164
7165         * MODULES.html.sh: Add mkancestors.
7166         * modules/mkancesdirs: New module.
7167         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
7168         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
7169         The chdir-safer and afs files are now orphans; I'll remove them
7170         unless someone speaks up.
7171         Add lib/dirchownmod.c, lib/dirchownmod.h.
7172         (Depends-on): Remove alloca, chown, save-cwd, dirname.
7173         Add lchown, mkancesdirs.
7174         (Maintainer): Add self.
7175
7176 2006-07-15  Karl Berry  <karl@gnu.org>
7177
7178         * gnulib-tool: help message wording/arrangement.
7179
7180 2006-07-14  Simon Josefsson  <jas@extundo.com>
7181
7182         * doc/gnulib.texi (Libtool and Windows): New section.
7183
7184 2006-07-12  Simon Josefsson  <jas@extundo.com>
7185
7186         * modules/gendocs (License): Fix license, approved by Karl.
7187
7188 2006-07-12  Eric Blake  <ebb9@byu.net>
7189
7190         * MODULES.html.sh: Add gendocs.
7191
7192 2006-07-11  Eric Blake  <ebb9@byu.net>
7193
7194         * modules/fdl: New module, to install doc/fdl.texi.
7195         * MODULES.html.sh: Add new section for documentation modules.
7196         * gnulib-tool: Avoid space-tab.
7197         (--doc-base): New option, to manage files from doc.
7198
7199 2006-07-11  Eric Blake  <ebb9@byu.net>
7200
7201         * m4/absolute-header.m4: Fix comments to match recent change.
7202
7203 2006-07-11  Eric Blake  <ebb9@byu.net>
7204
7205         * gnulib-tool: List --doc-base before --tests-base.
7206
7207 2006-07-11  Derek R. Price  <derek@ximbiot.com>
7208
7209         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
7210
7211 2006-07-11  Bruno Haible  <bruno@clisp.org>
7212
7213         * README: Mention where to put documentation.
7214
7215 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7216
7217         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
7218
7219 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
7220
7221         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
7222         to stdint.m4.
7223
7224 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
7225
7226         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
7227         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
7228         "no/such/file/stdint.h" when there is no such file, so that
7229         the resulting C code can be parsed by dodgy compilers.
7230         Problems reported by Bob Proulx.
7231
7232 2006-07-10  Derek R. Price  <derek@ximbiot.com>
7233
7234         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
7235         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
7236         macros into the GNU _D_EXACT_NAMLEN.
7237         * lib/savedir.c:  Likewise.
7238         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
7239
7240 2006-07-10  Derek R. Price  <derek@ximbiot.com>
7241         and Paul Eggert  <eggert@cs.ucla.edu>
7242
7243         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
7244         * m4/savedir.m4:
7245         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
7246         macros into the GNU _D_EXACT_NAMLEN.
7247
7248 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
7249
7250         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
7251         around the absolute name, to work around a problem with the HP-UX
7252         11.23 native C compiler, reported by Bob Proulx.
7253
7254 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
7255
7256         * doc/maintain.texi, make-stds.texi: Sync from
7257         <http://savannah.gnu.org/projects/gnustandards>.
7258
7259 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
7260
7261         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
7262
7263 2006-07-09  Jim Meyering  <jim@meyering.net>
7264
7265         * m4/glob.m4: Remove a doubled word in a comment.
7266
7267 2006-07-09  Jim Meyering  <jim@meyering.net>
7268
7269         * lib/argp-pv.c: Remove a doubled word in a comment.
7270         * lib/check-version.c (check_version): Likewise.
7271         * lib/javacomp.c (compile_java_class): Likewise.
7272
7273 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
7274
7275         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
7276         for the benefit of people using Autoconf 2.60.  If you want to
7277         support older Autoconf versions you can copy m4/onceonly_2_57.m4
7278         (or m4/onceonly.m4, if pre-2.57) manually.
7279
7280 2006-07-08  Jim Meyering  <jim@meyering.net>
7281
7282         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
7283         comment.
7284         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
7285         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
7286         comment.
7287
7288 2006-07-08  Jim Meyering  <jim@meyering.net>
7289
7290         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
7291
7292 2006-07-07  Simon Josefsson  <jas@extundo.com>
7293
7294         * tests/test-crc.c: Change expected crc value, the test vector
7295         were probably computed using the old broken crc.c?
7296
7297 2006-07-06  Simon Josefsson  <jas@extundo.com>
7298
7299         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
7300         now the canonical place for the M4 file).
7301
7302         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
7303         from the sys_socket dependency now.
7304
7305         * modules/inet_pton (Files): Ditto.
7306
7307         * modules/inet_ntop (Files): Ditto.
7308
7309 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
7310
7311         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
7312         not gl_PREREQ_GETUSERSHELL.
7313
7314 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7315
7316         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
7317         with only one argument, for Autoconf 2.60.
7318         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
7319         expand to nothing, so add a shell command to avoid syntax error.
7320         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7321
7322 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7323
7324         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
7325
7326 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7327
7328         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
7329         no longer needed.  Check for isblank decl.
7330         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
7331         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
7332         of existence.
7333
7334 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7335
7336         * lib/getloadavg.c: Use __VMS, not VMS.
7337         * lib/getopt.c: Likewise.
7338         * lib/getpagesize.h: Likewise.
7339         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
7340         and probably does not work.
7341
7342 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7343
7344         * lib/.cppi-disable: Add wcwidth.
7345         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
7346         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
7347         (ISGRAPH): Remove.  All uses changed to isgraph.
7348         (FOLD) [!defined _LIBC]: Remove special case.
7349         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
7350         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
7351         HAVE_ISBLANK.
7352         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
7353         case.
7354
7355 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
7356
7357         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
7358         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
7359         brackets.  Other minor changes to suppress some compiler
7360         warnings.
7361
7362 2006-07-06  Derek R. Price  <derek@ximbiot.com>
7363         and Paul Eggert  <eggert@cs.ucla.edu>
7364
7365         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
7366         of invoking obsolescent AC_HEADER_DIRENT macro.
7367         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
7368         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
7369         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
7370         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
7371         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
7372         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
7373         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
7374         * m4/readdir.m4: Remove; no longer needed.
7375
7376 2006-07-06  Derek R. Price  <derek@ximbiot.com>
7377         and Paul Eggert  <eggert@cs.ucla.edu>
7378
7379         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
7380         Don't worry about this obsolete case any more.
7381         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
7382         directories.
7383         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
7384         worry about this obsolete case any more.
7385         * lib/fts.c: Likewise.
7386         * lib/getcwd.c: Likewise.
7387         * lib/glob.h: Likewise.
7388         * lib/savedir.c: Likewise.
7389
7390 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
7391
7392         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
7393         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
7394         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
7395         needed.
7396         All uses removed.
7397         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7398         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
7399         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
7400         needed.
7401         * m4/getdate.m4 (gl_GETDATE): Likewise.
7402         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
7403         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
7404         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
7405         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7406         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
7407         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
7408         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
7409         needed.
7410
7411 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
7412
7413         * lib/memcasecmp.c: Include <limits.h>.
7414         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
7415         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
7416         Don't assume isdigit succeeds only on '0' through '9'.
7417
7418 2006-07-05  Eric Blake  <ebb9@byu.net>
7419
7420         * modules/getaddrinfo (Depends-on): Add snprintf.
7421
7422 2006-07-05  Eric Blake  <ebb9@byu.net>
7423
7424         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
7425         to avoid 'header present but could not be compiled' on cygwin.
7426
7427 2006-07-05  Eric Blake  <ebb9@byu.net>
7428
7429         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
7430         missing from netdb.h.
7431         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
7432
7433 2006-07-05  Derek R. Price  <derek@ximbiot.com>
7434
7435         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
7436         no longer needed.
7437         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
7438         * m4/getdate.m4 (gl_GETDATE): Likewise.
7439         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
7440         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
7441         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
7442         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7443         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
7444
7445 2006-07-05  Derek R. Price  <derek@ximbiot.com>
7446
7447         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
7448         All uses of is_space replaced by isspace.
7449         * lib/exit.h: Don't talk about STDC_HEADERS.
7450         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
7451         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
7452         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
7453         replaced by isprint etc.
7454         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
7455         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
7456         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
7457         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
7458         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
7459         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
7460
7461 2006-07-05  Bruno Haible  <bruno@clisp.org>
7462
7463         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
7464         the function exists, before testing against AIX.
7465         Reported by Martin Lambers <marlam@marlam.de>.
7466
7467 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
7468
7469         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
7470         From Mark D. Baushke.
7471
7472 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
7473
7474         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
7475         to the absolute name, not just one, to bypass Sun C 5.8's
7476         "warning: #include of /usr/include/... may be non-portable".
7477
7478 2006-07-04  Eric Blake  <ebb9@byu.net>
7479
7480         * modules/dirname-tests: New test module.
7481         * tests/test-dirname.c: New file, replacing dirname.c
7482         TEST_DIRNAME section that was recently deleted.
7483
7484 2006-07-04  Bruno Haible  <bruno@clisp.org>
7485
7486         Assume ANSI C header files and <ctype.h> functions.
7487         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
7488         (mbsnwidth): Use isprint, iscntrl instead.
7489
7490 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7491
7492         Merge from coreutils.
7493         * MODULES.html.sh: Add xstrtold.
7494         * modules/xstrtold: New file.
7495         * modules/cycle-check (Files): Add lib/same-inode.h.
7496         * modules/dirname (Files): Add m4/double-slash-root.m4.
7497         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
7498         * modules/mkdir-p (Files): Add lib/same-inode.h.
7499         * modules/same (Files): Add lib/same-inode.h.
7500
7501 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7502
7503         * m4/absolute-header.m4: Renamed from full-header-path.m4.
7504         This is to keep the terminology clean; POSIX talks about
7505         "absolute pathnames", not "full pathnames", but the GNU
7506         Coding Standards say to use "path" for something else;
7507         so use "absolute" to keep both sides happy.
7508         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
7509         Set gl_absolute_header, not gl_full_header_path.
7510         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
7511         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
7512         All uses changed.
7513
7514         Merge from coreutils.
7515
7516         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
7517
7518         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
7519         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
7520         want to require the building of c-strtod.o.
7521         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
7522         needs -lm directly.
7523         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
7524
7525         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
7526
7527         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
7528         --as-needed option if available.  Problem reported by Albert Chin in
7529         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
7530         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
7531         cc merely issues a bunch of annoying warnings for --as-needed
7532         (this problem was reported by Bob Proulx).  Also, try linking with
7533         -lm to detect a bug in binutils 2.16 (this problem was reported
7534         by Ralf Wildenhues).
7535
7536         2006-06-18  Jim Meyering  <jim@meyering.net>
7537
7538         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
7539         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
7540         macro.
7541         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
7542         also check for glibc-2.4's abort-inducing bug.
7543
7544         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
7545         Low-probability clean-up should be to use rmdir to get rid of
7546         the just-created directory, not unlink.
7547
7548         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
7549         configure fail, and request a bug report to inform us about it.
7550         Add a comment that, barring reports to the contrary, in 2007 we'll
7551         assume ftruncate is universally available.
7552
7553         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
7554
7555         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
7556
7557         2006-03-12  Jim Meyering  <jim@meyering.net>
7558
7559         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
7560         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
7561         * m4/same.m4 (gl_SAME): Likewise.
7562         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
7563
7564         2006-03-11  Eric Blake  <ebb9@byu.net>
7565
7566         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
7567         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
7568         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
7569         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
7570
7571 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7572
7573         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
7574         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
7575         reported by Mark D. Baushke, one in
7576         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
7577
7578         Merge from coreutils.
7579
7580         * lib/.cppi-disable: Add stdint_.h.
7581         * lib/.cvsignore: Add stdint.h.
7582
7583         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
7584
7585         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
7586         both double and long double versions.
7587         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
7588         * lib/xstrtold.c: New file.
7589         * lib/xstrtod.h (xstrtold): New decl.
7590
7591         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
7592
7593         * lib/filemode.c (setst): Remove.
7594         (strmode): Rewrite to avoid setst.  This makes the code shorter,
7595         (arguably) clearer, and the generated code is a bit smaller on my
7596         Debian GNU/Linux stable x86 host.
7597
7598         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
7599
7600         * lib/filemode.c: Include "filemode.h" first, to test the interface.
7601         Assume that filemode.h includes sys/types.h and sys/stat.h.
7602         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
7603         (ftypelet): Reorder to put common cases first, for efficiency.
7604         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
7605         to do 'M'.
7606         (strmode): Renamed from mode_string, and now stores 12 bytes instead
7607         of 10, for compatibility with FreeBSD.  All callers changed.
7608         (filemodestring): Now stores 12 bytes instead of 10, and sets file
7609         types that can't be deduced solely from st_mode.  First arg is now a
7610         const pointer.
7611         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
7612         (strmode): Renamed from mode_string.
7613         (filemodestring): New decl.
7614         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
7615         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
7616         needed.
7617         (S_ISPORT, S_ISWHT): New macros, if not already defined.
7618
7619         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
7620
7621         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
7622         fsusage.h now does that.  Include fsusage.h first, to test interface.
7623         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
7624         at most one method (the old code could have generated decls that
7625         didn't conform to C89, not that this was ever exercised).
7626         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
7627
7628         2006-03-19  Jim Meyering  <jim@meyering.net>
7629
7630         Work even in a chroot where d_ino values for entries in "/"
7631         don't match the stat.st_ino values for the same names.
7632         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
7633         number, iterate through all entries again, using lstat instead.
7634         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
7635         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
7636
7637         * lib/getcwd.c (__getcwd): Clarify a comment.
7638         Use memcpy in place of a call to strcpy.
7639
7640         2006-03-12  Jim Meyering  <jim@meyering.net>
7641
7642         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
7643         matches that of the current directory (which we're about to chdir ".."
7644         out of), then save the dev-ino of the parent, instead.
7645
7646         * lib/same-inode.h (SAME_INODE): New file/macro.
7647         * lib/chdir-safer.c (SAME_INODE): Remove definition.
7648         Include "same-inode.h", instead.
7649         * lib/same.c: Likewise.
7650         * lib/cycle-check.h: Include "same-inode.h".
7651         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
7652         * lib/cycle-check.c (SAME_INODE): Remove definition.
7653         * lib/root-dev-ino.h: Include "same-inode.h".
7654
7655         2006-03-11  Eric Blake  <ebb9@byu.net>
7656
7657         * lib/same.c (same_name): s/base_name/last_component/
7658         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
7659         * lib/filenamecat.c (file_name_concat): Likewise.
7660
7661         2006-03-11  Eric Blake  <ebb9@byu.net>,
7662                     Paul Eggert  <eggert@cs.ucla.edu>
7663
7664         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
7665         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
7666         drive prefix.
7667         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
7668         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
7669         (last_component): New method.
7670         * lib/dirname.c (dir_len): Determine when drive letters need a
7671         subsequent slash.  Preserve // when it is special.
7672         (dir_name): Don't append dot when drive letter is absolute.
7673         [TEST_DIRNAME]: Move into a full-blown gnulib test.
7674         * lib/basename.c (base_name): New semantics - malloc the result.
7675         Preserve // when it is special.  Preserve relative files that look
7676         like drive letters.
7677         (base_len): Preserve // when it is special.
7678         (last_component): New method, similar to old base_name semantics.
7679         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
7680         base_name.  Strip redundant slashes from ///.
7681
7682 2006-07-03  Jim Meyering  <jim@meyering.net>
7683
7684         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
7685         macro is used before the first cycle_check call.
7686
7687 2006-07-03  Eric Blake  <ebb9@byu.net>
7688
7689         * modules/dirname (Depends-on): Add xstrndup.
7690
7691 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
7692
7693         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
7694         test cases, so that config.log is a bit easier to follow.
7695
7696 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
7697
7698         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
7699         both are 64 bits, since this seems to be the tradition, and this
7700         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
7701         we ever run into a host that prefers long long to long in this
7702         case, we'll need another configure-time test.  Problem reported by
7703         Jim Meyering.
7704
7705 2006-07-02  Eric Blake  <ebb9@byu.net>
7706
7707         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
7708
7709 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7710
7711         * modules/inttypes (Depends-on): No longer depends on stdint.
7712         * modules/stdint (Description): Say more about assumptions.
7713         Say that the fast types might differ.  Say macros are used.
7714         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
7715         (Makefile.am): Revise list of substituted symbols to match
7716         new stdint.m4.
7717         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
7718         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
7719         * tests/test-stdint.c (verify_same_types)
7720         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
7721         the code conforms to C99/C89.
7722         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
7723         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
7724
7725 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7726
7727         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
7728         but fix a bug, by requiring at least 64 bits.
7729         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
7730         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
7731         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
7732         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
7733
7734         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
7735         changes.  Make 2.59 a prerequisite.  Check and substitute for
7736         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
7737         inttypes.h.  Do not use special include files; just use the
7738         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
7739         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
7740         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
7741         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
7742         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
7743         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
7744         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
7745         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
7746         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
7747         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
7748         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
7749         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
7750         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
7751         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
7752         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
7753         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
7754         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
7755         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
7756         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
7757         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
7758         WINT_MAX.  Check for C99 conformance more strictly, by detecting
7759         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
7760         not check for things that C99 does not require, e.g., int8_t.  If
7761         a test isn't needed unless <stdint.h> isn't working, and is
7762         unlikely to be needed for any other reason, then don't do it
7763         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
7764         size_t, since we assume C89 freestanding at least.  Do not check
7765         for sig_atomic_t, wchar_t, or wint_t, since the code now does
7766         the right thing even if the types are not defined.  Instead use:
7767         (gl_STDINT_TYPE_PROPERTIES): New macro.
7768         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
7769         testing whether <sys/types.h> clashes, as Autoconf does this for
7770         us now.  All uses removed.
7771         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
7772         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
7773         (gl_CHECK_TYPE_SAME):
7774         Remove; no longer needed.
7775         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
7776         exists, since we'll return 0 anyway in that case.
7777         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
7778
7779 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7780
7781         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
7782         possible collision with system files.
7783         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
7784         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
7785         WCHAR_MIN and WCHAR_MAX in this case.
7786         (<stddef.h>): Do not include; no longer needed.
7787         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
7788         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
7789         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
7790         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
7791         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
7792         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
7793         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
7794         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
7795         !defined(__c99))]: Include in this case too, since it's harmless
7796         now.
7797         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
7798         dangerous to do so.
7799         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
7800         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
7801         (_STDINT_MIN, _STDINT_MAX): New macros.
7802         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
7803         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
7804         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
7805         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
7806         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
7807         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
7808         macros, not typedefs; this simplifies things quite a bit.
7809         Use long int for all types narrower than int64_t.
7810         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
7811         Define in terms of long long int or int64_t or long int,
7812         not int64_t or int32_t.  This saves some compile-time testing.
7813         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
7814         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
7815         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
7816         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
7817         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
7818         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
7819         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
7820         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
7821         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
7822         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
7823         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
7824         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
7825         undef any previous version and define our own version, for
7826         simplicity and consistency with the new macros for types.
7827         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
7828         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
7829         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
7830         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
7831         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
7832         @WINT_T_SUFFIX@ to keep things simple here.
7833         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
7834         Simplify by assuming typical 8/16/32/64 host, since we're
7835         already doing that elsewhere anyway.
7836         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
7837         and assume long long int is 64 bits if available.  This
7838         speeds up 'configure'.
7839
7840 2006-07-01  Eric Blake  <ebb9@byu.net>
7841
7842         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
7843         Reported by Andreas Buening.
7844
7845 2006-07-01  Eric Blake  <ebb9@byu.net>
7846
7847         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
7848
7849 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
7850
7851         * lib/getaddrinfo.c: fixed typo
7852
7853 2006-06-29  Jim Meyering  <jim@meyering.net>
7854
7855         * modules/strftime (Maintainer): Add my name, since with the
7856         FPRINTFTIME changes strftime.c has forked from glibc.
7857
7858 2006-06-29  Eric Blake  <ebb9@byu.net>
7859
7860         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
7861
7862 2006-06-29  Eric Blake  <ebb9@byu.net>
7863
7864         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
7865
7866 2006-06-29  Eric Blake  <ebb9@byu.net>
7867
7868         * lib/stat_.h: New file.
7869
7870 2006-06-29  Eric Blake  <ebb9@byu.net>
7871
7872         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
7873         unused static function.
7874
7875 2006-06-29  Eric Blake  <ebb9@byu.net>
7876
7877         * doc/functions.texi (Function Portability): Document missing lstat
7878         on mingw.
7879
7880 2006-06-29  Eric Blake  <ebb9@byu.net>
7881
7882         * MODULES.html.sh: Add sys_stat.
7883         * modules/sys_stat: New module.
7884         * modules/mkstemp (Depends-on): Add sys_stat.
7885
7886 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7887
7888         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
7889
7890 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7891
7892         * m4/c-bs-a.m4: Removed.
7893
7894 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7895
7896         * lib/strftime.c: Assume strftime() exists.
7897
7898 2006-06-29  Derek Price  <derek@ximbiot.com>
7899
7900         * modules/c-bs-a: Removed - \a is C89.
7901         * MODULES.html.sh: Remove c-bs-a.
7902
7903 2006-06-29  Bruno Haible  <bruno@clisp.org>
7904
7905         * modules/wcwidth (License): Change to LGPL.
7906
7907 2006-06-28  Simon Josefsson  <jas@extundo.com>
7908
7909         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
7910         on _WIN32.
7911
7912         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
7913         getnameinfo.
7914
7915 2006-06-28  Simon Josefsson  <jas@extundo.com>
7916
7917         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
7918
7919 2006-06-28  Simon Josefsson  <jas@extundo.com>
7920
7921         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
7922         functions there.  It will succeed on Windows XP, but on Windows
7923         2000 and (presumably) earlier, it will fail, and use the internal
7924         re-implementation.
7925         (use_win32_p): New function.
7926         (getaddrinfo): Use strtoul on servname, to support numeric ports.
7927         Support AI_NUMERICSERV to disable getservbyname.
7928         (getnameinfo): New function, only supports
7929         NI_NUMERICHOST|NI_NUMERICSERV for now.
7930
7931         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
7932         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
7933         getnameinfo.
7934
7935 2006-06-28  Eric Blake  <ebb9@byu.net>
7936
7937         * modules/wcwidth: New file.
7938         * modules/mbchar (Depends-on): Add wcwidth.
7939         * modules/mbswidth (Depends-on): Add wcwidth.
7940         * MODULES.html.sh: Add wcwidth.
7941
7942 2006-06-28  Eric Blake  <ebb9@byu.net>
7943
7944         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
7945         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
7946
7947 2006-06-28  Eric Blake  <ebb9@byu.net>
7948
7949         * lib/xvasprintf.h: Fix comments.
7950
7951 2006-06-28  Eric Blake  <ebb9@byu.net>
7952
7953         * lib/mbchar.h (wcwidth): Include wcwidth.h.
7954         * lib/mbswidth.c (wcwidth): Move from here...
7955         * lib/wcwidth.h: ...to this new file.
7956
7957 2006-06-28  Derek R. Price  <derek@ximbiot.com>
7958
7959         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
7960
7961         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
7962         it's obsolete.
7963         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
7964
7965 2006-06-28  Derek R. Price  <derek@ximbiot.com>
7966
7967         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
7968         Autoconf 2.60 says this stuff was obsolete.
7969
7970 2006-06-28  Bruno Haible  <bruno@clisp.org>
7971
7972         * modules/wcwidth (Files): Add m4/wchar_t.m4.
7973
7974 2006-06-28  Bruno Haible  <bruno@clisp.org>
7975
7976         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
7977         gt_TYPE_WCHAR_T.
7978
7979 2006-06-28  Bruno Haible  <bruno@clisp.org>
7980
7981         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
7982         declaration for wcwidth.
7983         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
7984
7985 2006-06-28  Bruno Haible  <bruno@clisp.org>
7986
7987         * lib/mkdtemp.c [MINGW]: Include <io.h>.
7988         (mkdir): Define using _mkdir.
7989
7990 2006-06-28  Bruno Haible  <bruno@clisp.org>
7991
7992         * lib/getaddrinfo.h: Fix POSIX URL.
7993         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
7994         _WIN32.
7995         (use_win32_p): Make static.
7996         (getaddrinfo): Reject service name if it is empty or does not consist
7997         solely of decimal digits, or if its value is > 65535.
7998         (getnameinfo): Remove useless casts.
7999
8000 2006-06-27  Simon Josefsson  <jas@extundo.com>
8001
8002         * modules/sys_select: New file, suggested by Bruno Haible, Paul
8003         Eggert and Martin Lambers.
8004
8005 2006-06-27  Simon Josefsson  <jas@extundo.com>
8006
8007         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
8008         Eggert and Martin Lambers.
8009
8010 2006-06-27  Bruno Haible  <bruno@clisp.org>
8011
8012         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
8013         result to 0, not to empty.
8014         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
8015
8016 2006-06-27  Bruno Haible  <bruno@clisp.org>
8017
8018         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
8019
8020 2006-06-26  Simon Josefsson  <jas@extundo.com>
8021
8022         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
8023         present.
8024
8025 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
8026
8027         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
8028         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
8029         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
8030
8031 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
8032
8033         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
8034
8035 2006-06-26  Bruno Haible  <bruno@clisp.org>
8036
8037         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
8038
8039 2006-06-26  Bruno Haible  <bruno@clisp.org>
8040
8041         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
8042
8043 2006-06-26  Bruno Haible  <bruno@clisp.org>
8044
8045         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
8046         SGI C compiler in pre-C99 mode.
8047         Suggested by Mark D. Baushke and Larry Jones.
8048
8049 2006-06-26  Bruno Haible  <bruno@clisp.org>
8050
8051         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
8052         WCHAR_MAX.
8053         Reported by Mark D. Baushke and Larry Jones.
8054
8055 2006-06-26  Bruno Haible  <bruno@clisp.org>
8056
8057         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
8058         in pre-C99 mode.
8059         Suggested by Mark D. Baushke and Larry Jones.
8060
8061 2006-06-23  Simon Josefsson  <jas@extundo.com>
8062             Bruno Haible  <bruno@clisp.org>
8063
8064         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
8065         Emit mostlyclean-local rule.
8066         (func_emit_tests_Makefile_am): Likewise.
8067         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
8068
8069 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
8070
8071         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
8072
8073 2006-06-23  Bruno Haible  <bruno@clisp.org>
8074
8075         * tests/test-stdint.c: Update to match ISO C 99 Technical
8076         Corrigendum 1.
8077
8078 2006-06-23  Bruno Haible  <bruno@clisp.org>
8079
8080         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
8081
8082 2006-06-23  Bruno Haible  <bruno@clisp.org>
8083
8084         * lib/stdint_.h: Treat IRIX like OpenBSD.
8085
8086 2006-06-23  Bruno Haible  <bruno@clisp.org>
8087
8088         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
8089         ISO C 99 Technical Corrigendum 1.
8090
8091 2006-06-22  Simon Josefsson  <jas@extundo.com>
8092
8093         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
8094         MinGW.
8095
8096 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
8097
8098         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
8099         needed.  Some compiler complained about some of them.  Problem reported
8100         by Larry Jones in
8101         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
8102
8103 2006-06-21  Simon Josefsson  <jas@extundo.com>
8104
8105         * tests/test-getaddrinfo.c: New file.
8106
8107         * modules/getaddrinfo-tests: New file.
8108
8109         * MODULES.html.sh: Add inet_pton.
8110
8111         * modules/inet_pton: New file.
8112
8113 2006-06-21  Simon Josefsson  <jas@extundo.com>
8114
8115         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
8116         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
8117         of using the (limited) gnulib implementation on Windows XP.
8118
8119         * m4/inet_pton.m4: New file.
8120
8121 2006-06-21  Simon Josefsson  <jas@extundo.com>
8122
8123         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
8124         variable.
8125
8126         * lib/socket_.h: Don't define WINVER.
8127
8128         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
8129         slightly modified to work in gnulib.
8130
8131 2006-06-21  Simon Josefsson  <jas@extundo.com>
8132
8133         * doc/gnulib.texi (Windows sockets): Add.
8134
8135 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
8136
8137         * lib/read-file.c (fread_file): Start with buffer allocation of
8138         0 bytes rather than 1 byte; this simplifies the code.
8139         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
8140         code to free buffer and save/restore errno.
8141         (internal_read_file): Remove unused local.
8142
8143 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
8144
8145         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
8146         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
8147         Problem reported by Denis Excoffier in
8148         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
8149
8150 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8151
8152         * modules/sys_socket, modules/socklen: Include sys/types since
8153         FreeBSD 4.x's sys/socket.h needs it.
8154
8155 2006-06-19  Simon Josefsson  <jas@extundo.com>
8156
8157         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
8158
8159 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
8160
8161         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
8162
8163 2006-06-19  Bruno Haible  <bruno@clisp.org>
8164
8165         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
8166         and FULL_PATH_INTTYPES_H in angle brackets.
8167         Reported by Mark D. Baushke <mdb@gnu.org>.
8168
8169 2006-06-17  Eric Blake  <ebb9@byu.net>
8170
8171         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
8172         errno.
8173
8174 2006-06-17  Bruno Haible  <bruno@clisp.org>
8175
8176         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
8177         <sys/inttypes.h>.
8178
8179 2006-06-17  Bruno Haible  <bruno@clisp.org>
8180
8181         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
8182         whether errno is declared. Assume <errno.h> declares errno.
8183
8184 2006-06-17  Bruno Haible  <bruno@clisp.org>
8185
8186         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
8187
8188 2006-06-17  Bruno Haible  <bruno@clisp.org>
8189
8190         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
8191         problem on Solaris 2.5.1.
8192
8193 2006-06-16  Eric Blake  <ebb9@byu.net>
8194
8195         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
8196         * lib/unicodeio.c [!defined errno]: Likewise.
8197         * lib/strtol.c [!defined errno]: Likewise.
8198         * lib/strtod.c [!defined errno]: Likewise.
8199
8200 2006-06-15  Eric Blake  <ebb9@byu.net>
8201
8202         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
8203
8204 2006-06-15  Eric Blake  <ebb9@byu.net>
8205
8206         * config/srclist.txt (ssize_t.m4): Lose sync.
8207
8208 2006-06-15  Bruno Haible  <bruno@clisp.org>
8209
8210         * modules/stdint (Files): Include m4/full-header-path.m4,
8211         m4/size_max.m4, m4/wchar_t.m4.
8212         (Makefile.am): Many more substitutions.
8213         * modules/stdint-tests: New file.
8214         * tests/test-stdint.c: New file.
8215
8216 2006-06-15  Bruno Haible  <bruno@clisp.org>
8217
8218         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
8219         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
8220         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
8221         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
8222         gl_CHECK_TYPE_SAME): New macros.
8223
8224 2006-06-15  Bruno Haible  <bruno@clisp.org>
8225
8226         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
8227
8228 2006-06-15  Bruno Haible  <bruno@clisp.org>
8229
8230         * lib/stdint_.h: Rewritten to be fully auto-configured.
8231         Fixes bug on HP-UX/IA64.
8232
8233 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
8234
8235         * lib/getdate.y (__attribute__): Don't define if already defined.
8236         Problem reported by Larry Jones.
8237         * lib/utimens.c (__attribute__): Likewise.
8238
8239 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
8240
8241         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
8242         reported by Andreas Schwab.
8243
8244 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8245             Bruno Haible  <bruno@clisp.org>
8246
8247         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
8248         check for the declaration of strnlen and a run test that exposes the
8249         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
8250         rpl_strndup.
8251
8252 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8253             Bruno Haible  <bruno@clisp.org>
8254
8255         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
8256
8257 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8258
8259         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
8260         compile test, for Tru64 4.0D.
8261
8262 2006-05-28  Karl Berry  <karl@gnu.org>
8263
8264         * config/srclist.txt (printf-args.c): lose sync.
8265
8266 2006-05-26  Martin Lambers  <marlam@marlam.de>
8267
8268         * lib/getpass.c: Updates the test for the native W32 API, and adds
8269         missing includes, thus fixing compilation warnings.
8270
8271 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
8272
8273         * lib/exclude.c (exclude_fnmatch): New function.
8274         (excluded_file_name): Call exclude_fnmatch.
8275         * lib/exclude.h (excluded_file_name): New prototype
8276
8277 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
8278
8279         * lib/tempname.c (small_open, large_open): New macros.
8280         (__open, __open64) [!_LIBC]: Remove.
8281         (__gen_tempname): Use small_open and large_open instead of __open
8282         and __open64.  This fixes a portability bug on HP-UX 11.11i
8283         reported by Simon Wing-Tang in
8284         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
8285
8286 2006-05-24  Bruno Haible  <bruno@clisp.org>
8287
8288         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
8289         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
8290         Reported by Thorsten Maerz <torte@netztorte.de> via
8291         Aaron Stone <aaron@serendipity.cx>.
8292
8293 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
8294
8295         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
8296         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
8297         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
8298         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
8299         not really conditional on the cache.
8300         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
8301
8302 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
8303
8304         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
8305         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
8306         (my_usleep): Don't mishandle maximum value.
8307
8308 2006-05-19  Jim Meyering  <jim@meyering.net>
8309
8310         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
8311
8312 2006-05-17  Bruno Haible  <bruno@clisp.org>
8313
8314         Cygwin portability.
8315         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
8316
8317 2006-05-17  Bruno Haible  <bruno@clisp.org>
8318
8319         * lib/stdint_.h: Fix recognition of Cygwin.
8320
8321 2006-05-15  Bruno Haible  <bruno@clisp.org>
8322
8323         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
8324         on libtool patch by Ralf Wildenhues.
8325
8326 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
8327
8328         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
8329         test for C99 conformance; (bool) 0.5 is an integer constant
8330         expression, but (bool) -0.5 is not.  Problem reported by Fedor
8331         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
8332
8333 2006-05-11  Simon Josefsson  <jas@extundo.com>
8334
8335         * m4/xvasprintf.m4: Fix obvious typo.
8336
8337 2006-05-11  Jim Meyering  <jim@meyering.net>
8338
8339         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
8340         James Lemley.
8341
8342 2006-05-10  Simon Josefsson  <jas@extundo.com>
8343
8344         * lib/md4.c: Typo fix, update copyright years.
8345         (K1, K2): Don't use L because it turn computations into 64-bit on
8346         64-bit platforms.
8347
8348 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
8349
8350         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
8351         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
8352         unwanted sign propagation, e.g., on hosts with 64-bit int.
8353         There still are some problems with reeelly weird theoretical hosts
8354         (e.g., 33-bit int) but it's not worth worrying about now.
8355         * lib/sha1.c (rol): Likewise.
8356         (K1, K2, K3, K4): Remove unnecessary L suffix.
8357
8358 2006-05-10  Bruno Haible  <bruno@clisp.org>
8359
8360         * lib/des.c: Cast to avoid warnings.
8361
8362 2006-05-09  Bruno Haible  <bruno@clisp.org>
8363
8364         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
8365         (Depends-on): Depend also on xsize, stdarg.
8366         (configure.ac): Add gl_XVASPRINTF.
8367
8368 2006-05-09  Bruno Haible  <bruno@clisp.org>
8369
8370         * m4/xvasprintf.m4: New file.
8371
8372 2006-05-09  Bruno Haible  <bruno@clisp.org>
8373
8374         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
8375         (EOVERFLOW): Define fallback value.
8376         (xstrcat): New function.
8377         (xvasprintf): Recognize the special case of a string concatenation.
8378
8379 2006-05-08  Eric Blake  <ebb9@byu.net>
8380
8381         * gnulib-tool (func_version): Base copyright year on CVS date.
8382         (func_emit_copyright_notice): New function.
8383         (func_emit_lib_Makefile_am): Use it.
8384         (func_emit_tests_Makefile_am): Likewise.
8385         (func_import): Likewise.
8386
8387 2006-05-08  Bruno Haible  <bruno@clisp.org>
8388
8389         * modules/stdarg: New file.
8390         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
8391
8392 2006-05-08  Bruno Haible  <bruno@clisp.org>
8393
8394         * m4/stdarg.m4: New file, from GNU gettext.
8395
8396 2006-05-08  Bruno Haible  <bruno@clisp.org>
8397
8398         * config/srclist.txt (build-aux/config.rpath): different from latest
8399         release.
8400
8401 2006-05-08  Bruno Haible  <bruno@clisp.org>
8402
8403         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
8404
8405 2006-05-05  Jim Meyering  <jim@meyering.net>
8406
8407         * m4/warning.m4: New file, derived from bison's file by the same name.
8408
8409 2006-05-03  Bruno Haible  <bruno@clisp.org>
8410
8411         * lib/stdint_.h: Shorter URL.
8412         * lib/inttypes.h: Likewise.
8413
8414 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8415
8416         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
8417
8418 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8419
8420         * lib/verify.h: Document the internals better.  Most of this change
8421         was written by Bruno Haible.
8422
8423 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8424
8425         * doc/verify.texi: New file, partly based on a proposal by
8426         Bruno Haible.
8427
8428 2006-05-02  Bruno Haible  <bruno@clisp.org>
8429
8430         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
8431         test from here...
8432         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
8433
8434 2006-04-29  Bruno Haible  <bruno@clisp.org>
8435
8436         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
8437         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
8438
8439 2006-04-29  Bruno Haible  <bruno@clisp.org>
8440
8441         * gnulib-tool: Make --update option actually work.
8442
8443 2006-04-29  Bruno Haible  <bruno@clisp.org>
8444
8445         * doc/gcd.texi: New file.
8446         * doc/gnulib.texi: Include it.
8447
8448 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
8449
8450         * lib/getdate.y (get_date): When adding relative date, start with the
8451         initial time, not with the result of the first mktime call.
8452
8453 2006-04-25  Bruno Haible  <bruno@clisp.org>
8454
8455         * gnulib-tool (func_import): Output the include directives in three
8456         blocks, sorted separately.
8457         Reported by Ben Pfaff <blp@cs.stanford.edu>.
8458
8459 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
8460
8461         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
8462         to define main with arguments, for C++.  Reported by Eric Blake.
8463         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
8464         Prefer 'int main ()' to 'int main (void)', for C++.
8465         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
8466         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
8467         for 'main', for C99 and C++.
8468
8469 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
8470
8471         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
8472         Don't assume that exit status -1 is valid.
8473         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
8474         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
8475         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
8476         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
8477         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
8478         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
8479         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
8480         functions can be used without declaring them, or that you can
8481         exit with status -1.
8482         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
8483
8484 2006-04-24  Karl Berry  <karl@gnu.org>
8485
8486         * config/srclist.txt (longdouble.m4): sync lost.
8487
8488 2006-04-24  Eric Blake  <ebb9@byu.net>
8489
8490         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
8491
8492 2006-04-24  Bruno Haible  <bruno@clisp.org>
8493
8494         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
8495         poll() implementation in AIX.
8496         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8497
8498 2006-04-24  Bruno Haible  <bruno@clisp.org>
8499
8500         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
8501         assigned exactly once.
8502
8503 2006-04-23  Claudio Fontana  <claudio@gnu.org>
8504             Bruno Haible  <bruno@clisp.org>
8505
8506         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
8507         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
8508         for AM_CPPFLAGS.
8509
8510 2006-04-23  Bruno Haible  <bruno@clisp.org>
8511
8512         * modules/copy-file: Depend on unistd.
8513         * modules/execute: Likewise.
8514         * modules/fatal-signal: Likewise.
8515         * modules/findprog: Likewise.
8516         * modules/mkdtemp : Likewise.
8517         * modules/pipe: Likewise.
8518         * modules/wait-process: Likewise.
8519
8520 2006-04-23  Bruno Haible  <bruno@clisp.org>
8521
8522         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
8523         condition was already detected.
8524         Reported by Ben Pfaff <blp@cs.stanford.edu>.
8525
8526 2006-04-23  Bruno Haible  <bruno@clisp.org>
8527
8528         * lib/copy-file.c: Include <unistd.h> unconditionally.
8529         * lib/execute.c: Likewise.
8530         * lib/fatal-signal.c: Likewise.
8531         * lib/findprog.c: Likewise.
8532         * lib/mkdtemp.c: Likewise.
8533         * lib/pipe.h: Likewise.
8534         * lib/pipe.c: Likewise.
8535         * lib/wait-process.h: Likewise.
8536
8537 2006-04-23  Bruno Haible  <bruno@clisp.org>
8538
8539         * gnulib-tool (func_usage): Fix --import description. Document
8540         --update.
8541         (func_import): Create temporary file in a temporary directory, if
8542         --dry-run is specified. Silence errors from 'grep' when there are no
8543         m4 files in $m4dir.
8544         (func_create_testdir): Silence errors from 'grep' when there are no
8545         m4 files in $m4dir.
8546         Reported by Karl Berry <karl@freefriends.org>.
8547
8548 2006-04-20  Bruno Haible  <bruno@clisp.org>
8549
8550         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
8551         one argument, so that the code will be portable to Autoconf 2.60.
8552         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
8553         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
8554         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
8555
8556 2006-04-19  Derek Price  <derek@ximbiot.com>
8557             Eric Blake  <ebb9@byu.net>
8558
8559         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
8560         rather than "/full/path.h".  Update comment to match.  Shorten &
8561         generalize m4_translit call via AS_TR_CPP.
8562
8563 2006-04-19  Derek Price  <derek@ximbiot.com>
8564             Eric Blake  <ebb9@byu.net>
8565
8566         * lib/inttypes.h: Correct grammar in comment.
8567
8568 2006-04-18  Derek Price  <derek@ximbiot.com>
8569             Paul Eggert  <eggert@cs.ucla.edu>
8570
8571         * modules/inttypes: New file.
8572         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
8573
8574 2006-04-18  Derek Price  <derek@ximbiot.com>
8575             Paul Eggert  <eggert@cs.ucla.edu>
8576
8577         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
8578         New files.
8579
8580 2006-04-18  Derek Price  <derek@ximbiot.com>
8581             Paul Eggert  <eggert@cs.ucla.edu>
8582
8583         * lib/inttypes.h: New file.
8584         * lib/strtoimax.c: Assume <inttypes.h>.
8585
8586 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
8587
8588         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
8589         isn't mounted.  Problem reported by Kir Kolyshkin.
8590
8591 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
8592
8593         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
8594         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
8595         Derek R. Price.
8596         * lib/regex.h (RE_DUP_MAX): Update comment to match current
8597         implementation.
8598
8599 2006-04-12  Eric Blake  <ebb9@byu.net>
8600
8601         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
8602         is now done automatically by the corresponding Autoconf macro.
8603
8604 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
8605
8606         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
8607         time_r.h.
8608
8609 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8610
8611         Merge regex changes from libc, removing some of our
8612         POSIX-conformance changes that were rejected and redoing them in a
8613         less-intrusive way.
8614
8615         * lib/regcomp.c (re_compile_internal, init_dfa):
8616         Length arg is now size_t, not Idx.  All uses changed.
8617         (peek_token): Forward decl now says internal_function.
8618         (__re_error_msgid, __re_error_msgid_idx):
8619         Now static rather than extern with attribute_hidden.
8620         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
8621         For some reason libc prefers K&R style defns for external functions.
8622         (regerror) [!defined _LIBC]: Likewise.
8623         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
8624         (seek_collating_symbol_entry, lookup_collation_sequence_value):
8625         (build_range_exp, build_collating_symbol):
8626         Use K&R-style defn.
8627         (re_compile_fastmap): Use '\0' to memset, not 0.
8628         (utf8_sb_map): Make the calculations more obvious.
8629         (init_dfa, parse_bracket_exp, build_charclass_op):
8630         Call calloc and cast result, as glibc does.
8631         (init_word_char, fetch_token, peek_token, peek_token_bracket):
8632         (build_range_exp, build_collating_symbol):
8633         Now internal functions.
8634
8635         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
8636
8637         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
8638         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
8639         Don't depend on VMS; depend on __VMS instead, for POSIX
8640         namespace cleanness.
8641         (regoff_t): Define to ssize_t, not long int.
8642
8643         Remove the REG_ macros named below.  Instead, make the old names
8644         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
8645         __USE_GNU_REGEX.
8646         (REG_BACKSLASH_ESCAPE_IN_LISTS):
8647         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
8648         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
8649         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
8650         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
8651         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
8652         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
8653         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
8654         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
8655         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
8656         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
8657         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
8658         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
8659         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
8660         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
8661         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
8662         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
8663         (REG_NREGS):
8664         Remove.  All uses replaced by the old RE_* names.
8665         (RE_BACKSLASH_ESCAPE_IN_LISTS):
8666         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
8667         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
8668         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
8669         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
8670         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
8671         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
8672         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
8673         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
8674         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
8675         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
8676         Don't bother having these macros be independent of each others'
8677         values, since they no longer exist in the POSIX name space.
8678
8679         Rename the following member names back to their old names,
8680         unless !__USE_GNU_REGEX.  All uses changed back.
8681         (buffer): Renamed from re_buffer.
8682         (allocated): Renamed from re_allocated.
8683         (used): Renamed from re_used.
8684         (syntax): Renamed from re_syntax.
8685         (fastmap): Renamed from re_fastmap.
8686         (translate): Renamed from re_translate.
8687         (can_be_null): Renamed from re_can_be_null.
8688         (regs_allocated): Renamed from re_regs_allocated.
8689         (fastmap_accurate): Renamed from re_fastmap_accurate.
8690         (no_sub): Renamed from re_no_sub.
8691         (not_bol): Renamed from re_not_bol.
8692         (not_eol): Renamed from re_not_eol.
8693         (newline_anchor): Renamed from re_newline_anchor.
8694         (num_regs): Renamed from rm_num_regs.
8695         (start): Renamed from rm_start.
8696         (end): Renamed from rm_end.
8697
8698         (free_state): Move up a bit.
8699
8700         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
8701         #define to be empty.
8702         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
8703         when that is what is intended.
8704         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
8705         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
8706         (MAX): New macro.
8707         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
8708         All uses changed back to re_malloc, etc.  It's now the caller's
8709         responsibility to check for overflow; all callers changed.
8710         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
8711         (re_x2nrealloc): Remove.
8712         (free_state): Remove decl.
8713
8714         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
8715         (re_set_registers, re_exec):
8716         Use K&R-style defn.
8717
8718         2006-01-31  Roland McGrath  <roland@redhat.com>
8719
8720         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
8721         Reported by Mike Frysinger <vapier@gentoo.org>.
8722
8723         2006-01-15  Andreas Jaeger  <aj@suse.de>
8724
8725         [BZ #1950]
8726         * lib/regex_internal.c (re_string_reconstruct): Adjust for
8727         build_wcs_upper_buffer change.
8728         (build_wcs_upper_buffer): Change return type.
8729
8730         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
8731
8732         * lib/regex_internal.h: Include <stdint.h> if available.
8733
8734         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
8735
8736         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
8737
8738         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
8739
8740         * lib/regcomp.c: Adjust for changed secondary hash function.
8741
8742         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
8743
8744         * lib/regex.h: Pretty printing.
8745         Clean up namespace a bit.
8746
8747         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
8748
8749         * lib/regexec.c (update_cur_sifted_state, check_arrival,
8750         check_arrival_add_next_nodes): Avoid using uninitialized variable.
8751
8752         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
8753                     Ulrich Drepper  <drepper@redhat.com>
8754
8755         [BZ #1302]
8756         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
8757         changed.
8758         (bitset_word_t): Renamed from bitset_word.  All uses changed.
8759
8760         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
8761
8762         [BZ #281]
8763         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
8764         * lib/regcomp.c: Remove unnecessary uses of
8765         unsigned RE_TRANSLATE_TYPE.
8766         * lib/regex_internal.h: Likewise.
8767         * lib/regex_internal.c: Likewise.
8768         * lib/regexec.c: Likewise.
8769         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
8770
8771         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
8772
8773         * lib/regexec.c (find_recover_state): Remove unnecessary
8774         initialization.
8775         (transit_state_bkref): Make DFA a const pointer.
8776         (get_subexp): Likewise.
8777         (check_arrival): Likewise.
8778         (update_cur_sifted_state): Likewise.
8779         (re_search_internal): Likewise.
8780         (prune_impossible_nodes): Likewise.
8781         (acquire_init_state_context): Likewise.
8782         (proceed_next_node): Likewise.
8783         (set_regs): Likewise.
8784         (free_fail_stack_return): Likewise.
8785         (check_arrival_expand_ecl): Mark DFA parameter as const.
8786         (check_arrival_expand_ecl_sub): Likewise.
8787         (check_subexp_limits): Likewise.
8788         (sub_epsilon_src_nodes):  Likewise.
8789         (add_epsilon_src_nodes):  Likewise.
8790         (merge_state_array): Likewise.
8791         (update_regs): Likewise.
8792         (build_trtable): Likewise.
8793         (sift_states_backward): Mark MCTX parameter as const.
8794         (build_sifted_states): Likewise.
8795         (update_cur_sifted_state): Likewise.
8796         (sift_states_mkref): Likewise.
8797         (check_arrival_expand_ecl): Mark eclosure as const.
8798         (check_dst_limits_calc_pos_1): Likewise.
8799         * lib/regex_internal.h (re_match_context_t): Make dfa a const
8800         pointer.
8801
8802         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
8803
8804         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
8805         (transit_state_sb): Likewise.
8806         (transit_state_mb): Likewise.
8807         (sift_states_iter_mb): Likewise.
8808         (check_arrival_add_next_nodes): Likewise.
8809         (check_node_accept_bytes): Change first parameter to pointer-to-const.
8810         [_LIBC] (re_search_2_stub): Use mempcpy.
8811
8812         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
8813         mbrtowc for very simple UTF-8 case.
8814
8815         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
8816         a pointer-to-const.
8817         (re_acquire_state_context): Likewise.
8818         * lib/regex_internal.h: Adjust prototypes.
8819
8820         * lib/regex.c: Prevent using C++ compilers.
8821
8822         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
8823         (re_acquire_state_context): Likewise.
8824
8825 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8826
8827         * modules/regex (Depends-on): Add ssize_t.
8828
8829 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8830
8831         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
8832         translation table.
8833
8834 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8835
8836         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
8837
8838 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
8839             Bruno Haible  <bruno@clisp.org>
8840
8841         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
8842         <sys/types.h> and <inttypes.h>.
8843
8844 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8845
8846         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
8847         `__error_t_defined', so argp.h will not typedef the former.
8848
8849 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
8850
8851         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
8852         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
8853         glibc names.  Even if glibc is changed to conform to POSIX, the
8854         traditional names will be available anyway, since regex depends on
8855         the extensions module.  Also, fix a longstanding typo in the
8856         implementation of Spencer ERE test #75 from grep 2.3.  Problems
8857         reported by Emanuele Giaquinta.  Also, change sense of cached
8858         variable, so that the message makes sense.
8859
8860 2006-03-24  Simon Josefsson  <jas@extundo.com>
8861
8862         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
8863         including some doc fixes.
8864         (base64_encode_alloc): Fix +1 bug on allocation failures.
8865
8866 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8867
8868         * lib/base64.c (base64_encode): Do not read past end of array with
8869         unsanitized input on systems with CHAR_BIT > 8.
8870
8871 2006-03-24  Eric Blake  <ebb9@byu.net>
8872
8873         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
8874
8875 2006-03-22  Karl Berry  <karl@gnu.org>
8876
8877         * config/srclist.txt (*setenv.[ch]): get from coreutils.
8878         * config/srclistvars.sh (COREUTILS): new var.
8879
8880 2006-03-17  Jim Meyering  <jim@meyering.net>
8881
8882         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
8883         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
8884
8885 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
8886
8887         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
8888         no longer needs it.  Instead, check that regoff_t is as least
8889         as wide as ptrdiff_t.
8890
8891         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
8892         so that our regex.h stays compatible with the installed regex.
8893         This is helpful for installers who configure --without-included-regex.
8894         Problem reported by Emanuele Giaquinta.
8895
8896 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
8897
8898         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
8899         Typedef to long int, not to off_, as POSIX will likely change
8900         in that direction.
8901
8902 2006-03-15  Eric Blake  <ebb9@byu.net>
8903
8904         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
8905
8906 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
8907
8908         * lib/argp-help.c (validate_uparams): Fix typo
8909         * lib/argp-parse.c (argp_default_options): Consistently begin help
8910         messages with a lowercase letter.
8911
8912 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
8913
8914         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
8915         overrun buffers and shouldn't be used (much as gets shouldn't be
8916         used).
8917         * lib/time_r.c (asctime_r, ctime_r): Likewise.
8918
8919 2006-03-08  Simon Josefsson  <jas@extundo.com>
8920
8921         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
8922         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8923
8924 2006-03-08  Simon Josefsson  <jas@extundo.com>
8925
8926         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
8927         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8928
8929 2006-03-08  Simon Josefsson  <jas@extundo.com>
8930
8931         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
8932         signal that configure disabled the device.
8933
8934 2006-03-08  Simon Josefsson  <jas@extundo.com>
8935
8936         * build-aux/maint.mk: Fix refresh-po, to handle no translated
8937         languages.
8938
8939 2006-03-07  Simon Josefsson  <jas@extundo.com>
8940
8941         * modules/getopt (Depends-on): Add unistd.
8942
8943         * modules/unistd: New file.
8944
8945 2006-03-07  Simon Josefsson  <jas@extundo.com>
8946
8947         * modules/gc-random: New file.
8948
8949 2006-03-07  Simon Josefsson  <jas@extundo.com>
8950
8951         * m4/unistd_h.m4: New file.
8952
8953 2006-03-07  Simon Josefsson  <jas@extundo.com>
8954
8955         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
8956         test to be side-effect free by storing the result in the cache
8957         variable gl_cv_lib_readline, and moving the assignment of
8958         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
8959         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8960
8961 2006-03-07  Simon Josefsson  <jas@extundo.com>
8962
8963         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
8964         error on missing devices (the functions will return an error).
8965
8966         * m4/gc.m4: Move random stuff to gc-random.m4
8967
8968 2006-03-07  Simon Josefsson  <jas@extundo.com>
8969
8970         * lib/unistd_.h: New file.
8971
8972 2006-03-07  Simon Josefsson  <jas@extundo.com>
8973
8974         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
8975
8976 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8977
8978         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
8979         Problem reported by Juan Manuel Guerrero.
8980
8981 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8982
8983         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
8984         the unistd module.
8985         * lib/getlogin_r.c: Likewise.
8986         * lib/getlogin_r.h: Likewise.
8987         * lib/glob.c: Likewise.
8988         * lib/pagealign_alloc.c: Likewise.
8989         * lib/unistd_.h: Remove; no longer needed.
8990
8991 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8992
8993         * MODULES.html.sh (Support for systems lacking POSIX:2001):
8994         Add unistd.
8995         * modules/c-stack (Depends-on): Add unistd.
8996         * modules/getlogin_r: Likewise.
8997         * modules/glob: Likewise.
8998         * modules/pagealign_alloc: Likewise.
8999         * modules/unistd (Files): Remove lib/unistd_.h.
9000         (EXTRA_DIST): Remove.
9001         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
9002         need unistd_.h.
9003         (MOSTLYCLEANFILES): Remove unistd.h-t.
9004
9005 2006-03-03  Simon Josefsson  <jas@extundo.com>
9006
9007         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
9008
9009 2006-03-03  Simon Josefsson  <jas@extundo.com>
9010
9011         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
9012         libidn and bison.
9013
9014 2006-03-03  Simon Josefsson  <jas@extundo.com>
9015
9016         * build-aux/maint.mk: Add indent target.
9017
9018 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
9019
9020         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
9021         our replacement poll.h in any case, to avoid a differing
9022         declaration from a system header.  Seen on AIX.
9023
9024 2006-03-01  Simon Josefsson  <jas@extundo.com>
9025
9026         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
9027         <kasal@ucw.cz>.
9028
9029 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
9030
9031         * modules/gettime (Depends-on): Add extensions module.
9032         * modules/nanosleep (Depends-on): Likewise.
9033         * modules/settime (Depends-on): Likewise.
9034
9035 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
9036
9037         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
9038         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
9039         pedantically.
9040         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
9041         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
9042
9043         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
9044         not "==".  Reported by Ralf Wildenhues.
9045
9046 2006-03-01  Karl Berry  <karl@gnu.org>
9047
9048         * doc/Copyright/request-*: new files, synced from gnuorg.
9049
9050 2006-03-01  Karl Berry  <karl@gnu.org>
9051
9052         * config/srclist.txt (Copyright/*): new entries.
9053
9054 2006-02-28  Simon Josefsson  <jas@extundo.com>
9055
9056         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
9057
9058 2006-02-27  Simon Josefsson  <jas@extundo.com>
9059
9060         * lib/base64.h: Indent #define's.  From Jim Meyering
9061         <jim@meyering.net>.
9062
9063 2006-02-27  Jim Meyering  <jim@meyering.net>
9064
9065         Revert the change of 2006-02-24, so these files can continue
9066         to be sync'd from gettext.
9067         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
9068         of `config.h'.
9069
9070 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
9071
9072         * modules/intprops: New file.
9073         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
9074         Add intprops.
9075         * modules/getloadavg (Files): Remove lib/intprops.h.
9076         (Depends-on): Add intprops.
9077         * modules/human: Likewise.
9078         * modules/inttostr: Likewise.
9079         * modules/openat: Likewise.
9080         * modules/sig2str: Likewise.
9081         * modules/userspec: Likewise.
9082         * modules/utimecmp: Likewise.
9083         * modules/xnanosleep: Likewise.
9084         * modules/xstrtol: Likewise.
9085
9086 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
9087
9088         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
9089         * modules/lock-tests (TESTS): Use $(EXEEXT).
9090         * modules/tls-tests: Likewise.
9091         * modules/argp-tests: Likewise.
9092         (check_PROGRAMS): New var, replacing...
9093         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
9094
9095 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9096
9097         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
9098         `config.h'.
9099
9100 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
9101
9102         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
9103
9104 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9105
9106         Sync from coreutils.
9107         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
9108         gl_CHDIR_SAFER.
9109
9110 2006-02-22  Jim Meyering  <jim@meyering.net>
9111
9112         Sync from coreutils.
9113         * m4/chdir-safer.m4: New file.
9114
9115 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
9116
9117         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
9118         AT_FDCWD exceeds INT_MAX.
9119         * lib/openat.h (AT_FDCWD): Likewise.
9120
9121 2006-02-17  Eric Blake  <address@hidden>
9122
9123         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
9124
9125 2006-02-16  Simon Josefsson  <jas@extundo.com>
9126
9127         * modules/getaddrinfo (Depends-on): Add sys_socket.
9128
9129 2006-02-15  Simon Josefsson  <jas@extundo.com>
9130
9131         * build-aux/maint.mk: Add dsyntax-check rule.
9132
9133 2006-02-15  Eric Blake  <ebb9@byu.net>
9134
9135         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
9136         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
9137         'present but cannot compile' warnings on cygwin.
9138         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
9139         use ws2tcpip.h if sys/socket.h works.
9140         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
9141         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
9142
9143 2006-02-14  Simon Josefsson  <jas@extundo.com>
9144
9145         * modules/maintainer-makefile (Files): Rename.
9146
9147         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
9148         and (the local) Makefile.cfg to maint-cfg.mk.
9149
9150         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
9151         to the latter.
9152
9153         * modules/maintainer-makefile: New module.
9154
9155         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
9156         severaly stripped to make it possible to build it up from scratch
9157         with reliable tests.
9158
9159         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
9160         fixes to permit overriding the default actions when configure and
9161         makefile are not available.
9162
9163 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
9164
9165         Sync from coreutils.
9166         * modules/lstat (Depends-on): Don't depend on xalloc.
9167         (License): Change from GPL to LGPL, since this is now simply a
9168         replacement for a libc function.
9169
9170 2006-02-14  Jim Meyering  <jim@meyering.net>
9171
9172         Sync from coreutils.
9173
9174         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
9175         failure on deficient systems, and simplify gnulib lgpl dependencies.
9176         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
9177         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
9178
9179         * lib/xalloc-die.c: Remove unused definition of N_.
9180
9181 2006-02-14  Jim Meyering  <jim@meyering.net>
9182
9183         Sync from coreutils.
9184         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
9185         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
9186         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
9187         double-quote uses of that variable, to accommodate the rare case in
9188         which getmntent is available in none of the libraries checked.  This
9189         happens at least on FreeBSD 5.0.
9190
9191 2006-02-13  Simon Josefsson  <jas@extundo.com>
9192
9193         * gnulib-tool (Usage): Fix --import, from
9194         karl@freefriends.org (Karl Berry).
9195
9196 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
9197
9198         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
9199
9200 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
9201
9202         * lib/argp-namefrob.h: Restore changes accidentally lost during the
9203         "autoupdate" on 2005-12-12.
9204
9205 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
9206
9207         * modules/closeout (Depends-on): Remove atexit.
9208
9209 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
9210
9211         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
9212         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
9213
9214 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
9215
9216         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
9217         __EXTENSIONS__ if this causes compilation to fail.  Problem
9218         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
9219         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
9220
9221 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
9222
9223         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
9224         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
9225         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
9226         All uses changed.
9227
9228 2006-01-26  Simon Josefsson  <jas@extundo.com>
9229
9230         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
9231         prototype is visible on mingw32.
9232
9233         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
9234         for mingw32.
9235
9236         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
9237         mingw32).
9238
9239 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
9240
9241         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
9242         attempt to open for write; this always fails, at least on POSIX
9243         hosts.  This reinstates the 2006-01-09 change, which was
9244         inadvertently removed.
9245
9246 2006-01-26  Bruno Haible  <bruno@clisp.org>
9247
9248         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
9249         Reported by Paul Eggert.
9250
9251 2006-01-26  Bruno Haible  <bruno@clisp.org>
9252             Paul Eggert  <eggert@cs.ucla.edu>
9253
9254         * lib/stdbool_.h (_Bool)
9255         [(! (defined __cplusplus || defined __BEOS__)
9256           && !defined __GNUC__
9257           && !(defined __HP_cc || defined __xlc__
9258                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
9259                || defined __sgi))]:
9260         #define to signed char in these cases too; this simplifies
9261         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
9262         etc., separately) and makes it more conservative.
9263
9264 2006-01-25  Simon Josefsson  <jas@extundo.com>
9265
9266         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
9267         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
9268         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
9269
9270 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
9271
9272         * lib/argp-namefrob.h: Bugfix. Remove stray #
9273
9274 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
9275
9276         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
9277         so that we test the test.
9278         Check for yet another HP-UX cc bug involving *bool |= bool.
9279
9280 2006-01-25  Karl Berry  <karl@gnu.org>
9281
9282         * config/srclist.txt (vasnprintf.c): sync lost.
9283
9284 2006-01-25  Jim Meyering  <jim@meyering.net>
9285
9286         Sync from the stable (b5) branch of coreutils:
9287
9288         * lib/fts.c (fts_children): Don't let close() clobber errno from
9289         failed fchdir().
9290
9291         * lib/fts.c (fts_stat): When following a symlink-to-directory,
9292         don't necessarily interpret stat-fails+lstat-succeeds as indicating
9293         a dangling symlink.  That can also happen at least for ELOOP.
9294         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
9295         FYI, this bug predates the inclusion of fts.c in coreutils.
9296
9297         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
9298         in their own block, so pre-c99 compilers don't object.
9299
9300         Avoid the double-free (first in fts_read, second in fts_close) that
9301         would occur when an `active' directory is made inaccessible (e.g.,
9302         via chmod a-x) during a traversal.
9303         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
9304         before returning.  Reproduce this failure by
9305         mkdir -p a/b; cd a; chmod a-x . b
9306         Reported by Stavros Passas.
9307
9308 2006-01-25  Jim Meyering  <jim@meyering.net>
9309
9310         * lib/fileblocks.c: Remove more useless parentheses.
9311         * lib/readutmp.h: Likewise.
9312
9313 2006-01-25  Bruno Haible  <bruno@clisp.org>
9314
9315         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
9316         warnings.
9317         Reported by Paul Eggert.
9318
9319 2006-01-25  Bruno Haible  <bruno@clisp.org>
9320
9321         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
9322         rid of a trap command. For Solaris sh.
9323         Reported by Mark D. Baushke <mdb@gnu.org>.
9324
9325 2006-01-24  Simon Josefsson  <jas@extundo.com>
9326
9327         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
9328         Bruno.
9329
9330 2006-01-24  Karl Berry  <karl@gnu.org>
9331
9332         * config/srclist.txt (argp-namefrob.h): sync lost.
9333
9334 2006-01-24  Jim Meyering  <jim@meyering.net>
9335
9336         * modules/openat (Files): Add lib/intprops.h.
9337         From Mark D. Baushke.
9338
9339 2006-01-24  Jim Meyering  <jim@meyering.net>
9340
9341         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
9342         Reported by Mark D. Baushke.
9343
9344 2006-01-24  Jim Meyering  <jim@meyering.net>
9345
9346         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
9347
9348 2006-01-24  Bruno Haible  <bruno@clisp.org>
9349
9350         * modules/strnlen (Maintainer): Change from glibc to all.
9351
9352 2006-01-24  Bruno Haible  <bruno@clisp.org>
9353
9354         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
9355         Patch by Paul Eggert.
9356
9357 2006-01-24  Bruno Haible  <bruno@clisp.org>
9358
9359         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
9360         already has it.
9361         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
9362         2005-11-26.
9363
9364         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
9365         'signed char' to avoid problems with the built-in _Bool type.
9366         Reported by Paul Eggert on 2005-11-26.
9367
9368 2006-01-24  Bruno Haible  <bruno@clisp.org>
9369
9370         * gnulib-tool (func_import): Avoid constructing complicated sed
9371         expressions inside backquote.
9372         Report and solution by Mark D. Baushke <mdb@gnu.org>.
9373
9374 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
9375
9376         These changes imported from libc.
9377         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
9378         test and two separate function calls.
9379         * lib/strndup.c (__strndup): Add libc_hidden_def.
9380
9381 2006-01-23  Simon Josefsson  <jas@extundo.com>
9382
9383         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
9384         Remove the test_*_SOURCES variable: automake infers it by default.
9385         * modules/tls-tests: Likewise.
9386
9387 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9388
9389         Work around porting bugs reported by Dieter in
9390         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
9391         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
9392         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
9393         Include "getopt.h" first, to check interface.
9394         (getenv): Declare only if defined HAVE_DECL_GETENV &&
9395         !HAVE_DECL_GETENV.
9396         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
9397         (__strndup): Revert to K&R-style function dfns, the glibc style.
9398         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
9399         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
9400         Include strnlen.h first, to get prototype properly.
9401         (strnlen): Renamed from __strnlen.
9402         Remove weak alias.
9403
9404 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9405
9406         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
9407
9408 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9409
9410         * config/srclist.txt: Adjust to reflect glibc reorganization.
9411         This affects only comments.
9412
9413 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
9414
9415          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
9416          Reported by Bruce Korb <bkorb@gnu.org>.
9417
9418 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
9419
9420         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
9421         to pacify gcc -Wswitch-default.
9422
9423 2006-01-22  Bruno Haible  <bruno@clisp.org>
9424
9425         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
9426         temporary buffer for sprintf, take into account the precision also
9427         for 'd', 'i', 'u', 'o', 'x', 'X'.
9428
9429 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
9430
9431         * modules/argp-tests: New module
9432         * tests/test-argp.c: New file
9433         * tests/test-argp-2.sh: New file
9434
9435 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
9436
9437         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
9438         (__argp_base_name): Removed
9439         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
9440         typo.
9441         (__argp_base_name): Provide macro definition or extern declaration
9442         depending on the configuration
9443
9444 2006-01-20  Simon Josefsson  <jas@extundo.com>
9445
9446         * modules/inet_ntop (Depends-on): Depend on sys_socket.
9447
9448 2006-01-20  Simon Josefsson  <jas@extundo.com>
9449
9450         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
9451
9452 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
9453
9454         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
9455         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
9456         Suggested by Bruno Haible.
9457
9458 2006-01-20  Karl Berry  <karl@gnu.org>
9459
9460         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
9461         until changes propagate, I guess.
9462
9463 2006-01-19  Simon Josefsson  <jas@extundo.com>
9464
9465         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
9466
9467 2006-01-19  Simon Josefsson  <jas@extundo.com>
9468
9469         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
9470
9471 2006-01-19  Simon Josefsson  <jas@extundo.com>
9472
9473         * gnulib-tool: Set check_PROGRAMS.
9474
9475         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
9476         modules/des-tests, modules/gc-arcfour-tests,
9477         modules/gc-arctwo-tests, modules/gc-des-tests,
9478         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
9479         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
9480         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
9481         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
9482         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
9483         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
9484         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
9485         test_*_SOURCES.
9486
9487 2006-01-18  Simon Josefsson  <jas@extundo.com>
9488
9489         * modules/socklen (Depends-on): Depend on sys_socket.
9490
9491 2006-01-18  Simon Josefsson  <jas@extundo.com>
9492
9493         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
9494         modules/des-tests, modules/gc-arcfour-tests,
9495         modules/gc-arctwo-tests, modules/gc-des-tests,
9496         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
9497         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
9498         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
9499         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
9500         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
9501         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
9502         $(EXEEXT) to automake TESTS variable, for mingw32.
9503
9504 2006-01-17  Simon Josefsson  <jas@extundo.com>
9505
9506         * modules/socklen (Include): Need sys/socket.h.
9507
9508 2006-01-17  Bruno Haible  <bruno@clisp.org>
9509
9510         * modules/ssize_t (Include): Add <sys/types.h>.
9511
9512 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
9513
9514         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
9515         it's not portable and it doesn't work with cross-compiles.
9516         Problem reported by Bruno Haible.  Fix missing-$ typo in
9517         'test "gl_cv_ignore_unused_libraries" ...' that prevented
9518         -zignore from being used with Sun's C compiler.
9519
9520 2006-01-12  Simon Josefsson  <jas@extundo.com>
9521
9522         * lib/base64.c: Fix warning, reported by Bruno Haible
9523         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
9524
9525 2006-01-12  Bruno Haible  <bruno@clisp.org>
9526
9527         * modules/ldd: New file.
9528         * build-aux/ldd.sh.in: New file.
9529         * MODULES.html.sh (Support for building libraries and executables): Add
9530         ldd.
9531
9532 2006-01-12  Bruno Haible  <bruno@clisp.org>
9533
9534         * m4/ldd.m4: New file.
9535
9536 2006-01-12  Bruno Haible  <bruno@clisp.org>
9537
9538         * gnulib-tool (func_import, func_create_testdir): Don't go into an
9539         endless loop while replacing $auxdir with build-aux.
9540
9541 2006-01-11  Simon Josefsson  <jas@extundo.com>
9542
9543         * lib/stdint_.h (SIZE_MAX): Add missing (.
9544
9545 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
9546
9547         Sync from coreutils.
9548         * lib/md5.c: Fix commentary typos.
9549         (alignof, UNALIGNED_P): No need for a GCC-specific version.
9550         * lib/md5.h (__attribute__): Remove; unused.
9551         * lib/sha1.c: Fix commentary to match md5 better.
9552         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
9553         so that we don't need to worry about alignment.  All uses changed.
9554         This merges the 2005-10-28 md5 change into sha1.
9555
9556 2006-01-11  Jim Meyering  <jim@meyering.net>
9557
9558         Sync from coreutils.
9559         * lib/md5.c (OP): Fix spacing.
9560
9561 2006-01-11  Bruno Haible  <bruno@clisp.org>
9562
9563         Ensure automatic ordering between gl_LOCK and gl_ARGP.
9564         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
9565         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
9566
9567 2006-01-11  Bruno Haible  <bruno@clisp.org>
9568
9569         Ensure automatic ordering between gl_LOCK and gl_ARGP.
9570         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
9571         the "early" section as well.
9572
9573 2006-01-11  Bruno Haible  <bruno@clisp.org>
9574
9575         Avoid "ar: no archive members specified" error on MacOS X.
9576         * gnulib-tool (func_modules_add_dummy): New function.
9577         (func_import, func_create_testdir): Invoke it.
9578
9579 2006-01-11  Bruno Haible  <bruno@clisp.org>
9580
9581         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
9582         with $auxdir in AC_CONFIG_FILES statements.
9583
9584 2006-01-11  Bruno Haible  <bruno@clisp.org>
9585
9586         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9587         Initialize also noinst_HEADERS to empty.
9588
9589 2006-01-11  Bruno Haible  <bruno@clisp.org>
9590
9591         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
9592         variables.
9593         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
9594         autoreconf.
9595
9596 2006-01-11  Bruno Haible  <bruno@clisp.org>
9597
9598         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
9599         overridable by the user.
9600         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9601
9602 2006-01-10  Simon Josefsson  <jas@extundo.com>
9603
9604         * modules/sys_socket: New file.
9605
9606 2006-01-10  Simon Josefsson  <jas@extundo.com>
9607
9608         * m4/sys_socket_h.m4: New file.
9609
9610 2006-01-10  Simon Josefsson  <jas@extundo.com>
9611
9612         * lib/socket_.h: New file.
9613
9614 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9615
9616         * modules/readutmp (Maintainer): Add myself.
9617
9618 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9619
9620         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
9621         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
9622         People who are still concerned with buggy memcmp implementations
9623         can invoke gl_FUNC_MEMCMP themselves.
9624
9625 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9626
9627         * lib/regex_internal.h (BITSET_WORD_BITS):
9628         Work around a bug in 64-bit PGC (before version 6.1-2), where the
9629         preprocessor mishandles large unsigned values as if they were signed.
9630         Problem reported by Claudio Fontana in
9631         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
9632
9633 2006-01-10  Jim Meyering  <jim@meyering.net>
9634
9635         Avoid the double-free (first in fts_read, second in fts_close) that
9636         would occur when an `active' directory is made inaccessible (e.g.,
9637         via chmod a-x) during a traversal.
9638         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
9639         before returning.  Reproduce this failure by
9640         mkdir -p a/b; cd a; chmod a-x . b
9641         Reported by Stavros Passas.
9642
9643         Sync from coreutils.
9644         * lib/sha1.c: Tweak grammar in a comment.
9645
9646 2006-01-10  Jim Meyering  <jim@meyering.net>
9647
9648         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
9649         Patch by Joerg Sonnenberger.
9650
9651 2006-01-10  Bruno Haible  <bruno@clisp.org>
9652
9653         * modules/readutmp: Depend on module free.
9654         * modules/strtok_r: Depend on module restrict.
9655
9656 2006-01-10  Bruno Haible  <bruno@clisp.org>
9657
9658         * modules/gettext (configure.ac): Add an invocation of
9659         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
9660
9661 2006-01-10  Bruno Haible  <bruno@clisp.org>
9662
9663         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
9664         Reported by Werner Lemberg <wl@gnu.org>.
9665
9666 2006-01-10  Bruno Haible  <bruno@clisp.org>
9667
9668         * lib/localcharset.c: Update from GNU gettext.
9669
9670 2006-01-10  Bruno Haible  <bruno@clisp.org>
9671
9672         * lib/argp.h (__const): Remove macro. Use const instead.
9673         * lib/argp-fmtstream.h (__const): Likewise.
9674         * lib/glob_.h (__const): Remove macro.
9675         * lib/glob-libc.h: Use const instead of __const.
9676
9677 2006-01-10  Bruno Haible  <bruno@clisp.org>
9678
9679         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
9680         variable.
9681         Needed to avoid an automake error regarding the 'gettext' module.
9682
9683 2006-01-09  Simon Josefsson  <jas@extundo.com>
9684
9685         * modules/inet_ntop (Depends-on): Add restrict.
9686
9687 2006-01-09  Simon Josefsson  <jas@extundo.com>
9688
9689         * modules/gc-rijndael-tests (License): Put under LGPL.
9690
9691         * modules/gc-des-tests (License): Likewise.
9692
9693         * modules/gc-arcfour-tests (License): Likewise.
9694
9695         * modules/gc-arctwo-tests (License): Likewise.
9696
9697         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
9698
9699         * modules/gc-hmac-sha1-tests (Files): Likewise.
9700
9701         * modules/gc-hmac-md5-tests (License): Likewise.
9702
9703         * modules/gc-sha1-tests (License): Likewise.
9704
9705         * modules/gc-md5-tests (License): Likewise.
9706
9707         * modules/gc-md4-tests (License): Likewise.
9708
9709         * modules/gc-md2-tests (License): Likewise.
9710
9711         * modules/gc-tests (License): Likewise.
9712
9713         * modules/des-tests (License): Likewise.
9714
9715         * modules/md4-tests (License): Likewise.
9716
9717         * modules/md2-tests (License): Likewise.
9718
9719 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9720
9721         Sync from coreutils:
9722
9723         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
9724         * modules/lib-ignore: New file.
9725         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
9726         chdir-safer.m4, lchmod.m4.
9727         * modules/openat: Add mkdirat.c, openat-priv.h.
9728
9729 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9730
9731         Sync from coreutils.
9732         * m4/lib-ignore.m4: New file.
9733         * m4/lchmod.m4: New file.
9734
9735 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9736
9737         Sync from coreutils.
9738         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
9739         for write access: POSIX says that must fail.
9740         * lib/fts.c (diropen): Likewise.
9741         * lib/save-cwd.c (save_cwd): Likewise.
9742         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
9743         well, for minor improvements on hosts that lack O_DIRECTORY.
9744         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
9745         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
9746         Fall back on chown if open failed with EACCES.
9747
9748         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
9749         Report an error at compile-time if only a 1-second nominal clock
9750         resolution is found.
9751
9752         * lib/lchmod.h: New file.
9753         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
9754         (make_dir_parents): Use lchown rather than chown, and
9755         lchmod rather than chmod.
9756
9757         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
9758         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
9759         "proc" reported by n0dalus.
9760
9761         * lib/mountlist.c: Include <limits.h>.
9762         (dev_from_mount_options)
9763         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
9764         New function.  It no longer assumes "dev=" has the System V meaning
9765         on Linux (since it doesn't).  It also parses "dev=" more carefully.
9766         (read_file_system_list)
9767         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
9768         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
9769         dev= in that case.
9770
9771         * lib/posixtm.h (PDS_PRE_2000): New macro.
9772         * lib/posixtm.c (year): Arg is now syntax_bits rather than
9773         allow_century.  All usages changed.  Reject dates outside the range
9774         1969-1999 if PDS_PRE_2000 is used.
9775
9776 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9777
9778         Sync from coreutils.
9779         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
9780         (Time of day items): Mention the possibility of leap seconds.
9781         Problem reported by Dr. David Alan Gilbert.
9782
9783 2006-01-09  Jim Meyering  <jim@meyering.net>
9784
9785         Sync from coreutils.
9786
9787         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
9788
9789         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
9790
9791         * lib/modechange.c (mode_compile): Reject an invalid mode string
9792         that starts with an octal digit.  From Andreas Gruenbacher.
9793
9794         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
9795         and dup to open_safer and dup_safer, respectively.
9796         (openat_permissive): Fix typo in comment.
9797
9798         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
9799         "gettext.h"; either no longer needed or are guaranteed by openat.h.
9800         (_): Remove; no longer needed.
9801         (openat): Renamed from rpl_openat; no need for rpl_openat
9802         since openat.h renames openat for us.
9803         Replace most of the body with a call to openat_permissive,
9804         to avoid duplicate code.
9805         Port to (probably hypothetical) environments were mode_t is
9806         wider than int.
9807         (openat_permissive): Require mode arg, so that we can check
9808         types better.  Put it just after flags.  Change cwd failure
9809         indicator from pointer-to-bool to pointer-to-errno-value.
9810         All callers changed.
9811         Invoke openat_save_fail and/or openat_restore_fail if
9812         cwd_errno is null, so that openat can call us.
9813         (openat_permissive, fdopendir, fstatat, unlinkat):
9814         Simplify errno handling to avoid some duplicate code,
9815         as it's OK to set errno on success.
9816         * lib/openat.h: Revamp code so that function macros depend on
9817         __OPENAT_PREFIX only, not also on AT_FDCWD.
9818         (openat_ro): Remove.  Caller changed to use openat_permissive.
9819         (openat_permissive): Now a macro, if not a function.
9820         (openat_restore_fail, openat_save_fail): Now always functions,
9821         since mkdirat needs them even if __OPENAT_PREFIX is defined.
9822
9823         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
9824         and openat.c.
9825         * lib/mkdirat.c: Include openat-priv.h.
9826         Remove definitions of macros defined therein.
9827         * lib/openat.c: Likewise.
9828
9829         * lib/mkdirat.c (mkdirat): New file and function.
9830         * lib/openat.h (mkdirat): Declare.
9831
9832         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
9833
9834         * lib/openat.h (openat_permissive): Declare.
9835         (openat_ro): Define.
9836
9837         * lib/openat.c (EXPECTED_ERRNO): New macro.
9838         (openat_permissive): New function -- used in remove.c rewrite.
9839         (all functions): Set errno just before returning, only if there
9840         was an actual failure.
9841         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
9842
9843         Emulate openat-family functions using Linux's procfs, if possible.
9844         Idea and some code based on Ulrich Drepper's glibc changes.
9845
9846         * lib/openat.c: (BUILD_PROC_NAME): New macro.
9847         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
9848         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
9849         before falling back on save_cwd and restore_cwd.
9850         (fdopendir, fstatat, unlinkat): Likewise.
9851
9852         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
9853         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
9854
9855         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
9856         as second argument to va_arg.  Otherwise, some versions of gcc
9857         warn that `if this code is reached, the program will abort'.
9858
9859 2006-01-09  Jim Meyering  <jim@meyering.net>
9860
9861         Sync from coreutils.
9862         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
9863         Require openat-priv.h.
9864
9865 2006-01-09  Bruno Haible  <bruno@clisp.org>
9866
9867         * modules/strnlen (Include): Use strnlen.h.
9868
9869 2006-01-09  Bruno Haible  <bruno@clisp.org>
9870
9871         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
9872
9873 2006-01-09  Bruno Haible  <bruno@clisp.org>
9874
9875         * lib/sysexit_.h (EX_OK): New macro.
9876         Suggested by Martin Lambers <marlam@marlam.de>.
9877
9878 2006-01-09  Bruno Haible  <bruno@clisp.org>
9879
9880         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
9881         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
9882
9883 2006-01-09  Bruno Haible  <bruno@clisp.org>
9884
9885         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
9886         numbers.
9887
9888 2006-01-09  Bruno Haible  <bruno@clisp.org>
9889
9890         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
9891         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
9892         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
9893         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
9894
9895 2006-01-09  Bruno Haible  <bruno@clisp.org>
9896
9897         * build-aux/javacomp.sh.in: New file, moved from lib/.
9898         * modules/javacomp-script (Files): Update.
9899         (configure.ac): Add AC_CONFIG_FILES invocation.
9900         (EXTRA_DIST): Remove variable.
9901
9902         * build-aux/javaexec.sh.in: New file, moved from lib/.
9903         * modules/javaexec (Files): Update.
9904         (configure.ac): Add AC_CONFIG_FILES invocation.
9905         (EXTRA_DIST): Remove javaexec.sh.in.
9906
9907         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
9908         * modules/csharpcomp-script (Files): Update.
9909         (configure.ac): Add AC_CONFIG_FILES invocation.
9910         (EXTRA_DIST): Remove variable.
9911
9912         * build-aux/csharpexec.sh.in: New file, moved from lib/.
9913         * modules/csharpexec (Files): Update.
9914         (configure.ac): Add AC_CONFIG_FILES invocation.
9915         (EXTRA_DIST): Remove csharpexec.sh.in.
9916
9917 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
9918
9919         Sync from coreutils.
9920
9921         Add POSIX ACL support
9922         * lib/acl.h (copy_acl, set_acl): Add declarations.
9923         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
9924         systems other than Linux.
9925         (chmod_or_fchmod): New function: use fchmod when possible,
9926         and chmod otherwise.
9927         (file_has_acl): Add a POSIX ACL implementation, with a
9928         Linux-specific subcase.
9929         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
9930         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
9931         acls are unsupported.
9932         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
9933         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
9934         are unsupported.
9935
9936 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
9937
9938         Sync from coreutils.
9939         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
9940
9941 2006-01-07  Bruno Haible  <bruno@clisp.org>
9942
9943         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
9944         gl_EARLY.
9945
9946 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
9947
9948         * lib/strftime.c (tzname): Don't declare if it is already #defined.
9949         Problem reported for Mingw by Mark Junker.
9950
9951 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
9952
9953         * README: Gnulib normally doesn't generate a tarball.
9954
9955 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
9956
9957         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
9958         long int, not int, for nanosecond counts, so that people who are
9959         used to POSIX struct timespec won't be surprised.  Reported by Jim
9960         Meyering.
9961
9962 2005-12-28  Bruno Haible  <bruno@clisp.org>
9963
9964         * build-aux/config.rpath: Update from GNU gettext.
9965
9966 2005-12-16  Jim Meyering  <jim@meyering.net>
9967
9968         * modules/fprintftime: New module.
9969         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
9970
9971 2005-12-16  Jim Meyering  <jim@meyering.net>
9972
9973         * m4/fprintftime.m4: New file.
9974
9975 2005-12-16  Jim Meyering  <jim@meyering.net>
9976
9977         * lib/fprintftime.c, lib/fprintftime.h: New files.
9978
9979 2005-12-15  Simon Josefsson  <jas@extundo.com>
9980
9981         * modules/socklen (configure.ac): Fix M4 macro name, to align with
9982         new m4/socklen.m4.
9983
9984 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
9985
9986         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
9987         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
9988
9989 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
9990
9991         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
9992         * lib/argp-help.c (fill_in_uparams): Check if the constructed
9993         struct uparams is valid. Fall back to the default values if it is
9994         not.
9995
9996 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9997
9998         * modules/argp (Files): Add argp-pin.c
9999         (Depends-on): dirname
10000         (lib_SOURCES): Add argp-pin.c
10001
10002 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
10003
10004         * m4/argp.m4:  Check if program_invocation_name and
10005         program_invocation_short_name are declared and define appropriate
10006         macros if they are not.
10007
10008 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
10009
10010         * lib/argp-help.c (__argp_base_name): New function
10011         (__argp_short_program_name): Rewrite using __argp_base_name
10012         * lib/argp-namefrob.h: Define program_invocation_name and
10013         program_invocation_short_name if requested
10014         (__argp_base_name): Add prototype
10015         * lib/argp-parse.c (argp_def): Use gettext wrappers
10016         (argp_default_parser): Use __argp_base_name
10017         * lib/argp-pin.c: New file. Defines program_invocation_name and
10018         program_invocation_short_name on systems that lack them.
10019
10020 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
10021
10022         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
10023         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
10024         porting problem reported by Georg Schwarz in
10025         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
10026
10027 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
10028
10029         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
10030         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
10031         porting problem reported by Georg Schwarz in
10032         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
10033
10034 2005-12-05  Bruno Haible  <bruno@clisp.org>
10035
10036         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
10037         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
10038         Reported by Mark Junker <mjscod@gmx.de>.
10039
10040 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
10041
10042         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
10043         Use implementation from Albert Chin, with some
10044         comments/corrections by Stepan Kasal and myself.
10045
10046 2005-12-02  Bruno Haible  <bruno@clisp.org>
10047
10048         * gnulib-tool (func_import): Accept GPLed build tool modules when
10049         --lgpl is given.
10050         * modules/csharpcomp-script: New file.
10051         * modules/csharpcomp: Depend on it.
10052         * modules/javacomp-script: New file.
10053         * modules/javacomp: Depend on it.
10054         Suggested by Simon Josefsson.
10055
10056 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
10057
10058         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
10059         statement, to work around an HP-UX 10.20 compiler bug reported by
10060         Peter O'Gorman.
10061
10062 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
10063
10064         * modules/savedir (Depends-on): Add openat.
10065
10066 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
10067
10068         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
10069         (uintmax_t) [defined uintmax_t]: Do not declare.
10070         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
10071         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
10072         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
10073         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
10074         sake of portability to weird hosts that C allows (though we don't
10075         know of any practical examples).
10076
10077         * lib/savedir.h (fdsavedir): New decl.
10078         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
10079         contains most of the former guts of savedir.
10080         (savedir): Use savedirstream.
10081         Include "openat.h".
10082
10083 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
10084
10085         * modules/obstack (Files): Add m4/ulonglong.m4.
10086         Problem reported by Davide Angelocola.
10087
10088 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
10089
10090         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
10091         coreutils no longer futzes with rounding modes.
10092
10093 2005-11-14  Jim Meyering  <jim@meyering.net>
10094
10095         * lib/mkstemp-safer.c: Include <config.h>, required for possible
10096         replacement of mkstemp.
10097
10098 2005-11-10  Simon Josefsson  <jas@extundo.com>
10099
10100         * lib/readline.c: Remove EOL.
10101
10102 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
10103
10104         * modules/gethrxtime (Depends-on): Add gettime.
10105
10106 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
10107
10108         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
10109         or gettimeofday; no longer needed.
10110
10111 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
10112
10113         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
10114         time business.
10115         (gethrxtime) [! (HAVE_NANOUPTIME
10116         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
10117         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
10118         our own approximation.
10119
10120 2005-11-08  Eric Blake  <ebb9@byu.net>
10121
10122         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
10123
10124 2005-11-08  Eric Blake  <ebb9@byu.net>
10125
10126         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
10127
10128 2005-11-04  Bruno Haible  <bruno@clisp.org>
10129
10130         * gnulib-tool: Implement --update mode.
10131
10132 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
10133
10134         Fix porting problem reported by Theodoros V. Kalamatianos.
10135         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
10136         Don't assume that futimes failing means we must fail.
10137
10138 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
10139
10140         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
10141         variables to suggest the intended function of the PATH_MAX check.
10142
10143 2005-10-30  Kean Johnston  <jkj@sco.com>
10144
10145         Trivial changes to support SCO systems.
10146         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
10147         as PATH_MAX.
10148         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
10149         where __ptr is null when no I/O is pending.
10150
10151 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
10152
10153         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
10154         leave errno alone.  Problem reported by Dmitry V. Levin.
10155
10156 2005-10-28  Simon Josefsson  <jas@extundo.com>
10157
10158         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
10159         Test more.
10160
10161         * tests/test-gc-md2.c, tests/test-md2.c: New files.
10162
10163         * modules/md2, modules/md2-tests: New files.
10164
10165 2005-10-28  Simon Josefsson  <jas@extundo.com>
10166
10167         * m4/inet_ntop.m4: More tests.
10168
10169         * m4/gc-md2.m4, md2.m4: New file.
10170
10171 2005-10-28  Simon Josefsson  <jas@extundo.com>
10172
10173         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
10174         "restrict" keywords, as per POSIX.  Protect the function
10175         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
10176         Don't use K&R prototypes.  Check the sprintf return values.
10177         Re-define EAFNOSUPPORT if not present.  Indent.
10178
10179         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
10180         suggested by Bruno Haible <bruno@clisp.org>.
10181
10182         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
10183
10184         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
10185
10186         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
10187         libgcrypt).
10188
10189         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
10190
10191         * lib/md2.h, lib/md2.c: New files.
10192
10193 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
10194
10195         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
10196         errno alone.  Problem reported by Frederic Jolliton.
10197
10198 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
10199
10200         * modules/verify (License): Change from GPL to LGPL.  This is a
10201         tiny module and there are apparently near-equivalents that are
10202         under the BSD license.
10203
10204 2005-10-24  Simon Josefsson  <jas@extundo.com>
10205
10206         * modules/sha1: Relicense to LGPL.
10207
10208 2005-10-24  Simon Josefsson  <jas@extundo.com>
10209
10210         * lib/md4.h: Shrink buffer size, now that we changed the type.
10211
10212 2005-10-23  Simon Josefsson  <jas@extundo.com>
10213
10214         * gnulib-tool (func_import): Fix --tests-base.
10215
10216 2005-10-22  Simon Josefsson  <jas@extundo.com>
10217
10218         * modules/arcfour (Depends-on): Need stdint.
10219
10220 2005-10-22  Simon Josefsson  <jas@extundo.com>
10221
10222         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
10223         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
10224
10225 2005-10-22  Simon Josefsson  <jas@extundo.com>
10226
10227         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
10228         suggested by Bruno Haible <bruno@clisp.org>.
10229
10230 2005-10-22  Simon Josefsson  <jas@extundo.com>
10231
10232         * lib/crc.h: Include stddef.h, for size_t.
10233
10234 2005-10-22  Simon Josefsson  <jas@extundo.com>
10235
10236         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
10237         arcfour_context struct (simplify test vector testing in GNU
10238         Shishi).
10239
10240 2005-10-21  Simon Josefsson  <jas@extundo.com>
10241
10242         * modules/des, modules/des-tests: New files.
10243
10244         * modules/gc-des, modules/gc-des-tests: New files.
10245
10246         * tests/test-des.c, tests/test-gc-des.c: New file.
10247
10248 2005-10-21  Simon Josefsson  <jas@extundo.com>
10249
10250         * modules/arctwo, modules/arctwo-tests: New files.
10251
10252         * tests/test-arctwo.c: New file.
10253
10254         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
10255
10256         * tests/test-gc-arctwo.c: New file.
10257
10258 2005-10-21  Simon Josefsson  <jas@extundo.com>
10259
10260         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
10261         Bruno Haible <bruno@clisp.org>.
10262
10263         * m4/gc-des.m4: New file.
10264
10265 2005-10-21  Simon Josefsson  <jas@extundo.com>
10266
10267         * m4/arctwo.m4: New file.
10268
10269         * m4/gc-arctwo.m4: New file.
10270
10271 2005-10-21  Simon Josefsson  <jas@extundo.com>
10272
10273         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
10274         block.
10275
10276 2005-10-21  Simon Josefsson  <jas@extundo.com>
10277
10278         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
10279         <bruno@clisp.org>.
10280
10281         * lib/hmac-sha1.c (hmac_sha1): Likewise.
10282
10283         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
10284         Bruno Haible <bruno@clisp.org>.
10285
10286         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
10287         <bruno@clisp.org>.
10288
10289 2005-10-21  Simon Josefsson  <jas@extundo.com>
10290
10291         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
10292
10293 2005-10-21  Simon Josefsson  <jas@extundo.com>
10294
10295         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
10296
10297 2005-10-21  Simon Josefsson  <jas@extundo.com>
10298
10299         * lib/des.h, lib/des.c: New files.
10300
10301         * lib/gc-gnulib.c: Support DES.c
10302
10303 2005-10-21  Simon Josefsson  <jas@extundo.com>
10304
10305         * lib/arctwo.h, lib/arctwo.c: New files.
10306
10307         * lib/gc-gnulib.c: Support ARCTWO.
10308
10309 2005-10-21  Simon Josefsson  <jas@extundo.com>
10310
10311         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
10312         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10313
10314 2005-10-21  Simon Josefsson  <jas@extundo.com>
10315
10316         * gnulib-tool (func_import, func_create_testdir): Define automake
10317         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
10318         Makefile.am snippet),
10319         suggested by Bruno Haible <bruno@clisp.org>.
10320
10321         * modules/gc (Makefile.am): Use it.
10322
10323 2005-10-21  Bruno Haible  <bruno@clisp.org>
10324
10325         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
10326         patch.
10327
10328 2005-10-19  Simon Josefsson  <jas@extundo.com>
10329
10330         * tests/test-gc-rijndael.c: New file.
10331
10332         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
10333
10334 2005-10-19  Simon Josefsson  <jas@extundo.com>
10335
10336         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
10337         interface too.
10338
10339 2005-10-19  Simon Josefsson  <jas@extundo.com>
10340
10341         * tests/test-gc-arcfour.c: New file.
10342
10343         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
10344
10345 2005-10-19  Simon Josefsson  <jas@extundo.com>
10346
10347         * modules/gc-md4, modules/gc-md4-tests: New file.
10348
10349         * tests/test-gc-md4.c: New file.
10350
10351 2005-10-19  Simon Josefsson  <jas@extundo.com>
10352
10353         * m4/gc-md4.m4: New file.
10354
10355 2005-10-19  Simon Josefsson  <jas@extundo.com>
10356
10357         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
10358         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
10359         <kasal@ucw.cz>.
10360
10361 2005-10-19  Simon Josefsson  <jas@extundo.com>
10362
10363         * m4/gc-arcfour.m4: New file.
10364
10365         * m4/gc-rijndael.m4: New file.
10366
10367 2005-10-19  Simon Josefsson  <jas@extundo.com>
10368
10369         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
10370
10371 2005-10-19  Simon Josefsson  <jas@extundo.com>
10372
10373         * lib/gc-gnulib.c: Support ARCFOUR.
10374
10375 2005-10-19  Simon Josefsson  <jas@extundo.com>
10376
10377         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
10378         support.
10379
10380         * lib/gc.h: Add ECB enum type.
10381
10382         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
10383
10384 2005-10-18  Simon Josefsson  <jas@extundo.com>
10385
10386         * tests/test-md5.c: New file.
10387
10388         * modules/md5-tests: New file.
10389
10390 2005-10-18  Simon Josefsson  <jas@extundo.com>
10391
10392         * tests/test-md4.c: New file.
10393
10394         * modules/md4, modules/md4-tests: New files.
10395
10396 2005-10-18  Simon Josefsson  <jas@extundo.com>
10397
10398         * m4/md4.m4: New file.
10399
10400 2005-10-18  Simon Josefsson  <jas@extundo.com>
10401
10402         * lib/md4.h, lib/md4.c: New files, based on md5.?.
10403
10404 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
10405
10406         * gnulib-tool (func_create_testdir): Omit the second check whether
10407         BUILT_SOURCES in nonempty.
10408
10409 2005-10-17  Simon Josefsson  <jas@extundo.com>
10410
10411         * tests/test-rijndael.c: New file.
10412
10413 2005-10-17  Simon Josefsson  <jas@extundo.com>
10414
10415         * modules/sha1: Depend on stdint instead of md5.
10416
10417         * modules/md5: Depend on stdint, remove uint32_t.
10418
10419 2005-10-17  Simon Josefsson  <jas@extundo.com>
10420
10421         * modules/gc-sha1-tests: New file.
10422
10423         * tests/test-gc-sha1.c: New file.
10424
10425 2005-10-17  Simon Josefsson  <jas@extundo.com>
10426
10427         * m4/md5.m4: Remove call to uint32_t.m4.
10428
10429 2005-10-17  Simon Josefsson  <jas@extundo.com>
10430
10431         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
10432
10433         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
10434         md5.h.
10435
10436         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
10437
10438         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
10439
10440 2005-10-17  Simon Josefsson  <jas@extundo.com>
10441
10442         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
10443
10444 2005-10-17  Simon Josefsson  <jas@extundo.com>
10445
10446         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
10447
10448 2005-10-17  Simon Josefsson  <jas@extundo.com>
10449
10450         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
10451
10452         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
10453
10454 2005-10-17  Bruno Haible  <bruno@clisp.org>
10455
10456         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
10457         that it can also be used in a test.
10458
10459 2005-10-16  Bruno Haible  <bruno@clisp.org>
10460
10461         * gnulib-tool (func_emit_tests_Makefile_am): Also define
10462         TESTS_ENVIRONMENT, so that individual tests can augment it.
10463
10464         * gnulib-tool (func_create_testdir): Use an intermediate target for
10465         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
10466         macros, like $(ALLOCA_H), which cannot be passed through the command
10467         line.
10468
10469 2005-10-15  Simon Josefsson  <jas@extundo.com>
10470
10471         * modules/rijndael-tests: New file.
10472
10473         * modules/rijndael: New file.
10474
10475 2005-10-15  Simon Josefsson  <jas@extundo.com>
10476
10477         * m4/rijndael.m4: New file.
10478
10479 2005-10-15  Simon Josefsson  <jas@extundo.com>
10480
10481         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
10482
10483         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
10484
10485 2005-10-14  Simon Josefsson  <jas@extundo.com>
10486
10487         * tests/test-arcfour.c: New file.
10488
10489         * modules/arcfour, modules/arcfour-tests: New files.
10490
10491 2005-10-14  Simon Josefsson  <jas@extundo.com>
10492
10493         * m4/arcfour.m4: New file.
10494
10495 2005-10-14  Simon Josefsson  <jas@extundo.com>
10496
10497         * lib/arcfour.h, lib/arcfour.c: New files.
10498
10499 2005-10-14  Roland McGrath  <roland@redhat.com>
10500
10501         Import from libc.  [BZ #1331]
10502         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
10503         macro argument.
10504         Reported by Matej Vela <vela@debian.org>.
10505
10506 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
10507
10508         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
10509         include <wchar.h>; no longer needed.
10510
10511 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
10512
10513         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
10514
10515 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
10516         and  Ulrich Drepper  <drepper@redhat.com>
10517
10518         Import from libc.
10519         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
10520         instead of inline stream orientation test and two separate
10521         function calls.  Pay no attention to USE_IN_LIBIO.
10522
10523 2005-10-13  Simon Josefsson  <jas@extundo.com>
10524
10525         * modules/gc-hmac-md5-tests: New file.
10526
10527         * tests/test-gc-hmac-sha1.c: New file.
10528
10529         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
10530
10531         * modules/gc-hmac-md5-tests: New file.
10532
10533         * tests/test-gc-md5.c: New file.
10534
10535         * modules/gc-md5-tests: New file.
10536
10537 2005-10-13  Simon Josefsson  <jas@extundo.com>
10538
10539         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
10540         Move memory allocation outside of loop.
10541
10542 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
10543
10544         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
10545         intermediate directory is in a read-only file system.  Problem
10546         reported by Eric Blake.
10547
10548 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
10549
10550         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
10551
10552 2005-10-12  Simon Josefsson  <jas@extundo.com>
10553
10554         * tests/test-hmac-sha1.c: New file.
10555
10556         * modules/hmac-sha1-tests: New file.
10557
10558         * modules/hmac-sha1: New file.
10559
10560 2005-10-12  Simon Josefsson  <jas@extundo.com>
10561
10562         * modules/gc-sha1: New file.
10563
10564 2005-10-12  Simon Josefsson  <jas@extundo.com>
10565
10566         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
10567
10568         * tests/test-gc-pbkdf2-sha1.c: New file.
10569
10570 2005-10-12  Simon Josefsson  <jas@extundo.com>
10571
10572         * modules/gc-md5, modules/gc-hmac-md5: New files.
10573
10574         * modules/gc (Files): Remove md5, memxor and hmac files.
10575
10576 2005-10-12  Simon Josefsson  <jas@extundo.com>
10577
10578         * m4/gc-pbkdf2-sha1.m4: New file.
10579
10580         * m4/gc-hmac-sha1.m4: New file.
10581
10582         * m4/gc-sha1: New file.
10583
10584         * m4/hmac-sha1.m4: New file.
10585
10586 2005-10-12  Simon Josefsson  <jas@extundo.com>
10587
10588         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
10589
10590         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
10591
10592 2005-10-12  Simon Josefsson  <jas@extundo.com>
10593
10594         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
10595         suggested by Bruno Haible <bruno@clisp.org>.
10596
10597 2005-10-12  Simon Josefsson  <jas@extundo.com>
10598
10599         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
10600
10601 2005-10-12  Simon Josefsson  <jas@extundo.com>
10602
10603         * lib/gc-pbkdf2-sha1.c: New file.
10604
10605         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
10606
10607 2005-10-12  Simon Josefsson  <jas@extundo.com>
10608
10609         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
10610
10611         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
10612
10613 2005-10-12  Simon Josefsson  <jas@extundo.com>
10614
10615         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
10616         GC_USE_HMAC_MD5, respectively.
10617
10618         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
10619         (gc_md5): Fix typo.
10620
10621         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
10622
10623         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
10624
10625         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
10626
10627 2005-10-12  Bruno Haible  <bruno@clisp.org>
10628
10629         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
10630         Reported by Stepan Kasal <kasal@ucw.cz>.
10631
10632 2005-10-11  Simon Josefsson  <jas@extundo.com>
10633
10634         * tests/test-crc.c: New file.
10635
10636         * modules/crc, modules/crc-tests: New files.
10637
10638 2005-10-11  Simon Josefsson  <jas@extundo.com>
10639
10640         * m4/crc.m4: New file.
10641
10642 2005-10-11  Simon Josefsson  <jas@extundo.com>
10643
10644         * lib/gc.h: Add gc_hash and gc_hash_buffer.
10645
10646         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
10647
10648         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
10649
10650 2005-10-11  Simon Josefsson  <jas@extundo.com>
10651
10652         * lib/crc.h, lib/crc.c: New files.
10653
10654         * lib/gc.h (gc_hash_buffer): Add doc.
10655
10656 2005-10-11  Bruno Haible  <bruno@clisp.org>
10657
10658         * modules/c-strcasestr: New file.
10659         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
10660
10661 2005-10-11  Bruno Haible  <bruno@clisp.org>
10662
10663         * modules/c-strcase: New file.
10664         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
10665
10666 2005-10-11  Bruno Haible  <bruno@clisp.org>
10667
10668         * lib/strcasecmp.c: Include limits.h.
10669         (strcasecmp): Avoid integer overflow on exotic platforms.
10670         * lib/strncasecmp.c: Include limits.h.
10671         (strncasecmp): Avoid integer overflow on exotic platforms.
10672         Reported by Paul Eggert.
10673
10674 2005-10-11  Bruno Haible  <bruno@clisp.org>
10675
10676         * lib/c-strcasestr.h: New file, from GNU gettext.
10677         * lib/c-strcasestr.c: New file, from GNU gettext.
10678
10679 2005-10-11  Bruno Haible  <bruno@clisp.org>
10680
10681         * lib/c-strcase.h: New file, from GNU gettext.
10682         * lib/c-strcasecmp.c: New file, from GNU gettext.
10683         * lib/c-strncasecmp.c: New file, from GNU gettext.
10684
10685 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
10686
10687         * modules/mempcpy (License): GPL -> LGPL.
10688         * modules/strchrnul (License): Likewise.
10689         * modules/sysexits (License): Likewise.
10690
10691 2005-10-08  Simon Josefsson  <jas@extundo.com>
10692
10693         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
10694
10695 2005-10-07  Simon Josefsson  <jas@extundo.com>
10696
10697         * m4/memxor.m4: Remove gl_C_RESTRICT call.
10698
10699 2005-10-06  Simon Josefsson  <jas@extundo.com>
10700
10701         * tests/test-hmac-md5.c: New file.
10702
10703         * modules/hmac-md5-tests: New file.
10704
10705         * modules/hmac-md5: New file.
10706
10707 2005-10-06  Simon Josefsson  <jas@extundo.com>
10708
10709         * m4/hmac-md5.m4: New file.
10710
10711         * m4/memxor.m4: Require gl_C_RESTRICT.
10712
10713 2005-10-06  Simon Josefsson  <jas@extundo.com>
10714
10715         * lib/memxor.c (memxor): Avoid casts and warnings.
10716
10717 2005-10-06  Simon Josefsson  <jas@extundo.com>
10718
10719         * lib/hmac-md5.c: New file.
10720
10721         * lib/hmac.h: New file.
10722
10723 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10724
10725         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
10726         promotes to int, not unsigned int, to catch the AIX 5.3
10727         compiler bug.
10728
10729 2005-10-05  Simon Josefsson  <jas@extundo.com>
10730
10731         * modules/memxor: New file.
10732
10733         * modules/iconv (Files): Move config.rpath to havelib, it is used
10734         there.
10735
10736         * modules/havelib (Files): Add config.rpath.
10737
10738 2005-10-05  Simon Josefsson  <jas@extundo.com>
10739
10740         * m4/memxor.m4: New file.
10741
10742 2005-10-05  Simon Josefsson  <jas@extundo.com>
10743
10744         * lib/memxor.c (memxor): Fix compiler error.
10745
10746         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
10747         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
10748
10749         * lib/memxor.h, lib/memxor.c: New files.
10750
10751         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
10752         we assume all systems have it, suggested by Jim Meyering
10753         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
10754         any systems lack sys/socket.h; mingw32 is known to lack it, but we
10755         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
10756         same reasons.
10757
10758 2005-10-05  Simon Josefsson  <jas@extundo.com>
10759
10760         * config/srclist.txt: Add glibc bug 1423 for md5.h.
10761
10762 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10763
10764         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
10765         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
10766         needed, since the source code now assumes these .h files.
10767
10768 2005-10-05  Derek Price  <derek@ximbiot.com>
10769
10770         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
10771
10772 2005-10-05  Bruno Haible  <bruno@clisp.org>
10773
10774         * modules/stdint (License): Change to LGPL.
10775
10776 2005-10-04  Simon Josefsson  <jas@extundo.com>
10777
10778         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
10779         D. Baushke" <mdb@gnu.org>.
10780
10781 2005-10-04  Bruno Haible  <bruno@clisp.org>
10782
10783         * lib/verify.h (verify_true): Provide alternative definition for C++.
10784
10785 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
10786
10787         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
10788         (SSIZE_MAX): New macro, if not already defined.
10789         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
10790         than 2 GiB.
10791
10792 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10793
10794         Sync from coreutils.
10795         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
10796         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
10797         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
10798         ULLONG_MAX doesn't work with 2.7.2.1.
10799
10800 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10801
10802         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
10803         From Ben Pfaff.
10804
10805         * modules/exclude (Depends-on): Depend on verify.
10806         * modules/strtoimax (Depends-on): Likewise.
10807         * modules/utimecmp (Depends-on): Likewise.
10808
10809 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10810
10811         * lib/exclude.c: Include verify.h.
10812         (verify): Remove.  All callers changed to use verify.h's version.
10813         * lib/strtoimax.c: Likewise.
10814         * lib/utimecmp.c: Likewis.e
10815
10816         Sync from coreutils.
10817         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
10818         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
10819         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
10820         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
10821         bother returning ENOSYS if settimeofday or stime fails; just let
10822         them return whatever errno they want to return.
10823         * lib/utimens.c: Include unistd.h, for dup2.
10824         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
10825         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
10826
10827 2005-10-02  Jim Meyering  <jim@meyering.net>
10828
10829         Sync from coreutils.
10830         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
10831         from glibc-2.2.5 that fails for read-only files.
10832
10833 2005-10-02  Jim Meyering  <jim@meyering.net>
10834
10835         Sync from coreutils.
10836         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
10837         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
10838         `#if HAVE_CONFIG_H'.
10839         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
10840         Remove AT_FDCWD test.
10841         Do not consume the fd unless successful.
10842         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
10843         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
10844         block, so that we don't even try to compile it if settimeofday is
10845         available.  This works around a compilation failure on OSF1 V5.1,
10846         due to stime requiring a `long int*' while tv_sec is `int'.
10847
10848 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
10849
10850         Sync from coreutils.
10851         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
10852         against `yes', rather than just testing for nonempty.
10853
10854 2005-10-01  Simon Josefsson  <jas@extundo.com>
10855
10856         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
10857         and Darwin.
10858
10859         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
10860         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
10861         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
10862         freeaddrinfo and gai_strerror are declared by the POSIX headers.
10863         Check if struct addrinfo is declared.
10864
10865 2005-10-01  Simon Josefsson  <jas@extundo.com>
10866
10867         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
10868         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
10869         AI_* and EAI_* definitions.  Protect function declarations.
10870
10871 2005-10-01  Jim Meyering  <jim@meyering.net>
10872
10873         Sync from coreutils.
10874
10875         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
10876         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
10877         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
10878         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
10879         in the inet and nsl libraries.  Required on Solaris 5.7.
10880
10881 2005-10-01  Jim Meyering  <jim@meyering.net>
10882
10883         Sync from coreutils.
10884         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
10885         in the inet and nsl libraries.  Required on Solaris 5.7.
10886
10887 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
10888
10889         * lib/getdelim.c (getdelim): Remove unused variables.
10890
10891 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10892
10893         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
10894         so that the code works even with ancient cpp.  Portability problem
10895         with GCC 2.7.2.1 reported by Thomas M.Ott.
10896
10897 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10898
10899         * modules/regex (Depends-on): Add strcase.
10900
10901         * modules/gethostname (Licence): Change from GPL to LGPL, since
10902         gethostname.c is a trivial implementation of a standard library
10903         function.
10904         * modules/poll (License): Change from GPL to LGPL, since it's
10905         derived from LGPL code.
10906
10907 2005-09-27  Jim Meyering  <jim@meyering.net>
10908
10909         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
10910         HAVE_CONFIG_H.
10911
10912         * lib/intprops.h (signed_type_or_expr__): Define.
10913         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
10914         for unsigned types.
10915
10916 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10917
10918         * lib/verify.h (verify_expr): Remove, replacing with:
10919         (verify_true): New macro that returns true instead of void.
10920         (verify_type__): Remove.
10921         (verify): Use verify_true rather than verify_type__.
10922
10923 2005-09-26  Bruno Haible  <bruno@clisp.org>
10924
10925         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
10926         is necessary.
10927         (lib_SOURCES): Remove mbchar.c.
10928         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
10929         (Files): Add m4/mbrtowc.m4.
10930         * modules/mbiter: Likewise.
10931         * modules/mbuiter: Likewise.
10932
10933 2005-09-26  Bruno Haible  <bruno@clisp.org>
10934
10935         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
10936         compile mbchar.c if they are not both present.
10937         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
10938         * m4/mbiter.m4 (gl_MBITER): Likewise.
10939         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
10940         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
10941         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
10942
10943 2005-09-25  Jim Meyering  <jim@meyering.net>
10944
10945         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
10946         also uses socklen_t.
10947
10948 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
10949
10950         * lib/utimens.c (ENOSYS): Define if not already defined.
10951         (futimens): Support having a null PATH if the file descriptor
10952         is nonnegative.
10953
10954         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
10955         Remove.
10956         (__attribute): Define to empty unless GCC 3.1 or later.
10957         This works around a core dump on OpenBSD 3.4, which has GCC
10958         2.95.3, which dumps core when given __attribute__(()).  It also
10959         simplifies other tests, since we really don't want to bother with
10960         worrying about which ancient version of GCC supported what.
10961         Original problem reported by Yoann Vandoorselaere, with part of
10962         the fix suggested by Derek Price.
10963
10964 2005-09-24  Jim Meyering  <jim@meyering.net>
10965
10966         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
10967         so we can once again use a positive bitfield width of 1 -- now we
10968         don't have to explain why we were using a bitfield width of 2.
10969
10970 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
10971
10972         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
10973         and similarly for the other external symbols.  Problem reported
10974         by James Gallager.
10975
10976         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
10977         bug reported by Jim Meyering.
10978
10979         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
10980         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
10981         not needed, since socklen is a prerequisite module.
10982
10983 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
10984
10985         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
10986         Problem reported by Eric Blake.
10987         (getaddrinfo): Initialize se so that it's not garbage.
10988         Redo internal storage allocation so that it doesn't make unportable
10989         assumptions about alignment.
10990         Fix a memory leak.
10991
10992         * lib/utimens.c (futimens): Use futimesat if available.
10993         Prefer it to futimes since it doesn't have the futimes bug.
10994
10995         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
10996         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
10997         Instead, declare a function that returns a pointer to an array,
10998         and use verify_type__ to declare the size of the array.
10999         Problem and germ of a solution reported by Bruno Haible.
11000         (verify_type__): Use 2, not 1, for bitfield size, to avoid
11001         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
11002
11003 2005-09-23  Jim Meyering  <jim@meyering.net>
11004
11005         Sync from coreutils.
11006         Correct build failure (socklen_t not defined) on at least
11007         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
11008         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
11009
11010 2005-09-23  Jim Meyering  <jim@meyering.net>
11011
11012         * modules/getaddrinfo (Depends-on): Add socklen.
11013
11014 2005-09-23  Bruno Haible  <bruno@clisp.org>
11015
11016         * tests/test-verify.c: New file.
11017
11018 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
11019
11020         Sync from coreutils.
11021
11022         * modules/argmatch (Depends-on): Add verify.
11023         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
11024         unistd-safer.
11025         * modules/save-cwd (Depends-on): Likewise.
11026
11027         * modules/openat (Files): Add lib/openat-die.c.
11028         (Depends-on): Remove error, exitfail.
11029         Add dirname.
11030
11031         * modules/verify: New file.
11032         * MODULES.html.sh (Diagnostics <assert.h>): New section,
11033         with "verify" module.
11034
11035 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
11036
11037         Sync from coreutils.
11038
11039         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
11040         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
11041         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
11042         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
11043         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
11044         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
11045         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
11046         Don't bother checking for string.h, stdlib.h, unistd.h.
11047         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
11048         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
11049         module's job.
11050         * m4/jm-macros.m4 (gl_MACROS): Likewise.
11051         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
11052
11053         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
11054         (gl_GETDATE): Use it.
11055
11056         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
11057
11058 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
11059
11060         Sync from coreutils.
11061
11062         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
11063         stat-time.h.
11064         * lib/argmatch.h: Include verify.h
11065         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
11066         (ARGMATCH_ASSERT): Remove; unused.
11067         * lib/canonicalize.c: Assume STDC_HEADERS.
11068         * lib/exclude.c: Include "strcase.h".
11069         * lib/regex_internal.h [!defined _LIBC]: Likewise.
11070         * lib/getusershell.c: Include stdio--.h rather than stdio.h
11071         and stdio-safer.h.
11072         (getusershell): Call fopen, not fopen_safer.
11073         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
11074         Do not include unistd-safer.h.
11075         (save_cwd): Don't call fd_safer; no longer needed
11076         now that we include fcntl--.h.
11077
11078         * lib/getdate.y (relative_time): New type.
11079         (RELATIVE_TIME_0): New constant.
11080         (parser_control): Use relative_time instead of doing it ourselves.
11081         (%union): Add new relative_time rel member.
11082         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
11083         Now typeless.
11084         (relunit, relunit_snumber): Now of type rel.
11085         (zone, rel, relunit, get_date): Adjust to above changes.
11086
11087         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
11088         Do not include unistd-safer.h.
11089         (getloadavg): Don't call fd_safer; no longer needed
11090         now that we include fcntl--.h.
11091
11092         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
11093         (make_dir_parents): Treat ENOSYS like EEXIST.
11094
11095         Improve quality of diagnostics on restore_cwd failure.
11096         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
11097         (make_dir_parents): Last arg is now int * (for errno), not bool *.
11098         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
11099         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
11100         each time through the loop.  Do not diagnose restore_cwd failure;
11101         that is the caller's job (and perhaps the caller does not care).
11102
11103         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
11104         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
11105         If the file already exists but is not a directory, don't bother
11106         to try to make its parents.
11107         Close potential file descriptor leak if we can't chdir("/") (!).
11108         Don't always return true if chdir($PWD) fails; return true only
11109         if the requested action was done successfully (except for the
11110         chdir($PWD)).
11111         Don't log final directory unless we actually made it.
11112         Refactor to avoid duplicate code to fix up permissions.
11113         Don't attempt to fix up parent permissions if chdir($PWD) fails.
11114
11115         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
11116         to make it a bit faster and (I hope) clearer.
11117         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
11118         Fix bug in formats like %2N.
11119
11120         * lib/verify.h: New file.
11121
11122 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
11123
11124         Sync from coreutils.
11125         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
11126
11127 2005-09-22  Jim Meyering  <jim@meyering.net>
11128
11129         Sync from coreutils.
11130
11131         * m4/lstat.m4 (gl_FUNC_LSTAT):
11132         Use AC_LIBSOURCES to require lstat.c and lstat.h.
11133         Remove obsolete comment.
11134         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
11135         * m4/xstrtod.m4: Likewise.
11136
11137         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
11138
11139 2005-09-22  Jim Meyering  <jim@meyering.net>
11140
11141         Sync from coreutils.
11142
11143         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
11144
11145         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
11146         the .tm_year member, since otherwise gcc-4.0 would now warn about
11147         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
11148
11149         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
11150         order to avoid an unsuppressible warning from gcc on 64-bit systems.
11151
11152         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
11153         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
11154         when run in a time zone for which daylight savings time is in effect
11155         for the starting date.
11156
11157         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
11158         stop us from restricting permissions of just-created absolute-named
11159         directories.
11160         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
11161         to restore initial working directory.
11162         * lib/mkdir-p.c (make_dir_parents): New parameter:
11163         different_working_dir, to tell caller if/when we change the working
11164         directory and are unable to return to the initial one.
11165         * lib/mkdir-p.h (make_dir_parents): Update prototype.
11166         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
11167         `return false'.  This fixes a bug introduced on 2004-07-30.
11168
11169         * lib/openat.c (fdopendir): Be sure to close the supplied
11170         file descriptor before returning.  This makes our replacement
11171         implementation a little closer to Solaris's, where fdopendir
11172         ties the file descriptor to the returned DIR* pointer.
11173         * lib/openat.c (unlinkat): New function.
11174         * lib/openat.h (unlinkat): Add prototype.
11175         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
11176         (openat_restore_fail): Rename from openat_restore_die.
11177         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
11178
11179         Provide an alternative to exiting immediately upon save_cwd or
11180         restore_cwd failure.  Now, an application can arrange e.g.,
11181         to perform a longjump in that case.
11182         * lib/openat.c: Include dirname.h.
11183         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
11184         (rpl_openat, fdopendir, fstatat): Call openat_save_die
11185         and openat_restore_die rather than calling error directly.
11186         Don't include "error.h" or "exitfail.h"; they're no longer needed.
11187
11188         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
11189         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
11190         define.
11191
11192         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
11193         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
11194                             int utc, int nanoseconds);
11195         Background:
11196         date should not have to allocate a megabyte of virtual memory to
11197         handle a format argument like +%1048575T.  When implemented with
11198         strftime, it must allocate such a buffer, use strftime to fill it
11199         in, print it, then free it.
11200         With fprintftime, it simply prints everything and exits.
11201         With no need for memory allocation, that's one fewer way to fail.
11202         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
11203         optional field width, not before, so we accept %9:z, not %:9z.
11204         (my_strftime): Be sure to use L_('x') for literals.
11205
11206         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
11207         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
11208         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
11209         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
11210         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
11211         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
11212         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
11213         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
11214         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
11215         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
11216         * lib/xgethostname.c, lib/xreadlink.c:
11217         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
11218
11219         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
11220         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
11221         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
11222         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
11223         and don't include <sys/file.h>).
11224
11225 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
11226
11227         Sync from coreutils.
11228
11229         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
11230         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
11231         [!LDAV_DONE]: Avoid unused variable warning.
11232
11233 2005-09-21  Bruno Haible  <bruno@clisp.org>
11234
11235         * lib/unicodeio.h (unicode_to_mb): New declaration.
11236
11237 2005-09-20  Derek Price  <derek@ximbiot.com>
11238
11239         * lib/getaddrinfo.c: Don't include <netdb.h> included from
11240         getaddrinfo.h.
11241
11242 2005-09-20  Bruno Haible  <bruno@clisp.org>
11243
11244         * gnulib-tool: Remove trailing slashes from the values specified for
11245         --source-base, --m4-base, --tests-base, --aux-dir.
11246         Suggested by Simon Josefsson <jas@extundo.com>.
11247
11248 2005-09-20  Bruno Haible  <bruno@clisp.org>
11249
11250         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
11251         func_modules_to_filelist, func_import, func_create_testdir): Make all
11252         sorting results locale-independent, so that gnulib-cache.m4 doesn't
11253         change when gnulib-tool is invoked in a different locale.
11254
11255 2005-09-19  Simon Josefsson  <jas@extundo.com>
11256
11257         * m4/socklen.m4: Fix typo.
11258
11259 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11260
11261         Use a consistent style for including <config.h>.
11262         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
11263         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
11264         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
11265         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
11266         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
11267         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
11268         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
11269         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
11270         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
11271         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
11272         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
11273         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
11274         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
11275         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
11276         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
11277         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
11278         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
11279         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
11280         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
11281         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
11282         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
11283         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
11284         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
11285         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
11286         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
11287         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
11288         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
11289         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
11290         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
11291         lib/xstrtoumax.c, lib/yesno.c:
11292         Standardize inclusion of config.h.
11293         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
11294         lib/inttostr.h:  Removed inclusion of config.h from header files.
11295         * lib/inttostr.c:  Adjusted in-tree users.
11296         * lib/timespec.h: Remove superfluous warning to include config.h.
11297         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
11298         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
11299         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
11300         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
11301         config.h with HAVE_CONFIG_H.
11302
11303 2005-09-19  Jim Meyering  <jim@meyering.net>
11304
11305         * modules/pathmax (License): Change to LGPL.
11306
11307 2005-09-19  Derek Price  <derek@ximbiot.com>
11308
11309         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
11310
11311 2005-09-19  Bruno Haible  <bruno@clisp.org>
11312
11313         * gnulib-tool (import): Provide default for --tests-base.
11314
11315 2005-09-19  Bruno Haible  <bruno@clisp.org>
11316
11317         * doc/quote.texi: New file, extracted from gnulib.texi.
11318         * doc/ctime.texi: New file, extracted from gnulib.texi.
11319         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
11320         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
11321         * doc/gnulib.texi: Include them.
11322
11323 2005-09-18  Bruno Haible  <bruno@clisp.org>
11324
11325         Portability fix.
11326         * gnulib-tool (func_readlink): New function.
11327         (func_ln_if_changed): Use it.
11328
11329 2005-09-18  Bruno Haible  <bruno@clisp.org>
11330
11331         * gnulib-tool: Support --with-tests also with --import.
11332         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
11333         (func_import): Use variables $testsbase and $inctests. Emit a
11334         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
11335         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
11336         SUBDIRS += $testsdir.
11337         (func_create_testdir): Update.
11338
11339 2005-09-18  Bruno Haible  <bruno@clisp.org>
11340
11341         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
11342         instead of $dry_run.
11343         (func_cp_if_changed, func_mv_if_changed): Remove functions.
11344         (func_ln_if_changed): Don't handle dry-run here.
11345         (func_import): In dry-run mode, detect more precisely which actions
11346         would be performed, and don't use "...ing" verbs.
11347
11348 2005-09-18  Bruno Haible  <bruno@clisp.org>
11349
11350         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
11351         (func_import): Use join on two temporary files instead of three nested
11352         loops, in order to determine which files are new or old.
11353
11354 2005-09-18  Bruno Haible  <bruno@clisp.org>
11355
11356         * gnulib-tool (func_import): Comment out code that spits out the
11357         new files with --dry-run.
11358
11359 2005-09-18  Bruno Haible  <bruno@clisp.org>
11360
11361         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
11362
11363 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11364
11365         * lib/stat-time.h: New file.
11366         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
11367         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
11368         in a different way.
11369         (timespec_cmp): New function.
11370         * lib/utimecmp.c: Include stat-time.h.
11371         (SYSCALL_RESOLUTION): Depend on whether various struct stat
11372         members exist, not on the obsolescent ST_MTIM_NSEC.
11373         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
11374
11375 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11376
11377         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
11378
11379 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11380
11381         * MODULES.html.sh (File system functions): Add stat-time.
11382         * modules/stat-time: New file.
11383         * modules/timespec (Files): Remove m4/st_mtim.m4; this
11384         is now done in a different way, by the stat-time module.
11385         * modules/utimecmp (Depends-on): Add stat-time.
11386
11387 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11388
11389         * m4/st_mtim.m4: Remove.  Superseded by...
11390         * m4/stat-time.m4: New file.
11391         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
11392         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
11393
11394 2005-09-15  Derek Price  <derek@ximbiot.com>
11395
11396         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
11397
11398 2005-09-15  Derek Price  <derek@ximbiot.com>
11399
11400         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
11401         * lib/regex_internal.c: Ditto, using this...
11402         (__GNUC_PREREQ): ...new macro.
11403         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
11404         using...
11405         (__GNUC_PREREQ): ...this new macro.
11406
11407         * lib/strstr.h: Include string.h. Define strstr as a macro here.
11408
11409 2005-09-15  Derek Price  <derek@ximbiot.com>
11410             Paul Eggert  <eggert@cs.ucla.edu>
11411
11412         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
11413         changes, consolidating in...
11414         * lib/regex_internal.h: ...this file.
11415
11416 2005-09-13  Jim Meyering  <jim@meyering.net>
11417
11418         * lib/canon-host.c: Filter through gnu indent and reword comments
11419         slightly.
11420         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
11421
11422 2005-09-13  Derek Price  <derek@ximbiot.com>
11423
11424         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
11425         failure.
11426         Reported by Jim Meyering  <jim@meyering.net>.
11427
11428 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11429
11430         * lib/base64.c: Typo.
11431         (base64_encode): Put b64str in initialized data section.
11432
11433 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
11434
11435         Merge glibc and coreutils changes into gnulib, plus a few
11436         extra fixes.
11437         * lib/md5.c: Use #error rather than a string.
11438         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
11439         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
11440         (__attribute__): Define to empty for non recent-GCC.
11441         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
11442         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
11443         Renamed from their non-__ counterparts, with new macros replacing
11444         them if not _LIBC.  Add __THROW attribute.
11445         (rol): Remove.
11446         (struct md5_ctx): Align buffer if using GCC.
11447         * lib/sha1.h (struct sha1_ctx): Likewise.
11448         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
11449         The old name was backwards.
11450         (NOTSWAP): Remove; not used.
11451         (rol): New macro, moved here from md5.h.
11452         (sha1_process_block): Remove a FIXME that doesn't make sense.
11453
11454 2005-09-12  Derek Price  <derek@ximbiot.com>
11455
11456         Return usable errors from canon-host.
11457         * lib/canon-host.h: New file.
11458         * lib/canon-host.c (canon_host): Wrap...
11459         (canon_host_r): ...this new function, which now relies exclusively on
11460         getaddrinfo.
11461         (ch_strerror): New function.
11462         (last_cherror): New global.
11463         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
11464         interface.
11465         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
11466         void *.
11467         (freeaddrinfo): Free ai->ai_canonname when set.
11468
11469 2005-09-12  Derek Price  <derek@ximbiot.com>
11470
11471         Make canon-host require getaddrinfo.
11472         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
11473         AC_LIBSOURCE canon-host.h.  Call...
11474         (gl_PREREQ_CANON_HOST): ...this new function, which requires
11475         gl_GETADDRINFO.
11476         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
11477
11478 2005-09-12  Derek Price  <derek@ximbiot.com>
11479
11480         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
11481         LGPL.
11482         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
11483
11484 2005-09-12  Derek Price  <derek@ximbiot.com>
11485
11486         * lib/gai_strerror.c: Include config.h when available.  Include
11487         getaddrinfo.h before other headers to test interface.
11488         Reported by Larry Jones <lawrence.jones@ugs.com>.
11489
11490 2005-09-12  Derek Price  <derek@ximbiot.com>
11491             Paul Eggert  <eggert@cs.ucla.edu>
11492
11493         * modules/glob (Files): Add glob-libc.h.
11494
11495 2005-09-12  Derek Price  <derek@ximbiot.com>
11496             Paul Eggert  <eggert@cs.ucla.edu>
11497
11498         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
11499         glob_.h, glob-libc.h.
11500         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
11501
11502 2005-09-12  Derek Price  <derek@ximbiot.com>
11503             Paul Eggert  <eggert@cs.ucla.edu>
11504
11505         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
11506         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
11507         protecting things that should be done only in gnulib contexts.
11508         * lib/glob_.h: New file, containing only the glob things needed for
11509         gnulib.
11510         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
11511         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
11512         (glob, globfree, glob_pattern_p): Now defined simply in terms of
11513         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
11514         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
11515         and to respect the namespace rules better.
11516
11517 2005-09-08  Simon Josefsson  <jas@extundo.com>
11518
11519         * modules/socklen: New file.
11520
11521 2005-09-08  Simon Josefsson  <jas@extundo.com>
11522
11523         * m4/socklen.m4: New file.
11524
11525 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11526
11527         * modules/utimens (Files): Add m4/utimbuf.m4, since
11528         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
11529         Reported by Sergey Poznyakoff.
11530
11531 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11532
11533         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
11534         definitions, since that's the preferred style in glibc.
11535         Fix a minor spacing issue, and update copyright notice to match
11536         glibc's.
11537
11538 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11539
11540         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
11541
11542 2005-09-06  Simon Josefsson  <jas@extundo.com>
11543
11544         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
11545         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
11546
11547 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11548
11549         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
11550         warning.
11551
11552 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11553
11554         * config/srclist.txt: Add glibc bug 1302.
11555
11556 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
11557
11558         Change bitset word type from unsigned int to unsigned long int,
11559         as this has better performance on typical 64-bit hosts.
11560         Port bitset code to hosts with unusual word sizes.
11561         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
11562         (build_collating_symbol):
11563         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
11564         argument is a bitset.  This is merely a style issue, but it makes
11565         it clearer that an entire array is expected.
11566         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
11567         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
11568         Port to the case where bitset_word is not the same as unsigned int.
11569         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
11570         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
11571         Likewise.
11572         * lib/regexec.c (check_dst_limits_calc_pos_1,
11573         check_subexp_matching_top):
11574         (build_trtable, group_nodes_into_DFAstates):
11575         Likewise.
11576         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
11577         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
11578         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
11579         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
11580         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
11581         * lib/regcomp.c (optimize_subexps, lower_subexp):
11582         Work even if bitset_word has holes in its bitwise representation.
11583         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
11584         * lib/regexec.c (check_dst_limits_calc_pos_1,
11585         check_subexp_matching_top):
11586         Likewise.
11587         * lib/regex_internal.c (re_string_reconstruct):
11588         Don't assume UCHAR_MAX == 255.
11589         * lib/regex_internal.h (bitset_set_all): Likewise.
11590         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
11591         All uses changed.
11592         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
11593         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
11594         All uses changed.
11595         (BITSET_WORD_MAX): New macro.
11596         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
11597         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
11598         (bitset_empty, bitset_copy):
11599         Prefer sizeof (bitset) to multiplying it out ourselves.
11600         (bitset_not_merge): Remove; unused.
11601         (bitset_contain): Return bool, not unsigned int with one bit on.
11602         All callers changed.
11603         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
11604         alignment than re_node_set; do this by defining a new internal
11605         type struct dests_alloc and using it to allocate memory.
11606
11607 2005-09-05  Bruno Haible  <bruno@clisp.org>
11608
11609         * gnulib-tool (func_import): Fix comparison in handling of symbolic
11610         links.
11611
11612 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
11613
11614         * modules/size_max (Makefile.am): Add size_max.h
11615
11616 2005-09-04  Derek Price  <derek@ximbiot.com>
11617
11618         * gnulib-tool (func_import): Fix reversed $symbolic logic.
11619
11620 2005-09-03  Simon Josefsson  <jas@extundo.com>
11621
11622         * gnulib-tool: Fix typo.
11623
11624 2005-09-03  Simon Josefsson  <jas@extundo.com>
11625
11626         * config/srclist.txt: Add glibc bug 1293.
11627
11628 2005-09-03  Derek Price  <derek@ximbiot.com>
11629
11630         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
11631         From Larry Jones <lawrence.jones@ugs.com>.
11632
11633 2005-09-02  Simon Josefsson  <jas@extundo.com>
11634
11635         * modules/socklen: New file.
11636
11637 2005-09-02  Simon Josefsson  <jas@extundo.com>
11638
11639         * modules/havelib: New module.
11640
11641         * modules/gettext, modules/iconv, modules/lock, modules/readline:
11642         Use havelib.
11643
11644 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
11645
11646         Check for arithmetic overflow when calculating sizes, to prevent
11647         some buffer-overflow issues.  These patches are conservative, in the
11648         sense that when I couldn't determine whether an overflow was possible,
11649         I inserted a run-time check.
11650         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
11651         macros.
11652         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
11653         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
11654         (re_xnrealloc, re_x2nrealloc): New inline functions.
11655         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
11656         parse_bracket_exp):
11657         (build_equiv_class, build_charclass): Check for arithmetic overflow
11658         in size expression calculations.
11659         * lib/regex_internal.c (re_string_realloc_buffers):
11660         (build_wcs_upper_buffer, re_node_set_add_intersect):
11661         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
11662         (re_dfa_add_node, register_state): Likewise.
11663         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
11664         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
11665         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
11666         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
11667
11668 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
11669
11670         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
11671         m4/ulonglong.m4.  Problem reported by Martin Lambers.
11672
11673 2005-09-02  Bruno Haible  <bruno@clisp.org>
11674
11675         Support for lib vs. lib64 distinction on biarch platforms.
11676         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
11677         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
11678         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
11679
11680 2005-09-02  Bruno Haible  <bruno@clisp.org>
11681
11682         * gnulib-tool (import): In the other first-use case, provide defaults
11683         as well.
11684
11685 2005-09-02  Bruno Haible  <bruno@clisp.org>
11686
11687         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
11688         patches not yet found in the latest gettext release.
11689
11690 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11691
11692         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
11693         to avoid a collision with bits/local_lim.h in glibc.
11694         All uses changed.  Problem reported by Dmitry V. Levin in
11695         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
11696
11697         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
11698         bugs in int versus size_t comparisons.
11699         (re_string_context_at): Fix bug where the code assumed that
11700         Idx is signed.
11701
11702         Use bool where appropriate.
11703         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
11704         All callers changed.
11705         (calc_eclosure_iter): Likewise, for ROOT arg.
11706         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
11707         (build_charclass_op): Likewise, for NON_MATCH arg.
11708         * lib/regex_internal.c (re_string_allocate, re_string_construct):
11709         (re_string_construct_common): Likewise, for ICASE arg.
11710         * lib/regexec.c (re_search_2_stub, re_search_stub):
11711         Likewise, for RET_LEN arg.
11712         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
11713         (set_regs): Likewise, for FL_BACKTRACK arg.
11714         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
11715         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
11716         (calc_eclosure_iter, parse_bracket_exp):
11717         Use bool for internal variables that are booleans.
11718         * lib/regexec.c (re_search_internal, check_matching,
11719         proceed_next_node):
11720         (set_regs, build_sifted_states, sift_states_bkref):
11721         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
11722         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11723         (find_collation_sequence_value):
11724         Likewise.
11725         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
11726         (re_node_set_compare):
11727         Return bool, not int. All callers changed.
11728         * lib/regexec.c (check_halt_node_context, check_dst_limits):
11729         (build_trtable, check_node_accept): Likewise.
11730         * lib/regex_internal.h: Include stdbool.h.
11731
11732         Fix bugs uncovered when converting to bool.
11733         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
11734         failure instead of charging ahead blindly.
11735         * lib/regex_internal.c (register_state): Likewise.
11736         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
11737         for freeing internal storage.
11738         (group_nodes_into_DFA_states): Use unsigned int, not int, for
11739         bitset pieces used as boolean, to avoid undefined behavior
11740         on hosts that do int overflow checking.
11741
11742 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11743
11744         * config/srclist.txt: Add glibc bugs 1285-1287.
11745
11746 2005-09-01  Jim Meyering  <jim@meyering.net>
11747
11748         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
11749         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
11750         Require gl_STAT_MACROS, too.
11751
11752 2005-09-01  Bruno Haible  <bruno@clisp.org>
11753
11754         * gnulib-tool (import): In the first-use case, provide defaults.
11755
11756 2005-09-01  Bruno Haible  <bruno@clisp.org>
11757
11758         * gnulib-tool (func_import): Remove the .tmp files.
11759
11760 2005-09-01  Bruno Haible  <bruno@clisp.org>
11761
11762         * gnulib-tool (func_import): Fix handling of symbolic links.
11763
11764 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11765
11766         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
11767         old glibc regex code mishandles strings longer than 2**31 bytes.
11768         This patch fixes this when the regex code is used in gnulib
11769         (i.e., outside glibc).
11770
11771         This patch should not affect the use of the regex code inside
11772         glibc.  No doubt this problem also needs to be handled for glibc
11773         as well, but the result will be an incompatible change to the
11774         glibc ABI, and the old ABI will have to be supported too.  That
11775         can be the the subject for another patch.
11776
11777         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
11778         governing whether the rest of this patch is active.  By default,
11779         the macro is disabled and the patch has no effect.
11780         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
11781         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
11782         (struct re_pattern_buffer, re_search, re_search_2, re_match):
11783         (re_match_2, re_set_registers): Use the new types.
11784         * lib/regex_internal.h (Idx, re_hashval_t): New types.
11785         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
11786         New macros.
11787         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
11788         (re_string_context_at, bin_tree_t, re_dfastate_t):
11789         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
11790         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
11791         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
11792         (re_string_char_size_at, re_string_wchar_at):
11793         (re_string_elem_size_at):
11794         Use the new types and macros to port to 64-bit hosts.
11795         Use unsigned types for internal values, so that the code
11796         mostly works even for arrays larger than SSIZE_MAX.
11797         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
11798         (search_duplicated_node, calc_eclosure_iter, fetch_number):
11799         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
11800         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
11801         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
11802         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
11803         (calc_inveclosure, parse_dup_op, build_range_exp):
11804         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
11805         (fetch_number, create_token_tree, mark_opt_subexp):
11806         Likewise.
11807         * lib/regex_internal.c (re_string_construct_common,
11808         create_ci_newstate):
11809         (create_cd_newstate, re_string_allocate, re_string_construct):
11810         (re_string_realloc_buffers, build_wcs_upper_buffer):
11811         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11812         (re_string_reconstruct, re_string_peek_byte_case):
11813         (re_string_fetch_byte_case, re_string_context_at):
11814         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11815         (re_node_set_init_copy, re_node_set_add_intersect):
11816         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11817         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11818         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11819         (re_acquire_state, re_acquire_state_context, register_state):
11820         Likewise.
11821         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
11822         search_cur_bkref_entry):
11823         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
11824         (re_search_internal, re_search_2_stub, re_search_stub)
11825         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
11826         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
11827         (update_cur_sifted_state, check_dst_limits):
11828         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
11829         (check_subexp_limits, sift_states_bkref, merge_state_array):
11830         (check_subexp_matching_top, get_subexp, get_subexp_sub):
11831         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
11832         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11833         (expand_bkref_cache, check_node_accept_bytes):
11834         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
11835         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
11836         (acquire_init_state_context, check_halt_node_context):
11837         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
11838         (sift_states_backward, clean_state_log_if_needed):
11839         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
11840         (find_recover_state, transit_state_sb, transit_state_mb):
11841         (transit_state_bkref, build_trtable, match_ctx_clean):
11842         Likewise.
11843         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
11844         to work around an assumption that REG_MISSING is negative.
11845
11846         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
11847         (seek_collating_symbol_entry) [defined _LIBC]:
11848         (lookup_collation_sequence_value) [defined _LIBC]:
11849         (build_range_exp, build_collating_symbol) [defined _LIBC]:
11850         Use prototypes rather than old-style function definitions.
11851         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
11852         (transit_state_sb) [0]:
11853         (find_collation_sequence_value) [defined _LIBC]: Likewise.
11854
11855         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
11856         rm_eo.
11857
11858         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
11859         (optimize_subexps, lower_subexp):
11860         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
11861         since the signed shift might overflow.  Use 1u<<31 instead.
11862         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
11863         Likewise.
11864         * lib/regexec.c (check_dst_limits_calc_pos_1,
11865         check_subexp_matching_top): Likewise.
11866
11867         * lib/regcomp.c (optimize_subexps, lower_subexp):
11868         Use CHAR_BIT rather than 8, for clarity.
11869         * lib/regexec.c (check_dst_limits_calc_pos_1):
11870         (check_subexp_matching_top): Likewise.
11871         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
11872         have to worry about portability issues when shifting it left.
11873         Remove no-longer-needed test for table_size > 0.
11874         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
11875         in a word, as the resulting behavior is undefined.
11876         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
11877         in one case, a <= should have been an <, and in another case the
11878         whole test was missing.
11879         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
11880         the standard name CHAR_BIT.
11881         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
11882         this is not true on one's complement and signed-magnitude hosts.
11883
11884         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
11885         next_last_offset.
11886         (struct re_dfa_t): Remove unused member states_alloc.
11887         * lib/regcomp.c (init_dfa): Don't initialize unused members.
11888
11889 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11890
11891         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
11892         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
11893         and large-file glibc and in 32-bit large-file Solaris.
11894
11895 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11896
11897         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
11898         lengths fit in regoff_t; this isn't true if regoff_t is the same
11899         width as size_t.
11900         * lib/regex.c (re_search_internal): 5th arg is LAST_START
11901         (= START + RANGE) instead of RANGE.  This avoids overflow
11902         problems when regoff_t is the same width as size_t.
11903         All callers changed.
11904         (re_search_2_stub): Check for overflow when adding the
11905         sizes of the two strings.
11906         (re_search_stub): Check for overflow when adding START
11907         to RANGE; if it occurs, substitute the extreme value.
11908
11909 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11910
11911         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
11912
11913 2005-08-31  Jim Meyering  <jim@meyering.net>
11914
11915         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
11916         a pointer-to-const.
11917         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
11918         (register_state): Likewise.
11919         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
11920         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
11921         (group_nodes_into_DFAstates): Likewise.
11922
11923 2005-08-31  Jim Meyering  <jim@meyering.net>
11924
11925         * check-module: Add a FIXME comment.
11926
11927 2005-08-31  Eric Blake  <ebb9@byu.net>
11928
11929         * modules/unistd-safer (Files): Add unistd--.h.
11930         * modules/stdio-safer (Files): Add stdio--.h.
11931
11932 2005-08-31  Derek Price  <derek@ximbiot.com>
11933
11934         * lib/getdelim.c (getdelim): Return EOF on EOF.
11935         Reported by Larry Jones <lawrence.jones@ugs.com>.
11936
11937 2005-08-31  Bruno Haible  <bruno@clisp.org>
11938
11939         Avoid unnecessary diffs in the generated lib/Makefile.am.
11940         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
11941         the generated files.
11942         (func_import): Don't set cmd.
11943
11944 2005-08-31  Bruno Haible  <bruno@clisp.org>
11945
11946         * lib/strstr.c: Include <stddef.h>, for NULL.
11947         * lib/strcasestr.c: Likewise.
11948         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
11949
11950 2005-08-31  Bruno Haible  <bruno@clisp.org>
11951
11952         * gnulib-tool: New option --macro-prefix.
11953         (func_import): Use macro_prefix.
11954         (import): Handle option --macro-prefix.
11955
11956 2005-08-31  Bruno Haible  <bruno@clisp.org>
11957
11958         * gnulib-tool (import): Rename most ac_* variables to cached_*.
11959         Also use new variables cached_lgpl, cached_libtool.
11960
11961 2005-08-31  Bruno Haible  <bruno@clisp.org>
11962
11963         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
11964         always instantiating them.
11965
11966 2005-08-31  Bruno Haible  <bruno@clisp.org>
11967
11968         * gnulib-tool (func_import): Read the previous cached settings
11969         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
11970         earlier added by gnulib but are now dropped. Warn when a gnulib file
11971         overwrites a non-gnulib file.
11972
11973 2005-08-31  Bruno Haible  <bruno@clisp.org>
11974
11975         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
11976         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
11977         projects that don't keep autogenerated files in CVS. Put into
11978         actioncmd only the specified modules, not the transitive closure.
11979
11980 2005-08-31  Bruno Haible  <bruno@clisp.org>
11981
11982         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
11983         Create directories that shall be filled.
11984         (import): Don't look for gl_* macros in configure.ac. Recurse across
11985         all directories containing a gnulib-cache.m4 files, if meaningful.
11986
11987 2005-08-31  Bruno Haible  <bruno@clisp.org>
11988
11989         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
11990         (import): Set seen_libtool when we see gl_LIBTOOL.
11991
11992 2005-08-31  Bruno Haible  <bruno@clisp.org>
11993
11994         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
11995         declaration macro definitions from generated gnulib.m4.
11996
11997 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
11998
11999         * lib/iconvme.h: Add prototype for iconv_alloc.
12000
12001 2005-08-29  Simon Josefsson  <jas@extundo.com>
12002
12003         * lib/iconvme.c: Fix errno.
12004
12005 2005-08-29  Bruno Haible  <bruno@clisp.org>
12006
12007         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
12008         that it works when the directory contains spaces.
12009
12010 2005-08-29  Bruno Haible  <bruno@clisp.org>
12011
12012         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
12013
12014 2005-08-29  Bruno Haible  <bruno@clisp.org>
12015
12016         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
12017         Emit more advice.
12018
12019 2005-08-29  Bruno Haible  <bruno@clisp.org>
12020         and Stepan Kasal  <kasal@ucw.cz>
12021
12022         * check-module: If more parameters are given, check each of them
12023         separately; add more exceptions, as noted by Jim Meyering.
12024         (check_module): New procedure.
12025         (%exempt_header): Now contains all exceptions.
12026
12027 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
12028
12029         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
12030
12031 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
12032
12033         * lib/iconvme.c: Split iconv_string into iconv_alloc.
12034
12035 2005-08-28  Bruno Haible  <bruno@clisp.org>
12036
12037         * m4/gnulib-tool.m4: New file.
12038
12039 2005-08-27  Jim Meyering  <jim@meyering.net>
12040
12041         * modules/unistd-safer (Files): Add pipe-safer.c.
12042         * modules/fcntl-safer (Files): Add creat-safer.c.
12043
12044 2005-08-27  Jim Meyering  <jim@meyering.net>
12045
12046         * m4/stdlib-safer.m4: New file.  From coreutils.
12047         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
12048         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
12049         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
12050         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
12051         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
12052
12053 2005-08-27  Jim Meyering  <jim@meyering.net>
12054
12055         * lib/fopen-safer.c: Merge minor changes from coreutils.
12056         * lib/dup-safer.c: Likewise.
12057         * lib/fd-safer.c: Likewise.
12058
12059         Merge from coreutils.
12060         * lib/stdio--.h: New file.
12061         * lib/stdlib--.h: New file.
12062         * lib/mkstemp-safer.c: New file.
12063
12064         GNU tar needs these.
12065         * lib/pipe-safer.c: New file.
12066         * lib/creat-safer.c: New file.
12067         * lib/fcntl--.h (creat): Define to creat_safer.
12068         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
12069         * lib/unistd--.h (pipe): Define to pipe_safer.
12070         * lib/unistd-safer.h: Declare pipe_safer.
12071
12072 2005-08-26  Simon Josefsson  <jas@extundo.com>
12073
12074         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
12075         Haible <bruno@clisp.org>.
12076
12077 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
12078
12079         * lib/regex_internal.h: Remove all references to
12080         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
12081         or better.
12082         (bitset_not, bitset_merge, bitset_not_merge):
12083         (bitset_mask, re_string_allocate, re_string_construct):
12084         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
12085         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
12086         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
12087         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
12088         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
12089         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
12090         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
12091         (re_acquire_state_context):
12092         Remove unnecessary forward decls.
12093         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
12094         Put __attribute at function definition,
12095         now that the function decl has been removed.
12096         * lib/regex_internal.c (re_string_peek_byte_case):
12097         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
12098         Likewise.
12099
12100 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
12101
12102         * m4/regex.m4: Add AC_PREREQ(2.50).
12103         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
12104
12105 2005-08-25  Simon Josefsson  <jas@extundo.com>
12106
12107         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
12108         __fsetlocking.
12109
12110 2005-08-25  Simon Josefsson  <jas@extundo.com>
12111
12112         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
12113         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
12114         GLIBC specific code.
12115
12116 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
12117
12118         Make regex safe for g++.  This fixes one real bug (an "err"
12119         that should have been "*err").  g++ problem reported by
12120         Sam Steingold.
12121         * lib/regex_internal.h (re_calloc): New macro, consistent with
12122         re_malloc etc.  All callers of calloc changed to use re_calloc.
12123         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
12124         not int.  All callers changed.
12125         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
12126         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
12127         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
12128         (find_recover_state): Change "err" to "*err"; this fixes what
12129         appears to be a real bug.
12130         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
12131         versus int.
12132
12133 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
12134
12135         * modules/regex (Depends-on): Add malloc, since the code
12136         assumes that !malloc(0) means failure.
12137
12138 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
12139
12140         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
12141
12142         alloca modernization/simplification for regex.
12143         * lib/regex.c: Remove portability cruft for alloca.  This no longer
12144         needs to be at the start of the file, and can be moved into
12145         regex_internal.h and simplified.
12146         * lib/regex_internal.h: Include <alloca.h>.
12147         (__libc_use_alloca) [!defined _LIBC]: New macro.
12148         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
12149         now works outside glibc.
12150
12151 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
12152
12153         * config/srclist.txt: Add glibc bugs 1241, 1245.
12154
12155 2005-08-25  Jim Meyering  <jim@meyering.net>
12156
12157         * lib/open-safer.c: Include <config.h>.
12158         Otherwise, we'd lose LARGEFILE support in any file using
12159         e.g. "fcntl--.h"
12160
12161 2005-08-25  Bruno Haible  <bruno@clisp.org>
12162
12163         * m4/minmax.m4: Require autoconf 2.52.
12164         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
12165         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
12166         alternatives of translit over the alphabet.
12167         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
12168
12169 2005-08-24  Simon Josefsson  <jas@extundo.com>
12170
12171         * tests/test-getpass.c: New file.
12172
12173 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
12174
12175         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
12176         for GNU regex features.
12177
12178 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
12179
12180         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
12181         * lib/regex.h (regerror): Likewise.
12182
12183         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
12184         requires this.  (The code never needed it.)
12185
12186         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
12187         All uses of recently-renamed identifiers changed to use the new,
12188         POSIX-compliant names.  The code will build and run just fine
12189         without these changes, but it's better to eat our own dog food
12190         and use the standard-conforming names.
12191
12192         * lib/regex.h: Fix a multitude of POSIX name space violations.
12193         These changes have an effect only for programs that define
12194         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
12195         do not change anything for programs compiled in the normal way.
12196         Also, there is no effect on the ABI.
12197
12198         (_REGEX_SOURCE): New macro.
12199         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
12200         defined and _GNU_SOURCE is not; this fixes a name space violation.
12201
12202         Rename the following macros to obey POSIX requirements.
12203         The old names are still visible as macros if _REGEX_SOURCE is defined.
12204         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
12205         RE_BACKSLASH_ESCAPE_IN_LISTS.
12206         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
12207         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
12208         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
12209         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
12210         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
12211         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
12212         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
12213         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
12214         (REG_INTERVALS): renamed from RE_INTERVALS.
12215         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
12216         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
12217         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
12218         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
12219         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
12220         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
12221         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
12222         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
12223         RE_UNMATCHED_RIGHT_PAREN_ORD.
12224         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
12225         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
12226         (REG_DEBUG): renamed from RE_DEBUG.
12227         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
12228         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
12229         unusual, since we can't clash with the POSIX REG_ICASE.
12230         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
12231         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
12232         (REG_NO_SUB): renamed from RE_NO_SUB.
12233         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
12234         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
12235         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
12236         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
12237         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
12238         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
12239         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
12240         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
12241         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
12242         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
12243         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
12244         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
12245         RE_SYNTAX_POSIX_MINIMAL_BASIC.
12246         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
12247         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
12248         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
12249         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
12250         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
12251         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
12252         (REG_FIXED): Renamed from REGS_FIXED.
12253         (REG_NREGS): Renamed from RE_NREGS.
12254
12255         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
12256         of other REG_* macros, since POSIX says the user is allowed to
12257         #undef these macros selectively.
12258
12259         (reg_errcode_t): Update comment stating what other tables need
12260         to be consistent.
12261
12262         Rename the following enum values to obey POSIX requirements.
12263         The old names are still visible as macros.
12264         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
12265         is not defined, since GNU is supposed to be a superset of POSIX as
12266         much as possible, and since we want reg_errcode_t to be a signed
12267         type for implementation consistency.
12268         (_REG_NOERROR): Renamed from REG_NOERROR.
12269         (_REG_NOMATCH): Renamed from REG_NOMATCH.
12270         (_REG_BADPAT): Renamed from REG_BADPAT.
12271         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
12272         (_REG_ECTYPE): Renamed from REG_ECTYPE.
12273         (_REG_EESCAPE): Renamed from REG_EESCAPE.
12274         (_REG_ESUBREG): Renamed from REG_ESUBREG.
12275         (_REG_EBRACK): Renamed from REG_EBRACK.
12276         (_REG_EPAREN): Renamed from REG_EPAREN.
12277         (_REG_EBRACE): Renamed from REG_EBRACE.
12278         (_REG_BADBR): Renamed from REG_BADBR.
12279         (_REG_ERANGE): Renamed from REG_ERANGE.
12280         (_REG_ESPACE): Renamed from REG_ESPACE.
12281         (_REG_BADRPT): Renamed from REG_BADRPT.
12282         (_REG_EEND): Renamed from REG_EEND.
12283         (_REG_ESIZE): Renamed from REG_ESIZE.
12284         (_REG_ERPAREN): Renamed from REG_ERPAREN.
12285         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
12286         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
12287         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
12288         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
12289
12290         (_REG_RE_NAME, _REG_RM_NAME): New macros.
12291         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
12292         changed.  But support the old name if the new one is not defined
12293         and if _REGEX_SOURCE.
12294
12295         Change the following member names in struct re_pattern_buffer.
12296         The old names are still supported if !_REGEX_SOURCE.
12297         The new names are always supported, regardless of _REGEX_SOURCE.
12298         (re_buffer): Renamed from buffer.
12299         (re_allocated): Renamed from allocated.
12300         (re_used): Renamed from used.
12301         (re_syntax): Renamed from syntax.
12302         (re_fastmap): Renamed from fastmap.
12303         (re_translate): Renamed from translate.
12304         (re_can_be_null): Renamed from can_be_null.
12305         (re_regs_allocated): Renamed from regs_allocated.
12306         (re_fastmap_accurate): Renamed from fastmap_accurate.
12307         (re_no_sub): Renamed from no_sub.
12308         (re_not_bol): Renamed from not_bol.
12309         (re_not_eol): Renamed from not_eol.
12310         (re_newline_anchor): Renamed from newline_anchor.
12311
12312         Change the following member names in struct re_registers.
12313         The old names are still supported if !_REGEX_SOURCE.
12314         The new names are always supported, regardless of _REGEX_SOURCE.
12315         (rm_num_regs): Renamed from num_regs.
12316         (rm_start): Renamed from start.
12317         (rm_end): Renamed from end.
12318
12319         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
12320         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
12321         Prepend __ to parameter names.
12322
12323         Undo yesterday's changes.
12324
12325 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
12326
12327         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
12328         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
12329         lib/regex.c.
12330
12331 2005-08-24  Jim Meyering  <jim@meyering.net>
12332
12333         Sync from coreutils.
12334         * m4/fcntl-safer.m4: New file.
12335
12336         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
12337         and object files for this module.
12338
12339 2005-08-24  Jim Meyering  <jim@meyering.net>
12340
12341         Sync from coreutils.
12342         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
12343
12344 2005-08-24  Jim Meyering  <jim@meyering.net>
12345
12346         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
12347         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
12348
12349 2005-08-24  Jim Meyering  <jim@meyering.net>
12350
12351         * modules/fcntl-safer: New module.
12352         * modules/fts (Depends-on): Add fcntl-safer.
12353         * MODULES.html.sh (File descriptor based Input/Output):
12354         Add fcntl-safer.
12355
12356 2005-08-24  Bruno Haible  <bruno@clisp.org>
12357
12358         Support for unit test modules.
12359         * modules/README: Mention tests modules.
12360         * modules/TEMPLATE-TESTS: New file.
12361         * gnulib-tool: New options --extract-tests-module, --with-tests and
12362         --tests-base (unused for the moment).
12363         (testsbase, inctests): New variables.
12364         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
12365         (func_verify_module): Exclude TEMPLATE-TESTS.
12366         (func_verify_nontests_module, func_verify_tests_module): New functions.
12367         (func_get_dependencies): Add implicit dependency for tests modules.
12368         (func_get_tests_module): New function.
12369         (func_modules_transitive_closure): When --with-tests was specified,
12370         include the unit tests as well, unless explicitly avoided.
12371         (func_emit_lib_Makefile_am): Ignore the tests modules here.
12372         (func_emit_tests_Makefile_am): New function.
12373         (func_create_testdir): When --with-tests was specified, emit a
12374         tests/ directory.
12375         * MODULES.html.sh (Future developments): Update.
12376
12377 2005-08-24  Bruno Haible  <bruno@clisp.org>
12378
12379         * modules/tls-tests: New file.
12380         * tests/test-tls.c: New file, from GNU gettext.
12381
12382 2005-08-24  Bruno Haible  <bruno@clisp.org>
12383
12384         * modules/lock-tests: New file.
12385         * tests/test-lock.c: New file, from GNU gettext.
12386
12387 2005-08-24  Bruno Haible  <bruno@clisp.org>
12388
12389         * lib/lock.h: Add multiple inclusion guard.
12390         * lib/tls.h: Add multiple inclusion guard.
12391
12392 2005-08-24  Bruno Haible  <bruno@clisp.org>
12393
12394         * gnulib-tool: Add support for the --aux-dir option to
12395         --create-testdir, --create-megatestdir, --test, --megatest.
12396         (func_create_testdir, func_create_megatestdir): Optionally emit a
12397         AC_CONFIG_AUX_DIR directive.
12398         (create-testdir, create-megatestdir, test, megatest): Provide a
12399         default value for $auxdir.
12400
12401 2005-08-24  Bruno Haible  <bruno@clisp.org>
12402
12403         * gnulib-tool (import): Use compound statement instead of subshell
12404         where possible.
12405
12406 2005-08-24  Bruno Haible  <bruno@clisp.org>
12407
12408         * gnulib-tool (import): Change --aux-dir default to "build-aux".
12409
12410 2005-08-24  Bruno Haible  <bruno@clisp.org>
12411
12412         * gnulib-tool (func_version): Update.
12413
12414 2005-08-24  Bruno Haible  <bruno@clisp.org>
12415
12416         * gnulib-tool (func_import, func_create_testdir,
12417         func_create_megatestdir): Quote all autoconf macro arguments.
12418
12419 2005-08-24  Bruno Haible  <bruno@clisp.org>
12420
12421         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
12422         option --force, because --force causes the aclocal.m4 of each
12423         subdirectory to be newer than the corresponding config.h.in.
12424
12425 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12426
12427         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
12428         All contents moved to gl_REGEX.
12429         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
12430         assume that it does.
12431
12432 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12433
12434         * lib/regex.h (REG_NOSYS)
12435         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
12436         Define, since POSIX requires it as of 2001.
12437         (_REG_ENOSYS)
12438         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
12439         New private symbol, used to keep the enum signed in all cases.
12440         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
12441         Youngman in
12442         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
12443
12444         * lib/regex_internal.c (re_string_skip_chars, register_state):
12445         (calc_state_hash):
12446         Remove forward decls; no longer needed now that we use prototypes.
12447         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
12448         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
12449         (clean_state_log_if_needed): Likewise.
12450
12451 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12452
12453         * config/srclist.txt: Add glibc bugs 1231-1233.
12454
12455 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12456
12457         Fix problems reported by Sam Steingold in
12458         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
12459         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
12460         assumed that reg_errcode_t is a signed type, which is not
12461         necessarily true if _XOPEN_SOURCE is not defined.
12462         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
12463         since some compilers warn about it otherwise.
12464
12465 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12466
12467         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
12468         (init_word_char, create_initial_state, duplicate_node_closure):
12469         (fetch_token, peek_token_bracket, build_range_exp):
12470         (build_collating_symbol): Remove forward decls; no longer needed
12471         now that we use prototypes.
12472
12473         * lib/regcomp.c:
12474         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
12475         (re_compile_fastmap_iter, regcomp, regerror, regfree):
12476         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
12477         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
12478         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
12479         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
12480         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
12481         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
12482         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
12483         (build_range_exp, build_collating_symbol, parse_bracket_exp):
12484         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
12485         (build_charclass, build_charclass_op, fetch_number, create_tree):
12486         (create_token_tree, mark_opt_subexp, duplicate_tree):
12487         Use prototypes rather than old-style definitions.
12488
12489         * lib/regex_internal.c:
12490         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
12491         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
12492         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
12493         (re_string_reconstruct, re_string_peek_byte_case):
12494         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
12495         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
12496         (re_node_set_init_copy, re_node_set_add_intersect):
12497         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
12498         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
12499         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
12500         (re_acquire_state, re_acquire_state_context, register_state):
12501         (create_ci_newstate, create_cd_newstate, free_state):
12502         Likewise.
12503         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
12504         re_search_2):
12505         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
12506         (re_search_internal, prune_impossible_nodes):
12507         (acquire_init_state_context, check_matching, static):
12508         (check_halt_node_context, check_halt_state_context, proceed_next_node):
12509         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
12510         (update_regs, sift_states_backward, build_sifted_states):
12511         (clean_state_log_if_needed, merge_state_array):
12512         (update_cur_sifted_state, add_epsilon_src_nodes):
12513         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
12514         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
12515         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
12516         (find_recover_state, check_subexp_matching_top, transit_state_mb):
12517         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
12518         (check_arrival, check_arrival_add_next_nodes):
12519         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
12520         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
12521         (check_node_accept_bytes, check_node_accept, extend_buffers):
12522         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
12523         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
12524         (sift_ctx_init):
12525         Likewise.
12526
12527         * lib/regex_internal.h:
12528         (re_string_allocate, re_string_construct, re_string_reconstruct):
12529         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
12530         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
12531         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
12532         (re_string_context_at, re_string_peek_byte_case):
12533         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
12534         is defined, since we now use prototypes always.
12535
12536         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
12537         C89 or better.  All uses removed.
12538
12539 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12540
12541         * config/srclist.txt: Add glibc bugs 1220-1227.
12542
12543 2005-08-20  Jim Meyering  <jim@meyering.net>
12544
12545         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
12546         of unused local, dfa.
12547
12548 2005-08-20  Bruno Haible  <bruno@clisp.org>
12549
12550         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
12551
12552 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12553
12554         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
12555         (re_node_set_insert_last, re_dfa_add_node):
12556         Rename local variables to avoid GCC shadowing warnings.
12557
12558 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12559
12560         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
12561         [defined lint]: Suppress bogus uninitialized-variable warnings.
12562
12563         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
12564         and let the caller return REG_ESPACE if out of space.  This
12565         removes an uninitialied-variable warning with GCC 4.0.1, and also
12566         avoids taking the address of a local variable.  All callers
12567         changed.
12568
12569 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12570
12571         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
12572         $LIBCSRC/posix/regexec.c.
12573         Add glibc bug 1217 for regcomp.c.
12574
12575 2005-08-19  Jim Meyering  <jim@meyering.net>
12576
12577         * lib/regexec.c (proceed_next_node): Redo local variables to
12578         avoid GCC shadowing warnings.
12579
12580 2005-08-18  Bruno Haible  <bruno@clisp.org>
12581
12582         * lib/strstr.c (strstr): Fix return value in multibyte case.
12583         * lib/strcasestr.c (strcasestr): Likewise.
12584
12585 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12586
12587         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
12588
12589 2005-08-17  Jim Meyering  <jim@meyering.net>
12590
12591         Make the %s format (seconds since the epoch) work for a negative
12592         number and when used with a zero-padded field width, e.g. %015s.
12593
12594         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
12595         label so that it precedes the code to set `digits'.  Otherwise,
12596         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
12597         print `00-22'.  Now, it prints `-0022', as it should.
12598
12599 2005-08-17  Bruno Haible  <bruno@clisp.org>
12600
12601         * modules/strstr (Files): Add m4/mbrtowc.m4.
12602         (Depends-on): Add mbuiter.
12603
12604 2005-08-17  Bruno Haible  <bruno@clisp.org>
12605
12606         * modules/strcasestr: New file.
12607         * MODULES.html.sh (String handling, based on ANSI C 89): Add
12608         strcasestr.
12609
12610 2005-08-17  Bruno Haible  <bruno@clisp.org>
12611
12612         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
12613
12614 2005-08-17  Bruno Haible  <bruno@clisp.org>
12615
12616         * modules/mbuiter: New file.
12617         * MODULES.html.sh (Extended multibyte and wide character utilities):
12618         Add mbuiter.
12619
12620 2005-08-17  Bruno Haible  <bruno@clisp.org>
12621
12622         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
12623         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
12624
12625 2005-08-17  Bruno Haible  <bruno@clisp.org>
12626
12627         * m4/strcasestr.m4: New file.
12628
12629 2005-08-17  Bruno Haible  <bruno@clisp.org>
12630
12631         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
12632         * lib/strstr.c: Completely rewritten, with multibyte locale support.
12633
12634 2005-08-17  Bruno Haible  <bruno@clisp.org>
12635
12636         * lib/strcasestr.h: New file.
12637         * lib/strcasestr.c: New file.
12638
12639 2005-08-17  Bruno Haible  <bruno@clisp.org>
12640
12641         * lib/strcasecmp.c: Use mbuiter.h.
12642
12643 2005-08-17  Bruno Haible  <bruno@clisp.org>
12644
12645         * lib/mbuiter.h: New file.
12646
12647 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12648
12649         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
12650         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
12651         and gl_GETOPT are both invoked via different paths (as happens
12652         with GNU tar CVS because it uses both argp and getopt), the former
12653         wins.
12654
12655 2005-08-16  Bruno Haible  <bruno@clisp.org>
12656
12657         * modules/tls: New file.
12658         * MODULES.html.sh (Multithreading): Add tls.
12659
12660 2005-08-16  Bruno Haible  <bruno@clisp.org>
12661
12662         * modules/strnlen1: New file.
12663         * MODULES.html.sh (String handling): Add strnlen1.
12664
12665 2005-08-16  Bruno Haible  <bruno@clisp.org>
12666
12667         * modules/strcase (Files): Add m4/mbrtowc.m4.
12668         (Depends-on): Add strnlen1, mbchar.
12669
12670 2005-08-16  Bruno Haible  <bruno@clisp.org>
12671
12672         * modules/mbiter: New file.
12673         * MODULES.html.sh (Extended multibyte and wide character utilities):
12674         Add mbiter.
12675
12676 2005-08-16  Bruno Haible  <bruno@clisp.org>
12677
12678         * modules/mbfile: New file.
12679         * MODULES.html.sh (Extended multibyte and wide character utilities):
12680         Add mbfile.
12681
12682 2005-08-16  Bruno Haible  <bruno@clisp.org>
12683
12684         * modules/mbchar: New file.
12685         * MODULES.html.sh (Extended multibyte and wide character utilities):
12686         New section.
12687
12688 2005-08-16  Bruno Haible  <bruno@clisp.org>
12689
12690         * m4/tls.m4: New file, from GNU gettext.
12691
12692 2005-08-16  Bruno Haible  <bruno@clisp.org>
12693
12694         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
12695         always.
12696         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
12697
12698 2005-08-16  Bruno Haible  <bruno@clisp.org>
12699
12700         * m4/mbiter.m4: New file.
12701
12702 2005-08-16  Bruno Haible  <bruno@clisp.org>
12703
12704         * m4/mbfile.m4: New file.
12705
12706 2005-08-16  Bruno Haible  <bruno@clisp.org>
12707
12708         * m4/mbchar.m4: New file.
12709
12710 2005-08-16  Bruno Haible  <bruno@clisp.org>
12711
12712         * lib/tls.h: New file, from GNU gettext.
12713         * lib/tls.c: New file, from GNU gettext.
12714
12715 2005-08-16  Bruno Haible  <bruno@clisp.org>
12716
12717         * lib/strnlen1.h: New file.
12718         * lib/strnlen1.c: New file.
12719
12720 2005-08-16  Bruno Haible  <bruno@clisp.org>
12721
12722         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
12723         (mbi_init): Update.
12724         (mbi_avail, mbi_advance): Let the iteration end before the terminating
12725         NUL byte, not after it.
12726
12727 2005-08-16  Bruno Haible  <bruno@clisp.org>
12728
12729         * lib/strcase.h (strcasecmp): Add note in comments.
12730         * lib/strncasecmp.c: Use code from strcasecmp.c.
12731         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
12732         (strcasecmp): Work correctly in multibyte locales.
12733
12734 2005-08-16  Bruno Haible  <bruno@clisp.org>
12735
12736         * lib/mbiter.h: New file.
12737
12738 2005-08-16  Bruno Haible  <bruno@clisp.org>
12739
12740         * lib/mbfile.h: New file.
12741
12742 2005-08-16  Bruno Haible  <bruno@clisp.org>
12743
12744         * lib/mbchar.h: New file.
12745         * lib/mbchar.c: New file.
12746
12747 2005-08-16  Bruno Haible  <bruno@clisp.org>
12748
12749         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
12750         the valid ones. Makes the comparison operations transitive:
12751         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
12752         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
12753
12754 2005-08-15  Simon Josefsson  <jas@extundo.com>
12755
12756         * modules/ssize_t (License): Change to 'unlimited'.
12757
12758         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
12759
12760 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12761
12762         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
12763         Add comments for each pending glibc patch.
12764
12765 2005-08-15  Bruno Haible  <bruno@clisp.org>
12766
12767         * lib/regex.h (__restrict_arr): Don't define to __restrict if
12768         __cplusplus is defined.
12769
12770 2005-08-14  Jim Meyering  <jim@meyering.net>
12771
12772         Sync from coreutils.
12773
12774         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
12775         Use the hash-table-based cycle-detection code not just when
12776         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
12777         Reported by James Youngman in
12778         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
12779         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
12780         FTS_TIGHT_CYCLE_CHECK.
12781         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
12782         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
12783         once again.
12784         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
12785         * lib/fts.c (fd_safer): Remove decl.
12786         Include fcntl--.h rather than unistd-safer.h
12787         (fts_safe_changedir): Don't call fd_safer; no longer needed
12788         now that we include fcntl--.h.
12789
12790 2005-08-12  Simon Josefsson  <jas@extundo.com>
12791
12792         * modules/getndelim2: Use ssize_t module.
12793         * modules/getnline: Likewise.
12794         * modules/safe-read: Likewise.
12795         * modules/xreadlink: Likewise.
12796
12797         * modules/ssize_t: New file.
12798
12799 2005-08-12  Simon Josefsson  <jas@extundo.com>
12800
12801         * m4/readline.m4: Look for termcap, curses or ncurses if required.
12802
12803 2005-08-12  Simon Josefsson  <jas@extundo.com>
12804
12805         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12806         ssize_t.
12807
12808 2005-08-12  Simon Josefsson  <jas@extundo.com>
12809
12810         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
12811         readline, getdelim and check_version.
12812         (Support for systems lacking ISO C 99: Sizes of integer types):
12813         Add size_max.
12814
12815 2005-08-12  Bruno Haible  <bruno@clisp.org>
12816
12817         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
12818
12819 2005-08-11  Simon Josefsson  <jas@extundo.com>
12820
12821         * modules/readline: New file.
12822
12823         * modules/strnlen (Files): Add strnlen.h.
12824
12825 2005-08-11  Simon Josefsson  <jas@extundo.com>
12826
12827         * m4/readline.m4: New file.
12828
12829 2005-08-11  Simon Josefsson  <jas@extundo.com>
12830
12831         * lib/readline.h, readline.c: New file.
12832
12833 2005-08-11  Simon Josefsson  <jas@extundo.com>
12834
12835         * doc/gnulib.texi (Initial import, Finishing touches): Mention
12836         gl_AVOID.
12837
12838 2005-08-11  Bruno Haible  <bruno@clisp.org>
12839
12840         * lib/strnlen.h (strnlen): Change parameter name to match comment.
12841
12842 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
12843
12844         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
12845
12846 2005-08-10  Simon Josefsson  <jas@extundo.com>
12847
12848         * tests/test-iconvme.c: New file.
12849
12850 2005-08-10  Simon Josefsson  <jas@extundo.com>
12851
12852         * m4/strnlen.m4: New file.
12853
12854         * m4/strndup.m4: Don't check for strnlen declaration, done in
12855         strnlen.m4.
12856
12857 2005-08-10  Simon Josefsson  <jas@extundo.com>
12858
12859         * lib/strndup.c: Use strnlen.h.
12860
12861         * lib/strnlen.h: New file.
12862
12863 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12864
12865         * README: Typos.
12866
12867 2005-08-02  Simon Josefsson  <jas@extundo.com>
12868
12869         * modules/readline: New file.
12870
12871 2005-08-02  Simon Josefsson  <jas@extundo.com>
12872
12873         * modules/getdelim: New file.
12874
12875         * modules/getline: Rewrite, don't use getndelim2.
12876
12877 2005-08-02  Simon Josefsson  <jas@extundo.com>
12878
12879         * m4/getline.m4: Separate out getdelim stuff into separate module.
12880
12881         * m4/getdelim.m4: New file.
12882
12883 2005-08-02  Simon Josefsson  <jas@extundo.com>
12884
12885         * lib/getline.h, getline.c: Rewrite.
12886
12887         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
12888
12889 2005-07-31  Bruno Haible  <bruno@clisp.org>
12890
12891         * lib/lock.h (gl_lock_initializer): New macro.
12892         (gl_lock_define_initialized): Use it.
12893         (gl_rwlock_initializer): New macro.
12894         (gl_rwlock_define_initialized): Use it.
12895         (gl_recursive_lock_initializer): New macro.
12896         (gl_recursive_lock_define_initialized): Use it.
12897
12898 2005-07-30  Karl Berry  <karl@gnu.org>
12899
12900         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
12901         Report from Ben Pfaff, regarding getopt.
12902
12903 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
12904
12905         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
12906         normal way.
12907         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
12908         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
12909         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
12910         (gl_GETOPT): Use the new macros.  Most of the implementation
12911         is moved to the new macros.  This is for programs like Emacs
12912         that don't want all the functionality of gl_GETOPT.
12913
12914 2005-07-26  Bruno Haible  <bruno@clisp.org>
12915
12916         * m4/lock.m4: Update from GNU gettext.
12917
12918 2005-07-26  Bruno Haible  <bruno@clisp.org>
12919
12920         * lib/lock.h: Update from GNU gettext.
12921         * lib/lock.c: Update from GNU gettext.
12922
12923 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
12924
12925         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
12926         obsolescent AC_TRY_RUN.  Include the default includes files, for
12927         'exit'.
12928
12929 2005-07-24  Bruno Haible  <bruno@clisp.org>
12930
12931         * modules/visibility: New file.
12932         * MODULES.html.sh (Misc): Add visibility.
12933
12934 2005-07-24  Bruno Haible  <bruno@clisp.org>
12935
12936         * m4/visibility.m4: New file.
12937
12938 2005-07-24  Bruno Haible  <bruno@clisp.org>
12939
12940         * doc/visibility.texi: New file.
12941
12942 2005-07-22  Bruno Haible  <bruno@clisp.org>
12943
12944         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
12945         $(ALLOCA_H), redundant through BUILT_SOURCES.
12946         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
12947         redundant through BUILT_SOURCES.
12948         * modules/byteswap (Makefile.am): Remove explicit dependency on
12949         $(BYTESWAP_H), redundant through BUILT_SOURCES.
12950         * modules/fnmatch (Makefile.am): Remove explicit dependency on
12951         $(FNMATCH_H), redundant through BUILT_SOURCES.
12952         * modules/getopt (Makefile.am): Remove explicit dependency on
12953         $(GETOPT_H), redundant through BUILT_SOURCES.
12954         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
12955         redundant through BUILT_SOURCES.
12956         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
12957         redundant through BUILT_SOURCES.
12958         * modules/stdbool (Makefile.am): Remove explicit dependency on
12959         $(STDBOOL_H), redundant through BUILT_SOURCES.
12960         * modules/stdint (Makefile.am): Remove explicit dependency on
12961         $(STDINT_H), redundant through BUILT_SOURCES.
12962         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
12963         Remove explicit dependency on $(SYSEXITS_H).
12964         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
12965
12966 2005-07-18  Simon Josefsson  <jas@extundo.com>
12967
12968         * lib/check-version.c (check_version): Accept identical versions too.
12969
12970 2005-07-18  Bruno Haible  <bruno@clisp.org>
12971
12972         * modules/lock: New file.
12973         * MODULES.html.sh (Multithreading): New section.
12974
12975 2005-07-18  Bruno Haible  <bruno@clisp.org>
12976
12977         * m4/lock.m4: New file, from GNU gettext.
12978
12979 2005-07-18  Bruno Haible  <bruno@clisp.org>
12980
12981         * lib/lock.h: New file, from GNU gettext.
12982         * lib/lock.c: New file, from GNU gettext.
12983
12984 2005-07-18  Bruno Haible  <bruno@clisp.org>
12985
12986         * lib/lock.h (gl_once_t): New type.
12987         (gl_once_define, gl_once): New macros.
12988         * lib/lock.c (fresh_once): New variable.
12989         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
12990         functions.
12991
12992 2005-07-16  Simon Josefsson  <jas@extundo.com>
12993
12994         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
12995         workaround, suggested by Bruno.
12996
12997 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
12998
12999         * modules/xalloc (Depends-on): Add xalloc-die.
13000         * modules/xvasprintf (Depends-on): Add xalloc-die.
13001
13002 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
13003
13004         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
13005         with a minor change.
13006
13007 2005-07-15  Bruno Haible  <bruno@clisp.org>
13008
13009         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
13010         When using lib/poll.c, define poll as rpl_poll.
13011
13012 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
13013
13014         * modules/argp (Depends-on): Remove unlocked-io.
13015
13016 2005-07-14  Derek Price  <derek@ximbiot.com>
13017
13018         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
13019         for glob symlink bug.
13020
13021 2005-07-14  Bruno Haible  <bruno@clisp.org>
13022
13023         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
13024         Instead, test for *_unlocked function declarations directly.
13025
13026 2005-07-11  Simon Josefsson  <jas@extundo.com>
13027
13028         * modules/size_max: New file.
13029
13030         * modules/xsize: Depend on size_max module for size_max.m4.
13031
13032 2005-07-11  Simon Josefsson  <jas@extundo.com>
13033
13034         * lib/size_max.h: New file.
13035
13036 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
13037
13038         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
13039         copyright symbol and the year.
13040         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
13041         (version_etc_va): Use parameterized copyright notice.
13042         Reword to conform to the current GNU coding standards.
13043
13044 2005-07-11  Karl Berry  <karl@gnu.org>
13045
13046         * doc/gnulib.texi (Quoting): new node.
13047         (Initial import): more info, from Patrice.
13048
13049 2005-07-11  Bruno Haible  <bruno@clisp.org>
13050
13051         * gnulib-tool (func_usage): Document option --avoid.
13052         (Command line options): Handle --avoid.
13053         (func_acceptable): New function.
13054         (func_modules_transitive_closure): Use it.
13055
13056 2005-07-11  Bruno Haible  <bruno@clisp.org>
13057
13058         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
13059         Reported by Jim Meyering.
13060
13061 2005-07-10  Bruno Haible  <bruno@clisp.org>
13062
13063         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
13064         Needed when size_t is smaller than 'unsigned int'.
13065         Reported by Paul Eggert.
13066
13067 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13068
13069         * modules/argp (Depends-on): Add unlocked-io
13070
13071 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13072
13073         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
13074         block of defines.
13075
13076 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
13077
13078         * config/srclist.txt: Comment out regcomp.c, since we have a porting
13079         fix now.
13080
13081 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
13082         and Paul Eggert  <eggert@cs.ucla.edu>
13083
13084         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
13085         in wint_t, not wchar_t.  Remove now-unnecessary cast.
13086
13087 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
13088
13089         * modules/regex (Files): Add lib/regex_internal.c,
13090         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
13091         (Depends-on): Add extensions.
13092         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
13093
13094 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
13095
13096         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
13097         pathconf.
13098         * m4/same.m4 (gl_SAME): Likewise.
13099         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
13100
13101         * m4/regex.m4: Adjust to new libc regex implementation.
13102         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
13103         all the .c and .h parts of (the new) regex.
13104         Quote the m4 stuff better.
13105         Check for RE_ICASE bug of old gnulib.
13106         Check for REG_STARTEND of recent libc.
13107         Rename local variables from jm_* to gl_*.
13108         Quote operand of "test -f".
13109         Say "recent enough" version of libc, not "version 2".
13110         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
13111         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
13112         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
13113         Remove check for btowc, isascii.
13114         Require AM_LANGINFO_CODESET.
13115
13116 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
13117
13118         * lib/regex.c, regex.h: Sync from libc.
13119         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
13120         * lib/regexec.c:
13121         New files, synced from libc, except that regex_internal.h
13122         currently has a small porting fix.
13123
13124 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
13125
13126         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
13127         regex_internal.c, regexec.c.
13128         Add regex_internal.h too, but as a comment, since the libc version
13129         is currently broken in gnulib mode.
13130
13131 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13132
13133         Support programs like Emacs that use gnulib but not gettext.
13134         * MODULES.html.sh (Internationalization functions): Add gettext-h.
13135         * modules/gettext-h: New file.
13136         * modules/gettext (Files): Remove lib/gettext.h.
13137         (Depends-on): Add gettext-h.
13138         (Makefile.am): Remove lib_SOURCES.
13139         * modules/argmatch, modules/c-stack, modules/closeout:
13140         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
13141         * modules/execute, modules/file-type, modules/getaddrinfo:
13142         * modules/getopt, modules/human, modules/javacomp:
13143         * modules/javaexec, modules/mkdir-p, modules/obstack:
13144         * modules/openat, modules/pagealign_alloc, modules/pipe:
13145         * modules/quotearg, modules/regex, modules/rpmatch:
13146         * modules/unicodeio, modules/userspec, modules/version-etc:
13147         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
13148         * modules/xsetenv:
13149         Depend on gettext-h, not gettext.
13150
13151 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13152
13153         * gnulib-tool (func_import): Add support for 'public domain' license.
13154         * modules/alloca, modules/atexit, modules/memmove:
13155         Now public domain, not GPL.
13156         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
13157         * modules/realloc, modules/strerror, modules/strtod:
13158         Now LGPL, not GPL.
13159
13160 2005-07-05  Bruno Haible  <bruno@clisp.org>
13161
13162         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
13163         autoconf CVS. Needed for mingw.
13164
13165 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13166
13167         Remove the dependency of the strftime module on the tzset module.
13168         * modules/strftime (Depends-on): Remove dependency on tzset.
13169
13170 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13171
13172         Remove the dependency of the strftime module on the tzset module.
13173         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
13174         gl_FUNC_TZSET_CLOBBER.
13175
13176 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13177
13178         Remove the dependency of the strftime module on the tzset module.
13179         * lib/strftime.c (my_strftime)
13180         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
13181         Copy the input structure, to work around some of the bug with
13182         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
13183         Solaris releases, you should also use the tzset module, but we won't
13184         require it as a dependency any more since we don't want LGPLed code
13185         to depend on GPLed code.
13186
13187 2005-07-02  Jim Meyering  <jim@meyering.net>
13188
13189         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
13190         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
13191         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
13192         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
13193
13194 2005-07-02  Jim Meyering  <jim@meyering.net>
13195
13196         * lib/backupfile.c (backup_args): Change a `0' to NULL.
13197
13198 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13199
13200         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
13201         declares only 'struct timespec;' (!).
13202
13203 2005-07-01  Jim Meyering  <jim@meyering.net>
13204
13205         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
13206         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
13207         * lib/save-cwd.c, tempname.c:
13208         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
13209         and don't include <sys/file.h>).
13210
13211 2005-06-29  Jim Meyering  <jim@meyering.net>
13212
13213         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
13214         type name.  Use the variable name instead.
13215         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
13216         Likewise.
13217
13218 2005-06-28  Simon Josefsson  <jas@extundo.com>
13219
13220         * modules/check-version (Files): Add check-version.m4.
13221
13222 2005-06-28  Simon Josefsson  <jas@extundo.com>
13223
13224         * m4/check-version.m4: New file, suggested by Jim Meyering
13225         <jim@meyering.net>.
13226
13227 2005-06-28  Simon Josefsson  <jas@extundo.com>
13228
13229         * lib/check-version.h, lib/check-version.c: New files.
13230
13231 2005-06-28  Simon Josefsson  <jas@extundo.com>
13232
13233         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
13234         collision with global variable.  Better indentation.  Don't
13235         increment buffer pointer beyond buffer end.  Based on comments
13236         from Paul Eggert <eggert@cs.ucla.edu>.
13237
13238         * lib/base64.h: Indent.
13239
13240 2005-06-28  Simon Josefsson  <jas@extundo.com>
13241
13242         * doc/gnulib.texi (Library version handling): New section.
13243
13244 2005-06-28  Jim Meyering  <jim@meyering.net>
13245
13246         * check-module (find_included_lib_files): Hard-code another
13247         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
13248         but modules/fts-lgpl (correctly) does not list those files.
13249
13250         * modules/canonicalize (Files): Add lib/pathmax.h.
13251
13252 2005-06-25  Simon Josefsson  <jas@extundo.com>
13253
13254         * modules/check-version: New file.
13255
13256 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
13257
13258         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
13259         initializer of struct addrinfo, as an indication that we don't
13260         care how many members the structure has.
13261
13262 2005-06-24  Derek Price  <derek@ximbiot.com>
13263         and Bruno Haible  <bruno@clisp.org>
13264
13265         Remove stat module & update lstat.
13266         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
13267         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
13268         * m4/stat.m4: Remove this file.
13269
13270 2005-06-24  Derek Price  <derek@ximbiot.com>
13271         and Bruno Haible  <bruno@clisp.org>
13272
13273         Remove stat module & update lstat.
13274         * lib/stat.c: Remove this file...
13275         (slash_aware_lstat): ...moving this content and its support...
13276         * lib/lstat.c (rpl_lstat): ...into here.
13277         * lib/lstat.h: New file.
13278
13279 2005-06-24  Derek Price  <derek@ximbiot.com>
13280         and Bruno Haible  <bruno@clisp.org>
13281
13282         Remove stat module & update lstat.
13283         * config/srclist.txt (libc sources): Remove stat.
13284
13285 2005-06-24  Derek Price  <derek@ximbiot.com>
13286         and Bruno Haible  <bruno@clisp.org>
13287
13288         Remove stat module & update lstat.
13289         * MODULES.html.sh (stat): Remove.
13290         * MODULES.html: Regenerated.
13291         * modules/lstat (Description): Correct function name.
13292         (Files): Add "lstat.h".
13293         (Depends-on): Remove stat, add xalloc, stat-macros.
13294         * modules/stat: Remove this file.
13295         (Include): Add "lstat.h", remove <sys/stat.h>.
13296
13297 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
13298
13299         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
13300         (ranged_convert): Don't save conversion in a temporary struct.
13301         This causes a warning with GCC 4.0.0, and anyway in the typical
13302         case it's not worth the extra 100 bytes or so of code.
13303         (ranged_convert, __mktime_internal): When calling a function via a
13304         pointer P, use P () rather than (*P) (), as we now assume C89 or
13305         better.
13306
13307 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
13308
13309         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
13310         "who -r" failed to give output.  Problem reported by Tim Waugh.
13311
13312         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
13313         (xcalloc): Use it to avoid needless tests.
13314         Problem reported by Jim Meyering.
13315
13316 2005-06-20  Derek Price  <derek@ximbiot.com>
13317
13318         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
13319         unnecessary for Autoconfs > 2.59c.
13320
13321 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13322
13323         * lib/argp.h (__option_is_short): Check upper limit of
13324         __key. Isprint() requires its argument to have the value
13325         of an unsigned char or EOF.
13326
13327 2005-06-16  Jim Meyering  <jim@meyering.net>
13328
13329         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
13330         when either N or S is zero.
13331
13332 2005-06-16  Derek Price  <derek@ximbiot.com>
13333
13334         * m4/bison.m4: Declare YACC & YFLAGS precious.
13335
13336 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
13337
13338         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
13339         multibyte string or pattern, fall back on unibyte matching.
13340         Problem reported by James Youngman.
13341
13342 2005-06-08  Bruno Haible  <bruno@clisp.org>
13343
13344         * modules/csharpcomp: New file.
13345         * MODULES.html.sh (C#): Add csharpcomp.
13346
13347 2005-06-08  Bruno Haible  <bruno@clisp.org>
13348
13349         * m4/csharpcomp.m4: New file, from GNU gettext.
13350
13351 2005-06-08  Bruno Haible  <bruno@clisp.org>
13352
13353         * lib/csharpcomp.h: New file, from GNU gettext.
13354         * lib/csharpcomp.c: New file, from GNU gettext.
13355         * lib/csharpcomp.sh.in: New file, from GNU gettext.
13356
13357 2005-06-08  Bruno Haible  <bruno@clisp.org>
13358
13359         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
13360         warning on mingw.
13361
13362 2005-06-07  Derek Price  <derek@ximbiot.com>
13363
13364         Sync from CVS.
13365         * lib/glob_.h: Indent nested #ifdef.
13366
13367 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13368
13369         Sync from coreutils.
13370         Use "file name" when talking about file names, instead of "filename"
13371         or "path", as per the GNU coding standards.
13372         * lib/mkdir-p.c: Renamed from makepath.c.
13373         (make_dir_parents): Renamed from make_path.  All callers changed.
13374         * lib/mkdir-p.h: Likewise.  All includers changed.
13375         * lib/filenamecat.c: Renamed from path-concat.c.
13376         (file_name_concat): Renamed from path_concat.  All callers changed.
13377         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
13378         * lib/filenamecat.h: Likewise.  All includers changed.
13379         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
13380         in comments or local variable names.
13381         * lib/basename.c: Likewise.
13382         * lib/canonicalize.c, canonicalize.h: Likewise.
13383         * lib/dirname.c, dirname.h: Likewise.
13384         * lib/euidaccess.c: Likewise.
13385         * lib/exclude.c: Likewise
13386         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
13387         * lib/fsusage.c, fsuage.h: Likewise.
13388         * lib/fts.c, fts_.h: Likewise.
13389         * lib/getcwd.c: Likewise.
13390         * lib/getloadavg.c: Likewise.
13391         * lib/mkstemp.c: Likewise.
13392         * lib/mountlist.c, mountlist.h: Likewise.
13393         * lib/openat.c, openat.h: Likewise.
13394         * lib/readlink-stub.c: Likewise.
13395         * lib/readutmp.c, readutmp.h: Likewise.
13396         * lib/rename.c: Likewise.
13397         * lib/rmdir.c: Likewise.
13398         * lib/same.c: Likewise.
13399         * lib/savedir.c: Likewise.
13400         * lib/stripslash.c: Likewise.
13401         * lib/tempname.c: Likewise.
13402         * lib/xreadlink.c: Likewise.
13403         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
13404         All uses changed.
13405         * lib/exclude.h: Likewise.
13406
13407         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
13408         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13409         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
13410         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13411         * lib/pathmax.h: Include <limits.h> unconditionally, since other
13412         files have been getting away with it for years (MORE/BSD 4.3
13413         is extinct now).
13414         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
13415         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13416
13417         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
13418         Define to 256, not 255, as per modern POSIX.
13419
13420 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13421
13422         Sync from coreutils.
13423         Use "file name" when talking about file names, instead of "filename"
13424         or "path", as per the GNU coding standards.
13425         * MODULES.html.sh: mkdir-p renamed from makepath.
13426         filenamecat renamed from path-concat.
13427         * modules/filenamecat: Renamed from modules/path-concat.
13428         (Files): filenamecat.h and filenamecat.c renamed from
13429         path-concat.h and path-concat.c.
13430         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
13431         (Include): filenamecat.h, not path-concat.h.
13432         * modules/mkdir-p: Renamed from modules/makepath.
13433         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
13434         makepath.c.
13435         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
13436         (Include): mkdir-p.h, not makepath.h.
13437
13438 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13439
13440         Sync from coreutils.
13441         * m4/mkdir-p.m4: Renamed from makepath.m4.
13442         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
13443         Rename files from makepath.c to mkdir-p.c, and from
13444         makepath.h to mkdir-p.h.
13445         * m4/filenamecat.m4: Renamed from path-concat.m4.
13446         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
13447         Rename files from path-concat.c to filenamecat.c,
13448         and from path-concat.h to filenamecat.h.
13449         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
13450         "file name" in local variables or comments.
13451         * m4/rename.m4: Likewise.
13452
13453 2005-06-01  Bruno Haible  <bruno@clisp.org>
13454
13455         * modules/csharpexec: New file.
13456         * MODULES.html.sh (C#): New section.
13457
13458 2005-06-01  Bruno Haible  <bruno@clisp.org>
13459
13460         * m4/csharp.m4: New file, from GNU gettext.
13461         * m4/csharpexec.m4: New file, from GNU gettext.
13462
13463 2005-06-01  Bruno Haible  <bruno@clisp.org>
13464
13465         * lib/csharpexec.h: New file, from GNU gettext.
13466         * lib/csharpexec.c: New file, from GNU gettext.
13467         * lib/csharpexec.sh.in: New file, from GNU gettext.
13468
13469 2005-05-31  Derek Price  <derek@ximbiot.com>
13470             Paul Eggert  <eggert@cs.ucla.edu>
13471
13472         Sync from cvs.
13473         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
13474
13475 2005-05-31  Derek Price  <derek@ximbiot.com>
13476             Paul Eggert  <eggert@cs.ucla.edu>
13477
13478         Sync from cvs.
13479         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
13480
13481 2005-05-29  Derek Price  <derek@ximbiot.com>
13482
13483         * config/srclist.txt (glob_.h, glob.c): Add these files.
13484
13485 2005-05-29  Derek Price  <derek@ximbiot.com>
13486
13487         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
13488         * modules/glob: New file.
13489         * modules/getlogin_r: Add link to POSIX spec in description.
13490
13491 2005-05-29  Derek Price  <derek@ximbiot.com>
13492             Paul Eggert  <eggert@cs.ucla.edu>
13493
13494         * m4/glob.m4: New file.
13495
13496 2005-05-29  Derek Price  <derek@ximbiot.com>
13497             Paul Eggert  <eggert@cs.ucla.edu>
13498
13499         * lib/glob_.h, lib/glob.c: New files.
13500
13501 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13502
13503         * modules/fts (Files): Remove m4/inttypes-pri.m4.
13504         * modules/fts-lgpl (Depends-on): Remove gettext.
13505
13506 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13507
13508         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
13509         and don't require gt_INTTYPES_PRI.
13510
13511 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13512
13513         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
13514
13515         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
13516         the configuration hassle isn't worth it.
13517         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
13518         (LONGEST_MODIFIER, PRIuMAX): Remove.
13519
13520 2005-05-27  Bruno Haible  <bruno@clisp.org>
13521
13522         * lib/getlogin_r.h: Remove second include of <stddef.h>.
13523
13524 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
13525
13526         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
13527         _POSIX_PTHREAD_SEMANTICS for Solaris.
13528
13529 2005-05-25  Derek Price  <derek@ximbiot.com>
13530
13531         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
13532
13533 2005-05-25  Derek Price  <derek@ximbiot.com>
13534             Paul Eggert  <eggert@cs.ucla.edu>
13535
13536         * modules/getlogin_r, m4/getlogin_r.m4: New files.
13537         * lib/getlogin_r.c, getlogin_r.h: New files.
13538
13539 2005-05-25  Bruno Haible  <bruno@clisp.org>
13540             Derek Price  <derek@ximbiot.com>
13541
13542         * lib/getlogin_r.h: Simplify API documentation.
13543
13544 2005-05-23  Derek Price  <derek@ximbiot.com>
13545
13546         * modules/minmax (Files): Add m4/minmax.m4.
13547         (configure.ac): Add gl_MINMAX.
13548
13549 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13550
13551         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
13552         so that unistd-safer.h (GPL'ed code) need not be included.
13553
13554 2005-05-22  Bruno Haible  <bruno@clisp.org>
13555
13556         * m4/minmax.m4: New file.
13557         Based on a patch by Derek Price <derek@ximbiot.com>.
13558
13559 2005-05-22  Bruno Haible  <bruno@clisp.org>
13560
13561         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
13562         (INT64_MIN): Fix definition.
13563         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
13564
13565         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
13566         NEED_SIGNED_INT_TYPES.
13567
13568         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
13569         HAVE_SYSTEM_INTTYPES.
13570
13571 2005-05-22  Bruno Haible  <bruno@clisp.org>
13572
13573         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
13574         Also include <sys/param.h> if it defines MIN, MAX.
13575         Based on a patch by Derek Price <derek@ximbiot.com>.
13576
13577 2005-05-21  Jim Meyering  <jim@meyering.net>
13578
13579         * modules/fts (Files): Add m4/inttypes-pri.m4.
13580         (Depends-on): Add lstat and remove gettext.  Alphabetize.
13581
13582 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13583
13584         New fts module.
13585         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
13586         (setup_dir, free_dir): New functions.
13587         (enter_dir, leave_dir): Define trivial
13588         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
13589         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
13590         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
13591         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
13592         Move to fts-cycle.c.
13593         (fts_open): Use setup_dir.
13594         (fts_close): Use free_dir.
13595         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
13596         This adds a label and some gotos, but the alternatives were messier.
13597         Check for memory allocation failure when entering a dir.
13598         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
13599         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
13600         (FTS): New member fts_cycle, that is a union that contains the
13601         old active_dir_ht and cycle_state.  All uses changed to mention
13602         fts_cycle.ht and fts_cycle.state.
13603         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
13604         fts.c, with the following changes:
13605         (setup_dir, free_dir): New functions.
13606         (enter_dir): Now returns bool.  Return true if successful, false
13607         if memory exhausted.  All callers changed.
13608         Do not bother partly cleaning up on
13609         memory allocation failure; that is free_dir's job.
13610         However, free ad if hash_insert fails, to avoid memory leak.
13611         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
13612         fts->fts_options to see which union member to use.
13613
13614 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13615
13616         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
13617         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
13618
13619 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13620
13621         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
13622
13623 2005-05-20  Jim Meyering  <jim@meyering.net>
13624
13625         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
13626         Now a macro, to pacify GCC.
13627
13628 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
13629
13630         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
13631         of -1.
13632
13633 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
13634
13635         * lib/chown.c (rpl_chown): Return -1 on failure.
13636
13637 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
13638
13639         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
13640         Don't check for stddef.h.
13641         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
13642         don't use its results.
13643         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
13644         since we include them unconditionally.  Don't require
13645         AM_STDBOOL_H, since stdbool is a prerequisite.
13646         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
13647         since we assume C89 or better.
13648         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
13649         as we don't use their results.
13650         Don't check for fchdir, memmove, memset, strrchr, as we use
13651         them unconditionally.
13652         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
13653         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
13654
13655 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
13656
13657         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
13658         Include <stddef.h> unconditionally, since we assume C89 now.
13659         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
13660         * lib/fts.c: Include fts_.h first, to check interface.
13661         Do not include intprops.h; no longer needed.
13662         Include cycle-check.h and hash.h, since fts_.h no longer does.
13663         Remove unnecessary casts of closedir to void.
13664         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
13665         decide whether to decrement nlinks.
13666         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
13667         (FTS): Use struct hash_table * instead of Hash_table, so that
13668         we no longer need to include hash.h here.
13669
13670 2005-05-18  Jim Meyering  <jim@meyering.net>
13671
13672         * modules/dirfd (License): Change to LGPL.  Most of the code
13673         is already in the public domain.
13674
13675 2005-05-18  Jim Meyering  <jim@meyering.net>
13676
13677         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
13678         Reported by Yoann Vandoorselaere.
13679
13680 2005-05-17  Jim Meyering  <jim@meyering.net>
13681
13682         * m4/fts.m4: New file, from coreutils.
13683
13684 2005-05-17  Jim Meyering  <jim@meyering.net>
13685
13686         * lib/fts.c, lib/fts_.h: New files, from coreutils.
13687
13688 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13689
13690         Sync from coreutils.
13691         * m4/unlinkdir.m4: New file.
13692
13693 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13694
13695         Sync from coreutils.
13696         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
13697         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
13698         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
13699         White space changes only.
13700         * lib/makepath.c (make_path): Port to hosts where leading "//" is
13701         special.
13702         * lib/yesno.c: Include getline.h, not ctype.h.
13703         (yesno): Don't remove leading white space; POSIX doesn't allow it.
13704         Use getline to remove arbitrary restriction on response length.
13705
13706 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13707
13708         * config/srclist-update: Spell out "Street" in FSF postal
13709         mail address; this is the style the FSF seems to prefer.
13710
13711         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
13712         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
13713         this updates FSF postal mail address.
13714
13715         Sync from coreutils.
13716         * modules/unlinkdir: New file.
13717         * modules/yesno (Depends-on): Add getline.
13718         * MODULES.html.sh (File system functions): Add unlinkdir.
13719
13720 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
13721
13722         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
13723         lib/strsep.h:
13724         Change the initial comment to refer to GPL, not LGPL.
13725         gnulib-tool will change it to LGPL as needed.
13726
13727         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
13728         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
13729         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
13730         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
13731         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
13732         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
13733         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
13734         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
13735         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
13736         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
13737         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
13738         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
13739         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
13740         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
13741         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
13742         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
13743         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
13744         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
13745         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
13746         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
13747         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
13748         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
13749         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
13750         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
13751         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
13752         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
13753         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
13754         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
13755         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
13756         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
13757         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
13758         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
13759         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
13760         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
13761         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
13762         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
13763         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
13764         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
13765         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
13766         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
13767         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
13768         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
13769         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
13770         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
13771         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
13772         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
13773         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
13774         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
13775         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
13776         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
13777         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
13778         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
13779         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
13780         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
13781         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
13782         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
13783         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
13784         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
13785         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
13786         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
13787         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
13788         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
13789         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
13790         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
13791         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
13792         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
13793         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
13794         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
13795         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
13796         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
13797         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
13798         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
13799         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
13800         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
13801         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
13802         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
13803         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
13804         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
13805         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
13806         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
13807         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
13808         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
13809         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
13810         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
13811         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
13812         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
13813         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
13814         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
13815         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
13816         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
13817         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
13818         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
13819         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
13820         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
13821         lib/yesno.c, lib/yesno.h:
13822         Update FSF postal mail address.
13823
13824 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
13825
13826         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
13827         tests/test-memmem.c, tests/test-stpncpy.c:
13828         Update FSF postal mail address.
13829
13830 2005-05-13  Bruno Haible  <bruno@clisp.org>
13831
13832         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
13833         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
13834         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
13835         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
13836         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
13837         Add support for 64-bit integers in the MSVC compiler.
13838
13839 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13840
13841         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
13842
13843 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
13844
13845         * gnulib-tool (func_import): Sort and uniquify recommended includes.
13846
13847 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
13848
13849         * doc/getdate.texi (General date syntax): Don't say that date
13850         date --iso-8601=ns generates acceptable dates; it doesn't yet.
13851         Problem reported by Nic Ferrier.
13852
13853 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13854
13855         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
13856         specified in ai_socktype. Fix invalid ai_protocol
13857         check. ai_protocol is usually set to 0 or depending on
13858         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
13859         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
13860         ai_socktype / ai_protocol in the returned addrinfo structure.
13861
13862 2005-05-10  Simon Josefsson  <jas@extundo.com>
13863
13864         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
13865         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
13866
13867 2005-05-10  Karl Berry  <karl@gnu.org>
13868
13869         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
13870         (from http://www.gnu.org/licenses).
13871         * doc/COPYING.LIB: also rename to COPYING.LESSER.
13872         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
13873         fdl.texi suffices.
13874
13875 2005-05-10  Karl Berry  <karl@gnu.org>
13876
13877         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
13878         (COPYING.DOC): remove.
13879
13880         * config/srclist-update: new FSF address.
13881
13882 2005-05-10  Derek Price  <derek@ximbiot.com>
13883
13884         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
13885         possible.
13886
13887 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13888             Bruno Haible  <bruno@clisp.org>
13889
13890         * modules/inet_ntop: New file.
13891         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
13892         inet_ntop.
13893
13894 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13895             Bruno Haible  <bruno@clisp.org>
13896
13897         * m4/inet_ntop.m4: New file.
13898
13899 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13900             Bruno Haible  <bruno@clisp.org>
13901
13902         * lib/inet_ntop.h: New file.
13903         * lib/inet_ntop.c: New file, from glibc with modifications.
13904
13905 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
13906
13907         * modules/time_r (License): Change to LGPL.
13908         * modules/extensions (License): Change to LGPL.  Actually,
13909         the license is more permissive than that, but currently gnulib-tool
13910         doesn't know how to handle more-permissive licenses.
13911
13912         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
13913         Problem reported by Dave Love.
13914
13915 2005-05-08  Jim Meyering  <jim@meyering.net>
13916
13917         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
13918         blank.
13919
13920 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
13921
13922         * modules/argmatch (Depends-on): Add stdbool.
13923         * modules/backupfile (Depends-on): Likewise.
13924         * modules/chdir-long (Depends-on): Likewise.
13925         * modules/closeout (Depends-on): Likewise.
13926         * modules/cycle-check (Depends-on): Likewise.
13927         * modules/dirname (Depends-on): Likewise.
13928         * modules/fnmatch (Depends-on): Likewise.
13929         * modules/fsusage (Depends-on): Likewise.
13930         * modules/fwriteerror (Depends-on): Likewise.
13931         * modules/getcwd (Depends-on): Likewise.
13932         * modules/getloadavg (Depends-on): Likewise.
13933         * modules/hard-locale (Depends-on): Likewise.
13934         * modules/makepath (Depends-on): Likewise.
13935         * modules/mountlist (Depends-on): Likewise.
13936         * modules/nanosleep (Depends-on): Likewise.
13937         * modules/posixtm (Depends-on): Likewise.
13938         * modules/quotearg (Depends-on): Likewise.
13939         * modules/readtokens (Depends-on): Likewise.
13940         * modules/readtokens0 (Depends-on): Likewise.
13941         * modules/readutmp (Depends-on): Likewise.
13942         * modules/save-cwd (Depends-on): Likewise.
13943         * modules/strftime (Depends-on): Likewise.
13944         * modules/userspec (Depends-on): Likewise.
13945         * modules/utimecmp (Depends-on): Likewise.
13946         * modules/xgetcwd (Depends-on): Likewise.
13947         * modules/xnanosleep (Depends-on): Likewise.
13948         * modules/xstrtod (Depends-on): Likewise.
13949         * modules/yesno (Depends-on): Likewise.
13950
13951 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
13952
13953         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
13954         needless checks.
13955
13956 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13957
13958         Merge from coreutils.  Among other things,
13959         add bulletproofing for cases where stdin, stdout, or stderr are closed.
13960         * lib/fd-safer.c: New file.
13961         * lib/fcntl-safer.h, open-safer.c: Remove.
13962         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
13963         * lib/dup-safer.c: Include unistd-safer.h first.
13964         Don't include errno.h.
13965         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
13966         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
13967         * lib/file-type.c: Rely on file-type.h change.
13968         * lib/getloadavg.c: Include unistd-safer.h.
13969         (getloadavg): Use safer open.
13970         * lib/getusershell.c: Include "stdio-safer.h".
13971         (getusershell): Use safer fopen.
13972         * lib/long-options.c (long_options): Use NULL rather than 0.
13973         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
13974         'free'.
13975         * lib/modechange.c: Likewise.
13976         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
13977         (MODE_DONE): New constant.
13978         (struct mode_change): Remove 'next' member.
13979         (make_node_op_equals): New function; like the old one of the
13980         same name, except it allocates an array.
13981         (mode_compile, mode_create_from_ref): Use it.
13982         (mode_compile): Allocate result as an array, not a linked list.
13983         Parse octal string ourself, so that we catch mistakes like "+0".
13984         (mode_adjust): Arg is an array, not a linked list.
13985         * lib/modechange.c: Include stat-macros.h, xalloc.h.
13986         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
13987         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
13988         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
13989         Remove.  This is now stat-macros.h's job.
13990         (talloc): Remove.  All callers replaced by xalloc, so that
13991         our invokers don't have to worry about reporting memory failures.
13992         (make_node_op_equals): Remove.
13993         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
13994         New constants.
13995         (struct mode_change): Moved here from modechange.h.
13996         (mode_append_entry): Remove.
13997         (mode_compile): Remove MASKED_OPS arg, since it encouraged
13998         apps to have incorrect behavior.  Use simpler algorithm for head
13999         and tail.  Don't futz with umask; that's now the job of mode_adjust.
14000         Detect more invalid usages rather than having somewhat-random behavior.
14001         Don't insert an "a=" action, as that leads to incorrect behavior.
14002         (mode_compile, mode_create_from_ref): Return NULL on error instead
14003         of an enum, since now there's only one way to have an error.  All
14004         callers changed.
14005         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
14006         at the correct time.  Simplify calculation of "+u" and its ilk.
14007         Don't mishandle "+X".
14008         (mode_free): Remove "register" and localize decls.
14009         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
14010         (struct mode_change): Move to modechange.c; callers don't
14011         need to see this stuff.
14012         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
14013         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
14014         (mode_change, mode_adjust): Reflect the new signatures noted above.
14015         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
14016         that might redefine system include files.
14017         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
14018         (my_usleep): Use NULL rather than (void *) 0.
14019         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
14020         Use siginterrupt to specify that system calls should be interrupted.
14021         (rpl_nanosleep): Move initialization of suspended closer to call of
14022         my_usleep.
14023         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
14024         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
14025         (desirable_utmp_entry): New function.
14026         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
14027         using x2nrealloc, to simplify logic.
14028         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
14029         size calculation.  Do not assume utmp file is a regular file.
14030         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
14031         (READ_UTMP_CHECK_PIDS): New constant.
14032         * lib/save-cwd.c: Include unistd-safer.h.
14033         (save_cwd): Use fd_safer.
14034         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
14035         [!_LIBC] Include "stat-macros.h" instead.
14036         * lib/unistd-safer.h (fd_safer): New decl.
14037
14038 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
14039
14040         * modules/getloadavg (Depends-on): Add unistd-safer.
14041         * modules/getusershell (Depends-on): Add stdio-safer.
14042         * modules/lstat (Depends-on): Remove xalloc.
14043         * modules/mkstemp (Depends-on): Add stat-macros.
14044         * modules/modechange (Depends-on): Remove xstrtol.
14045         Add stat-macros, xalloc.
14046         * modules/save-cwd (Depends-on): Add unistd-safer.
14047         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
14048         * modules/unistd-safer (Files): Add lib/fd-safer.c
14049         (Makefile.am): Remove lib_SOURCES.
14050
14051         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
14052         Remove fcntl-safer; unistd-safer supersedes it.
14053
14054 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
14055
14056         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
14057         AC_HEADER_STAT.
14058         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
14059         (gl_PREREQ_CHOWN): Remove.
14060         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
14061         it.  Don't require AC_HEADER_STAT.
14062         (gl_PREREQ_LSTAT): Remove.
14063         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
14064         Don't require AC_HEADER_STAT.
14065         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
14066         (gl_PREREQ_RMDIR): Remove.
14067         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
14068         mention stat-macros.h or AC_HEADER_STAT, since we'll make
14069         the stat-macros module a prerequisite.
14070         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
14071         * m4/filemode.m4 (gl_FILEMODE): Likewise.
14072         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
14073         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
14074         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
14075         variable names.
14076         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
14077         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
14078         variable prefixes.
14079         * m4/fcntl-safer.m4: Remove.
14080         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
14081         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
14082         Invoke gl_PREREQ_FD_SAFER.
14083         (gl_PREREQ_FD_SAFER): New macro.
14084         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
14085         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
14086         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
14087         Remove duplicate call to AC_LIBOBJ(readutmp).
14088         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
14089
14090         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
14091         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
14092
14093 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
14094
14095         * MODULES.html.sh (Misc): Add byteswap.
14096
14097 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
14098
14099         * modules/getcwd (Depends-on): Add extensions.
14100         * modules/openat (Depends-on): Likewise.
14101
14102 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
14103
14104         * modules/byteswap: New file.
14105
14106 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
14107
14108         * m4/byteswap.m4: New file.
14109
14110 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
14111
14112         * lib/byteswap_.h: New file.
14113
14114 2005-04-25  Karl Berry  <karl@gnu.org>
14115
14116         * m4/gettext.m4: Update from GNU gettext 0.14.4.
14117
14118 2005-04-25  Albert Chin  <china@thewrittenword.com>
14119
14120         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
14121         Toolkit C bug.
14122
14123 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
14124
14125         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
14126         (func_ln_if_changed) Remove forcibly for no error message
14127         in case file does not exist.
14128
14129 2005-04-19  Simon Josefsson  <jas@extundo.com>
14130
14131         * gnulib-tool (Options): Make --symlink mean --symbolic.
14132
14133 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
14134
14135         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
14136
14137 2005-04-16  Simon Josefsson  <jas@extundo.com>
14138
14139         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
14140
14141 2005-04-15  Simon Josefsson  <jas@extundo.com>
14142
14143         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
14144
14145 2005-04-15  Simon Josefsson  <jas@extundo.com>
14146
14147         * gnulib-tool: Rename --symlink to --symbolic.
14148
14149 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
14150
14151         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
14152         symbolic links to files instead of copying/moving.  Add --aux-dir,
14153         specifying directory relative --dir where auxiliary build tools
14154         are placed.
14155
14156 2005-04-14  Bruno Haible  <bruno@clisp.org>
14157
14158         * modules/allocsa (License): Change to LGPL.
14159         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
14160
14161 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14162
14163         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
14164         that "UTC +1 second" continues to work.  Problem reported
14165         by Dmitry V. Levin.
14166         (relunit_snumber): New rule.
14167         (relunit): Use it.
14168
14169 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
14170
14171         * lib/getdate.y (universal_time_zone_table): New constant.
14172         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
14173         universal_time_zone_table.
14174         (lookup_zone): Prefer universal_time_zone_table to
14175         local_time_zone_table, so that "GMT" time stamps are allowed in
14176         London during the summer.  Problem reported by Ian Abbott.
14177
14178 2005-04-12  Jim Meyering  <jim@meyering.net>
14179
14180         * lib/human.c (humblock): Set *options even when returning due to
14181         xstrtoumax conversion failure.  Thanks to a used-uninitialized
14182         warning from gcc-4.
14183
14184 2005-04-09  Jim Meyering  <jim@meyering.net>
14185
14186         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
14187         -Wuninitialized: initialize tm0.tm_year.
14188
14189 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
14190
14191         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
14192         count, since there's no maximum.  All uses changed.
14193         Add member dsts_seen.
14194         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
14195         not being INT_MAX.
14196         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
14197         Use pc_rels_seen to decide whther a date is absolute.
14198
14199         * lib/getdate.y (number): Don't overwrite year.
14200         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
14201         check.
14202
14203 2005-04-02  Simon Josefsson  <jas@extundo.com>
14204
14205         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
14206         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
14207
14208 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
14209
14210         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
14211         where no absolute path name can be longer than PATH_MAX.
14212
14213 2005-03-27  Jim Meyering  <jim@meyering.net>
14214
14215         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
14216
14217 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
14218
14219         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
14220         "one's complement" -> "ones' complement" in comment, as per Knuth.
14221         "value of type" -> "type or expression" in comment.
14222         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
14223
14224 2005-03-26  Jim Meyering  <jim@meyering.net>
14225
14226         Comment nits.
14227         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
14228         Correct typos: s/or/of/.
14229
14230 2005-03-26  Jim Meyering  <jim@meyering.net>
14231
14232         * modules/check-include-files: Move to ../ and rename to...
14233         * check-module: ...this.
14234
14235 2005-03-25  Jim Meyering  <jim@meyering.net>
14236
14237         * modules/xvasprintf (Files): Add xalloc.h.
14238
14239 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
14240
14241         * modules/gettext (Files): config/config.rpath ->
14242         build-aux/config.rpath
14243         * modules/iconv (Files): Likewise.
14244         Problem reported by Oskar Liljeblad.
14245
14246 2005-03-23  Jim Meyering  <jim@meyering.net>
14247
14248         * modules/check-include-files: New script to check for
14249         missing dependencies, multiple includes, etc.
14250
14251         * modules/c-strtold (Depends-on): Add xalloc.
14252         * modules/c-strtod (Depends-on): Add xalloc.
14253         * modules/hash (Depends-on): Add xalloc.
14254         (Files): Remove lib/xalloc.h.
14255
14256         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
14257         * modules/userspec (Files): Add lib/inttostr.h.
14258
14259 2005-03-23  Jim Meyering  <jim@meyering.net>
14260
14261         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
14262
14263 2005-03-22  Jim Meyering  <jim@meyering.net>
14264
14265         * modules/stat-macros: New module.
14266         * modules/canonicalize, modules/euidaccess, modules/file-type,
14267         * modules/filemode, modules/lchown, modules/makepath,
14268         * modules/rmdir, modules/stat: Depend on new stat-macros module
14269         rather than listing lib/stat-macros.h manually.
14270         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
14271
14272 2005-03-22  Jim Meyering  <jim@meyering.net>
14273
14274         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
14275
14276 2005-03-22  Bruno Haible  <bruno@clisp.org>
14277
14278         * config/srclist.txt: Replace target directory 'config' with
14279         'build-aux'.
14280         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
14281         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
14282         ../build-aux/.
14283
14284 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
14285
14286         * modules/chdir-long (Depends-on): Add mempcpy.
14287
14288         * modules/acl, modules/backupfile, modules/c-strtod,
14289         modules/c-strtold, modules/canon-host, modules/canonicalize,
14290         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
14291         modules/exclude, modules/exitfail, modules/file-type,
14292         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
14293         modules/getdate, modules/getline, modules/getpagesize,
14294         modules/getpass, modules/getugroups, modules/group-member,
14295         modules/hard-locale, modules/hash, modules/human, modules/idcache,
14296         modules/inttostr, modules/long-options, modules/makepath,
14297         modules/md5, modules/memcasecmp, modules/memcoll,
14298         modules/modechange, modules/mountlist, modules/path-concat,
14299         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
14300         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
14301         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
14302         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
14303         modules/strftime, modules/strndup, modules/strverscmp,
14304         modules/timespec, modules/unlocked-io, modules/userspec,
14305         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
14306         modules/yesno:
14307         Remove lib_SOURCES line from Makefile.am section, as this is now
14308         done automatically by the corresponding Autoconf macro.
14309
14310 2005-03-21  Jim Meyering  <jim@meyering.net>
14311
14312         Changes imported from coreutils.
14313
14314         * lib/cycle-check.c: Don't include xalloc.h.
14315
14316         * lib/path-concat.c: Don't include assert.h.
14317         (path_concat): Remove assertion that would have triggered
14318         for ABASE starting with more than one slash.
14319         Reported by Andreas Schwab.
14320
14321         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
14322         properly when ABASE is an absolute file name.
14323         Correct the description of this function.
14324         Include <assert.h>.
14325         Add an assertion and a test driver.
14326         This fixes a bug introduced on 2004-07-02.
14327         Andreas Schwab reported the resulting failure of cp --parents:
14328         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
14329
14330 2005-03-21  Jim Meyering  <jim@meyering.net>
14331
14332         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
14333         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
14334
14335 2005-03-21  Jim Meyering  <jim@meyering.net>
14336         and  Paul Eggert  <eggert@cs.ucla.edu>
14337
14338         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
14339         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
14340         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
14341         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
14342         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
14343         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
14344         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
14345         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
14346         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
14347         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
14348         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
14349         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
14350         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
14351         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
14352         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
14353         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
14354         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
14355         for these modules.
14356
14357 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
14358
14359         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
14360         (which shouldn't happen), generate nothing instead of returning 0
14361         immediately, so that nstrftime (NULL, ...) doesn't return 0.
14362
14363 2005-03-16  Bruno Haible  <bruno@clisp.org>
14364
14365         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
14366         HAVE_LONGLONG_64BIT.
14367
14368 2005-03-16  Bruno Haible  <bruno@clisp.org>
14369
14370         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
14371         HAVE_LONGLONG_64BIT.
14372
14373 2005-03-16  Bruno Haible  <bruno@clisp.org>
14374
14375         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
14376         HAVE_LONGLONG_64BIT.
14377
14378 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
14379
14380         * lib/strftime.c (my_strftime): Prepend space to format so that we can
14381         reliably distinguish strftime failure from empty output on POSIX
14382         hosts.
14383
14384 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
14385
14386         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
14387         (iconv_string): Don't guess a size-zero buffer, as that might cause
14388         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
14389         result would be 'too large', where 'too large' is (heuristically)
14390         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
14391         overflow concerns.  This will prevent some unwanted malloc failures
14392         when the inputs are very large.
14393
14394 2005-03-15  Karl Berry  <karl@gnu.org>
14395
14396         * config/srclist.txt (config.rpath): from gettext.
14397         * config/config.rpath: update.
14398
14399 2005-03-15  Bruno Haible  <bruno@clisp.org>
14400
14401         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
14402         to 'negate'.
14403
14404         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
14405         variable.
14406
14407         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
14408         results.
14409
14410 2005-03-14  Simon Josefsson  <jas@extundo.com>
14411
14412         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
14413         <fx@gnu.org>.
14414
14415 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
14416
14417         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
14418         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
14419         intprops.h.
14420         * lib/strtol.c: Likewise.
14421
14422 2005-03-14  Jim Meyering  <jim@meyering.net>
14423
14424         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
14425         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
14426         to be nonzero so that we (and caller) can detect the difference
14427         between a valid zero-length expansion and an error return, even
14428         when the underlying strftime fails before writing anything into
14429         that location.
14430
14431 2005-03-14  Bruno Haible  <bruno@clisp.org>
14432
14433         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
14434         Update from GNU gettext 0.14.3.
14435
14436 2005-03-10  Jim Meyering  <jim@meyering.net>
14437
14438         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
14439
14440 2005-03-10  Jim Meyering  <jim@meyering.net>
14441
14442         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
14443         so that this module works on systems without fchdir.
14444
14445 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
14446
14447         Factor int-properties macros into a single file, except for
14448         glibc-related files.
14449         * lib/intprops.h: New file.
14450         * lib/getloadavg.c: Include it instead of limits.h.
14451         (INT_STRLEN_BOUND): Remove.
14452         * lib/human.c: Include intprops.h.
14453         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
14454         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
14455         302/1000.
14456         * lib/inttostr.h: Include intprops.h instead of limits.h.
14457         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
14458         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
14459         for consistency with intprops.h.
14460         (time_t_is_integer, twos_complement_arithmetic): Use them.
14461         * lib/sig2str.h: Include <signal.h>, intprops.h.
14462         (INT_STRLEN_BOUND): Remove.
14463         * lib/strftime.c (TYPE_SIGNED): Remove.
14464         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
14465         * lib/strtol.c: Adjust comments to match intprops.h.
14466         * lib/userspec.c: Include intprops.h.
14467         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
14468         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
14469         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
14470         instead of rolling our own expressions.
14471         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
14472
14473         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
14474         instead of int.
14475         (my_strftime): Do not mishandle years close to INT_MAX, by doing
14476         the right thing even if adding 1900 would overflow.  Similarly
14477         for tm_mon + 1 and tm_yday + 1.
14478         Make %Y always equivalent to %C%y, and similarly for %G and %g.
14479         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
14480         (DO_SIGNED_NUMBER): New macro.
14481         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
14482
14483 2005-03-07  Bruno Haible  <bruno@clisp.org>
14484
14485         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
14486
14487 2005-03-07  Bruno Haible  <bruno@clisp.org>
14488
14489         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
14490
14491 2005-03-04  Derek R. Price  <derek@ximbiot.com>
14492
14493         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
14494         (func_import): Only replace files via --import when they have actually
14495         changed.
14496
14497 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14498
14499         * m4/mmap-anon.m4: New file.
14500         * m4/pagealign_alloc.m4: New file.
14501
14502 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14503             Bruno Haible  <bruno@clisp.org>
14504
14505         * modules/pagealign_alloc: New file.
14506         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
14507
14508 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14509             Bruno Haible  <bruno@clisp.org>
14510
14511         * lib/pagealign_alloc.h: New file.
14512         * lib/pagealign_alloc.c: New file.
14513
14514 2005-03-03  Bruno Haible  <bruno@clisp.org>
14515
14516         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
14517         Use an all-permissive copyright notice, recommended by RMS.
14518
14519 2005-03-02  Bruno Haible  <bruno@clisp.org>
14520
14521         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
14522         of AIX, the replacement has to be done only after <string.h> is
14523         included, therefore not in config.h. stpncpy.h does the replacement,
14524         and stpncpy.c uses it.
14525
14526 2005-03-02  Bruno Haible  <bruno@clisp.org>
14527
14528         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
14529         stpncpy.c uses it.
14530
14531 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14532
14533         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
14534         The workaround isn't strictly needed for POSIX conformance, and
14535         it's too much of a pain to configure and maintain.  We'll ask
14536         people to fix their kernels instead.
14537         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
14538         (NANOSLEEP_BUG_WORKAROUND): Remove.
14539         (xnanosleep): Remove the workaround.
14540
14541 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14542
14543         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
14544         Reported by Derek Price.
14545         (Include): Add "timespec.h".
14546
14547         * modules/xnanosleep (Depends-on): Remove gethrxtime.
14548
14549 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14550
14551         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
14552         to detect nanosleep bug.
14553
14554 2005-03-01  Bruno Haible  <bruno@clisp.org>
14555
14556         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
14557
14558 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
14559
14560         * modules/gethrxtime: New file.
14561         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
14562         (Depends-on): Add gethrxtime.
14563         (configure.ac): Add gl_XNANOSLEEP.
14564         (Makefile.am): Remove lib_SOURCES line.
14565
14566 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
14567
14568         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
14569         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
14570
14571 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
14572
14573         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
14574         * lib/timespec.h (gettime): Return void, since it always
14575         succeeds now.  All uses changed.
14576         * lib/gettime.c (gettime) Likewise.
14577         [HAVE_NANOTIME]: Prefer nanotime.
14578         Assume gettimeofday succeeds, as POSIX requires.
14579         Assime time () succeeds, since other code already does.
14580         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
14581         (timespec_subtract): Remove.
14582         (NANOSLEEP_BUG_WORKAROUND): New constant.
14583         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
14584         things considerably.  Use it only on GNU/Linux hosts, since the
14585         workaround shouldn't be needed elsewhere.
14586
14587 2005-02-24  Bruno Haible  <bruno@clisp.org>
14588
14589         * modules/gettext (Files): Add m4/glibc2.m4.
14590
14591 2005-02-24  Bruno Haible  <bruno@clisp.org>
14592
14593         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
14594         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
14595         * m4/progtest.m4:
14596         Update from GNU gettext 0.14.2.
14597         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
14598
14599 2005-02-24  Bruno Haible  <bruno@clisp.org>
14600
14601         * lib/localcharset.c: Update from GNU gettext 0.14.2.
14602         * lib/config.charset: Update from GNU gettext 0.14.2.
14603
14604 2005-02-24  Bruno Haible  <bruno@clisp.org>
14605
14606         * lib/gettext.h: Update from GNU gettext 0.14.2.
14607
14608 2005-02-23  Simon Josefsson  <jas@extundo.com>
14609
14610         * m4/iconvme.m4: New file.
14611
14612 2005-02-23  Jim Meyering  <jim@meyering.net>
14613
14614         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
14615         change.
14616         Thanks to Bruno Haible for catching it.
14617
14618 2005-02-22  Simon Josefsson  <jas@extundo.com>
14619
14620         * modules/iconvme: New file.
14621
14622         * MODULES.html.sh: Add iconvme.
14623
14624 2005-02-22  Simon Josefsson  <jas@extundo.com>
14625
14626         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
14627
14628 2005-02-22  Simon Josefsson  <jas@extundo.com>
14629
14630         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
14631
14632 2005-02-22  Jim Meyering  <jim@meyering.net>
14633
14634         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
14635         s/ifndef/ifdef/.
14636
14637 2005-02-20  Neil Conway  <neilc@samurai.com>
14638
14639         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
14640         returned by OSX/Darwin if the specified buffer is not large
14641         enough for the hostname.
14642
14643 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14644
14645         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
14646         pass it to _help, otherwise the latter coredumps trying to
14647         dereference state.root_argp.
14648
14649 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14650
14651         * modules/chdir-long (Depends-on): Add memrchr.
14652         * modules/memrchr (Files): Add lib/memrchr.h.
14653         (Include): "memrchr.h".
14654
14655 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14656
14657         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
14658
14659 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14660
14661         * lib/memrchr.h: New file.
14662         * lib/chdir-long.c: Include it.
14663         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
14664         Don't bother including stddef.h.
14665
14666 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
14667
14668         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
14669         inclusion.
14670         Include <sys/types.h>, for dev_t.
14671         (ME_DUMMY, ME_REMOTE): Move from here....
14672         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
14673         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
14674         Dmitry V. Levin.
14675         Include mountlist.h first, to test the interface.
14676
14677 2005-01-29  Bruno Haible  <bruno@clisp.org>
14678
14679         * lib/progname.c (program_name): Initialize.
14680         Needed when linking statically on MacOS X.
14681
14682 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
14683
14684         Sync from coreutils.
14685         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
14686         (Depends-on): Add c-strtod.
14687         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
14688
14689 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
14690
14691         Sync from coreutils.
14692         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
14693
14694         Remove files that are specific to coreutils.
14695         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
14696
14697 2005-01-28  Bruno Haible  <bruno@clisp.org>
14698
14699         * modules/javacomp: New file.
14700         * MODULES.html.sh (Java): Add javacomp.
14701
14702 2005-01-28  Bruno Haible  <bruno@clisp.org>
14703
14704         * m4/javacomp.m4: New file, from GNU gettext.
14705
14706 2005-01-28  Bruno Haible  <bruno@clisp.org>
14707
14708         * lib/javacomp.sh.in: New file, from GNU gettext.
14709         * lib/javacomp.h: New file, from GNU gettext.
14710         * lib/javacomp.c: New file, from GNU gettext.
14711
14712 2005-01-26  Simon Josefsson  <jas@extundo.com>
14713
14714         * lib/gai_strerror.c: Use GPL in header.
14715
14716 2005-01-26  Bruno Haible  <bruno@clisp.org>
14717
14718         * modules/javaexec: New file.
14719         * MODULES.html.sh (Java): Add javaexec.
14720
14721 2005-01-26  Bruno Haible  <bruno@clisp.org>
14722
14723         * m4/javaexec.m4: New file, from GNU gettext.
14724
14725 2005-01-26  Bruno Haible  <bruno@clisp.org>
14726
14727         * lib/javaexec.sh.in: New file, from GNU gettext.
14728         * lib/javaexec.h: New file, from GNU gettext.
14729         * lib/javaexec.c: New file, from GNU gettext.
14730
14731 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14732
14733         * modules/lchown (Depends-on): Remove lchown.h
14734
14735 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14736
14737         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
14738         must be defined if the header file was not found, in order
14739         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
14740
14741 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14742
14743         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
14744         initializers for struct pentry_state.
14745         (__argp_error): Check return value of __asprintf
14746         (__argp_failure): Translate error message
14747
14748         * lib/argp-parse.c: Removed braces around the expansion of N_()
14749
14750 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
14751
14752         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
14753         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
14754         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
14755         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
14756         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
14757         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
14758         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
14759         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
14760         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
14761         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
14762         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
14763         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
14764         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
14765         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
14766         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
14767         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
14768         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
14769         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
14770         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
14771         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
14772         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
14773         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
14774         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
14775         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
14776         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
14777         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
14778         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
14779         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
14780         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
14781         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
14782         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
14783         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
14784         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
14785         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
14786         xstrtol.m4, xstrtoumax.m4, yesno.m4:
14787         Use an all-permissive copyright notice, recommended by RMS.
14788
14789 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
14790
14791         * modules/chdir-long (Depends-on): Remove mempcpy.
14792
14793 2005-01-21  Jim Meyering  <jim@meyering.net>
14794
14795         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
14796         same value as for Solaris 9.
14797
14798         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
14799         component length.  This included changing the parameter to be
14800         of type `char *' rather than `char const *'.
14801         * lib/chdir-long.h (chdir_long): Update prototype.
14802
14803         * lib/openat.c (fdopendir, fstatat): New functions.
14804         * lib/openat.h: Include headers required for use of DIR and struct
14805         stat.
14806         [AT_SYMLINK_NOFOLLOW]: Define.
14807         (fdopendir, fstatat): Add prototypes.
14808
14809 2005-01-21  Bruno Haible  <bruno@clisp.org>
14810
14811         * modules/classpath: New file.
14812         * MODULES.html.sh (Java): Add classpath.
14813
14814 2005-01-21  Bruno Haible  <bruno@clisp.org>
14815
14816         * lib/classpath.h: New file, from GNU gettext.
14817         * lib/classpath.c: New file, from GNU gettext.
14818
14819 2005-01-20  Simon Josefsson  <jas@extundo.com>
14820
14821         * modules/version-etc-fsf: New file.
14822
14823 2005-01-20  Simon Josefsson  <jas@extundo.com>
14824
14825         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
14826         * lib/version-etc.c: Remove version_etc_copyright.
14827         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
14828         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
14829
14830 2005-01-20  Simon Josefsson  <jas@extundo.com>
14831
14832         * lib/base64.h (isbase64): Add.
14833
14834         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
14835         using a unsigned prototype, don't inline.
14836         (base64_decode): Use it.
14837
14838 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14839
14840         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
14841         it.
14842
14843 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14844
14845         * lib/save-cwd.c (save_cwd): Remove code to support the case
14846         where fchdir is missing or flaky.
14847
14848 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14849
14850         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
14851
14852 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
14853
14854         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
14855         AC_LIBSOURCES now does this.
14856         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
14857         with new ullong_max module.
14858
14859 2005-01-19  Bruno Haible  <bruno@clisp.org>
14860
14861         * modules/sh-quote: New file.
14862         * MODULES.html.sh (Executing programs): Add sh-quote.
14863
14864 2005-01-19  Bruno Haible  <bruno@clisp.org>
14865
14866         * lib/sh-quote.h: New file, from GNU gettext.
14867         * lib/sh-quote.c: New file, from GNU gettext.
14868
14869 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14870
14871         Merge from coreutils.
14872         * m4/ullong_max.m4: New file.
14873         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
14874         (gl_MACROS): Assume localeconv exists.
14875
14876 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14877
14878         Merge changes from coreutils, as described below in several
14879         changelogs dated today.
14880
14881         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
14882         (O_DIRECTORY): Remove; not needed here, since "." must be
14883         a directory.  All uses removed.
14884         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
14885         universal on Suns, and we also need to test for IRIX.
14886         Revamp code to use 'if' rather than '#if'.
14887         Avoid unnecessary comparison of cwd->desc to 0.
14888
14889         * lib/utimens.c (futimens): Robustify the previous patch, by checking
14890         for known valid error numbers rather than observed invalid ones.
14891
14892 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14893
14894         * modules/ullong_max: New file.
14895
14896         * modules/chdir-long, modules/openat: New files.
14897         * modules/save-cwd (Depends-on): Depend on chdir-long.
14898         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
14899
14900 2005-01-18  Jim Meyering  <jim@meyering.net>
14901
14902         Merge from coreutils.
14903         * m4/chdir-long.m4, m4/openat.m4: New files.
14904         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
14905         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
14906         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
14907         is sane and DOES follow symlinks.  Besides, testing 20 different
14908         systems found no broken chown implementations.
14909         Prompted by a change in rsync's copy of this macro.
14910         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
14911
14912         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
14913
14914         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
14915         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
14916         NULL-means-set-to-current-time semantics.
14917         Remove temporary file immediately, rather than waiting
14918         for configure's at-exit trap code to do it.
14919
14920 2005-01-18  Jim Meyering  <jim@meyering.net>
14921
14922         * lib/version-etc.c (version_etc_copyright): Update copyright date.
14923
14924         * lib/utimens.c (futimens): Account for the fact that futimes
14925         can also fail with errno == ENOSYS or errno == ENOENT.
14926         Patch from Dmitry V. Levin.
14927
14928         Change the name of the robust chdir function from chdir to chdir_long.
14929         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
14930         (restore_cwd): Use chdir_long, not chdir.
14931         * lib/chdir-long.c: Renamed from chdir.c.
14932         * lib/chdir-long.h: Renamed from chdir.h.
14933         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
14934         Hurd.
14935
14936 2005-01-18  Bruno Haible  <bruno@clisp.org>
14937
14938         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
14939         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
14940         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
14941         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
14942         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
14943         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
14944         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
14945         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
14946         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
14947         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
14948         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
14949         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
14950         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
14951         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
14952         Use an all-permissive copyright notice, recommended by RMS.
14953
14954 2005-01-18  Bob Proulx  <bob@proulx.com>
14955
14956         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
14957         simplify offsetof() macro construct to avoid compile failure with
14958         native HP-UX 11.0 ANSI C compiler.
14959
14960 2005-01-17  Bruno Haible  <bruno@clisp.org>
14961
14962         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
14963         redundant because stpncpy.m4 takes care of it.
14964
14965 2005-01-17  Bruno Haible  <bruno@clisp.org>
14966
14967         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
14968
14969 2005-01-17  Bruno Haible  <bruno@clisp.org>
14970
14971         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
14972         used.
14973
14974 2005-01-17  Bruno Haible  <bruno@clisp.org>
14975
14976         * lib/fwriteerror.h (fwriteerror): Change specification to include
14977         fclose.
14978         * lib/fwriteerror.c: Include <stdbool.h>.
14979         (fwriteerror): At the end, close the file stream. Record whether
14980         stdout was already closed.
14981
14982 2005-01-17  Bruno Haible  <bruno@clisp.org>
14983
14984         * lib/execute.c (environ): Declare if needed.
14985         * lib/pipe.c (environ): Likewise.
14986         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
14987
14988 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14989
14990         * modules/argp: Depend on vsnprintf
14991
14992 2005-01-10  Jim Meyering  <jim@meyering.net>
14993
14994         * modules/closeout (Depends-on): Add atexit.
14995
14996 2005-01-06  Bruno Haible  <bruno@clisp.org>
14997
14998         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
14999
15000 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15001
15002         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
15003         definitions to be after all include files, to avoid collisions.
15004         Problem reported by Bob Proulx.
15005
15006 2005-01-04  Jim Meyering  <jim@meyering.net>
15007
15008         Changes imported from coreutils.
15009         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
15010         as the mkstemp template, use a temporary directory and an
15011         8.3-friendly template to avoid trouble on systems like DJGPP.
15012         Reported by Juan M. Guerrero via Stepan Kasal.
15013         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
15014         close. Remove the temporary directory right away, rather than waiting
15015         for configure's at-exit trap code to do it.
15016         Suggestion from Stepan Kasal.
15017
15018 2005-01-01  Simon Josefsson  <jas@extundo.com>
15019
15020         * gnulib-tool: Print #include directives when --import'ing.
15021
15022 2004-12-28  Simon Josefsson  <jas@extundo.com>
15023
15024         * tests/test-base64.c: Include required header files.  Remove
15025         unused variables.
15026
15027 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
15028
15029         * modules/error (Depends-on): Remove gettext.
15030
15031 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
15032
15033         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
15034         not needed.  This removes a dependency on the gettext module.
15035         [defined _LIBC]: Do not include <libintl.h>; not needed.
15036
15037 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
15038
15039         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
15040         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
15041
15042 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
15043
15044         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
15045         HAVE_DECL_STRTOLD.
15046
15047 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
15048
15049         * modules/getdate (Depends-on): Remove alloca-opt.
15050
15051 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
15052
15053         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
15054
15055 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
15056
15057         * lib/argp-parse.c: Include <stddef.h>.
15058         (alignof, alignto): New macros.
15059         (parser_init): Don't assume that void * is aligned sufficiently
15060         for struct option.
15061
15062         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
15063         need to extend the stack.
15064         (YYINITDEPTH): New macro, so that the initial stack isn't overly
15065         large.
15066
15067 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15068
15069         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
15070
15071 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
15072
15073         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
15074         (2004-10-24) change.  Apparently this was a false alarm.
15075
15076         * modules/getdate: Depend on alloca-opt, not alloca.
15077
15078 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
15079
15080         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
15081         Remove now-obsolete comment about AIX.
15082         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
15083         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
15084         (YYMAXDEPTH): New macro.
15085
15086 2004-12-18  Simon Josefsson  <jas@extundo.com>
15087
15088         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
15089
15090 2004-12-18  Bruno Haible  <bruno@clisp.org>
15091
15092         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
15093
15094 2004-12-18  Bruno Haible  <bruno@clisp.org>
15095
15096         * lib/fatal-signal.c (fatal_signals): Make non-const.
15097         (init_fatal_signals): New function.
15098         (uninstall_handlers, install_handlers): Ignore signals that were set to
15099         SIG_IGN.
15100         (at_fatal_signal): Call init_fatal_signals.
15101         (init_fatal_signal_set): Likewise. Ignore signals that were set to
15102         SIG_IGN.
15103         Reported by Paul Eggert.
15104
15105 2004-12-18  Bruno Haible  <bruno@clisp.org>
15106
15107         * doc/alloca.texi: New file.
15108         * doc/alloca-opt.texi: New file.
15109
15110 2004-12-17  Jim Meyering  <jim@meyering.net>
15111
15112         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
15113         Otherwise, install-sh could exit with improper exit status when
15114         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
15115
15116 2004-12-16  Simon Josefsson  <jas@extundo.com>
15117
15118         * tests/test-base64.c: Add license.
15119
15120 2004-12-15  Stepan Kasal  <address@hidden>
15121
15122         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
15123
15124 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
15125
15126         * modules/getcwd (Files): Add m4/d-ino.m4.
15127         Suggested by Mark D. Baushke.
15128
15129 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
15130
15131         * lib/getdate.y (textint): New member "negative".
15132         (time_zone_hhmm): New function.
15133         Expect 14 shift-reduce conflicts, not 13.
15134         (o_colon_minutes): New rule.
15135         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
15136         (yylex): Set the "negative" member of signed numbers.
15137
15138 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
15139
15140         * doc/getdate.texi (Time of day items, Time zone items):
15141         Describe new formats +00:00, UTC+00:00.
15142
15143 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
15144
15145         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
15146         spurious "-l"s.  Problem reported by Stepan Kasal.
15147
15148 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
15149
15150         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
15151         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
15152
15153 2004-12-04  Simon Josefsson  <jas@extundo.com>
15154
15155         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
15156         Vandoorselaere <yoann@prelude-ids.org>.
15157
15158 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
15159
15160         Changes imported from coreutils.
15161         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
15162         exist.
15163         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
15164
15165 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
15166
15167         Changes imported from coreutils.
15168         * lib/hard-locale.c: Assume <locale.h> exists.
15169         Include "strdup.h".
15170         (GLIBC_VERSION): New macro.
15171         (hard_locale): Assume setlocale exists.
15172         Rewrite to avoid #ifdef.
15173         Use strdup rather than malloc + strcpy.
15174         * lib/human.c: Assume <locale.h> exists.
15175         (human_readable): Assume localeconv exists.
15176
15177 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
15178
15179         * modules/hard-locale (Depends-on): Add strdup.
15180
15181 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
15182
15183         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
15184         convert T2, not T.  (Imported from libc.)
15185
15186 2004-11-30  Simon Josefsson  <jas@extundo.com>
15187
15188         * modules/restrict (License): Change to LGPL.
15189
15190 2004-11-30  Simon Josefsson  <jas@extundo.com>
15191
15192         * m4/restrict.m4: Add copyright and copying conditions.
15193
15194 2004-11-30  Simon Josefsson  <jas@extundo.com>
15195
15196         * m4/base64.m4: New file.
15197
15198 2004-11-30  Simon Josefsson  <jas@extundo.com>
15199
15200         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
15201         base64.
15202
15203         * tests/test-base64.c: New file.
15204
15205         * modules/base64: New file.
15206
15207 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
15208
15209         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
15210         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
15211
15212         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
15213
15214 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
15215
15216         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
15217         (__getcwd.c): Don't restore errno; glibc doesn't.
15218         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
15219         first, falling back to our code only if its results look suspicious.
15220         Ensure that the resulting buffer is only as large as necessary.
15221
15222         * lib/readutmp.c: Include readutmp.h first.
15223         Include <errno.h>, since readutmp.h no longer does that.
15224         * lib/readutmp.h: Don't include <errno.h>,
15225         <sys/param.h>, <time.h>; not needed to establish interface.
15226         (errno): Remove decl.
15227         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
15228         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
15229         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
15230
15231 2004-11-28  Simon Josefsson  <jas@extundo.com>
15232
15233         * lib/base64.h, base64.c: New file.
15234
15235 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
15236
15237         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
15238
15239 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
15240
15241         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
15242         (Depends-on): Remove pathmax, same.  Add mempcpy.
15243         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
15244         (Makefile.am): Append getcwd.h to lib_SOURCES.
15245         (Include): Add getcwd.h.
15246         (Maintainer): Change from Jim Meyering to "all, glibc",
15247         since getdate now uses intended-for-glibc code.
15248         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
15249         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
15250
15251 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
15252
15253         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
15254         HP's ANSI C compiler.
15255         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
15256         Declaring int functions causes warnings on some modern systems and
15257         shouldn't be needed to compile on ancient ones.
15258         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
15259         defined.
15260
15261         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
15262         with the following changes.
15263         (__set_errno): Parenthesize properly.
15264         Include <stdbool.h>.
15265         (MIN, MAX, MATCHING_INO): New macros.
15266         (__getcwd): Define with prototype, not K&R form.
15267         Use heuristics to allocate default buffer on stack if possible.
15268         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
15269         behavior, and to avoid the PATH_MAX limit when computing
15270         ../../../../...
15271         Use MATCHING_INO to compare inode number to file.
15272         Check for arithmetic overflow in size calculations.
15273         Fix bug in reallocation of dot array that caused getcwd to fail
15274         on directories nested deeper than 75.
15275         Be more careful about saving errno on error.
15276         Do not use realloc; use only free+malloc, as this is a bit
15277         more flexible and avoids a needless copy operation.
15278         Do not inspect st_dev and st_ino for symbolic links; POSIX
15279         doesn't specify the latter.
15280         Check for closedir errors.
15281         Avoid needless casts.
15282         Use "#ifdef weak_alias" around weak_alias, to be like other
15283         glibc code.
15284         The following changes to getcwd.c have effect only when used in
15285         gnulib; they have no effect inside glibc proper.
15286         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
15287         as alloca isn't used.
15288         (alloca, __alloca): Likewise.
15289         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
15290         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
15291         unconditionally, as gnulib assumes C89 or better.
15292         Do not include <sys/param.h>.
15293         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
15294         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
15295         better.
15296         (NULL) [!defined NULL]: Remove; we assume C89 or better.
15297         Include <dirent.h> in a way that is compatible with modern Autoconf.
15298         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
15299         New macros, if not already defined.
15300         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
15301         Use "_LIBC", not "defined _LIBC", for consistency.
15302         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
15303         a mempcpy module.
15304         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
15305         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
15306         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
15307         credit only to Jim Meyering and adjust the copyright dates.
15308         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
15309         <stdlib.h>, <unistd.h>, "pathmax.h".
15310         Instead, include "xgetcwd.h" (first) and "getcwd.h".
15311         (INITIAL_BUFFER_SIZE): Remove.
15312         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
15313
15314 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
15315
15316         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
15317         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
15318         Use the _ONCE methods, for efficiency.
15319         Check for fcntl.h.  In test program, include <errno.h>
15320         and <fcntl.h> if available.  Remove old K&R cruft from
15321         test program.  Check for common errors in GNU/Linux,
15322         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
15323         don't do AC_LIBOBJ, as that's getcwd.m4's job.
15324         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
15325         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
15326         name accordingly.
15327         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
15328         accommodate new getcwd.c.
15329         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
15330         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
15331         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
15332         that's all we need now.
15333
15334 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15335
15336         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
15337         argp-parse.c depends on getopt internals, that means we should
15338         always use our getopt, to be on the safe side.
15339         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
15340         order not to spoil the result of an eventual previous invocation
15341         of gl_GETOPT_SUBSTITUTE.
15342
15343 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15344
15345         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
15346         redefinition warnings. To avoid them, include the defines
15347         in `#if !defined __need_getopt ... #endif'. The only place
15348         where __getopt_argv_const is used is in definitions
15349         of getopt_long and getopt_long_only below, which are as well
15350         protected by `#ifndef __need_getopt'.
15351         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
15352         __need_getopt after including <stdio.h> and <unistd.h> These
15353         headers might have defined it.
15354
15355 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
15356
15357         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
15358
15359 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
15360
15361         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
15362         (futimens): New function, which uses futimes if available.
15363         (futimens, utimens): Support timespec==NULL, with same semantics
15364         as utime and utimens.
15365         * lib/utimens.h (futimens): New decl.
15366
15367 2004-11-23  Jim Meyering  <jim@meyering.net>
15368
15369         * lib/getopt_.h: Remove trailing blanks.
15370
15371 2004-11-23  Jim Meyering  <jim@meyering.net>
15372
15373         * lib/__fpending.c: Add comment.
15374
15375 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
15376
15377         * modules/canonicalize (Depends-on): Add xreadlink.
15378         Problem reported by James Youngman.
15379
15380 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
15381
15382         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
15383         New macros.
15384         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
15385         optopt): Use them instead of invoking ## directly; otherwise, the
15386         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
15387
15388 2004-11-19  Bruno Haible  <bruno@clisp.org>
15389
15390         * lib/strtok_r.c: Move comments from here...
15391         * lib/strtok_r.h: ... to here.
15392
15393 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
15394
15395         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
15396         implementations that mishandle size_t overflow.
15397
15398 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
15399
15400         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
15401         might fail.  Problem reported by Yoann Vandoorselaere.
15402         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
15403         implementations that mishandle size_t overflow.
15404
15405 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15406
15407         * modules/canon-host (Depends-on): Add strdup.
15408
15409 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15410
15411         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
15412
15413 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15414
15415         * lib/canon-host.c: Include "strdup.h".
15416         (canon_host): Use getaddrinfo if available, so that IPv6 works.
15417         Use strdup instead of malloc/strcpy to duplicate strings.
15418
15419         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
15420         (human_space_before_unit): New constant.
15421         * lib/human.c (human_readable): Support it.
15422
15423         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
15424         (xgetcwd): Set errno correctly when failing.
15425         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
15426         the failure is actually due to a PATH_MAX problem.
15427
15428         Further getopt changes to make it more likely that glibc will
15429         buy the changes back.
15430         * lib/getopt.c (POSIXLY_CORRECT): New constant.
15431         (getopt): Use it, so to preserve glibc semantic
15432         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
15433         when compiling for libc.
15434         * lib/getopt_.h (__getopt_argv_const): Bring it back.
15435         (getopt_long, getopt_long_only): Use it.
15436
15437         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
15438         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
15439         (getopt): Argv is now char * const *, as per standard.
15440         (_getopt_internal_r, _getopt_internal): Argv is now char **,
15441         not char *__getopt_argv_const *.
15442         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
15443         _getopt_long_only_r): Likewise.
15444         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
15445         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
15446         _getopt_long_r, _getopt_long_only_r): Likewise.
15447         * lib/getopt_.h (__getopt_argv_const): Remove.
15448         (getopt): Argv is now char * const *, as per standard.
15449
15450         * lib/getdate.y (tORDINAL): New token.
15451         (day, relunit): Allow it for relative times.
15452         (relative_time_table): Use tORDINAL for ordinals.
15453
15454 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15455
15456         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
15457         Document that "second" isn't allowed as an ordinal number.
15458
15459 2004-11-16  Jim Meyering  <jim@meyering.net>
15460
15461         * modules/closeout (Depends-on): Add fpending.
15462
15463 2004-11-15  Jim Meyering  <jim@meyering.net>
15464
15465         * lib/closeout.c: Include "__fpending.h" once again.
15466         Include <stdbool.h>.
15467         (close_stdout): Don't fail just because stdout was closed initially,
15468         since some programs don't write to stdout in the normal course of
15469         operation (other than --version and --help), and we don't want this
15470         function to make e.g. `touch file >&-' fail.
15471         But do fail if it was closed and someone has tried to write to it.
15472         E.g., `printf foo >&-' must fail.
15473
15474 2004-11-13  Jim Meyering  <jim@meyering.net>
15475
15476         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
15477
15478 2004-11-12  Simon Josefsson  <jas@extundo.com>
15479
15480         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
15481         small doc fix is still pending.
15482
15483 2004-11-11  Simon Josefsson  <jas@extundo.com>
15484
15485         * modules/strtok_r: New file.
15486
15487         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15488         strtok_r.
15489
15490 2004-11-11  Simon Josefsson  <jas@extundo.com>
15491
15492         * m4/strtok_r.m4: New file.
15493
15494         * m4/getopt.m4: Replace opterr.
15495
15496 2004-11-11  Simon Josefsson  <jas@extundo.com>
15497
15498         * lib/strtok_r.h, strtok_r.c: New file.
15499
15500 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
15501
15502         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
15503         of replacing opterr, getopt, etc.  This should handle the
15504         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
15505
15506 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
15507
15508         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
15509         we can stop lying to compilers about the constness of argv when we
15510         are compiled outside glibc.
15511         (getopt, getopt_long, getopt_long_only): Use it.
15512         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
15513         _getopt_internal, getopt): Likewise.
15514         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
15515         _getopt_long_only_r): Likewise.
15516         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
15517         _getopt_long_r, _getopt_long_only_r): Likewise.
15518
15519         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
15520         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
15521         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
15522         the other external symbols.
15523         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
15524         declaration, since the above renaming now works around collisions.
15525
15526 2004-11-11  Jim Meyering  <jim@meyering.net>
15527
15528         * lib/linebreak.c: Remove trailing blanks.
15529         * lib/alloca_.h: Likewise.
15530         * lib/acosl.c: Likewise.
15531         * lib/euidaccess.c: Likewise.
15532         * lib/allocsa.h: Likewise.
15533
15534 2004-11-10  Simon Josefsson  <jas@extundo.com>
15535
15536         * m4/getaddrinfo.m4: New file.
15537
15538 2004-11-10  Simon Josefsson  <jas@extundo.com>
15539
15540         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
15541
15542 2004-11-10  Simon Josefsson  <jas@extundo.com>
15543
15544         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15545         getaddrinfo.
15546
15547         * modules/getaddrinfo: New file.
15548
15549 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15550
15551         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
15552
15553 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15554
15555         * lib/mktime.c (SHR): New macro, which is a portable
15556         substitute for >> that should work even on Crays.
15557         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
15558         Problem reported by Mark D. Baushke in
15559         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
15560         * lib/getdate.y (SHR): Likewise.
15561         (tm_diff): Use it.
15562         * lib/strftime.c (SHR): Likewise.
15563         (tm_diff): Use it.
15564         * lib/quotearg.c (struct quoting_options): Use unsigned int for
15565         quote_these_too, so that right shifts are well defined.  All uses
15566         changed.
15567
15568 2004-11-10  Jim Meyering  <jim@meyering.net>
15569
15570         Ensure that no close failure goes unreported.
15571         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
15572         return early when it seems there's nothing to flush.
15573         Don't include __fpending.h.
15574
15575 2004-11-10  Jim Meyering  <jim@meyering.net>
15576
15577         * modules/closeout (Depends-on): Remove fpending.
15578
15579 2004-11-10  Jim Meyering  <jim@meyering.net>
15580
15581         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
15582
15583 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
15584
15585         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
15586         gl_FUNC_STRFTIME.
15587         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
15588         and AC_REQUIRE when possible, to avoid duplicate checks.
15589         Check for <wchar.h>.
15590
15591 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
15592
15593         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
15594
15595 2004-11-09  Bruno Haible  <bruno@clisp.org>
15596
15597         * m4/sockpfaf.m4: New file.
15598
15599 2004-11-05  Bruno Haible  <bruno@clisp.org>
15600
15601         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
15602         Reported by Mark D. Baushke <mdb@cvshome.org>.
15603
15604 2004-11-04  Bruno Haible  <bruno@clisp.org>
15605
15606         2004-09-11  Bruno Haible  <bruno@clisp.org>
15607                 * allocsa.valgrind: New file.
15608         2004-02-06  Bruno Haible  <bruno@clisp.org>
15609                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
15610                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
15611                 Reported by Christopher Seip <chris.seip@hp.com>.
15612
15613 2004-11-04  Bruno Haible  <bruno@clisp.org>
15614
15615         * modules/allocsa (Files): Add lib/allocsa.valgrind.
15616         (Makefile.am): Distribute it.
15617
15618 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
15619
15620         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
15621         with errno == ERANGE if the buffer is too small.
15622         Problem reported by Mark D. Baushke.
15623
15624 2004-11-03  Albert Chin  <china@thewrittenword.com>
15625             Paul Eggert  <eggert@cs.ucla.edu>
15626
15627         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
15628         equivalent, substitute $ac_type for equivalent type rather than
15629         blindly using uint32_t *always* which won't work if uint32_t is not
15630         available.  Define _UINT32_T to work around typedef of uint32_t if
15631         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
15632         2.5.1.
15633
15634 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15635
15636         * m4/jm-macros.m4: Sync from coreutils.
15637         (gl_MACROS): Check for mbrlen, for pathchk.
15638         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
15639
15640 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15641
15642         * lib/xreadlink.c (MAXSIZE): New macro.
15643         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
15644         size does not exceed MAXSIZE.  Avoid cast.
15645         As suggested by Mark D. Baushke in
15646         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
15647         if readlink fails with buffer size just under MAXSIZE, try again
15648         with MAXSIZE.
15649
15650 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15651
15652         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
15653
15654 2004-11-02  Derek R. Price  <derek@ximbiot.com>
15655         and  Paul Eggert  <eggert@cs.ucla.edu>
15656
15657         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
15658         (get_date): Overparenthesize to avoid GCC warning.
15659
15660 2004-11-02  Bruno Haible  <bruno@clisp.org>
15661
15662         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
15663         returns void.
15664
15665 2004-11-02  Bruno Haible  <bruno@clisp.org>
15666
15667         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
15668         function returns void.
15669
15670 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
15671
15672         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
15673         fflush_unlocked, flockfile, funlockfile, funlockfile,
15674         fputs_unlocked, putc_unlocked.
15675
15676 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
15677
15678         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
15679         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
15680         already declared.
15681
15682 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15683
15684         * modules/getdate (Files): Add doc/getdate.texi.
15685         (Depends-on): Add setenv, xalloc.
15686
15687 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15688
15689         * lib/getdate.y: Add support for TZ="foo" within a date string.
15690         Fix some bugs near time_t boundaries.  Reject dates with
15691         out-of-range components, e.g., "Sept 31".
15692         Include <stdlib.h>, "setenv.h", "xalloc.h".
15693         (ISDIGIT_LOCALE): Remove; unused.
15694         Note that the TZ and time functions used here are not reentrant.
15695         (mktime_ok, get_tz): New functions.
15696         (TZBUFSIZE): New constant.
15697         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
15698         This requires that we sometimes generate our own TZ="XXX..." setting.
15699
15700 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15701
15702         * doc/getdate.texi: New file, from coreutils with modifications for
15703         the new TZ parsing.
15704
15705 2004-10-27  Derek R. Price  <derek@ximbiot.com>
15706
15707         * lib/mktime.c (not_equal_tm): Remove redundant check.
15708
15709 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
15710
15711         * modules/regex (lib_SOURCES): Add regex.c.
15712         Reported by James Youngman in
15713         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
15714
15715 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
15716
15717         * lib/getdate.y: Use Bison 1.875 features, and some minor
15718         code cleanups.  This change does not affect semantics.
15719         Don't include <stdlib.h>; no longer needed.
15720         Don't include unlocked-io.h; only the "#if TEST" code uses
15721         stdio, and performance isn't crucial there.
15722         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
15723         Bison 1.875 features as described below.
15724         All uses of "PC." replaced by "pc->".
15725         (YYSTYPE): Add a forward declaration.
15726         (yylex, yyerror): Use full prototypes in forward decls.
15727         Use "%pure-parser" rather than obsolescent "%pure_parser".
15728         Use %parse-param and %lex-param instead of obsolescent
15729         YYPARSE_PARAM and YYLEX_PARAM.
15730         (meridian_table, month_and_day_table, time_units_table,
15731         relative_time_table, time_zone_table, military_table,
15732         lookup_zone, lookup_word, get_date):
15733         Use NULL instead of 0 where appropriate.
15734         (to_hour): Avoid abort (), to avoid a dependency on
15735         stdlib.h.
15736         (yyerror, yylex): Now accepts parser_control * arg.
15737         (main) [TEST]: Use '\0' rather than 0 for char.
15738
15739 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
15740
15741         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
15742
15743 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
15744
15745         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
15746         It's now the caller's responsibility to handle the case where
15747         !HAVE_GETPAGESIZE && !defined getpagesize.
15748
15749         * lib/mktime.c (leapyear): Arg is long int, not int.
15750
15751 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
15752
15753         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
15754
15755 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
15756
15757         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
15758         missing.  Problem reported by James Youngman.
15759
15760 2004-10-16  Simon Josefsson  <jas@extundo.com>
15761
15762         * gnulib-tool: Fix comments.  Fix parse problem.
15763         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
15764
15765 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
15766
15767         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
15768         implementation of getopt_long.  Problem reported by Alexander Taler in:
15769         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
15770
15771 2004-10-15  Bruno Haible  <bruno@clisp.org>
15772
15773         * gnulib-tool: Untabify. Initialize supplied_libname.
15774         (func_usage): More homogenous output.
15775         (func_modules_transitive_closure, func_modules_to_filelist,
15776         func_emit_lib_Makefile_am): New functions.
15777         (func_import): New function, extracted from big case statement. Use
15778         func_get_license, func_modules_transitive_closure,
15779         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
15780         opt_lgpl. Don't use test -a, as it's not portable.
15781         (func_create_testdir): Use func_modules_transitive_closure,
15782         func_modules_to_filelist, func_emit_lib_Makefile_am.
15783
15784 2004-10-15  Bruno Haible  <bruno@clisp.org>
15785
15786         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
15787
15788 2004-10-15  Bruno Haible  <bruno@clisp.org>
15789
15790         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
15791         the portions belonging to each module.
15792         Suggested by Derek Robert Price <derek@ximbiot.com>.
15793
15794 2004-10-12  Simon Josefsson  <jas@extundo.com>
15795
15796         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
15797         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
15798         to real functions.
15799
15800 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15801
15802         * modules/vsnprintf: New file.
15803
15804 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15805
15806         * m4/vsnprintf.m4: New file.
15807
15808 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15809
15810         * lib/vsnprintf.h: New file.
15811         * lib/vsnprintf.c: New file.
15812
15813 2004-10-11  Bruno Haible  <bruno@clisp.org>
15814
15815         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
15816         vsnprintf.
15817
15818 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
15819
15820         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
15821
15822 2004-10-07  Bruno Haible  <bruno@clisp.org>
15823
15824         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
15825         fits into the provided buffer.
15826
15827 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
15828
15829         * lib/diacrit.c, diacrit.h: Add GPL notice.
15830
15831         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
15832         notice.
15833         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
15834         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
15835         This avoids a potential constant-folding bug.
15836
15837 2004-10-05  Bruno Haible  <bruno@clisp.org>
15838
15839         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
15840         for the declaration of strsep.
15841
15842 2004-10-05  Bruno Haible  <bruno@clisp.org>
15843
15844         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
15845
15846 2004-10-04  Simon Josefsson  <jas@extundo.com>
15847
15848         * modules/memmem: New file.
15849         * tests/test-memmem.c: New file.
15850         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
15851
15852 2004-10-04  Simon Josefsson  <jas@extundo.com>
15853
15854         * m4/memmem.m4: New file.
15855
15856 2004-10-04  Simon Josefsson  <jas@extundo.com>
15857
15858         * lib/memmem.h: New file.
15859         * lib/memmem.c: New file, taken from glibc.
15860
15861 2004-10-04  Simon Josefsson  <jas@extundo.com>
15862
15863         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
15864         '#ifdef USE_UNLOCKED_IO'.
15865
15866 2004-10-04  Simon Josefsson  <jas@extundo.com>
15867
15868         * config/srclist.txt: Add memmem from glibc.
15869
15870 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15871
15872         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
15873
15874         * modules/argmatch, modules/argp, modules/closeout, modules/error,
15875         modules/exclude, modules/getdate, modules/getline,
15876         modules/getndelim2, modules/getpass, modules/getpass-gnu,
15877         modules/getusershell, modules/linebuffer, modules/md5,
15878         modules/mountlist, modules/posixtm, modules/readtokens,
15879         modules/readutmp, modules/regex, modules/sha1,
15880         modules/version-etc, modules/yesno:
15881         Remove dependency on unlocked-io.
15882
15883 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15884
15885         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
15886
15887         * m4/unlocked-io.m4: Add copyright notice.
15888         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
15889
15890 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15891
15892         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
15893         * lib/xmalloc.c (xmemdup): Likewise.
15894         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
15895         XFREE): Remove these long-obsolescent macros.
15896         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
15897         * lib/xstrdup.c: Remove.
15898
15899         * lib/regex.c (re_comp): Cast gettext return value to char *,
15900         Problem reported by Martin Neitzel via Mark D. Baushke.
15901
15902 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15903
15904         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
15905         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
15906         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
15907         regex.c, sha1.c, version-etc.c, yesno.c:
15908         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
15909         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
15910         the includer's responsibility.
15911
15912         Sync from coreutils.
15913
15914         * lib/modechange.c (mode_compile): Don't decrement a pointer that
15915         points to the start of a string, as the C Standard says the
15916         resulting behavior is undefined.
15917
15918         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
15919         simple -> simple_backups, numbered_existing ->
15920         numbered_existing_backups, numbered -> numbered_backups
15921         to avoid shadowing problems.  All uses changed.
15922         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
15923         * lib/backupfile.c (check_extension, numbered_backup):
15924         Rename locals to avoid shadowing 'basename'.
15925         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
15926         once.
15927
15928         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
15929         * lib/.cvsignore: Add getopt.h.
15930
15931 2004-10-04  Bruno Haible  <bruno@clisp.org>
15932
15933         * modules/README: New file.
15934         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
15935         not a module.
15936
15937 2004-10-02  Jim Meyering  <jim@meyering.net>
15938
15939         * lib/dirfd.h, getpagesize.h: Add copyright notice.
15940
15941 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15942
15943         * modules/strsep: New file.
15944
15945 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15946
15947         * m4/strsep.m4: New file.
15948
15949 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15950
15951         * lib/strsep.h: New file.
15952         * lib/strsep.c: New file.
15953
15954 2004-10-01  Simon Josefsson  <jas@extundo.com>
15955
15956         * lib/snprintf.c (snprintf): Handle size==0.
15957
15958 2004-10-01  Simon Josefsson  <jas@extundo.com>
15959             Bruno Haible  <bruno@clisp.org>
15960
15961         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
15962         (snprintf): Declare 'args'.
15963
15964 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
15965
15966         * lib/snprintf.c: Remove comments as to why each header is needed.
15967
15968 2004-10-01  Bruno Haible  <bruno@clisp.org>
15969
15970         * MODULES.html.sh: Add strsep.
15971
15972 2004-09-30  Simon Josefsson  <jas@extundo.com>
15973
15974         * modules/snprintf: New file.
15975
15976 2004-09-30  Simon Josefsson  <jas@extundo.com>
15977
15978         * m4/snprintf.m4: New file.
15979
15980 2004-09-30  Simon Josefsson  <jas@extundo.com>
15981
15982         * lib/snprintf.h, lib/snprintf.c: New files.
15983
15984 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15985
15986         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
15987         (hol_entry_help): Never translate an empty string.
15988         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
15989         * lib/argp.h (OPTION_NO_TRANS): New option.
15990
15991 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
15992
15993         * modules/argp (Maintainer): Replace Simon Josefsson
15994         by Sergey Poznyakoff.
15995
15996 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
15997
15998         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
15999         changes merged back into glibc.
16000
16001 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
16002
16003         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
16004
16005 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
16006
16007         * lib/xvasprintf.c: Include xalloc.h.
16008         (xvasprintf): Use xalloc_die, not xmalloc_die.
16009
16010 2004-09-29  Bruno Haible  <bruno@clisp.org>
16011
16012         * modules/alloca-opt: New file, derived from modules/alloca.
16013         * modules/allocsa: Depend on alloca-opt instead of alloca.
16014         * modules/setenv: Likewise.
16015         * modules/vasnprintf: Likewise.
16016         * MODULES.html.sh: Add alloca-opt.
16017
16018 2004-09-28  Simon Josefsson  <jas@extundo.com>
16019
16020         * gnulib-tool: New parameter --lgpl, to asseert that modules are
16021         LGPL, and to replace license template from GPL to LGPL.
16022
16023 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
16024
16025         * modules/dummy: Change license to LGPL.
16026
16027 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
16028
16029         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
16030
16031 2004-09-24  Simon Josefsson  <jas@extundo.com>
16032
16033         * modules/minmax (License): Change from GPL to LGPL.
16034
16035 2004-09-23  Simon Josefsson  <jas@extundo.com>
16036
16037         * gnulib-tool (--import): Typo.
16038
16039 2004-09-23  Simon Josefsson  <jas@extundo.com>
16040
16041         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
16042
16043 2004-09-22  Bruno Haible  <bruno@clisp.org>
16044
16045         * modules/*: Add 'License' field.
16046         * gnulib-tool: Accept --extract-license option.
16047         (func_get_license): New function.
16048
16049 2004-09-21  Bruno Haible  <bruno@clisp.org>
16050
16051         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
16052         Reported by Simon Josefsson.
16053
16054 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
16055
16056         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
16057         gl_AC_TYPE_LONG_LONG.
16058
16059 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
16060
16061         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
16062
16063 2004-09-18  Simon Josefsson  <jas@extundo.com>
16064         and  Paul Eggert  <eggert@cs.ucla.edu>
16065
16066         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
16067         calls with autoreconf.  Define GL_LIB.
16068
16069 2004-09-14  Karl Berry  <karl@gnu.org>
16070
16071         * config/srclist.txt: unsync setenv.c, sigh.
16072
16073 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
16074
16075         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
16076         Problem reported by Bruno Haible in:
16077         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
16078
16079 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
16080
16081         * config/srclist.txt: Comment out argp-pvh.c.
16082
16083 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
16084
16085         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
16086         in case some system header has #define'd it.  Problem reported by
16087         Soeren D. Schulze in
16088         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
16089
16090 2004-09-09  Karl Berry  <karl@gnu.org>
16091
16092         * regex.[ch]: delete from the root.  These were supposed to be
16093                 synced with emacs cvs, but this has not happened for about
16094                 a year, and anyway nothing else uses emacs regex.[ch].
16095                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
16096                 lib/regex[.ch] is untouched.
16097
16098 2004-09-09  Bruno Haible  <bruno@clisp.org>
16099
16100         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
16101
16102 2004-09-09  Bruno Haible  <bruno@clisp.org>
16103
16104         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
16105         modifications.
16106         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
16107
16108 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
16109
16110         * modules/xvasprintf: New file.
16111         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
16112
16113 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
16114
16115         * lib/xvasprintf.h: New file.
16116         * lib/xvasprintf.c: New file.
16117         * lib/xasprintf.c: New file.
16118
16119 2004-09-08  Bruno Haible  <bruno@clisp.org>
16120
16121         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
16122
16123 2004-09-08  Bruno Haible  <bruno@clisp.org>
16124
16125         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
16126         length is > INT_MAX.
16127         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
16128         more.
16129
16130 2004-09-08  Bruno Haible  <bruno@clisp.org>
16131
16132         * lib/stdint_.h: New file, taken from GNU clisp.
16133
16134 2004-09-08  Bruno Haible  <bruno@clisp.org>
16135             Oskar Liljeblad  <oskar@osk.mine.nu>
16136
16137         * modules/stdint: New file.
16138         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
16139
16140 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16141
16142         Import from coreutils.
16143         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
16144         strings on unbounded length.  alloca's performance benefits aren't
16145         that important here.
16146         (V_STRDUP): Remove.
16147         (parse_with_separator): New function, with most of the internals
16148         of the old parse_user_spec.  Allow user to omit both user and group,
16149         for compatibility with FreeBSD.
16150         Clone only the user name, not the entire spec.
16151         Do not set *uid, *gid unless entirely successful.
16152         Avoid memory leak in some failing cases.
16153         Fix regression for USER.GROUP reported by Dmitry V. Levin in
16154         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
16155         (parse_user_spec): Rewrite to use parse_with_separator.
16156
16157 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16158
16159         * modules/userspec: Don't depend on alloca.
16160
16161 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16162
16163         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
16164
16165 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
16166
16167         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
16168         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
16169         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
16170
16171 2004-08-16  Simon Josefsson  <jas@extundo.com>
16172
16173         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
16174         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
16175         Add --dry-run for --import.
16176         Let user provided command line parameters override configure.ac
16177         settings.
16178
16179 2004-08-12  Simon Josefsson  <jas@extundo.com>
16180
16181         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
16182         as discussed with Paul Eggert in threads rooted at
16183         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
16184         and
16185         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
16186         Before, the test was empty, and relied on ELIDE_CODE in source
16187         code.)
16188         (gl_PREREQ_GETOPT): New macro.
16189         (gl_GETOPT): Use them.
16190
16191 2004-08-12  Simon Josefsson  <jas@extundo.com>
16192
16193         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
16194         * lib/getopt_.h: Renamed from getopt.h.
16195
16196 2004-08-12  Simon Josefsson  <jas@extundo.com>
16197
16198         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
16199         Change default library name from libfoo to libgnu.
16200         Now, if you have a configure.ac that says:
16201                 gl_SOURCE_BASE(gl)
16202                 gl_M4_BASE(gl/m4)
16203                 gl_MODULES(error getopt etcetera)
16204                 gl_INIT
16205         you can import all you need by running:
16206                 ../gnulib/gnulib-tool --import
16207
16208         * modules/getopt (Files): Rename getopt.h to getopt_.h.
16209         (Makefile.am): Rewrite, use logic from argz.
16210         (Include): Use <getopt.h> instead of "getopt.h".
16211
16212 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
16213
16214         * modules/argp (Files): Add m4/unlocked-io.m4.
16215         (Depends-on): Add extensions.
16216
16217 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
16218
16219         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
16220         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
16221         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
16222         Check for program_invocation_name, program_invocation_short_name,
16223         flockfile, funlockfile, features.h, _getopt_long_only_r.
16224
16225 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
16226
16227         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
16228         its complicated substitute.
16229         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
16230         and program_invocation_name.
16231         (__argp_basename) [!_LIBC]: Remove; the only use was
16232         replaced by its body.
16233         (__argp_short_program_name): Change condition from
16234         !defined __argp_short_program_name to
16235         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
16236         to match argp-namefrob.h.
16237         (__argp_failure): Don't assume strerror_r returns char *.
16238         * lib/argp-parse.c (N_): Define unconditionally.
16239         (argp_default_options): Fill out initializers with 0 to avoid
16240         gcc warnings.
16241
16242 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
16243
16244         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
16245         getopt1.c.
16246
16247 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
16248
16249         Merge from coreutils.
16250
16251         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
16252
16253         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
16254         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
16255
16256 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
16257
16258         Merge from coreutils.
16259
16260         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
16261         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
16262         for Reliant Unix 5.43.
16263
16264         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
16265         (union fooround): Use uintmax_t, not long int.
16266         The rest is a merge from libc:
16267         [defined _LIBC]: Include <shlib-compat.h>.
16268         (_obstack) [defined _LIBC]: Remove after 2.3.4.
16269
16270         * lib/settime.c (settime): Recode to avoid warning with
16271         Sun Forte C 6U2.
16272
16273         * lib/strverscmp.c: Convert to UTF-8.
16274
16275 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
16276
16277         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
16278         m4/uintmax_t.m4.
16279
16280 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
16281
16282         * modules/xalloc-die: New file.
16283         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
16284
16285         * modules/md5 (Files): Add m4/uint32_t.m4.
16286         * modules/sha1: Renamed from modules/sha.
16287         (Files):
16288         Rename lib/sha.h to lib/sha1.h.
16289         Rename lib/sha.c to lib/sha1.c.
16290         Rename m4/sha.m4 to m4/sha1.m4.
16291         (lib_SOURCES): Likewise.
16292         (configure.ac): Rename gl_SHA to gl_SHA1.
16293         (Include): sha.h -> sha1.h.
16294
16295 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
16296
16297         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
16298         * m4/sha1.m4: Renamed from sha.m4.
16299         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
16300
16301 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
16302
16303         * lib/obstack.h (obstack_empty_p):
16304         Don't assume that chunk->contents is suitably aligned.
16305         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
16306         Likewise. Problem reported by Benno in
16307         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
16308
16309         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
16310         readable.  This could be improved further but it'd take some work.
16311
16312 2004-08-08  Simon Josefsson  <jas@extundo.com>
16313
16314         * modules/xgethostname (Depends-on): Remove exit and error (not
16315         used).
16316
16317         * modules/getpass-gnu: Add getpass.h.
16318         (Depends-on): Add stdbool.
16319         * modules/getpass: Add getpass.h.
16320
16321 2004-08-08  Simon Josefsson  <jas@extundo.com>
16322
16323         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
16324         Check getpass declaration.
16325
16326 2004-08-08  Simon Josefsson  <jas@extundo.com>
16327
16328         * lib/xgethostname.c: Don't include error.h (not used).
16329
16330         * lib/getpass.h: Add.
16331         * lib/getpass.c: Include getpass.h first.
16332
16333 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
16334
16335         * lib/xalloc-die.c: New file.
16336         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
16337         All uses removed.
16338         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
16339         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
16340         xalloc-die.c.
16341         (_, N_, xalloc_die): Move to xalloc-die.c.
16342         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
16343         so that we needn't mess with xalloc_msg_memory_exhausted.
16344
16345         * lib/sha1.h: Renamed from sha.h.
16346         (SHA1_H): Renamed from _SHA_H.
16347         (sha1_ctx): Renamed from sha_ctx.
16348         (sha1_init_ctx): Renamed from sha_init_ctx.
16349         (sha1_process_block): Renamed from sha_process_block.
16350         (sha1_process_bytes): Renamed from sha_process_bytes.
16351         (sha1_finish_ctx): Renamed from sha_finish_ctx.
16352         (sha1_read_ctx): Renamed from sha_read_ctx.
16353         (sha1_stream): Renamed from sha_stream.
16354         (sha1_buffer): Renamed from sha_buffer.
16355         * lib/sha1.c: Likewise; renamed from sha.c.
16356         Do not include <sys/types.h>.
16357         Include <stddef.h> rather than <stdlib.h>.
16358
16359 2004-08-08  Bruno Haible  <bruno@clisp.org>
16360
16361         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
16362         FILESYSTEM_PREFIX_LEN.
16363         * lib/progreloc.c: Likewise.
16364         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
16365
16366 2004-08-06  Simon Josefsson  <jas@extundo.com>
16367
16368         * modules/progname (Depends-on): Don't depend on stdbool.
16369
16370 2004-08-06  Simon Josefsson  <jas@extundo.com>
16371
16372         * modules/getsubopt: New file.
16373         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16374         getsubopt.
16375
16376 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16377
16378         More merge from coreutils.
16379
16380         * m4/utimens.m4, m4/utimecmp.m4: New files.
16381         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
16382         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
16383         prereq.m4, sha.m4: Import changes from coreutils.
16384
16385 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16386
16387         More merge from coreutils.
16388         * modules/raise, modules/readtokens0, modules/utimens:
16389         * modules/utimecmp, module/xnanosleep: New files.
16390         * modules/strftime: Add lib/strftime.h.
16391         Change include from <time.h> to "strftime.h".
16392         * modules/yesno: Add lib/yesno.h.
16393         * modules/backupfile: Remove lib/addext.c.
16394         * modules/euidaccess: Add stat-macros.h.
16395         * modules/canonicalize, modules/euidaccess,
16396         modules/filemode, modules/lchown, modules/makepath,
16397         modules/rmdir, modules/stat: Likewise.
16398
16399 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16400
16401         Merge from tar.
16402         * lib/argp-help.c (make_hol, hol_append): Don't assume that
16403         SIZE_MAX is a valid preprocessor constant.
16404         (__argp_basename): Change from "#ifndef _LIBC"
16405         to "#ifndef __argp_short_program_name", so that
16406         we don't compile these functions for tar.
16407
16408         More merges from coreutils.
16409         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
16410         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
16411         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
16412         * lib/addext.c: Remove; no longer needed.
16413         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
16414         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
16415         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
16416         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
16417         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
16418         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
16419         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
16420         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
16421         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
16422         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
16423         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
16424         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
16425         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
16426         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
16427         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
16428         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
16429         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
16430         Import changes from coreutils.
16431
16432 2004-08-05  Simon Josefsson  <jas@extundo.com>
16433
16434         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
16435
16436 2004-08-05  Simon Josefsson  <jas@extundo.com>
16437
16438         * m4/getsubopt.m4: New file.
16439
16440 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16441
16442         Merge from coreutils.
16443
16444         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
16445         * m4/getcwd-path-max.m4: New files.
16446
16447         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
16448         FILESYSTEM_PREFIX_LEN ->
16449         FILE_SYSTEM_PREFIX_LEN.
16450         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
16451         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
16452         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
16453         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
16454
16455         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
16456         prerequisite modules now handle the DOS stuff.
16457         Don't check for unistd.h.
16458
16459 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16460
16461         Merge from coreutils.
16462
16463         * lib/.gdb-history: Remove; this doesn't belong here.
16464
16465         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
16466         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
16467         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
16468         * lib/getcwd.c: New files.
16469
16470         * lib/dirname.h: Include <stdbool.h>.
16471         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
16472         for consistency with POSIX terminology.  All uses changed.
16473         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
16474         (strip_trailing_slashes): Use bool for booleans.
16475         * lib/stripslash.c (strip_trailing_slashes): Likewise.
16476
16477         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
16478         sometimes returns a positive errno value even when it succeeds.
16479         (print_errno_message) [!LIBC]: Fall back on strerror if
16480         __strerror_r fails.
16481
16482         * lib/path-concat.c (mempcpy): Don't define if a system header defines
16483         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
16484         (longest_relative_suffix): New function.
16485         (path_concat): Use it.  Assume first argument is not NULL.
16486         Port to DOS.  Omit redundant separators.
16487         Report an error instead of returning NULL.
16488         Use mempcpy instead of memcpy.
16489         (xpath_concat): Remove: not declared or used.
16490
16491         * lib/same.h: Include <stdbool.h>
16492         (same_name): Return bool, not int.
16493         * lib/same.c (same_name): Likewise.
16494         (errno): Don't declare; we assume C89 or better now.
16495
16496         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
16497         if not already defined.
16498
16499         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
16500         * lib/dup-safer.c (errno): Likewise.
16501
16502 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16503
16504         Merge from coreutils.
16505         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
16506         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
16507         * modules/path-concat: Don't depend on strdup.
16508
16509 2004-08-03  Simon Josefsson  <jas@extundo.com>
16510
16511         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
16512         * lib/progname.h: Don't include stdbool.h.
16513
16514 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16515
16516         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
16517         * MODULES.html.sh (func_all_modules): Remove fatal.
16518
16519 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16520
16521         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
16522
16523 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16524
16525         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
16526         working.
16527
16528 2004-08-02  Simon Josefsson  <jas@extundo.com>
16529
16530         * lib/getsubopt.h: New file, with comments from Bruno Haible.
16531         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
16532         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
16533
16534 2004-08-01  Simon Josefsson  <jas@extundo.com>
16535
16536         * lib/xgetdomainname.c: Include stdlib.h, for free().
16537
16538 2004-07-19  Bruno Haible  <bruno@clisp.org>
16539
16540         * MODULES.html.sh (func_all_modules): Add dummy.
16541
16542 2004-07-16  Simon Josefsson  <jas@extundo.com>
16543
16544         * modules/dummy: New file.
16545
16546 2004-07-16  Simon Josefsson  <jas@extundo.com>
16547
16548         * lib/dummy.c: New file.
16549
16550 2004-07-16  Bruno Haible  <bruno@clisp.org>
16551
16552         * lib/backupfile.h: Add extern "C" for C++.
16553         * lib/closeout.h: Likewise.
16554         * lib/copy-file.h: Likewise.
16555         * lib/findprog.h: Likewise.
16556         * lib/full-write.h: Likewise.
16557         * lib/pathname.h: Likewise.
16558         * lib/progname.h: Likewise.
16559         * lib/stpcpy.h: Likewise.
16560         * lib/stpncpy.h: Likewise.
16561         * lib/strcase.h: Likewise.
16562         * lib/strstr.h: Likewise.
16563         * lib/xalloc.h: Likewise.
16564
16565         * lib/mbswidth.h: Add extern "C" for C++.
16566         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
16567
16568 2004-07-13  Robert Millan  <robertmh@gnu.org>
16569
16570         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
16571
16572 2004-07-09  Simon Josefsson  <jas@extundo.com>
16573
16574         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
16575         failed without this.)
16576
16577 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
16578
16579         * modules/chown (Files): Add lib/fchown-stub.c, since
16580         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
16581
16582 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
16583
16584         * lib/fchown-stub.c: New file.
16585
16586 2004-06-24  Jim Meyering  <jim@meyering.net>
16587
16588         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
16589
16590 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16591
16592         * modules/argz: Omit "#include".
16593
16594         * MODULES.html.sh (func_all_modules): Add calloc, to match
16595         2004-06-01 addition of calloc module.
16596
16597 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16598
16599         * m4/argz.m4: New file, which is autoupdated from libtool.
16600
16601 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16602
16603         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
16604         libtool.
16605
16606 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16607
16608         * config/srclist-update: Don't insist on "USA." before the
16609         close-comment, as libtool omits the period and puts the */ on a
16610         separate line.
16611         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
16612         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
16613
16614 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
16615
16616         * modules/argz: New file.
16617         * MODULES.html.sh (func_all_modules): Add argz.
16618
16619 2004-06-12  Jim Meyering  <jim@meyering.net>
16620         and  Paul Eggert  <eggert@cs.ucla.edu>
16621
16622         * modules/hash (Files): Add lib/xalloc.h.
16623         * modules/pipe (Depends-on): Add wait-process.
16624         * modules/stat (Depends-on): Add xalloc.
16625         * modules/userspec (Files): Add lib/userspec.h.
16626         * modules/xstrto
16627
16628         Upgrade from gettext-0.13.
16629         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
16630         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
16631         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
16632
16633 2004-06-10  Jim Meyering  <jim@meyering.net>
16634
16635         * lib/calloc.c: New file.
16636
16637 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
16638
16639         * lib/getdate.y (yylex): Allow space between sign and number.
16640         Problem reported by Dan Jacobson.
16641
16642 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
16643
16644         Merge from coreutils CVS.
16645
16646         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
16647         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
16648         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
16649         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
16650         xstrtol.m4: Fix copyright date and/or serial number.
16651
16652         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
16653         See if we need an fchown replacement.
16654         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
16655         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
16656         and use the replacement function if we detect either defect.
16657
16658         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
16659         gl_UTIMECMP.
16660
16661 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
16662         and  Jim Meyering  <jim@meyering.net>
16663
16664         Merge from coreutils CVS.
16665
16666         * lib/stat-macros.h: New file, with contents from file-type.h
16667         and coreutils' system.h.
16668         * lib/file-type.c: Include "stat-macros.h".
16669         * lib/file-type.h (file_type): Move all macro definitions to new file,
16670         stat-macros.h.
16671
16672         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
16673         Wrap old code with this conditional.
16674         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
16675         function that does not dereference symlinks.
16676         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
16677
16678         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
16679         dependency problems.
16680         (xreadlink): Accept new arg SIZE, for efficiency.
16681         All decls and uses changed.
16682         * lib/xreadlink.h: Include <stddef.h>, for size_t.
16683
16684         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
16685         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
16686
16687         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
16688         sysexits.h.
16689
16690 2004-06-01  Jim Meyering  <jim@meyering.net>
16691
16692         * m4/calloc.m4: New file.
16693
16694 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
16695
16696         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
16697         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
16698         Also, fix a typo in a diagnostic.
16699
16700 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
16701
16702         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
16703         or AC_FUNC_REALLOC.
16704
16705 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
16706
16707         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
16708         macros to be defined.
16709         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
16710         the allocator returns NULL because the requested size is zero.
16711
16712 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16713
16714         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
16715         var.  Add comment explaining why libc still defines it.  This
16716         merges the following patch from glibc:
16717         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
16718
16719 2004-05-20  Andreas Schwab  <schwab@suse.de>
16720
16721         * m4/free.m4: Replace free if it not known to work, not the other
16722         way round.
16723
16724 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
16725
16726         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
16727         present in glibc since revision 1.1 of this file.
16728         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
16729         obstack_alignment_mask, obstack_alloc, obstack_base,
16730         obstack_blank, obstack_blank_fast, obstack_chunk_size,
16731         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
16732         obstack_grow0, obstack_init, obstack_int_grow,
16733         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
16734         obstack_next_free, obstack_object_size, obstack_ptr_grow,
16735         obstack_ptr_grow_fast, obstack_room): Remove declarations of
16736         nonexistent functions.
16737
16738 2004-05-18  Karl Berry  <karl@gnu.org>
16739
16740         * config/srclist.txt: break link for vasnprintf.c.
16741
16742 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
16743
16744         Port obstack to the AS/400, where pointers are 16 bytes wide and
16745         you cannot cast an integer to a valid pointer.  This patch is
16746         currently waiting to be integrated into glibc; see
16747         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
16748
16749         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
16750         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
16751         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
16752         (struct obstack): temp member is now a union of a pointer and
16753         an integer, instead of an integer.  All integer uses changed.
16754         This does not affect the physical layout of struct obstack,
16755         except on hosts (like the AS/400) where the size or alignment of
16756         void * is greater than that of ptrdiff_t.
16757         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
16758         __STDC__)]: Store temporary in pointer member of union, not
16759         integer member.
16760         * lib/obstack.c: Include <stddef.h>, for offsetof.
16761         (struct fooalign): Remove; it doesn't need a name.
16762         (union fooround): Change double to long double, and add void *.
16763         (DEFAULT_ALIGNMENT): Use offsetof to compute.
16764         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
16765         not a macro.  Hence the values are always int; so remove all
16766         casts-to-int in uses.
16767
16768 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
16769
16770         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
16771         we can get this patch merged into glibc.
16772
16773 2004-05-17  Derek R. Price  <derek@ximbiot.com>
16774             Paul Eggert  <eggert@cs.ucla.edu>
16775
16776         * m4/argp: Depend on alloca.
16777
16778 2004-05-17  Derek R. Price  <derek@ximbiot.com>
16779             Paul Eggert  <eggert@cs.ucla.edu>
16780
16781         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
16782         freecoding.
16783
16784 2004-05-17  Bruno Haible  <bruno@clisp.org>
16785
16786         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
16787         precision that consists of a '.' followed by an empty digit string.
16788         Patch by Tor Lillqvist <tml@iki.fi>.
16789
16790 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
16791
16792         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
16793         for backward compatibility with older code.  We need our own
16794         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
16795         it under some other name, and our alloca.h will define it.
16796
16797 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
16798             Derek Price  <derek@ximbiot.com>
16799
16800         * lib/alloca.c: Include <alloca.h>, to get our interface.
16801         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
16802         include <alloca.h> first.  Use C89 prototype for alloca; this
16803         requires including <stddef.h> for size_t.  Use extern "C" if C++.
16804         Use #elif for simplicity, since we can assume C89 now.
16805         Don't try to source the system alloca.h since it will not be found
16806         and to prevent recursively including its replacement.
16807         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
16808         * lib/regex.c: Likewise.
16809
16810 2004-05-16  Derek Price  <derek@ximbiot.com>
16811             Paul Eggert  <eggert@cs.ucla.edu>
16812
16813         getline cleanup.  This changes the getndelim2 API: both order of
16814         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
16815         no delimiter).
16816
16817         * lib/getline.c: Don't include stddef.h or stdio.h, since our
16818         interface does that.
16819         (getline): Always use getdelim, so that we don't have two
16820         copies of this code.
16821         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
16822         if available.
16823         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
16824         (GETNDELIM2_MAXIMUM): New macro.
16825         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
16826         instead of the old practice of delim2==0.  All callers changed.
16827         Return -1 on overflow, instead of returning junk.
16828         Do not set *linesize unless allocation succeeds.
16829         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
16830         that we include sys/types.h.
16831         * lib/getnline.h: Likewise.
16832         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
16833         (getndelim2): Reorder arguments.
16834         * lib/getnline.c (getnline, getndelim):
16835         Don't discard the NMAX argument.
16836         (getnline): Invoke getndelim, to avoid code duplication.
16837         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
16838         of (size_t) -1 by callers of the getnline family.
16839
16840 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16841
16842         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
16843         Check for gettimeofday.
16844         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
16845         Check for settimeofday, stime.
16846
16847 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16848
16849         * lib/nanosleep.c (suspended): Change its type from int to
16850         sig_atomic_t volatile.
16851         (first_call): Make it private to rpl_nanosleep, and have it
16852         be zero initially as that's a bit faster.
16853         (my_usleep): Round up fractional times instead of truncating them,
16854         as this is the usual meaning for 'sleep'.
16855
16856         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
16857         doesn't work.
16858         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
16859         (ENOSYS): Define if not defined.
16860         (settime): Fall back on stime if it exists and settimeofday fails.
16861         But don't bother with fallbacks if a method fails with errno == EPERM.
16862
16863 2004-05-11  Jim Meyering  <jim@meyering.net>
16864
16865         Prior to this change, the save_cwd caller required read access to the
16866         current directory on most systems (ones with the fchdir function).
16867
16868         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
16869         fails, try write-only, and finally, resort to using xgetcwd.
16870
16871 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
16872
16873         * lib/obstack.c, obstack.h: Import changes from libc.
16874
16875 2004-04-28  Bruno Haible  <bruno@clisp.org>
16876
16877         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
16878         also implicitly appends .exe to executables.
16879         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
16880         accepts Windows pathnames.
16881         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
16882         Treat Cygwin like Windows, since it now accepts Windows pathnames.
16883         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
16884         Treat Cygwin like Windows, since it now accepts Windows pathnames.
16885         Reported by Derek Robert Price <derek@ximbiot.com>.
16886
16887 2004-04-21  Karl Berry  <karl@gnu.org>
16888
16889         * config/srclist.txt (localcharset.c): break sync.
16890
16891 2004-04-20  Paul Eggert  <eggert@twinsun.com>
16892
16893         * m4/host-os.m4: Add a copyright notice.
16894
16895 2004-04-20  Jim Meyering  <jim@meyering.net>
16896
16897         Change UTILS_ to gl_ in AC_DEFINE'd names.
16898         Change utils_- and jm_-prefixed variables, too.
16899         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
16900         UTILS_FUNC_MKDIR_TRAILING_SLASH.
16901         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
16902
16903         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
16904         Don't emit trailing blanks.
16905         Also rename jm_-prefixed variables to have gl_ prefix.
16906
16907         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
16908         Also rename jm_-prefixed variables to have gl_ prefix.
16909
16910         * m4/jm-macros.m4: Reflect the renamings.
16911         * m4/prereq.m4: Likewise.
16912
16913 2004-04-20  Jim Meyering  <jim@meyering.net>
16914
16915         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
16916         memory.
16917
16918 2004-04-20  Jim Meyering  <jim@meyering.net>
16919             Bruno Haible  <bruno@clisp.org>
16920
16921         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
16922         memory when realloc fails.
16923
16924 2004-04-19  Jim Meyering  <jim@meyering.net>
16925
16926         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
16927         now that readutmp.c may call `free (0)'.
16928
16929 2004-04-19  Bruno Haible  <bruno@clisp.org>
16930
16931         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
16932         * m4/inttypes_h.m4: Likewise.
16933         * m4/stdint_h.m4: Likewise.
16934         * m4/intmax_t.m4: Likewise.
16935         * m4/uintmax_t.m4: Likewise.
16936
16937 2004-04-18  Jim Meyering  <jim@meyering.net>
16938
16939         * m4/prereq.m4: Don't forbid jm_ prefix.
16940
16941         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
16942         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
16943         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
16944         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
16945         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
16946         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
16947         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
16948         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
16949         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
16950         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
16951         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
16952         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
16953         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
16954         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
16955         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
16956         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
16957         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
16958         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
16959         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
16960
16961 2004-04-18  Jim Meyering  <jim@meyering.net>
16962
16963         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
16964         failure, don't leak memory and do call END_UTMP_ENT.
16965
16966 2004-04-16  Jim Meyering  <jim@meyering.net>
16967
16968         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
16969         coreutils' stat program.
16970         (gl_PREREQ): Don't require jm_PREREQ_STAT.
16971
16972 2004-04-11  Paul Eggert  <eggert@twinsun.com>
16973
16974         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
16975         C89.
16976         (CHAR_BIT): Remove, since we assume C89.
16977         Include <stdint.h> if available, as per current Autoconf CVS advice.
16978
16979 2004-03-31  Jim Meyering  <jim@meyering.net>
16980
16981         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
16982         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
16983         * m4/xalloc.m4: Likewise.
16984
16985 2004-03-30  Paul Eggert  <eggert@twinsun.com>
16986
16987         Merge from coreutils.
16988
16989         * m4/inttostr.m4: New file.
16990         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
16991         Require AM_STDBOOL_H and gl_TIMESPEC instead.
16992         Require gl_CLOCK_TIME.
16993         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
16994
16995 2004-03-30  Paul Eggert  <eggert@twinsun.com>
16996
16997         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
16998         not bool, to be more consistent with Unix conventions.
16999         Suggested by Bruno Haible.
17000
17001         Merge from coreutils.
17002
17003         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
17004         * lib/umaxtostr.c: New files.
17005
17006         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
17007         the usual <time.h> dance.
17008         (get_date): Change signature to support fractional time stamps.
17009         All callers changed.
17010         * lib/getdate.y: Include "getdate.h" first, as we can now
17011         assume C89 and don't need to worry about 'const'.
17012         Similarly, include "unlocked-io.h" near start, not in middle.
17013         Include <limits.h>.
17014         (textint.value): Use long int rather than int.
17015         (textint.digits): Use size_t rather than int.
17016         (BILLION, LOG10_BILLION): New constants.
17017         (parser_control): New member rel_ns.  Members day_ordinal,
17018         time_zone, month, day, hour, minutes, rel_year, rel_month,
17019         rel_day, rel_hour, rel_minutes, rel_seconds
17020         are now long int, not int.  Member seconds is now struct timespec,
17021         not int.  New member timespec_seen.  Members dates_seen, days_seen,
17022         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
17023         not int.
17024         (%union.intval): Now long int, not int.
17025         New member timespec.
17026         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
17027         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
17028         (spec): Now is a timespec or an item list.
17029         (timespec, items): New nonterminals.
17030         (time, rel, relunit, number, get_date):
17031         Add support for fractional seconds.
17032         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
17033         (gmtime, localtime, mktime): Remove decls; not needed with C89.
17034         (to_hour): First arg is now long int, not int.
17035         (to_year): Returns long int, not int.
17036         Don't treat year -70 like 70.
17037         (tm_diff): Returns long int, not int.
17038         (lookup_word): Use bool instead of int when appropriate.
17039         (yylex): Use size_t for count, not int.
17040         Detect overflow when parsing large integer constants.
17041         Add support for fractions.
17042         (get_date): Make pointers 'const' if possible.
17043         Use more-portable code to detect integer overflow.
17044         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
17045         Don't use ctime; it's not reliable if the year has >4 digits.
17046
17047         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
17048         This is for compatibility with BSD.
17049
17050         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
17051         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
17052         From coreutils' system.h.
17053
17054         * lib/userspec.c: Don't include "posixver.h".
17055         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
17056         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
17057         compatible extension.  Simplify code by removing a boolean int
17058         that was always nonzero if a string was nonnull.
17059
17060 2004-03-30  Jim Meyering  <jim@meyering.net>
17061
17062         Merge from coreutils.
17063
17064         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
17065         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
17066         on some systems one must include <grp.h> before it.
17067         Reported by Christian Krackowizer.
17068
17069 2004-03-30  Jim Meyering  <jim@meyering.net>
17070
17071         Merge from coreutils.
17072
17073         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
17074
17075         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
17076         an empty input stream.
17077
17078         * lib/readtokens.c: Include <stdbool.h>.
17079         (readtoken): Use `size_t' rather than int/long.
17080         All callers adjusted.
17081         Use `bool' rather than `int' where appropriate.
17082         Use memset rather than an explicit loop.
17083         Use x2nrealloc rather than xrealloc.
17084         Allow the use of `\0' as a delimiter.
17085         (readtokens): Likewise.
17086         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
17087
17088 2004-03-30  Jim Meyering  <jim@meyering.net>
17089
17090         * m4/realloc.m4: Remove file, since now it does no more than
17091         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
17092         the `configure.ac' section of module/realloc.
17093         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
17094
17095 2004-03-30  Bruno Haible  <bruno@clisp.org>
17096
17097         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
17098         nonnull.
17099
17100 2004-03-29  Paul Eggert  <eggert@twinsun.com>
17101
17102         Merge changes to getloadavg.c from coreutils and Emacs.
17103
17104         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
17105         Define to an expression, not to the empty string.
17106         Include cloexec.h and xalloc.h.
17107         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
17108         Use set_cloexec_flag rather than rolling our own.
17109         * lib/cloexec.c, lib/cloexec.h: New files.
17110
17111 2004-03-29  Paul Eggert  <eggert@twinsun.com>
17112
17113         * m4/cloexec.m4: New file.
17114
17115 2004-03-18  Paul Eggert  <eggert@twinsun.com>
17116
17117         * lib/getopt.h: Sync with libc CVS.
17118
17119 2004-03-18  Paul Eggert  <eggert@twinsun.com>
17120             Bruno Haible  <bruno@clisp.org>
17121
17122         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
17123         mbswidth.
17124
17125 2004-03-18  Paul Eggert  <eggert@twinsun.com>
17126             Bruno Haible  <bruno@clisp.org>
17127
17128         * lib/mbswidth.h: Include <wchar.h> only if
17129         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
17130         <wchar.h>.
17131         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
17132
17133 2004-03-09  Paul Eggert  <eggert@twinsun.com>
17134
17135         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
17136         Sync with libc CVS.
17137         * lib/getopt_int.h: New file, also synced from libc.
17138
17139 2004-03-09  Paul Eggert  <eggert@twinsun.com>
17140
17141         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
17142         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
17143         Bring back getopt.c, getopt.h, getopt1.c.
17144
17145 2004-03-07  Paul Eggert  <eggert@twinsun.com>
17146
17147         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
17148         All uses changed.  Check for sa_sigaction member; this fixes
17149         a bug first reported by Jason Andrade in
17150         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
17151
17152 2004-03-07  Paul Eggert  <eggert@twinsun.com>
17153
17154         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
17155         '#if' expressions.  Unlike the code it replaces, it does not
17156         depend on (defined _SC_PAGESIZE).  However, it does depend on
17157         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
17158         first reported by Jason Andrade in
17159         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
17160
17161 2004-02-25  Simon Josefsson  <jas@extundo.com>
17162
17163         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
17164
17165 2004-02-25  Simon Josefsson  <jas@extundo.com>
17166
17167         * lib/strdup.h: New file.
17168         * lib/strdup.c: Include it.
17169         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
17170         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
17171
17172 2004-02-23  Karl Berry  <karl@gnu.org>
17173
17174         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
17175         (from fencepost.gnu.org:/gd/gnuorg).
17176
17177 2004-02-23  Karl Berry  <karl@gnu.org>
17178
17179         * config/srclistvars.sh (GNUORG) [karl]: redefine.
17180         * config/srclist.txt: add maintain/standards documents.
17181
17182 2004-02-18  Bruno Haible  <bruno@clisp.org>
17183
17184         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
17185         Reported by Derek Robert Price <derek@ximbiot.com>.
17186
17187 2004-02-16  Karl Berry  <karl@gnu.org>
17188
17189         * config/mkinstalldirs, install-sh: update from automake.
17190
17191 2004-02-06  Karl Berry  <karl@gnu.org>
17192
17193         * m4/po.m4: update from gettext 0.14.1.
17194
17195 2004-02-06  Karl Berry  <karl@gnu.org>
17196
17197         * lib/config.charset: update from gettext 0.14.1.
17198
17199 2004-02-05  Paul Eggert  <eggert@twinsun.com>
17200
17201         Add comments and code, prompted by suggestions from Bruno Haible
17202         for sh-quote.
17203         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
17204         describing the enum quoting_style values.
17205         * lib/quotearg.c (quotearg_alloc): New function.
17206         (quotearg_buffer_restyled): Treat lone { and } as special.
17207         Treat = as special.  Work around bug with older shells
17208         that "see" a '\' that is really the 2nd byte of a multibyte char.
17209         Quote empty string with shell_quoting_style.
17210
17211 2004-02-03  Bruno Haible  <bruno@clisp.org>
17212
17213         * m4/pipe.m4: New file, from GNU gettext.
17214
17215 2004-02-03  Bruno Haible  <bruno@clisp.org>
17216
17217         * lib/pipe.h: New file, from GNU gettext.
17218         * lib/pipe.c: New file, from GNU gettext.
17219
17220 2004-01-27  Bruno Haible  <bruno@clisp.org>
17221
17222         * m4/execute.m4: New file, from GNU gettext.
17223
17224 2004-01-27  Bruno Haible  <bruno@clisp.org>
17225
17226         * lib/execute.h: New file, from GNU gettext.
17227         * lib/execute.c: New file, from GNU gettext.
17228         * lib/w32spawn.h: New file, from GNU gettext.
17229
17230 2004-01-24  Paul Eggert  <eggert@twinsun.com>
17231
17232         Merge from diffutils.
17233
17234         * lib/file-type.c (file_type): Add typed memory objects.
17235         * lib/file-type.h (S_TYPEISTMO): New macro.
17236
17237         * lib/c-stack.h (c_stack_action): Remove argv argument.
17238         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
17239         (die): Don't calculate message unless segv_action returns.
17240         (get_stack_location, min_address_from_argv, max_address_from_argv,
17241         volatile stack_base, volatile_stack_size): Remove.
17242         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
17243         that every segmentation violation is a stack overflow.  (Ouch!)
17244         See Debian bug 136249 (still outstanding) for more info about why
17245         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
17246
17247 2004-01-24  Paul Eggert  <eggert@twinsun.com>
17248
17249         Exit-status fix from coreutils.
17250
17251         Use exit_failure consistently in place of EXIT_FAILURE,
17252         so that program exit statuses are consistent on failure.
17253
17254         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
17255         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
17256         * lib/argmatch.h: Comment fix to match the above.
17257         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
17258         Now a macro referring to exit_failure, instead of a separate
17259         variable.  Include "exitfail.h" to get it.
17260         * lib/xstrtol.h: Include "exitfail.h".
17261         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
17262
17263         * lib/long-options.c (parse_long_options): Use prototype
17264         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
17265         for clarity.
17266
17267 2004-01-21  Jim Meyering  <jim@meyering.net>
17268
17269         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
17270         so as not to conflict with a different-sized __mktime_internal
17271         function in GNU libc.
17272         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
17273         Problem building statically-linked `ls' reported by Michael Brunnbauer.
17274
17275 2004-01-20  Karl Berry  <karl@gnu.org>
17276
17277         * config/config.guess: update from config.
17278
17279         * config/srclistvars.sh: GNUWWWLICENSES for karl.
17280
17281 2004-01-20  Bruno Haible  <bruno@clisp.org>
17282
17283         Safer stack allocation.
17284         * lib/setenv.c: Include allocsa.h.
17285         (alloca): Remove fallback definition.
17286         (freea): Remove macro.
17287         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
17288         instead of freea.
17289
17290 2004-01-20  Bruno Haible  <bruno@clisp.org>
17291
17292         * m4/eealloc.m4: New file, from GNU gettext.
17293
17294 2004-01-20  Bruno Haible  <bruno@clisp.org>
17295
17296         * m4/allocsa.m4: New file, from GNU gettext.
17297
17298 2004-01-20  Bruno Haible  <bruno@clisp.org>
17299
17300         * lib/xallocsa.h: New file, from GNU gettext.
17301         * lib/xallocsa.c: New file, from GNU gettext.
17302
17303 2004-01-20  Bruno Haible  <bruno@clisp.org>
17304
17305         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
17306
17307 2004-01-20  Bruno Haible  <bruno@clisp.org>
17308
17309         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
17310         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
17311         specially.
17312
17313 2004-01-20  Bruno Haible  <bruno@clisp.org>
17314
17315         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
17316         patch.
17317
17318 2004-01-20  Bruno Haible  <bruno@clisp.org>
17319
17320         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
17321
17322 2004-01-20  Bruno Haible  <bruno@clisp.org>
17323
17324         * lib/eealloc.h: New file.
17325
17326 2004-01-20  Bruno Haible  <bruno@clisp.org>
17327
17328         * lib/binary-io.h: Avoid warnings on Cygwin.
17329
17330 2004-01-20  Bruno Haible  <bruno@clisp.org>
17331
17332         * lib/allocsa.h: New file, from GNU gettext.
17333         * lib/allocsa.c: New file, from GNU gettext.
17334
17335 2004-01-18  Karl Berry  <karl@gnu.org>
17336
17337         * doc/gpl.texi, doc/lgpl.texi: new files.
17338
17339 2004-01-18  Karl Berry  <karl@gnu.org>
17340
17341         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
17342         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
17343
17344 2004-01-15  Paul Eggert  <eggert@twinsun.com>
17345
17346         Merge from coreutils.
17347
17348         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
17349         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
17350         (gl_DEFAULT_POSIX2_VERSION): Move
17351         the documentation from 'configure' into 'config.hin',
17352         so that 'configure --help' isn't burdened by it and
17353         we don't have to worry about its formatting there.
17354         Reword the documentation so that it's more succinct
17355         and can be run together into a single paragraph.
17356         * m4/same.m4 (gl_SAME): Check for pathconf.
17357
17358 2004-01-15  Paul Eggert  <eggert@twinsun.com>
17359
17360         Merge from coreutils.
17361
17362         * lib/posixver.c: Include posixver.h.
17363
17364         * lib/same.c: Include <stdbool.h>, <limits.h>.
17365         (_POSIX_NAME_MAX): Define if not defined.
17366         (MIN): New macro.
17367         (same_name): If file names are silently truncated, report
17368         that the file names are the same if they are the same after
17369         the silent truncation.
17370
17371         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
17372         conversion function.
17373         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
17374         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
17375         longer needed.
17376
17377 2004-01-15  Jim Meyering  <jim@meyering.net>
17378
17379         Merge from coreutils.
17380
17381         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
17382         if no library is required.
17383         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
17384         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
17385         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
17386         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
17387         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
17388         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
17389         value, $ac_cv_search_crypt, if it's "none required".
17390         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
17391         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
17392         not gl_FUNC_GETLOADAVG.
17393         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
17394         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
17395
17396 2004-01-15  Jim Meyering  <jim@meyering.net>
17397
17398         Merge from coreutils.
17399
17400         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
17401         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
17402         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
17403
17404         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
17405         optional configure-time default.
17406
17407         * lib/version-etc.c (version_etc_copyright): Update copyright date.
17408
17409         * lib/xreadlink.c (xreadlink): Correct outdated comment.
17410
17411 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
17412
17413         Merge from coreutils.
17414
17415         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
17416         value, $ac_cv_search_nanosleep, if it's "none required".
17417
17418 2004-01-14  Paul Eggert  <eggert@twinsun.com>
17419
17420         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
17421         with like-named macro in fnmatch.c.
17422         (EXT): Use an internal constant instead.
17423
17424         Merge fnmatch patches from glibc.
17425         * lib/fnmatch.c (mbsinit): Remove define.
17426         Add libc_hidden_ver (__fnmatch, fnmatch).
17427         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
17428         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
17429
17430 2004-01-14  Karl Berry  <karl@gnu.org>
17431
17432         * config/install-sh: update from automake.
17433
17434 2004-01-13  Karl Berry  <karl@gnu.org>
17435
17436         * config/install-sh: update from automake.
17437
17438 2004-01-09  Karl Berry  <karl@gnu.org>
17439
17440         * config/install-sh: update from automake.
17441
17442 2004-01-05  Karl Berry  <karl@gnu.org>
17443
17444         * config/config.{sub,guess}: update from config.
17445
17446 2003-12-31  Karl Berry  <karl@gnu.org>
17447
17448         * config/depcomp: update from automake.
17449
17450 2003-12-14  Karl Berry  <karl@gnu.org>
17451
17452         * lib/config.charset: update from gettext-runtime.
17453
17454 2003-12-03  Paul Eggert  <eggert@twinsun.com>
17455
17456         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
17457         Bug reported by Alfred M. Szmidt.
17458
17459 2003-12-03  Bruno Haible  <bruno@clisp.org>
17460
17461         * m4/gettext.m4: Upgrade from gettext-0.13.
17462         * m4/po.m4: Upgrade from gettext-0.13.
17463         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
17464         * m4/intmax.m4: New file, from gettext-0.13.
17465         * m4/printf-posix.m4: New file, from gettext-0.13.
17466
17467 2003-11-29  Karl Berry  <karl@gnu.org>
17468
17469         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
17470
17471 2003-11-25  Paul Eggert  <eggert@twinsun.com>
17472             Bruno Haible  <bruno@clisp.org>
17473
17474         * lib/printf-parse.h: Don't include sys/types.h.
17475         (ARG_NONE): New macro.
17476         (char_directive): Change type of *arg_index fields to size_t.
17477         * lib/printf-parse.c: Don't include sys/types.h.
17478         (SSIZE_MAX): Remove macro.
17479         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
17480         Remove unnecessary overflow check.
17481         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
17482         fields.
17483
17484 2003-11-25  Bruno Haible  <bruno@clisp.org>
17485
17486         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
17487
17488 2003-11-25  Bruno Haible  <bruno@clisp.org>
17489
17490         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
17491         gt_TYPE_SSIZE_T.
17492
17493 2003-11-24  Paul Eggert  <eggert@twinsun.com>
17494
17495         * modules/alloca: Remove dependency on xalloc.
17496
17497 2003-11-24  Paul Eggert  <eggert@twinsun.com>
17498
17499         * lib/alloca.c: Remove dependency on xalloc module.
17500         (xalloc_die): Remove.
17501         (memory_full) [!defined emacs]: New macro.
17502         [!defined emacs]: Don't include xalloc.h.
17503         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
17504         address arithmetic overflows.  Change datatypes a bit to avoid
17505         unnecessary casts.
17506
17507 2003-11-22  Jim Meyering  <jim@meyering.net>
17508
17509         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
17510         s/size/size_t/.
17511
17512 2003-11-21  Karl Berry  <karl@gnu.org>
17513
17514         * config/config.{sub,guess}: update from config.
17515
17516 2003-11-18  Karl Berry  <karl@gnu.org>
17517
17518         * config/config.{sub,guess}: update from config.
17519
17520         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
17521
17522 2003-11-17  Paul Eggert  <eggert@twinsun.com>
17523
17524         * README: Mention that S+T cannot overflow if S is the size of
17525         an existing object and T is sufficiently small.
17526
17527 2003-11-17  Jim Meyering  <jim@meyering.net>
17528
17529         On systems without utime and without a utimes function capable of
17530         dealing with a NULL struct utimbuf* argument, this utime replacement
17531         could -- in unusual circumstances -- leak a file descriptor.
17532         * lib/utime.c: Include <unistd.h> and <errno.h>.
17533         (utime_null): Be sure to close `fd' and to preserve errno.
17534         Reported by Geoff Collyer via Arnold Robbins.
17535
17536 2003-11-17  Bruno Haible  <bruno@clisp.org>
17537
17538         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
17539         (Depends-on): Add xsize.
17540
17541 2003-11-17  Bruno Haible  <bruno@clisp.org>
17542
17543         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
17544
17545 2003-11-17  Bruno Haible  <bruno@clisp.org>
17546
17547         * lib/vasnprintf.c (alloca): Remove fallback definition.
17548         (freea): Remove definition.
17549         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
17550         Reported by Paul Eggert.
17551
17552 2003-11-16  Paul Eggert  <eggert@twinsun.com>
17553             Bruno Haible  <bruno@clisp.org>
17554
17555         Protect against address arithmetic overflow.
17556         * lib/printf-args.h: Include stddef.h.
17557         (arguments): Change type of field 'count' to size_t.
17558         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
17559         'unsigned int' where appropriate.
17560         * lib/printf-parse.h: Include sys/types.h.
17561         (char_directive): Change type of *arg_index fields to ssize_t.
17562         (char_directives): Change type of fields 'count', max_*_length to
17563         size_t.
17564         * lib/printf-parse.c: Include sys/types.h and xsize.h.
17565         (SSIZE_MAX): Define fallback value.
17566         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
17567         instead of 'int' where appropriate. Check a_allocated, d_allocated
17568         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
17569         * lib/vasnprintf.c: Include xsize.h.
17570         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
17571         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
17572         overflow. Avoid wraparound when converting a width or precision from
17573         decimal to binary.
17574
17575 2003-11-16  Bruno Haible  <bruno@clisp.org>
17576
17577         Update from GNU gettext.
17578         * lib/printf-parse.c: Generalize to it can be compiled for wide
17579         strings.
17580         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
17581         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
17582         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
17583         SNPRINTF): New macros.
17584         Don't include <alloca.h> if the file is used inside libintl.
17585         (local_wcslen): New function, for Solaris 2.5.1.
17586         (VASNPRINTF): Use it instead of wcslen.
17587
17588 2003-11-16  Bruno Haible  <bruno@clisp.org>
17589
17590         * lib/xsize.h (xmax): New function.
17591         (xsum, xsum3, xsum4): Declare as "pure" functions.
17592
17593 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17594
17595         * modules/xalloc (Files): Undo latest change, since xalloc.h
17596         no longer needs SIZE_MAX or PTRDIFF_MAX.
17597
17598 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17599
17600         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
17601         gl_PTRDIFF_MAX.
17602
17603 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17604
17605         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
17606         "return", to pacify some unknown compiler.  Problem reported
17607         by Joerg Schilling.
17608
17609 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17610
17611         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
17612         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
17613         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
17614         heuristic is just as accurate as far as we know, and it removes a
17615         dependency on size_max.m4 and ptrdiff_max.m4.
17616
17617 2003-11-11  Bruno Haible  <bruno@clisp.org>
17618
17619         * modules/xsize (Files): Add m4/size_max.m4.
17620         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
17621
17622 2003-11-11  Bruno Haible  <bruno@clisp.org>
17623
17624         * m4/size_max.m4: New file.
17625         * m4/ptrdiff_max.m4: New file.
17626         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
17627         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
17628         (gl_XALLOC): Invoke it.
17629
17630 2003-11-11  Bruno Haible  <bruno@clisp.org>
17631
17632         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
17633         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
17634         defined.
17635
17636 2003-11-10  Paul Eggert  <eggert@twinsun.com>
17637
17638         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
17639         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
17640         rejected some allocations of exactly SIZE_MAX - 2 bytes.
17641         From Bruno Haible.
17642         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
17643         not (size_t) -1, since it's defined here.
17644
17645 2003-11-09  Karl Berry  <karl@gnu.org>
17646
17647         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
17648
17649 2003-11-06  Paul Eggert  <eggert@twinsun.com>
17650
17651         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
17652         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
17653         Reject sizes of exactly SIZE_MAX bytes.
17654         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
17655         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
17656
17657 2003-11-05  Bruno Haible  <bruno@clisp.org>
17658
17659         * lib/xsize.h: Include limits.h, to avoid a possible collision with
17660         SIZE_MAX defined in <limits.h> on Solaris.
17661
17662 2003-11-04  Jim Meyering  <jim@meyering.net>
17663
17664         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
17665         variable names, rather than @VAR@.
17666         * modules/poll: Likewise.
17667
17668 2003-11-04  Bruno Haible  <bruno@clisp.org>
17669
17670         * modules/xsize: New file.
17671         * modules/linebreak: Depend on xsize.
17672         * MODULES.html.sh (func_all_modules): Add xsize.
17673
17674 2003-11-04  Bruno Haible  <bruno@clisp.org>
17675
17676         * m4/xsize.m4: New file.
17677
17678 2003-11-04  Bruno Haible  <bruno@clisp.org>
17679
17680         * lib/xsize.h: New file.
17681         * lib/linebreak.c: Include xsize.h.
17682         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
17683         argument for overflow.
17684         Suggested by Paul Eggert.
17685
17686 2003-11-03  Karl Berry  <karl@gnu.org>
17687
17688         * config/config.{guess,sub}: update from config.
17689
17690 2003-11-03  Jim Meyering  <jim@meyering.net>
17691
17692         * modules/userspec (lib_SOURCES): Add userspec.h.
17693         (Include): Add "userspec.h".
17694         Improve description.
17695
17696 2003-11-03  Jim Meyering  <jim@meyering.net>
17697
17698         * lib/userspec.c: Include "userspec.h".
17699         * lib/userspec.h: New file.
17700
17701 2003-11-03  Bruno Haible  <bruno@clisp.org>
17702
17703         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
17704
17705 2003-11-03  Bruno Haible  <bruno@clisp.org>
17706
17707         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
17708         available, to avoid (extremely rare) race condition.
17709         Suggested by Paul Eggert.
17710
17711 2003-11-02  Karl Berry  <karl@gnu.org>
17712
17713         * config/srclist.txt (vasprintf.c): sync broken, sigh.
17714
17715 2003-10-31  Paul Eggert  <eggert@twinsun.com>
17716
17717         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
17718         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
17719         (read_filesystem_list): Set and use me_type_malloced.
17720         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
17721         whatever the type happens to be), for brevity and consistency.
17722         Check for size calculation overflow on Alphas running OSF/1.
17723
17724 2003-10-31  Jim Meyering  <jim@meyering.net>
17725
17726         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
17727
17728         * lib/linebuffer.c: Include <string.h> for declaration of memset.
17729
17730 2003-10-30  Paul Eggert  <eggert@twinsun.com>
17731             Bruno Haible  <bruno@clisp.org>
17732
17733         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
17734         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
17735
17736 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
17737
17738         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
17739         netbsd*-gnu*.  Suggested by Robert Millan.
17740
17741 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17742
17743         * modules/group-member: Depend on stdbool.
17744
17745 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17746
17747         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
17748
17749 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17750
17751         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
17752         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
17753         after the 'gnu' in these cases.  This fixes some bugs in the
17754         previous change, and is based on suggestions by Robert Millan.
17755
17756 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17757
17758         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
17759         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
17760         no longer needed.
17761         * lib/quotearg.c (quotearg_n_options): Use it.
17762         * lib/group-member.c: Include <stdbool.h>.
17763         (free_group_info): Arg is now const *; don't free arg.
17764         (get_group_info): Now returns bool and accepts struct group_info *,
17765         rather than returning a malloc'ed struct group_info *.
17766         All uses changed.  Check for overflow in internal size calculation.
17767
17768         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
17769         rather than xmalloc/xrealloc.
17770         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
17771         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
17772         conformance bug: the old code used a pointer after freeing the
17773         storage that it addressed.
17774         * lib/hash.c (hash_initialize): Simplify the code by using
17775         xalloc_oversized rather than doing it by hand.
17776         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
17777         the buffer preserved.  Use free and xmalloc instead.
17778         * lib/quotearg.c (quotearg_n_options): Likewise.
17779         Use a simpler test for size overflow.  Don't use xalloc_oversized
17780         because unsigned int might be wider than size_t (!); this suggests
17781         that we should switch from unsigned int to size_t for slot numbers.
17782
17783 2003-10-28  Paul Eggert  <eggert@twinsun.com>
17784
17785         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
17786         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
17787         NetBSD kernels.  Requested by Richard Stallman.
17788
17789 2003-10-27  Paul Eggert  <eggert@twinsun.com>
17790
17791         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
17792         to allocate the returned structure.  Do not allocate a subarray,
17793         as x2nrealloc will do that.
17794         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
17795         instead of xnrealloc.
17796         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
17797
17798 2003-10-27  Bruno Haible  <bruno@clisp.org>
17799
17800         * lib/stdbool_.h: Better support for BeOS.
17801
17802 2003-10-26  Paul Eggert  <eggert@twinsun.com>
17803
17804         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
17805         now uses inline.
17806
17807 2003-10-26  Paul Eggert  <eggert@twinsun.com>
17808
17809         * lib/xalloc.h (xalloc_oversized): New static inline function, for
17810         callers that want to do their own size-overflow checking.  Include
17811         <stdbool.h>, since xalloc_oversized returns bool.
17812         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
17813         to use xalloc_oversized.
17814
17815         Add two functions x2realloc, x2nrealloc, for programs that grow
17816         arrays dynamically by doubling their sizes.
17817         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
17818         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
17819         New functions.
17820
17821         Port to C99 semantics for 'inline' of external functions.
17822         Bug reported by Bruno Haible.
17823         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
17824         with the old contents of xnmalloc.
17825         (xnmalloc, xmalloc): Use it.
17826         (xnrealloc_inline): New static inline function,
17827         with the old contents of xnrealloc.
17828         (xnrealloc, xrealloc): Use it.
17829
17830         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
17831         that.
17832
17833 2003-10-26  Karl Berry  <karl@gnu.org>
17834
17835         * config/srclist.txt (COPYING.DOC): no longer available from
17836         /gd/gnuorg; don't know where the ultimate source is.
17837
17838 2003-10-25  Paul Eggert  <eggert@twinsun.com>
17839
17840         Fix several address-calculation bugs in the hash modules,
17841         plus some minor code cleanup.
17842
17843         * lib/hash.h: Include <stdbool.h>, for bool.
17844         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
17845         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
17846         hash_get_n_entries, hash_get_max_bucket_length,
17847         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
17848         hash_rehash): Use size_t rather than unsigned.
17849         * lib/hash.c (struct hash_table, hash_get_n_buckets,
17850         hash_get_n_buckets_used, hash_get_n_entries,
17851         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
17852         hash_get_entries, hash_do_for_each, hash_string, is_prime,
17853         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
17854         Likewise.
17855         (SIZE_MAX): Define if not defined.
17856         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
17857         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
17858         hash_print):
17859         Use const * when possible.
17860         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
17861         (check_tuning): Fix bug: if tuning parameters were very close to
17862         0 or 1, rounding errors could have caused subscript violations.
17863         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
17864         (hash_initialize): Add 'fail:' label
17865         to free table and return NULL, and use it to simplify code.
17866         Use calloc rather than clearing the storage ourself.
17867         (hash_initialize, hash_rehash): Check for arithmetic overflow in
17868         buffer size calculations.
17869         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
17870         Include <stddef.h>, for size_t.
17871         * lib/hash-pjw.c (hash_pjw): Likewise.
17872         Switch to method described by Bruno Haible.
17873         Include <limits.h>, for CHAR_BIT.
17874         (SIZE_BITS): New macro.
17875
17876 2003-10-23  Paul Eggert  <eggert@twinsun.com>
17877
17878         * m4/getline.m4 (AM_FUNC_GETLINE):
17879         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
17880         hosts.  Problem reported by Derek Robert Price in
17881         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
17882         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
17883         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
17884
17885 2003-10-21  Paul Eggert  <eggert@twinsun.com>
17886
17887         * lib/getndelim2.c (getndelim2): When size calculation overflows,
17888         ceiling the allocation at NMAX bytes rather than silently
17889         discarding input bytes before NMAX is reached.  This makes
17890         a difference only if NMAX exceeds SIZE_MAX / 2.
17891
17892         * lib/obstack.c: Merge from glibc.
17893         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
17894         Add libc_hidden_def (_obstack_newchunk).
17895         (_obstack_free) [! defined _LIBC]: Remove.
17896         [defined _LIBC]: Make a strong alias from obstack_free, rather than
17897         a clone of the function body.
17898         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
17899         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
17900
17901         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
17902         glibc.
17903         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
17904         arg to memcpy.
17905
17906         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
17907         (obstack_ptr_grow_fast, obstack_int_grow_fast):
17908         Don't use lvalue casts, as GCC plans to remove support for them
17909         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
17910         was also present in the non-GCC version, indicating that this
17911         code had always been buggy and had never been widely used.
17912         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
17913         Use the fast variant of each macro, rather than copying the
17914         definiens of the fast variant; that way, we'll be more likely to
17915         catch future bugs in the fast variants.
17916
17917 2003-10-20  Bruno Haible  <bruno@clisp.org>
17918
17919         * modules/wait-process: New file.
17920         * MODULES.html.sh (func_all_modules): Add wait-process.
17921
17922 2003-10-20  Bruno Haible  <bruno@clisp.org>
17923
17924         * m4/wait-process.m4: New file.
17925
17926 2003-10-20  Bruno Haible  <bruno@clisp.org>
17927
17928         * lib/wait-process.h: New file, from GNU gettext.
17929         * lib/wait-process.c: New file, from GNU gettext.
17930
17931 2003-10-19  Jim Meyering  <jim@meyering.net>
17932
17933         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
17934         HPUX 10.20.
17935
17936 2003-10-18  Karl Berry  <karl@gnu.org>
17937
17938         * config/config.guess: update from config.
17939
17940 2003-10-16  Paul Eggert  <eggert@twinsun.com>
17941
17942         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
17943         (getgroups): First arg is int, not size_t.
17944         Don't let 'free' mangle errno.
17945
17946 2003-10-16  Paul Eggert  <eggert@twinsun.com>
17947
17948         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
17949
17950 2003-10-16  Karl Berry  <karl@gnu.org>
17951
17952         * config/config.{guess,sub}: update from config.
17953
17954 2003-10-16  Jim Meyering  <jim@meyering.net>
17955
17956         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
17957         memcpy.
17958
17959 2003-10-15  Paul Eggert  <eggert@twinsun.com>
17960
17961         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
17962         (SIZE_MAX): Remove.
17963         (new_exclude, add_exclude_file): Initial size no longer needs to
17964         be a power of 2.
17965         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
17966         our own address arithmetic overflow checking.
17967
17968         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
17969         (fnmatch): Do not alloca more than 2000 wide characters;
17970         instead, use malloc for large buffers.
17971         Check for address arithmetic overflow, and return -1
17972         with errno set to ENOMEM in that case.
17973         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
17974         (NEW_PATTERN): Do not alloca more than 8000 bytes;
17975         instead, return -1.  Check for address arithmetic overflow.
17976
17977 2003-10-14  Paul Eggert  <eggert@twinsun.com>
17978
17979         Handle invalid suffixes and overflow independently, so that
17980         callers can treat them independently as needed.  Fix some bugs in
17981         suffix handling, e.g., "100k@" was not diagnosed as an invalid
17982         suffix for a human-readable blocksize.  The major caller-visible
17983         change is the addition of a new
17984         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
17985         that both overflow and suffix chars were found.
17986
17987         * lib/human.c (humblock): Don't check separately for invalid suffix
17988         char; that is xstrtoumax's job (now that its bug is fixed).
17989         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
17990         INTMAX_MAX]: New macros.
17991         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
17992         TYPE_MAXIMUM): New macros.
17993         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
17994         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
17995         if overflow occurs, as it's what __strtol does and it's more useful
17996         in practice.
17997         (__xstrtol): If __strtol reports some error other than ERANGE,
17998         reflect it to the caller as LONGINT_INVALID.  If it reports
17999         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
18000         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
18001         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
18002         value.
18003         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
18004         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
18005         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
18006         [defined UINTMAX_MAX]: New macros.
18007
18008 2003-10-14  Bruno Haible  <bruno@clisp.org>
18009
18010         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
18011
18012 2003-10-14  Bruno Haible  <bruno@clisp.org>
18013
18014         * m4/sig_atomic_t: New file, from GNU gettext.
18015         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
18016
18017 2003-10-14  Bruno Haible  <bruno@clisp.org>
18018
18019         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
18020         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
18021         Also use volatile where needed.
18022
18023 2003-10-12  Paul Eggert  <eggert@twinsun.com>
18024
18025         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
18026         Change maintainer from Bruno Haible to 'all'.
18027
18028 2003-10-12  Paul Eggert  <eggert@twinsun.com>
18029
18030         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
18031
18032 2003-10-12  Paul Eggert  <eggert@twinsun.com>
18033
18034         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
18035         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
18036         and define in terms of the other primitives.
18037         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
18038         (SIZE_MAX): Define if not already defined.
18039         (array_size_overflow): New function.
18040         (xalloc_die): Abort instead of exiting if 'error' returns.
18041         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
18042         (xmalloc, xrealloc): Use them.
18043         (xcalloc): Check for address arithmetic overflow.
18044         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
18045         a bit faster than strcpy.
18046
18047 2003-10-10  Simon Josefsson  <jas@extundo.com>
18048
18049         * modules/argp (Depends-on): Add restrict and strcase.
18050
18051 2003-10-10  Simon Josefsson  <jas@extundo.com>
18052
18053         * m4/argp.m4: Add AC_C_INLINE.
18054
18055 2003-10-08  Paul Eggert  <eggert@twinsun.com>
18056
18057         Merge getpass from libc, plus a few fixes.
18058
18059         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
18060         Include <stdbool.h>.
18061         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
18062         __fsetlocking to empty.
18063         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
18064         do include <bits/libc-lock.h>.
18065         Do not include <fcntl.h>; not needed.
18066         [_LIBC]: Include <wchar.h>.
18067         (NOTCANCEL_MODE): New macro.
18068         (flockfile, funlockfile) [_LIBC]: New macros.
18069         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
18070         [!_LIBC]: New macros.
18071         (call_fclose): New function.
18072         (getpass): Use it.  Save tty stream separately; this simplifies the
18073         code and makes it more reliable if stdin happens to equal stdout.
18074         Invoke __fsetlocking on tty.
18075         Handle thread cancellation if needed.
18076         Namespace cleanup (use __tcgetattr, __getline).
18077         Use bool for Booleans.
18078         [USE_IN_LIBIO]: Handle wide streams.
18079         [!_LIBC]: Unconditionally do the fseek, since we don't know what
18080         stream might go where.
18081
18082         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
18083         doesn't have to include <stdio.h> before us.
18084         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
18085         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
18086         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
18087         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
18088         if not declared, so that we can use getpass.c code from libc without
18089         rewriting it.
18090         (flockfile, ftrylockfile, funlockfile): New macros.
18091
18092 2003-10-08  Paul Eggert  <eggert@twinsun.com>
18093
18094         * modules/getpass: Depend on stdbool.
18095
18096 2003-10-08  Paul Eggert  <eggert@twinsun.com>
18097
18098         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
18099
18100 2003-10-07  Karl Berry  <karl@gnu.org>
18101
18102         * config/config.{guess,sub}: update from config.
18103
18104 2003-10-06  Jim Meyering  <jim@meyering.net>
18105             Bruno Haible  <bruno@clisp.org>
18106
18107         This lets translators provide better translations for the
18108         "Written by ..." part of --version output.
18109         * lib/version-etc.h: Include stdarg.h.
18110         (version_etc_copyright): Declare as readonly.
18111         (version_etc): Make this function variadic with a NULL-terminated list
18112         of author name strings.
18113         (version_etc_va): New declaration.
18114         * lib/version-etc.c: Include stdarg.h, stdlib.h.
18115         (version_etc_copyright): Declare as readonly.
18116         (version_etc_va): New function. Provide a different translatable string
18117         for each possible number of authors < 10. Abbreviate when there are 10
18118         authors or more.
18119         (version_etc): Make this function variadic. Call version_etc_va.
18120         Suggestion from Gary V. Vaughan.
18121
18122         * lib/long-options.h (parse_long_options): Change prototype: the
18123         authors string is moved to the end and becomes variadic.
18124         * lib/long-options.c: Include stdarg.h.
18125         (parse_long_options): Make this function variadic, too.
18126         Call version_etc_va, not version_etc.
18127
18128 2003-10-06  Bruno Haible  <bruno@clisp.org>
18129
18130         * modules/version-etc-2: Remove file.
18131         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
18132
18133 2003-10-06  Bruno Haible  <bruno@clisp.org>
18134
18135         * modules/fatal-signal: New file.
18136         * MODULES.html.sh (func_all_modules): Add fatal-signal.
18137
18138 2003-10-06  Bruno Haible  <bruno@clisp.org>
18139
18140         * m4/fatal-signal.m4: New file.
18141         * m4/signalblocking.m4: New file, from GNU gettext.
18142
18143 2003-10-06  Bruno Haible  <bruno@clisp.org>
18144
18145         * lib/version-etc-2.h: Remove file.
18146         * lib/version-etc-2.c: Remove file.
18147
18148 2003-10-06  Bruno Haible  <bruno@clisp.org>
18149
18150         * lib/fatal-signal.h: New file, from GNU gettext.
18151         * lib/fatal-signal.c: New file, from GNU gettext.
18152
18153 2003-10-05  Paul Eggert  <eggert@twinsun.com>
18154
18155         * README: Rework advice for preventing empty .o files.
18156         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
18157         not <sys/types.h>.
18158
18159 2003-10-04  Karl Berry  <karl@gnu.org>
18160
18161         * lib/argp*: update from libc.
18162
18163 2003-10-04  Karl Berry  <karl@gnu.org>
18164
18165         * config/config.{guess,sub}: update from config.
18166
18167 2003-10-02  Bruno Haible  <bruno@clisp.org>
18168
18169         * modules/lchown (Include): Add lchown.h.
18170         * modules/time_r (Include): Use "..." syntax.
18171         * modules/xgetdomainname (Include): Add xgetdomainname.h.
18172
18173 2003-10-01  Simon Josefsson  <jas@extundo.com>
18174
18175         * MODULES.html.sh (func_all_modules): Move gethostname from section
18176         'based on' to section 'lacking' POSIX:2001.
18177
18178 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
18179
18180         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
18181         to output mode on the same stream.
18182
18183 2003-09-29  Paul Eggert  <eggert@twinsun.com>
18184
18185         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
18186         Fix arg typo in previous patch.
18187
18188 2003-09-28  Jim Meyering  <jim@meyering.net>
18189
18190         * lib/error.c: Correct cpp indentation.
18191
18192 2003-09-27  Paul Eggert  <eggert@twinsun.com>
18193
18194         * modules/free: New file.
18195
18196 2003-09-27  Paul Eggert  <eggert@twinsun.com>
18197
18198         * m4/free.m4: New file.
18199
18200 2003-09-27  Paul Eggert  <eggert@twinsun.com>
18201
18202         * lib/minmax.h (MIN, MAX)
18203         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
18204         Omit the special code that used __typeof__, since we worry that
18205         it could be more trouble than it's worth.  See:
18206         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
18207         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
18208
18209         * lib/free.c: New file.
18210
18211 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
18212
18213         Trivial fixes to Makefile.am parts of module listings.
18214         * modules/strstr: Append strstr.h to lib_SOURCES.
18215         * modules/strcase: Likewise, for strcase.h.
18216
18217 2003-09-27  Karl Berry  <karl@gnu.org>
18218
18219         * config/mkinstalldirs: update from automake.
18220
18221 2003-09-26  Paul Eggert  <eggert@twinsun.com>
18222
18223         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
18224         (error_tail): Do not loop, reallocating temporary buffer, since
18225         the output cannot contain more wide characters than the input
18226         contains bytes, the size must be big enough already.  This avoids
18227         one potential size overflow calculation.  Check for size overflow
18228         when calculating temporary buffer size.  Free temporary buffer
18229         when done, if it was allocated with malloc; this plugs a memory
18230         leak.  Remove casts from void * to pointers, that are no longer
18231         needed now that we're assuming C89 or better.
18232
18233         Merge error changes from glibc.
18234
18235         * lib/error.c, error.h: Update copyright notice header to match glibc.
18236         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
18237         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
18238         Disable cancellation while printing error.
18239         * lib/error.h: Prepend __ to parameter names.
18240
18241 2003-09-26  Jim Meyering  <jim@meyering.net>
18242
18243         * lib/error.c (error_tail): Move some declarations
18244         into inner scope where the local variables are used.
18245
18246 2003-09-26  Bruno Haible  <bruno@clisp.org>
18247
18248         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
18249         stpncpy().
18250         Don't define stpncpy through config.h; it's now done through stpncpy.h.
18251
18252 2003-09-26  Bruno Haible  <bruno@clisp.org>
18253
18254         * lib/stpncpy.h (gnu_stpncpy): New declaration.
18255         (stpncpy): Define as alias for gnu_stpncpy.
18256         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
18257
18258 2003-09-25  Simon Josefsson  <jas@extundo.com>
18259
18260         * lib/xgetdomainname.h: New file.
18261         * lib/xgetdomainname.c: New file.
18262
18263 2003-09-25  Simon Josefsson  <jas@extundo.com>
18264             Bruno Haible  <bruno@clisp.org>
18265
18266         * modules/getdomainname: New file.
18267         * modules/xgetdomainname: New file.
18268         * MODULES.html.sh (func_all_modules): Add getdomainname,
18269         xgetdomainname.
18270
18271 2003-09-25  Simon Josefsson  <jas@extundo.com>
18272             Bruno Haible  <bruno@clisp.org>
18273
18274         * m4/getdomainname.m4: New file.
18275
18276 2003-09-25  Simon Josefsson  <jas@extundo.com>
18277             Bruno Haible  <bruno@clisp.org>
18278
18279         * lib/getdomainname.h: New file.
18280         * lib/getdomainname.c: New file.
18281
18282 2003-09-25  Karl Berry  <karl@gnu.org>
18283
18284         * lib/argp-fmtstream.c, argp-help.c: update from libc.
18285
18286 2003-09-25  Karl Berry  <karl@gnu.org>
18287
18288         * config/install-sh: update from automake.
18289
18290 2003-09-25  Bruno Haible  <bruno@clisp.org>
18291
18292         * modules/version-etc-2: New file, from modules/version-etc with
18293         modifications.
18294         * MODULES.html.sh (func_all_modules): Add version-etc-2.
18295
18296 2003-09-25  Bruno Haible  <bruno@clisp.org>
18297
18298         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
18299         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
18300
18301 2003-09-24  Simon Josefsson  <jas@extundo.com>
18302
18303         * modules/xgethostname: Add xgethostname.h.
18304
18305 2003-09-24  Paul Eggert  <eggert@twinsun.com>
18306
18307         * lib/linebuffer.c (freebuffer): Don't free the argument, just
18308         the buffer associated with the argument.  Bug reported by
18309         Simon Josefsson.
18310
18311 2003-09-24  Paul Eggert  <eggert@twinsun.com>
18312
18313         * README: Document assumptions that 'int' is at least 32 bits
18314         wide, that integer arithmetic is 2's complement without overflow,
18315         that there are no holes in integer values, that adding sizes of
18316         two nonoverlapping objects can't overflow, and that all-bits-zero
18317         yields scalar zero.  Fix spelling and capitalization typos.
18318
18319 2003-09-19  Karl Berry  <karl@gnu.org>
18320
18321         * lib/argp.h: update from libc.
18322
18323 2003-09-17  Paul Eggert  <eggert@twinsun.com>
18324
18325         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
18326         to avoid spurious warnings like "AC_RUN_IFELSE was called before
18327         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
18328
18329 2003-09-17  Paul Eggert  <eggert@twinsun.com>
18330
18331         * gnulib-tool: Use "test -h", not "test -L", for portability
18332         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
18333         (tags_regexp): Remove, since \| doesn't conform to POSIX.
18334         (sed_extract_prog): Issue s commands one-by-one, rather than
18335         using \| in one s command.
18336
18337 2003-09-16  Paul Eggert  <eggert@twinsun.com>
18338
18339         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
18340         input error, instead of returning NULL the next time we are called
18341         (and therefore losing track of errno).
18342
18343 2003-09-16  Bruno Haible  <bruno@clisp.org>
18344
18345         * gnulib-tool (func_create_testdir): Warn about duplicated
18346         dependencies.
18347
18348 2003-09-15  Paul Eggert  <eggert@twinsun.com>
18349
18350         * modules/argmatch, modules/fatal, modules/obstack,
18351         modules/xalloc, modules/xgethostname: Sort dependencies by
18352         importance, not alphabetically.
18353
18354 2003-09-15  Paul Eggert  <eggert@twinsun.com>
18355
18356         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
18357         fails, so that the caller gets the proper errno.
18358
18359         * lib/readutmp.c (read_utmp): Likewise.
18360         Check for fstat error.  Close stream and free storage
18361         when failing.
18362
18363 2003-09-14  Karl Berry  <karl@gnu.org>
18364
18365         * config/srclist.txt (strdup.c): disable for c89 changes.
18366
18367 2003-09-14  Jim Meyering  <jim@meyering.net>
18368
18369         * lib/getloadavg.c: Correct cpp indentation.
18370         * lib/strdup.c: Likewise.
18371         * lib/vasnprintf.c: Likewise.
18372
18373 2003-09-14  Bruno Haible  <bruno@clisp.org>
18374
18375         * modules/fwriteerror: New file.
18376         * MODULES.html.sh (func_all_modules): Add fwriteerror.
18377
18378 2003-09-14  Bruno Haible  <bruno@clisp.org>
18379
18380         * lib/fwriteerror.h: New file.
18381         * lib/fwriteerror.c: New file.
18382
18383 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18384
18385         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
18386         modules/xgethostname, modules/xalloc: Depend on exit.
18387
18388 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18389
18390         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
18391
18392         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
18393         and AC_MINIX, too, so that their extensions are available.
18394
18395         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
18396         This macro has been superseded by gl_BACKUPFILE.
18397
18398         More patches to assume C89 or better.
18399
18400         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
18401
18402         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
18403         unconditionally.
18404         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
18405         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
18406         Include <string.h>, <stdlib.h> unconditionally.
18407         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
18408         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
18409         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
18410         headers or for string.h.
18411         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
18412         or strtoul.
18413
18414         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
18415         headers.
18416         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
18417         * m4/userspec.m4 (gl_USERSPEC): Likewise.
18418         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
18419         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
18420         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
18421         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
18422         memcpy, memset.
18423         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
18424         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
18425         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
18426         strtol.
18427         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
18428         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
18429         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
18430         strtoul.
18431
18432 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18433
18434         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
18435         * lib/obstack.c [!defined _LIBC]: Likewise.
18436         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
18437         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
18438         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
18439
18440         More changes to assume C89 or better.
18441
18442         * lib/error.c (error_tail): Assume vprintf.
18443
18444         * lib/argmatch.c (getenv): Remove decl.
18445         * lib/progreloc.c (get_full_program_name): Define via prototype.
18446         * lib/setenv.c (clearenv): Likewise.
18447         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
18448         needed.
18449         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
18450         (malloc, memcpy): Remove decls.
18451         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
18452         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
18453         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
18454         (memcpy): Remove macro.
18455         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
18456         (__P): Remove.  All uses removed.
18457         (PTR): Remove.  All uses changed to void *.
18458         (CHAR_BIT, NULL): Remove.
18459         (spaces, zeros, memset_space, memset_zero)
18460         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
18461         Remove.
18462         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
18463         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
18464         Define with prototype.
18465         Remove now-unnecessary prototype decl.
18466         (extra_args_spec): Assume ANSI C.  All uses changed.
18467         (extra_args_spec_iso): Remove.
18468         (my_strftime, emacs_strftimeu): Define via prototype.
18469         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
18470         unconditionally.
18471         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
18472         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
18473         (strtoul, strtol): Remove decls.
18474         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
18475         LONG_MAX): Remove.
18476         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
18477         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
18478         (LOCALE_PARAM_PROTO): New macro.
18479         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
18480         (INTERNAL (strtol), strtol): Define with a prototype.
18481         (PARAMS): Remove.  All uses removed.
18482         * lib/tempname.c: Include <string.h> unconditionally.
18483         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
18484         * lib/xgethostname.c (main): Define with a prototype.
18485         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
18486         Include <stdlib.h> unconditionally.
18487         (calloc, malloc, realloc, free): Remove decls.
18488         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
18489         Include <stdlib.h> unconditionally.  Sort include file names.
18490         (strtod): Remove.
18491         (xstrtod): Define with a prototype.
18492         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
18493         (strtol, strtoul): Remove decls.
18494
18495 2003-09-11  Paul Eggert  <eggert@twinsun.com>
18496
18497         More patches to assume C89 or better.
18498         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
18499         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
18500         string.h, memchr, STDC_HEADERS.
18501
18502 2003-09-11  Paul Eggert  <eggert@twinsun.com>
18503
18504         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
18505         Include <stdlib.h>, <string.h> unconditionally.
18506         Remove now-unnecessary cast to char *.
18507         * lib/strnlen.c: Include <string.h> unconditionally.
18508         * lib/yesno.c (yesno): Define with a prototype.
18509
18510 2003-09-11  Bruno Haible  <bruno@clisp.org>
18511
18512         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
18513
18514 2003-09-10  Jim Meyering  <jim@meyering.net>
18515
18516         * lib/error.c: Correct indentation of cpp directives.
18517
18518 2003-09-10  Bruno Haible  <bruno@clisp.org>
18519
18520         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
18521         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
18522         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
18523         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
18524         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
18525         <stdlib.h> and <string.h> checks.
18526         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
18527         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
18528
18529 2003-09-10  Bruno Haible  <bruno@clisp.org>
18530
18531         * lib/strcspn.c: Include <string.h> unconditionally.
18532         * lib/strpbrk.c: Include <string.h> unconditionally.
18533         * lib/strstr.c: Include <string.h> unconditionally.
18534         * lib/unicodeio.c: Include <string.h> unconditionally.
18535         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
18536         * lib/unsetenv.c: Likewise.
18537         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
18538         * lib/yesno.c: Include <stdlib.h> unconditionally.
18539         (rpmatch): Add prototype.
18540
18541 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18542
18543         More patches to assume C89 or better.
18544         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
18545         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
18546         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
18547         or for string.h.
18548         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
18549         stdlib.h.
18550         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
18551         C headers.
18552         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
18553         string.h.
18554         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
18555         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
18556         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
18557         or for string.h.
18558         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
18559         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
18560         C headers.
18561         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
18562         memcpy.
18563         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
18564         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
18565         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
18566         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
18567         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
18568         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
18569         string.h, free.
18570         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
18571         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
18572         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
18573         C headers, or for string.h.
18574         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
18575         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
18576         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
18577         headers, memory.h, stdlib.h, string.h, strings.h.
18578         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
18579         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
18580         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
18581         strchr.
18582         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
18583         headers, memory.h, string.h.
18584         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
18585         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
18586         free.
18587         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
18588         headers.
18589         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
18590         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
18591         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
18592         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
18593         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
18594
18595 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18596
18597         More K&R removal.
18598
18599         * lib/acosl.c (main): Use a prototype.
18600         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
18601         tanl.c: Likewise.
18602
18603         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
18604
18605         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
18606         (getopt, etopt_long, getopt_long_only, _getopt_internal)
18607         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
18608         with a prototype.
18609         * lib/getopt.c (const): Remove macro.
18610         Include <string.h> unconditionally.
18611         (my_index): Remove; all uses changed to strchr.
18612         (strlen): Remove decl.
18613         (exchange): Remove forward decl; no longer needed.
18614         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
18615         Define with prototype.
18616         * lib/getopt1.c (const): Remove macro.
18617         (getopt_long, getopt_long_only, main): Define with prototype.
18618
18619         * lib/getugroups.c: Include <string.h> unconditionally.
18620
18621         * lib/getusershell.c: Include <stdlib.h> unconditionally.
18622         (getusershell, setusershell, endusershell, readname, main):
18623         Define with prototypes.
18624
18625         * lib/group-member.c: Include group-member.h first.
18626         Include <stdlib.h> unconditionally.
18627
18628         * lib/hard-locale.c: Include hard-locale.h first.
18629         Include <stdlib.h>, <string.h> unconditionally.
18630
18631         * lib/hash.c (free, malloc): Remove decls.
18632         Include <stdlib.h> unconditionally.
18633
18634         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
18635         (getenv): Do not declare.
18636
18637         * lib/idcache.c: Include <string.h> unconditionally.
18638
18639         * lib/long-options.c: Include long-options.h first, to test interface.
18640         Include <stdlib.h> unconditionally.
18641
18642         * lib/makepath.c: Include makepath.h first, to test interface.
18643         Include <stdlib.h> and <string.h> unconditionally.
18644
18645         * lib/linebuffer.c: Include <stdlib.h>.
18646         (free): Remove decl.
18647
18648         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
18649         stddef.h. rpl_malloc returns void *, not char *.
18650         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
18651         prototype.
18652
18653         * lib/md5.h: Include <limits.h> unconditionally.
18654         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
18655         (__P): Remove; all uses removed.
18656         * lib/md5.c: Include "md5.h" first.
18657         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
18658         md5_buffer, md5_process_bytes, md5_process_block):
18659         Define with prototypes.
18660         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
18661         * lib/sha.c: Include "sha.h" first.
18662         Include <stdlib.h>, <string.h> unconditionally.
18663
18664         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
18665         * lib/memcmp.c (__ptr_t): Likewise.
18666         * lib/memrchr.c (__ptr_t): Likewise.
18667         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
18668         Include <string.h> unconditionally.
18669         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
18670         * lib/memchr.c: Include <stdlib.h> unconditionally.
18671         * lib/memchr.c (LONG_MAX): Remove.
18672         * lib/memrchr.c (LONG_MAX): Likewise.
18673         * lib/memchr.c (__memchr): Define via a prototype.
18674         * lib/memrchr.c (__memrchr): Likewise.
18675         * lib/memcmp.c (__P): Remove, and remove all uses.
18676         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
18677         Remove forward decls; no longer needed.
18678         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
18679         Use types required by C89 in prototype.
18680
18681         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
18682         * lib/savedir.c: Likewise.
18683         * lib/mkdir.c (free): Remove decl.
18684         * lib/rmdir.c (rmdir): Define with a prototype.
18685         * lib/savedir.c: Include savedir.h first, to test interface.
18686
18687         * lib/mktime.c (STDC_HEADERS): Remove.
18688         Include <stdlib.h>, <string.h> unconditionally.
18689
18690         * lib/modechange.c: Include <stdlib.h> unconditionally.
18691         (malloc): Remove decl.
18692
18693         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
18694         (free): Remove decl.
18695
18696         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
18697         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
18698         (This type really should be intptr_t, but that's a C99ism.)
18699         (_obstack_memcpy): Remove: all uses changed to memcpy.
18700         Include <string.h> unconditionally.
18701         (struct obstack): Assume __STDC__ for types of members
18702         chunkfun, freefun, extra_arg.
18703         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
18704         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
18705         obstack_begin, obstack_specify_allocation,
18706         obstack_specify_allocation_with_arg, obstack_chunkfun,
18707         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
18708         Remove unprototyped decls and the macros that use them.
18709         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
18710         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
18711         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
18712         (defined __STDC__ && __STDC__)]:
18713         Remove nonprototyped code.
18714         Include <stdlib.h> unconditionally.
18715         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
18716         _obstack_allocated_p, _obstack_free, obstack_free,
18717         _obstack_memory_used, print_and_abort):
18718         Define using prototypes.
18719         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
18720         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
18721         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
18722         obstack_next_free, obstack_object_size, obstack_room) [0]:
18723         Remove unused, unprototyped code.
18724
18725         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
18726
18727         * lib/physmem.c (physmem_total, physmem_available, main): Define
18728         with prototypes.
18729
18730         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
18731         (main): Define with a prototype.
18732
18733         * lib/posixver.c (getenv): Remove decl.
18734
18735         * lib/putenv.c (malloc): Returns void *, not char *.
18736         Include <string.h> unconditionally.
18737         (strchr, memcpy, NULL): Do not define.
18738
18739         * lib/readtokens.c: Include readtokens.h first, to test interface.
18740         Include <stdlib.h>, <string.h> unconditionally.
18741         (init_tokenbuffer): Define with a prototype.
18742
18743         * lib/regex.c (PARAMS): Remove.  All uses removed.
18744         All uses of _RE_ARGS removed, too.
18745         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
18746         unconditionally.
18747         (bzero): Assume memset exists.
18748         (memcmp, memcpy, NULL): Remove.
18749         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
18750         char, or assignments to local vars of type signed char.
18751         (init_syntax_once, PREFIX(extract_number_and_incr),
18752         PREFIX(print_partial_compiled_pattern),
18753         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
18754         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
18755         PREFIX(regex_grow_registers), PREFIX(regex_compile),
18756         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
18757         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
18758         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
18759         wcs_compile_range, byte_compile_range, truncate_wchar,
18760         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
18761         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
18762         count_mbs_length, wcs_re_match_2_internal,
18763         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
18764         PREFIX(alt_match_null_string_p),
18765         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
18766         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
18767         regfree, PREFIX(extract_number)): Define with prototype.  Remove
18768         now-unnecessary declaration, if any.
18769         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
18770         regcomp, regexec):
18771         Remove now-unnecessary casts among pointer types.
18772         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
18773
18774         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
18775         (free): Remove decl.
18776
18777         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
18778
18779         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
18780         (free): Remove decl.
18781
18782         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
18783         * lib/xgetcwd.c: Likewise.
18784
18785         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
18786         (free): Remove decl.
18787
18788         * lib/strchrnul.c (strchrnul): Define with a prototype.
18789         Fix bug: c_in was not converted to char before searching.
18790
18791         The following changes are not K&R related:
18792
18793         * lib/group-member.h: Include <sys/types.h>, so that this file is
18794         self-contained.
18795         * lib/makepath.h: Likewise.
18796
18797         * lib/getusershell.c (readname, default_index, line_size, readname):
18798         Use size_t, not int, for sizes.
18799         (readname): If the size overflows, report an error instead of
18800         looping forever.
18801
18802 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18803
18804         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
18805         libc.
18806
18807 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18808
18809         * README: New section: portability guidelines.
18810
18811 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
18812
18813         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
18814         C89 spec.
18815
18816 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
18817
18818         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
18819
18820 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18821
18822         Assume C89 or better; remove K&R cruft.
18823         A few of these changes were first proposed by Derek Robert Price
18824         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
18825
18826         * lib/addext.c: Include <string.h> unconditionally.
18827         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
18828         Don't declare getenv or malloc.
18829
18830         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
18831         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
18832         (NULL): Remove.
18833         (find_stack_direction, alloca): Use prototypes.
18834
18835         * lib/atexit.c (atexit): Define using a prototype.
18836
18837         * lib/basename.c, dirname.c, stripslash.c:
18838         Include <string.h> unconditionally.
18839
18840         * lib/bcopy.c: Include <stddef.h>.
18841         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
18842
18843         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
18844
18845         * lib/error.h (error, error_at_line, error_print_progname)
18846         [! (defined (__STDC__) && __STDC__)]: Remove decls.
18847         * lib/error.c: Include error.h first, to check interface.
18848         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
18849         (VA_START): Remove; all uses changeed to va_start.
18850         (exit, strerror): Remove decls.
18851         (error_print_progname): Prototype uncondionally.
18852         Don't include <errno.h>; no longer needed.
18853         (private_strerror): Remove.
18854         (error_tail): Always define.
18855         (error, error_at_line): Assume C89 or better; always use prototypes.
18856         * lib/fatal.c: Include "fatal.h" first, to test interface.
18857         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
18858         (VA_START): Remove; all uses changed to va_start.
18859         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
18860         this case.
18861         (exit): Remove decl.
18862         (fatal): Prototype unconditionally.  Assume va_start works.
18863         Abort at end, to pacify gcc.
18864
18865         * lib/euidaccess.c (main): Define with a prototype.
18866
18867         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
18868
18869         * lib/exitfail.c: Include <stdlib.h> unconditionally.
18870
18871         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
18872         prototypes.
18873         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
18874         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
18875         (getenv): Remove decl.
18876         (fnmatch): Define using a prototype.
18877         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
18878         (FCT): Define using a prototype.
18879
18880         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
18881
18882         * lib/gethostname.c: Include <stddef.h>.
18883         (gethostname): Define with prototype.  Length is size_t, not int.
18884
18885 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18886
18887         Assume C89 or better; remove K&R cruft.
18888         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
18889         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
18890         string.h, getenv, malloc.
18891         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
18892         headers.
18893         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
18894         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
18895         do not check for strerror.
18896         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
18897         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
18898         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
18899         do not check for doprnt or vprintf.
18900         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
18901         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
18902
18903 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18904
18905         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
18906         getversion.c should have been removed then, but was accidentally
18907         preserved.
18908
18909         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
18910         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
18911
18912 2003-09-08  Karl Berry  <karl@gnu.org>
18913
18914         * config/config.sub, config.guess, srclistvars.sh: update from savannah
18915                 config, forget about prep.
18916
18917         * config/depcomp, missing: update from automake.
18918
18919 2003-09-07  Paul Eggert  <eggert@twinsun.com>
18920
18921         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
18922         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
18923
18924 2003-09-07  Paul Eggert  <eggert@twinsun.com>
18925
18926         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
18927         copy_tm_result.  Bug reported by Simon Josefsson in
18928         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
18929
18930 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18931
18932         * m4/time_r.m4: New file.
18933         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
18934         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
18935         is. Check for timegm declaration.
18936         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
18937         Do not check for gmtime_r.
18938         Replace mktime if __mktime_internal does not exist and if mktime
18939         hasn't been replaced already.
18940
18941 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18942
18943         * lib/time_r.c, lib/time_r.h: New files.
18944
18945         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
18946         __localtime_r.
18947         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
18948         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
18949
18950         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
18951         __gmtime_r.
18952         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
18953         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
18954         Include <time_r.h>.
18955
18956         * lib/timegm.c: Switch to glibc implementation, with the following
18957         changes:
18958         [defined HAVE_CONFIG_H]: Include <config.h>.
18959         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
18960         (__mktime_internal) [!defined _LIBC]: New decl.
18961         (__gmtime_r) [!defined _LIBC]: New macro and function.
18962         (timegm): Use a prototype, since gnulib assumes C89.
18963         Do not bother declaring tmp to be const, as it's not really usefu.
18964         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
18965         (timegm): Declare only if HAVE_DECL_TIMEGM.
18966
18967 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18968
18969         * MODULES.html.sh (func_all_modules): Add time_r.
18970         * modules/time_r: New file.
18971         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
18972         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
18973
18974 2003-09-03  Paul Eggert  <eggert@twinsun.com>
18975
18976         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
18977         Bug reported by Lute Kamstra in
18978         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
18979
18980         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
18981         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
18982         course with correspondingly smaller numbers for tomorrow and
18983         yesterday.  From Tadayoshi Funaba.  Originally installed into
18984         sh-utils on 1999-08-07, but the patch got lost (I guess during the
18985         coreutils merge?).
18986
18987 2003-08-31  Simon Josefsson  <jas@extundo.com>
18988
18989         * modules/timegm: New file.
18990         * MODULES.html.sh (func_all_modules): Add timegm.
18991
18992 2003-08-31  Simon Josefsson  <jas@extundo.com>
18993
18994         * m4/timegm.m4: New file.
18995
18996 2003-08-31  Simon Josefsson  <jas@extundo.com>
18997
18998         * lib/timegm.h: New file.
18999         * lib/timegm.c: New file.  Based on
19000         wget-1.8.2/src/http.c:mktime_from_utc.
19001
19002 2003-08-31  Karl Berry  <karl@gnu.org>
19003
19004         * lib/argp.h: update from libc.
19005
19006 2003-08-28  Bruno Haible  <bruno@clisp.org>
19007
19008         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
19009         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
19010         followed by '#define fnmatch fnmatch_posix' gives an error.
19011
19012 2003-08-28  Bruno Haible  <bruno@clisp.org>
19013
19014         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
19015         warning on QNX, which defines O_BINARY to 000000.
19016
19017 2003-08-27  Jim Meyering  <jim@meyering.net>
19018
19019         * m4/mkstemp.m4: Require that the system mkstemp be able to create
19020         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
19021         would fail after 32.  Reported by Danny Levinson.  Details here:
19022         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
19023
19024 2003-08-24  Bruno Haible  <bruno@clisp.org>
19025
19026         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
19027         MSVC7 <stdio.h> is included later.
19028
19029 2003-08-22  Simon Josefsson  <jas@extundo.com>
19030
19031         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
19032
19033 2003-08-20  Karl Berry  <karl@gnu.org>
19034
19035         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
19036
19037 2003-08-20  Bruno Haible  <bruno@clisp.org>
19038
19039         * modules/progname: New file.
19040         * MODULES.html.sh (func_all_modules): Add progname.
19041
19042 2003-08-20  Bruno Haible  <bruno@clisp.org>
19043
19044         * lib/progname.h: New file, from GNU gettext.
19045         * lib/progname.c: New file, from GNU gettext.
19046         * lib/progreloc.c: New file, from GNU gettext.
19047
19048 2003-08-19  Jim Meyering  <jim@meyering.net>
19049
19050         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
19051         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
19052
19053 2003-08-19  Bruno Haible  <bruno@clisp.org>
19054
19055         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
19056         more.
19057
19058 2003-08-19  Bruno Haible  <bruno@clisp.org>
19059
19060         * lib/xstrdup.c: Assume <string.h> exists.
19061
19062 2003-08-18  Paul Eggert  <eggert@twinsun.com>
19063
19064         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
19065         in makefile rules.
19066
19067 2003-08-18  Jim Meyering  <jim@meyering.net>
19068
19069         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
19070         * m4/lib-ld.m4: Likewise.
19071
19072 2003-08-18  Jim Meyering  <jim@meyering.net>
19073
19074         * lib/setenv.h: Indent nested cpp directive.
19075         * lib/vasnprintf.c: Remove trailing blanks.
19076
19077 2003-08-17  Simon Josefsson  <jas@extundo.com>
19078
19079         * modules/xstrndup: New file.
19080         * MODULES.html.sh (func_all_modules): Add xstrndup.
19081
19082 2003-08-17  Simon Josefsson  <jas@extundo.com>
19083
19084         * modules/argp: Fix autoconf macro name. Add more dependencies.
19085
19086 2003-08-17  Simon Josefsson  <jas@extundo.com>
19087
19088         * m4/xstrndup.m4: New file.
19089
19090 2003-08-17  Simon Josefsson  <jas@extundo.com>
19091
19092         * m4/argp.m4: New file.
19093
19094 2003-08-17  Simon Josefsson  <jas@extundo.com>
19095             Bruno Haible  <bruno@clisp.org>
19096
19097         * lib/xstrndup.h: New file.
19098         * lib/xstrndup.c: New file.
19099
19100 2003-08-17  Bruno Haible  <bruno@clisp.org>
19101
19102         * modules/strndup (Files, Include): Add lib/strndup.h.
19103
19104 2003-08-17  Bruno Haible  <bruno@clisp.org>
19105
19106         * modules/euidaccess (Files): Add lib/euidaccess.h.
19107
19108 2003-08-17  Bruno Haible  <bruno@clisp.org>
19109
19110         * lib/strndup.h: New file.
19111
19112 2003-08-17  Bruno Haible  <bruno@clisp.org>
19113
19114         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
19115         like AC_GNU_SOURCE.
19116         * modules/extensions (configure.ac): Comment out the invocation of
19117         gl_USE_SYSTEM_EXTENSIONS.
19118
19119 2003-08-16  Paul Eggert  <eggert@twinsun.com>
19120
19121         Merges from coreutils, etc.
19122         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
19123         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
19124         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
19125         fixing a typo.
19126         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
19127         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
19128
19129 2003-08-16  Paul Eggert  <eggert@twinsun.com>
19130
19131         Document merge from coreutils.
19132         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
19133         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
19134         * modules/utime: Add m4/utimes-null.m4.
19135
19136 2003-08-16  Paul Eggert  <eggert@twinsun.com>
19137
19138         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
19139         space, undoing this 2003-08-12 change:
19140         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
19141
19142 2003-08-16  Paul Eggert  <eggert@twinsun.com>
19143
19144         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
19145         strtoul.c from libc, undoing this 2003-08-12 change:
19146         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
19147
19148 2003-08-16  Jim Meyering  <jim@meyering.net>
19149
19150         Merges from coreutils.
19151         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
19152         prefix.  Adjust cache variables similarly.  Create 500 rather than
19153         just 300 files, to exercise bug on Darwin6.5, too.
19154         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
19155         $missing_dir.
19156         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
19157         AM_SYS_POSIX_TERMIOS.
19158         Reported by mkc@mathdogs.com.
19159         Also change use of $am_cv_sys_posix_termios
19160         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
19161         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
19162         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
19163         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
19164         in /proc/mounts until it finds one with matching device number.  This
19165         is unnecessary when the FILE argument *is* a mount point.  No stat call
19166         is necessary in that case.  So, disable the statvfs-testing code on
19167         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
19168         as RedHat bug# 84846.
19169         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
19170         to 1MB, so as not to render systems with no stack size limit (e.g.,
19171         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
19172         Include <unistd.h>.  On some systems,
19173         it is required for the definition of _SC_PAGESIZE.
19174
19175 2003-08-16  Jim Meyering  <jim@meyering.net>
19176
19177         Merge from coreutils.
19178         * lib/xstrtoimax.c: #else #if -> #elif.
19179         * lib/xstrtoumax.c: Likewise.
19180
19181 2003-08-16  Jim Meyering  <jim@meyering.net>
19182
19183         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
19184         * m4/utimes.m4: Removed.
19185         * m4/utimes-null.m4: Renamed from utimes.m4.
19186
19187         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
19188         to 1MB, so as not to render systems with no stack size limit (e.g.,
19189         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
19190         Include <unistd.h>.  On some systems,
19191         it is required for the definition of _SC_PAGESIZE.
19192
19193 2003-08-16  Jim Meyering  <jim@meyering.net>
19194         and Paul Eggert  <eggert@cs.ucla.edu>
19195
19196         Merges from coreutils, etc.
19197
19198         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
19199         using the latest version from cvs.  This avoids problems with #line
19200         directives using a vendor (Sun) compiler.
19201         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
19202         Don't set GETGROUPS_LIB here; now it's
19203         done via getgroups.m4's wrapper function.
19204         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
19205         rather than just in sh-util/configure.in, so that the
19206         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
19207         same.
19208         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
19209         AC_FUNC_GETLOADAVG where to find getloadavg.c.
19210         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
19211         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
19212         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
19213         Remove code that is now done by the newly-required macros.
19214         Append $(EXEEXT) to DF_PROG.
19215         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
19216         Do not invoke or require the following here,
19217         since prereq.m4 or some gnulib .m4 now does this for us:
19218         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
19219         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
19220         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
19221         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
19222         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
19223         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
19224         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
19225         AC_FUNC_OBSTACK.
19226         Do not replace the following functions, as this is now the job
19227         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
19228         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
19229         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
19230         atexit getpass, strdup, getpagesize.
19231         Replace 'raise'.
19232         Do not check for the following functions, as this is now the job
19233         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
19234         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
19235         setregid.
19236         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
19237         Check for sys/sysctl.h.
19238         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
19239         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
19240         of checking for ssize_t ourselves.
19241
19242         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
19243         Require every macro that gnulib/modules/* suggests for us.
19244         (jm_PREREQ_ADDEXT): New macro.
19245         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
19246         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
19247
19248         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
19249         (gl_PHYSMEM): Use it.
19250         Also check for `table' function.
19251         Check for new headers and functions.
19252         Add check for sys/sysmp.h.
19253         With suggestions from Kaveh Ghazi.
19254         Ignore headers that are present but cannot be compiled.  This
19255         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
19256         C 5.4.
19257
19258 2003-08-15  Paul Eggert  <eggert@twinsun.com>
19259
19260         Document merge from coreutils.
19261         * modules/userspec: Depend on posixver.
19262         * modules/strftime: Depend on tzset.
19263
19264 2003-08-15  Paul Eggert  <eggert@twinsun.com>
19265
19266         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
19267         rather than tab, after '#' in shell-script copyright notices.
19268         Suggested by Bruno Haible.
19269
19270 2003-08-15  Paul Eggert  <eggert@twinsun.com>
19271
19272         * config/srclist-update: Use three spaces, rather than tab, after '#'
19273         in shell-script copyright notices.  Suggested by Bruno Haible.
19274         Remove unnecessary parenthesization in regular expression.
19275
19276 2003-08-15  Jim Meyering  <jim@meyering.net>
19277
19278         Merge from coreutils.
19279         * lib/xgethostname.c: Include <stdlib.h>.
19280         (xghostname): Don't exit for anything other than memory-related
19281         failure; just return NULL.
19282         * lib/userspec.c: Include "posixver.h".
19283         (parse_user_spec): Accept `.' as a separator only
19284         in pre-POSIX-200112 mode.
19285         * lib/strtoimax.c: Use #elif rather than #else #if.
19286         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
19287         Remove function, now that we can rely on a working tzset function.
19288         [!_LIBC]: Ensure that the required autoconf test has been run.
19289         [!defined _NL_CURRENT && HAVE_STRFTIME]:
19290         Use underlying_strftime for %r.
19291         * lib/sha.c: Merge in some clean-up and optimization changes from
19292         glibc.
19293         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
19294         Ensure that it is a multiple of 64.
19295         Rearrange loop exit tests so as to avoid performing an
19296         additional fread after encountering an error or EOF.
19297         * lib/realloc.c: Update copyright date.
19298
19299 2003-08-15  Jim Meyering  <jim@meyering.net>
19300         and Paul Eggert  <eggert@twinsun.com>
19301
19302         Merge from coreutils.
19303         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
19304         member but strut utmpx does not.  Needed for AIX 4.3.3.
19305         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
19306
19307 2003-08-15  Jim Meyering  <jim@meyering.net>
19308         and Paul Eggert  <eggert@cs.ucla.edu>
19309
19310         Merges from coreutils, etc.
19311         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
19312         Require gl_FUNC_TZSET_CLOBBER.
19313         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
19314         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
19315         members.
19316
19317 2003-08-14  Paul Eggert  <eggert@twinsun.com>
19318
19319         Help the merge from coreutils.
19320         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
19321         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
19322         * m4/tzset.m4: Use it too.
19323
19324 2003-08-14  Paul Eggert  <eggert@twinsun.com>
19325
19326         * modules/tzset: New file.
19327
19328 2003-08-14  Jim Meyering  <jim@meyering.net>
19329
19330         Merges from coreutils.
19331         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
19332         variable names, rather than @FNMATCH_H@.
19333         * modules/alloca: Likewise for $(ALLOCA_H).
19334
19335         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
19336         the three copies of the literal target, `fnmatch.h'.
19337         * modules/alloca (alloca.h): Likewise.
19338
19339 2003-08-14  Jim Meyering  <jim@meyering.net>
19340
19341         Merge from coreutils.
19342         * m4/tzset.m4: New file.
19343         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
19344         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
19345         otherwise, AIX 5.1 systems would end up using the latter.
19346         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
19347         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
19348         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
19349         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
19350
19351 2003-08-14  Jim Meyering  <jim@meyering.net>
19352
19353         Merge from coreutils.
19354         * lib/obstack.h: Whitespace changes.
19355         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
19356         and xcalloc return values.
19357         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
19358         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
19359         hang on OSF/1 5.1 for DIR on both local and remote file systems.
19360         Reported by (and fix confirmed by) Nelson H. F. Beebe.
19361         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19362         error from mntctl.
19363         Use mntctl's return value to drive the entry-processing loop, since
19364         we can't rely on the value of the vmt_length member in the last
19365         entry.  On some systems doing so could result in exhausting
19366         virtual memory.  Based in part on a patch from Mike Jetzer.
19367
19368 2003-08-14  Jim Meyering  <jim@meyering.net>
19369         and Paul Eggert  <eggert@twinsun.com>
19370
19371         Merges from coreutils, plus other fixes.
19372         * lib/physmem.c: Merge in portability changes from gcc/libiberty
19373         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
19374         for credits and details.  Thanks to Kaveh Ghazi for helping
19375         to keep these files in sync.
19376         (ARRAY_SIZE): Define it.
19377         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
19378         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
19379         (memcasecmp): Don't assume size_t fits in unsigned int.
19380         Remove casts and duplicate code.
19381         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
19382         (memcpy): Remove definition.
19383         Merge in some clean-up and optimization changes from glibc.
19384         [BLOCKSIZE]: Move definition to top of file.
19385         Ensure that it is a multiple of 64.
19386         Rearrange loop exit tests so as to avoid performing an
19387         additional fread after encountering an error or EOF.
19388         * lib/md5.h (md5_uintptr): Define.
19389         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
19390         return to the initial working directory.  Preserve errno
19391         for caller.
19392         * lib/idcache.c: Include "xalloc.h".
19393         (xmalloc, xrealloc): Remove decls.
19394         (getuser): Remove casts no longer required in C89.
19395         * lib/human.c: Include stdio.h, for sprintf.
19396         * lib/group-member.c: Include "xalloc.h".
19397         (xmalloc, xrealloc): Remove decls.
19398         (get_group_info): Remove casts no longer required in C89.
19399         * lib/getusershell.c (readname): Remove casts no longer required in
19400         C89.
19401         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
19402         * lib/getline.c: Whitespace fix, from coreutils.
19403
19404 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19405
19406         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
19407         Check for isascii.
19408
19409         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
19410         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
19411         Undo previous (whitespace-only) change.
19412
19413 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19414
19415         * lib/exclude.c: Include <ctype.h>
19416         (IN_CTYPE_DOMAIN): New macro.
19417         (is_space): New fn.
19418         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
19419         and empty lines.
19420
19421         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
19422         Undo previous (whitespace-only) change.
19423
19424 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19425
19426         * config/srclist-update: Change update back to the old behavior,
19427         leaving whitespace alone.  Use one 'sed' command rather than a
19428         pipeline.
19429         (fixlicense): Now a variable, not a function.
19430         (remove_trailing_blanks): Remove.
19431         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
19432         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
19433         Undo previous (whitespace-only) change.
19434
19435 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19436
19437         Merge from coreutils.
19438         * modules/euidaccess: Add lib_SOURCES, include for new
19439         file euidaccess.h
19440
19441 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19442
19443         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
19444         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
19445         Normalize leading white space and remove trailing white space.
19446
19447         Merge from coreutils
19448         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
19449
19450         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
19451         0.12.1.  These files are now being upgraded automatically by
19452         ../config/srclist-update.
19453
19454 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19455
19456         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
19457         Normalize leading white space and remove trailing white space.
19458         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
19459         notice, as per ../config/srclist-update.
19460
19461         Merge from coreutils.
19462         * lib/euidaccess.h: New file.
19463         * lib/euidaccess.c: Include it.
19464         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
19465         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
19466         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
19467
19468 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19469
19470         * config/srclist-update: Add copyright notice.
19471         (remove_id_lines, remove_trailing_blanks): New constants.
19472         (fixfile): Use them to normalize spacing a bit in copied files.
19473         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
19474         Normalize leading white space and remove trailing white space.
19475
19476         * config/texinfo.tex: Sync with texinfo.
19477
19478         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
19479         strtoul.c from libc, to merge coreutils whitespace changes.
19480
19481         * config/srclist.txt: Get the following m4 files from gettext:
19482         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
19483         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
19484         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
19485         wint_t.m4.
19486
19487 2003-08-12  Karl Berry  <karl@gnu.org>
19488
19489         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
19490         been made.
19491
19492 2003-08-11  Paul Eggert  <eggert@twinsun.com>
19493
19494         * modules/gnu-source, m4/gnu-source.m4:
19495         Remove; we're assuming Autoconf 2.54 or later now.
19496         Suggested by Bruno Haible.
19497         * MODULES.html.sh (func_all_modules): Remove gnu-source.
19498
19499 2003-08-11  Bruno Haible  <bruno@clisp.org>
19500
19501         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
19502
19503 2003-08-11  Bruno Haible  <bruno@clisp.org>
19504
19505         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
19506         (vasnprintf): Use it instead of wcslen.
19507
19508 2003-08-11  Bruno Haible  <bruno@clisp.org>
19509
19510         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
19511         value to ensure that _Bool promotes to int. Use #define for _Bool when
19512         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
19513
19514 2003-08-10  Karl Berry  <karl@gnu.org>
19515
19516         * lib/regex.h: update from libc (whitespace fix).
19517
19518 2003-08-09  Paul Eggert  <eggert@twinsun.com>
19519
19520         Merge some files from coreutils.  These changes were
19521         originally made by Jim Meyering.
19522         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
19523         many older Unixes require this.
19524         * lib/alloca.c (alloca): Remove cast to argument of free;
19525         no longer needed in C89.
19526         * lib/alloca_.h, regex.h: Fix white space to match
19527         what GNU indent does.
19528
19529 2003-08-09  Paul Eggert  <eggert@twinsun.com>
19530
19531         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
19532         apparently Emacs's Unicode mode got confused before my 2003-08-05
19533         checkin.
19534
19535 2003-08-08  Paul Eggert  <eggert@twinsun.com>
19536
19537         * m4/extensions.m4: New file.
19538         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
19539         Require gl_USE_SYSTEM_EXTENSIONS.
19540         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
19541         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
19542
19543 2003-08-08  Paul Eggert  <eggert@twinsun.com>
19544
19545         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
19546         * modules/extensions, modules/gnu-source: New files.
19547         * modules/timespec, modules/unlocked-io: Depend on extensions.
19548
19549 2003-08-07  Paul Eggert  <eggert@twinsun.com>
19550
19551         * modules/restrict: New file.
19552         * MODULES.html.sh (func_all_modules): Add restrict.
19553         * modules/regex: Depend on restrict.
19554
19555 2003-08-07  Paul Eggert  <eggert@twinsun.com>
19556
19557         * m4/restrict.m4: New file.
19558         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
19559
19560 2003-08-07  Bruno Haible  <bruno@clisp.org>
19561
19562         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
19563         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
19564
19565 2003-08-07  Bruno Haible  <bruno@clisp.org>
19566
19567         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
19568         makes the module 'getndelim2' compatible with the module 'getline'.
19569
19570 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19571
19572         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
19573         byte with "\201" to avoid glitches when editing that source file
19574         with multi-gnome-terminal.
19575
19576 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19577
19578         * lib/bumpalloc.h: Remove.
19579
19580 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19581
19582         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
19583         * modules/bumpalloc: Remove.
19584
19585 2003-08-04  Paul Eggert  <eggert@twinsun.com>
19586
19587         * lib/getloadavg.c: Change copyright notice and spacing to conform to
19588         GNU coding style.
19589
19590         Merge from coreutils.
19591         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
19592         1. From glibc.
19593         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
19594         from Karl Berry, implemented by Jim Meyering.
19595         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
19596         from Dmitry V. Levin.
19597         Remove anachronistic cast of xrealloc.
19598         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
19599         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
19600         type. Otherwise, it wouldn't compile with at least /bin/cc on
19601         ymp-cray-unicos9.0.2.X.
19602         Combine two mostly-identical uses of alloca into one.
19603         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
19604
19605 2003-08-04  Dave Love  <d.love@dl.ac.uk>
19606
19607         [From Emacs.]
19608
19609         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
19610         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
19611         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
19612         obsolete NLIST_NAME_UNION.
19613         [__GNU__]: Undef BSD and FSCALE.
19614         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
19615
19616 2003-08-03  Paul Eggert  <eggert@twinsun.com>
19617
19618         * lib/stdbool_.h (_Bool): Make it signed char, instead of
19619         an enum type, so that it's guaranteed to promote to int.  See:
19620         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
19621
19622 2003-08-03  Karl Berry  <karl@gnu.org>
19623
19624         * config/depcomp: update from automake.
19625
19626 2003-07-31  Paul Eggert  <eggert@twinsun.com>
19627
19628         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
19629         (strerror): Don't assume that a printable int fits in 14 bytes.
19630
19631 2003-07-31  Bruno Haible  <bruno@clisp.org>
19632
19633         * modules/getpass-gnu: New file.
19634         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
19635
19636 2003-07-31  Bruno Haible  <bruno@clisp.org>
19637
19638         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
19639
19640 2003-07-24  Karl Berry  <karl@gnu.org>
19641
19642         * config/missing: update from automake.
19643
19644 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
19645             Bruno Haible  <bruno@clisp.org>
19646
19647         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
19648         * lib/getline.c (getline, getdelim): Likewise.
19649         Remove _GNU_SOURCE define; now it's defined in config.h through
19650         m4/getline.m4.
19651
19652 2003-07-23  Karl Berry  <karl@gnu.org>
19653
19654         * config/config.sub: update from prep.
19655
19656 2003-07-22  Paul Eggert  <eggert@twinsun.com>
19657
19658         * modules/xalloc (Depends-on): Add exitfail.
19659         * modules/xmemcoll: Likewise.
19660
19661 2003-07-22  Paul Eggert  <eggert@twinsun.com>
19662
19663         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
19664         over-parenthesization in macros.
19665
19666         Sync with coreutils.
19667
19668         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
19669         required by C99.
19670
19671         Use `exit_failure' for xalloc and xmemcoll instead of their own
19672         private exit-failure variables.
19673         * lib/xalloc.h (xalloc_exit_failure): Remove.
19674         * lib/xmalloc.c: Likewise.  Include exitfail.h.
19675         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
19676         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
19677         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
19678         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
19679
19680 2003-07-20  Jim Meyering  <jim@meyering.net>
19681
19682         * modules/closeout (Depends-on): Add exitfail.
19683         Suggestion from Bruno Haible.
19684
19685 2003-07-19  Karl Berry  <karl@gnu.org>
19686
19687         * config/config.sub: update from prep.
19688
19689 2003-07-18  Paul Eggert  <eggert@twinsun.com>
19690
19691         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
19692         Remove.
19693         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
19694         to test that it can stand by itself.  Include "exitfail.h".
19695         Clients should set exit_failure instead.
19696         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
19697
19698 2003-07-18  Bruno Haible  <bruno@clisp.org>
19699
19700         * modules/getndelim2: New file.
19701         * modules/getline: Share files with module getndelim2.
19702         * modules/getnline: Depend on getndelim2 instead of sharing files with
19703         it. Add getnline.c to lib_SOURCES.
19704         * MODULES.html.sh (func_all_modules): Add getndelim2.
19705
19706 2003-07-18  Bruno Haible  <bruno@clisp.org>
19707
19708         * m4/getndelim2.m4: New file.
19709         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
19710         invoke gl_PREREQ_GETNDELIM2.
19711         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
19712         gl_PREREQ_GETNDELIM2.
19713         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
19714         gl_GETNDELIM2.
19715
19716 2003-07-18  Bruno Haible  <bruno@clisp.org>
19717
19718         * lib/getndelim2.h: New file.
19719         * lib/getndelim2.c: Make into a module of its own. Include config.h,
19720         getndelim2.h.
19721         (getndelim2): Make non-static. Change return type to ssize_t.
19722         * lib/getline.h: Change argument names.
19723         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
19724         * lib/getnline.c: Include getndelim2.h.
19725
19726 2003-07-18  Andreas Schwab  <schwab@suse.de>
19727
19728         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
19729
19730 2003-07-17  Karl Berry  <karl@gnu.org>
19731
19732         * config/config.sub: update from prep.
19733
19734 2003-07-17  Bruno Haible  <bruno@clisp.org>
19735
19736         * modules/getnline: New file.
19737         * modules/getline: Add lib/getndelim2.c to source file list.
19738         * MODULES.html.sh (func_all_modules): Add getnline.
19739
19740 2003-07-17  Bruno Haible  <bruno@clisp.org>
19741
19742         * m4/getnline.m4: New file.
19743
19744 2003-07-17  Bruno Haible  <bruno@clisp.org>
19745
19746         * m4/Makefile.am.in: Remove file.
19747         * m4/Makefile.am: Remove file.
19748         * m4/Makefile.in: Remove file.
19749
19750 2003-07-17  Bruno Haible  <bruno@clisp.org>
19751
19752         * lib/getnline.h: New file.
19753         * lib/getnline.c: New file.
19754         * lib/getndelim2.c: New file, extracted from getline.c.
19755         (getndelim2): Renamed from getdelim2, with added nmax argument.
19756         * lib/getline.c: Include getndelim2.c.
19757         (getdelim2): Moved out to getndelim2.c.
19758         (getline, getdelim): Update.
19759
19760 2003-07-17  Bruno Haible  <bruno@clisp.org>
19761
19762         * lib/Makefile.am: Remove file.
19763         * lib/Makefile.in: Remove file.
19764
19765 2003-07-17  Bruno Haible  <bruno@clisp.org>
19766
19767         * configure.in: Remove file.
19768         * Makefile.in: Remove file.
19769
19770 2003-07-17  Bruno Haible  <bruno@clisp.org>
19771
19772         * MODULES.html.sh: Put the </BODY> right before </HTML>.
19773
19774 2003-07-16  Karl Berry  <karl@gnu.org>
19775
19776         * config/srclist-update: was running fixlicense twice, which caused
19777                 texinfo.tex to be nullified for some reason.  Simplify,
19778                 $gplsrc is no longer needed as far as I can see?
19779
19780 2003-07-16  Jim Meyering  <jim@meyering.net>
19781
19782         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
19783
19784 2003-07-15  Paul Eggert  <eggert@twinsun.com>
19785
19786         * config/srclist.txt: Get the following files from gettext-runtime/intl
19787         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
19788         ref-del.sin.  From Bruno Haible.
19789         * config/srclist-update (fixfile): Change grep pattern again, since the
19790         previous fix didn't work (there was another trailing $).  Use
19791         '[$]' to escape the $s.
19792
19793 2003-07-15  Karl Berry  <karl@gnu.org>
19794
19795         * lib/vasnprintf.c: update from gettext.
19796
19797 2003-07-15  Karl Berry  <karl@gnu.org>
19798
19799         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
19800         gets expanded when surrounded by '$'.
19801
19802 2003-07-15  Jim Meyering  <jim@meyering.net>
19803
19804         * modules/save-cwd: Don't depend on error.  From Derek Price.
19805
19806 2003-07-15  Jim Meyering  <jim@meyering.net>
19807
19808         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
19809
19810 2003-07-14  Simon Josefsson  <jas@extundo.com>
19811
19812         * modules/mempcpy: New file.
19813         * MODULES.html.sh (func_all_modules): Add mempcpy.
19814
19815 2003-07-14  Simon Josefsson  <jas@extundo.com>
19816
19817         * m4/mempcpy.m4: New file.
19818
19819 2003-07-14  Simon Josefsson  <jas@extundo.com>
19820
19821         * lib/mempcpy.h: New file.
19822         * lib/mempcpy.c: New file.
19823
19824 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19825
19826         * modules/getdate, modules/posixtm: Depend on mktime.
19827
19828 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19829
19830         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
19831         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
19832         unicodeio.c, unicodeio.h, unlocked-io.h:
19833         Switch from LGPL to GPL.
19834
19835 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19836
19837         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
19838         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
19839         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
19840         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
19841         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
19842         updated automatically by ../config/srclist-update.  This changes
19843         their license from LPGL to GPL.
19844
19845 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19846
19847         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
19848         assumed to refer to the root of the most recent stable gettext version.
19849         * config/srclistvars.sh: Add defaults for eggert.
19850         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
19851         Match "This program" as well as "The program".  This is needed
19852         for gettext.
19853
19854 2003-07-14  Jim Meyering  <jim@meyering.net>
19855
19856         Don't emit diagnostics.  Let callers do that.
19857         * lib/save-cwd.c: Don't include "error.h".
19858         (save_cwd): Don't call error.  Ensure that errno is valid
19859         when returning nonzero.
19860
19861         * lib/save-cwd.h (restore_cwd): Update prototype.
19862         * lib/save-cwd.c (restore_cwd): Remove two parameters.
19863         Simplify.  Don't call error upon failure.  Let callers do that.
19864         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
19865         when auditing is enabled.  But don't bother updating the #if.
19866
19867 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
19868
19869         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
19870         it breaks C++ compilation.
19871         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
19872
19873 2003-07-10  Simon Josefsson  <jas@extundo.com>
19874
19875         * modules/strchrnul (Makefile.am): Add strchrnul.h.
19876
19877 2003-07-10  Jim Meyering  <jim@meyering.net>
19878
19879         * m4/clock_time.m4: Remove trailing blank.
19880         * m4/intmax_t.m4: Likewise.
19881
19882 2003-07-10  Jim Meyering  <jim@meyering.net>
19883
19884         * lib/vasnprintf.c: Remove trailing blanks.
19885         Make cpp indentation consistent.
19886
19887 2003-07-09  Paul Eggert  <eggert@twinsun.com>
19888
19889         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
19890         posixver.c, strftime.c, strnlen.c, strverscmp.c:
19891         Switch from LGPL to GPL.
19892
19893 2003-07-09  Paul Eggert  <eggert@twinsun.com>
19894
19895         * config/srclist.txt: Sort sublists.  Add
19896         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
19897         that differ from gnulib for one reason or another; we'd like this list
19898         to be smaller but for now let's document what we have.
19899
19900 2003-07-08  Paul Eggert  <eggert@twinsun.com>
19901
19902         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
19903         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
19904         and sweeter "eval x=$x".
19905         * config/srclist.txt: Get lib/argp* from glibc.
19906
19907 2003-07-07  Paul Eggert  <eggert@twinsun.com>
19908
19909         * lib/mktime.c: Fix some boundary cases and remove need for floating
19910         point.
19911
19912         Issue a compile-time diagnostic if time_t is floating point, or if
19913         two's complement arithmetic is not in effect, or if arithmetic
19914         right shift does not propagate the sign.  These assumptions were
19915         all in the original code but they weren't checked.
19916
19917         (TIME_T_MIDPOINT, verify): New macros.
19918         (__isleap): Remove; it has integer overflow problems.
19919         (leapyear): New function, without those problems.
19920         (ydhms_tm_diff): Remove; splitting into two parts.
19921         (ydhms_diff): New function, containing the arithmetic part of
19922         the old ydhms_tm_diff function.  Issue a compile-time
19923         diagnostic if we are not using C99 integer division.
19924         Avoid casts when possible.
19925         (guess_time_tm): New function, containing the checking part of
19926         the old ydhms_tm_diff function.  Return the new value, rather than
19927         the difference between it and the old.  Accept a new argument T
19928         so that *T specifies the old value.  Check for overflow in the result.
19929
19930         (__mktime_internal): Use a time_t offset, not a long int offset.
19931         This undoes the 2003-06-04 change, which is no longer needed now
19932         that we have better overflow checking.
19933         (localtime_offset): Likewise.
19934
19935         (__mktime_internal): Avoid harmful overflow on hosts where time_t
19936         and long are 64-bit but int is only 32-bit.
19937         (ydhms_diff): Use long int to store year1 and yday1.
19938         Issue a compile-time diagnostic if long int is not wide enough.
19939
19940         (__mktime_internal): Use long int to store adjusted year and yday.
19941         Use plain C rather than preprocessor commands, if that doesn't
19942         affect efficiency.
19943         Check for overflow (and try to repair) after each probe
19944         rather than checking only at the very end.  This avoids some bugs
19945         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
19946         does not equal GMT offset at maximum time).
19947         Use integer to check for overflow rather than floating point; this
19948         is more portable to non-IEEE hosts, and is a tad faster.
19949         When we detect that we are oscillating between two values,
19950         don't check whether tm_isdst has the requested value, since
19951         we already know the answer.  When tm_isdst has the wrong value,
19952         use a different heuristic to find the right one, based on the
19953         extreme values actually observed in practice in tz2003a,
19954         rather than the (overly optimistic) "previous 3 calendar quarters".
19955
19956         (not_equal_tm, print_tm, check_result): Use "const T" rather than
19957         "T const" to accommodate glibc style.
19958         (check_result): Use less-confusing report format.  "long" -> "long int.
19959         (main): Likewise.
19960         Don't loop if the iteration overflows time_t.
19961         Allow a negative step in the iteration.
19962
19963 2003-07-06  Karl Berry  <karl@gnu.org>
19964
19965         * config/depcomp: update from automake.
19966         * config/config.sub: update from prep.
19967
19968 2003-07-03  Karl Berry  <karl@gnu.org>
19969
19970         * config/config.guess: update from prep.
19971
19972 2003-07-01  Paul Eggert  <eggert@twinsun.com>
19973
19974         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
19975         xreadlink.c now includes it unconditionally.
19976
19977 2003-07-01  Paul Eggert  <eggert@twinsun.com>
19978
19979         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
19980         having it depend on HAVE_SYS_TYPES_H.
19981
19982 2003-07-01  Bruno Haible  <bruno@clisp.org>
19983
19984         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
19985         <sys/types.h> should be sufficient.
19986         Reported by Paul Eggert.
19987
19988 2003-06-26  Karl Berry  <karl@gnu.org>
19989
19990         * config/depcomp: update from automake.
19991
19992 2003-06-26  Bruno Haible  <bruno@clisp.org>
19993
19994         * modules/human: Depend on module stdbool.
19995
19996 2003-06-25  Bruno Haible  <bruno@clisp.org>
19997
19998         * modules/readlink: New file.
19999         * modules/xreadlink: Depend on it.
20000         * MODULES.html.sh (func_all_modules): Add readlink.
20001
20002 2003-06-25  Bruno Haible  <bruno@clisp.org>
20003
20004         * m4/readlink.m4: New file.
20005
20006 2003-06-25  Bruno Haible  <bruno@clisp.org>
20007
20008         * lib/readlink.c: New file.
20009
20010 2003-06-22  Karl Berry  <karl@gnu.org>
20011
20012         * config/srclist.txt: update mkinstalldirs from automake.
20013         * config/mkinstalldirs: update.
20014
20015 2003-06-22  Bruno Haible  <bruno@clisp.org>
20016
20017         Portability to mingw32.
20018         * m4/ssize_t.m4: New file, from GNU gettext.
20019         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
20020         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
20021
20022 2003-06-22  Bruno Haible  <bruno@clisp.org>
20023
20024         * modules/safe-read: Add m4/ssize_t.m4.
20025         * modules/xreadlink: Add m4/ssize_t.m4.
20026
20027 2003-06-20  Bruno Haible  <bruno@clisp.org>
20028
20029         Assume C89, so PARAMS isn't needed.
20030         * lib/unicodeio.h (PARAMS): Remove.
20031         * lib/unicodeio.c: Don't use PARAMS.
20032
20033 2003-06-18  Karl Berry  <karl@gnu.org>
20034
20035         * config/config.{guess,sub}: update from prep.
20036
20037 2003-06-18  Jim Meyering  <jim@meyering.net>
20038
20039         Merge changes from coreutils.
20040         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
20041         Remove explicit declarations of xmalloc and realloc.
20042         Include xalloc.h.
20043         (read_utmp): Remove anachronistic cast of xmalloc.
20044
20045 2003-06-17  Paul Eggert  <eggert@twinsun.com>
20046
20047         Assume C89, so PARAMS isn't needed.
20048         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
20049         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
20050         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
20051         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
20052         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
20053         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
20054         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
20055         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
20056         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
20057         lib/xstrtod.h, lib/xstrtol.h: Likewise.
20058         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
20059         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
20060         no longer needed. Anyway, config.h should always be included before any
20061         other file.
20062
20063 2003-06-11  Simon Josefsson  <jas@extundo.com>
20064
20065         * modules/sysexits: New file.
20066         * MODULES.html.sh (func_all_modules): Add sysexits.
20067
20068 2003-06-11  Simon Josefsson  <jas@extundo.com>
20069
20070         * lib/sysexit_.h: New file.
20071
20072 2003-06-11  Derek Price  <derek@ximbiot.com>
20073
20074         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
20075         necessary.
20076
20077 2003-06-11  Bruno Haible  <bruno@clisp.org>
20078
20079         * m4/sysexits.m4: New file.
20080
20081 2003-06-10  Simon Josefsson  <jas@extundo.com>
20082
20083         * lib/argp.h: New file, from glibc.
20084         * lib/argp-ba.c: New file, from glibc.
20085         * lib/argp-eexst.c: New file, from glibc.
20086         * lib/argp-fmtstream.c: New file, from glibc.
20087         * lib/argp-fmtstream.h: New file, from glibc.
20088         * lib/argp-fs-xinl.c: New file, from glibc.
20089         * lib/argp-help.c: New file, from glibc.
20090         * lib/argp-namefrob.h: New file, from glibc.
20091         * lib/argp-parse.c: New file, from glibc.
20092         * lib/argp-pv.c: New file, from glibc.
20093         * lib/argp-pvh.c: New file, from glibc.
20094         * lib/argp-xinl.c: New file, from glibc.
20095
20096 2003-06-10  Simon Josefsson  <jas@extundo.com>
20097
20098         * modules/strchrnul: New file.
20099
20100 2003-06-10  Simon Josefsson  <jas@extundo.com>
20101
20102         * modules/argp: New file.
20103
20104 2003-06-10  Simon Josefsson  <jas@extundo.com>
20105
20106         * m4/strchrnul.m4: New file.
20107
20108 2003-06-10  Simon Josefsson  <jas@extundo.com>
20109
20110         * lib/strchrnul.h: New file.
20111         * lib/strchrnul.c: New file.
20112
20113 2003-06-10  Bruno Haible  <bruno@clisp.org>
20114
20115         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
20116
20117 2003-06-07  Karl Berry  <karl@gnu.org>
20118
20119         * config/config.{guess,sub}: update from prep.
20120
20121 2003-06-07  Jim Meyering  <jim@meyering.net>
20122
20123         * modules/strtod: Use $(...) notation, not @...@ for
20124         AC_REPLACE'd variables.
20125         * modules/localcharset: Likewise.
20126
20127 2003-06-07  Jim Meyering  <jim@meyering.net>
20128
20129         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
20130         in place of my name in the copyright comment.
20131         Remove definition and uses of __P.
20132
20133         From coreutils.
20134         * lib/stat.c: Don't declare xmalloc explicitly.
20135         Instead, include "xalloc.h".
20136         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
20137         xrealloc, and xcalloc return values.
20138         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
20139         Improve comment.
20140         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
20141
20142 2003-06-07  Bruno Haible  <bruno@clisp.org>
20143
20144         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
20145         avoid AC_CONFIG_LINKS.
20146         * modules/fnmatch (Makefile.am): Use explicit creation rule for
20147         fnmatch.h, to avoid AC_CONFIG_LINKS.
20148         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
20149
20150 2003-06-07  Bruno Haible  <bruno@clisp.org>
20151
20152         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
20153         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
20154         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
20155         directory.
20156         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
20157         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
20158         directory.
20159
20160 2003-06-06  Jim Meyering  <jim@meyering.net>
20161
20162         Merge from coreutils.
20163         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
20164         Consolidate declarations and initializations of *_base* locals.
20165
20166         Merge from coreutils.
20167         This avoids a core dump on systems without GNU putenv,
20168         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
20169         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
20170         (unsetenv): New static function, from GNU libc.
20171         (rpl_putenv): Use it.
20172
20173         * lib/modechange.c: Remove trailing blanks.
20174
20175         Merge from coreutils.
20176         * lib/fsusage.c: Remove declaration of statfs.
20177         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
20178
20179         * lib/posixtm.c: Include <stdbool.h> unconditionally.
20180
20181 2003-06-06  Jim Meyering  <jim@meyering.net>
20182
20183         * lib/stdbool_.h: Renamed from stdbool.h.in.
20184
20185 2003-06-06  Jim Meyering  <jim@meyering.net>
20186             Bruno Haible  <bruno@clisp.org>
20187
20188         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
20189         Adjust Makefile.am snippet not to redirect directly to target.
20190         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
20191
20192 2003-06-05  Paul Eggert  <eggert@twinsun.com>
20193
20194         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
20195         mismatch, look in future quarters as well as past.  This fixes a
20196         bug when processing fall-backwards gaps immediately after a long
20197         period of daylight-saving time.
20198
20199         * lib/mktime.c: Assume freestanding C89 or better.
20200         (HAVE_LIMITS_H): Remove.  Assume it's 1.
20201         (__P): Remove; not used.
20202         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
20203         (mktime, not_equal_tm, print_tm, check_result,
20204         main): Use prototypes.  Use const * where appropriate.
20205         (main): Fix typo in testing code that uncovered by above changes.
20206         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
20207
20208 2003-06-04  Paul Eggert  <eggert@twinsun.com>
20209
20210         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
20211         locale.h, localeconv.  This merges changes from coreutils.
20212
20213         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
20214         It can be removed after the next Autoconf is released.
20215         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
20216         needed.
20217
20218 2003-06-04  Paul Eggert  <eggert@twinsun.com>
20219
20220         * lib/mktime.c: Fix Debian bug 177940
20221         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
20222         (localtime_offset): Now long int, not time_t, because we want it
20223         to be guaranteed to be signed.  All uses changed.
20224         (__mktime_internal): If overflow would occur when adding offset,
20225         don't add it.
20226
20227         Merge 'human' changes from coreutils.  Rewrite to support
20228         locale-specific notations like thousands separators.
20229         * lib/human.c: Simplify authorship notice.
20230         Include human.h immediately after config.h.
20231         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
20232         <limits.h>: Do not include, since human.h does.
20233         (SIZE_MAX, UINTMAX_MAX): New macros.
20234         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
20235         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
20236         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
20237         (power_letter): Renamed from suffixes.
20238         (generate_suffix_backwards): Remove.
20239         (adjust_value): Now takes int style (because of human.h changes)
20240         and long double value (for greater precision on some platforms).
20241         (group_number): New function.
20242         (human_readable): Use it.  Use integer options, not enum.
20243         Put the options before the sizes in the arg list.
20244         Support all the new options.
20245         The old human_readable function has been removed;
20246         use inttostr.h instead.
20247         (human_readable, default_block_size, humblock):
20248         Use uintmax_t, not int, for block sizes.
20249         (human_readable_inexact, block_size_types): Remove.
20250         (block_size_opts): New constant.
20251         (human_options): Renamed from human_block_size, with new signature
20252         that allows block sizes up to UINTMAX_MAX.  All callers changed.
20253         * lib/human.h: Add copyright and authorship notice.
20254         Include <limits.h> and <stdbool.h> unconditionally.
20255         (PARAMS): Remove.  All uses removed.
20256         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
20257         (enum human_inexact_style): Remove tag; now a nameless enum.
20258         (human_floor, human_ceiling, human_round_to_even): Now have
20259         values 2, 0, 1 rather than -1, 1, 0.
20260         (human_group_digits, human_suppress_point_zero, human_autoscale,
20261         human_base_1024, human_SI, human_B): New constants.
20262         (human_readable_inexact, human_block_size): Remove.
20263         (human_readable): Size args are now uintmax_t, not int.
20264         (human_options): New decl.
20265
20266         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
20267         unnecessary now that we assume C89 or better.  This change
20268         imported from coreutils.
20269
20270         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
20271         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
20272         in the 2003-05-30 sync from glibc.
20273
20274         .h files should stand alone, but we shouldn't include <sys/types.h>
20275         if we can get away with just <stddef.h>.
20276
20277         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
20278         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
20279         rather than <sys/types.h>, as we merely need size_t.
20280         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
20281         to get size_t.
20282         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
20283         Include <stdio.h>, to get FILE.
20284         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
20285         memcasecmp.h has included <stddef.h> and all we need is size_t.
20286         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
20287         our interface, instead of including <sys/types.h>
20288
20289 2003-06-04  Paul Eggert  <eggert@twinsun.com>
20290
20291         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
20292         now, as glibc mktime is buggy on non-glibc systems.
20293
20294 2003-06-03  Karl Berry  <karl@gnu.org>
20295
20296         * config/config.sub: update from prep.
20297
20298 2003-06-02  Paul Eggert  <eggert@twinsun.com>
20299
20300         [from coreutils]
20301         Fix some minor time-related bugs with POSIX time arguments.
20302         Some valid time stamps were being rejected (notably -1, and
20303         time stamps before 1900 on 64-bit hosts).  And some invalid
20304         time stamps were being accepted, e.g. September 31.
20305
20306         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
20307         that we can return (time_t) -1 successfully.
20308         * lib/posixtm.c: Likewise.
20309         [HAVE_STDBOOL_H]: Include <stdbool.h>.
20310         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
20311         (t): Remove static var.
20312         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
20313         of static var.  All uses changed.
20314         (year): Do not reject years before 1900; they can occur with
20315         64-bit time_t.
20316         (posix_time_parse): Do not check for out-of-range components;
20317         that is now the caller's responsibility, since our checks were
20318         only approximations.
20319         (posixtime): Use mktime to check for out-of-range components,
20320         since it knows them exactly.
20321         If mktime returns (time_t) -1, check whether an error actually occurred
20322         by invoking localtime on -1.
20323         (main) [TEST_POSIXTIME]: Check for input data errors, and report
20324         posixtime failures better.
20325         Improve the test data (in comments only).
20326
20327 2003-06-02  Karl Berry  <karl@gnu.org>
20328
20329         * config/mkinstalldirs (version): new variable.
20330         (--version): new option.
20331         (usage): improve message.
20332
20333 2003-05-30  Karl Berry  <karl@gnu.org>
20334
20335         * lib/mktime.c: update from libc.
20336
20337 2003-05-30  Bruno Haible  <bruno@clisp.org>
20338
20339         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
20340         * config/config.rpath: Upgrade to gettext-0.12.1.
20341
20342 2003-05-30  Bruno Haible  <bruno@clisp.org>
20343
20344         * m4/gettext.m4: Upgrade to gettext-0.12.1.
20345         * m4/nls.m4: New file, from gettext-0.12.1.
20346         * m4/po.m4: New file, from gettext-0.12.1.
20347         * m4/progtest.m4: Upgrade to gettext-0.12.1.
20348
20349 2003-05-30  Bruno Haible  <bruno@clisp.org>
20350
20351         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
20352         * lib/localcharset.h: Likewise.
20353         * lib/localcharset.c: Likewise.
20354
20355 2003-05-29  Karl Berry  <karl@gnu.org>
20356
20357         * config/config.rpath: update from gettext.
20358
20359 2003-05-28  Paul Eggert  <eggert@twinsun.com>
20360
20361         Assume the headers required for C89 freestanding compilers.
20362         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
20363         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
20364         * m4/human.m4 (gl_HUMAN): Likewise.
20365         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
20366         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
20367         * m4/userspec.m4 (gl_USERSPEC): Likewise.
20368         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
20369         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
20370         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
20371
20372 2003-05-28  Paul Eggert  <eggert@twinsun.com>
20373
20374         Assume the headers required for C89 freestanding compilers.
20375         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
20376         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
20377         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
20378         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
20379         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
20380         define, since <limits.h> is guaranteed to do that.
20381         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
20382         * lib/exclude.c: Include <stdbool.h> unconditionally.
20383         * lib/tempname.c: Include <stddef.h> unconditionally.
20384         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
20385         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
20386         <stddef.h> does that.
20387         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
20388         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
20389         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
20390         needed.
20391         * lib/xstrtol.c: Likewise.
20392         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
20393         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
20394
20395         * lib/addext.c (addext): Use assignment rather than cast, to avoid
20396         warnings on some platforms.
20397
20398         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
20399         arbitrarily.
20400
20401 2003-05-26  Jim Meyering  <jim@meyering.net>
20402
20403         Merge in a change from coreutils:
20404         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
20405         that is guaranteed to be `no'.  Use `no_such_member' to indicate
20406         that condition, rather than `-1' which is slightly misleading.
20407         Change the name of the cache variable to have the gl_ prefix.
20408         Prompted by a patch from Richard Dawe for DJGPP.
20409
20410 2003-05-24  Karl Berry  <karl@gnu.org>
20411
20412         * config/config.guess: update from prep.
20413
20414 2003-05-22  Karl Berry  <karl@gnu.org>
20415
20416         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
20417
20418 2003-05-20  Karl Berry  <karl@gnu.org>
20419
20420         * config/config.guess: update from prep.
20421
20422 2003-05-18  Karl Berry  <karl@gnu.org>
20423
20424         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
20425         might actually be set by the user.
20426
20427         * config/depcomp, install-sh, mdate-sh: update from automake.
20428
20429 2003-05-17  Bruno Haible  <bruno@clisp.org>
20430
20431         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
20432         invalid expansion for AC_EGREP_CPP.
20433         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
20434         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
20435         Suggested by Akim Demaille <akim@epita.fr> in
20436         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
20437
20438 2003-05-12  Jim Meyering  <jim@meyering.net>
20439
20440         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
20441         the space-padded-by-default conversion specifiers, %e, %k, %l.
20442
20443 2003-05-12  Bruno Haible  <bruno@clisp.org>
20444
20445         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
20446         the string is longer than 4 KB.
20447
20448 2003-05-11  Karl Berry  <karl@gnu.org>
20449
20450         * config/config.{guess,sub}: update from prep.
20451
20452 2003-05-09  Bruno Haible  <bruno@clisp.org>
20453
20454         * modules/error: Add m4/strerror_r.m4 to file list.
20455
20456 2003-05-03  Bruno Haible  <bruno@clisp.org>
20457
20458         Upgrade to Unicode-4.0.
20459         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
20460         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
20461         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
20462         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
20463         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
20464         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
20465         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
20466         Change width of U+E0100..U+E01EF from 1 to 0.
20467
20468 2003-04-25  Jim Meyering  <jim@meyering.net>
20469
20470         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
20471         of type size_t, not int.
20472
20473 2003-04-25  Bruno Haible  <bruno@clisp.org>
20474
20475         * lib/copy-file.c: Include <stddef.h>, for size_t.
20476
20477 2003-04-21  Paul Eggert  <eggert@twinsun.com>
20478
20479         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
20480         code which expansion is under static control.  Patch imported from
20481         Akim Demaille's patch to Bison; see
20482         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
20483
20484 2003-04-14  Bruno Haible  <bruno@clisp.org>
20485
20486         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
20487
20488 2003-04-11  Jim Meyering  <jim@meyering.net>
20489
20490         Merge changes from Coreutils.
20491
20492         2003-03-22  Jim Meyering  <jim@meyering.net>
20493
20494         * lib/strftime.c (widen): Cast alloca return value to proper type.
20495
20496         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
20497
20498         From GNU libc.
20499         * lib/strftime.c (my_strftime): Handle very large width
20500         specifications for numeric values correctly.  Improve checks for
20501         overflow.
20502
20503         2003-01-19  Jim Meyering  <jim@meyering.net>
20504
20505         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
20506         definitions.
20507         (nl_get_alt_digit) [! defined my_strftime]: Define.
20508         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
20509         _nl_get_alt_digit and _nl_get_walt_digit.
20510
20511         * lib/strftime.c (my_strftime): Merge in locale-related changes from
20512         libc. These changes have no effect outside of _LIBC.
20513
20514 2003-04-10  Bruno Haible  <bruno@clisp.org>
20515
20516         * modules/findprog: New file.
20517         * MODULES.html.sh (func_all_modules): Add it.
20518
20519 2003-04-10  Bruno Haible  <bruno@clisp.org>
20520
20521         * m4/findprog.m4: New file.
20522         * m4/eaccess.m4: New file.
20523
20524 2003-04-10  Bruno Haible  <bruno@clisp.org>
20525
20526         * lib/findprog.h: New file, from GNU gettext.
20527         * lib/findprog.c: New file, from GNU gettext.
20528
20529 2003-04-05  Jim Meyering  <jim@meyering.net>
20530
20531         Merge changes from Coreutils.
20532
20533         * lib/exclude.h (PARAMS): Remove definition and uses.
20534         * lib/exclude.c: Remove uses of `PARAMS'.
20535
20536         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
20537         Add test-cases for DOS filenames. Declare program_name.
20538         (main): Set up program_name.  Patch by Rich Dawe.
20539
20540         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
20541         error from mntctl.
20542         Use mntctl's return value to drive the entry-processing loop, since
20543         we can't rely on the value of the vmt_length member in the last
20544         entry.  On some systems doing so could result in exhausting
20545         virtual memory.  Based in part on a patch from Mike Jetzer.
20546
20547 2003-04-04  Bruno Haible  <bruno@clisp.org>
20548
20549         * modules/linebreak: New file.
20550         * MODULES.html.sh (func_all_modules): Add it.
20551
20552 2003-04-04  Bruno Haible  <bruno@clisp.org>
20553
20554         * m4/linebreak.m4: New file.
20555
20556 2003-04-04  Bruno Haible  <bruno@clisp.org>
20557
20558         * lib/linebreak.h: New file, from GNU gettext.
20559         * lib/linebreak.c: New file, from GNU gettext with slight
20560         modifications.
20561         * lib/lbrkprop.h: New file, from GNU gettext.
20562
20563 2003-04-03  Bruno Haible  <bruno@clisp.org>
20564
20565         * modules/utf8-ucs4: New file.
20566         * modules/utf16-ucs4: New file.
20567         * modules/ucs4-utf8: New file.
20568         * modules/ucs4-utf16: New file.
20569         * MODULES.html.sh (func_all_modules): Add them.
20570
20571 2003-04-03  Bruno Haible  <bruno@clisp.org>
20572
20573         * m4/utf-ucs4.m4: New file.
20574         * m4/ucs4-utf.m4: New file.
20575
20576 2003-04-03  Bruno Haible  <bruno@clisp.org>
20577
20578         * lib/utf8-ucs4.h: New file, from GNU gettext.
20579         * lib/utf16-ucs4.h: New file, from GNU gettext.
20580         * lib/ucs4-utf8.h: New file, from GNU gettext.
20581         * lib/ucs4-utf16.h: New file, from GNU gettext.
20582
20583 2003-04-02  Bruno Haible  <bruno@clisp.org>
20584
20585         * modules/binary-io: New file.
20586         * MODULES.html.sh (func_all_modules): Add it.
20587
20588 2003-04-02  Bruno Haible  <bruno@clisp.org>
20589
20590         * lib/binary-io.h: New file, from GNU gettext.
20591
20592 2003-04-01  Bruno Haible  <bruno@clisp.org>
20593
20594         * modules/pathname: New file.
20595         * MODULES.html.sh (func_all_modules): Add it.
20596
20597 2003-04-01  Bruno Haible  <bruno@clisp.org>
20598
20599         * lib/pathname.h: New file, from GNU gettext.
20600         * lib/concatpath.c: New file, from GNU gettext.
20601
20602 2003-03-30  Bruno Haible  <bruno@clisp.org>
20603
20604         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
20605
20606 2003-03-30  Bruno Haible  <bruno@clisp.org>
20607
20608         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
20609         function chown() doesn't exist.
20610
20611 2003-03-28  Bruno Haible  <bruno@clisp.org>
20612
20613         * modules/copy-file: New file.
20614         * MODULES.html.sh (func_all_modules): Add it.
20615
20616 2003-03-28  Bruno Haible  <bruno@clisp.org>
20617
20618         * m4/copy-file.m4: New file.
20619
20620 2003-03-28  Bruno Haible  <bruno@clisp.org>
20621
20622         * lib/copy-file.h: New file, from GNU gettext.
20623         * lib/copy-file.c: New file, from GNU gettext.
20624
20625 2003-03-18  Jim Meyering  <jim@meyering.net>
20626
20627         * lib/quote.c (quote_n): Fix typo in comment.
20628
20629 2003-03-18  Bruno Haible  <bruno@clisp.org>
20630
20631         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
20632         checking.
20633         * m4/onceonly_2_57.m4: Likewise.
20634
20635 2003-03-17  Bruno Haible  <bruno@clisp.org>
20636
20637         * m4/onceonly.m4: Require autoconf 2.54 or newer.
20638         (m4_quote): Remove macro.
20639         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
20640
20641 2003-03-14  Jim Meyering  <jim@meyering.net>
20642
20643         Merge changes from Coreutils.
20644         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
20645         to be const, in order to avoid warnings.
20646         (obstack_room): Likewise.
20647         (obstack_empty_p): Likewise.
20648
20649 2003-03-14  Bruno Haible  <bruno@clisp.org>
20650
20651         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
20652         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
20653
20654 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20655
20656         Merge changes from Bison.
20657         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
20658         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
20659         when compiling Bison 1.875's `bitset bset = obstack_alloc
20660         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
20661         * lib/hash.c: Include <stdbool.h> unconditionally.
20662
20663 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20664
20665         * m4/onceonly.m4 (m4_quote): New macro.
20666         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
20667         Quote AC_FOREACH variable-expansions properly.
20668
20669 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20670
20671         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
20672
20673 2003-03-09  Paul Eggert  <eggert@twinsun.com>
20674
20675         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
20676         Reported by Bruce Becker; see:
20677         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
20678
20679 2003-03-03  Paul Eggert  <eggert@twinsun.com>
20680             Bruno Haible  <bruno@clisp.org>
20681
20682         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
20683         Reported by John Hughes, see
20684         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
20685
20686 2003-02-20  Bruno Haible  <bruno@clisp.org>
20687
20688         * MODULES.html.sh (func_all_modules): Add poll.
20689
20690 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20691
20692         * modules/poll: New file.
20693
20694 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20695
20696         * lib/poll_.h: New file.
20697         * lib/poll.c: New file.
20698
20699 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20700
20701         * m4/poll.m4: New file.
20702
20703 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20704
20705         * modules/mathl: New file.
20706
20707 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20708
20709         * lib/mathl.h: New file.
20710         * lib/acosl.c: New file.
20711         * lib/asinl.c: New file.
20712         * lib/atanl.c: New file.
20713         * lib/ceill.c: New file.
20714         * lib/cosl.c: New file.
20715         * lib/expl.c: New file.
20716         * lib/floorl.c: New file.
20717         * lib/frexpl.c: New file.
20718         * lib/ldexpl.c: New file.
20719         * lib/logl.c: New file.
20720         * lib/sincosl.c: New file.
20721         * lib/sinl.c: New file.
20722         * lib/sqrtl.c: New file.
20723         * lib/tanl.c: New file.
20724         * lib/trigl.c: New file.
20725         * lib/trigl.h: New file.
20726
20727 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20728
20729         * m4/mathl.m4: New file.
20730
20731 2003-02-18  Bruno Haible  <bruno@clisp.org>
20732
20733         * MODULES.html.sh (func_all_modules): Add mathl.
20734
20735 2003-02-17  Bruno Haible  <bruno@clisp.org>
20736
20737         * modules/mkdtemp: New module.
20738         * MODULES.html.sh (func_all_modules): Add it.
20739
20740 2003-02-17  Bruno Haible  <bruno@clisp.org>
20741
20742         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
20743
20744 2003-02-17  Bruno Haible  <bruno@clisp.org>
20745
20746         * lib/mkdtemp.h: New file, from GNU gettext.
20747         * lib/mkdtemp.c: New file, from GNU gettext.
20748
20749 2003-02-02  Jim Meyering  <jim@meyering.net>
20750
20751         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
20752         e.g. glibc-2.2.93.
20753
20754 2003-01-31  Bruno Haible  <bruno@clisp.org>
20755
20756         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
20757         'rpl_rename'.
20758         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
20759         'rpl_strnlen'.
20760         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
20761         'rpl_strtod'.
20762         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
20763         'rpl_utime'.
20764
20765 2003-01-31  Bruno Haible  <bruno@clisp.org>
20766
20767         * lib/rename.c: #undef rename before defining rpl_rename.
20768         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
20769
20770 2003-01-30  Bruno Haible  <bruno@clisp.org>
20771
20772         * modules/vasnprintf, modules/vasprintf: New modules.
20773         * MODULES.html.sh (func_all_modules): Add them.
20774
20775 2003-01-30  Bruno Haible  <bruno@clisp.org>
20776
20777         * m4/signed.m4: New file, from GNU gettext.
20778         * m4/longdouble.m4: New file, from GNU gettext.
20779         * m4/wchar_t.m4: New file, from GNU gettext.
20780         * m4/wint_t.m4: New file, from GNU gettext.
20781         * m4/vasnprintf.m4: New file.
20782         * m4/vasprintf.m4: New file.
20783
20784 2003-01-30  Bruno Haible  <bruno@clisp.org>
20785
20786         * lib/printf-args.h: New file, from GNU gettext.
20787         * lib/printf-args.c: New file, from GNU gettext.
20788         * lib/printf-parse.h: New file, from GNU gettext.
20789         * lib/printf-parse.c: New file, from GNU gettext.
20790         * lib/vasnprintf.h: New file, from GNU gettext.
20791         * lib/vasnprintf.c: New file, from GNU gettext.
20792         * lib/asnprintf.c: New file, from GNU gettext.
20793         * lib/vasprintf.h: New file, from GNU gettext with modifications.
20794         * lib/vasprintf.c: New file, from GNU gettext.
20795         * lib/asprintf.c: New file, from GNU gettext.
20796
20797 2003-01-29  Bruno Haible  <bruno@clisp.org>
20798
20799         * modules/stpncpy: New module.
20800         * MODULES.html.sh (func_all_modules): Add it.
20801
20802 2003-01-29  Bruno Haible  <bruno@clisp.org>
20803
20804         * m4/stpncpy.m4: New file.
20805
20806 2003-01-29  Bruno Haible  <bruno@clisp.org>
20807
20808         * lib/stpncpy.h: New file, from GNU gettext with modifications.
20809         * lib/stpncpy.c: New file, from GNU gettext with modifications.
20810
20811 2003-01-28  Bruno Haible  <bruno@clisp.org>
20812
20813         * modules/c-ctype: New module.
20814         * MODULES.html.sh (func_all_modules): Add it.
20815
20816 2003-01-28  Bruno Haible  <bruno@clisp.org>
20817
20818         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
20819         Paul Eggert.
20820         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
20821         Paul Eggert.
20822
20823 2003-01-27  Bruno Haible  <bruno@clisp.org>
20824
20825         * modules/xsetenv: New module.
20826         * MODULES.html.sh (func_all_modules): Add it.
20827
20828 2003-01-27  Bruno Haible  <bruno@clisp.org>
20829
20830         * lib/xsetenv.h: New file, from GNU gettext.
20831         * lib/xsetenv.c: New file, from GNU gettext.
20832
20833 2003-01-23  Jim Meyering  <jim@meyering.net>
20834
20835         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
20836         from working on systems without dirfd (at least Irix and OSF1/Tru64).
20837
20838 2003-01-23  Bruno Haible  <bruno@clisp.org>
20839
20840         * modules/minmax: New module.
20841         * MODULES.html.sh (func_all_modules): Add it.
20842
20843 2003-01-23  Bruno Haible  <bruno@clisp.org>
20844
20845         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
20846         Eggert.
20847
20848 2003-01-22  Bruno Haible  <bruno@clisp.org>
20849
20850         * modules/exit: New module.
20851         * MODULES.html.sh (func_all_modules): Add it.
20852
20853 2003-01-22  Bruno Haible  <bruno@clisp.org>
20854
20855         * lib/exit.h: New file, from GNU gettext.
20856
20857 2003-01-19  Bruno Haible  <bruno@clisp.org>
20858
20859         * gnulib-tool: Recognize option --extract-maintainer.
20860         (func_get_maintainer): New function.
20861         * modules/*: Add Maintainer entry.
20862
20863 2003-01-16  Jim Meyering  <jim@meyering.net>
20864
20865         * m4/regex.m4: The `regex' struct is both input and output.
20866         Initialize it before each use.  Patch by Tim Waugh.
20867
20868 2003-01-16  Bruno Haible  <bruno@clisp.org>
20869
20870         * MODULES.html.sh: Add a table of contents. Add the module name as
20871         leftmost column. Add hyperlinks.
20872
20873 2003-01-15  Bruno Haible  <bruno@clisp.org>
20874
20875         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
20876
20877 2003-01-15  Bruno Haible  <bruno@clisp.org>
20878
20879         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
20880         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
20881         suffix.
20882
20883 2003-01-15  Bruno Haible  <bruno@clisp.org>
20884
20885         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
20886
20887 2003-01-15  Bruno Haible  <bruno@clisp.org>
20888
20889         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
20890         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
20891
20892 2003-01-14  Jim Meyering  <jim@meyering.net>
20893
20894         * lib/same.c (same_name): Tweak a comment.
20895
20896 2003-01-14  Bruno Haible  <bruno@clisp.org>
20897
20898         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
20899         when a string comparison is sufficient.
20900
20901 2003-01-14  Bruno Haible  <bruno@clisp.org>
20902
20903         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
20904         'unsigned int'.
20905
20906 2003-01-14  Bruno Haible  <bruno@clisp.org>
20907
20908         * lib/hash-pjw.c: Add comment about low quality of this function.
20909
20910 2003-01-13  Bruno Haible  <bruno@clisp.org>
20911
20912         * modules/stpcpy: Distribute lib/stpcpy.h.
20913         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
20914
20915 2003-01-13  Bruno Haible  <bruno@clisp.org>
20916
20917         * modules/*: Add a description.
20918         * modules/strpbrk: Fix Makefile.am snippet.
20919         * modules/strtoimax: Fix dependencies.
20920         * modules/strtoumax: Likewise.
20921
20922 2003-01-13  Bruno Haible  <bruno@clisp.org>
20923
20924         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
20925         * modules/alloca (Makefile.am): All object files depend on alloca.h.
20926         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
20927
20928 2003-01-13  Bruno Haible  <bruno@clisp.org>
20929
20930         * gnulib-tool (func_create_testdir): Store config/* files in the main
20931         directory.
20932         * config.rpath: Move to ...
20933         * config/config.rpath: ... here.
20934         * modules/gettext: Contains config/config.rpath, not config.rpath.
20935         * modules/iconv: Likewise.
20936
20937 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20938
20939         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20940         to avoid collisions with libcurses and libreadline.
20941
20942         * m4/getstr.m4: Remove.
20943         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
20944
20945 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20946
20947         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20948         to avoid collisions with libcurses and libreadline.
20949
20950         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
20951         * lib/getstr.h, getstr.c: Remove.
20952         * lib/getline.c: Include "getline.h", to check interface.
20953         Move body of old getstr.c here: this defines MIN_CHUNK and
20954         declares getdelim2, which is renamed from getstr.
20955         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
20956
20957         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
20958         All uses changed.
20959         * lib/linebuffer.h: Likewise.
20960         (readline): Remove backward-compatibility macro.
20961
20962 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20963
20964         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20965         to avoid collisions with libcurses and libreadline.
20966         * getstr: Remove.
20967         * MODULES.html.sh: Remove getstr.
20968         * modules/getline: Depend on unlocked-io, not getstr.
20969
20970 2003-01-12  Jim Meyering  <jim@meyering.net>
20971
20972         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
20973
20974 2003-01-10  Bruno Haible  <bruno@clisp.org>
20975
20976         * modules/alloca: Change Makefile.am requirements. Simplify Include
20977         requirements. Add lib/alloca_.h to file list.
20978
20979 2003-01-10  Bruno Haible  <bruno@clisp.org>
20980
20981         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
20982
20983 2003-01-10  Bruno Haible  <bruno@clisp.org>
20984
20985         * lib/alloca_.h: New file.
20986         * lib/getdate.y: Unconditionally include alloca.h.
20987         * lib/makepath.c: Likewise.
20988         * lib/setenv.c: Likewise.
20989         * lib/userspec.c: Likewise.
20990
20991 2003-01-09  Karl Berry  <karl@gnu.org>
20992
20993         * MODULES.html.sh: include `dirname $0` in PATH, to find
20994         gnulib-tool.
20995
20996 2003-01-09  Bruno Haible  <bruno@clisp.org>
20997
20998         * modules/stdbool: Change configure.ac, Makefile.am requirements.
20999         Simplify Include requirements. Add lib/stdbool.h.in to file list.
21000
21001 2003-01-09  Bruno Haible  <bruno@clisp.org>
21002
21003         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
21004
21005 2003-01-09  Bruno Haible  <bruno@clisp.org>
21006
21007         * lib/stdbool.h.in: New file.
21008
21009 2003-01-09  Bruno Haible  <bruno@clisp.org>
21010
21011         * gnulib-tool (func_all_modules): Ignore files ending in ~.
21012         * MODULES.html.sh: Likewise.
21013
21014 2003-01-08  Jim Meyering  <jim@meyering.net>
21015
21016         * lib/full-write.c: Undefine and define-away `const' after inclusion
21017         of errno.h, not before.  Suggestion from Bruno Haible.
21018
21019 2003-01-08  Bruno Haible  <bruno@clisp.org>
21020
21021         * modules/full-read: Depend on full-write.
21022
21023 2003-01-08  Bruno Haible  <bruno@clisp.org>
21024
21025         * lib/safe-read.c: Include specification header first, to ensure its
21026         selfcontainedness.
21027         * lib/full-write.c: Likewise.
21028
21029 2003-01-07  Jim Meyering  <jim@meyering.net>
21030
21031         * lib/full-write.c: Rework so that it may serve to define full_read,
21032         too.
21033         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
21034
21035 2003-01-07  Bruno Haible  <bruno@clisp.org>
21036
21037         * lib/strtoimax.c: Include <stdint.h> as an alternative to
21038         <inttypes.h>.
21039         * lib/xstrtol.h: Likewise.
21040         * lib/xstrtoimax.c: Likewise.
21041         * lib/xstrtoumax.c: Likewise.
21042         * lib/human.h: Likewise.
21043
21044         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
21045         on systems that have <inttypes.h> but not <stdint.h>.
21046
21047 2003-01-07  Bruno Haible  <bruno@clisp.org>
21048
21049         * MODULES.html.sh: Add copyright notice.
21050         (missed_files): Omit CVS directory entries.
21051         (func_module): Make it work with sed-3.02.
21052         * MODULES.txt: Remove file.
21053
21054 2003-01-06  Jim Meyering  <jim@meyering.net>
21055
21056         * lib/version-etc.c: Update year in translatable copyright string.
21057
21058 2003-01-03  Karl Berry  <karl@gnu.org>
21059
21060         * config/config.{guess,sub}: update from prep.
21061
21062 2003-01-02  Karl Berry  <karl@gnu.org>
21063
21064         * doc/COPYING.DOC: belatedly updated to 1.2.
21065
21066 2003-01-01  Karl Berry  <karl@gnu.org>
21067
21068         * gnulib-tool (func_verify_module): report module name $module in
21069         error message, not $1.
21070         * gnulib-tool (create-testdir): don't complain if destdir couldn't
21071         be created, only if it doesn't exist.
21072         * gnulib-tool (last_checkin_date): don't expand the $Date here.
21073
21074 2002-12-31  Paul Eggert  <eggert@twinsun.com>
21075
21076         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
21077
21078 2002-12-31  Paul Eggert  <eggert@twinsun.com>
21079
21080         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
21081         memcmp if strcoll doesn't work.
21082
21083 2002-12-31  Bruno Haible  <bruno@clisp.org>
21084
21085         * lib/utime.c (utime_null): No need to call ftruncate if the file was
21086         nonempty.
21087
21088 2002-12-31  Bruno Haible  <bruno@clisp.org>
21089
21090         * lib/memcoll.c (STRCOLL): New macro.
21091         (memcoll): Use it.
21092
21093 2002-12-31  Bruno Haible  <bruno@clisp.org>
21094
21095         * lib/localcharset.h: New file.
21096         * lib/localcharset.c: Include it.
21097         * lib/unicodeio.c: Likewise.
21098
21099 2002-12-31  Bruno Haible  <bruno@clisp.org>
21100
21101         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
21102         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
21103
21104 2002-12-31  Bruno Haible  <bruno@clisp.org>
21105
21106         * lib/getline.h: Include <stddef.h>, for size_t.
21107
21108         * lib/unicodeio.h: Include <stddef.h>, for size_t.
21109         * lib/unicodeio.c: Don't include <stddef.h>.
21110
21111 2002-12-31  Bruno Haible  <bruno@clisp.org>
21112
21113         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
21114         HAVE_TM_ZONE.
21115
21116 2002-12-24  Karl Berry  <karl@gnu.org>
21117
21118         * config/config.guess: update from prep.
21119
21120 2002-12-24  Bruno Haible  <bruno@clisp.org>
21121
21122         General infrasructure.
21123         * m4/README: Rewritten.
21124         * m4/onceonly.m4: New file.
21125         * m4/onceonly_2_57.m4: New file.
21126
21127         Module atexit.
21128         * m4/atexit.m4: New file.
21129
21130         Module strtod.
21131         * m4/strtod.m4: New file.
21132
21133         Module strtol.
21134         * m4/strtol.m4: New file.
21135
21136         Module strtoul.
21137         * m4/strtoul.m4: New file.
21138
21139         Module memchr.
21140         * m4/memchr.m4: New file.
21141
21142         Module memcmp.
21143         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
21144         (jm_FUNC_MEMCMP): Invoke it.
21145
21146         Module memcpy.
21147         * m4/memcpy.m4: New file.
21148
21149         Module memmove.
21150         * m4/memmove.m4: New file.
21151
21152         Module memset.
21153         * m4/memset.m4: New file.
21154
21155         Module strcspn.
21156         * m4/strcspn.m4: New file.
21157
21158         Module strpbrk.
21159         * m4/strpbrk.m4: New file.
21160
21161         Module strstr.
21162         * m4/strstr.m4: New file.
21163
21164         Module strerror.
21165         * m4/strerror.m4: New file.
21166
21167         Module mktime.
21168         * m4/mktime.m4: Renamed from jm-mktime.m4.
21169         (gl_PREREQ_MKTIME): New macro.
21170         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
21171
21172         Module malloc.
21173         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
21174         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
21175         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
21176
21177         Module realloc.
21178         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
21179         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
21180         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
21181
21182         Module strftime.
21183         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
21184         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
21185         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
21186         gl_TM_GMTOFF.
21187         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
21188
21189         Module xalloc.
21190         * m4/xalloc.m4: New file.
21191
21192         Module alloca.
21193         * m4/alloca.m4: New file.
21194
21195         Module putenv.
21196         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
21197         (jm_FUNC_PUTENV): Invoke it.
21198
21199         Module setenv.
21200         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
21201         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
21202         when invoked twice.
21203         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
21204         gt_FUNC_SETENV.
21205
21206         Module memrchr.
21207         * m4/memrchr.m4: New file.
21208
21209         Module stpcpy.
21210         * m4/stpcpy.m4: New file.
21211
21212         Module strcase.
21213         * m4/strcase.m4: New file.
21214
21215         Module strdup.
21216         * m4/strdup.m4: New file.
21217
21218         Module strnlen.
21219         * m4/strnlen.m4: New file.
21220
21221         Module strndup.
21222         * m4/strndup.m4: New file.
21223
21224         Module xstrtod.
21225         * m4/xstrtod.m4: New file.
21226
21227         Module xstrtol.
21228         * m4/xstrtol.m4: New file.
21229
21230         Module getdate.
21231         * m4/getdate.m4: New file.
21232
21233         Module unlocked-io.
21234         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
21235         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
21236         * m4/jm-glibc-io.m4n: Remove file.
21237
21238         Module long-options.
21239         * m4/long-options.m4: New file.
21240
21241         Module md5.
21242         * m4/md5.m4: New file.
21243
21244         Module sha.
21245         * m4/sha.m4: New file.
21246
21247         Module getstr.
21248         * m4/getstr.m4: New file.
21249
21250         Module getline.
21251         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
21252         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
21253         <sys/types.h>, for size_t. Use the function name gnu_getline, not
21254         simply getline. Infoke gl_PREREQ_GETLINE.
21255
21256         Module obstack.
21257         * m4/obstack.m4: New file.
21258
21259         Module hash.
21260         * m4/hash.m4: New file.
21261
21262         Module readtokens.
21263         * m4/readtokens.m4: New file.
21264
21265         Module strverscmp.
21266         * m4/strverscmp.m4: New file.
21267
21268         Module stdbool.
21269         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
21270         OSF/1.
21271
21272         Module strtoll.
21273         * m4/strtoll.m4: New file.
21274
21275         Module strtoull.
21276         * m4/strtoull.m4: New file.
21277
21278         Module strtoimax.
21279         * m4/strtoimax.m4: New file.
21280
21281         Module strtoumax.
21282         * m4/strtoumax.m4: New file.
21283
21284         Module xstrtoimax.
21285         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
21286         jm_AC_PREREQ_XSTRTOIMAX.
21287         Moved the strtol prerequisites to strtol.m4.
21288         Moved the strtoll prerequisites to strtoll.m4.
21289         Moved the strtoimax prerequisites to strtoimax.m4.
21290
21291         Module xstrtoumax.
21292         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
21293         jm_AC_PREREQ_XSTRTOUMAX.
21294         Moved the strtoul prerequisites to strtoul.m4.
21295         Moved the strtoull prerequisites to strtoull.m4.
21296         Moved the strtoumax prerequisites to strtoumax.m4.
21297
21298         Module chown.
21299         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
21300         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
21301
21302         Module dup2.
21303         * m4/dup2.m4: New file.
21304
21305         Module ftruncate.
21306         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
21307         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
21308
21309         Module getgroups.
21310         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
21311         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
21312
21313         Module gettimeofday.
21314         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
21315         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
21316         gl_PREREQ_GETTIMEOFDAY.
21317
21318         Module mkdir.
21319         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
21320         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
21321
21322         Module mkstemp.
21323         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
21324         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
21325         jm_AC_TYPE_UINTMAX_T.
21326         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
21327
21328         Module stat.
21329         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
21330         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
21331
21332         Module lstat.
21333         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
21334         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
21335
21336         Module timespec.
21337         * m4/timespec.m4 (gl_TIMESPEC): New macro.
21338         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
21339         * m4/st_mtim.m4: Indentation.
21340
21341         Module nanosleep.
21342         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
21343         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
21344         gl_PREREQ_NANOSLEEP.
21345
21346         Module regex.
21347         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
21348         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
21349         (gl_REGEX): New macro.
21350
21351         Module rename.
21352         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
21353         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
21354
21355         Module rmdir.
21356         * m4/rmdir.m4: New file.
21357
21358         Module utime.
21359         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
21360         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
21361         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
21362
21363         Module dirname.
21364         * m4/dirname.m4: New file.
21365
21366         Module getopt.
21367         * m4/getopt.m4: New file.
21368
21369         Module unistd-safer.
21370         * m4/unistd-safer.m4: New file.
21371
21372         Module fnmatch.
21373         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
21374         declaration.
21375         (gl_PREREQ_FNMATCH_EXTRA): New macro.
21376         (gl_FUNC_FNMATCH_POSIX): New macro.
21377         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
21378         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
21379         simply fnmatch.
21380
21381         Module exclude.
21382         * m4/exclude.m4: New file.
21383
21384         Module human.
21385         * m4/human.m4: New file.
21386
21387         Module acl.
21388         * m4/acl.m4: Nop.
21389
21390         Module backupfile.
21391         * m4/backupfile.m4: New file.
21392         * m4/d-ino.m4: Indentation.
21393
21394         Module fsusage.
21395         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
21396         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
21397         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
21398
21399         Module dirfd.
21400         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
21401         requirements.
21402
21403         Module euidaccess.
21404         * m4/euidaccess.m4: New file.
21405
21406         Module file-type.
21407         * m4/file-type.m4: New file.
21408
21409         Module fileblocks.
21410         * m4/fileblocks.m4: New file.
21411
21412         Module filemode.
21413         * m4/filemode.m4: New file.
21414
21415         Module isdir.
21416         * m4/isdir.m4: New file.
21417
21418         Module lchown.
21419         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
21420         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
21421
21422         Module makepath.
21423         * m4/makepath.m4: New file.
21424
21425         Module modechange.
21426         * m4/modechange.m4: New file.
21427
21428         Module mountlist.
21429         * m4/mountlist.m4: New file.
21430         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
21431         Indentation.
21432
21433         Module path-concat.
21434         * m4/path-concat.m4: New file.
21435
21436         Module pathmax.
21437         * m4/pathmax.m4: New file.
21438
21439         Module same.
21440         * m4/same.m4: New file.
21441
21442         Module save-cwd.
21443         * m4/save-cwd.m4: New file.
21444
21445         Module savedir.
21446         * m4/savedir.m4: New file.
21447
21448         Module xgetcwd.
21449         * m4/xgetcwd.m4: New file.
21450         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
21451
21452         Module xreadlink.
21453         * m4/xreadlink.m4: New file.
21454
21455         Module safe-read.
21456         * m4/safe-read.m4: New file.
21457
21458         Module safe-write.
21459         * m4/safe-write.m4: New file.
21460
21461         Module closeout.
21462         * m4/closeout.m4: New file.
21463
21464         Module stdio-safer.
21465         * m4/stdio-safer.m4: New file.
21466
21467         Module getpass.
21468         * m4/getpass.m4: New file.
21469
21470         Module getugroups.
21471         * m4/getugroups.m4: New file.
21472
21473         Module group-member.
21474         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
21475         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
21476
21477         Module idcache.
21478         * m4/idcache.m4: New file.
21479
21480         Module userspec.
21481         * m4/userspec.m4: New file.
21482
21483         Module gettime.
21484         * m4/clock_time.m4: New file.
21485         * m4/gettime.m4: New file.
21486
21487         Module settime.
21488         * m4/settime.m4: New file.
21489
21490         Module posixtm.
21491         * m4/posixtm.m4: New file.
21492
21493         Module gethostname.
21494         * m4/gethostname.m4: New file.
21495
21496         Module canon-host.
21497         * m4/canon-host.m4: New file.
21498
21499         Module gettext.
21500         * m4/codeset.m4: New file, from gettext-0.11.5.
21501         * m4/gettext.m4: New file, from gettext-0.11.5.
21502         * m4/glibc21.m4: New file, from gettext-0.11.5.
21503         * m4/iconv.m4: New file, from gettext-0.11.5.
21504         * m4/intdiv0.m4: New file, from gettext-0.11.5.
21505         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
21506         * m4/inttypes.m4: New file, from gettext-0.11.5.
21507         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
21508         * m4/isc-posix.m4: New file, from gettext-0.11.5.
21509         * m4/lcmessage.m4: New file, from gettext-0.11.5.
21510         * m4/lib-ld.m4: New file, from gettext-0.11.5.
21511         * m4/lib-link.m4: New file, from gettext-0.11.5.
21512         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
21513         * m4/progtest.m4: New file, from gettext-0.11.5.
21514         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
21515         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
21516         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
21517
21518         Module localcharset.
21519         * m4/localcharset.m4: New file.
21520
21521         Module hard-locale.
21522         * m4/hard-locale.m4: New file.
21523
21524         Module mbswidth.
21525         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
21526         onceonly macros.
21527         * m4/mbrtowc.m4: Add comment.
21528
21529         Module memcasecmp.
21530         * m4/memcasecmp.m4: New file.
21531
21532         Module memcoll.
21533         * m4/memcoll.m4: New file.
21534
21535         Module unicodeio.
21536         * m4/unicodeio.m4: New file.
21537
21538         Module rpmatch.
21539         * m4/rpmatch.m4: New file.
21540
21541         Module yesno.
21542         * m4/yesno.m4: New file.
21543
21544         Module exitfail.
21545         * m4/exitfail.m4: New file.
21546
21547         Module c-stack.
21548         * m4/c-stack.m4 (gl_C_STACK): New macro.
21549         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
21550
21551         Module error.
21552         * m4/error.m4 (gl_ERROR): New macro.
21553         (jm_PREREQ_ERROR): Use onceonly macros.
21554
21555         Module fatal.
21556         * m4/fatal.m4: New file.
21557
21558         Module getloadavg.
21559         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
21560         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
21561
21562         Module getpagesize.
21563         * m4/getpagesize.m4: New file.
21564
21565         Module getusershell.
21566         * m4/getusershell.m4: New file.
21567
21568         Module physmem.
21569         * m4/physmem.m4: New file.
21570
21571         Module posixver.
21572         * m4/posixver.m4: New file.
21573
21574         Module quotearg.
21575         * m4/quotearg.m4: New file.
21576
21577         Module quote.
21578         * m4/quote.m4: New file.
21579
21580         Module readutmp.
21581         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
21582
21583         Module sig2str.
21584         * m4/sig2str.m4: New file.
21585
21586         Other.
21587         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
21588         ulonglong.m4.
21589         * m4/intmax_t.m4: New file.
21590         * m4/d-type.m4: Indentation.
21591         * m4/jm-macros.m4: Update.
21592         * m4/prereq.m4 (jm_PREREQ): Update.
21593         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
21594         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
21595         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
21596         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
21597         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
21598         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
21599         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
21600         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
21601         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
21602         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
21603         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
21604         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
21605         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
21606         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
21607         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
21608         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
21609         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
21610         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
21611         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
21612
21613 2002-12-24  Bruno Haible  <bruno@clisp.org>
21614
21615         * MODULES.txt: Update according to m4/ changes.
21616
21617         Module gettext.
21618         * config.rpath: New file, from gettext-0.11.5.
21619
21620         * modules/*: New module descriptions.
21621         * gnulib-tool: New file.
21622         * MODULES.html.sh: New file.
21623
21624 2002-12-21  Karl Berry  <karl@gnu.org>
21625
21626         * doc/fdl.texi: update to version 1.2.
21627
21628 2002-12-19  Karl Berry  <karl@gnu.org>
21629
21630         * config/config.guess: update from prep.
21631
21632 2002-12-18  Bruno Haible  <bruno@clisp.org>
21633
21634         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
21635         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
21636
21637 2002-12-17  Bruno Haible  <bruno@clisp.org>
21638
21639         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
21640         stdlib.h, string.h.
21641
21642 2002-12-17  Bruno Haible  <bruno@clisp.org>
21643
21644         * lib/canon-host.c (strdup): Remove unused declaration.
21645
21646         * lib/fsusage.c: Include full_read.h.
21647         (get_fs_usage): Use full_read instead of safe_read.
21648
21649         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
21650
21651 2002-12-12  Karl Berry  <karl@gnu.org>
21652
21653         * config/config.guess: update from prep.
21654
21655 2002-12-11  Bruno Haible  <bruno@clisp.org>
21656
21657         * m4/setenv.m4: New file, from gettext-0.11.5.
21658
21659 2002-12-11  Bruno Haible  <bruno@clisp.org>
21660
21661         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
21662         not unsetenv().
21663         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
21664         modifications:
21665
21666         2002-12-11  Bruno Haible  <bruno@clisp.org>
21667
21668                 * setenv.c (alloca): Fall back to malloc.
21669                 (freea): New macro.
21670                 (setenv): Use freea() to free memory allocated with alloca().
21671
21672         2002-11-13  Bruno Haible  <bruno@clisp.org>
21673
21674                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
21675                 function declarations.
21676                 * unsetenv.c (unsetenv): Likewise.
21677
21678         2002-03-04  Bruno Haible  <bruno@clisp.org>
21679
21680                 Portability to AIX 4.3.3.
21681                 * unsetenv.c: New file, extracted from setenv.c.
21682                 * setenv.c: Move the unsetenv() function to unsetenv.c.
21683
21684         2001-12-20  Bruno Haible  <bruno@clisp.org>
21685
21686                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
21687                 use malloc instead. For SunOS 4.
21688
21689         2001-12-11  Bruno Haible  <bruno@clisp.org>
21690
21691                 * setenv.c: Declare alloca.
21692                 (compar_fn_t): New typedef.
21693                 (KNOWN_VALUE, STORE_VALUE): Use it.
21694
21695         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
21696         setenv.h.
21697
21698 2002-12-10  Paul Eggert  <eggert@twinsun.com>
21699
21700         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
21701         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
21702         Choose values that are less likely to collide with system fnmatch
21703         options.
21704         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
21705         defined (e.g., a pure POSIX system).
21706         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
21707         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
21708
21709 2002-12-06  Paul Eggert  <eggert@twinsun.com>
21710
21711         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
21712         a pain in practice to deal with generated m4 files.  This change
21713         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
21714
21715         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
21716         and jm-glibc-io.m4, as they are no longer a special case.
21717         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
21718         kludge and the auto-generation stuff.  Check only whether the
21719         functions are declared, not whether they exist, since older hosts
21720         that don't declare the functions can't use the optimization anyway.
21721
21722 2002-12-06  Jim Meyering  <jim@meyering.net>
21723
21724         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
21725
21726         Merge in changes from libc's misc/error.c, in preparation
21727         for the merge of gnulib's changes back into libc.
21728
21729         * lib/error.c (_): Define only if not already defined.
21730         Move definition to follow all #include directives.
21731         Include unlocked-io.h only if !_LIBC.
21732         [_LIBC]: Include <libio/libioP.h>.
21733         [USE_IN_LIBIO]: Include <libio/iolibio.h>
21734         (fflush): Tweak definition to use INTUSE.
21735         (putc): Define.
21736
21737 2002-12-05  Paul Eggert  <eggert@twinsun.com>
21738
21739         * lib/alloca.c [defined emacs]: Include "lisp.h".
21740         (xalloc_die) [defined emacs]: New macro.
21741         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
21742         [! defined emacs]: Include <xalloc.h>.
21743         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
21744         (pointer): Typedef to POINTER_TYPE *.
21745         (malloc): Remove decl; we now always use xmalloc.
21746         (alloca): Use old-style definition, since Emacs needs this.
21747         Check for arithmetic overflow when computing combined size.
21748
21749 2002-12-04  Paul Eggert  <eggert@twinsun.com>
21750
21751         Do not generate unlocked-io.h automatically, since it's easier to
21752         maintain it by hand.
21753
21754         * lib/unlocked-io.h: New file, from GNU diffutils,
21755         but with proper copyright notice and attribution.
21756         * lib/gen-uio: Remove.
21757         * lib/Makefile.am: Add copyright notice.
21758         (libfetish_a_SOURCES): Add unlocked-io.h.
21759         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
21760         (DISTCLEANFILES, io_functions): Remove macros.
21761         (EXTRA_DIST): Remove gen_uio.
21762         (unlocked-io.h): Remove rule.
21763
21764 2002-12-04  Jim Meyering  <jim@meyering.net>
21765
21766         Reflect the fact that stat.c and lstat.c are no longer generated.
21767         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
21768         (DISTCLEANFILES): Likewise.
21769         (EXTRA_DIST): Likewise.
21770         (all_local): Don't depend on stat.c or lstat.c.
21771         (stat.c, lstat.c): Remove rules.
21772         (EXTRA_DIST): Remove xstat.in.
21773
21774         * lib/xstat.in: Remove file.  Contents moved into stat.c.
21775         * lib/stat.c: New file.  Contents mostly from xstat.in.
21776         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
21777         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
21778
21779         * lib/safe-read.c: Rework so that it may serve to define safe_write,
21780         too.
21781         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
21782
21783 2002-12-03  Jim Meyering  <jim@meyering.net>
21784
21785         * lib/safe-read.c, safe-write.c: Change variable names and comments,
21786         but not semantics, to minimize the differences between these two files.
21787         (safe_read): Change comment to mention SAFE_READ_ERROR.
21788
21789         * lib/safe-read.c (IS_EINTR): Define.
21790         (safe_read): Use IS_EINTR in place of in-function cpp directives.
21791
21792 2002-12-02  Jim Meyering  <jim@meyering.net>
21793
21794         * lib/safe-read.c (EINTR): Define.
21795         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
21796         (INT_MAX): Provide fallback.
21797         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
21798
21799         * lib/safe-read.h (SAFE_READ_ERROR): Define.
21800
21801 2002-12-02  Bruno Haible  <bruno@clisp.org>
21802
21803         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
21804         Define, taken from safe-read.c.
21805         (INT_MAX): Provide fallback.
21806         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
21807         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
21808
21809         * lib/safe-read.c (EINTR): Remove definition.
21810         (safe_read): Don't use EINTR if it is absent.
21811
21812 2002-12-01  Jim Meyering  <jim@meyering.net>
21813
21814         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
21815         zero.
21816         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
21817
21818 2002-11-27  Paul Eggert  <eggert@twinsun.com>
21819
21820         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
21821         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
21822         with `if (! (value < limit)) abort ();', for readability.
21823
21824 2002-11-26  Karl Berry  <karl@gnu.org>
21825
21826         * lib/strdup.c: copy from libc again, with jim's ok.
21827         * lib/.cppi-disable: re-add strdup.c
21828
21829 2002-11-25  Karl Berry  <karl@gnu.org>
21830
21831         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
21832         instead of "strtol.c".
21833
21834 2002-11-25  Karl Berry  <karl@gnu.org>
21835
21836         * config/install-sh: update from automake for variable quoting, $0 in
21837         error msgs, etc.
21838
21839         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
21840         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
21841         entry.
21842
21843 2002-11-25  Jim Meyering  <jim@meyering.net>
21844
21845         * lib/mktime.c: Sync from libc, now that it has the latest fix.
21846
21847 2002-11-24  Karl Berry  <karl@gnu.org>
21848
21849         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
21850         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
21851
21852 2002-11-24  Jim Meyering  <jim@meyering.net>
21853
21854         Update from coreutils:
21855
21856         * lib/mktime.c: Merge in changes from libc.
21857
21858         Avoid a link-time failure on some Linux systems.
21859         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
21860         (otherwise).
21861         (__mon_yday): Declare with the STATIC attribute.
21862         (__mktime_internal): Likewise.
21863         Based on a report from Greg Schafer.
21864
21865 2002-11-23  Jim Meyering  <jim@meyering.net>
21866
21867         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
21868         Use `unsigned', not `int', as type of index.
21869
21870         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
21871
21872         * lib/fsusage.c: Remove unneeded parentheses around operands of
21873         `defined'.
21874
21875 2002-11-22  Paul Eggert  <eggert@twinsun.com>
21876
21877         * lib/quotearg.h: Allow multiple inclusion by surrounding with
21878         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
21879         so that we can be included first.
21880         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
21881         * lib/quotearg.c: Include quotearg.h immediately after config.h.
21882         No need to include stddef.h or sys/types.h any more.
21883         Surround local include files with "", not "<>".
21884         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
21885         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
21886         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
21887         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
21888         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
21889         (ISPRINT): Remove; no longer needed now that we assume C89.
21890
21891         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
21892         Preserve errno.
21893
21894         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
21895         quotearg_char): Use SIZE_MAX rather than
21896         (size_t) -1 when we are talking about "infinity".
21897
21898         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
21899
21900 2002-11-22  Paul Eggert  <eggert@twinsun.com>
21901
21902         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
21903         hint that one should use `if (! x) abort ();' rather than `assert
21904         (x);', and anyway it's one less thing to worry about configuring.
21905         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
21906         hash_rehash, hash_insert): Use abort rather than assert.
21907
21908 2002-11-22  Bruno Haible  <bruno@clisp.org>
21909
21910         * lib/safe-read.h: Assume C89. Add comments.
21911         (safe_read): Change return type to size_t.
21912         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
21913         byte counts > SSIZE_MAX correctly.
21914         * lib/safe-write.h: New file.
21915         * lib/safe-write.c: New file.
21916         * lib/full-read.h: New file.
21917         * lib/full-read.c: New file.
21918         * lib/full-write.h: Assume C89. Add comments.
21919         * lib/full-write.c: Include safe-write.h.
21920         (full_write): Rewritten to use safe_write.
21921         Suggested by Jim Meyering and Paul Eggert.
21922
21923 2002-11-21  Jim Meyering  <jim@meyering.net>
21924
21925         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
21926
21927         Merge in changes from the coreutils.
21928
21929         2002-09-25  Paul Eggert  <eggert@twinsun.com>
21930         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
21931         <stdint.h>.
21932         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
21933         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
21934         int.  Work more efficiently if X is the same width as uintmax_t.
21935         Do not compare X to -1, to avoid bogus compiler warning.
21936         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
21937         Don't assume that f_frsize and f_bsize are the same type.
21938
21939         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
21940         warning on FreeBSD.
21941
21942         * lib/makepath.c (make_path): Restore umask *before* creating the final
21943         component.
21944         (make_path): Minor reformatting.
21945
21946         * lib/xmalloc.c: Adjust to work with new autoconf macros,
21947         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
21948         HAVE_MALLOC/HAVE_REALLOC.
21949
21950         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
21951         dummy ones.  At least on GNU/Linux systems, `auto' means something
21952         else.
21953         From Michael Stone.
21954
21955 2002-11-21  Bruno Haible  <bruno@clisp.org>
21956
21957         Remove case insensitive option matching.
21958         * lib/argmatch.h (argcasematch): Remove declaration.
21959         (ARGCASEMATCH): Remove macro.
21960         (__xargmatch_internal): Remove case_sensitive argument.
21961         (XARGMATCH): Update.
21962         (XARGCASEMATCH): Remove macro.
21963         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
21964         case_sensitive argument.
21965         (argcasematch): Remove function.
21966         (__xargmatch_internal): Remove case_sensitive argument.
21967         (main): Use XARGMATCH instead of XARGCASEMATCH.
21968
21969         * lib/xmalloc.c: Change compile-time error message. Add comment about
21970         required autoconf version.
21971
21972 2002-11-20  Paul Eggert  <eggert@twinsun.com>
21973
21974         Merge argmatch cleanups from Bison.  Assume C89.
21975
21976         * lib/argmatch.c: Include config.h here, not in argmatch.h.
21977         Include stdlib.h, for EXIT_FAILURE.
21978         Always include <string.h>, since we assume C89.
21979         (EXIT_FAILURE): Remove pre-C89 bug workaround.
21980         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
21981         Include <stddef.h> instead, since it's all we need for size_t.
21982         (PARAMS): Remove.  All uses removed.
21983         (ARRAY_CARDINALITY): Do not bother to #undef.
21984         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
21985         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
21986         Remove unnecessary parentheses.
21987         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
21988         Insert necessary parentheses.
21989         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
21990         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
21991
21992 2002-11-19  Bruno Haible  <bruno@clisp.org>
21993
21994         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
21995         * lib/mbswidth.h: Include <stddef.h>, for size_t.
21996
21997         * lib/mbswidth.h (PARAMS): Remove macro.
21998         (mbswidth, mbsnwidth): Use ANSI C function declarations.
21999         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
22000
22001         * lib/gcd.h (PARAMS): Remove macro.
22002         (gcd): Use ANSI C function declarations.
22003         * lib/gcd.c (gcd): Likewise.
22004
22005 2002-11-15  Bruno Haible  <bruno@clisp.org>
22006
22007         * lib/strcspn.c: Include <stddef.h>.
22008         (strcspn): Use ANSI C function declaration. Change return type to
22009         size_t. Use NULL.
22010         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
22011         (strpbrk): Use NULL.
22012         * lib/strpbrk.h (PARAMS): Remove macro.
22013         (strpbrk): Use ANSI C function declaration.
22014         * lib/strstr.c: Don't include <sys/types.h>.
22015         * lib/strstr.h (PARAMS): Remove macro.
22016         (strstr): Use ANSI C function declarations.
22017
22018 2002-11-14  Karl Berry  <karl@gnu.org>
22019
22020         * config/mkinstalldirs: `do' on separate line, instead of
22021         `for var; do'.
22022
22023 2002-11-06  Bruno Haible  <bruno@clisp.org>
22024
22025         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
22026         * lib/gcd.c (gcd): Likewise.
22027
22028 2002-11-05  Bruno Haible  <bruno@clisp.org>
22029
22030         * lib/gcd.h: New file, from gettext-0.11.5.
22031         * lib/gcd.c: New file, from gettext-0.11.5.
22032
22033 2002-11-05  Bruno Haible  <bruno@clisp.org>
22034
22035         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
22036         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
22037         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
22038         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
22039
22040         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
22041         <libintl.h>.
22042         * lib/makepath.c: Include gettext.h instead of <locale.h> and
22043         <libintl.h>.
22044
22045         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
22046         * lib/human.c: Include gettext.h instead of <libintl.h>.
22047         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
22048         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
22049         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
22050         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
22051         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
22052         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
22053         (textdomain): Remove definition.
22054         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
22055
22056         * lib/long-options.c: Remove include of <libintl.h> and definition of
22057         _.
22058         * lib/same.c: Remove include of <libintl.h> and definition of _.
22059
22060 2002-11-04  Owen Taylor  <otaylor@redhat.com>
22061
22062         * lib/config.charset: A few additions for Solaris.
22063
22064 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
22065
22066         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
22067         * lib/localcharset.c (locale_charset): Declare as extern "C".
22068
22069 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
22070
22071         * lib/config.charset: msdos in uk_UA uses CP1125.
22072
22073 2002-11-04  Bruno Haible  <bruno@clisp.org>
22074
22075         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
22076         * lib/strcase.h: New file, from GNU gettext-0.11.5.
22077         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
22078         * lib/strstr.h: New file, from GNU gettext-0.11.5.
22079         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
22080
22081 2002-11-04  Bruno Haible  <bruno@clisp.org>
22082
22083         * lib/localcharset.c (locale_charset): Don't return an empty string.
22084
22085 2002-11-04  Bruno Haible  <bruno@clisp.org>
22086
22087         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
22088         aliases.
22089
22090 2002-11-04  Bruno Haible  <bruno@clisp.org>
22091
22092         * lib/config.charset: Update for newest glibc. Add canonical names
22093         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
22094
22095 2002-11-04  Bruno Haible  <bruno@clisp.org>
22096
22097         * lib/config.charset: Add support for NetBSD.
22098
22099 2002-11-04  Bruno Haible  <bruno@clisp.org>
22100
22101         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
22102
22103 2002-11-01  Bruno Haible  <bruno@clisp.org>
22104
22105         * configure.in: Add AC_CONFIG_AUX_DIR call.
22106         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
22107         test/Makefile.
22108         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
22109
22110 2002-09-28  Karl Berry  <karl@gnu.org>
22111
22112         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
22113         installed automake until the next release, since changes have been
22114         made.
22115
22116 2002-09-25  Karl Berry  <karl@gnu.org>
22117
22118         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
22119         * lib/getopt*: copy from libc/posix.
22120         * lib/gettext.h: copy from gettext.
22121         * lib/.cppi-disable: add strdup.c, gettext.h.
22122
22123 2002-09-25  Karl Berry  <karl@gnu.org>
22124
22125         * config/srclist.txt: enable gettext.h check.
22126         * config/config.{guess,sub}: update from prep.
22127         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
22128                 from automake 1.6.3.
22129         See srclist*.
22130
22131 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
22132
22133         * regex.c (PATFETCH): Remove the translating fetch.
22134         (PATFETCH_RAW): Rename to PATFETCH.
22135         (set_image_of_range): New fun.
22136         (SET_RANGE_TABLE_WORK_AREA): Use it.
22137         (regex_compile): Don't translate the pattern chars so eagerly.
22138         Only do it when inserting an `exactn' bytecode or when handling
22139         a char-range.
22140         (mutually_exclusive_p): Avoid empty statement.
22141
22142 2002-07-06  Jim Meyering  <meyering@lucent.com>
22143
22144         * m4/README: Don't mention Makefile.am.in.
22145         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
22146
22147 2002-07-01  Jim Meyering  <meyering@lucent.com>
22148
22149         * lib/c-stack.c: Include sys/time.h.
22150         From Volker Borchert.
22151
22152 2002-06-26  Paul Eggert  <eggert@twinsun.com>
22153
22154         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
22155
22156 2002-06-26  Paul Eggert  <eggert@twinsun.com>
22157
22158         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
22159         New macro.  Use it uniformly instead of
22160         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
22161         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
22162         reported by Vin Shelton.
22163
22164 2002-06-22  Paul Eggert  <eggert@twinsun.com>
22165
22166         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
22167         Do not assume SA_SIGINFO behavior.
22168         Bug reported by Jim Meyering on NetBSD 1.5.2.
22169
22170 2002-06-22  Jim Meyering  <meyering@lucent.com>
22171
22172         * m4/c-stack.m4: New file, from diffutils-2.8.2.
22173         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
22174
22175         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
22176         now that configure.ac uses AC_GNU_SOURCE.
22177         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
22178         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
22179
22180         Update to latest tools.  Suggestions from Paul Eggert.
22181         * m4/stdbool.m4: New file, from diffutils-2.8.2.
22182         * m4/gnu-source.m4: Update from diffutils-2.8.2.
22183         * m4/fnmatch.m4: Likewise.
22184         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
22185         to AC_HEADER_STDBOOL
22186
22187 2002-06-22  Jim Meyering  <meyering@lucent.com>
22188
22189         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
22190         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
22191
22192 2002-06-22  Jim Meyering  <meyering@lucent.com>
22193
22194         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
22195
22196         * lib/exitfail.c, exitfail.h: Likewise.
22197         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
22198
22199         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
22200         of fnmatch.h.
22201         (EXTRA_DIST): Add fnmatch_loop.c.
22202         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
22203
22204         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
22205         * lib/fnmatch.c: Update from diffutils-2.8.2.
22206         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
22207         * lib/fnmatch.h: Remove file.
22208
22209 2002-06-21  Jim Meyering  <meyering@lucent.com>
22210
22211         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
22212         * m4/mbrtowc.m4: Likewise.
22213
22214         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
22215         * m4/mbswidth.m4: Reflect name change:
22216         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
22217         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22218
22219         * m4/lib-link.m4: Update from gettext-0.11.2.
22220         * m4/gettext.m4: Likewise.
22221
22222         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
22223         From Alfred M. Szmidt.
22224
22225 2002-06-18  Paul Eggert  <eggert@twinsun.com>
22226
22227         * lib/file-type.h: Report an error if neither S_ISREG nor
22228         S_IFREG is defined, instead of using a test specific to glibc
22229         2.2.  This should be safe, since POSIX requires S_ISREG and
22230         Unix Version 7 had S_IFREG.  We don't need to check for
22231         <sys/types.h> since we don't use any symbols that it defines.
22232
22233 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
22234
22235         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
22236         $@-t, so that each temporary file name is unique and valid in the first
22237         8 characters, for operation under DOS.
22238
22239 2002-06-15  Paul Eggert  <eggert@twinsun.com>
22240
22241         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
22242
22243 2002-06-15  Jim Meyering  <meyering@lucent.com>
22244
22245         Work even with DJGPP 2.03, which lacks support for symlinks.
22246         From Richard Dawe.
22247         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
22248         is defined.
22249         * lib/lchown.c (S_ISLNK): Likewise.
22250
22251 2002-06-15  Jim Meyering  <meyering@lucent.com>
22252
22253         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
22254         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
22255         have been included before this file.
22256
22257 2002-06-14  Jim Meyering  <meyering@lucent.com>
22258
22259         * lib/file-type.h: Use the version from diffutils-2.8.2.
22260         * lib/file-type.c: Likewise.
22261
22262 2002-06-07  Jim Meyering  <meyering@lucent.com>
22263
22264         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
22265         They're needed at least for NetBSD 1.5.2.
22266         ($statxfs_includes): Include those same headers.
22267         ($statxfs_includes): Include sys/vfs.h if available.
22268         ($statxfs_includes): Likewise for sys/statvfs.h.
22269         Check for the following members in both structs statfs and statvfs:
22270         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
22271
22272 2002-06-01  Jim Meyering  <meyering@lucent.com>
22273
22274         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
22275         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
22276
22277 2002-05-28  Jim Meyering  <meyering@lucent.com>
22278
22279         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
22280         Reported by Volker Borchert.
22281
22282 2002-05-27  Jim Meyering  <meyering@lucent.com>
22283
22284         Fix a problem seen only on nonconforming systems whereby ls.c's
22285         use of localtime, and then of gettimeofday would cause trouble:
22286         the localtime call used to initialize rpl_gettimeofday's save
22287         mechanism would clobber ls's current local time information so
22288         that in any long listing the first file would always be listed
22289         with date 1970-01-01.  Analysis by Volker Borchert.
22290
22291         * lib/gettimeofday.c (localtime): Undefine.
22292         (rpl_localtime): New function.
22293
22294 2002-05-27  Jim Meyering  <meyering@lucent.com>
22295
22296         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
22297         localtime.
22298
22299         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
22300         use the replacement function; it wouldn't resolve at link time.
22301         Reported by Volker Borchert.
22302
22303 2002-05-22  Jim Meyering  <meyering@lucent.com>
22304
22305         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
22306         file-type.h.
22307         * lib/file-type.h: New file.
22308         * lib/file-type.c (file_type): New file/function.  Extracted from
22309         diffutils.
22310
22311 2002-04-30  Jim Meyering  <meyering@lucent.com>
22312
22313         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
22314
22315 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22316
22317         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
22318
22319 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22320
22321         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
22322         Do not check for alloca.h (no longer used) or stdbool.h (was never
22323         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
22324
22325 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22326
22327         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
22328
22329 2002-04-29  Jim Meyering  <meyering@lucent.com>
22330
22331         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
22332         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
22333         Use AC_FUNC_STRNLEN here instead.
22334
22335         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
22336         With autoconf-2.53a, it's part of AC_PROG_CC.
22337
22338 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22339
22340         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
22341         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
22342
22343 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22344
22345         * lib/sig2str.h, lib/sig2str.c: New files.
22346         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
22347
22348 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22349
22350         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
22351         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
22352         of 127, since 64 is the largest conceivable number for ancient
22353         nonstandard hosts.
22354         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
22355
22356 2002-04-28  Jim Meyering  <meyering@lucent.com>
22357
22358         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
22359
22360 2002-04-24  Jim Meyering  <meyering@lucent.com>
22361
22362         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
22363         (jm_PREREQ): Use it.
22364
22365         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
22366         mach/mach.h fcntl.h.
22367         Check for this function: setlocale.
22368
22369 2002-04-24  Jim Meyering  <meyering@lucent.com>
22370
22371         * lib/gettext.h: New file, from Gettext.
22372         * lib/Makefile.am (INCLUDES): Remove -I../intl.
22373         (libfetish_a_SOURCES): Add gettext.h.
22374
22375 2002-04-16  Jim Meyering  <meyering@lucent.com>
22376
22377         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
22378         ut_pid, ut_id, ut_exit.
22379
22380 2002-04-16  Jim Meyering  <meyering@lucent.com>
22381
22382         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
22383         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
22384         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
22385
22386 2002-04-12  Jim Meyering  <meyering@lucent.com>
22387
22388         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
22389         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
22390         existence of the getmntinfo function.  Needed for Darwin 5.3.
22391
22392         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
22393         This is necessary at least on Darwin 5.3.
22394
22395         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
22396         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
22397         strnlen.o in the library, and that makes some versions of ranlib
22398         object.
22399
22400 2002-04-12  Jim Meyering  <meyering@lucent.com>
22401
22402         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
22403
22404 2002-04-09  Jim Meyering  <meyering@lucent.com>
22405
22406         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
22407         to be more precise.  Rather than saying we're checking whether the
22408         function `works', say what we're testing.
22409         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
22410         Reported by Bruno Haible.
22411
22412 2002-03-10  Jim Meyering  <meyering@lucent.com>
22413
22414         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
22415         Suggestion from Santiago Vila.
22416
22417 2002-03-08  Jim Meyering  <meyering@lucent.com>
22418
22419         * lib/rename.c: Mention that this wrapper is needed also on
22420         mips-dec-ultrix4.4 systems.
22421
22422 2002-03-02  Jim Meyering  <meyering@lucent.com>
22423
22424         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
22425         not HAVE_CLOCK_SETTIME.
22426
22427 2002-02-27  Paul Eggert  <eggert@twinsun.com>
22428
22429         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
22430         Check for clock_settime.
22431
22432 2002-02-27  Paul Eggert  <eggert@twinsun.com>
22433
22434         * lib/nanosleep.h: Rename to....
22435         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
22436
22437         * lib/gettime.c: New file.
22438         * lib/settime.c: New file.
22439         * lib/stime.c: Remove.
22440
22441         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
22442         timespec.h.  Remove nanosleep.h.
22443
22444 2002-02-25  Paul Eggert  <eggert@twinsun.com>
22445
22446         * m4/acl.m4: New file.
22447         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
22448         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
22449
22450 2002-02-25  Paul Eggert  <eggert@twinsun.com>
22451
22452         * lib/acl.c, lib/acl.h: New files.
22453         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
22454
22455 2002-02-24  Jim Meyering  <meyering@lucent.com>
22456
22457         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
22458         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
22459         cause trouble.  Reported by Nelson Beebe.
22460
22461 2002-02-23  Paul Eggert  <eggert@twinsun.com>
22462
22463         * lib/path-concat.c (xpath_concat): Reorder code to pacify
22464         compilers that don't know that xalloc_die never returns.
22465
22466 2002-02-20  Jim Meyering  <meyering@lucent.com>
22467
22468         * lib/getdate.c: Regenerate using bison-1.33.
22469
22470 2002-02-17  Jim Meyering  <meyering@lucent.com>
22471
22472         * config/config.guess (main): Don't use `head -1'; it's no longer
22473         portable. Use `sed 1q' instead.
22474
22475 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
22476
22477         * m4/codeset.m4: Upgrade to gettext-0.11.
22478         * m4/gettext.m4: Upgrade to gettext-0.11.
22479         * m4/glibc21.m4: Upgrade to gettext-0.11.
22480         * m4/iconv.m4: Upgrade to gettext-0.11.
22481         * m4/isc-posix.m4: Upgrade to gettext-0.11.
22482         * m4/lcmessage.m4: Upgrade to gettext-0.11.
22483         * m4/lib-ld.m4: New file, from gettext-0.11.
22484         * m4/lib-link.m4: New file, from gettext-0.11.
22485         * m4/lib-prefix.m4: New file, from gettext-0.11.
22486         * m4/progtest.m4: Upgrade to gettext-0.11.
22487
22488 2002-02-15  Paul Eggert  <eggert@twinsun.com>
22489
22490         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
22491         (jm_PREREQ): Use it.
22492
22493 2002-02-15  Paul Eggert  <eggert@twinsun.com>
22494
22495         * lib/posixver.c, lib/posixver.h: New files.
22496         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
22497
22498 2002-02-02  Paul Eggert  <eggert@twinsun.com>
22499             Bruno Haible  <bruno@clisp.org>
22500
22501         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
22502         (fwrite_success_callback): New declaration.
22503         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
22504         print_unicode_char. Call failure callback instead of error.
22505         (fwrite_success_callback): New function.
22506         (exit_failure_callback): New function.
22507         (fallback_failure_callback): New function.
22508         (print_unicode_char): Call unicode_to_mb.
22509
22510 2002-01-26  Jim Meyering  <meyering@lucent.com>
22511
22512         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
22513         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
22514
22515 2002-01-26  Jim Meyering  <meyering@lucent.com>
22516
22517         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
22518
22519 2002-01-22  Paul Eggert  <eggert@twinsun.com>
22520
22521         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
22522
22523 2002-01-22  Jim Meyering  <meyering@lucent.com>
22524
22525         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
22526         Otherwise, some versions of automake would omit the rule that makes
22527         Makefile from Makefile.in.
22528
22529 2002-01-21  Paul Eggert  <eggert@twinsun.com>
22530
22531         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
22532         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
22533         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
22534         (memcoll): Set errno to zero if there is no error.
22535
22536         * lib/quotearg.c (quotearg_buffer_restyled):
22537         Fix bug with quoting buffers containing NUL when backslashing escapes.
22538         This bug was exposed by the other changes in this patch.
22539         (quotearg_n_options): New arg ARGSIZE.
22540         All callers changed.
22541         (quoting_options_from_style): New function.
22542         (quotearg_n_style): Use it.
22543         (quotearg_n_style_mem): New function.
22544
22545         * lib/quotearg.h (quotearg_n_style_mem): New function.
22546
22547 2002-01-19  Jim Meyering  <meyering@lucent.com>
22548
22549         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
22550         Remove useless quotes: DF_PROG="df".
22551         * m4/strnlen.m4: New file.
22552
22553 2002-01-16  Paul Eggert  <eggert@twinsun.com>
22554
22555         * lib/backupfile.c (ISDIGIT): Comment fix.
22556         * lib/getdate.y (ISDIGIT): Likewise.
22557         * lib/posixtm.c (ISDIGIT, year): Likewise.
22558         * lib/strverscmp.c (ISDIGIT): Likewise.
22559         * lib/userspec.c (ISDIGIT): Likewise.
22560
22561 2002-01-16  Jim Meyering  <meyering@lucent.com>
22562
22563         * lib/getdate.y: Add three semicolons, each just before a closing
22564         brace. Bison (as of version 1.31) no longer papers over that mistake.
22565
22566 2002-01-05  Jim Meyering  <meyering@lucent.com>
22567
22568         * lib/version-etc.c (version_etc_copyright): Update copyright year.
22569
22570 2001-12-19  Paul Eggert  <eggert@twinsun.com>
22571
22572         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
22573         not silently exit merely because the output buffer happens to
22574         have nothing pending.
22575
22576 2001-12-18  Paul Eggert  <eggert@twinsun.com>
22577
22578         See the big note in ../ChangeLog.
22579         * lib/human.c (suffixes): Prefer K to k for 1024.
22580         (generate_suffix_backwards): New function.
22581         (human_readable_inexact): Use it.
22582         * lib/xstrtol.c (__xstrtol): If there is no number but there
22583         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
22584         Accept 'K' as well as 'k'.
22585
22586 2001-12-15  Jim Meyering  <meyering@lucent.com>
22587
22588         * lib/regex.h (__restrict_arr): Update from libc.
22589
22590         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
22591         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
22592         (STREQ): Define.
22593
22594 2001-12-14  Jim Meyering  <meyering@lucent.com>
22595
22596         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
22597         Suggestion from Bruno Haible.
22598
22599 2001-12-10  Jim Meyering  <meyering@lucent.com>
22600
22601         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
22602         xrealloc, Instead, include "xalloc.h".
22603         (initbuffer): Don't cast xmalloc return value to char*.
22604         (readline): Reword comment.
22605         Don't cast xrealloc return value to char*
22606         Return NULL, not 0.
22607
22608 2001-12-09  Jim Meyering  <meyering@lucent.com>
22609
22610         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
22611         about `signed and unsigned type in conditional expression'.
22612         * lib/posixtm.c (posix_time_parse): Likewise.
22613
22614         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
22615
22616         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
22617         to avoid a pedantic warning.
22618
22619         * lib/getstr.c: Don't include assert.h.
22620         (getstr): Remove warning-evoking assertions.
22621         Return -1 if offset parameter is out of bounds.
22622         Change the type of a local from int to size_t.
22623
22624         * lib/strftime.c (my_strftime_localtime_r): Include this function
22625         definition in the `#if ! HAVE_TM_GMTOFF' block.
22626
22627         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
22628         Include xalloc.h instead.
22629
22630 2001-12-02  Jim Meyering  <meyering@lucent.com>
22631
22632         * lib/tempname.c: Don't declare getenv, thus reverting the change of
22633         2001-11-18.  It's no longer necessary, now that stdlib.h is always
22634         included.
22635
22636         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
22637         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
22638
22639 2001-11-30  Akim Demaille  <akim@epita.fr>
22640
22641         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
22642         before being defined.
22643
22644 2001-11-27  Paul Eggert  <eggert@twinsun.com>
22645
22646         * lib/quotearg.h (quotearg_n, quotearg_n_style):
22647         First arg is int, not unsigned.
22648         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
22649         (SIZE_MAX, UINT_MAX): New macros.
22650         (quotearg_n_options): Abort if N is negative.
22651         Avoid overflow check on hosts where size_t is 64 bits and int
22652         is 32 bits, as overflow is impossible there.
22653         Fix off-by-one typo that caused unnecessary reallocation.
22654
22655 2001-11-27  Jim Meyering  <meyering@lucent.com>
22656
22657         * lib/tempname.c: Merge with version from libc.
22658         * lib/regex.c: Likewise.
22659
22660         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
22661         systems for which STDC_HEADERS is 0, it was not included, resulting in
22662         a warning about an integer-to-pointer conversion problem with getenv.
22663         Reported by Volker Borchert.
22664
22665 2001-11-26  Jim Meyering  <meyering@lucent.com>
22666
22667         * lib/gtod.h: Remove file.
22668         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
22669         * lib/gettimeofday.c: Don't include gtod.h.
22670         (GTOD_init): Remove function.
22671         (rpl_gettimeofday): Do its job here instead, rather than aborting.
22672         Suggestion from Volker Borchert.
22673
22674 2001-11-23  Jim Meyering  <meyering@lucent.com>
22675
22676         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
22677         it.
22678         * lib/hash.c (struct hash_table): Define it here instead.
22679
22680 2001-11-22  Jim Meyering  <meyering@lucent.com>
22681
22682         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
22683
22684 2001-11-20  Jim Meyering  <meyering@lucent.com>
22685
22686         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
22687         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
22688
22689 2001-11-19  Jim Meyering  <meyering@lucent.com>
22690
22691         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
22692         directory.  Use "conftestXXXXXX" as the template.
22693         Suggestion from Paul Eggert.
22694
22695         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
22696         immediately, so the test doesn't mistakenly hit the max-open-files
22697         limit.
22698
22699 2001-11-18  Paul Eggert  <eggert@twinsun.com>
22700
22701         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
22702         (TEMPORARIES): New macro.
22703         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
22704         removes an artificial limitation (e.g. HP-UX 10.20, where
22705         TMP_MAX is 17576).
22706
22707 2001-11-18  Jim Meyering  <meyering@lucent.com>
22708
22709         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
22710
22711 2001-11-18  Jim Meyering  <meyering@lucent.com>
22712
22713         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
22714         on SunOS 4.
22715
22716         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
22717         files will be created before anything else.
22718
22719 2001-11-17  Paul Eggert  <eggert@twinsun.com>
22720
22721         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
22722         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
22723
22724 2001-11-17  Jim Meyering  <meyering@lucent.com>
22725
22726         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
22727         Prompted by a report from Bob Proulx.
22728
22729         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
22730         Instead, require UTILS_FUNC_MKSTEMP.
22731
22732 2001-11-17  Jim Meyering  <meyering@lucent.com>
22733
22734         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
22735         Now, that's done as part of AC_FUNC_STRTOD.
22736
22737 2001-11-17  Jim Meyering  <meyering@lucent.com>
22738
22739         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
22740         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
22741         rather than group writable.  Patch by Juan F. Codagnone.
22742
22743         * lib/readtokens.c: Remove explicit declarations of xmalloc and
22744         xrealloc, Instead, include "xalloc.h".
22745
22746         * lib/mountlist.c: Include unlocked-io.h after all system headers.
22747         Remove explicit declarations of xmalloc, xrealloc,
22748         and xstrdup.  Instead, include "xalloc.h".
22749
22750         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
22751         unlocked-io.h.
22752         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
22753         Likewise.
22754         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
22755
22756         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
22757         Reported by Padraig Brady.
22758
22759         * lib/mkstemp.c: #undef mkstemp.
22760         Include config.h.
22761         (rpl_mkstemp): Rename from mkstemp.
22762         Protoize.
22763
22764 2001-11-16  Jim Meyering  <meyering@lucent.com>
22765
22766         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
22767         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
22768         determine the amount of total physical memory, use pstat_getstatic.
22769         HPUX-11 doesn't define _SC_PHYS_PAGES.
22770         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
22771         If sysconf couldn't be used to determine the amount of available
22772         physical memory, use both pstat_getstatic and pstat_getdynamic.
22773         Based on a patch from Bob Proulx.
22774
22775 2001-11-10  Jim Meyering  <meyering@lucent.com>
22776
22777         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
22778         (jm_PREREQ): Use it.
22779
22780 2001-11-09  Jim Meyering  <meyering@lucent.com>
22781
22782         * m4/jm-macros.m4: Require autoconf-2.52f.
22783         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
22784         Use these AC_-prefixed names, not the AM_-prefixed ones.
22785
22786         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
22787
22788 2001-11-05  Jim Meyering  <meyering@lucent.com>
22789
22790         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
22791
22792 2001-11-04  Jim Meyering  <meyering@lucent.com>
22793
22794         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
22795         $DEFS.
22796
22797 2001-11-03  Jim Meyering  <meyering@lucent.com>
22798
22799         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
22800         of AC_DEFUN.
22801
22802         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
22803         know the name of the variable in the macro definition.
22804
22805 2001-11-03  Jim Meyering  <meyering@lucent.com>
22806
22807         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
22808         in argmatch_to_argument call.
22809
22810         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
22811         argument.
22812
22813         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
22814         e.g., a fault due to an attempt to free a NULL pointer.
22815
22816 2001-11-01  Jim Meyering  <meyering@lucent.com>
22817
22818         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
22819         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
22820
22821 2001-11-01  Jim Meyering  <meyering@lucent.com>
22822
22823         * lib/dirfd.c, lib/dirfd.h: New files.
22824         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
22825
22826         * lib/hash.c (hash_print) [TESTING]: Clean up.
22827
22828 2001-10-22  Paul Eggert  <eggert@twinsun.com>
22829
22830         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
22831         to avoid a warning if -Wall.
22832
22833 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
22834
22835         * README: New file
22836         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
22837         (per RMS's instructions, this is now the canonical source)
22838         * lgpl/, gpl/: New directories.
22839
22840 2001-10-21  Paul Eggert  <eggert@twinsun.com>
22841
22842         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
22843
22844 2001-10-21  Jim Meyering  <meyering@lucent.com>
22845
22846         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
22847         this code would end up calling gettext even in packages built
22848         with --disable-nls.
22849         * lib/getopt.c (_): Likewise.
22850         * lib/regex.c (_): Likewise.
22851
22852 2001-10-20  Paul Eggert  <eggert@twinsun.com>
22853
22854         * m4/error.m4 (jm_PREREQ_ERROR):
22855         Do not invoke AC_CHECK_FUNCS with strerror_r, as
22856         AC_FUNC_STRERROR_R does that.
22857         Check for strerror declaration.
22858
22859         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
22860         are supposed to have them these days.
22861         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
22862         Merge changes from latest Autoconf CVS.
22863         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
22864         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
22865         POSIX decided to standardize on the int flavor of strerror_r.
22866
22867 2001-10-20  Paul Eggert  <eggert@twinsun.com>
22868
22869         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
22870         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
22871         Use strerror_r that is only a macro, even if it is not a function.
22872         (strerror): Check for HAVE_DECL_STRERROR before declaring.
22873         (private_strerror): Use prototypes, not old-style function definition.
22874         (print_errno_message): New function.
22875         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
22876         char*-flavored one.
22877         (error_tail, error, error_at_line): Use it.
22878
22879 2001-10-11  Jim Meyering  <meyering@lucent.com>
22880
22881         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
22882         and quote_n (1, ... to avoid clobbering a buffer.
22883
22884 2001-10-05  Jim Meyering  <meyering@lucent.com>
22885
22886         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
22887         hash-pjw.h.
22888         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
22889         * lib/hash-pjw.h: New file.
22890
22891 2001-09-30  Jim Meyering  <meyering@lucent.com>
22892
22893         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
22894         `struct fsstat' has the `f_fstypename' member.
22895         Use that to define FS_TYPE, which is now used to make
22896         the getfsstat link test tighter.
22897
22898 2001-09-30  Jim Meyering  <meyering@lucent.com>
22899
22900         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
22901         Include <sys/ucred.h>, for Apple Darwin.
22902         Include sys/mount.h and sys/fs_types.h only if available.
22903         (FS_TYPE): Define.
22904         (read_filesystem_list): Use FS_TYPE.
22905
22906 2001-09-29  Paul Eggert  <eggert@twinsun.com>
22907
22908         * lib/exclude.c (excluded_filename): 0 -> false, since it's
22909         a boolean context.
22910
22911 2001-09-29  Jim Meyering  <meyering@lucent.com>
22912
22913         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
22914         [one-argument getmntent function]): Include stdio.h before mntent.h.
22915         SunOS 4.1.x needs it for the declaration of `FILE'.
22916         Patch by Volker Borchert.
22917
22918         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
22919         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
22920         sys/fs_types.h, and make the link-test for getfsstat guard #include
22921         directives with appropriate #if HAVE_*_H tests so that we can
22922         detect getfsstat on Apple Darwin1.3.7 systems.
22923         Reported by Nelson Beebe.
22924         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
22925
22926 2001-09-28  Paul Eggert  <eggert@twinsun.com>
22927
22928         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
22929         #defines strtoimax.  Also treat the other strto* functions
22930         like strtoimax.
22931
22932         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
22933         Check for strtoul and strtoumax,
22934         as those declarations are made even in the signed case.
22935         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
22936         Likewise, for strtol and strtoimax.
22937
22938 2001-09-28  Paul Eggert  <eggert@twinsun.com>
22939
22940         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
22941         #defines strtoimax.  Also treat the other strto* functions
22942         like strtoimax.
22943
22944         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
22945         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
22946         (strtoimax, strtoumax): Do not declare if already defined as a macro.
22947
22948 2001-09-26  Jim Meyering  <meyering@lucent.com>
22949
22950         Most macros in unlocked-io.h had the wrong number of arguments.
22951         * lib/gen-uio: New script.
22952         (USE_UNLOCKED_IO): Define to 1 if not already defined.
22953         * lib/unlocked-io.hin: Remove file.
22954         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
22955         rather than trying to embed it here.
22956         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
22957         Reported by Padraig Brady.
22958
22959 2001-09-25  Volker Borchert  <bt@teknon.de>
22960
22961         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
22962         `result'.
22963
22964 2001-09-24  Jim Meyering  <meyering@lucent.com>
22965
22966         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
22967
22968 2001-09-23  Jim Meyering  <meyering@lucent.com>
22969
22970         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
22971         instead of the mere test for existence of mntent.h.  The latter
22972         would get a false-positive on AIX 3.4 systems.
22973         In the outer getmntent if-block, don't die if neither of the getmntent
22974         tests succeeds.  Instead, just fall through and continue with the
22975         remaining tests.
22976
22977 2001-09-23  Jim Meyering  <meyering@lucent.com>
22978
22979         * lib/mountlist.c: Remove useless parentheses in #if directives.
22980         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
22981         the deprecated MOUNTED symbol is no longer defined in mntent.h.
22982
22983 2001-09-22  Jim Meyering  <meyering@lucent.com>
22984
22985         * m4/gettext.m4: New file.  From gettext.
22986         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
22987         * m4/progtest.m4: Likewise
22988         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
22989         * m4/glibc21.m4: Likewise.
22990
22991         * m4/libintl.m4: Remove.  No longer used.
22992
22993 2001-09-22  Jim Meyering  <meyering@lucent.com>
22994
22995         * lib/localcharset.c: Update from latest gettext.
22996         * lib/config.charset: Likewise.
22997
22998 2001-09-20  Jim Meyering  <meyering@lucent.com>
22999
23000         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
23001         strtoimax.
23002         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
23003         strtoumax.
23004
23005 2001-09-20  Jim Meyering  <meyering@lucent.com>
23006
23007         * lib/xstrtol.c (strtoimax): Guard declaration with
23008         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
23009         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
23010         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
23011         (strtoumax): Likewise, for completeness (it wasn't necessary).
23012
23013 2001-09-17  Paul Eggert  <eggert@twinsun.com>
23014
23015         * lib/strtoimax.c (HAVE_LONG_LONG):
23016         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
23017         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
23018         to work around bug in IBM C compiler.
23019
23020 2001-09-17  Jim Meyering  <meyering@lucent.com>
23021
23022         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
23023         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
23024         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
23025         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
23026         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
23027         whenever the right hand side need not be expanded by the shell.
23028
23029 2001-09-16  Paul Eggert  <eggert@twinsun.com>
23030
23031         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
23032         library.  It's not correct, as some older glibcs are buggy.
23033         fnmatch wasn't fixed until glibc 2.2.
23034
23035         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
23036         special shell magic here.
23037
23038 2001-09-16  Jim Meyering  <meyering@lucent.com>
23039
23040         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
23041         * m4/jm-macros.m4: Require it.
23042
23043 2001-09-16  Jim Meyering  <meyering@lucent.com>
23044
23045         * lib/mkdir.c: New file.
23046
23047 2001-09-15  Jim Meyering  <meyering@lucent.com>
23048
23049         * m4/jm-macros.m4: Check for help2man.
23050
23051 2001-09-11  Jim Meyering  <meyering@lucent.com>
23052
23053         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
23054         The body, by Paul Eggert, was moved here from configure.in.
23055         * m4/jm-macros.m4: Require UTILS_HOST_OS.
23056
23057 2001-09-04  Paul Eggert  <eggert@twinsun.com>
23058
23059         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
23060         (jm_PREREQ): Use it.
23061
23062 2001-09-04  Paul Eggert  <eggert@twinsun.com>
23063
23064         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
23065         Use ssize_t, not int, to store result of readlink.
23066         Check for ssize_t overflow as well as size_t overflow,
23067         as POSIX says the result of readlink is implementation-defined
23068         when ssize_t overflows.
23069         Remove unnecessary cast to char*.
23070         Use free+malloc instead of realloc, as the storage doesn't need
23071         to be preserved and it's clearer and can be more efficient that way.
23072         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
23073         * lib/xreadlink.h (xreadlink): Update prototype.
23074
23075 2001-09-04  Paul Eggert  <eggert@twinsun.com>
23076
23077         * lib/xgetcwd.c: Revert some of the previous change; intead,
23078         fix the HAVE_GETCWD_NULL code to behave more like the
23079         !HAVE_GETCWD_NULL code used to.
23080
23081         Include "xalloc.h".
23082         (xgetcwd): Do not return NULL when memory is exhausted; instead,
23083         invoke xalloc_die.
23084
23085 2001-09-03  Paul Eggert  <eggert@twinsun.com>
23086
23087         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
23088         sys/param.h, as pathmax.h includes them.
23089
23090 2001-09-03  Paul Eggert  <eggert@twinsun.com>
23091
23092         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
23093         (jm_PREREQ_XGETCWD): New macro.
23094
23095         * m4/getcwd.m4: New file.
23096
23097 2001-09-03  Paul Eggert  <eggert@twinsun.com>
23098
23099         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
23100         like the HAVE_GETCWD_NULL code.
23101         Include pathmax.h if not HAVE_GETCWD.
23102         Do not include xalloc.h.
23103         (INITIAL_BUFFER_SIZE): New symbol.
23104         Do not use xmalloc / xrealloc, since the caller is responsible for
23105         handling errors.  Preserve errno around `free' during failure.
23106         Do not overrun buffer when using getwd.
23107
23108 2001-09-03  Paul Eggert  <eggert@twinsun.com>
23109
23110         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
23111         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
23112         getcwd (NULL, 0).
23113
23114 2001-09-03  Paul Eggert  <eggert@twinsun.com>
23115
23116         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
23117         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
23118         spotted by Jim Meyering.
23119
23120 2001-09-03  Jim Meyering  <meyering@lucent.com>
23121
23122         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
23123         failure.
23124
23125 2001-09-02  Jim Meyering  <meyering@lucent.com>
23126
23127         * lib/error.c: Update from GNU libc.
23128
23129 2001-09-01  Jim Meyering  <meyering@lucent.com>
23130
23131         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
23132         Used by df.
23133
23134 2001-09-01  Jim Meyering  <meyering@lucent.com>
23135
23136         * lib/xreadlink.c: New file.
23137         * lib/xreadlink.h: New file.
23138         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
23139         xreadlink.h.
23140
23141         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
23142         doesn't conflict with sparc Solaris 7's definition in
23143         /usr/include/sys/int_types.h.
23144
23145         * lib/exclude.c: Use `""', not `<>' to #include non-system header
23146         files.
23147         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
23148         and strncasecmp as r-values.  Unixware didn't have declarations.
23149
23150 2001-08-31  Paul Eggert  <eggert@twinsun.com>
23151
23152         * lib/xstrtol.h: Add copyright notice.
23153         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
23154         LONGINT_INVALID_SUFFIX_CHAR.
23155
23156 2001-08-31  Paul Eggert  <eggert@twinsun.com>
23157
23158         * lib/xstrtol.c (strtoimax): New decl.
23159
23160 2001-08-31  Paul Eggert  <eggert@twinsun.com>
23161
23162         * lib/xgetcwd.c: Don't include pathmax.h.
23163         Include stdlib.h and unistd.h if available.
23164         Include xalloc.h.
23165         (xmalloc, xstrdup, free): Remove decls.
23166         (xgetcwd): Don't assume sizes fit in unsigned.
23167         Check for overflow when computing sizes.
23168         Simplify reallocation code.
23169
23170 2001-08-31  Paul Eggert  <eggert@twinsun.com>
23171
23172         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
23173         a directory's st_size can have an arbitrary value, so the old
23174         usage could waste an arbitrary amount of memory.  All uses
23175         changed.
23176         * lib/savedir.h: Update prototype.
23177
23178 2001-08-31  Paul Eggert  <eggert@twinsun.com>
23179
23180         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
23181
23182         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
23183         old strtoimax.c.
23184
23185         Also, make the following further changes to make this file's
23186         configuration more similar to that of strtol.c:
23187         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
23188         (strtoumax, uintmax_t, strtoull, strtol): Remove.
23189         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
23190         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
23191         changed to signed values.
23192
23193         And make the following changes as well:
23194         Fix copyright notice, as 1999 was missing.
23195         (verify): New macro.
23196         (strtoimax): Check sizes at compile-time, not run-time.
23197         Prefer strtol to strtoll if both work.
23198         (main): Remove; it was not that useful and was a pain to maintain.
23199
23200         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
23201
23202 2001-08-31  Jim Meyering  <meyering@lucent.com>
23203
23204         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
23205         Use an initial, malloc'd, buffer of length 128 rather than
23206         a statically allocated one of length 1024.
23207
23208 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23209
23210         Simplify code, partly by assuming autoconf 2.52 semantics.
23211
23212         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
23213
23214         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
23215         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
23216         All uses removed.
23217         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
23218         Move AC_REQUIRE to next-to-top level, to avoid confusion.
23219         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
23220         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
23221         jm_AC_HEADER_INTTYPES_H.
23222         * m4/jm-macros.m4 (jm_MACROS): Likewise.
23223
23224         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
23225
23226         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
23227         Quote first arg of AC_DEFUN.
23228         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
23229         since they are needed to parse the include file even if we need
23230         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
23231         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
23232         but with opposite signedness.
23233
23234 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23235
23236         Merge 'exclude' changes from tar 1.13.22.
23237         This fixes one or two unlikely storage allocation overflow bugs,
23238         but doesn't change user-visible behavior otherwise.
23239
23240 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23241
23242         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
23243         (jm_PREREQ_EXCLUDE): New macro.
23244
23245 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23246
23247         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
23248         tm to be declared.
23249
23250 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23251
23252         * lib/hash.c: Remove '2001' from copyright notice.
23253
23254 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23255
23256         * lib/full-write.h: New file.
23257         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
23258         * lib/full-write.c: Correct credits, as cccp.c no longer
23259         exists and anyway it was so heavily changed from the old cccp
23260         code as to be unrecognizable.  Include full-write.h.
23261         (full_write) Return size_t, with short writes meaning failure.
23262         All callers changed.  This fixes a bug with large buffers
23263         on 64-bit hosts.
23264         * lib/utime.c: Include full-write.h.
23265
23266 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23267
23268         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
23269         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
23270         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
23271         Include if available.
23272         (<xalloc.h>): Include
23273         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
23274         (verify): New macro.  Use it to verify that EXCLUDE macros do not
23275         collide with FNM macros.
23276         (struct patopts): New struct.
23277         (struct exclude): Use it, as exclude patterns now come with options.
23278         (new_exclude): Support above changes.
23279         (new_exclude, add_exclude_file):
23280         Initial size must now be a power of two to simplify overflow checking.
23281         (free_exclude, fnmatch_no_wildcards): New function.
23282         (excluded_filename): No longer requires options arg, as the options
23283         are determined by add_exclude.  Now returns bool, not int.
23284         (excluded_filename, add_exclude):
23285         Add support for the fancy new exclusion options.
23286         (add_exclude, add_exclude_file): Now takes int options arg.
23287         Check for arithmetic overflow when computing sizes.
23288         (add_exclude_file): xrealloc might modify errno, so don't
23289         realloc until after errno might be used.
23290
23291         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
23292         New macros.
23293         (free_exclude): New decl.
23294         (add_exclude, add_exclude_file): Now takes int options arg.
23295         (excluded_filename): No longer requires options arg, as the options
23296         are determined by add_exclude.  Now returns bool, not int.
23297
23298 2001-08-30  Paul Eggert  <eggert@twinsun.com>
23299
23300         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
23301
23302 2001-08-27  Jim Meyering  <meyering@lucent.com>
23303
23304         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
23305
23306         * lib/version-etc.c (N_): Remove definition.
23307         Revert most of last change.
23308         Instead, simply don't mark the `Copyright...' string for translation.
23309         Based on advice from Paul Eggert.
23310
23311         * lib/strtoxmax.c: Tweak comment.
23312
23313 2001-08-26  Jim Meyering  <meyering@lucent.com>
23314
23315         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
23316
23317         * m4/xstrtoimax.m4: New file.
23318         * m4/xstrtoumax.m4: Add comments explaining why we
23319         AC_REPLACE_FUNCS(strtol).
23320
23321 2001-08-26  Jim Meyering  <meyering@lucent.com>
23322
23323         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
23324         of copyright with `%s' so translators don't get an untranslated
23325         message in 2002.
23326         (COPYRIGHT_YEAR): Define.
23327         (version_etc): Use fprintf rather than fputs.
23328         Suggestion from Ulrich Drepper.
23329
23330         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
23331
23332         * lib/strtoll.c: New file, from GNU libc.
23333         * lib/xstrtoimax.c: New file.
23334
23335         * lib/xstrtol.h: Add xstrtoimax.
23336         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
23337         * lib/strtoimax.c: New file.  Likewise, but first define
23338         STRTOUXMAX_SIGNED.
23339
23340         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
23341         ...
23342         * lib/strtoxmax.c: ... then renamed to this.
23343
23344 2001-08-18  Paul Eggert  <eggert@twinsun.com>
23345
23346         * m4/inttypes.m4: Add AC_PREREQ(2.13).
23347         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
23348         (jm_AC_TYPE_INTMAX_T): New macro.
23349         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
23350
23351         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
23352
23353         * m4/longlong.m4: Renamed from ulonglong.m4.
23354         * m4/inttypes.m4: Renamed from inttypes_h.m4.
23355         * m4/uintmax_t.m4: Removed.
23356
23357 2001-08-13  Paul Eggert  <eggert@twinsun.com>
23358
23359         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
23360         Port to Solaris 8, where 'sed' requires a space after the 'r'
23361         command, and where sh dislikes "$/".  Clean up the spacing a bit.
23362         Redirect output to $tmp just once.
23363
23364 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
23365
23366         * lib/addext.c (<errno.h>): Include.
23367         (errno): Declare if not defined.
23368         (addext): Work correctly when pathconf returns -1 and leaves
23369         errno alone because there is no limit.  Also, work even if
23370         pathconf returns a value greater than SIZE_MAX.
23371
23372 2001-08-12  Jim Meyering  <meyering@lucent.com>
23373
23374         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
23375         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
23376         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
23377         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
23378         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
23379         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
23380         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
23381         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
23382         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
23383         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
23384         utime.m4, utimes.m4, xstrtoumax.m4:
23385         Quote the first argument in each use of AC_DEFUN.
23386
23387 2001-08-12  Jim Meyering  <meyering@lucent.com>
23388
23389         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
23390         Simply `return getcwd (NULL, 0);'.
23391         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
23392         Use 1300 as initial value for length, not PATH_MAX.
23393
23394         * lib/pathmax.h: Clean up cpp syntax.
23395
23396 2001-08-12  Jim Meyering  <meyering@lucent.com>
23397
23398         * lib/gettimeofday.c: New file.
23399         * lib/gtod.h: New file.
23400         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
23401
23402 2001-08-05  Jim Meyering  <meyering@lucent.com>
23403
23404         * m4/jm-macros.m4: Require autoconf-2.52.
23405
23406 2001-08-04  Jim Meyering  <meyering@lucent.com>
23407
23408         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
23409         stmt, to get in sync with glibc.
23410
23411 2001-08-03  Paul Eggert  <eggert@twinsun.com>
23412
23413         The following changes are from gettext 0.10.39 as maintained by
23414         Bruno Haible.
23415
23416         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
23417         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
23418         with inverted sense.  All uses changed.
23419
23420         * lib/mbswidth.c: Don't include <limits.h>.
23421         Include <stdlib.h> and <string.h> unconditionally.
23422         (iswcntrl, mbsinit, ISCNTRL): New macros.
23423         (mbsnwidth): Use K&R style function declarations.
23424         Don't bother checking for MB_LEN_MAX == 1, since the compiler
23425         can optimize it when MB_CUR_MAX == 1.
23426         The width of control characters is zero, not 1.
23427
23428 2001-08-03  Paul Eggert  <eggert@twinsun.com>
23429
23430         The following changes are from gettext 0.10.39 as maintained by
23431         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
23432
23433         * m4/codeset.m4: Upgrade to serial AM1.
23434         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
23435         all uses changed.  Quote first arg of AC_DEFUN.
23436         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
23437
23438         * m4/iconv.m4: Upgrade to serial AM2.
23439         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
23440         Add --with-libconv-prefix.
23441         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
23442         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
23443         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
23444         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
23445         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
23446
23447         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
23448         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
23449         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
23450         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
23451         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
23452         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
23453         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
23454         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
23455         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
23456
23457         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
23458         string.h any more.
23459
23460         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
23461         not the default value.
23462
23463         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
23464         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
23465         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
23466         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
23467         Also check for iswcntrl, used for wcwidth fallback.
23468         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
23469         to Autoconf 2.13.
23470
23471 2001-08-03  Jim Meyering  <meyering@lucent.com>
23472
23473         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
23474         as it was in the original.  Reported by Paul Eggert.
23475
23476 2001-07-16  Jim Meyering  <meyering@lucent.com>
23477
23478         * m4/gettimeofday.m4: New file.
23479         Prompted by a report from Bernhard Baehr.
23480
23481 2001-07-15  Jim Meyering  <meyering@lucent.com>
23482
23483         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
23484         stuff. Now it's in ../Makefile.cfg.
23485
23486 2001-07-15  Jim Meyering  <meyering@lucent.com>
23487
23488         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
23489         (BUILT_SOURCES): Add unlocked-io.h.
23490         (io_functions): Define.
23491         (unlocked-io.h): New rule.
23492         (DISTCLEANFILES): Add unlocked-io.h.
23493         (all-local): Depend on unlocked-io.h, to ensure it is created.
23494
23495         * lib/unlocked-io.hin: New file
23496
23497         * lib/regex.c: Update from glibc.
23498
23499 2001-07-05  Jim Meyering  <meyering@lucent.com>
23500
23501         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
23502         recommendation.
23503         (libfetish_a_SOURCES): Put all .h files here instead.
23504         Remove a thus-exposed (better checks in automake) duplicate and
23505         two unnecessary .h files.
23506
23507 2001-07-04  Jim Meyering  <meyering@lucent.com>
23508
23509         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
23510         that generates jm-glibc-io.m4 so that it doesn't trigger any make
23511         distcheck failure.
23512
23513 2001-07-02  Jim Meyering  <meyering@lucent.com>
23514
23515         The following changes were prompted by suggestions from Bruno Haible.
23516
23517         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
23518         is now generated.
23519         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
23520         definition of EXTRA_DIST.
23521         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
23522         ensure that the generated file is created/updated whenever the list
23523         of $(unlocked_functions) is changed.
23524         (jm-glibc-io.m4): New rule.
23525         (unlocked-io.h): New rule -- currently unused.
23526
23527 2001-06-24  Jim Meyering  <meyering@lucent.com>
23528
23529         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
23530         unmatched right bracket, rather than kludging it with an extra,
23531         falsely-matching quote in a comment.  Patch by Akim Demaille.
23532
23533 2001-06-11  Jim Meyering  <meyering@lucent.com>
23534
23535         * lib/regex.c: Update from GNU libc.
23536
23537 2001-05-27  Jim Meyering  <meyering@lucent.com>
23538
23539         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
23540         Check for ut_type in struct utmp.
23541
23542 2001-05-27  Jim Meyering  <meyering@lucent.com>
23543
23544         * lib/readutmp.h (UT_TYPE): Define.
23545
23546 2001-05-24  Jim Meyering  <meyering@lucent.com>
23547
23548         * lib/argmatch.c: Include "quote.h".
23549         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
23550         quote function.  Reported by Göran Uddeborg.
23551
23552 2001-05-22  Jim Meyering  <meyering@lucent.com>
23553
23554         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
23555         now that we use the package-supplied version unconditionally.
23556         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
23557
23558 2001-05-21  Jim Meyering  <meyering@lucent.com>
23559
23560         * m4/regex.m4: Change a couple backticks to single quotes to avoid
23561         shell syntax errors.
23562
23563 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
23564
23565         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
23566
23567 2001-05-20  Paul Eggert  <eggert@twinsun.com>
23568
23569         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
23570         Don't bother to check library strftime, since
23571         we'll be using our own my_strftime function anyway.
23572         Define my_strftime instead of strftime.
23573
23574 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
23575
23576         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
23577         which is not yet declared.
23578
23579 2001-05-15  Jim Meyering  <meyering@lucent.com>
23580
23581         * m4/regex.m4: Use proper quoting so brackets appear in the test
23582         program.
23583         Reported by, and with help from, Bruno Haible.
23584
23585 2001-05-13  Jim Meyering  <meyering@lucent.com>
23586
23587         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
23588         undefined.
23589
23590 2001-05-11  Paul Eggert  <eggert@twinsun.com>
23591
23592         dirname code cleanup.  base_name now behaves more compatibly
23593         with POSIX basename when given file names that have trailing
23594         slashes, and similarly for dir_name.  Add new primitives
23595         base_len and dir_len.  Put the directory-name-related decls
23596         into dirname.h.
23597
23598         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
23599         * lib/backupfile.c (base_name): Likewise.
23600         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
23601         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
23602         * lib/makepath.c (strip_trailing_slashes): Likewise.
23603         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
23604         ISSLASH): Likewise.
23605         * lib/rename.c (strip_trailing_slashes): Likewise.
23606         * lib/same.c (base_name): Likewise.
23607         * lib/stripslash.c (ISSLASH): Likewise.
23608
23609         * lib/addext.c: Include <dirname.h> after size_t is defined.
23610         * lib/backupfile.c: Likewise.
23611
23612         * lib/addext.c (addext): Use base_len to trim redundant
23613         trailing slashes instead of doing it ourselves.
23614         But do not trim the last slash if it is not redundant.
23615
23616         * lib/backupfile.c (find_backup_file_name,
23617         max_backup_version): Use base_len instead of rolling it ourselves.
23618         Handle the case of "" and (on DOS) "C:" correctly.
23619
23620         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
23621         needed. Include <string.h>, <dirname.h>.
23622         (base_name): Allow file names ending in slashes, other than names
23623         that are all slashes.  In this case, return the basename followed
23624         by the slashes.  This is more general, and can be used in places
23625         where the original base_name purposely had an assertion failure.
23626         (base_len): New function.
23627
23628         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
23629         Do not include <assert.h>; no longer needed.
23630         Include xalloc.h.
23631         (memrchr): Remove decl.
23632         (dir_name_r): Remove.
23633         (dir_len): Renamed from dirlen.  All callers changed.
23634         Rewrite in terms of base_name, for simplicity and consistency.
23635         (dir_name): Never return NULL.  All callers changed.
23636         Do not include <stdlib.h> in test program; no longer needed.
23637         return 0; is fine for test program.
23638
23639         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
23640         New macros.
23641         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
23642
23643         * lib/path-concat.c (path_concat): Use base_len to compute
23644         base length, not strlen; this means we cannot rely on memcpy
23645         to null-terminate.
23646
23647         * lib/same.c (STREQ): Remove.
23648         (same_name): Handle the case where the basename ends in trailing '/'.
23649
23650         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
23651         a slash was stripped.  Do not strip the last slash after a
23652         file system prefix.
23653
23654 2001-05-11  Paul Eggert  <eggert@twinsun.com>
23655
23656         * lib/Makefile.am (libfetish_a_SOURCES):
23657         Add strftime.c, since we now compile it on all hosts.
23658
23659         * lib/strftime.c (my_strftime):
23660         Define to nstrftime if emacs, but only if my_strftime is not defined.
23661         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
23662         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
23663         Add one more extra argument: a nanoseconds value.
23664         All uses changed.
23665         (ns): New macro.
23666         (my_strftime function): Add %N format.
23667         (emacs_strftimeu): Renamed from emacs_strftime,
23668         with extra ut argument.
23669
23670 2001-05-09  Paul Eggert  <eggert@twinsun.com>
23671
23672         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
23673
23674 2001-04-21  Jim Meyering  <meyering@lucent.com>
23675
23676         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
23677         doesn't interfere.
23678
23679 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
23680
23681         * m4/ftruncate.m4: Check for chsize.
23682         Link with ftruncate.o unconditionally if ftruncate is missing.
23683         This was required when cross-compiling to i586-mingw32msvc.
23684
23685 2001-04-08  Jim Meyering  <meyering@lucent.com>
23686
23687         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
23688         recomputed; that's necessary when the offset spans a DST transition.
23689         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
23690
23691 2001-04-02  Jim Meyering  <meyering@lucent.com>
23692
23693         * lib/regex.h, regex.c: Update from GNU libc.
23694
23695 2001-03-24  Jim Meyering  <meyering@lucent.com>
23696
23697         * m4/jm-macros.m4: Require autoconf-2.49d.
23698
23699 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
23700
23701         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
23702
23703 2001-03-19  Paul Eggert  <eggert@twinsun.com>
23704
23705         * lib/version-etc.c (version_etc_copyright): Update to 2001.
23706
23707 2001-03-17  Jim Meyering  <meyering@lucent.com>
23708
23709         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
23710         now that the version in autoconf is equivalent.
23711         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
23712
23713         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
23714         Suggestion from Akim Demaille.
23715
23716         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
23717         (jm_PREREQ_TEMPNAME): New function.
23718
23719 2001-03-16  Paul Eggert  <eggert@twinsun.com>
23720
23721         * lib/tempname.c (uint64_t): Define to uintmax_t if
23722         not defined, and if UINT64_MAX is not defined.
23723         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
23724         Reported by John David Anglin.
23725
23726 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
23727
23728         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
23729         resolve alias if codeset is empty.
23730         * lib/config.charset (BeOS): Use wildcard syntax.
23731
23732 2001-03-13  Jim Meyering  <meyering@lucent.com>
23733
23734         * lib/path-concat.c (path_concat)
23735         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
23736         concatenating e.g., `C:' and `foo'.
23737         From Bruno Haible.
23738
23739 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
23740
23741         * lib/localcharset.c (locale_charset): Don't use
23742         setlocale(LC_CTYPE,NULL). Don't return NULL.
23743         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
23744
23745 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
23746
23747         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
23748         support for DOS/DJGPP.
23749
23750 2001-03-01  Paul Eggert  <eggert@twinsun.com>
23751
23752         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
23753         lacks mkstemp.  Compile our own tempname.c if we compile our own
23754         mkstemp.c, as mkstemp relies on tempname.
23755
23756 2001-03-01  Jim Meyering  <meyering@lucent.com>
23757
23758         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
23759         AH_VERBATIM really does output its argument verbatim.
23760
23761 2001-02-28  Paul Eggert  <eggert@twinsun.com>
23762
23763         * lib/Makefile.am (libfetish_a_SOURCES):
23764         Add dup-safer.c, fopen-safer.c.
23765         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
23766
23767         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
23768         * lib/unistd-safer.h: New files.
23769
23770 2001-02-25  Paul Eggert  <eggert@twinsun.com>
23771
23772         The mkstemp replacement is taken from glibc 2.2.2, with some
23773         portability fixes for use outside glibc, as follows:
23774
23775         * lib/tempname.c (struct_stat64): New macro.
23776         (direxists, __gen_tempname): Use it.
23777         This avoids a portability problem with Solaris 8.
23778
23779         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
23780         (<stddef.h>, <stdint.h>, <string.h>):
23781         Include only if STDC_HEADERS || _LIBC.
23782         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
23783         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
23784         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
23785         (__set_errno): Define this macro if <errno.h> doesn't.
23786         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
23787         Define these macros if <stdio.h> doesn't.
23788         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
23789         Define these macros if <sys/stat.h>
23790         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
23791         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
23792         __xstat64): Define if not _LIBC.
23793         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
23794         (__gen_tempname): Invoke gettimeofday only if
23795         HAVE_GETTIMEOFDAY || _LIBC;
23796         otherwise, fall back on plain "time".
23797         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
23798
23799         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
23800
23801         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
23802
23803 2001-02-18  Paul Eggert  <eggert@twinsun.com>
23804
23805         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
23806
23807 2001-02-17  Paul Eggert  <eggert@twinsun.com>
23808
23809         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
23810         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
23811         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
23812         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
23813
23814 2001-02-17  Paul Eggert  <eggert@twinsun.com>
23815
23816         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
23817         Remove workaround macros for hosts that have mbrtowc but not
23818         mbstate_t, as we now insist on proper declarations for both
23819         before using mbrtowc.
23820
23821 2001-02-17  Jim Meyering  <meyering@lucent.com>
23822
23823         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
23824         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
23825         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
23826         UnixWare 7.1.1.
23827
23828         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
23829         rather than AC_CACHE_VAL.
23830
23831 2001-02-17  Jim Meyering  <meyering@lucent.com>
23832
23833         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
23834         around included file name.
23835
23836         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
23837
23838         * lib/strftime.c: Update from GNU libc (the only changes were to
23839         comments).
23840
23841 2001-02-17  Jim Meyering  <meyering@lucent.com>
23842
23843         * lib/regex.c: Update from libc.
23844
23845 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
23846
23847         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
23848         clash.
23849
23850 2001-02-16  Paul Eggert  <eggert@twinsun.com>
23851
23852         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
23853         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
23854         Reported by Mark Hounschell via Paul Eggert.
23855
23856 2001-02-07  Jim Meyering  <meyering@lucent.com>
23857
23858         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
23859
23860 2001-02-05  Jim Meyering  <meyering@lucent.com>
23861
23862         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
23863         it includes the patch required for `large file' support with at least
23864         HP-UX's 10.20 /bin/cc.
23865
23866 2001-02-03  Jim Meyering  <meyering@lucent.com>
23867
23868         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
23869         AS_IF, now that it works once again (mysteriously).
23870         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
23871
23872 2001-01-30  Jim Meyering  <meyering@lucent.com>
23873
23874         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
23875         * m4/chown.m4: Rename conftestchown to conftest.chown.
23876         * m4/rename.m4: s/conftestdir/conftest.d1/ and
23877         s/conftestdir2/conftest.d2/.
23878         * m4/utimes.m4: s/conftestdata/conftest.data/
23879         Inspired by Pavel Roskin's change in autoconf.
23880
23881 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
23882
23883         * lib/config.charset: Update for FreeBSD 4.2.
23884
23885 2001-01-27  Jim Meyering  <meyering@lucent.com>
23886
23887         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
23888         a use of AS_IF.
23889         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
23890
23891 2001-01-26  Jim Meyering  <meyering@lucent.com>
23892
23893         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
23894         quotearg.c includes it.
23895
23896 2001-01-26  Jim Meyering  <meyering@lucent.com>
23897
23898         * lib/quotearg.c: Include stddef.h.
23899         * lib/quote.c: Include stddef.h.
23900         Reported by Axel Kittenberger.
23901
23902         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
23903         line in double quotes so that it evokes a better diagnostic.
23904         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
23905         Reported by Axel Kittenberger.
23906
23907 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
23908
23909         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
23910         as if it was a `charset'.
23911
23912 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
23913
23914         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
23915         has const.
23916
23917 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
23918
23919         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
23920         to avoid a warning.  Add back 'const' to inptr.
23921
23922 2001-01-20  Jim Meyering  <meyering@lucent.com>
23923
23924         Be sure that headers are checked before used in code compiled
23925         for the type checks.
23926         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
23927         In place of that, invoke jm_CHECK_ALL_TYPES.
23928         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
23929         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
23930         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
23931         The check for ssize_t was mistakenly run before the test for unistd.h.
23932
23933         The configure-time check for stdbool.h was missing.
23934         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
23935         (jm_PREREQ_HASH): New function.
23936
23937 2001-01-17  Jim Meyering  <meyering@lucent.com>
23938
23939         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
23940         for autoconf-2.49c.
23941         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
23942
23943 2001-01-16  Jim Meyering  <meyering@lucent.com>
23944
23945         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
23946         From Bruno Haible.
23947
23948 2001-01-14  Jim Meyering  <meyering@lucent.com>
23949
23950         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
23951         foo and bar.  Create conftestdir/ in the script, not in the C code.
23952         Remove directories in the script, not in the C code.
23953         Remove conftestdir{,2} before trying to create the directory.
23954         Make the entire configure script fail if the mkdir fails.
23955
23956 2001-01-14  Jim Meyering  <meyering@lucent.com>
23957
23958         * lib/rename.c: New file.  From Volker Borchert.
23959         Include stdlib.h, string.h or strings.h, and xalloc.h.
23960         Use strip_trailing_slashes rather than open-coding it.
23961
23962 2001-01-03  Paul Eggert  <eggert@twinsun.com>
23963
23964         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
23965
23966 2001-01-03  Jim Meyering  <meyering@lucent.com>
23967
23968         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
23969         of local `inptr' to avoid warning with some system declarations of
23970         iconv.
23971
23972 2001-01-02  Volker Borchert  <bt@teknon.de>
23973
23974         * m4/rename.m4: New file.
23975         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
23976
23977 2001-01-01  Jim Meyering  <meyering@lucent.com>
23978
23979         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
23980         even on systems with utmpx.h.  It's necessary for the declaration of
23981         utmp's ut_user member.  Reported by Andreas Jaeger.
23982
23983         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
23984         available. They are required for the declarations of getgrgid and
23985         getpwuid resp.
23986         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
23987         Reported by Andreas Jaeger.
23988
23989 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
23990
23991         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
23992         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
23993         so `make install' also works in VPATH builds.
23994
23995 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
23996
23997         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
23998         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
23999         can be used in subdirectories.
24000
24001 2000-12-29  Paul Eggert  <eggert@twinsun.com>
24002
24003         * lib/modechange.c: Do not assume that mode_t uses the
24004         traditional octal encoding.  E.g. "chmod 1 FOO" should set
24005         the other-execute bit of FOO even if S_IXOTH != 1.
24006
24007         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
24008         WOTH, XOTH, ALLM): New macros.
24009         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
24010          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
24011         Use them.
24012         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
24013         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
24014         (mode_compile):
24015         No need to use uintmax_t; unsigned long is long enough.
24016         Don't bother to get suffix since we don't use it.
24017
24018 2000-12-26  Jim Meyering  <meyering@lucent.com>
24019
24020         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
24021         better with autoheader.
24022
24023 2000-12-24  Jim Meyering  <meyering@lucent.com>
24024
24025         * lib/hash.c (is_prime): Return explicit boolean values.
24026         (hash_get_first): Return NULL to appease Irix5.6's 89.
24027         Reported by Nelson Beebe.
24028
24029 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
24030
24031         * lib/localcharset.c (locale_charset): Add support for Win32.
24032
24033 2000-12-18  Paul Eggert  <eggert@twinsun.com>
24034
24035         * lib/physmem.h, lib/physmem.c: New files.
24036
24037         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
24038         (noinst_HEADERS): Add physmem.h.
24039
24040         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
24041         't' for compatibility with Solaris 8 sort.
24042
24043 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
24044
24045         * lib/config.charset: Add support for BeOS.
24046
24047 2000-12-17  Jim Meyering  <meyering@lucent.com>
24048
24049         * m4/dos.m4 (jm_AC_DOS): New file and macro.
24050         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
24051
24052 2000-12-16  Jim Meyering  <meyering@lucent.com>
24053
24054         This bug had a serious impact on chown: `chown N:M FILE' (for integer
24055         N and M) would have treated it like `chown N:N FILE'.
24056
24057         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
24058
24059 2000-12-16  Jim Meyering  <meyering@lucent.com>
24060
24061         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
24062         SHELLS_FILE to a file name that's useful on djgpp systems.
24063         Include stdlib.h.
24064         (ADDITIONAL_DEFAULT_SHELLS): Define.
24065         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
24066         Based mostly on a patch from Prashant TR.
24067
24068 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
24069
24070         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
24071         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
24072         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
24073
24074 2000-12-08  Andreas Schwab  <schwab@suse.de>
24075
24076         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
24077         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
24078
24079 2000-12-07  Jim Meyering  <meyering@lucent.com>
24080
24081         * lib/stripslash.c (ISSLASH): Define.
24082         (strip_trailing_slashes): Use ISSLASH rather than comparing against
24083         `/'.
24084         From Prashant TR.
24085
24086         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
24087         (dir_name_r): Declare this function as static.
24088         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
24089         manifest itself on a name containing a mix of slashes and
24090         backslashes.
24091         Make this function work with names starting with a DOS-style
24092         drive letter and colon prefix.
24093         (dir_name): Append `.' if necessary.
24094         Based mostly on patches from Prashant TR and Eli Zaretskii.
24095
24096         * lib/dirname.h (dir_name_r): Remove prototype.
24097
24098 2000-12-06  Paul Eggert  <eggert@twinsun.com>
24099
24100         * m4/off_t-format.m4: Remove this file.
24101         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
24102
24103 2000-12-06  Jim Meyering  <meyering@lucent.com>
24104
24105         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
24106         replacement strtoull, we may well need the replacement strtoul, too.
24107         Check for declarations of strtoul and strtoull.
24108         Check for strtol.  Mainly as a cue to cause automake to include
24109         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
24110         Check for limits.h -- strtol.c needs it.
24111
24112 2000-12-05  Jim Meyering  <meyering@lucent.com>
24113
24114         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
24115
24116 2000-12-04  Jim Meyering  <meyering@lucent.com>
24117
24118         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
24119         Also include memory.h, stdlib.h, unistd.h if appropriate.
24120         Reported by Andreas Jaeger (conflicting declaration of malloc).
24121
24122 2000-12-02  Jim Meyering  <meyering@lucent.com>
24123
24124         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
24125         * m4/jm-macros.m4 (jm_MACROS): require it.
24126
24127 2000-12-02  Jim Meyering  <meyering@lucent.com>
24128
24129         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
24130
24131 2000-12-01  Paul Eggert  <eggert@twinsun.com>
24132
24133         * lib/memrchr.c: Include <config.h> before any system include file.
24134
24135 2000-11-30  Jim Meyering  <meyering@lucent.com>
24136
24137         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
24138
24139 2000-11-30  Jim Meyering  <meyering@lucent.com>
24140
24141         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
24142
24143 2000-11-29  Paul Eggert  <eggert@twinsun.com>
24144
24145         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
24146
24147 2000-11-26  Jim Meyering  <meyering@lucent.com>
24148
24149         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
24150
24151 2000-11-22  Paul Eggert  <eggert@twinsun.com>
24152
24153         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
24154         size of (size_t) -1; it's not portable.
24155
24156 2000-11-17  Jim Meyering  <meyering@lucent.com>
24157
24158         * lib/strstr.c: Update from GNU libc.
24159
24160 2000-11-17  Akim Demaille  <akim@epita.fr>
24161
24162         * lib/obstack.h: Formatting changes.
24163         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
24164         prevent type checking.
24165         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
24166         cast the value to (void *): assigning a `foo *' to a `void *'
24167         variable is valid.
24168         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
24169
24170 2000-11-16  Jim Meyering  <meyering@lucent.com>
24171
24172         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
24173
24174 2000-11-11  Jim Meyering  <meyering@lucent.com>
24175
24176         * lib/error.c: Add a couple #includes, merging from GNU libc version.
24177
24178 2000-11-10  Jim Meyering  <meyering@lucent.com>
24179
24180         * lib/obstack.h: Update from GNU libc.
24181         * lib/obstack.c: Likewise.
24182
24183 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
24184
24185         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
24186
24187 2000-11-06  Paul Eggert  <eggert@twinsun.com>
24188
24189         * lib/getusershell.c (setusershell): Use rewind rather than
24190         fseek/fseeko, to avoid configuration hassles with fseeko.
24191         Don't bother opening SHELLS_FILE if shellstream is NULL;
24192         it's not necessary.
24193
24194 2000-11-05  Jim Meyering  <meyering@lucent.com>
24195
24196         * lib/makepath.h (make_dir): Declare.
24197         * lib/makepath.c (make_dir): Remove `static' attribute.
24198         Tweak a comment.
24199
24200 2000-11-04  Jim Meyering  <meyering@lucent.com>
24201
24202         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
24203
24204 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
24205
24206         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
24207         last one in a bucket, advance to the next bucket.
24208
24209 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
24210
24211         * lib/fnmatch.c: Do not comment out all the code if we are using
24212         the GNU C library, because in some cases we are replacing buggy
24213         code in the GNU C library itself.
24214
24215 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
24216
24217         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
24218         (regex_compile): Catch bogus \(\1\).
24219
24220 2000-10-30  Paul Eggert  <eggert@twinsun.com>
24221
24222         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
24223         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
24224         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
24225
24226 2000-10-30  Paul Eggert  <eggert@twinsun.com>
24227
24228         * lib/error.h, getline.h, modechange.h:
24229         Remove "2000" from Copyright line, as the file hasn't been
24230         changed this year other than in the copyright notice.
24231
24232         * lib/xalloc.h: Add "2000" to Copyright line, as this file
24233         was changed this year.
24234
24235 2000-10-29  Jim Meyering  <meyering@lucent.com>
24236
24237         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
24238         renaming.
24239         * m4/ls-mntd-fs.m4: Likewise
24240
24241 2000-10-29  Jim Meyering  <meyering@lucent.com>
24242
24243         * lib/xstat.in: Fix grammar in comment.
24244
24245 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
24246
24247         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
24248         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
24249         doesn't define __restrict_arr.
24250
24251 2000-10-28  Jim Meyering  <meyering@lucent.com>
24252
24253         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
24254         (jm_PREREQ_MEMCHR): New function.
24255
24256 2000-10-28  Jim Meyering  <meyering@lucent.com>
24257
24258         * lib/memchr.c: Update from libc.
24259         Adjust for portability:
24260         [HAVE_STDLIB_H]: Include stdlib.h.
24261         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
24262         Undef __memchr, too.
24263         [!weak_alias]: Define __memchr to memchr.
24264
24265         * lib/regex.c: Update from libc.
24266         * lib/regex.h: Likewise.
24267         * lib/getopt1.c: Likewise.
24268         * lib/memcmp.c: Likewise.
24269
24270         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
24271         Avoid using fseek, when possible -- it's broken by design.
24272         Patch by Ulrich Drepper.
24273
24274 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
24275
24276         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
24277         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
24278         Giving in to popular pressure to shut up the compiler with casts.
24279
24280 2000-10-26  Jim Meyering  <meyering@lucent.com>
24281
24282         * lib/strftime.c: Update from libc.
24283
24284 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
24285
24286         * regex.c: More `unsigned char' -> `re_char' changes.
24287         Also change several `int' into `re_wchar_t'.
24288         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
24289         (PUSH_FAILURE_POINTER): Don't cast any more.
24290         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
24291         We want GCC to complain, since this piece of code makes
24292         re_match non-reentrant, which *should* be fixed.
24293         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
24294         (EXTEND_BUFFER): Use RETALLOC.
24295         (SET_LIST_BIT): Don't cast.
24296         (re_wchar_t): New type.
24297         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
24298         that those two functions will always properly return.
24299         (IMMEDIATE_QUIT_CHECK): Cast to void.
24300         (analyse_first): Use recursion rather than an explicit stack.
24301         (re_compile_fastmap): Can't fail anymore.
24302         (re_search_2): Don't check re_compile_fastmap for failure.
24303         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
24304         Now also sets the new value (passed in a new argument).
24305         (re_match_2_internal): Use it.
24306         Also, use a new var `reg' of type size_t when looping through regs
24307         rather than reuse the inappropriate `mcnt'.
24308
24309 2000-10-25  Jim Meyering  <meyering@lucent.com>
24310
24311         * lib/obstack.c: Update from libc.
24312
24313 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
24314
24315         * regex.c (regex_compile): Change the way of handling a range from
24316         a char less than 256 to a char not less than 256.
24317
24318 2000-10-24  Andrew Innes  <andrewi@gnu.org>
24319
24320         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
24321         NT-Emacs only.
24322         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
24323         so that re_search functions only quit when callers expect them to.
24324
24325 2000-10-23  Jim Meyering  <meyering@lucent.com>
24326
24327         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
24328         wrong.  That set_locale call must not have any side effects.
24329         From Paul Eggert.
24330
24331 2000-10-22  Jim Meyering  <meyering@lucent.com>
24332
24333         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
24334         [CYCLIC]: Remove now-unused definition.
24335
24336         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
24337         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
24338         Suggestion from Ulrich Drepper.
24339
24340 2000-10-21  Jim Meyering  <meyering@lucent.com>
24341
24342         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
24343         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
24344         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
24345
24346 2000-10-21  Jim Meyering  <meyering@lucent.com>
24347
24348         * lib/dirname.c (memrchr): Declare if necessary.
24349         (dir_name): Remove the restriction that there be no
24350         trailing slashes.  Now, this code skips past them, effectively
24351         ignoring them.
24352         [TEST_DIRNAME] (main): New unit tests.
24353
24354         * lib/memrchr.c: New file from GNU libc.
24355         Undef __memrchr, too.
24356         [!weak_alias]: Define __memrchr to memrchr.
24357         Guard weak_alias use with `#ifdef weak_alias'.
24358
24359 2000-10-21  Jim Meyering  <meyering@lucent.com>
24360
24361         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
24362         (dir_name): Use dir_name_r.
24363         * lib/dirname.h (dir_name_r): Declare it.
24364
24365 2000-10-17  Jim Meyering  <meyering@lucent.com>
24366
24367         * lib/quote.h (PARAMS): Define and use.
24368         Reported by Akim Demaille.
24369
24370         * lib/getopt.c: Update from libc.
24371
24372 2000-10-16  Jim Meyering  <meyering@lucent.com>
24373
24374         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
24375         setlocale.
24376         From Jan Fedak.
24377
24378 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
24379
24380         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
24381
24382 2000-09-25  Jim Meyering  <meyering@lucent.com>
24383
24384         * lib/md5.h (rol): Define (from GnuPG).
24385
24386         * lib/sha.c: Give credit (GnuPG) where due.
24387         (M): Use rol rather than open-coding it.
24388         Add a FIXME comment.
24389
24390 2000-09-21  Jim Meyering  <meyering@lucent.com>
24391
24392         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
24393         Reported by Michael Stone.
24394
24395 2000-09-20  Jim Meyering  <meyering@lucent.com>
24396
24397         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
24398         (noinst_HEADERS): Add sha.h.
24399         Based on code from Scott G. Miller and from GnuPG.
24400
24401 2000-09-18  Jim Meyering  <meyering@lucent.com>
24402
24403         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
24404         LIBS. Otherwise, everyone ends up linking with -lelf for some
24405         configurations.
24406         Reported by Mike Stone.
24407
24408 2000-09-15  Jim Meyering  <meyering@lucent.com>
24409
24410         * lib/regex.c: Update from libc.
24411
24412 2000-09-10  Jim Meyering  <meyering@lucent.com>
24413
24414         * lib/getopt.c (_getopt_internal): Update from glibc.
24415
24416 2000-09-09  Jim Meyering  <meyering@lucent.com>
24417
24418         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
24419         think it should be used as a general replacement for isascii.
24420         * lib/fnmatch.c: Likewise.
24421         * lib/mbswidth.c: Likewise
24422         * lib/regex.c: Likewise.
24423
24424         Don't use atoi.
24425         * lib/userspec.c: Include sys/param.h and limits.h.
24426         Include xstrtol.h.
24427         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
24428         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
24429         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
24430         UID, GID.  Check range.
24431
24432 2000-09-06  Jim Meyering  <meyering@lucent.com>
24433
24434         * lib/getopt.c (_getopt_internal): Update from glibc.
24435
24436 2000-08-30  Jim Meyering  <meyering@lucent.com>
24437
24438         * lib/strftime.c: Merge in changes from GNU libc.
24439
24440 2000-08-26  Jim Meyering  <meyering@lucent.com>
24441
24442         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
24443         * m4/fpending.m4: New file.
24444
24445 2000-08-26  Jim Meyering  <meyering@lucent.com>
24446
24447         * lib/closeout.c: Include "__fpending.h".
24448         (close_stdout_status): Return right away if there's nothing to flush.
24449
24450         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
24451         * lib/__fpending.c: New file.
24452         * lib/__fpending.h: New file.
24453
24454 2000-08-20  Jim Meyering  <meyering@lucent.com>
24455
24456         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
24457         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
24458         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
24459
24460 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
24461
24462         Improve fileutils installation on systems where running
24463         programs (like install) can't be unlinked.
24464         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
24465         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
24466
24467 2000-08-07  Paul Eggert  <eggert@twinsun.com>
24468
24469         Standardize on "memory exhausted" instead of "Memory exhausted"
24470         or "virtual memory exhausted".
24471         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
24472         "virtual memory exhausted".
24473         * lib/same.c (same_name): Invoke xalloc_die instead of printing
24474         our own message.
24475         * lib/userspec.c (parse_user_spec): Likewise.
24476         * lib/bumpalloc.h: comment fix
24477         * lib/same.c, userspec.c: Include xalloc.h.
24478
24479         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
24480         not char *const and pointing to a constant array.
24481         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
24482         (xrealloc): Comment fix.
24483
24484         * lib/userspec.c (parse_user_spec):
24485         Don't translate a message until just before returning,
24486         to avoid unnecessary translation.
24487
24488 2000-08-07  Jim Meyering  <meyering@lucent.com>
24489
24490         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
24491         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
24492         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
24493         getgroups.c, gethostname.c, getopt.h, group-member.c,
24494         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
24495         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
24496         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
24497         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
24498         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
24499         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
24500         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
24501         yesno.c: Back out Copyright date changes for each file with no change
24502         this year.  This eases coordination with other programs using the same
24503         source code modules.  From Paul Eggert.
24504
24505 2000-08-06  Paul Eggert  <eggert@twinsun.com>
24506
24507         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
24508         not char, for compatibility with glibc 2.1.3 strftime.c.
24509
24510 2000-08-03  Greg McGary  <greg@mcgary.org>
24511
24512         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
24513         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
24514         (EXTEND_BUFFER): Use them.
24515
24516 2000-08-01  Jim Meyering  <meyering@lucent.com>
24517
24518         * lib/dirname.c (ISSLASH): Define.
24519         (BACKSLASH_IS_PATH_SEPARATOR): Define.
24520         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
24521         both `\' and `/' may be use as path separators.
24522         Based on a patch from Prashant TR.
24523
24524 2000-07-31  Paul Eggert  <eggert@twinsun.com>
24525
24526         * lib/quotearg.c (quotearg_n_options): Don't make the initial
24527         slot vector a constant, since it might get modified.
24528
24529 2000-07-31  Jim Meyering  <meyering@lucent.com>
24530
24531         * lib/xmalloc.c: Use `virtual memory exhausted', not
24532         `Memory exhausted'.
24533         * lib/obstack.c (print_and_abort): Likewise.
24534
24535 2000-07-30  Paul Eggert  <eggert@twinsun.com>
24536
24537         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
24538         buffer, so that the caller can always quote one small
24539         component of a "memory exhausted" message in slot 0.
24540         From a suggestion by Jim Meyering.
24541
24542 2000-07-30  Jim Meyering  <meyering@lucent.com>
24543
24544         * lib/makepath.c (make_path): Quote the other instance, too.
24545
24546         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
24547         (STATIC_BUF_SIZE): Define.
24548         (quotearg_n_options): Use only statically allocated storage when
24549         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
24550         than STATIC_BUF_SIZE.
24551
24552 2000-07-29  Jim Meyering  <meyering@lucent.com>
24553
24554         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
24555         * lib/dirname.c (dir_name): Likewise.
24556
24557         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
24558         `/'.
24559
24560         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
24561         (dir_name): Assert that there are no trailing slashes.
24562
24563 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
24564
24565         * lib/mbswidth.h (mbswidth): Add a flags argument.
24566         (mbswidth): New declaration.
24567         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
24568         * lib/mbswidth.c (mbswidth): Add a flags argument.
24569         (mbsnwidth): New function.
24570
24571 2000-07-24  Jim Meyering  <meyering@lucent.com>
24572
24573         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
24574
24575 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24576
24577         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
24578
24579 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24580
24581         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
24582         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
24583         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
24584         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
24585         invoke multibyte primitives.
24586
24587 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24588
24589         * lib/quotearg.c:
24590         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
24591         so that mbstate_t is always defined.
24592
24593         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
24594         be 1 in at least one GCC installation, and this configuration
24595         error is likely to be common.  Ignoring MB_LEN_MAX hurts
24596         performance on hosts that have mbrtowc but have only unibyte
24597         locales, but I assume these hosts are rare.
24598
24599 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24600
24601         * lib/mbswidth.c (_XOPEN_SOURCE):
24602         Don't define; this causes problems on Solaris 7.
24603         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
24604
24605 2000-07-23  Jim Meyering  <meyering@lucent.com>
24606
24607         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
24608         too: getgrgid, getpwuid, getuid.
24609
24610 2000-07-23  Jim Meyering  <meyering@lucent.com>
24611
24612         * lib/basename.c (base_name): Add an assertion.
24613
24614 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
24615
24616         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
24617         shadow its mbsinit function.
24618
24619 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
24620
24621         * lib/mbswidth.h: New file.
24622         * lib/mbswidth.c: New file.
24623         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
24624         (noinst_HEADERS): Add mbswidth.h.
24625
24626 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
24627
24628         * lib/config.charset: Add support for FreeBSD. Improve support for
24629         HP-UX and IRIX 6.
24630
24631 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
24632
24633         * m4/mbswidth.m4: New file.
24634         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
24635
24636 2000-07-15  Jim Meyering  <meyering@lucent.com>
24637
24638         * lib/makepath.c: Include quote.h.
24639         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
24640         corresponding argument in a `quote (...)' call.
24641         Give better diagnostics.
24642
24643         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
24644         (noinst_HEADERS): Add quote.h.
24645
24646         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
24647         from tar's src/misc.c.
24648         * lib/quote.h: New file.  Prototypes for same.
24649
24650 2000-07-14  Paul Eggert  <eggert@twinsun.com>
24651
24652         From a suggestion by Bruno Haible.
24653         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
24654         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
24655         to decide whether to define the BeOS workaround macro;
24656         this adjusts to the change to AC_MBSTATE_T.
24657
24658 2000-07-14  Jim Meyering  <meyering@lucent.com>
24659
24660         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
24661         jm_AC_TYPE_UINTMAX_T.
24662
24663 2000-07-13  Paul Eggert  <eggert@twinsun.com>
24664
24665         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
24666
24667         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
24668         quotearg_buffer_restyled): Add support for
24669         clocale_quoting_style.  Undo previous change to
24670         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
24671         and "{RIGHT QUOTATION MARK}" msgids.
24672
24673 2000-07-10  Paul Eggert  <eggert@twinsun.com>
24674
24675         From a suggestion by Bruno Haible.
24676         * m4/mbstate_t.m4 (AC_MBSTATE_T):
24677         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
24678         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
24679         and mbstate_t, to a single-part test that simply defines mbstate_t.
24680         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
24681         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
24682
24683 2000-07-10  Jim Meyering  <meyering@lucent.com>
24684
24685         * m4/strerror_r.m4: Mirror the correction made in autoconf.
24686
24687         * m4/gnu-source.m4: Output to confdefs.h directly.
24688         Suggestion from Akim Demaille.
24689
24690 2000-07-09  Paul Eggert  <eggert@twinsun.com>
24691
24692         The old behavior of quoting `like this' doesn't look good with
24693         newer, ISO-style fonts.  See:
24694         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
24695
24696         Instead, quote "like this" by default.  Let the translator
24697         tailor the locale-specific quoting behavior by providing
24698         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
24699
24700         * lib/quotearg.c (N_): New macro.
24701         (gettext_default): New function.
24702         (quotearg_buffer_restyled): Use
24703         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
24704         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
24705
24706 2000-07-09  Jim Meyering  <meyering@lucent.com>
24707
24708         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
24709         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
24710
24711         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
24712         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
24713
24714 2000-07-09  Jim Meyering  <meyering@lucent.com>
24715
24716         * lib/Most files: Update copyright dates to include 2000.
24717
24718 2000-07-08  Jim Meyering  <meyering@lucent.com>
24719
24720         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
24721         if not defined.
24722         (xgethostname): Remove now-unnecessary #ifdef.
24723         Move declaration of `err' into loop where it's used.
24724
24725 2000-07-05  Paul Eggert  <eggert@twinsun.com>
24726         and Bruno Haible  <haible@clisp.cons.org>
24727
24728         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
24729         only if the test for an object-type mbstate_t fails.  This
24730         prevents us from mistakenly reporting that mbstate_t is a
24731         system object type after we "#define mbstate_t int" to work
24732         around its lack.
24733
24734 2000-07-05  Paul Eggert  <eggert@twinsun.com>
24735         and Bruno Haible  <haible@clisp.cons.org>
24736
24737         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
24738
24739 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24740
24741         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
24742         to strerror_r.
24743         Include <ctype.h> for use of isalpha.
24744
24745 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24746
24747         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
24748         by allocating a larger buffer. Test the gethostname return value for
24749         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
24750         returns an error and ENAMETOOLONG isn't defined.
24751
24752 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24753
24754         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
24755         dimension.
24756
24757 2000-07-04  Jim Meyering  <meyering@lucent.com>
24758
24759         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
24760         of the deprecated AC_CHECKING.
24761
24762 2000-07-04  Jim Meyering  <meyering@lucent.com>
24763
24764         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
24765         Reported by Bruno Haible.
24766
24767 2000-07-04  Jim Meyering  <meyering@lucent.com>
24768
24769         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
24770         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
24771         lacks mbrtowc.
24772
24773 2000-07-03  Paul Eggert  <eggert@twinsun.com>
24774
24775         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
24776         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
24777
24778 2000-07-03  Paul Eggert  <eggert@twinsun.com>
24779         and Bruno Haible  <haible@clisp.cons.org>
24780
24781         * lib/quotearg.c (mbrtowc):
24782         Assign to *pwc, and return 1 only if result is nonzero.
24783         (iswprint): Use ISPRINT when substituting our own mbrtowc.
24784
24785 2000-07-03  Jim Meyering  <meyering@lucent.com>
24786
24787         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
24788
24789 2000-07-03  Jim Meyering  <meyering@lucent.com>
24790
24791         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
24792         This is necessary to get a definition of e.g., UTMP_FILE on
24793         HP-UX 10.20.
24794         From Bob Proulx.
24795
24796 2000-07-02  Jim Meyering  <meyering@lucent.com>
24797
24798         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
24799
24800         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
24801         AC_LIBOBJ(function_name).
24802         * m4/chown.m4: Likewise.
24803         * m4/fnmatch.m4: Likewise.
24804         * m4/ftruncate.m4: Likewise.
24805         * m4/getgroups.m4: Likewise.
24806         * m4/getline.m4: Likewise.
24807         * m4/group-member.m4: Likewise.
24808         * m4/jm-macros.m4: Likewise.
24809         * m4/lstat.m4: Likewise.
24810         * m4/malloc.m4: Likewise.
24811         * m4/memcmp.m4: Likewise.
24812         * m4/nanosleep.m4: Likewise.
24813         * m4/putenv.m4: Likewise.
24814         * m4/realloc.m4: Likewise.
24815         * m4/regex.m4: Likewise.
24816         * m4/stat.m4: Likewise.
24817         * m4/strftime.m4: Likewise.
24818
24819 2000-07-02  Jim Meyering  <meyering@lucent.com>
24820
24821         * lib/quotearg.c (mbstate_t): Don't define here.
24822
24823 2000-07-02  Jim Meyering  <meyering@lucent.com>
24824
24825         * lib/nanosleep.c (SIGCONT): Define if not already defined.
24826
24827 2000-07-01  Jim Meyering  <meyering@lucent.com>
24828
24829         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
24830
24831 2000-07-01  Jim Meyering  <meyering@lucent.com>
24832
24833         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
24834         problem.
24835
24836 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
24837
24838         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
24839         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
24840
24841 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
24842
24843         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
24844         per change in ../m4/ls-mntd-fs.m4.
24845         (read_filesystem_list): Ignore symbolic links.
24846
24847 2000-06-29  Jim Meyering  <meyering@lucent.com>
24848
24849         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
24850         for declaration of strcmp.
24851
24852         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
24853
24854         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
24855         Avoid warning by casting result to `char *' to remove `const'.
24856
24857 2000-06-28  Jim Meyering  <meyering@lucent.com>
24858
24859         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
24860         included by quotearg.c, for which we perform this test.  From
24861         Bruno Haible.
24862
24863 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
24864
24865         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
24866         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
24867         <utmpx.h> exists, put readutmp.o into LIBOBJS.
24868
24869 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
24870
24871         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
24872
24873 2000-06-26  Paul Eggert  <eggert@twinsun.com>
24874
24875         savedir now sets errno on failure and invokes xmalloc to get memory.
24876         Fix a couple of other minor bugs while we're at it.
24877
24878         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
24879         (NAMLEN): Remove macro.
24880         (malloc, realloc): Remove decls.
24881         (stpcpy): Likewise.
24882         ("xalloc.h"): Include.
24883         (NAME_SIZE_DEFAULT): New macro.
24884         (savedir): Use xmalloc / xrealloc to allocate memory.
24885         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
24886         Skip "" directory entries.
24887         Use strlen to calculate directory entry length, since the old method
24888         is rarely used these days and isn't worth supporting.
24889         Don't use a pointer after freeing it.
24890         Check for integer overflow when calculating allocation size.
24891         Use memcpy to copy entries, instead of stpcpy.
24892         Set errno properly when returning NULL.
24893         Check for readdir error.
24894
24895 2000-06-26  Jim Meyering  <meyering@lucent.com>
24896
24897         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
24898
24899 2000-06-25  Jim Meyering  <meyering@lucent.com>
24900
24901         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
24902         Linux header bug when _XOPEN_SOURCE is defined to 500.
24903
24904 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
24905
24906         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
24907         deficiency.
24908
24909 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
24910
24911         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
24912         Include xalloc.h.
24913         Don't include <stdlib.h>.  Don't declare malloc, realloc.
24914
24915 2000-06-24  Jim Meyering  <meyering@lucent.com>
24916
24917         * m4/strerror_r.m4: Revive this file -- to try out an experimental
24918         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
24919         for which strerror does return char*, but which lacks a conveniently
24920         accessible declaration of the function.  If the compile-test says
24921         strerror_r doesn't work, then resort to a `run'-test that works on
24922         BeOS and segfaults on DEC Unix.
24923
24924 2000-06-24  Jim Meyering  <meyering@lucent.com>
24925
24926         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
24927
24928 2000-06-23  Paul Eggert  <eggert@twinsun.com>
24929
24930         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
24931         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
24932
24933 2000-06-23  Paul Eggert  <eggert@twinsun.com>
24934
24935         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
24936         (mbrtowc, mbstate_t): Define substitutes if
24937         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
24938         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
24939         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
24940
24941 2000-06-23  Jim Meyering  <meyering@lucent.com>
24942
24943         * m4/afs.m4: Add missing AC_MSG_RESULT.
24944         Reported by Bruno Haible.
24945
24946         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
24947         Suggestion from Bruno Haible.
24948
24949 2000-06-23  Jim Meyering  <meyering@lucent.com>
24950
24951         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
24952
24953 2000-06-21  Jim Meyering  <meyering@lucent.com>
24954
24955         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
24956
24957 2000-06-21  Jim Meyering  <meyering@lucent.com>
24958
24959         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
24960         (noinst_HEADERS): Add getstr.h.
24961
24962         * lib/getline.c (getstr): Move into a separate file.
24963         * lib/getstr.c (getstr): New file, extracted from getline.c, with
24964         the following changes: new parameter, delim2; both delim[12]
24965         parameters have type `int', not `char'.  The latter would lose
24966         with 8-bit delimiters.
24967         * lib/getstr.h: New file.
24968
24969 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24970
24971         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
24972         than 1024, return a memory chunk of least possible size, instead
24973         of size PATH_MAX + 2. In the loop, increment the size proportionally.
24974         Use free/xmalloc instead of xrealloc to avoid copying for very long
24975         paths.
24976
24977 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24978
24979         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
24980         the empty string.
24981
24982 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24983
24984         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
24985         address, not strdup.  Include <stdlib.h> and don't declare free().
24986
24987 2000-06-19  Jim Meyering  <meyering@lucent.com>
24988
24989         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
24990
24991 2000-06-18  Jim Meyering  <meyering@lucent.com>
24992
24993         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
24994
24995         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
24996         `checking whether...' message to be consistent with that of the
24997         lstat test.
24998
24999 2000-06-18  Jim Meyering  <meyering@lucent.com>
25000
25001         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
25002         Besides, these days every porting target provides a mkdir function.
25003
25004         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
25005         needed. (this snippet comes from src/system.h).
25006
25007 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
25008
25009         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
25010
25011 2000-06-15  Paul Eggert  <eggert@twinsun.com>
25012
25013         * lib/human.c (adjust_value): New function.
25014         (human_readable_inexact): Apply rounding style even when
25015         printing approximate values.
25016
25017 2000-06-14  Paul Eggert  <eggert@twinsun.com>
25018
25019         * lib/human.c (human_readable_inexact): Allow an input block
25020         size that is not a multiple of the output block size, and vice versa.
25021         Reported by Piergiorgio Sartor.
25022
25023 2000-06-14  Paul Eggert  <eggert@twinsun.com>
25024
25025         * lib/getdate.y (get_date): Apply relative times after time
25026         zone indicator, not before.  Reported by Todd A. Jacobs.
25027
25028 2000-06-13  Jim Meyering  <meyering@lucent.com>
25029
25030         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
25031
25032         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
25033
25034 2000-06-12  Paul Eggert  <eggert@twinsun.com>
25035
25036         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
25037
25038 2000-06-12  Jim Meyering  <meyering@lucent.com>
25039
25040         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
25041         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
25042         optional argument.
25043         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
25044         the optional argument, `lib'.
25045
25046 2000-06-08  Jim Meyering  <meyering@lucent.com>
25047
25048         * m4/largefile.m4: Remove file (now that it's part of autoconf).
25049
25050 2000-06-04  Paul Eggert  <eggert@twinsun.com>
25051
25052         Rewrite largefile configuration so that we don't need to run
25053         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
25054         AC_CANONICAL_HOST in configure.in -- jmm]
25055
25056         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
25057         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
25058         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
25059         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
25060         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
25061         All uses changed.
25062         Instead of inspecting the output of getconf, try to compile the
25063         test program without and with the macro definition.
25064         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
25065         for getconf.  Instead, check for the needed flags by compiling
25066         test programs.
25067
25068 2000-06-04  Paul Eggert  <eggert@twinsun.com>
25069
25070         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
25071
25072 2000-06-04  Jim Meyering  <meyering@lucent.com>
25073
25074         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
25075         SunOS 4.1.4 for which gid_t is an unsigned type.
25076
25077 2000-06-03  Jim Meyering  <meyering@lucent.com>
25078
25079         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
25080         now that autoconf requires that.
25081
25082         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
25083         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
25084         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
25085
25086 2000-06-03  Jim Meyering  <meyering@lucent.com>
25087
25088         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
25089
25090 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
25091
25092         * m4/glibc21.m4: New file.
25093         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
25094
25095 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
25096
25097         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
25098         newer, don't install charset.alias.
25099         * lib/config.charset: Change the Linux/glibc rules so they become empty
25100         on glibc-2.1 or newer.
25101
25102 2000-06-02  Jim Meyering  <meyering@lucent.com>
25103
25104         * lib/mountlist.c: Back out last change.  Instead, do this...
25105         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
25106         me_dummy member using the same `ignore'-testing code.
25107         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
25108         fs_type strings.
25109         From Mark D. Roth.
25110
25111 2000-05-29  Jim Meyering  <meyering@lucent.com>
25112
25113         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
25114         mounts with the `ignore' attribute.  Based on a patch from
25115         Mark D. Roth.
25116
25117 2000-05-28  Jim Meyering  <meyering@lucent.com>
25118
25119         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
25120         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
25121         * m4/stat.m4: Likewise.
25122         * m4/lstat.m4: Likewise.
25123         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
25124
25125         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
25126         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
25127
25128 2000-05-26  Jim Meyering  <meyering@lucent.com>
25129
25130         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
25131
25132 2000-05-24  Jim Meyering  <meyering@lucent.com>
25133
25134         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
25135         autoconf requires that.
25136         * m4/lib-check.m4: Likewise.
25137         * m4/jm-macros.m4: Likewise.
25138         * m4/strftime.m4: Likewise.
25139
25140         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
25141         AC_CHECK_DECLS, now that autoconf requires that.
25142
25143 2000-05-22  Jim Meyering  <meyering@lucent.com>
25144
25145         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
25146         * m4/lstat.m4: Likewise.
25147
25148 2000-05-22  Jim Meyering  <meyering@lucent.com>
25149
25150         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
25151
25152 2000-05-20  Jim Meyering  <meyering@lucent.com>
25153
25154         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
25155         (jm_PREREQ): Use it.
25156
25157 2000-05-18  Jim Meyering  <meyering@lucent.com>
25158
25159         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
25160         back, too, since it may have been modified by allocate_entry.
25161         (hash_delete): Rewrite to use neither the assignment operator
25162         nor the comma operator in an if-expression.
25163
25164 2000-05-15  Paul Eggert  <eggert@twinsun.com>
25165
25166         * lib/closeout.c:
25167         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
25168         Remove; no longer needed.
25169         "quotearg.h": Add include.
25170         (file_name): Do not bother to explicitly initialize to NULL; it's less
25171         efficient on some hosts.
25172         (close_stdout_status): Remove test as to whether stdout was already
25173         closed; it breaks for the case "echo x | sort >&-".
25174         Quote file name colons.
25175         Do not assume that _("write error") lacks format strings.
25176
25177 2000-05-15  Jim Meyering  <meyering@lucent.com>
25178
25179         * lib/version-etc.c (version_etc_copyright): Update the copyright
25180         string used in all --version output.
25181
25182 2000-05-14  Jim Meyering  <meyering@lucent.com>
25183
25184         * lib/closeout.c (close_stdout_set_file_name): New function.
25185         (close_stdout_status): Use new file-scoped global.
25186         Return right away if fstat says the stdout file descriptor is invalid.
25187         * lib/closeout.h (close_stdout_set_file_name): Declare.
25188
25189 2000-05-10  Jim Meyering  <meyering@lucent.com>
25190
25191         * lib/closeout.c [default_exit_status]: New file-scoped variable.
25192         (close_stdout_set_status): New function.
25193         * lib/closeout.h (close_stdout_set_status): Declare.
25194
25195 2000-05-09  Jim Meyering  <meyering@lucent.com>
25196
25197         * m4/gettext.m4: Rename this...
25198         * m4/libintl.m4: ...to this.
25199
25200 2000-05-08  Jim Meyering  <meyering@lucent.com>
25201
25202         * lib/long-options.c: Don't include closeout.h.
25203         (parse_long_options): Don't call close_stdout for --version.
25204
25205 2000-05-06  Paul Eggert  <eggert@twinsun.com>
25206
25207         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
25208         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
25209         2.1.3 bug.  This avoids a clash when files like regex.c define
25210         _GNU_SOURCE.
25211
25212 2000-05-06  Jim Meyering  <meyering@lucent.com>
25213
25214         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
25215         (AC_REPLACE_FUNCS): Add strnlen.
25216
25217         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
25218         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
25219
25220         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
25221         AC_SEARCH_LIBS call for nanosleep.
25222         (LIB_NANOSLEEP): Set and AC_SUBST.
25223
25224 2000-05-06  Jim Meyering  <meyering@lucent.com>
25225
25226         * lib/strnlen.c: Undefine __strnlen and strnlen.
25227         [!weak_alias]: Define __strnlen to strnlen.
25228
25229         * lib/atexit.c: New file, from libiberty.
25230
25231 2000-05-06  Jim Meyering  <meyering@lucent.com>
25232
25233         * lib/closeout.c (close_stdout_status): Also check for errors on the
25234         stderr stream.
25235
25236 2000-05-05  Jim Meyering  <meyering@lucent.com>
25237
25238         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
25239         AC_SEARCH_LIBS call for clock_gettime.
25240         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
25241
25242         * m4/search-libs.m4: Update from autoconf.
25243
25244         su doesn't work on Solaris 2.6.
25245         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
25246         <shadow.h>.  Reported by Dragos Harabor.
25247
25248 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
25249
25250         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
25251         memcpy instead of xmalloc, xrealloc, path_concat.
25252         (locale_charset): Treat empty environment variables as absent.
25253         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
25254
25255 2000-05-04  Jim Meyering  <meyering@lucent.com>
25256
25257         * lib/getopt.c: Update from glibc.
25258         * lib/obstack.c: Likewise.
25259         * lib/obstack.h: Likewise.
25260         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
25261         file
25262
25263         * lib/regex.h: Likewise.
25264         * lib/strndup.c: Likewise.
25265         * lib/strnlen.c: New file, from glibc.
25266
25267 2000-05-03  Jim Meyering  <meyering@lucent.com>
25268
25269         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
25270
25271 2000-05-02  Paul Eggert  <eggert@twinsun.com>
25272
25273         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
25274         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
25275         compile-time test, rather than inspecting host and OS, to
25276         decide whether to define _LARGEFILE_SOURCE.
25277
25278 2000-05-01  Jim Meyering  <meyering@lucent.com>
25279
25280         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
25281
25282         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
25283         Based on a patch from Bruno Haible.
25284
25285 2000-05-01  Jim Meyering  <meyering@lucent.com>
25286
25287         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
25288
25289 2000-04-29  Jim Meyering  <meyering@lucent.com>
25290
25291         * lib/path-concat.c: Declare strdup only if it's not defined.
25292         * lib/canon-host.c: Likewise.
25293
25294 2000-04-28  Jim Meyering  <meyering@lucent.com>
25295
25296         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
25297         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
25298         is included first, then limits.h is included by locale.h by libintl.h.
25299         From John David Anglin.
25300
25301 2000-04-25  Jim Meyering  <meyering@lucent.com>
25302
25303         * lib/makepath.c (S_IRWXUGO): Define.
25304         (make_path): Always perform explicit chmod if MODE specifies any
25305         of the `special' permission bits.  Prompted by a bug report against
25306         install from Mate Wierdl and Joost van Baal.
25307
25308 2000-04-18  Jim Meyering  <meyering@lucent.com>
25309
25310         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
25311         (jm_PREREQ): Use it.
25312
25313 2000-04-18  Jim Meyering  <meyering@lucent.com>
25314
25315         * lib/README: New file.
25316
25317         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
25318         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
25319
25320 2000-04-17  Jim Meyering  <meyering@lucent.com>
25321
25322         Get it right :-)
25323         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
25324         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
25325         Suggestion from Akim Demaille.
25326
25327 2000-04-17  Jim Meyering  <meyering@lucent.com>
25328
25329         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
25330         the definition of it to rpl_strftime also defined-away the system's
25331         declaration.
25332
25333 2000-04-15  Jim Meyering  <meyering@lucent.com>
25334
25335         Use `C' to denote so-called `contiguous' files, the same way
25336         that tar does.
25337         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
25338         (ftypelet): Use S_ISCTG.
25339         From Michael Deutschmann.
25340
25341 2000-04-14  Jim Meyering  <meyering@lucent.com>
25342
25343         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
25344         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
25345         clobbered.
25346
25347 2000-04-14  Jim Meyering  <meyering@lucent.com>
25348
25349         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
25350
25351 2000-04-13  Jim Meyering  <meyering@lucent.com>
25352
25353         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
25354         AH_VERBATIM to insert required #ifndef into config.h.in.
25355         Suggestion from Akim Demaille.
25356
25357 2000-04-12  Jim Meyering  <meyering@lucent.com>
25358
25359         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
25360         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
25361         Christian Krackowizer.
25362
25363         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
25364         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
25365         (AC_SYS_LARGEFILE): Require.
25366         (AM_C_PROTOTYPES): Require.
25367
25368 2000-04-08  Jim Meyering  <meyering@lucent.com>
25369
25370         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
25371         names don't conflict.  Reported by Eli Zaretskii.
25372
25373 2000-04-07  Jim Meyering  <meyering@lucent.com>
25374
25375         * lib/putenv.c: Move inclusion of errno.h so it follows that of
25376         sys/types.h, to work around system header problems on AIX 3.2.5.
25377         From Bruno Haible.
25378
25379 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
25380
25381         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
25382         bug.  Deal with the different error behavior of Irix iconv.
25383
25384 2000-04-05  Paul Eggert  <eggert@twinsun.com>
25385
25386         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
25387         IRIX if the installer said otherwise.
25388
25389 2000-04-05  Jim Meyering  <meyering@lucent.com>
25390
25391         Portability tweaks required for ultrix4.3.
25392         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
25393         (jm_CHECK_DECLS): Add getutent to the list of functions.
25394         (_jm_DECL_HEADERS): Add utmpx.h.
25395         From John David Anglin.
25396
25397         * m4/strftime.m4: Back out the 2000-04-02 change.
25398         Instead of that change, simply undefine putenv in the test program.
25399
25400 2000-04-05  Jim Meyering  <meyering@lucent.com>
25401
25402         Portability tweaks required for ultrix4.3.
25403         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
25404         getutent.
25405         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
25406         * lib/canon-host.c: Declare strdup.
25407         * lib/path-concat.c: Likewise.
25408         From John David Anglin.
25409
25410 2000-04-04  Jim Meyering  <meyering@lucent.com>
25411
25412         Be more DOS 8.3-friendly.
25413         * lib/ref-add.sin: Renamed from ref-add.sed.in.
25414         * lib/ref-del.sin: Renamed from ref-del.sed.in.
25415         * lib/Makefile.am: Reflect renaming.
25416         Reported by Eli Zaretskii.
25417
25418         Use a temporary file name that won't clash with `charset.alias'
25419         in the DOS 8.3 name space.
25420         * lib/Makefile.am (charset_tmp): Define.
25421         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
25422         (uninstall-local): Likewise.
25423         Reported by Eli Zaretskii.
25424
25425 2000-04-03  Jim Meyering  <meyering@lucent.com>
25426
25427         * m4/gettext.m4: Fix typo in comment.
25428
25429         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
25430         textutils/configure.in).  Suggestion from Paul Eggert.
25431         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
25432
25433 2000-04-02  Paul Eggert  <eggert@twinsun.com>
25434
25435         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
25436         variable in the shell rather than using putenv, which isn't
25437         portable.  This avoids the configure-time inter-test dependency
25438         on the potentially-renamed putenv function.
25439
25440 2000-03-30  Paul Eggert  <eggert@twinsun.com>
25441
25442         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
25443         before checking struct stat.st_blksize, so that
25444         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
25445
25446 2000-03-29  Paul Eggert  <eggert@twinsun.com>
25447
25448         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
25449         since strftime.c uses HAVE_STRFTIME to decide whether to use
25450         the underlying strftime.
25451
25452 2000-03-29  Paul Eggert  <eggert@twinsun.com>
25453
25454         * lib/time/strftime.c (my_strftime): Make sure we call the system
25455         strftime, not ourselves, when invoking the underlying strftime.
25456
25457 2000-03-24  Jim Meyering  <meyering@lucent.com>
25458
25459         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
25460         (charset_alias): Define.
25461         (install-exec-local): Factor out common code.
25462         (uninstall-local): Split lines longer than 80.
25463         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
25464         (SUFFIXES): Define.
25465         (.sed.in.sed): New rule.  Don't redirect directly to $@.
25466         (CLEANFILES): Add ref-add.sed and ref-del.sed.
25467
25468 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
25469
25470         * lib/config.charset: Output a line containing "Packages using this
25471         file".
25472         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
25473         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
25474         ref-del.sed): New rules.
25475
25476 2000-03-17  Jim Meyering  <meyering@lucent.com>
25477
25478         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
25479         Otherwise, include <strings.h>
25480
25481 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
25482
25483         * lib/unicodeio.c (utf8_wctomb): New function.
25484         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
25485         format instead of in UCS-4 with platform dependent endianness.
25486
25487 2000-03-10  Jim Meyering  <meyering@lucent.com>
25488
25489         * m4/lib-check.m4: Look for getspnam in -lgen, too.
25490         From Marco Franzen.
25491
25492 2000-03-07  Paul Eggert  <eggert@twinsun.com>
25493
25494         * lib/savedir.c (savedir): Work even if directory size is
25495         negative; this can happen with some screwy NFS configurations.
25496
25497 2000-03-06  Jim Meyering  <meyering@lucent.com>
25498
25499         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
25500         if it's NULL (because we ran out of memory).  From Bruno Haible.
25501
25502 2000-03-05  Jim Meyering  <meyering@lucent.com>
25503
25504         * lib/localcharset.c ("path-concat.h"): Include.
25505         (get_charset_aliases): Use path_concat instead of ANSI string
25506         concatenation.
25507
25508         * lib/unicodeio.h (PARAMS): Define.
25509         Use it to guard prototype.
25510
25511 2000-03-04  Jim Meyering  <meyering@lucent.com>
25512
25513         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
25514         for lib/localcharset.c.
25515
25516 2000-03-04  Jim Meyering  <meyering@lucent.com>
25517
25518         * lib/Makefile.am (install-exec-local): Create $(libdir) before
25519         installing into it.
25520         (uninstall-local): Uncomment this rule so `make distcheck' works
25521         once again.
25522
25523         * lib/unicodeio.c (<errno.h>): Include it.
25524         (errno): Declare if not defined.
25525
25526         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
25527
25528         * lib/config.charset: New version, incorporating remarks from a linux
25529         i18n mailing list.  From Bruno Haible.
25530
25531 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
25532
25533         * m4/codeset.m4: New file.
25534         * m4/iconv.m4: New file.
25535         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
25536
25537 2000-03-03  Jim Meyering  <meyering@lucent.com>
25538
25539         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
25540
25541 2000-03-02  Jim Meyering  <meyering@lucent.com>
25542
25543         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
25544         the messages come out on separate lines.
25545
25546         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
25547         rather than jm_CHECK_DECLARATIONS.
25548         * m4/decl.m4: Remove now-unused file.
25549
25550         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
25551         geteuid.
25552
25553 2000-03-02  Jim Meyering  <meyering@lucent.com>
25554
25555         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
25556
25557 2000-03-01  Jim Meyering  <meyering@lucent.com>
25558
25559         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
25560         * lib/unicodeio.c: Likewise.
25561
25562 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
25563
25564         * lib/config.charset: New file.
25565         * lib/localcharset.c: New file.
25566         * lib/unicodeio.h, lib/unicodeio.c: New files.
25567         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
25568         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
25569         (noinst_HEADERS): Add unicodeio.h.
25570         (all-local, install-exec-local, charset.alias): New targets.
25571
25572 2000-02-28  Paul Eggert  <eggert@twinsun.com>
25573
25574         * lib/quotearg.c (ALERT_CHAR): New macro.
25575         (quotearg_buffer_restyled): Use it.
25576
25577 2000-02-27  Jim Meyering  <meyering@lucent.com>
25578
25579         * m4/check-decl.m4: Add getenv to the list.
25580
25581 2000-02-27  Jim Meyering  <meyering@lucent.com>
25582
25583         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
25584         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
25585
25586         * lib/backupfile.c: Guard inclusion of stdlib.h with
25587         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
25588         Declare malloc if needed.
25589
25590         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
25591         `#ifndef HAVE_DECL..'
25592         now that autoconf always defines the HAVE_DECL_ symbols.
25593         * lib/human.c: Likewise.
25594         * lib/same.c: Likewise.
25595         * lib/strtoumax.c: Likewise.
25596
25597         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
25598         declaration check was not run.
25599         * lib/hash.c: Likewise.
25600         * lib/human.c: Likewise.
25601         * lib/same.c: Likewise.
25602         * lib/strtoumax.c: Likewise.
25603
25604         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
25605         `.', then first look up the entire `.'-containing string as a login
25606         name.
25607
25608 2000-02-23  Jim Meyering  <meyering@lucent.com>
25609
25610         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
25611         in place of my hack.
25612
25613 2000-02-18  Paul Eggert  <eggert@twinsun.com>
25614
25615         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
25616         (textint): New typedef.
25617         (parser_control): Member year changed from int to textint.
25618         All uses changed.
25619         (YYSTYPE): Removed; replaced by %union with int and textint members.
25620         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
25621         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
25622         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
25623         (tSNUMBER, tUNUMBER): Now of type <textintval>.
25624         (date, number, to_year): Use width of number in digits, not its value,
25625         to determine whether it's a 2-digit year, or a 2-digit time.
25626         (yylex): Store number of digits of numeric tokens.
25627         Reported by John Kendall.
25628
25629         (parser_control): Changed from struct parser_control to typedef (for
25630         consistency).  All uses changed.
25631
25632         (tID): Removed; not used.
25633         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
25634
25635 2000-02-14  Paul Eggert  <eggert@twinsun.com>
25636
25637         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
25638         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
25639
25640 2000-02-12  Jim Meyering  <meyering@lucent.com>
25641
25642         * lib/userspec.c (ISDIGIT): Define it.
25643         (isdigit): Remove definition.
25644         (is_number): Use ISDIGIT, not isdigit.
25645         <libintl.h>: Include.
25646         (_ and N_): Define.
25647         (parse_user_spec): Mark translatable strings.
25648
25649 2000-02-10  Jim Meyering  <meyering@lucent.com>
25650
25651         With these changes, nanosleep.[ch] are finally enough like the other
25652         lib/* replacement files to compile on a few more losing systems.
25653
25654         * lib/nanosleep.h: Don't include config.h.
25655         Remove prototype from declaration of nanosleep.
25656         (PARAMS): Remove now-unneeded definition.
25657         * lib/nanosleep.c: #undef nanosleep.
25658         (rpl_nanosleep): Rename from nanosleep.
25659
25660 2000-02-10  Jim Meyering  <meyering@lucent.com>
25661
25662         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
25663         gnu_nanosleep to rpl_nanosleep.
25664
25665 2000-02-09  Jim Meyering  <meyering@lucent.com>
25666
25667         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
25668         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
25669
25670 2000-02-08  Akim Demaille  <akim@epita.fr>
25671
25672         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
25673         `[' and `]' and remove uses of `changequote'.
25674         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
25675         (AC_SYS_LARGEFILE): Likewise.
25676         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
25677         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
25678         of changequote.
25679         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
25680         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
25681         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
25682         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
25683
25684 2000-02-05  Jim Meyering  <meyering@lucent.com>
25685
25686         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
25687         Remove explicit use of AC_HEADER_TIME.  It is required by
25688         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
25689         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
25690         in autoconf whereby the expansion of the latter ended up preceding
25691         the expansion of its prerequisite, AC_HEADER_TIME.
25692         Reported by Volker Borchert.
25693
25694 2000-02-03  Jim Meyering  <meyering@lucent.com>
25695
25696         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
25697
25698 2000-02-03  Jim Meyering  <meyering@lucent.com>
25699
25700         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
25701         rather than with `#if HAVE_UTMPNAME'.
25702
25703 2000-02-02  Jim Meyering  <meyering@lucent.com>
25704
25705         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
25706         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
25707         Reported by Eli Zaretskii.
25708
25709 2000-02-01  Jim Meyering  <meyering@lucent.com>
25710
25711         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
25712
25713 2000-01-31  Jim Meyering  <meyering@lucent.com>
25714
25715         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
25716         functions.  Add the time.h and sys/time.h headers along with the
25717         AC_REQUIRE'ment of AC_HEADER_TIME.
25718
25719 2000-01-31  Jim Meyering  <meyering@lucent.com>
25720
25721         * lib/nanosleep.h (nanosleep): Guard declaration with
25722         `#if ! HAVE_DECL_NANOSLEEP'.
25723         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
25724         the declaration in that vendor's sys/timers.h.
25725         Reported by Christian Krackowizer.
25726
25727         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
25728         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
25729         (ISPRINT): Likewise.
25730         Reported by Tom Tromey.
25731
25732 2000-01-30  Jim Meyering  <meyering@lucent.com>
25733
25734         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
25735
25736         * m4/prereq.m4 (utmp_includes): Define.
25737         Check for ut_user and ut_name members in both struct utmpx
25738         and struct utmp.
25739
25740 2000-01-30  Jim Meyering  <meyering@lucent.com>
25741
25742         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
25743         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
25744         header files where only utmpx.ut_user is declared.
25745
25746         * lib/readutmp.h (UT_USER): Define.
25747
25748 2000-01-29  Jim Meyering  <meyering@lucent.com>
25749
25750         * m4/lib-check.m4: New file containing library-related checks from
25751         fileutils and sh-utils (textutils had none).
25752
25753 2000-01-28  Jim Meyering  <meyering@lucent.com>
25754
25755         * m4/perl.m4: Change format of warning message to look more like that
25756         from the missing script.  Suggestion from François Pinard.
25757
25758 2000-01-25  Jim Meyering  <meyering@lucent.com>
25759
25760         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
25761         well as time.h in the compile check.
25762         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
25763         Fix typo in cross-compiling case: s/yes/no/.
25764
25765 2000-01-23  Jim Meyering  <meyering@lucent.com>
25766
25767         * m4/jm-macros.m4: Move df-related tests here from
25768         fileutils/configure.in
25769
25770         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
25771         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
25772
25773         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
25774         s/space/ac_fsusage_space/.
25775         (jm_FILE_SYSTEM_USAGE): Take two parameters.
25776
25777         * m4/ftruncate.m4: New file (derived from part of
25778         fileutils/configure.in).
25779         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
25780         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
25781
25782         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
25783         AC_SUBST these here, rather than just in sh-util/configure.in, so
25784         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
25785         all the same.
25786         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
25787         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
25788         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
25789         (AC_SUBST(POW_LIBM)): Likewise.
25790         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
25791
25792 2000-01-23  Jim Meyering  <meyering@lucent.com>
25793
25794         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
25795         obstack.c.
25796
25797 2000-01-22  Jim Meyering  <meyering@lucent.com>
25798
25799         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
25800
25801         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
25802
25803         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
25804         configure.in
25805         (AC_CHECK_HEADERS): Likewise for sh-utils.
25806         (AC_CHECK_HEADERS): Likewise for textutils.
25807         Merge the three lists of headers.
25808
25809         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
25810         from fileutils' configure.in.
25811
25812         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
25813         code. Moved tests into their own function (_jm_DECL_HEADERS) in
25814         check-decl.m4.
25815
25816         * m4/check-decl.m4: Use #if rather than #ifdef.
25817         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
25818         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
25819         (_jm_DECL_HEADERS): Define new function.
25820         (jm_CHECK_DECLARATIONS): Require it.
25821
25822 2000-01-22  Jim Meyering  <meyering@lucent.com>
25823
25824         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
25825         [! HAVE_DECL_STRTOULL]: Declare strtoull.
25826         Required for some AIX systems.  Reported by Christian Krackowizer.
25827         [TESTING] (main): New function.
25828
25829         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
25830         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
25831         letters.
25832
25833         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
25834         iswprint.
25835
25836         * lib/strverscmp.c (ISDIGIT): Define.
25837         (strverscmp): Use ISDIGIT, not isdigit.
25838
25839 2000-01-19  Jim Meyering  <meyering@lucent.com>
25840
25841         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
25842         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
25843         defines `struct timespec' in <sys/time.h>
25844
25845         * m4/c-bs-a.m4: Remove uses of changequote altogether.
25846         Thanks to Akim for explaining.
25847
25848 2000-01-17  Paul Eggert  <eggert@twinsun.com>
25849
25850         * lib/nanosleep.c (nanosleep):
25851         Don't use SA_INTERRUPT to decide whether to call sigaction, as
25852         POSIX.1 doesn't require SA_INTERRUPT and some systems
25853         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
25854         it's been part of POSIX.1 since day 1 (in 1988).
25855
25856 2000-01-17  Jim Meyering  <meyering@lucent.com>
25857
25858         * lib/interlock: Remove unused file.  Reported by François Pinard.
25859
25860 2000-01-16  Paul Eggert  <eggert@twinsun.com>
25861
25862         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
25863         alert, backslash, formfeed, and vertical tab unnecessarily in
25864         shell quoting style.
25865
25866 2000-01-16  Jim Meyering  <meyering@lucent.com>
25867
25868         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
25869         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
25870         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
25871         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
25872
25873 2000-01-16  Jim Meyering  <meyering@lucent.com>
25874
25875         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
25876         because the latter didn't work.
25877
25878 2000-01-15  Jim Meyering  <meyering@lucent.com>
25879
25880         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
25881         (AC_REPLACE_FUNCS): Add memcpy and memset.
25882         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
25883         Add strpbrk.
25884         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
25885
25886 2000-01-12  Jim Meyering  <meyering@lucent.com>
25887
25888         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
25889         (jm_PREREQ): Use it.
25890         (jm_PREREQ_READUTMP): New macro.
25891         (jm_PREREQ): Use it.
25892
25893 2000-01-11  Paul Eggert  <eggert@twinsun.com>
25894
25895         Quote multibyte characters correctly.
25896         * m4/c-bs-a.m4: New file.
25897         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
25898         (jm_PREREQ): Use it.
25899
25900 2000-01-11  Paul Eggert  <eggert@twinsun.com>
25901
25902         * m4/uintmax_t.m4: Port to autoconf 2.13.
25903
25904 2000-01-08  Jim Meyering  <meyering@ascend.com>
25905
25906         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
25907         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
25908
25909 2000-01-04  Jim Meyering  <meyering@ascend.com>
25910
25911         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
25912         jm_STRUCT_DIRENT_D_TYPE.
25913         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
25914         jm_STRUCT_DIRENT_D_INO.
25915         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
25916         jm_STRUCT_UTIMBUF.
25917         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
25918         renamings.
25919         * m4/utime.m4: Likewise.
25920
25921         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
25922         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
25923
25924 2000-01-03  Paul Eggert  <eggert@twinsun.com>
25925
25926         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
25927         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
25928
25929 2000-01-02  Jim Meyering  <meyering@ascend.com>
25930
25931         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
25932         remember if this is necessary.
25933
25934 1999-12-26  Jim Meyering  <meyering@ascend.com>
25935
25936         * m4/jm-macros.m4: Use it here.
25937         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
25938
25939 1999-12-23  Jim Meyering  <meyering@ascend.com>
25940
25941         * m4/jm-macros.m4: Check for clock_gettime (moved from
25942         fileutils/configure.in)
25943         Check for gettimeofday.
25944
25945 1999-12-20  Jim Meyering  <meyering@ascend.com>
25946
25947         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
25948         autoconf-2.14a-1999-12-20.
25949
25950 1999-12-19  Jim Meyering  <meyering@ascend.com>
25951
25952         * m4/lstat-slash.m4: New file.
25953         * m4/jm-macros.m4: Use the new macro:
25954         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
25955
25956 1999-12-07  Jim Meyering  <meyering@ascend.com>
25957
25958         * m4/perl.m4: Require that File::Compare be available, too.
25959         Too many systems seem to lack it.
25960
25961         * m4/strftime.m4: Add checks for most of the cpp macros tested in
25962         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
25963
25964 1999-11-18  Paul Eggert  <eggert@twinsun.com>
25965
25966         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
25967         problem with the QNX 4.25 shell, which doesn't propagate exit
25968         status of failed commands inside shell assignments.
25969
25970 1999-11-17  Jim Meyering  <meyering@ascend.com>
25971
25972         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
25973
25974 1999-11-07  Jim Meyering  <meyering@ascend.com>
25975
25976         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
25977
25978 1999-11-06  Jim Meyering  <meyering@ascend.com>
25979
25980         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
25981         * m4/jm-macros.m4 (jm_MACROS): Use it here.
25982
25983 1999-11-05  Jim Meyering  <meyering@ascend.com>
25984
25985         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
25986         configure.in of textutils, fileutils, and sh-utils into this one
25987         (shared between those packages) file.
25988         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
25989         AC_STRUCT_ST_BLKSIZE.
25990
25991 1999-11-03  Jim Meyering  <meyering@ascend.com>
25992
25993         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
25994         of AC_CHECK_TYPE checks includes unistd.h.
25995         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
25996         Suggestion from Akim Demaille.
25997
25998 1999-10-30  Jim Meyering  <meyering@ascend.com>
25999
26000         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
26001         m4-quoted string.
26002         * m4/ls-mntd-fs.m4: Likewise.
26003         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
26004         * m4/jm-winsz1.m4: Likewise.
26005
26006         * m4/const.m4: Remove file, since the fix made it into the experimental
26007         version of autoconf.
26008         * m4/mktime.m4: Likewise.
26009
26010         * m4/check-type.m4: Remove file, now that the latest version of
26011         AC_CHECK_TYPE takes a third arg to specify additional #includes.
26012
26013         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
26014         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
26015         AC_CHECK_TYPE.
26016
26017 1999-10-04  Jim Meyering  <meyering@ascend.com>
26018
26019         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
26020
26021 1999-09-22  Paul Eggert  <eggert@twinsun.com>
26022
26023         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
26024         2.95.1 bug with HP-UX 10.20.
26025
26026 1999-09-17  Jim Meyering  <meyering@ascend.com>
26027
26028         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
26029         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
26030         due to missing strdup (against sh-utils-2.0).
26031
26032 1999-08-29  Jim Meyering  <meyering@ascend.com>
26033
26034         * m4/jm-macros.m4: Require jm_BISON.
26035         * m4/bison.m4: New file.
26036
26037 1999-08-17  Paul Eggert  <eggert@twinsun.com>
26038
26039         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
26040         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
26041
26042 1999-08-05  Jim Meyering  <meyering@ascend.com>
26043
26044         * m4/getline.m4: Rename test file from conftestdata to conftest.data
26045         to avoid conflicts with `conftest' on 8+3 filesystems.
26046         Suggestion from Eli Zaretskii.
26047
26048 1999-08-04  Jim Meyering  <meyering@ascend.com>
26049
26050         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
26051         fileutils and sh-utils (textutils's getline test was inadequate).
26052         (AM_FUNC_GETLINE): Run this test.
26053         (AC_CHECK_FUNCS): Check for getdelim.
26054         Reported by Bob Proulx.
26055
26056 1999-08-02  Jim Meyering  <meyering@ascend.com>
26057
26058         * m4/jm-macros.m4: Add a comment.
26059
26060 1999-08-01  Paul Eggert  <eggert@twinsun.com>
26061
26062         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
26063         <inttypes.h> defines strtoumax as a macro (and not as a
26064         function).
26065
26066 1999-08-01  Paul Eggert  <eggert@twinsun.com>
26067
26068         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
26069         that we can shift, multiply and divide unsigned long long
26070         values; Ultrix cc can't do it.
26071
26072 1999-08-01  Paul Eggert  <eggert@twinsun.com>
26073
26074         * m4/mktime.m4: New file, which is a preview of what should appear
26075         in the next public autoconf release.
26076
26077 1999-08-01  Paul Eggert  <eggert@twinsun.com>
26078
26079         * m4/lfs.m4: Remove this file.
26080         * m4/largefile.m4: New file.  It contains the old contents of
26081         lfs.m4, except that all names with prefix AC_LFS have been
26082         changed to use the prefix AC_SYS_LARGEFILE instead, to be
26083         compatible with future autoconf versions.  Also, some minor m4
26084         quoting problems have been fixed.
26085
26086 1999-08-01  Paul Eggert  <eggert@twinsun.com>
26087
26088         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
26089         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
26090         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
26091         and simplify the shell code.
26092
26093 1999-08-01  Jim Meyering  <meyering@ascend.com>
26094
26095         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
26096         m4.
26097
26098 1999-07-20  Jim Meyering  <meyering@ascend.com>
26099
26100         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
26101
26102 1999-07-15  Jim Meyering  <meyering@ascend.com>
26103
26104         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
26105
26106 1999-05-22  Jim Meyering  <meyering@ascend.com>
26107
26108         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
26109
26110 1999-05-20  Jim Meyering  <meyering@ascend.com>
26111
26112         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
26113         Add a colon after each `then' in case $4 is empty.
26114
26115 1999-05-16  Jim Meyering  <meyering@ascend.com>
26116
26117         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
26118
26119 1999-05-10  Jim Meyering  <meyering@ascend.com>
26120
26121         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
26122
26123         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
26124         AC_FUNC_MKTIME.
26125
26126 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
26127
26128         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
26129
26130 1999-05-04  Paul Eggert  <eggert@twinsun.com>
26131
26132         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
26133         not CPPFLAGS, so that linking works correctly in IRIX.
26134
26135 1999-04-30  Paul Eggert  <eggert@twinsun.com>
26136
26137         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
26138
26139 1999-04-20  Paul Eggert  <eggert@twinsun.com>
26140
26141         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
26142         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
26143         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
26144         jm_AC_TYPE_UNSIGNED_LONG_LONG.
26145         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
26146
26147         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
26148
26149 1999-04-20  Jim Meyering  <meyering@ascend.com>
26150
26151         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
26152         AC_REPLACE xstroull if necessary.  From Paul Eggert.
26153         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
26154
26155 1999-04-18  Jim Meyering  <meyering@ascend.com>
26156
26157         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
26158         * m4/jm-macros.m4: Use it.
26159
26160 1999-04-06  Jim Meyering  <meyering@ascend.com>
26161
26162         * m4/strftime.m4: Remove test for %f.
26163
26164 1999-03-29  Jim Meyering  <meyering@ascend.com>
26165
26166         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
26167         superset of the AC_TYPE_* checks in the textutils, fileutils,
26168         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
26169         AC_TYPE_PID_T.
26170
26171 1999-03-28  Jim Meyering  <meyering@ascend.com>
26172
26173         * m4/jm-macros.m4: Define GNU_PACKAGE here.
26174         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
26175         replaced e.g., in the *.sh files of the sh-utils.
26176
26177 1999-03-20  Jim Meyering  <meyering@ascend.com>
26178
26179         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
26180         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
26181         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
26182
26183 1999-03-19  Jim Meyering  <meyering@ascend.com>
26184
26185         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
26186
26187 1999-03-12  Jim Meyering  <meyering@ascend.com>
26188
26189         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
26190
26191 1999-03-07  Jim Meyering  <meyering@ascend.com>
26192
26193         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
26194         declared.
26195
26196 1999-02-17  Jim Meyering  <meyering@ascend.com>
26197
26198         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
26199         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
26200
26201 1999-02-07  Jim Meyering  <meyering@ascend.com>
26202
26203         * m4/group-member.m4: New file -- extracted from sh-utils'
26204         configure.in.
26205
26206         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
26207         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
26208
26209 1999-02-06  Jim Meyering  <meyering@ascend.com>
26210
26211         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
26212         * m4/fnmatch.m4: Likewise.
26213         * m4/getgroups.m4: Likewise.
26214         * m4/lstat.m4: Likewise.
26215         * m4/malloc.m4: Likewise.
26216         * m4/putenv.m4: Likewise.
26217         * m4/realloc.m4: Likewise.
26218         * m4/regex.m4: Likewise.
26219         * m4/stat.m4: Likewise.
26220         * m4/strftime.m4: Likewise.
26221         Suggestion from Alain Magloire.
26222
26223         * m4/chown.m4: Use `.$ac_objext', not `.o'.
26224         * m4/fnmatch.m4: Likewise.
26225         * m4/getgroups.m4: Likewise.
26226         * m4/getline.m4: Likewise.
26227         * m4/lstat.m4: Likewise.
26228         * m4/malloc.m4: Likewise.
26229         * m4/memcmp.m4: Likewise.
26230         * m4/putenv.m4: Likewise.
26231         * m4/realloc.m4: Likewise.
26232         * m4/regex.m4: Likewise.
26233         * m4/stat.m4: Likewise.
26234         * m4/strftime.m4: Likewise.
26235         Suggestion from Alain Magloire.
26236
26237         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
26238         an argument.
26239
26240         * m4/regex.m4: Add a run-time Test for proper operation of
26241         re_compile_pattern.
26242
26243 1999-01-31  Jim Meyering  <meyering@ascend.com>
26244
26245         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
26246
26247 1999-01-30  Jim Meyering  <meyering@ascend.com>
26248
26249         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
26250
26251         * m4/jm-mktime.m4: Make this a wrapper around the official
26252         AM_FUNC_MKTIME rather than my private copy, now that the official one
26253         is up to date.
26254         * m4/mktime.m4: Remove file.
26255
26256         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
26257         * m4/uptime.m4: Likewise.
26258         * m4/uintmax_t.m4: Likewise.
26259
26260 1999-01-28  Jim Meyering  <meyering@ascend.com>
26261
26262         * m4/jm-macros.m4: Use jm_AFS.
26263         * m4/afs.m4: New file (from fileutils' configure.in).
26264
26265         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
26266         * m4/chown.m4: Likewise.
26267         * m4/d-ino.m4: Likewise.
26268         * m4/d-type.m4: Likewise.
26269         * m4/fnmatch.m4: Likewise.
26270         * m4/getgroups.m4: Likewise.
26271         * m4/gettext.m4: Likewise.
26272         * m4/jm-mktime.m4: Likewise.
26273         * m4/jm-winsz2.m4: Likewise.
26274         * m4/lcmessage.m4: Likewise.
26275         * m4/ls-mntd-fs.m4: Likewise.
26276         * m4/malloc.m4: Likewise.
26277         * m4/memcmp.m4: Likewise.
26278         * m4/putenv.m4: Likewise.
26279         * m4/realloc.m4: Likewise.
26280         * m4/st_mtim.m4: Likewise.
26281         * m4/strftime.m4: Likewise.
26282
26283 1999-01-16  Jim Meyering  <meyering@ascend.com>
26284
26285         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
26286         (ARGMATCH_DIE_DECL): Define.
26287
26288 1999-01-12  Jim Meyering  <meyering@ascend.com>
26289
26290         * m4/Makefile.am.in: Rewrite to avoid using fmt.
26291         Reported by Lars Hecking.
26292
26293 1999-01-10  Jim Meyering  <meyering@ascend.com>
26294
26295         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
26296         gross kludge.
26297         * m4/inttypes_h.m4: Likewise.
26298         * m4/lstat.m4: Likewise.
26299         * m4/malloc.m4: Likewise.
26300         * m4/readdir.m4: Likewise.
26301         * m4/realloc.m4: Likewise.
26302         * m4/st_dm_mode.m4: Likewise.
26303         * m4/stat.m4: Likewise.
26304         * m4/utimbuf.m4: Likewise.
26305         * m4/utimes.m4: Likewise.
26306
26307         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
26308         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
26309         comments in config.h.in are meaningful.
26310
26311         * m4/jm-macros.m4: Require autoconf-2.13 here.
26312
26313         * m4/regex.m4: By default, don't use the included regex.c on systems
26314         with glibc 2.  Suggestion from Uli Drepper.
26315
26316 1999-01-02  Jim Meyering  <meyering@ascend.com>
26317
26318         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
26319
26320 1998-12-18  Jim Meyering  <meyering@ascend.com>
26321
26322         * m4/Makefile.am.in (Makefile.am): Simplify rule.
26323         Based on a suggestion from Lars Hecking.
26324
26325 1998-11-16  Paul Eggert  <eggert@twinsun.com>
26326
26327         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
26328
26329 1998-11-16  Jim Meyering  <meyering@ascend.com>
26330
26331         * m4/lfs.m4: Double-quote the `uname...` expression.
26332
26333 1998-11-14  Jim Meyering  <meyering@ascend.com>
26334
26335         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
26336         * m4/stat.m4: Likewise.
26337
26338 1998-11-03  Jim Meyering  <meyering@ascend.com>
26339
26340         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
26341         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
26342
26343 1998-10-18  Jim Meyering  <meyering@ascend.com>
26344
26345         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
26346
26347 1998-10-17  Jim Meyering  <meyering@ascend.com>
26348
26349         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
26350         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
26351         calls for those previously hard-coded headers.  Instead, take a new
26352         parameter.
26353         (jm_CHECK_DECLARATIONS): Reflect interface change.
26354         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
26355         (jm_CHECK_DECL_LOCALTIME_R): New macro.
26356
26357         * m4/mktime.m4: Test for spring-forward gap before long-running test.
26358
26359 1998-10-14  Jim Meyering  <meyering@ascend.com>
26360
26361         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
26362         instead of "TZ=America/Vancouver".  From Paul Eggert.
26363
26364 1998-10-11  Jim Meyering  <meyering@ascend.com>
26365
26366         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
26367         This adds a test for a recently added compatibility fix for mktime.c.
26368         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
26369
26370 1998-09-27  Jim Meyering  <meyering@ascend.com>
26371
26372         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
26373
26374         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
26375         ../configure.in, including a change from Gordon Matzigkeit to allow
26376         cross-compiling for the Hurd.
26377
26378         * m4/glibc.m4: New file/macro to test for the GNU C Library
26379         versions 1 and 2.  From Gordon Matzigkeit.
26380         Indent.
26381
26382 1998-09-21  Jim Meyering  <meyering@ascend.com>
26383
26384         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
26385
26386 1998-08-18  Paul Eggert  <eggert@twinsun.com>
26387
26388         Port nanosecond-resolution times to UnixWare 2.1.2 and
26389         pedantic Solaris 2.6.
26390
26391         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
26392         AC_STRUCT_ST_MTIM.
26393         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
26394         Generate name of ns member, instead of just 1 or undef.
26395         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
26396
26397 1998-08-15  Jim Meyering  <meyering@ascend.com>
26398
26399         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
26400         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
26401         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
26402         instead of jm_TYPE_SSIZE_T.
26403
26404 1998-08-12  Jim Meyering  <meyering@ascend.com>
26405
26406         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
26407
26408 1998-08-02  Jim Meyering  <meyering@ascend.com>
26409
26410         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
26411         in acconfig.h manually.
26412
26413 1998-07-31  Paul Eggert  <eggert@twinsun.com>
26414
26415         * m4/st_mtim.m4: New file.
26416
26417 1998-07-28  Jim Meyering  <meyering@ascend.com>
26418
26419         * m4/utimes.m4: Undef stat.
26420
26421 1998-07-25  Jim Meyering  <meyering@ascend.com>
26422
26423         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
26424         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
26425
26426 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
26427
26428         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
26429         uid and gid actually remain unchanged.
26430
26431 1998-07-07  Jim Meyering  <meyering@ascend.com>
26432
26433         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
26434
26435 1998-07-04  Jim Meyering  <meyering@ascend.com>
26436
26437         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
26438         to prove that this macro can be used in packages without regex.c.
26439
26440 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
26441
26442         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
26443         is to be used.
26444
26445 1998-07-03  Jim Meyering  <meyering@ascend.com>
26446
26447         * m4/gettext.m4: Add -lintl if it's found to be necessary.
26448
26449         * m4/gettext.m4: New file -- from gettext-0.10.35.
26450         * m4/lcmessage.m4: Likewise.
26451         * m4/progtest.m4: Likewise.
26452
26453         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
26454         * m4/jm-macros.m4: Require the new macro.
26455
26456 1998-06-29  Jim Meyering  <meyering@ascend.com>
26457
26458         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
26459         for the definition of NGROUPS (used in a system header included
26460         by sys/mount.h).
26461
26462 1998-06-28  Jim Meyering  <meyering@ascend.com>
26463
26464         * m4/ls-mntd-fs.m4: New file.
26465         * m4/fstypename.m4: New file.
26466
26467         * m4/jm-macros.m4: Require the new macro.
26468         * m4/jm-glibc-io.m4: New file.
26469
26470 1998-05-19  Jim Meyering  <meyering@ascend.com>
26471
26472         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
26473         * m4/lchown.m4: New file.
26474
26475         * m4/Makefile.am.in: New file.
26476         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
26477
26478 1998-05-14  Jim Meyering  <meyering@ascend.com>
26479
26480         * m4/Makefile.am (EXTRA_DIST): Add them.
26481         * m4/jm-macros.m4: New file.
26482         * m4/utimbuf.m4: New file.
26483
26484 1998-05-12  Jim Meyering  <meyering@ascend.com>
26485
26486         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
26487
26488 1998-05-11  Jim Meyering  <meyering@ascend.com>
26489
26490         * m4/isc-posix.m4: New file.
26491
26492 1998-05-10  Jim Meyering  <meyering@ascend.com>
26493
26494         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
26495
26496 1998-05-09  Jim Meyering  <meyering@ascend.com>
26497
26498         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
26499         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
26500         with automake.
26501
26502         * m4/ssize_t.m4: New file.
26503         * m4/mktime.m4: Remove file -- the new automake has this now.
26504
26505 1998-04-26  Jim Meyering  <meyering@ascend.com>
26506
26507         * m4/assert.m4: New file.
26508         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
26509
26510 1998-04-05  Jim Meyering  <meyering@ascend.com>
26511
26512         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
26513         (jm_PREREQ): Use it here.
26514
26515 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
26516
26517         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
26518         in acconfig.h.
26519
26520 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
26521
26522         * m4/prereq.m4: New file.
26523         * m4/error.m4: New file.
26524         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
26525
26526 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
26527
26528         * m4/getline.m4: Don't set am_cv_func_working_getline before the
26529         cache-check for the same variable -- that defeated the purpose of
26530         the test; the test program was never run.  This was a problem only
26531         on systems with losing getline functions -- HP-UX 10.20 is one.
26532         Reported by Bjorn Helgaas.
26533
26534 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
26535
26536         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
26537
26538 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
26539
26540         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
26541
26542         * m4/const.m4: New file.  Use an initializer in this declaration
26543         typedef int charset[2]; const charset x;
26544         Reported by Bob Glickstein.
26545
26546 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
26547
26548         * m4/chown.m4: Fix reversed types on -1 args to chown.
26549         From Kaveh Ghazi.
26550
26551 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
26552
26553         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
26554         Add lseek and memchr.
26555
26556         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
26557         T.E.Dickey <dickey@clark.net> said that some older preprocessors
26558         have a 20-character limit on names.
26559
26560 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
26561
26562         * m4/inttypes_h.m4: New file.
26563         * m4/uintmax_t.m4: New file.
26564         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
26565
26566 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
26567   Free Software Foundation, Inc.
26568 Copying and distribution of this file, with or without modification,
26569 are permitted provided the copyright notice and this notice are preserved.