b4e602f48e1adc96b187d8af900b88ec798cec08
[gnulib.git] / ChangeLog
1 2007-02-01  Bruno Haible  <bruno@clisp.org>
2
3         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
4         renamings.
5
6 2007-02-01  Eric Blake  <ebb9@byu.net>
7
8         * modules/regex (Depends-on): Revert dependence on mempcpy.
9         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
10         module's definition of mempcpy.
11         Reported by Paul Eggert.
12
13 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
14
15         * lib/string_.h: If the gnulib module XYZ is not present, undefine
16         the symbol XYZ before redefining it.  This fixes a problem with
17         programs that don't use XYZ, when compiled on systems that define
18         XYZ to something else.
19
20 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
21
22         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
23         occurs when "mkdir -m foo" creates a setgid directory that is (1)
24         writeable to group or other and (2) is intended to have a special
25         mode bit that is set or cleared.  In such a case, the directory
26         should be neither group- nor other-writeable until the special
27         mode bits are right.
28
29 2007-01-31  Eric Blake  <ebb9@byu.net>
30
31         * modules/mountlist (Depends-on): Add strstr.
32
33         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
34         bug.
35         * modules/string (Makefile.am): Remove redundant replacement.
36         * modules/regex (Depends-on): Add mempcpy.
37
38 2007-01-31  Bruno Haible  <bruno@clisp.org>
39
40         New module description field 'Link'.
41         * gnulib-tool (func_usage): Document --extract-link-directive.
42         (sed_extract_prog): Recognize 'Link' directive.
43         (func_get_link_directive): New function.
44         (func_import): Show summary of link directives.
45         Handle --extract-link-directive option.
46         * modules/acl (Link): New section.
47         * modules/clock-time (Link): New section.
48         * modules/euidaccess (Link): New section.
49         * modules/gettext (Link): New section.
50         * modules/iconv (Link): New section.
51         * modules/lock (Link): New section.
52         * modules/nanosleep (Link): New section.
53         * modules/readline (Link): New section.
54
55 2007-01-27  Bruno Haible  <bruno@clisp.org>
56
57         Enforce the use of gnulib modules for unportable <string.h> functions.
58         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
59         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
60         (gl_HEADER_STRING_H_BODY): Require it.
61         * lib/string_.h: If the gnulib module XYZ is not present, redefine
62         the symbol XYZ to one that gives a link error.
63         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
64         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
65         * modules/mempcpy (configure.ac): Likewise.
66         * modules/memrchr (configure.ac): Likewise.
67         * modules/stpcpy (configure.ac): Likewise.
68         * modules/stpncpy (configure.ac): Likewise.
69         * modules/strcase (configure.ac): Likewise.
70         * modules/strcasestr (configure.ac): Likewise.
71         * modules/strchrnul (configure.ac): Likewise.
72         * modules/strdup (configure.ac): Likewise.
73         * modules/strndup (configure.ac): Likewise.
74         * modules/strnlen (configure.ac): Likewise.
75         * modules/strpbrk (configure.ac): Likewise.
76         * modules/strsep (configure.ac): Likewise.
77         * modules/strstr (configure.ac): Likewise.
78         * modules/strtok_r (configure.ac): Likewise.
79
80 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
81
82         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
83
84 2007-01-30  Jim Meyering  <jim@meyering.net>
85
86         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
87
88 2007-01-29  Bruno Haible  <bruno@clisp.org>
89
90         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
91         * lib/execute.c: Likewise.
92         * lib/pipe.c: Likewise.
93         * lib/printf-args.h: Likewise.
94         * lib/printf-args.c: Likewise.
95         * lib/printf-parse.c: Likewise.
96         * lib/vasnprintf.c: Likewise.
97
98 2007-01-29  Eric Blake  <ebb9@byu.net>
99
100         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
101         declaration.
102
103 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
104
105         * lib/strptime.h (strptime): Use 'restrict' for args where
106         POSIX requires this.
107         * lib/strptime.c (strptime): Likewise.
108         Change license notice from LGPL to GPL, since gnulib-tool will
109         change this as needed.
110         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
111         defined.
112         Include "strptime.h" first, to check interface.
113         Do not #undef _LIBC and _NL_CURRENT.
114         Do not include <stdlib.h>; no longer needed.
115         Include "time_r.h" and declare ptime_locale_status
116         only if _LIBC is not defined.
117         (__P): Remove unused macro.
118         (match_string): Bring back glibc version, but use it only if _LIBC
119         is defined.
120         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
121         Remove unnecessary assertion and abort() call.
122         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
123         * m4/strptime.m4: Fix serial number comment.
124         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
125         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
126         (Depends-on): Add time_r.
127
128 2007-01-29  Bruno Haible  <bruno@clisp.org>
129
130         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
131         strptime.
132         * modules/strptime (Depends-on): Add stdbool.
133         * lib/strptime.h: Include <time.h> always. Add comments.
134
135 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
136
137         * modules/strptime: New file.
138         * lib/strptime.h: New file.
139         * lib/strptime.c: New file.
140         * m4/strptime.m4: New file.
141
142 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
143
144         * MODULES.html.sh: New module mpsort.
145         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
146
147         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
148         a circularity problem with HP-UX ia64 reported by Bob Proulx in
149         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
150         All uses changed.
151         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
152         All uses changed.
153         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
154         to _Restrict_.
155         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
156         the parameter matches the prototype.
157
158 2007-01-28  Jim Meyering  <jim@meyering.net>
159
160         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
161         sys/time.h here, reverting that part of the previous patch:
162         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
163
164 2007-01-28  Bruno Haible  <bruno@clisp.org>
165
166         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
167         value of $(SYS_TIME_H).
168         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
169         remove it conditionally, too. [added by Jim Meyering]
170         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
171         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
172         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
173         GETTIMEOFDAY_REPLACEMENT to 1.
174
175 2007-01-28  Bruno Haible  <bruno@clisp.org>
176
177         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
178         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
179         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
180         Set UNISTD_H instead of UNISTD_H2.
181         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
182
183 2007-01-28  Bruno Haible  <bruno@clisp.org>
184
185         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
186         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
187
188 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
189
190         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
191         (func_create_testdir): Ensure C locale for `grep' and `tr'
192         character ranges.
193         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
194         ACLOCAL_AMFLAGS parsing state machine.
195
196 2007-01-27  Bruno Haible  <bruno@clisp.org>
197
198         * modules/unistr/base: Update.
199
200 2007-01-27  Bruno Haible  <bruno@clisp.org>
201
202         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
203         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
204         * modules/unistr/u32-mbtouc-unsafe: Renamed from
205         modules/unistr/u32-mbtouc.
206         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
207         * lib/unistr.h: Update.
208         * lib/linebreak.c: Update.
209         * modules/unistr/u32-mbtouc: Renamed from
210         modules/unistr/u32-mbtouc-safe.
211         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
212         * lib/unistr.h: Update.
213         * lib/unistr/u32-to-u8.c: Update.
214         * lib/unistr/u32-to-u16.c: Update.
215
216 2007-01-27  Bruno Haible  <bruno@clisp.org>
217
218         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
219         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
220         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
221         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
222         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
223         * modules/unistr/u16-mbtouc-unsafe: Renamed from
224         modules/unistr/u16-mbtouc.
225         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
226         * lib/unistr.h: Update.
227         * lib/linebreak.c: Update.
228         * modules/linebreak: Update.
229         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
230         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
231         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
232         * modules/unistr/u16-mbtouc: Renamed from
233         modules/unistr/u16-mbtouc-safe.
234         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
235         * lib/unistr.h: Update.
236         * lib/unistr/u16-to-u8.c: Update.
237         * modules/unistr/u16-to-u8: Update.
238         * lib/unistr/u16-to-u32.c: Update.
239         * modules/unistr/u16-to-u32: Update.
240
241 2007-01-27  Bruno Haible  <bruno@clisp.org>
242
243         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
244         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
245         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
246         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
247         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
248         * modules/unistr/u8-mbtouc-unsafe: Renamed from
249         modules/unistr/u8-mbtouc.
250         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
251         * lib/unistr.h: Update.
252         * lib/striconveh.c: Update.
253         * modules/striconveh: Update.
254         * lib/linebreak.c: Update.
255         * modules/linebreak: Update.
256         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
257         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
258         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
259         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
260         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
261         * lib/unistr.h: Update.
262         * lib/striconveh.c: Update.
263         * modules/striconveh: Update.
264         * lib/unistr/u8-to-u16.c: Update.
265         * modules/unistr/u8-to-u16: Update.
266         * lib/unistr/u8-to-u32.c: Update.
267         * modules/unistr/u8-to-u32: Update.
268
269 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
270
271         Sync from Libtool.
272         * lib/argz.c: Do not include strings.h nor memory.h, include
273         string.h unconditionally.  Patch by Simon Josefsson.
274
275 2007-01-27  Bruno Haible  <bruno@clisp.org>
276
277         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
278         from gl_HEADER_STRING_H_BODY.
279         (gl_HEADER_STRING_H_BODY): Require it.
280         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
281         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
282         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
283         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
284         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
285         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
286         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
287         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
288         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
289         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
290         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
291         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
292         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
293         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
294         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
295
296 2007-01-27  Bruno Haible  <bruno@clisp.org>
297
298         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
299         check_PROGRAMS into noinst_PROGRAMS.
300         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
301         check_PROGRAMS in this case.
302         (func_import): Set for_test to false.
303         (func_create_testdir): Set for_test to true.
304
305 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
306             Bruno Haible  <bruno@clisp.org>
307
308         * modules/strcasestr (Files): Remove lib/strcasestr.h.
309         (Depends-on): Add string.
310         (Includes): Use <string.h> instead of strcasestr.h.
311         * modules/string (Makefile.am): Also substitute the value of
312         REPLACE_STRCASESTR.
313         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
314         assume strcasestr is declared in <string.h> not <strings.h>. Also
315         set REPLACE_STRCASESTR.
316         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
317         REPLACE_STRCASESTR.
318         * lib/strcasestr.h: Remove file.
319         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
320         * lib/string_.h (strcasestr): New declaration.
321
322 2007-01-27  Bruno Haible  <bruno@clisp.org>
323
324         * lib/string_.h: Use 'extern'.
325
326 2007-01-27  Jim Meyering  <jim@meyering.net>
327
328         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
329         of set-but-not-used local, "q".
330
331         * lib/mempcpy.c: Include <config.h> before <string.h>.
332         This fixes a compilation error on HP-UX, due to the system's
333         "restrict"-using mempcpy prototype.
334
335 2007-01-26  Bruno Haible  <bruno@clisp.org>
336
337         Small optimization.
338         * lib/javacomp.c: Include c-strstr.h.
339          (is_envjavac_gcj): Use c_strstr instead of strstr.
340         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
341
342 2007-01-26  Bruno Haible  <bruno@clisp.org>
343
344         * MODULES.html.sh (Unicode string functions): Add the new modules.
345
346         * modules/uniconv/u32-strconv-to-locale: New file.
347         * lib/uniconv/u32-strconv-to-locale.c: New file.
348
349         * modules/uniconv/u16-strconv-to-locale: New file.
350         * lib/uniconv/u16-strconv-to-locale.c: New file.
351
352         * modules/uniconv/u8-strconv-to-locale: New file.
353         * lib/uniconv/u8-strconv-to-locale.c: New file.
354
355         * modules/uniconv/u32-strconv-from-locale: New file.
356         * lib/uniconv/u32-strconv-from-locale.c: New file.
357
358         * modules/uniconv/u16-strconv-from-locale: New file.
359         * lib/uniconv/u16-strconv-from-locale.c: New file.
360
361         * modules/uniconv/u8-strconv-from-locale: New file.
362         * lib/uniconv/u8-strconv-from-locale.c: New file.
363
364         * modules/uniconv/u32-strconv-to-enc: New file.
365         * lib/uniconv/u32-strconv-to-enc.c: New file.
366         * modules/uniconv/u32-strconv-to-enc-tests: New file.
367         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
368
369         * modules/uniconv/u16-strconv-to-enc: New file.
370         * lib/uniconv/u16-strconv-to-enc.c: New file.
371         * lib/uniconv/u-strconv-to-enc.h: New file.
372         * modules/uniconv/u16-strconv-to-enc-tests: New file.
373         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
374
375         * modules/uniconv/u8-strconv-to-enc: New file.
376         * lib/uniconv/u8-strconv-to-enc.c: New file.
377         * modules/uniconv/u8-strconv-to-enc-tests: New file.
378         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
379
380         * modules/uniconv/u32-strconv-from-enc: New file.
381         * lib/uniconv/u32-strconv-from-enc.c: New file.
382         * modules/uniconv/u32-strconv-from-enc-tests: New file.
383         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
384
385         * modules/uniconv/u16-strconv-from-enc: New file.
386         * lib/uniconv/u16-strconv-from-enc.c: New file.
387         * modules/uniconv/u16-strconv-from-enc-tests: New file.
388         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
389
390         * modules/uniconv/u8-strconv-from-enc: New file.
391         * lib/uniconv/u8-strconv-from-enc.c: New file.
392         * lib/uniconv/u-strconv-from-enc.h: New file.
393         * modules/uniconv/u8-strconv-from-enc-tests: New file.
394         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
395
396         * modules/uniconv/u32-conv-from-enc: New file.
397         * lib/uniconv/u32-conv-from-enc.c: New file.
398         * modules/uniconv/u32-conv-from-enc-tests: New file.
399         * tests/uniconv/test-u32-conv-from-enc.c: New file.
400
401         * modules/uniconv/u16-conv-from-enc: New file.
402         * lib/uniconv/u16-conv-from-enc.c: New file.
403         * lib/uniconv/u-conv-from-enc.h: New file.
404         * modules/uniconv/u16-conv-from-enc-tests: New file.
405         * tests/uniconv/test-u16-conv-from-enc.c: New file.
406
407         * modules/uniconv/u8-conv-from-enc: New file.
408         * lib/uniconv/u8-conv-from-enc.c: New file.
409         * modules/uniconv/u8-conv-from-enc-tests: New file.
410         * tests/uniconv/test-u8-conv-from-enc.c: New file.
411
412         * modules/uniconv/base: New file.
413         * lib/uniconv.h: New file.
414
415 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
416
417         * doc/gnulib-tool.texi (Initial import): Update to match current
418         behavior with strdup module.
419         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
420         * lib/memmem.h: Remove; all uses removed.  This is now done
421         by <string.h>.
422         * lib/mempcpy.h: Likewise.
423         * lib/memrchr.h: Likewise.
424         * lib/stpcpy.h: Likewise.
425         * lib/stpncpy.h: Likewise.
426         * lib/strcase.h: Likewise.
427         * lib/strchrnul.h: Likewise.
428         * lib/strdup.h: Likewise.
429         * lib/strndup.h: Likewise.
430         * lib/strnlen.h: Likewise.
431         * lib/strpbrk.h: Likewise.
432         * lib/strsep.h: Likewise.
433         * lib/strstr.h: Likewise.
434         * lib/strtok_r.h: Likewise.
435         * lib/string_.h: New file.
436         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
437         Rely on <string.h> instead.
438         * lib/canon-host.c: Likewise.
439         * lib/chdir-long.c: Likewise.
440         * lib/concatpath.c: Likewise.
441         * lib/exclude.c: Likewise.
442         * lib/fchdir.c: Likewise.
443         * lib/getaddrinfo.c: Likewise.
444         * lib/getcwd.c: Likewise.
445         * lib/getsubopt.c: Likewise.
446         * lib/glob.c: Likewise.
447         * lib/hard-locale.c: Likewise.
448         * lib/iconvme.c: Likewise.
449         * lib/javacomp.c: Likewise.
450         * lib/mempcpy.c: Likewise.
451         * lib/memrchr.c: Likewise.
452         * lib/regex_internal.h: Likewise.
453         * lib/stpncpy.c: Likewise.
454         * lib/strcasecmp.c: Likewise.
455         * lib/strchrnul.c: Likewise.
456         * lib/strdup.c: Likewise.
457         * lib/striconv.c: Likewise.
458         * lib/striconveh.c: Likewise.
459         * lib/striconveha.c: Likewise.
460         * lib/strncasecmp.c: Likewise.
461         * lib/strndup.c: Likewise.
462         * lib/strnlen.c: Likewise.
463         * lib/strsep.c: Likewise.
464         * lib/strstr.c: Likewise.
465         * lib/strtok_r.c: Likewise.
466         * lib/userspec.c: Likewise.
467         * lib/w32spawn.h: Likewise.
468         * lib/xstrndup.c: Likewise.
469         * lib/mountlist.c (strstr): Remove decl.
470         * m4/string_h.m4: New file.
471         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
472         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
473         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
474         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
475         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
476         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
477         Set REPLACE_STRCASECMP if necessary.
478         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
479         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
480         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
481         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
482         HAVE_DECL_STRDUP if necessary.
483         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
484         since gl_FUNC_STRNDUP does that now.
485         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
486         Check for decl here...
487         (gl_PREREQ_STRNLEN): ... not here.
488         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
489         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
490         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
491         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
492         necessary.
493         * modules/string: New file.
494         * modules/memmem (Files): Remove special-purpose include file.
495         (Depends-on): Add string.
496         (Include): Include <string.h>, not the removed file.
497         * modules/mempcpy: Likewise.
498         * modules/memrchr: Likewise.
499         * modules/stpcpy: Likewise.
500         * modules/stpncpy: Likewise.
501         * modules/strcase: Likewise.
502         * modules/strchrnul: Likewise.
503         * modules/strdup: Likewise.
504         * modules/strndup: Likewise.
505         * modules/strnlen: Likewise.
506         * modules/strpbrk: Likewise.
507         * modules/strsep: Likewise.
508         * modules/strstr: Likewise.
509         * modules/strtok_r: Likewise.
510         * tests/test-dirname.c: Don't include "strdup.h", since
511         <string.h> now suffices.
512         * tests/test-memmem.c: Don't include "memmem.h", since
513         <string.h> now suffices.
514
515 2007-01-25  Bruno Haible  <bruno@clisp.org>
516
517         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
518         *resultp is 0.
519
520         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
521         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
522         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
523         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
524
525         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
526         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
527         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
528         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
529         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
530         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
531
532 2007-01-24  Bruno Haible  <bruno@clisp.org>
533
534         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
535         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
536         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
537         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
538         gl_FUNC_FTS_CORE.
539         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
540         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
541         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
542         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
543         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
544         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
545         gl_FUNC_FCHOWNAT.
546         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
547         gl_FUNC_STRFTIME.
548         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
549         Reported by Ralf Wildenhues.
550
551 2007-01-24  Bruno Haible  <bruno@clisp.org>
552
553         Drop AC_REQUIRE calls that are redundant with the module dependencies.
554         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
555         gl_GETADDRINFO.
556         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
557         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
558         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
559
560 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
561
562         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
563         Don't use 'exit'; just return from 'main'.
564         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
565
566         * lib/fnmatch_.h: Readjust white space and comments to match
567         glibc, to avoid spurious diffs.
568
569 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
570
571         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
572         2004-12-01 change by Jakub Jelinek, since this code won't compile
573         if !LIBC.  Problem reported by Bob Proulx.
574
575 2007-01-23  Bruno Haible  <bruno@clisp.org>
576
577         * lib/striconveh.c: Include c-strcaseeq.h.
578         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
579         * modules/striconveh (Depends-on): Add c-strcaseeq.
580
581 2007-01-23  Bruno Haible  <bruno@clisp.org>
582
583         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
584
585         * modules/c-strcaseeq: New file.
586         * lib/c-strcaseeq.h: New file.
587
588         * modules/streq: New file.
589         * lib/streq.h: New file.
590
591 2007-01-23  Bruno Haible  <bruno@clisp.org>
592
593         * modules/striconveha-tests: New file.
594         * tests/test-striconveha.c: New file.
595
596         * lib/striconveha.h: Include <stdbool.h>.
597         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
598         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
599         (mem_iconveha_notranslit): Renamed from mem_iconveha.
600         (mem_iconveha): New function.
601         (str_iconveha_notranslit): Renamed from str_iconveha.
602         (str_iconveha): New function.
603         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
604         c-strcase.
605
606 2007-01-23  Bruno Haible  <bruno@clisp.org>
607
608         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
609         encodings without forgiving before trying any encoding with handler.
610         (str_iconveha): Try all encodings without forgiving before trying any
611         encoding with handler.
612
613 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
614
615         Import the following changes from libc.
616
617         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
618
619         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
620
621         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
622
623         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
624         normal_bracket label.
625
626         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
627
628         [BZ #361]
629         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
630         to normal_bracket after fetching the next character.
631
632 2007-01-22  Bruno Haible  <bruno@clisp.org>
633
634         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
635         argument.
636         * lib/striconveh.c (iconv_carefully_1): New function.
637         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
638         argument.
639         (str_cd_iconveh): Update.
640         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
641         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
642         * tests/test-striconveh.c (MAGIC): New macro.
643         (new_offsets): New function.
644         (main): Test call with and without offsets.
645
646 2007-01-22  Bruno Haible  <bruno@clisp.org>
647
648         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
649         * modules/sys_select (Makefile.am): Likewise.
650         * modules/sys_socket (Makefile.am): Likewise.
651         * modules/sys_time (Makefile.am): Likewise.
652
653 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
654
655         * modules/gettimeofday (License): Change from GPL to LGPL, since
656         gettimeofday is a library function.
657
658 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
659
660         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
661
662 2007-01-21  Bruno Haible  <bruno@clisp.org>
663
664         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
665
666 2007-01-21  Bruno Haible  <bruno@clisp.org>
667
668         * modules/striconveha: New file.
669         * lib/striconveha.h: New file.
670         * lib/striconveha.c: New file.
671         * MODULES.html.sh (Internationalization functions): Add striconveha.
672         * lib/striconv.c (str_iconv): Optimize the case of an empty input
673         string.
674         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
675
676 2007-01-21  Bruno Haible  <bruno@clisp.org>
677
678         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
679         * lib/striconveh.c (str_iconveh): Likewise.
680
681 2007-01-21  Bruno Haible  <bruno@clisp.org>
682
683         * lib/striconveh.h (mem_iconveh): New declaration.
684         * lib/striconveh.c (mem_iconveh): New function.
685         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
686
687 2007-01-21  Bruno Haible  <bruno@clisp.org>
688
689         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
690
691         * lib/striconveh.h (mem_cd_iconveh): Change specification.
692         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
693         original result buffer.
694         (str_cd_iconveh): Update.
695         * tests/test-striconveh.c (main): Update.
696
697         * lib/striconv.h (mem_cd_iconv): Change specification.
698         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
699         result buffer.
700         (str_cd_iconv): Update.
701         * tests/test-striconv.c (main): Update.
702
703 2007-01-21  Bruno Haible  <bruno@clisp.org>
704
705         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
706
707 2007-01-20  Jim Meyering  <jim@meyering.net>
708
709         * lib/userspec.c (parse_with_separator): If a user or group string
710         starts with "+", skip the corresponding name-to-ID look-up, since
711         such a look-up must fail: user and group names may not include "+".
712
713 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
714
715         * lib/poll.c: Include sys/time.h and time.h unconditionally,
716         since we now assume the sys_time module.
717         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
718         check for sys/time.h; no longer needed.
719         * modules/poll (Depends-on): Depend on sys_time.
720
721 2007-01-18  Bruno Haible  <bruno@clisp.org>
722
723         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
724         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
725
726         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
727         gettimeofday.
728
729         * tests/test-gettimeofday.c: Include <time.h>.
730         (dummy): Remove variable.
731
732         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
733         gl_HEADER_SYS_TIME_H.
734         (gl_HEADER_SYS_TIME_H): New macro.
735
736         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
737         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
738         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
739         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
740         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
741         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
742         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
743         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
744         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
745         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
746         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
747
748         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
749         last change; it caused a compilation error when cross-compiling to
750         Cygwin.
751
752 2007-01-18  Jim Meyering  <jim@meyering.net>
753
754         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
755         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
756         than the race-prone "test -d sys || mkdir sys".
757         (configure.ac): Use AC_PROG_MKDIR_P.
758         * modules/sys_select: Likewise.
759         * modules/sys_socket: Likewise.
760         * modules/sys_time: Likewise.
761
762 2007-01-18  Eric Blake  <ebb9@byu.net>
763
764         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
765         replace gettimeofday.
766         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
767         name, to avoid infinite recursion.
768
769 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
770
771         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
772         module sys_time.
773         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
774         assume timespec.h defines struct timeval.
775         * lib/settime.c: Likewise.
776         * lib/utimens.c: Likewise.
777         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
778         since we now assume the gettimeofday module.
779         * lib/tempname.c (__gen_tempname): Likewise.
780         * lib/gettimeofday.h: Remove.
781         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
782         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
783         Include <time.h>, for 'time()'.
784         (localtime_buffer_addr): Also use this workaround if
785         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
786         to simplify the uses.  All uses changed.
787         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
788         that #undef is inside {}, and 'const' follows type name consistently.
789         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
790         (gettimeofday): Do not use the maximum possible value for
791         tv->tv_usec, since that might break usages other than ls.c.
792         Instead, we'll leave ls.c alone.  This undoes today's patch
793         by Bruno.  Add a compile-time warning for 1s-clock resolution;
794         we've never observed the problem but might as well keep the
795         canary.
796         * lib/nanosleep.c: Include timespec.h first, for interface check.
797         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
798         now assume the sys_time module.
799         * lib/tempname.c: Likewise.
800         * lib/timespec.h: Likewise.
801         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
802         needed.
803         * lib/strftime.c: Likewise.
804         * lib/timespec.h: Likewise.
805         * lib/posixtm.c: Include posixtm.h first, for interface check.
806         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
807         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
808         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
809         * lib/sys_time_.h: New file.
810         * lib/timespec.h (struct timespec): Use long int, not long.
811         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
812         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
813         Remove obsolescent call to AC_HEADER_TIME.
814         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
815         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
816         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
817         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
818         Likewise.
819         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
820         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
821         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
822         into the sys_time module.  Check for gettimeofday just once.
823         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
824         for gettimeofday signature to just check the signature.  Merely
825         compile it, since linking doesn't test signature.  Improve test for
826         whether gettimeofday.o is actually needed.
827         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
828         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
829         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
830         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
831         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
832         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
833         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
834         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
835         than worrying about sys/time.h.
836         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
837         Don't bother worrying about TIME_WITH_SYS_TIME.
838         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
839         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
840         * m4/sys_time_h.m4: New file.
841         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
842         Don't include sys/time.h.  Return from main rather than exiting.
843         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
844         all uses changed.
845         * modules/gethrxtime (Depends-on): Add sys_time.
846         * modules/gettime (Depends-on): Likewise.
847         * modules/gettimeofday (Depends-on): Likewise.
848         * modules/nanosleep (Depends-on): Likewise.
849         * modules/settime (Depends-on): Likewise.
850         * modules/tempname (Depends-on): Likewise.
851         * modules/utimens (Depends-on): Likewise.
852         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
853         (Include:) Change back to <sys/time.h>.
854         (Maintainer:) Add self.
855         * modules/sys_time: New file.
856         * modules/tempname (Depends-on): Add gettimeofday.
857         * tests/test-gettimeofday.c: Include <sys/time.h>
858         rather than gettimeofday.h.
859
860 2007-01-17  Bruno Haible  <bruno@clisp.org>
861
862         * gnulib-tool (func_get_license): Revert last patch. Instead, let
863         the license default to GPL.
864         (func_create_testdir): Don't complain if a module is LGPL and its
865         tests module depends on GPLed modules.
866
867 2007-01-17  Bruno Haible  <bruno@clisp.org>
868
869         * lib/gettimeofday.c (gettimeofday): Add code for the case
870         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
871         maximum possible value for tv->tv_usec, rather than the minimum one.
872
873 2005-10-08  Martin Lambers  <marlam@marlam.de>
874 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
875 2007-01-16  Bruno Haible  <bruno@clisp.org>
876
877         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
878         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
879         gl_FUNC_GETTIMEOFDAY.
880         (Include): Add gettimeofday.h.
881         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
882         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
883         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
884         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
885         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
886         * lib/gettimeofday.h: New file.
887         * lib/gettimeofday.c: Include <sys/timeb.h>.
888         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
889         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
890         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
891         fall back on time().
892
893         * tests/test-gettimeofday.c: New file.
894         * modules/gettimeofday-tests: New file.
895
896 2007-01-16  Eric Blake  <ebb9@byu.net>
897
898         * modules/fnmatch (Depends-on): Depend on wchar.
899         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
900         * m4/fnmatch.m4: Likewise.
901         * modules/mbchar (Makefile.am): Assume <wchar.h>.
902         * m4/mbchar.m4: Likewise.
903         * modules/mbswidth (Depends-on): Depend on wchar.
904         * lib/mbswidth.c: Assume <wchar.h>.
905         * m4/mbswidth.m4: Likewise.
906         * modules/quotearg (Depends-on): Depend on wchar.
907         * lib/quotearg.c: Assume <wchar.h>.
908         * m4/quotearg.m4: Likewise.
909         * modules/regex (Depends-on): Depend on wchar.
910         * lib/regex_internal.h: Assume <wchar.h>.
911         * m4/regex.m4: Likewise.
912         * modules/stdint (Depends-on): Depend on wchar.
913         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
914         * m4/stdint.m4: Likewise.
915         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
916         * modules/strftime (Depends-on): Depend on wchar.
917         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
918         * modules/strtol (Depends-on): Depend on wchar.
919         * lib/strtol.c: Assume <wchar.h>.
920         * modules/wcwidth (Depends-on): Depend on wchar.
921         * lib/wcwidth.h: Assume <wchar.h>.
922         * m4/wcwidth.m4: Likewise.
923
924 2007-01-16  Bruno Haible  <bruno@clisp.org>
925
926         * modules/csharpexec-script: New, created from...
927         * modules/csharpexec: ... this.
928
929 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
930
931         * modules/javaexec-script: New, created from...
932         * modules/javaexec: ... this.
933
934 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
935
936         * modules/poll (Dependencies): Add sys_select.
937
938 2007-01-15  Jim Meyering  <jim@meyering.net>
939
940         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
941         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
942         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
943         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
944
945 2007-01-15  Bruno Haible  <bruno@clisp.org>
946
947         * modules/striconveh: New file.
948         * lib/striconveh.h: New file.
949         * lib/striconveh.c: New file.
950         * MODULES.html.sh (Internationalization functions): Add striconveh.
951
952         * modules/striconveh-tests: New file.
953         * tests/test-striconveh.c: New file.
954
955 2007-01-15  Bruno Haible  <bruno@clisp.org>
956
957         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
958         not from GNU libiconv or GNU libc.
959
960 2007-01-15  Bruno Haible  <bruno@clisp.org>
961
962         * doc/gnulib-intro.texi (Copyright): Explain the different license
963         terms for module descriptions, autoconf macros, tests, documentation.
964
965 2007-01-14  Bruno Haible  <bruno@clisp.org>
966
967         * modules/striconv-tests: New file.
968         * tests/test-striconv.c: New file.
969
970 2007-01-14  Bruno Haible  <bruno@clisp.org>
971
972         * modules/iconv-tests: New file.
973         * tests/test-iconv.c: New file.
974
975 2007-01-14  Bruno Haible  <bruno@clisp.org>
976
977         * gnulib-tool (func_get_license): For test modules, use the license of
978         the main module.
979
980 2007-01-14  Bruno Haible  <bruno@clisp.org>
981
982         * modules/iconv (Include): Clarify that <iconv.h> can only be included
983         if iconv is found to exist.
984
985 2007-01-14  Bruno Haible  <bruno@clisp.org>
986
987         * modules/c-ctype-tests: New file.
988         * tests/test-c-ctype.c: New file.
989
990 2007-01-14  Bruno Haible  <bruno@clisp.org>
991
992         * modules/binary-io-tests: New file.
993         * tests/test-binary-io.sh: New file.
994         * tests/test-binary-io.c: New file.
995
996 2007-01-14  Bruno Haible  <bruno@clisp.org>
997
998         * modules/array-oset-tests: New file.
999         * tests/test-array_oset.c: New file.
1000
1001 2007-01-14  Bruno Haible  <bruno@clisp.org>
1002
1003         * modules/array-list-tests: New file.
1004         * tests/test-array_list.c: New file.
1005
1006 2007-01-14  Bruno Haible  <bruno@clisp.org>
1007
1008         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
1009         and make.
1010         Reported by Simon Josefsson in
1011         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
1012
1013 2007-01-14  Bruno Haible  <bruno@clisp.org>
1014
1015         * modules/allocsa-tests: New file.
1016         * tests/test-allocsa.c: New file.
1017
1018 2007-01-14  Bruno Haible  <bruno@clisp.org>
1019
1020         * modules/fchdir (Depends-on): Add absolute-header.
1021         * modules/unistd (Depends-on): Likewise.
1022
1023 2006-12-30  Bruno Haible  <bruno@clisp.org>
1024
1025         * modules/fchdir: New file.
1026         * modules/unistd (Files): Add lib/unistd_.h.
1027         (Makefile.am): Generate unistd.h from unistd_.h.
1028         * lib/fchdir.c: New file.
1029         * lib/dirent_.h: New file.
1030         * lib/unistd_.h: New file.
1031         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
1032         * m4/fchdir.m4: New file.
1033         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
1034         (gl_HEADER_UNISTD): Invoke it.
1035         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
1036         function.
1037         * lib/backupfile.c (opendir, closedir): Undefine.
1038         * lib/chown.c (open, close): Undefine.
1039         * lib/clean-temp.c (open, close): Undefine.
1040         * lib/copy-file.c (open, close): Undefine.
1041         * lib/execute.c (open, close): Undefine.
1042         * lib/fsusage.c (open, close): Undefine.
1043         * lib/gc-gnulib.c (open, close): Undefine.
1044         * lib/getcwd.c (opendir, closedir): Undefine.
1045         * lib/glob.c (opendir, closedir): Undefine.
1046         * lib/javacomp.c (open, close): Undefine.
1047         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
1048         * lib/openat-proc.c (open, close): Undefine.
1049         * lib/pagealign_alloc.c (open, close): Undefine.
1050         * lib/pipe.c (open, close): Undefine.
1051         * lib/progreloc.c (open, close): Undefine.
1052         * lib/savedir.c (opendir, closedir): Undefine.
1053         * lib/utime.c (open, close): Undefine.
1054         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
1055
1056 2007-01-10  Bruno Haible  <bruno@clisp.org>
1057
1058         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
1059
1060 2007-01-12  Eric Blake  <ebb9@byu.net>
1061
1062         Provide a robust <wchar.h>.  Further simplifications are now
1063         possible in other modules, but not included here.
1064         * modules/wchar: New module.
1065         * m4/wchar.m4: New file.
1066         * lib/wchar_.h: Likewise.
1067         * modules/mbchar (Depends-on): Depend on wchar, as the first use
1068         of the new module.
1069         * MODULES.html.sh (Extended multibyte and wide character utilities):
1070         New section.
1071
1072 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
1073
1074         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
1075         to a reasonable default for memory allocation.
1076         (xreadlink): Don't allocate a huge buffer, to work around a buggy
1077         file system that reports garbage st_size values for symlinks.
1078         Problem reported by Liyang Hu.
1079
1080 2007-01-11  Simon Josefsson  <simon@josefsson.org>
1081
1082         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
1083         Emacs .#* auto-save files).
1084
1085 2007-01-11  Bruno Haible  <bruno@clisp.org>
1086
1087         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
1088         directory.
1089
1090 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
1091
1092         Use @...@ consistently in lib/wctype_.h.
1093         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
1094         on it being set to 1 or 0.
1095         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
1096         go back to AC_SUBSTing it.
1097         * modules/wctype (Makefile.am): Undo previous change.
1098
1099 2007-01-10  Eric Blake  <ebb9@byu.net>
1100
1101         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
1102         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
1103         * modules/wctype (Makefile.am): Likewise.
1104         Reported by Chris McGuire.
1105
1106 2007-01-10  Jim Meyering  <jim@meyering.net>
1107
1108         fts.c: a small readability/maintainability improvement
1109         * lib/fts.c (fts_read): Make this code slightly more readable and
1110         maintainable by hoisting the "sp->fts_cur = p" assignments to
1111         immediately follow the statements that set P.  Derived from
1112         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
1113
1114 2007-01-10  Eric Blake  <ebb9@byu.net>
1115
1116         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
1117         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
1118         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
1119         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
1120         Reported by Chris McGuire.
1121
1122 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1123
1124         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
1125         in sed script.
1126
1127 2007-01-09  Bruno Haible  <bruno@clisp.org>
1128
1129         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
1130         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
1131         variables.
1132         (func_module): Use them.
1133
1134 2007-01-09  Bruno Haible  <bruno@clisp.org>
1135
1136         * modules/unistr/base: New file.
1137         * lib/unistr.h: New file.
1138
1139         * modules/unistr/u8-to-u16: New file.
1140         * lib/unistr/u8-to-u16.c: New file.
1141
1142         * modules/unistr/u8-to-u32: New file.
1143         * lib/unistr/u8-to-u32.c: New file.
1144
1145         * modules/unistr/u16-to-u8: New file.
1146         * lib/unistr/u16-to-u8.c: New file.
1147
1148         * modules/unistr/u16-to-u32: New file.
1149         * lib/unistr/u16-to-u32.c: New file.
1150
1151         * modules/unistr/u32-to-u8: New file.
1152         * lib/unistr/u32-to-u8.c: New file.
1153
1154         * modules/unistr/u32-to-u16: New file.
1155         * lib/unistr/u32-to-u16.c: New file.
1156
1157         * modules/unistr/u8-check: New file.
1158         * modules/unistr/u16-check: New file.
1159         * modules/unistr/u32-check: New file.
1160         * lib/unistr/u8-check.c: New file.
1161         * lib/unistr/u16-check.c: New file.
1162         * lib/unistr/u32-check.c: New file.
1163
1164         * modules/unistr/u8-chr: New file.
1165         * modules/unistr/u16-chr: New file.
1166         * modules/unistr/u32-chr: New file.
1167         * lib/unistr/u8-chr.c: New file.
1168         * lib/unistr/u16-chr.c: New file.
1169         * lib/unistr/u32-chr.c: New file.
1170
1171         * modules/unistr/u8-cmp: New file.
1172         * modules/unistr/u16-cmp: New file.
1173         * modules/unistr/u32-cmp: New file.
1174         * lib/unistr/u8-cmp.c: New file.
1175         * lib/unistr/u16-cmp.c: New file.
1176         * lib/unistr/u32-cmp.c: New file.
1177
1178         * modules/unistr/u8-cpy: New file.
1179         * modules/unistr/u16-cpy: New file.
1180         * modules/unistr/u32-cpy: New file.
1181         * lib/unistr/u8-cpy.c: New file.
1182         * lib/unistr/u16-cpy.c: New file.
1183         * lib/unistr/u32-cpy.c: New file.
1184         * lib/unistr/u-cpy.h: New file.
1185
1186         * modules/unistr/u8-cpy-alloc: New file.
1187         * modules/unistr/u16-cpy-alloc: New file.
1188         * modules/unistr/u32-cpy-alloc: New file.
1189         * lib/unistr/u8-cpy-alloc.c: New file.
1190         * lib/unistr/u16-cpy-alloc.c: New file.
1191         * lib/unistr/u32-cpy-alloc.c: New file.
1192         * lib/unistr/u-cpy-alloc.h: New file.
1193
1194         * modules/unistr/u8-endswith: New file.
1195         * modules/unistr/u16-endswith: New file.
1196         * modules/unistr/u32-endswith: New file.
1197         * lib/unistr/u8-endswith.c: New file.
1198         * lib/unistr/u16-endswith.c: New file.
1199         * lib/unistr/u32-endswith.c: New file.
1200         * lib/unistr/u-endswith.h: New file.
1201
1202         * modules/unistr/u8-mblen: New file.
1203         * modules/unistr/u16-mblen: New file.
1204         * modules/unistr/u32-mblen: New file.
1205         * lib/unistr/u8-mblen.c: New file.
1206         * lib/unistr/u16-mblen.c: New file.
1207         * lib/unistr/u32-mblen.c: New file.
1208
1209         * modules/unistr/u8-mbtouc: New file.
1210         * modules/unistr/u16-mbtouc: New file.
1211         * modules/unistr/u32-mbtouc: New file.
1212         * lib/unistr/u8-mbtouc.c: New file.
1213         * lib/unistr/u16-mbtouc.c: New file.
1214         * lib/unistr/u32-mbtouc.c: New file.
1215
1216         * modules/unistr/u8-mbtouc-safe: New file.
1217         * modules/unistr/u16-mbtouc-safe: New file.
1218         * modules/unistr/u32-mbtouc-safe: New file.
1219         * lib/unistr/u8-mbtouc-safe.c: New file.
1220         * lib/unistr/u16-mbtouc-safe.c: New file.
1221         * lib/unistr/u32-mbtouc-safe.c: New file.
1222
1223         * modules/unistr/u8-move: New file.
1224         * modules/unistr/u16-move: New file.
1225         * modules/unistr/u32-move: New file.
1226         * lib/unistr/u8-move.c: New file.
1227         * lib/unistr/u16-move.c: New file.
1228         * lib/unistr/u32-move.c: New file.
1229         * lib/unistr/u-move.h: New file.
1230
1231         * modules/unistr/u8-next: New file.
1232         * modules/unistr/u16-next: New file.
1233         * modules/unistr/u32-next: New file.
1234         * lib/unistr/u8-next.c: New file.
1235         * lib/unistr/u16-next.c: New file.
1236         * lib/unistr/u32-next.c: New file.
1237
1238         * modules/unistr/u8-prev: New file.
1239         * modules/unistr/u16-prev: New file.
1240         * modules/unistr/u32-prev: New file.
1241         * lib/unistr/u8-prev.c: New file.
1242         * lib/unistr/u16-prev.c: New file.
1243         * lib/unistr/u32-prev.c: New file.
1244
1245         * modules/unistr/u8-set: New file.
1246         * modules/unistr/u16-set: New file.
1247         * modules/unistr/u32-set: New file.
1248         * lib/unistr/u8-set.c: New file.
1249         * lib/unistr/u16-set.c: New file.
1250         * lib/unistr/u32-set.c: New file.
1251         * lib/unistr/u-set.h: New file.
1252
1253         * modules/unistr/u8-startswith: New file.
1254         * modules/unistr/u16-startswith: New file.
1255         * modules/unistr/u32-startswith: New file.
1256         * lib/unistr/u8-startswith.c: New file.
1257         * lib/unistr/u16-startswith.c: New file.
1258         * lib/unistr/u32-startswith.c: New file.
1259         * lib/unistr/u-startswith.h: New file.
1260
1261         * modules/unistr/u8-stpcpy: New file.
1262         * modules/unistr/u16-stpcpy: New file.
1263         * modules/unistr/u32-stpcpy: New file.
1264         * lib/unistr/u8-stpcpy.c: New file.
1265         * lib/unistr/u16-stpcpy.c: New file.
1266         * lib/unistr/u32-stpcpy.c: New file.
1267         * lib/unistr/u-stpcpy.h: New file.
1268
1269         * modules/unistr/u8-stpncpy: New file.
1270         * modules/unistr/u16-stpncpy: New file.
1271         * modules/unistr/u32-stpncpy: New file.
1272         * lib/unistr/u8-stpncpy.c: New file.
1273         * lib/unistr/u16-stpncpy.c: New file.
1274         * lib/unistr/u32-stpncpy.c: New file.
1275         * lib/unistr/u-stpncpy.h: New file.
1276
1277         * modules/unistr/u8-strcat: New file.
1278         * modules/unistr/u16-strcat: New file.
1279         * modules/unistr/u32-strcat: New file.
1280         * lib/unistr/u8-strcat.c: New file.
1281         * lib/unistr/u16-strcat.c: New file.
1282         * lib/unistr/u32-strcat.c: New file.
1283         * lib/unistr/u-strcat.h: New file.
1284
1285         * modules/unistr/u8-strchr: New file.
1286         * modules/unistr/u16-strchr: New file.
1287         * modules/unistr/u32-strchr: New file.
1288         * lib/unistr/u8-strchr.c: New file.
1289         * lib/unistr/u16-strchr.c: New file.
1290         * lib/unistr/u32-strchr.c: New file.
1291
1292         * modules/unistr/u8-strcmp: New file.
1293         * modules/unistr/u16-strcmp: New file.
1294         * modules/unistr/u32-strcmp: New file.
1295         * lib/unistr/u8-strcmp.c: New file.
1296         * lib/unistr/u16-strcmp.c: New file.
1297         * lib/unistr/u32-strcmp.c: New file.
1298
1299         * modules/unistr/u8-strcpy: New file.
1300         * modules/unistr/u16-strcpy: New file.
1301         * modules/unistr/u32-strcpy: New file.
1302         * lib/unistr/u8-strcpy.c: New file.
1303         * lib/unistr/u16-strcpy.c: New file.
1304         * lib/unistr/u32-strcpy.c: New file.
1305         * lib/unistr/u-strcpy.h: New file.
1306
1307         * modules/unistr/u8-strcspn: New file.
1308         * modules/unistr/u16-strcspn: New file.
1309         * modules/unistr/u32-strcspn: New file.
1310         * lib/unistr/u8-strcspn.c: New file.
1311         * lib/unistr/u16-strcspn.c: New file.
1312         * lib/unistr/u32-strcspn.c: New file.
1313         * lib/unistr/u-strcspn.h: New file.
1314
1315         * modules/unistr/u8-strdup: New file.
1316         * modules/unistr/u16-strdup: New file.
1317         * modules/unistr/u32-strdup: New file.
1318         * lib/unistr/u8-strdup.c: New file.
1319         * lib/unistr/u16-strdup.c: New file.
1320         * lib/unistr/u32-strdup.c: New file.
1321         * lib/unistr/u-strdup.h: New file.
1322
1323         * modules/unistr/u8-strlen: New file.
1324         * modules/unistr/u16-strlen: New file.
1325         * modules/unistr/u32-strlen: New file.
1326         * lib/unistr/u8-strlen.c: New file.
1327         * lib/unistr/u16-strlen.c: New file.
1328         * lib/unistr/u32-strlen.c: New file.
1329         * lib/unistr/u-strlen.h: New file.
1330
1331         * modules/unistr/u8-strmblen: New file.
1332         * modules/unistr/u16-strmblen: New file.
1333         * modules/unistr/u32-strmblen: New file.
1334         * lib/unistr/u8-strmblen.c: New file.
1335         * lib/unistr/u16-strmblen.c: New file.
1336         * lib/unistr/u32-strmblen.c: New file.
1337
1338         * modules/unistr/u8-strmbtouc: New file.
1339         * modules/unistr/u16-strmbtouc: New file.
1340         * modules/unistr/u32-strmbtouc: New file.
1341         * lib/unistr/u8-strmbtouc.c: New file.
1342         * lib/unistr/u16-strmbtouc.c: New file.
1343         * lib/unistr/u32-strmbtouc.c: New file.
1344
1345         * modules/unistr/u8-strncat: New file.
1346         * modules/unistr/u16-strncat: New file.
1347         * modules/unistr/u32-strncat: New file.
1348         * lib/unistr/u8-strncat.c: New file.
1349         * lib/unistr/u16-strncat.c: New file.
1350         * lib/unistr/u32-strncat.c: New file.
1351         * lib/unistr/u-strncat.h: New file.
1352
1353         * modules/unistr/u8-strncmp: New file.
1354         * modules/unistr/u16-strncmp: New file.
1355         * modules/unistr/u32-strncmp: New file.
1356         * lib/unistr/u8-strncmp.c: New file.
1357         * lib/unistr/u16-strncmp.c: New file.
1358         * lib/unistr/u32-strncmp.c: New file.
1359
1360         * modules/unistr/u8-strncpy: New file.
1361         * modules/unistr/u16-strncpy: New file.
1362         * modules/unistr/u32-strncpy: New file.
1363         * lib/unistr/u8-strncpy.c: New file.
1364         * lib/unistr/u16-strncpy.c: New file.
1365         * lib/unistr/u32-strncpy.c: New file.
1366         * lib/unistr/u-strncpy.h: New file.
1367
1368         * modules/unistr/u8-strnlen: New file.
1369         * modules/unistr/u16-strnlen: New file.
1370         * modules/unistr/u32-strnlen: New file.
1371         * lib/unistr/u8-strnlen.c: New file.
1372         * lib/unistr/u16-strnlen.c: New file.
1373         * lib/unistr/u32-strnlen.c: New file.
1374         * lib/unistr/u-strnlen.h: New file.
1375
1376         * modules/unistr/u8-strpbrk: New file.
1377         * modules/unistr/u16-strpbrk: New file.
1378         * modules/unistr/u32-strpbrk: New file.
1379         * lib/unistr/u8-strpbrk.c: New file.
1380         * lib/unistr/u16-strpbrk.c: New file.
1381         * lib/unistr/u32-strpbrk.c: New file.
1382         * lib/unistr/u-strpbrk.h: New file.
1383
1384         * modules/unistr/u8-strrchr: New file.
1385         * modules/unistr/u16-strrchr: New file.
1386         * modules/unistr/u32-strrchr: New file.
1387         * lib/unistr/u8-strrchr.c: New file.
1388         * lib/unistr/u16-strrchr.c: New file.
1389         * lib/unistr/u32-strrchr.c: New file.
1390
1391         * modules/unistr/u8-strspn: New file.
1392         * modules/unistr/u16-strspn: New file.
1393         * modules/unistr/u32-strspn: New file.
1394         * lib/unistr/u8-strspn.c: New file.
1395         * lib/unistr/u16-strspn.c: New file.
1396         * lib/unistr/u32-strspn.c: New file.
1397         * lib/unistr/u-strspn.h: New file.
1398
1399         * modules/unistr/u8-strstr: New file.
1400         * modules/unistr/u16-strstr: New file.
1401         * modules/unistr/u32-strstr: New file.
1402         * lib/unistr/u8-strstr.c: New file.
1403         * lib/unistr/u16-strstr.c: New file.
1404         * lib/unistr/u32-strstr.c: New file.
1405         * lib/unistr/u-strstr.h: New file.
1406
1407         * modules/unistr/u8-strtok: New file.
1408         * modules/unistr/u16-strtok: New file.
1409         * modules/unistr/u32-strtok: New file.
1410         * lib/unistr/u8-strtok.c: New file.
1411         * lib/unistr/u16-strtok.c: New file.
1412         * lib/unistr/u32-strtok.c: New file.
1413         * lib/unistr/u-strtok.h: New file.
1414
1415         * modules/unistr/u8-uctomb: New file.
1416         * modules/unistr/u16-uctomb: New file.
1417         * modules/unistr/u32-uctomb: New file.
1418         * lib/unistr/u8-uctomb.c: New file.
1419         * lib/unistr/u16-uctomb.c: New file.
1420         * lib/unistr/u32-uctomb.c: New file.
1421
1422         * MODULES.html.sh (Unicode string functions): Add the new modules.
1423
1424 2007-01-08  Bruno Haible  <bruno@clisp.org>
1425
1426         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
1427         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
1428         subdirectories.
1429
1430 2007-01-08  Karl Berry  <karl@gnu.org>
1431
1432         * doc/error.texi: mention that main() fns must set program_name
1433         when progname is used.
1434
1435 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
1436
1437         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
1438         WCTYPE_H is empty, for the benefit of builds from non-distclean
1439         directories.  Problem reported by Eric Blake in
1440         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
1441
1442 2007-01-08  Bruno Haible  <bruno@clisp.org>
1443
1444         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
1445         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
1446         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
1447         PROVIDE_CANONICALIZE_FILENAME_MODE.
1448         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
1449
1450 2007-01-08  Bruno Haible  <bruno@clisp.org>
1451
1452         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
1453         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
1454         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
1455         * lib/fts.c: Likewise.
1456         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
1457
1458 2006-12-25  Bruno Haible  <bruno@clisp.org>
1459
1460         * modules/utf8-ucs4-safe: New file.
1461         * lib/utf8-ucs4-safe.h: New file.
1462         * lib/unistr/utf8-ucs4-safe.c: New file.
1463
1464         * modules/utf16-ucs4-safe: New file.
1465         * lib/utf16-ucs4-safe.h: New file.
1466         * lib/unistr/utf16-ucs4-safe.c: New file.
1467
1468         * MODULES.html.sh (Unicode string functions): Add the new modules.
1469
1470 2007-01-08  Bruno Haible  <bruno@clisp.org>
1471
1472         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
1473         (Depends-on): Add unitypes.
1474         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
1475         (u8_mbtouc_aux): Move out to separate file.
1476         (u8_mbtouc): Use ucs4_t, uint8_t types.
1477         * lib/unistr/utf8-ucs4.c: New file.
1478
1479         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
1480         (Depends-on): Add unitypes.
1481         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
1482         (u16_mbtouc_aux): Move out to separate file.
1483         (u16_mbtouc): Use ucs4_t, uint16_t types.
1484         * lib/unistr/utf16-ucs4.c: New file.
1485
1486         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
1487         (Depends-on): Add unitypes.
1488         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
1489         (u8_uctomb_aux): Move out to separate file.
1490         (u8_uctomb): Use ucs4_t, uint8_t types.
1491         * lib/unistr/ucs4-utf8.c: New file.
1492
1493         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
1494         (Depends-on): Add unitypes.
1495         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
1496         (u16_uctomb_aux): Move out to separate file.
1497         (u16_uctomb): Use ucs4_t, uint16_t types.
1498         * lib/unistr/ucs4-utf16.c: New file.
1499
1500 2006-12-25  Bruno Haible  <bruno@clisp.org>
1501
1502         * modules/unitypes: New file.
1503         * lib/unitypes.h: New file.
1504         * MODULES.html.sh (func_all_modules): New section "Unicode string
1505         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
1506         this section. Add unitypes.
1507
1508 2007-01-08  Bruno Haible  <bruno@clisp.org>
1509
1510         Avoid variable names that conflict with those from libtool.
1511         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
1512         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
1513         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
1514         library_names_spec to acl_library_names_spec, hardcode_* to
1515         acl_hardcode_*.
1516         Reported by Ralf Wildenhues.
1517
1518 2007-01-08  Bruno Haible  <bruno@clisp.org>
1519
1520         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
1521         definition.
1522         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
1523         definition.
1524         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
1525         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
1526         definition.
1527         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
1528         definition.
1529         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
1530         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
1531         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
1532         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
1533         definition.
1534         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
1535         definition.
1536         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
1537         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
1538         GC_USE_<algorithm>.
1539         * lib/gc-libgcrypt.c: Likewise.
1540         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
1541         * modules/gc-arctwo (configure.ac): Likewise.
1542         * modules/gc-des (configure.ac): Likewise.
1543         * modules/gc-hmac-md5 (configure.ac): Likewise.
1544         * modules/gc-hmac-sha1 (configure.ac): Likewise.
1545         * modules/gc-md2 (configure.ac): Likewise.
1546         * modules/gc-md4 (configure.ac): Likewise.
1547         * modules/gc-md5 (configure.ac): Likewise.
1548         * modules/gc-random (configure.ac): Likewise.
1549         * modules/gc-rijndael (configure.ac): Likewise.
1550         * modules/gc-sha1 (configure.ac): Likewise.
1551
1552 2007-01-08  Bruno Haible  <bruno@clisp.org>
1553
1554         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
1555         macro definition.
1556         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
1557         definition.
1558         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
1559         definition.
1560         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
1561         * modules/fcntl-safer (configure.ac): Likewise.
1562         * modules/fopen-safer (configure.ac): Likewise.
1563         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
1564         GNULIB_FWRITEERROR macro definition.
1565
1566 2007-01-08  Bruno Haible  <bruno@clisp.org>
1567
1568         * m4/gnulib-common.m4: New file.
1569         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
1570         (func_get_filelist): Add m4/gnulib-common.m4.
1571
1572 2007-01-08  Bruno Haible  <bruno@clisp.org>
1573
1574         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
1575         command.
1576
1577 2007-01-08  Jim Meyering  <jim@meyering.net>
1578
1579         Use a more robust test for a "can't happen" condition.
1580         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
1581         narrowed the st_size value.  Presuming the "can't happen" condition
1582         is true, that narrowing could conceivably convert an invalid st_size
1583         value into a valid one.  Instead, use a change based on Matthew
1584         Woehlke's original patch.
1585
1586         Slight readability improvement: use an assert-like macro
1587         in place of literal "abort ()" uses.
1588         * lib/fts.c (fts_assert): Define.
1589         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
1590         Use this macro instead of a bare 'abort'.
1591
1592 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
1593
1594         Don't worry about using IRIX 5.3's wctype.h broken definitions;
1595         simply work around them.
1596         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
1597         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
1598         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
1599         Don't bother to define as macros, since the standard doesn't require it.
1600         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
1601         longer worry about IRIX 5.3.
1602         (HAVE_WCTYPE_CTMP_BUG): Remove.
1603
1604 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
1605
1606         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
1607         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
1608         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1609         Problems reported by Georg Schwarz for IRIX 5.3.
1610
1611         * gnulib-tool (autoconf_minversion): Take the maximum version number
1612         found, not the minimum.  Problem reported by James Youngman.
1613
1614 2007-01-03  Karl Berry  <karl@gnu.org>
1615
1616         * doc/error.texi: new file, explaining interaction with progname.
1617         * doc/gnulib.texi: include it.  Update copyright.
1618
1619 2007-01-03  Simon Josefsson  <simon@josefsson.org>
1620
1621         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
1622         AC_CANONICAL_HOST, to improve autobuild outputs.
1623
1624 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
1625             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
1626
1627         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
1628         sockets, server sockets, and other file descriptors.  Count errors
1629         to compute the return value.  Reorder the code a bit to be easier
1630         to follow.  Don't set event bits that were not requested (except
1631         POLLERR and POLLHUP).
1632
1633 2007-01-01  Bruno Haible  <bruno@clisp.org>
1634
1635         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
1636
1637 2007-01-03  Jim Meyering  <jim@meyering.net>
1638
1639         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
1640
1641 2007-01-02  Bruno Haible  <bruno@clisp.org>
1642
1643         * modules/settime (Include): Require timespec.h.
1644         * modules/nanosleep (Include): Likewise.
1645
1646 2007-01-01  Bruno Haible  <bruno@clisp.org>
1647
1648         * gnulib-tool (func_emit_copyright_notice): Bump year.
1649         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
1650
1651 2007-01-01  Bruno Haible  <bruno@clisp.org>
1652
1653         Improve support for OpenBSD.
1654         * build-aux/config.rpath (libname_spec): Export.
1655         (library_names_spec): New variable. Export.
1656         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
1657         library_names_spec from the config.rpath output. Locate shared library
1658         through the name pattern in library_names_spec.
1659
1660 2007-01-01  Eric Blake  <ebb9@byu.net>
1661
1662         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
1663
1664 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
1665
1666         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
1667         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
1668         assume the C locale, and avoid an "eval" that could cause trouble.
1669         Problem with SORT reported by Bob Proulx.
1670
1671         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
1672         Define.  Trivial patch from Henning Nielsen Lund, originally
1673         sent to bug-grep@gnu.org today.
1674
1675 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
1676
1677         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
1678         struct stat.  Problem reported by Henning Nielsen Lund.
1679         * lib/acl.c: Include acl.h first, to check interface.  Don't
1680         bother to include sys/types.h and sys/stat.h again.
1681
1682 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
1683
1684         Import the following change from libc; problem reported by
1685         Sven Verdoolaege.
1686
1687         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
1688
1689         [BZ #1373]
1690         * lib/argp.h: Remove __NTH for __argp_usage inline function.
1691
1692 2006-12-28  Jim Meyering  <jim@meyering.net>
1693
1694         * build-aux/announce-gen: Do not assume that the package
1695         builds any of tar.gz, tar.bz2, and .xdelta files.
1696         Suggestion from Simon Josefsson.
1697
1698 2006-12-28  Simon Josefsson  <simon@josefsson.org>
1699
1700         * modules/announce-gen: New file.
1701
1702 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
1703
1704         * lib/mbchar.h: Just include <wctype.h>; the wctype module
1705         handles its gotchas now.
1706         * lib/mbswidth.c: Likewise.
1707         * lib/wcwidth.h: Likewise.
1708         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
1709         and iswcntrl; the wctype module does this stuff now.
1710         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
1711         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
1712         * modules/mbchar (Depends-on): Add wctype.
1713         * modules/mbswidth (Depends-on): Likewise.
1714         * modules/wcwidth (Depends-on): Likewise.
1715
1716 2006-12-27  Eric Blake  <ebb9@byu.net>
1717
1718         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
1719         module uses more than what <wctype.h> is required to provide.
1720
1721 2006-12-26  Eric Blake  <ebb9@byu.net>
1722
1723         * gnulib-tool (sed_extract_prog): Avoid space-tab.
1724
1725 2006-12-26  Eric Blake  <ebb9@byu.net>
1726
1727         * modules/absolute-header: New module.
1728         * modules/fcntl (Depends-on): Depend on it.
1729         * modules/inttypes (Depends-on): Likewise.
1730         * modules/stdint (Depends-on): Likewise.
1731         * modules/sys_stat (Depends-on): Likewise.
1732         * modules/wctype (Depends-on): Likewise.
1733         * MODULES.html.sh (Support for building libraries and
1734         executables): Document it.
1735
1736 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
1737
1738         * gnulib-tool (SED): Remove, undoing previous change.
1739         The problem was that it broke coreutils on Solaris, because
1740         "sed --posix" leaked into a makefile.
1741         (sed): New alias, if 'alias' and GNU sed.
1742
1743 2006-12-24  Jim Meyering  <jim@meyering.net>
1744
1745         Work around an fchownat bug in glibc-2.4:
1746         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
1747         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
1748         in spite of the -P option.
1749         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
1750         New macros.
1751         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
1752         * modules/openat (Files): Add lib/fchownat.c.
1753         * lib/openat.c (fchownat): Don't define here.  Move to...
1754         * lib/fchownat.c: ...this new file.
1755
1756 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
1757
1758         Fix bug reported by Bruno Haible in
1759         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
1760         where quotearg.c didn't compile on Mac OS X 10.2 because it
1761         lacks <wchar.h> and wint_t.
1762         * lib/wctype_.h (__wctype_wint_t): New type.
1763         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
1764         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
1765         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
1766         Arg is now of type __wctype_wint_t, not wint_t.
1767         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
1768         substitute HAVE_WINT_T.
1769         * modules/wctype (Files): Add m4/wint_t.m4.
1770         (wctype.h): Substitute HAVE_WINT_T.
1771
1772 2006-12-23  Bruno Haible  <bruno@clisp.org>
1773
1774         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
1775
1776 2006-12-23  Bruno Haible  <bruno@clisp.org>
1777
1778         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
1779         S_ISLNK.
1780         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
1781         mingw.
1782
1783 2006-12-22  Bruno Haible  <bruno@clisp.org>
1784
1785         * lib/copy-file.c: Include acl.h.
1786         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
1787         Close the file descriptors only after being done with copy_acl.
1788         * modules/copy-file (Depends-on): Add acl.
1789
1790 2006-12-22  Bruno Haible  <bruno@clisp.org>
1791
1792         * gnulib-tool (SED): New variable.
1793         Use $SED instead of sed everywhere.
1794
1795 2006-12-22  Bruno Haible  <bruno@clisp.org>
1796
1797         * modules/no-c++: New file.
1798         * m4/no-c++.m4: New file.
1799         * MODULES.html.sh (Support for building libraries and executables):
1800         Add no-c++.
1801
1802 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
1803
1804         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
1805         Include <limits.h>, and use its INT_MAX to rewrite the
1806         j loop so that it does not overflow 'int'.  Problem reported by
1807         Ralf Wildenhues in
1808         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
1809         Play it safe by shifting left by 1 rather than multiplying by 2,
1810         as GCC is less likely to optimize this away when the value
1811         is signed (when it assumes overflow leads to undefined behavior).
1812         Also, don't assume time_t uses two's complement.
1813
1814 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
1815
1816         * MODULES.html.sh: New module wctype.
1817         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
1818         * lib/fnmatch.c: Don't bother to include <wchar.h> before
1819         <wctype.h>, since the new wctype module should fix this.
1820         * lib/quotearg.c: Include <wctype.h> unconditionally, since
1821         the wctype module should arrange for it.
1822         * lib/regex_internal.h: Likewise.
1823         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
1824         since the wctype module should handle this now.
1825         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
1826         * modules/fnmatch (Depends-on): Add wctype.
1827         * modules/quotearg (Depends-on): Likewise.
1828         * modules/regex (Depends-on): Likewise.
1829
1830 2006-12-19  Bruno Haible  <bruno@clisp.org>
1831
1832         * lib/strdup.h [C++]: Wrap definitions in extern "C".
1833         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
1834
1835 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1836
1837         * modules/savewd (Depends-on): Fix dependency on fcntl.
1838
1839 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
1840
1841         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
1842         conforms to C99, rather than relying on the user's environment
1843         setting of STDINT_H.
1844
1845 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
1846         and Eric Blake  <ebb9@byu.net>
1847
1848         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
1849         This is more consistent with the other defines here.
1850         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
1851         Port to z/OS.  Problem reported by Paul Gilmartin.
1852         Change local vars to use gl_ prefix rather than ac_.
1853         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
1854         with other defines.
1855         * modules/double-slash-root: New module.
1856         * modules/dirname (Files): Remove m4/double-slash-root.m4.
1857         (Depends-on): Add double-slash-root.
1858         * MODULES.html.sh (File system functions): Mention new module.
1859
1860 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
1861
1862         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
1863         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
1864         This is for the benefit of gzip, which doesn't do i18n.
1865
1866 2006-12-12  Jim Meyering  <jim@meyering.net>
1867
1868         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
1869         Reported by Andreas Schwab <schwab@suse.de>.
1870
1871 2006-12-12  Bruno Haible  <bruno@clisp.org>
1872
1873         Merge these changes.
1874         2006-09-05  Bruno Haible  <bruno@clisp.org>
1875         * lib/iconvme.c (iconv_string): No need to save and restore errno when
1876         iconv_alloc succeeded.
1877         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
1878         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
1879         test for " && dest " at the end - dest is always != NULL there. Call
1880         iconv with 4xNULL arguments initially, to reset the state. Call iconv
1881         with 2xNULL arguments, also to flush the state storage. Handle the
1882         IRIX iconv behaviour. Realloc the final result, to throw away unused
1883         memory.
1884
1885 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
1886
1887         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
1888         and fchmodat unconditionally, since glibc 2.4 has them.
1889         Problem reported by Arkadiusz Miskiewicz.
1890
1891 2006-12-10  Bruno Haible  <bruno@clisp.org>
1892
1893         * gnulib-tool (func_import): Show the include files only for those
1894         modules that are copied and specified.
1895         Reported by Karl Berry.
1896
1897 2006-12-08  Jim Meyering  <jim@meyering.net>
1898
1899         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
1900         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
1901
1902         * build-aux/announce-gen: Add two new options, both optional:
1903         --bootstrap-tools=TOOL_LIST
1904               a comma-separated list of tools, e.g.,
1905               autoconf,automake,bison,gnulib
1906         --gnulib-snapshot-date=DATE
1907               if gnulib is in the bootstrap tool list,
1908               then report this as the snapshot date.
1909               If not specified, use the current date/time.
1910               If you specify a date here, be sure it's UTC.
1911
1912 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1913
1914         * tests/test-argp-2.sh: Fix test to match actual output.
1915         (func_compare): Fix sed script to be portable.
1916
1917 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
1918
1919         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
1920         workaround for this case.  It is not autoconfigured now; offhand
1921         it's hard to see how to autoconfigure it.
1922
1923 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
1924
1925         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
1926         a directory that is about to be chowned.  Such a directory's
1927         initial file permissions should permit the owner only and this
1928         should not be changed until after the chown, since the group and
1929         other bits would be incorrect if they granted permission before
1930         the chown.
1931
1932         Fix porting problem for iswctype reported by Georg Schwarz in:
1933         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
1934         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
1935         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
1936         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
1937         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1938
1939 2006-12-03  Jim Meyering  <jim@meyering.net>
1940
1941         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
1942         p->fts_statp may not yet be defined.
1943         (fts_read): Instead, set it in the caller, once p->fts_statp is
1944         sure to be defined, and corresponds to a top-level directory.
1945         This bug made du -x fail.  Here's the coreutils test case:
1946         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
1947         Reported by Mike Frysinger.
1948
1949 2006-12-01  Jim Meyering  <jim@meyering.net>
1950
1951         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
1952         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
1953         Reported by Simon Josefsson.
1954
1955 2006-11-30  Jim Meyering  <jim@meyering.net>
1956
1957         * m4/warning.m4: Use the all-permissive copyright notice
1958         recommended by RMS (rather than LGPL).
1959         * m4/vararrays.m4: Likewise.
1960         * m4/flexmember.m4: Likewise.
1961
1962 2006-11-29  Bruno Haible  <bruno@clisp.org>
1963
1964         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1965         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
1966         using +=.
1967         Reported by Simon Josefsson <simon@josefsson.org>.
1968
1969 2006-11-28  James Youngman <jay@gnu.org>
1970
1971         * README: Advise users that they might find the bug-gnulib@gnu.org
1972         and autotools-announce@gnu.org mailing lists useful.
1973
1974 2006-11-28  Bruno Haible  <bruno@clisp.org>
1975
1976         * m4/ptrdiff_max.m4: Remove file.
1977
1978 2006-11-21  Bruno Haible  <bruno@clisp.org>
1979
1980         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
1981         _AC_COMPUTE_INT.
1982         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1983         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
1984         _AC_COMPUTE_INT.
1985         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1986         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
1987         _AC_COMPUTE_INT.
1988         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1989
1990 2006-11-28  Jim Meyering  <jim@meyering.net>
1991
1992         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
1993         warning from "gcc -Wshadow" about shadowing the builtin.
1994
1995 2006-11-27  Bruno Haible  <bruno@clisp.org>
1996
1997         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
1998         _AC_COMPUTE_INT.
1999         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
2000
2001 2006-11-27  Bruno Haible  <bruno@clisp.org>
2002             Paul Eggert  <eggert@cs.ucla.edu>
2003
2004         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
2005
2006 2006-11-26  Bruno Haible  <bruno@clisp.org>
2007
2008         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
2009         noinst_LTLIBRARIES.
2010
2011 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
2012             Bruno Haible  <bruno@clisp.org>
2013
2014         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
2015         if compiling with "gcc -ansi".
2016
2017 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
2018
2019         Fix some incompatibilities with gcc -ansi -pedantic.
2020         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
2021         if compiling pedantically with GCC, unless it's C99 or later.
2022         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
2023         it mishandles gcc -ansi -pedantic as well.
2024         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
2025         if gcc -pedantic.
2026         * lib/regexec.c (check_node_accept_bytes): Don't use auto
2027         initializers for struct if -pedantic, unless it's C99 or later.
2028
2029 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
2030
2031         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
2032         Don't close an fd more than once. Identical atimes indicate
2033         success, not failure.
2034
2035 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
2036
2037         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
2038
2039 2006-11-23  Jim Meyering  <jim@meyering.net>
2040
2041         * build-aux/announce-gen: New file.  From coreutils.
2042
2043 2006-11-22  Jim Meyering  <jim@meyering.net>
2044
2045         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
2046         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
2047         (fts_read): Use a temporary to narrow the overused st_size member
2048         before using it in a switch statement.  Reported by Matthew Woehlke.
2049
2050         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
2051         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
2052
2053 2006-11-20  Bruno Haible  <bruno@clisp.org>
2054
2055         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
2056         changequote instead of pairs of brackets.
2057         Reported by Andreas Schwab <schwab@suse.de>.
2058
2059 2006-11-21  Jim Meyering  <jim@meyering.net>
2060
2061         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
2062         so as to remain compatible with older compilers.
2063         Patch from Michael Deutschmann.
2064
2065 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
2066
2067         * MODULES.html.sh (File system functions): Add openat.
2068
2069         * lib/openat.h (rpl_fstatat): New macro, if
2070         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
2071         (fstatat): Define to rpl_fstatat under the same conditions,
2072         unless COMPILING_FSTATAT.
2073         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
2074         seems to have the bug.
2075         * lib/fstatat.c: New file.
2076         * modules/openat (Files): Add it.
2077
2078 2006-11-20  Bruno Haible  <bruno@clisp.org>
2079
2080         * Makefile: New file.
2081
2082 2006-11-20  Jim Meyering  <jim@meyering.net>
2083
2084         The beginnings of syntax-related checks for gnulib.
2085         * lib/Makefile: New file.
2086         * lib/t-idcache: New script.  Ensure that the two halves of
2087         idcache.c stay in sync.
2088
2089         * lib/idcache.c: Adjust comments in user- and group- portions to
2090         be more accurate, and to be consistent with one another.
2091
2092 2006-11-20  Jim Meyering  <jim@meyering.net>
2093
2094         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
2095         continue using the flexible array member (thus, this module performs
2096         half as many malloc calls), with the addition that...
2097         (getgroup, getuser): Consistently record a non-match via an empty
2098         "name" string, and map an empty string match to a NULL return value.
2099         * modules/idcache (Depends-on): Re-add flexmember.
2100
2101         * lib/idcache.c (getuser): Remove all uses of the register keyword.
2102         (getuidbyname, getgroup, getgidbyname): Likewise.
2103
2104         Use cleaner syntax: NULL rather than 0.
2105         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
2106
2107 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
2108
2109         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
2110         It mishandled the case where the group was missing.
2111         Problem reported by Greg Schafer.
2112         * modules/idcache: Likewise.
2113
2114 2006-11-18  Jim Meyering  <jim@meyering.net>
2115
2116         * check-module (%exempt_header): Add exception for some
2117         conditionally-included headers.
2118
2119         * modules/i-ring (Depends-on): Add verify.
2120         (License): Change to LGPL.
2121
2122 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
2123
2124         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
2125         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
2126         and inttostr.h.  Use snprintf rather than uinttostr, so that
2127         LGPLed code doesn't depend on GPLed.
2128
2129 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
2130
2131         * modules/inline (License): Change from GPL to LGPL.
2132
2133 2006-11-17  Jim Meyering  <jim@meyering.net>
2134
2135         * modules/d-type (License): Switch to LGPL.
2136
2137 2006-11-15  Bruno Haible  <bruno@clisp.org>
2138
2139         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
2140
2141 2006-11-15  Eric Blake  <ebb9@byu.net>
2142
2143         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
2144         the module dependency.
2145
2146 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
2147             Bruno Haible  <bruno@clisp.org>
2148
2149         * gnulib-tool (func_create_testdir): Add license consistency check.
2150
2151 2006-11-15  Eric Blake  <ebb9@byu.net>
2152
2153         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
2154         random "(cached)" in configure output.
2155
2156 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2157
2158         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
2159         test for conforming inttypes.h is both announced and cached.
2160
2161         * MODULES.html.sh (seen_modules, seen_files): New variables.
2162         (func_module): Rewrite to use a few less gnulib-tool and sed
2163         invocations.  Avoid a couple of quadratic algorithms for ...
2164         (missed_modules, missed_files): ... these, with ...
2165         (func_append, func_tmpdir): ... these new functions, from
2166         gnulib-tool.  Analogously, install traps for cleanup.
2167
2168         * tests/test-gc.c (main): Remove unused variables.
2169         * tests/test-read-file.c: Include stdlib.h, for 'free'.
2170
2171 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
2172
2173         * modules/inttostr (License): Change to LGPL.
2174
2175 2006-11-14  Eric Blake  <ebb9@byu.net>
2176
2177         * modules/tempname (License): Change to LGPL.
2178
2179 2006-11-14  Eric Blake  <ebb9@byu.net>
2180
2181         * doc/functions.texi (Function Portability): *printf functions on
2182         Cygwin now understand all POSIX size specifiers.
2183
2184 2006-11-14  Bruno Haible  <bruno@clisp.org>
2185
2186         * modules/c-ctype (License): Change to LGPL.
2187
2188 2006-11-12  Bruno Haible  <bruno@clisp.org>
2189
2190         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
2191         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
2192         for GNOME libraries, for which the include files are installed in
2193         subdirectories of $prefix/include.
2194
2195 2006-11-12  Bruno Haible  <bruno@clisp.org>
2196
2197         * m4/lib-link.m4: Require at least autoconf-2.54.
2198         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
2199         name to underscores for the --with option.
2200
2201 2006-11-13  Bruno Haible  <bruno@clisp.org>
2202
2203         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
2204         the tests directory.
2205         Reported by Ralf Wildenhues.
2206
2207 2006-11-13  Bruno Haible  <bruno@clisp.org>
2208
2209         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
2210         (func_emit_initmacro_end): Undo the override here.
2211         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
2212         Works around the famous automake error in coreutils.
2213
2214 2006-11-13  Eric Blake  <ebb9@byu.net>
2215
2216         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
2217         element, not its node.
2218
2219 2006-11-12  Bruno Haible  <bruno@clisp.org>
2220
2221         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
2222         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
2223
2224 2006-11-12  Bruno Haible  <bruno@clisp.org>
2225
2226         * gnulib-tool: New option --local-symlink.
2227         (func_usage): Document it.
2228         (lsymbolic): New variable.
2229         (func_import, func_create_testdir): If --symlink was not specified,
2230         test whether --local-symlink was specified and the file comes from
2231         the local_gnulib_dir.
2232
2233 2006-11-12  Bruno Haible  <bruno@clisp.org>
2234
2235         * gnulib-tool (func_ln): New function.
2236         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
2237
2238 2006-11-12  Bruno Haible  <bruno@clisp.org>
2239
2240         Finish support for source files in subdirectories.
2241         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
2242         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
2243         AUTOMAKE_OPTIONS.
2244         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
2245
2246 2006-11-12  Bruno Haible  <bruno@clisp.org>
2247
2248         * gnulib-tool (func_get_automake_snippet): Synthesize also an
2249         EXTRA_lib_SOURCES augmentation.
2250         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
2251
2252 2006-11-12  Jim Meyering  <jim@meyering.net>
2253
2254         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
2255         file descriptors.  This also averts a failure on systems with
2256         native openat support when a traversed directory lacks "x" access.
2257         * lib/fts_.h: Include "i-ring.h"
2258         (struct FTS) [fts_fd_ring]: New member.
2259         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
2260         (FCHDIR): Add parentheses.
2261         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
2262         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
2263         When descending, rather than simply closing the previous
2264         fts_cwd_fd value, push that file descriptor onto the ring.
2265         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
2266         (fts_open): Initialize the new fd_ring member.
2267         (fts_close): Clear the ring.
2268         (fts_safe_changedir): When possible, use our new fd_ring to skip
2269         the diropen and fstat and dev/ino comparison that would normally
2270         accompany a virtual `chdir ("..")'.
2271
2272         * modules/fts (Depends-on): Add i-ring.
2273         * modules/i-ring: New module.
2274         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
2275         * m4/i-ring.m4: New file.
2276
2277 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2278
2279         * gnulib-tool (func_create_testdir): Fix replacement of
2280         `build-aux' in configure.ac.  Run autotools in gltests
2281         subdirectory.
2282         (func_create_testdir, func_create_megatestdir, test): There is
2283         no need for '--force' in most autotool invocations in a new
2284         tree.  Actually fail the whole test if any of the tools, or the
2285         configure or make stages fail.
2286
2287         Sync from Automake.
2288         * build-aux/gnupload: Revert last change.  Add pointer to upload
2289         instructions of the GNU Maintenance Instructions.
2290         Suggestion by Karl Berry.
2291
2292 2006-11-10  Jim Meyering  <jim@meyering.net>
2293
2294         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
2295
2296 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
2297
2298         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
2299         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
2300         (bind_textdomain_codeset) [! ENABLE_NLS]:
2301         Evaluate all the arguments.  That way, callers get compatible behavior
2302         if the arguments have side effects.  Also, it avoids some GCC
2303         diagnostics in some cases; Joel E. Denny reported problems when Bison
2304         was configured with --enable-gcc-warnigs.
2305
2306 2006-11-10  Jim Meyering  <jim@meyering.net>
2307
2308         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
2309         relevant options in CFLAGS (like -O, -fno-inline) are taken into
2310         account.
2311
2312 2006-11-10  Jim Meyering  <jim@meyering.net>
2313
2314         * modules/inline: New file/module.
2315         * modules/xalloc (Files): Remove m4/inline.m4.
2316         (Depends-on): Add inline, instead.
2317         * modules/oset: Likewise.
2318         * modules/list: Likewise.
2319
2320 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
2321
2322         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
2323         Problem reported by Matthew Woehlke.
2324
2325 2006-11-09  Bruno Haible  <bruno@clisp.org>
2326
2327         * lib/tempname.c (gen_tempname): Remove variant that invokes
2328         __gen_tempname.
2329         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
2330         __gen_tempname.
2331
2332 2006-11-08  Bruno Haible  <bruno@clisp.org>
2333
2334         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
2335         to 'yes' instead of 'cross-compiling'.
2336
2337 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
2338
2339         * lib/quotearg.h (quotearg_free): New decl.
2340         * lib/quotearg.c (quotearg_free): New function.
2341         (slot0, nslots, slotvec0, slotvec):
2342         Now file-scope so that quotearg_free can get at them.
2343
2344 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2345
2346         Sync from Automake.
2347         * build-aux/gnupload: Add missing 'gnu' to example URL.
2348         Report by Karl Berry.
2349
2350 2006-11-08  Bruno Haible  <bruno@clisp.org>
2351
2352         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
2353         Suggested by Paul Eggert.
2354
2355 2006-11-08  Jim Meyering  <jim@meyering.net>
2356
2357         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
2358         It's already included if !_LIBC.
2359         (fts_safe_changedir): Add a comment.
2360
2361 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
2362
2363         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
2364         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
2365         Matthew Woehlke.
2366
2367         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
2368         definitions up, to avoid colliding with change below.
2369         (static_inline) [HAVE_INLINE]: New macro.
2370         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
2371         Provide extern decls when !HAVE_INLINE.  Do not define unless
2372         static_inline is defined, either by us or by xmalloc.c.  Use
2373         static_inline rather than static inline.
2374         (XCALLOC): Optimize sizeof(T) = 1 case.
2375         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
2376
2377 2006-11-07  Bruno Haible  <bruno@clisp.org>
2378
2379         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
2380         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
2381         AC_C_INLINE.
2382         * modules/xalloc (Files): Add m4/inline.m4.
2383
2384 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2385
2386         * README: Fix typo.
2387         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
2388         (Miscellanous Notes): ...from this.
2389
2390 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
2391
2392         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
2393         Mention that offsetof should be used instead of sizeof.
2394         From Bruno Haible.
2395
2396 2006-11-07  Bruno Haible  <bruno@clisp.org>
2397
2398         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
2399
2400 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
2401
2402         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
2403         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
2404         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
2405         (gl_tree_add_before, gl_tree_add_after):
2406         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
2407         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
2408         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
2409         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
2410         (gl_linked_add_after, gl_linked_add_at): Likewise.
2411         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
2412         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
2413         (gl_tree_add_before, gl_tree_add_after): Likewise.
2414         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
2415         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
2416         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
2417
2418 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2419
2420         * lib/gl_oset.h: Use C comment style, not C++ comment style.
2421
2422 2006-11-06  Bruno Haible  <bruno@clisp.org>
2423
2424         * m4/inline.m4: New file.
2425         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
2426         * modules/list (Files): Add m4/inline.m4.
2427         * modules/oset (Files): Likewise.
2428
2429 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
2430
2431         * lib/idcache.c: Include <stddef.h>, for offsetof.
2432         (struct userid.name): Change from char * to a flexible array member.
2433         All uses changed.
2434         * modules/idcache (Depends-on): Add flexmember.
2435
2436         * MODULES.html.sh (Core language properties): New module flexmember.
2437         * modules/flexmember, m4/flexmember.m4: New files.
2438
2439         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
2440         inline functions that are identical with the old xnmalloc_inline,
2441         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
2442         that we can avoid some unnecessary integer multiplications and
2443         divisions in the common case where the element size is known at
2444         compile time.
2445         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
2446         needed.
2447         (xnboundedmalloc): Remove.
2448         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
2449         arguments, for consistency with rest of this header.
2450         (xcharalloc): Rewrite using XNMALLOC.
2451         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
2452         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
2453         versions have been moved to lib/xalloc.h and renamed to be the
2454         non-*_inline versions.
2455         (xmalloc, xrealloc): Implement without reference to the xnmalloc
2456         and xnrealloc functions, since those functions are now inline and
2457         now call us.
2458         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
2459         renaming described above.
2460         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
2461         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
2462         captures the dependency in AC_C_INLINE.
2463
2464         New module canonicalize-lgpl, proposed by Charles Wilson in
2465         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
2466         with a few small changes afterwards.
2467         * MODULES.html.sh (File system functions): New module
2468         canonicalize-lgpl.
2469         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
2470         and canonicalize_file_name.
2471         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
2472         * modules/canonicalize-lgpl: New files.
2473
2474 2006-11-05  Bruno Haible  <bruno@clisp.org>
2475
2476         * gnulib-tool (func_import, func_create_testdir): Create directories
2477         also for files in subdirectories of lib/.
2478
2479 2006-11-05  Bruno Haible  <bruno@clisp.org>
2480
2481         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
2482         ANSI C compliant.
2483
2484 2006-11-03  Bruno Haible  <bruno@clisp.org>
2485
2486         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
2487         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
2488         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
2489         (xnboundedmalloc): New inline function.
2490         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
2491         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
2492         xmalloc.
2493         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
2494         xmalloc.
2495         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
2496         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
2497         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
2498         xmalloc.
2499         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
2500         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
2501         xmalloc.
2502         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
2503         gl_tree_add_after): Use XMALLOC instead of xmalloc.
2504         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
2505         xmalloc.
2506         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
2507         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
2508         gl_tree_add_after): Use XMALLOC instead of xmalloc.
2509         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
2510         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
2511         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
2512         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
2513
2514 2006-11-03  Bruno Haible  <bruno@clisp.org>
2515
2516         * lib/c-ctype.h [C++]: Define functions without name mangling.
2517         * lib/fwriteerror.h [C++]: Likewise.
2518         * lib/gcd.h [C++]: Likewise.
2519         * lib/linebreak.h [C++]: Likewise.
2520
2521 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
2522
2523         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
2524         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
2525         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
2526         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
2527         Check for functions and headers just once.
2528         Check for declaration of canonicalize_file_name.
2529         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
2530
2531 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
2532
2533         * gnulib-tool (func_import): Fix typo in actioncmd.
2534
2535 2006-11-02  Bruno Haible  <bruno@clisp.org>
2536
2537         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
2538         newline sequence in the Makefile.am snippet as a space, like "make"
2539         does.
2540         Reported by Roger Persson <perrog@gmail.com>.
2541
2542 2006-11-01  Bruno Haible  <bruno@clisp.org>
2543
2544         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
2545         already declared in <string.h>.
2546         * lib/strcase.h (strncasecmp): Don't declare it if yes.
2547
2548 2006-11-01  Bruno Haible  <bruno@clisp.org>
2549
2550         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
2551         * lib/strcase.h: Include <string.h>.
2552         (strcasecmp): Define to rpl_strcasecmp here.
2553
2554 2006-11-01  Bruno Haible  <bruno@clisp.org>
2555
2556         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
2557
2558 2006-11-01  Eric Blake  <ebb9@byu.net>
2559
2560         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
2561
2562         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
2563
2564 2006-10-29  Bruno Haible  <bruno@clisp.org>
2565
2566         Make it compile in C++ mode.
2567         * lib/full-write.c (full_rw): Add a cast.
2568
2569 2006-11-01  Bruno Haible  <bruno@clisp.org>
2570
2571         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
2572         be POSIX compliant.
2573         Reported by Roger Persson <perrog@gmail.com>.
2574
2575 2006-11-01  Eric Blake  <ebb9@byu.net>
2576
2577         * lib/getopt_.h: Fix comments.
2578
2579 2006-10-31  Eric Blake  <ebb9@byu.net>
2580
2581         * modules/tmpdir (Depends-on): Add sys_stat.
2582         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
2583         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
2584         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
2585         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
2586         tempname.
2587
2588 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
2589
2590         Avoid some C++ diagnostics reported by Bruno Haible.
2591         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
2592         xmalloc.
2593         (quotearg_alloc): Use xcharalloc rather than xmalloc.
2594         (struct slotvec): Move to top level.
2595         (quotearg_n_options): Rewrite to avoid xmalloc.
2596         * lib/xalloc.h (xcharalloc): New function.
2597         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
2598         [defined __cplusplus]: Add function template that provides result
2599         type propagation.  This part of the change is from Bruno Haible.
2600
2601 2006-10-29  Bruno Haible  <bruno@clisp.org>
2602
2603         Make it compile in C++ mode.
2604         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
2605         * lib/strnlen1.c (strnlen1): Cast memchr result.
2606         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
2607         * lib/clean-temp.c (string_equals, string_hash): Add casts.
2608         (create_temp_dir): Rename local variable 'template'.
2609         (compile_csharp_using_sscli): Add cast.
2610         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
2611         * lib/findprog.c (find_in_path): Likewise.
2612         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
2613         * lib/wait-process.c (register_slave_subprocess): Likewise.
2614
2615 2006-10-22  Bruno Haible  <bruno@clisp.org>
2616
2617         * modules/tsearch: New file.
2618         * lib/tsearch.h: New file.
2619         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
2620         * m4/tsearch.m4: New file.
2621         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
2622
2623 2006-10-29  Eric Blake  <ebb9@byu.net>
2624
2625         * lib/arcfour.c: Assume config.h.
2626         * lib/arctwo.c: Likewise.
2627         * lib/base64.c: Likewise.
2628         * lib/check-version.c: Likewise.
2629         * lib/crc.c: Likewise.
2630         * lib/des.c: Likewise.
2631         * lib/gc-gnulib.c: Likewise.
2632         * lib/gc-libgcrypt.c: Likewise.
2633         * lib/gc-pbkdf2-sha1.c: Likewise.
2634         * lib/getaddrinfo.c: Likewise.
2635         * lib/getdelim.c: Likewise.
2636         * lib/getline.c: Likewise.
2637         * lib/hmac-md5.c: Likewise.
2638         * lib/hmac-sha1.c: Likewise.
2639         * lib/iconvme.c: Likewise.
2640         * lib/md2.c: Likewise.
2641         * lib/md4.c: Likewise.
2642         * lib/memxor.c: Likewise.
2643         * lib/read-file.c: Likewise.
2644         * lib/readline.c: Likewise.
2645         * lib/rijndael-alg-fst.c: Likewise.
2646         * lib/rijndael-api-fst.c: Likewise.
2647         * lib/xgetdomainname.c: Likewise.
2648
2649 2006-10-28  Eric Blake  <ebb9@byu.net>
2650
2651         * lib/xstrndup.c: Assume config.h.
2652
2653 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
2654
2655         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
2656         stat-macros.h is now for our own macros, whereas stat_h is for
2657         macros in the <sys/stat.h> name space.
2658         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
2659         (STAT_MACROS_H): Remove.
2660         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
2661         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
2662         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
2663         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
2664         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
2665         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
2666         Move these macros to ...
2667         * lib/stat_.h: here.  Don't include stat-macros.h.
2668         * lib/canonicalize.c: Don't include stat-macros.h.
2669         * lib/chown.c: Likewise.
2670         * lib/euidaccess.c: Likewise.
2671         * lib/file-type.c: Likewise.
2672         * lib/filemode.c: Likewise.
2673         * lib/glob.c: Likewise.
2674         * lib/isapipe.c: Likewise.
2675         * lib/lchown.c: Likewise.
2676         * lib/lstat.c: Likewise.
2677         * lib/mkdir-p.c: Likewise.
2678         * lib/rmdir.c: Likewise.
2679         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
2680         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
2681         unless mkdir isn't declared, to speed up 'configure'.
2682         Always create sys/stat.h, since it's unlikely any real sys/stat.h
2683         would define all the S_* symbols.
2684         * modules/canonicalize (Depends-on):
2685         Depend on sys_stat, not stat-macros.
2686         * modules/chown: Likewise.
2687         * modules/euidaccess: Likewise.
2688         * modules/filemode: Likewise.
2689         * modules/file-type: Likewise.
2690         * modules/glob: Likewise.
2691         * modules/isapipe: Likewise.
2692         * modules/lchown: Likewise.
2693         * modules/lstat: Likewise.
2694         * modules/mkancesdirs: Likewise.
2695         * modules/rmdir: Likewise.
2696         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
2697         * modules/modechange: Likewise.
2698         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
2699         (configure.ac): Remove gl_STAT_MACROS.
2700         * modules/sys_stat (Depends-on): Remove stat-macros.
2701
2702 2006-10-27  Bruno Haible  <bruno@clisp.org>
2703
2704         * m4/signed.m4: Remove file.
2705         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
2706         invocation.
2707         * modules/vasnprintf (Files): Remove m4/signed.m4.
2708
2709 2006-10-27  Bruno Haible  <bruno@clisp.org>
2710
2711         Update to GNU gettext 0.16.
2712         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
2713         m4/inttypes-h.m4, m4/signed.m4.
2714         * m4/gettext.m4: Update to GNU gettext 0.16.
2715         * m4/intl.m4: New file, from GNU gettext.
2716         * m4/intldir.m4: New file, from GNU gettext.
2717         * config/srclist.txt: Update
2718
2719 2006-10-27  Eric Blake  <ebb9@byu.net>
2720
2721         * MODULES.html.sh: Document tempname.
2722         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
2723         dependencies.
2724         (Files): Move lib/tempname.c...
2725         * modules/tempname: ...to this new module.
2726         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
2727         (gl_PREREQ_TEMPNAME): Move...
2728         * m4/tempname.m4: ...to this new file.
2729         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
2730         * modules/sys_stat (Depends-on): Add stat-macros.
2731         * lib/stat_.h (includes): Pick up stat macros.
2732         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
2733         if stat macros are broken.
2734         * lib/tempname.c (includes): No need to include "stat-macros.h".
2735         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
2736         (direxists, __path_search) [!_LIBC]: Don't compile these in
2737         gnulib; the tmpdir module covers that.
2738         * lib/tempname.h: New file.
2739
2740 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
2741
2742         * COPYING: Explain how gnulib-tool converts licence headers.
2743         Almost all wording by Eric Blake.
2744
2745 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
2746
2747         * lib/mbchar.h (is_basic_table): Make read-only.
2748         * lib/mbchar.c (is_basic_table): Likewise.
2749         Reported by John Darrington.
2750
2751 2006-10-25  Bruno Haible  <bruno@clisp.org>
2752
2753         * lib/progname.h (set_program_name): Undefine before defining.
2754
2755 2006-10-25  Bruno Haible  <bruno@clisp.org>
2756
2757         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
2758         false for non-gcc C++ compilers.
2759         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
2760
2761 2006-10-24  Bruno Haible  <bruno@clisp.org>
2762
2763         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
2764         iconv implementations like Irix iconv.
2765
2766 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2767
2768         * modules/vararrays: New file.
2769         * m4/vararrays.m4: New file, taken from diffutils.
2770         * MODULES.html.sh: New module vararrays.
2771
2772 2006-10-24  Karl Berry  <karl@gnu.org>
2773
2774         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
2775         Don't call GNU Unix.
2776
2777 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2778
2779         * users.txt: Add Libtool.
2780
2781         Sync from Libtool:
2782
2783         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2784
2785         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
2786         to gnulib's policy of including config.h unconditionally.
2787
2788 2006-10-24  Bruno Haible  <bruno@clisp.org>
2789
2790         * modules/wcwidth (Files): Add m4/wint_t.m4.
2791         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
2792         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
2793
2794 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2795
2796         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
2797         to pacify GCC with some -W flags enabled.  Problem reported by
2798         Bruno Haible.
2799
2800 2006-10-24  Jim Meyering  <jim@meyering.net>
2801
2802         * MODULES.html.sh: Remove uinttostr.  It's not a module.
2803         Reported by Karl Berry.
2804
2805 2006-10-23  Bruno Haible  <bruno@clisp.org>
2806
2807         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
2808
2809 2006-10-24  Bruno Haible  <bruno@clisp.org>
2810
2811         * lib/gl_list.h: Use C comment style, not C++ comment style.
2812
2813 2006-10-23  Eric Blake  <ebb9@byu.net>
2814
2815         * lib/getaddrinfo.c (includes): Add missing include.
2816
2817 2006-10-23  Bruno Haible  <bruno@clisp.org>
2818             Paul Eggert  <eggert@cs.ucla.edu>
2819
2820         Ability to rename obstack_free.
2821         * lib/obstack.h (__obstack_free): New macro. Declare instead of
2822         obstack_free.
2823         (obstack_free): Invoke the __obstack_free macro.
2824         * lib/obstack.c (obstack_free): Use __obstack_free macro.
2825
2826 2006-10-23  Bruno Haible  <bruno@clisp.org>
2827             Paul Eggert  <eggert@cs.ucla.edu>
2828
2829         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
2830         __argc, __argv from the declaration. (They are defined as macros on
2831         mingw.)
2832
2833 2006-10-22  Bruno Haible  <bruno@clisp.org>
2834
2835         * doc/gnulib-intro.texi: New file.
2836         * doc/gnulib.texi: Include it.
2837
2838 2006-10-21  Bruno Haible  <bruno@clisp.org>
2839
2840         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
2841         "Introduction", "Miscellanous Notes", "Particular Modules".
2842
2843 2006-10-21  Bruno Haible  <bruno@clisp.org>
2844
2845         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2846         Change mostlyclean-local rule to avoid sh syntax error from bash
2847         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
2848
2849 2006-10-23  Jim Meyering  <jim@meyering.net>
2850
2851         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
2852         in place of snprintf.
2853
2854         * modules/inttostr (Files): Add lib/uinttostr.c.
2855         * lib/uinttostr.c (inttostr): New file/function.
2856         * lib/inttostr.h (uinttostr): Declare.
2857         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
2858         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
2859         Add uinttostr.
2860         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
2861
2862 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
2863
2864         * lib/canonicalize.c (ELOOP): Define if not already defined.
2865         Problem reported by Bruno Haible in
2866         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
2867
2868 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
2869
2870         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
2871         Problem reported by Perry Smith and Ville Laurikari.
2872
2873         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
2874         uses.
2875
2876 2006-10-19  Bruno Haible  <bruno@clisp.org>
2877
2878         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
2879         for mingw.
2880
2881 2006-10-19  Bruno Haible  <bruno@clisp.org>
2882
2883         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
2884         Needed for mingw.
2885
2886 2006-10-19  Bruno Haible  <bruno@clisp.org>
2887
2888         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
2889
2890 2006-10-19  Bruno Haible  <bruno@clisp.org>
2891
2892         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
2893         it.
2894
2895 2006-10-19  Bruno Haible  <bruno@clisp.org>
2896
2897         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
2898         invocation.
2899
2900 2006-10-19  Bruno Haible  <bruno@clisp.org>
2901
2902         * gnulib-tool (func_create_testdir): Don't include ftruncate and
2903         mountlist by default.
2904
2905 2006-10-16  Bruno Haible  <bruno@clisp.org>
2906
2907         * lib/c-strstr.c: Include c-strstr.h.
2908
2909 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
2910
2911         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
2912         in a slash.
2913
2914 2006-10-18  Bruno Haible  <bruno@clisp.org>
2915
2916         * lib/lock.h [C++]: Wrap definitions in extern "C".
2917
2918 2006-10-18  Bruno Haible  <bruno@clisp.org>
2919
2920         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
2921         gl_LIBOBJS list.
2922
2923 2006-10-18  Bruno Haible  <bruno@clisp.org>
2924
2925         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
2926
2927 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
2928
2929         * lib/xstrtol.h: Include gettext.h.
2930         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
2931         Problem reported by Eric Blake.
2932         * modules/xstrtol (Depends-on): Add gettext-h.
2933
2934 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
2935
2936         * lib/strftime.c (advance): New macro.
2937         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
2938         incomplete type, so you can't add 0 to it.  Problem and patch
2939         reported by Eelco Dolstra for dietlibc.
2940
2941 2006-10-18  Jim Meyering  <jim@meyering.net>
2942
2943         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
2944         type for a local, and rename it: s/up/user_proc/.
2945
2946 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
2947
2948         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
2949         READ_UTMP_USER_PROCESS.
2950         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
2951
2952 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
2953
2954         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
2955         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
2956
2957 2006-10-17  Eric Blake  <ebb9@byu.net>
2958
2959         * lib/sigprocmask.c (sigprocmask): Fix typo.
2960
2961         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
2962
2963         * modules/clean-temp (Makefile.am): Don't add to make output...
2964         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
2965         config.h.
2966
2967 2006-10-17  Bruno Haible  <bruno@clisp.org>
2968
2969         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
2970         differently if DEFAULT_TEXT_DOMAIN is set.
2971
2972 2006-10-16  Bruno Haible  <bruno@clisp.org>
2973
2974         * lib/clean-temp.c: Include fwriteerror.h.
2975
2976 2006-10-16  Bruno Haible  <bruno@clisp.org>
2977
2978         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
2979
2980 2006-10-16  Bruno Haible  <bruno@clisp.org>
2981
2982         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
2983         * lib/sigprocmask.h: Include <sys/types.h>.
2984         (sigset_t): Use the system's definition if present.
2985
2986 2006-10-17  Eric Blake  <ebb9@byu.net>
2987
2988         * lib/xvasprintf.c (includes): Assume config.h.
2989         * lib/xasprintf.c (includes): Likewise.
2990
2991 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
2992
2993         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
2994         at least as wide as intmax_t.
2995
2996 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
2997
2998         (Imported from Automake.)
2999         * build-aux/gnupload: Update to version 1.1 of directive file.
3000
3001 2006-10-16  Eric Blake  <ebb9@byu.net>
3002
3003         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
3004         match Automake 1.10a.
3005
3006 2006-10-14  Bruno Haible  <bruno@clisp.org>
3007
3008         * modules/sigprocmask: New file.
3009         * lib/sigprocmask.h: New file.
3010         * lib/sigprocmask.c: New file.
3011         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
3012         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
3013         request sigprocmask.o.
3014         (gl_PREREQ_SIGPROCMASK): New macro.
3015         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
3016         (Depends-on): Add sigprocmask.
3017         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
3018         gt_SIGNALBLOCKING. Test for 'raise' only once.
3019         * lib/fatal-signal.c: Include sigprocmask.h.
3020         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
3021         unblock_fatal_signals): Define always.
3022         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
3023         sigprocmask.
3024
3025 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
3026
3027         Sync from Automake.
3028         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
3029         which incorrectly sets the mode of an existing destination
3030         directory.  In some cases the unpatched install-sh could do the
3031         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
3032         system.  We hope this is rare in practice, but it's clearly worth
3033         fixing.  Problem reported by Alex Unleashed in
3034         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
3035         Also, don't bother to check for -m bugs unless we're using -m;
3036         suggested by Stepan Kasal.
3037
3038 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3039
3040         Sync from Automake.
3041         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
3042         `-c' flag, so they appear at the same position as in %FASTDEP%
3043         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
3044         which ignores unknown options only after the first non-option.
3045         Bug report against M4 by Nelson H. F. Beebe.
3046
3047 2006-10-13  Jim Meyering  <jim@meyering.net>
3048
3049         Fix a bug in yesterday's change.
3050         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
3051         p->fts_statp->st_dev would be used uninitialized.
3052         Ensures that we always call fts_stat on the very first entry.
3053         Miklos Szeredi reported that find -xdev stopped working.
3054
3055 2006-10-12  Bruno Haible  <bruno@clisp.org>
3056
3057         * gnulib-tool (func_get_automake_snippet): Append an automatically
3058         computed EXTRA_DIST augmentation.
3059         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
3060         * modules/alloca-opt (Makefile.am): Likewise.
3061         * modules/allocsa (Makefile.am): Likewise.
3062         * modules/arcfour (Makefile.am): Likewise.
3063         * modules/arctwo (Makefile.am): Likewise.
3064         * modules/argmatch (Makefile.am): Likewise.
3065         * modules/argz (Makefile.am): Likewise.
3066         * modules/atexit (Makefile.am): Likewise.
3067         * modules/backupfile (Makefile.am): Likewise.
3068         * modules/byteswap (Makefile.am): Likewise.
3069         * modules/c-strtod (Makefile.am): Likewise.
3070         * modules/c-strtold (Makefile.am): Likewise.
3071         * modules/calloc (Makefile.am): Likewise.
3072         * modules/canon-host (Makefile.am): Likewise.
3073         * modules/canonicalize (Makefile.am): Likewise.
3074         * modules/chdir-long (Makefile.am): Likewise.
3075         * modules/chdir-safer (Makefile.am): Likewise.
3076         * modules/check-version (Makefile.am): Likewise.
3077         * modules/chown (Makefile.am): Likewise.
3078         * modules/cloexec (Makefile.am): Likewise.
3079         * modules/close-stream (Makefile.am): Likewise.
3080         * modules/closeout (Makefile.am): Likewise.
3081         * modules/crc (Makefile.am): Likewise.
3082         * modules/csharpexec (Makefile.am): Likewise.
3083         * modules/cycle-check (Makefile.am): Likewise.
3084         * modules/des (Makefile.am): Likewise.
3085         * modules/dev-ino (Makefile.am): Likewise.
3086         * modules/dirfd (Makefile.am): Likewise.
3087         * modules/dirname (Makefile.am): Likewise.
3088         * modules/dup2 (Makefile.am): Likewise.
3089         * modules/eealloc (Makefile.am): Likewise.
3090         * modules/error (Makefile.am): Likewise.
3091         * modules/euidaccess (Makefile.am): Likewise.
3092         * modules/exclude (Makefile.am): Likewise.
3093         * modules/exitfail (Makefile.am): Likewise.
3094         * modules/fcntl-safer (Makefile.am): Likewise.
3095         * modules/fcntl (Makefile.am): Likewise.
3096         * modules/file-type (Makefile.am): Likewise.
3097         * modules/fileblocks (Makefile.am): Likewise.
3098         * modules/filemode (Makefile.am): Likewise.
3099         * modules/filenamecat (Makefile.am): Likewise.
3100         * modules/fnmatch (Makefile.am): Likewise.
3101         * modules/fopen-safer (Makefile.am): Likewise.
3102         * modules/fpending (Makefile.am): Likewise.
3103         * modules/fprintftime (Makefile.am): Likewise.
3104         * modules/free (Makefile.am): Likewise.
3105         * modules/fsusage (Makefile.am): Likewise.
3106         * modules/ftruncate (Makefile.am): Likewise.
3107         * modules/fts (Makefile.am): Likewise.
3108         * modules/gc-arcfour (Makefile.am): Likewise.
3109         * modules/gc-des (Makefile.am): Likewise.
3110         * modules/gc-hmac-md5 (Makefile.am): Likewise.
3111         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
3112         * modules/gc-md4 (Makefile.am): Likewise.
3113         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
3114         * modules/gc-sha1 (Makefile.am): Likewise.
3115         * modules/gc (Makefile.am): Likewise.
3116         * modules/getaddrinfo (Makefile.am): Likewise.
3117         * modules/getcwd (Makefile.am): Likewise.
3118         * modules/getdelim (Makefile.am): Likewise.
3119         * modules/getdomainname (Makefile.am): Likewise.
3120         * modules/getgroups (Makefile.am): Likewise.
3121         * modules/gethostname (Makefile.am): Likewise.
3122         * modules/gethrxtime (Makefile.am): Likewise.
3123         * modules/getline (Makefile.am): Likewise.
3124         * modules/getloadavg (Makefile.am): Likewise.
3125         * modules/getlogin_r (Makefile.am): Likewise.
3126         * modules/getndelim2 (Makefile.am): Likewise.
3127         * modules/getopt (Makefile.am): Likewise.
3128         * modules/getpagesize (Makefile.am): Likewise.
3129         * modules/getpass-gnu (Makefile.am): Likewise.
3130         * modules/getpass (Makefile.am): Likewise.
3131         * modules/getsubopt (Makefile.am): Likewise.
3132         * modules/gettime (Makefile.am): Likewise.
3133         * modules/gettimeofday (Makefile.am): Likewise.
3134         * modules/getugroups (Makefile.am): Likewise.
3135         * modules/getusershell (Makefile.am): Likewise.
3136         * modules/glob (Makefile.am): Likewise.
3137         * modules/group-member (Makefile.am): Likewise.
3138         * modules/hard-locale (Makefile.am): Likewise.
3139         * modules/hash (Makefile.am): Likewise.
3140         * modules/hmac-md5 (Makefile.am): Likewise.
3141         * modules/hmac-sha1 (Makefile.am): Likewise.
3142         * modules/human (Makefile.am): Likewise.
3143         * modules/idcache (Makefile.am): Likewise.
3144         * modules/imaxabs (Makefile.am): Likewise.
3145         * modules/imaxdiv (Makefile.am): Likewise.
3146         * modules/inet_ntop (Makefile.am): Likewise.
3147         * modules/inet_pton (Makefile.am): Likewise.
3148         * modules/intprops (Makefile.am): Likewise.
3149         * modules/inttostr (Makefile.am): Likewise.
3150         * modules/inttypes (Makefile.am): Likewise.
3151         * modules/isapipe (Makefile.am): Likewise.
3152         * modules/javaversion (Makefile.am): Likewise.
3153         * modules/lchmod (Makefile.am): Likewise.
3154         * modules/lchown (Makefile.am): Likewise.
3155         * modules/localcharset (Makefile.am): Likewise.
3156         * modules/long-options (Makefile.am): Likewise.
3157         * modules/lstat (Makefile.am): Likewise.
3158         * modules/malloc (Makefile.am): Likewise.
3159         * modules/mathl (Makefile.am): Likewise.
3160         * modules/mbchar (Makefile.am): Likewise.
3161         * modules/md2 (Makefile.am): Likewise.
3162         * modules/md4 (Makefile.am): Likewise.
3163         * modules/md5 (Makefile.am): Likewise.
3164         * modules/memcasecmp (Makefile.am): Likewise.
3165         * modules/memchr (Makefile.am): Likewise.
3166         * modules/memcmp (Makefile.am): Likewise.
3167         * modules/memcoll (Makefile.am): Likewise.
3168         * modules/memcpy (Makefile.am): Likewise.
3169         * modules/memmem (Makefile.am): Likewise.
3170         * modules/memmove (Makefile.am): Likewise.
3171         * modules/mempcpy (Makefile.am): Likewise.
3172         * modules/memrchr (Makefile.am): Likewise.
3173         * modules/memset (Makefile.am): Likewise.
3174         * modules/memxor (Makefile.am): Likewise.
3175         * modules/mkancesdirs (Makefile.am): Likewise.
3176         * modules/mkdir-p (Makefile.am): Likewise.
3177         * modules/mkdir (Makefile.am): Likewise.
3178         * modules/mkdtemp (Makefile.am): Likewise.
3179         * modules/mkstemp (Makefile.am): Likewise.
3180         * modules/mktime (Makefile.am): Likewise.
3181         * modules/modechange (Makefile.am): Likewise.
3182         * modules/mountlist (Makefile.am): Likewise.
3183         * modules/nanosleep (Makefile.am): Likewise.
3184         * modules/obstack (Makefile.am): Likewise.
3185         * modules/openat (Makefile.am): Likewise.
3186         * modules/pagealign_alloc (Makefile.am): Likewise.
3187         * modules/pathmax (Makefile.am): Likewise.
3188         * modules/physmem (Makefile.am): Likewise.
3189         * modules/poll (Makefile.am): Likewise.
3190         * modules/posixtm (Makefile.am): Likewise.
3191         * modules/posixver (Makefile.am): Likewise.
3192         * modules/putenv (Makefile.am): Likewise.
3193         * modules/quote (Makefile.am): Likewise.
3194         * modules/quotearg (Makefile.am): Likewise.
3195         * modules/raise (Makefile.am): Likewise.
3196         * modules/read-file (Makefile.am): Likewise.
3197         * modules/readline (Makefile.am): Likewise.
3198         * modules/readlink (Makefile.am): Likewise.
3199         * modules/readtokens (Makefile.am): Likewise.
3200         * modules/readutmp (Makefile.am): Likewise.
3201         * modules/realloc (Makefile.am): Likewise.
3202         * modules/regex (Makefile.am): Likewise.
3203         * modules/rename-dest-slash (Makefile.am): Likewise.
3204         * modules/rename (Makefile.am): Likewise.
3205         * modules/rijndael (Makefile.am): Likewise.
3206         * modules/rmdir (Makefile.am): Likewise.
3207         * modules/rpmatch (Makefile.am): Likewise.
3208         * modules/safe-read (Makefile.am): Likewise.
3209         * modules/safe-write (Makefile.am): Likewise.
3210         * modules/same-inode (Makefile.am): Likewise.
3211         * modules/same (Makefile.am): Likewise.
3212         * modules/save-cwd (Makefile.am): Likewise.
3213         * modules/savedir (Makefile.am): Likewise.
3214         * modules/setenv (Makefile.am): Likewise.
3215         * modules/settime (Makefile.am): Likewise.
3216         * modules/sha1 (Makefile.am): Likewise.
3217         * modules/sig2str (Makefile.am): Likewise.
3218         * modules/snprintf (Makefile.am): Likewise.
3219         * modules/stat-macros (Makefile.am): Likewise.
3220         * modules/stat-time (Makefile.am): Likewise.
3221         * modules/stdbool (Makefile.am): Likewise.
3222         * modules/stdint (Makefile.am): Likewise.
3223         * modules/stdlib-safer (Makefile.am): Likewise.
3224         * modules/stpcpy (Makefile.am): Likewise.
3225         * modules/stpncpy (Makefile.am): Likewise.
3226         * modules/strcase (Makefile.am): Likewise.
3227         * modules/strcasestr (Makefile.am): Likewise.
3228         * modules/strchrnul (Makefile.am): Likewise.
3229         * modules/strcspn (Makefile.am): Likewise.
3230         * modules/strdup (Makefile.am): Likewise.
3231         * modules/strerror (Makefile.am): Likewise.
3232         * modules/strftime (Makefile.am): Likewise.
3233         * modules/strndup (Makefile.am): Likewise.
3234         * modules/strnlen (Makefile.am): Likewise.
3235         * modules/strpbrk (Makefile.am): Likewise.
3236         * modules/strsep (Makefile.am): Likewise.
3237         * modules/strstr (Makefile.am): Likewise.
3238         * modules/strtod (Makefile.am): Likewise.
3239         * modules/strtoimax (Makefile.am): Likewise.
3240         * modules/strtok_r (Makefile.am): Likewise.
3241         * modules/strtol (Makefile.am): Likewise.
3242         * modules/strtoll (Makefile.am): Likewise.
3243         * modules/strtoul (Makefile.am): Likewise.
3244         * modules/strtoull (Makefile.am): Likewise.
3245         * modules/strtoumax (Makefile.am): Likewise.
3246         * modules/strverscmp (Makefile.am): Likewise.
3247         * modules/sys_socket (Makefile.am): Likewise.
3248         * modules/sys_stat (Makefile.am): Likewise.
3249         * modules/sysexits (Makefile.am): Likewise.
3250         * modules/time_r (Makefile.am): Likewise.
3251         * modules/timegm (Makefile.am): Likewise.
3252         * modules/timespec (Makefile.am): Likewise.
3253         * modules/tmpfile-safer (Makefile.am): Likewise.
3254         * modules/trim (Makefile.am): Likewise.
3255         * modules/unistd-safer (Makefile.am): Likewise.
3256         * modules/unlinkdir (Makefile.am): Likewise.
3257         * modules/unlocked-io (Makefile.am): Likewise.
3258         * modules/userspec (Makefile.am): Likewise.
3259         * modules/utime (Makefile.am): Likewise.
3260         * modules/utimecmp (Makefile.am): Likewise.
3261         * modules/utimens (Makefile.am): Likewise.
3262         * modules/vasnprintf (Makefile.am): Likewise.
3263         * modules/vasprintf (Makefile.am): Likewise.
3264         * modules/vsnprintf (Makefile.am): Likewise.
3265         * modules/xalloc (Makefile.am): Likewise.
3266         * modules/xgetcwd (Makefile.am): Likewise.
3267         * modules/xnanosleep (Makefile.am): Likewise.
3268         * modules/xreadlink (Makefile.am): Likewise.
3269         * modules/xstrtod (Makefile.am): Likewise.
3270         * modules/xstrtol (Makefile.am): Likewise.
3271         * modules/xstrtold (Makefile.am): Likewise.
3272         * modules/yesno (Makefile.am): Likewise.
3273         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
3274
3275 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
3276
3277         * modules/error (Makefile.am): Distribute files through
3278         EXTRA_DIST, not lib_SOURCES.
3279
3280 2006-10-12  Eric Blake  <ebb9@byu.net>
3281
3282         * modules/error (Makefile.am): Distribute files in /lib.
3283         * modules/obstack (Makefile.am): Likewise.
3284
3285 2006-10-12  Bruno Haible  <bruno@clisp.org>
3286
3287         * modules/acl (Makefile.am): Distribute all files in lib/ through
3288         EXTRA_DIST.
3289         * modules/arcfour (Makefile.am): Likewise.
3290         * modules/arctwo (Makefile.am): Likewise.
3291         * modules/argmatch (Makefile.am): Likewise.
3292         * modules/argz (Makefile.am): Likewise.
3293         * modules/atexit (Makefile.am): Likewise.
3294         * modules/backupfile (Makefile.am): Likewise.
3295         * modules/c-strtod (Makefile.am): Likewise.
3296         * modules/c-strtold (Makefile.am): Likewise.
3297         * modules/calloc (Makefile.am): Likewise.
3298         * modules/canon-host (Makefile.am): Likewise.
3299         * modules/canonicalize (Makefile.am): Likewise.
3300         * modules/chdir-long (Makefile.am): Likewise.
3301         * modules/chdir-safer (Makefile.am): Likewise.
3302         * modules/check-version (Makefile.am): Likewise.
3303         * modules/chown (Makefile.am): Likewise.
3304         * modules/cloexec (Makefile.am): Likewise.
3305         * modules/close-stream (Makefile.am): Likewise.
3306         * modules/closeout (Makefile.am): Likewise.
3307         * modules/crc (Makefile.am): Likewise.
3308         * modules/cycle-check (Makefile.am): Likewise.
3309         * modules/des (Makefile.am): Likewise.
3310         * modules/dirfd (Makefile.am): Likewise.
3311         * modules/dirname (Makefile.am): Likewise.
3312         * modules/dup2 (Makefile.am): Likewise.
3313         * modules/euidaccess (Makefile.am): Likewise.
3314         * modules/exclude (Makefile.am): Likewise.
3315         * modules/exitfail (Makefile.am): Likewise.
3316         * modules/fcntl-safer (Makefile.am): Likewise.
3317         * modules/file-type (Makefile.am): Likewise.
3318         * modules/fileblocks (Makefile.am): Likewise.
3319         * modules/filemode (Makefile.am): Likewise.
3320         * modules/filenamecat (Makefile.am): Likewise.
3321         * modules/fnmatch (Makefile.am): Likewise.
3322         * modules/fopen-safer (Makefile.am): Likewise.
3323         * modules/fpending (Makefile.am): Likewise.
3324         * modules/fprintftime (Makefile.am): Likewise.
3325         * modules/free (Makefile.am): Likewise.
3326         * modules/fsusage (Makefile.am): Likewise.
3327         * modules/ftruncate (Makefile.am): Likewise.
3328         * modules/fts (Makefile.am): Likewise.
3329         * modules/gc (Makefile.am): Likewise.
3330         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
3331         * modules/getaddrinfo (Makefile.am): Likewise.
3332         * modules/getcwd (Makefile.am): Likewise.
3333         * modules/getdelim (Makefile.am): Likewise.
3334         * modules/getdomainname (Makefile.am): Likewise.
3335         * modules/getgroups (Makefile.am): Likewise.
3336         * modules/gethostname (Makefile.am): Likewise.
3337         * modules/gethrxtime (Makefile.am): Likewise.
3338         * modules/getline (Makefile.am): Likewise.
3339         * modules/getloadavg (Makefile.am): Likewise.
3340         * modules/getlogin_r (Makefile.am): Likewise.
3341         * modules/getopt (Makefile.am): Likewise.
3342         * modules/getpass (Makefile.am): Likewise.
3343         * modules/getpass-gnu (Makefile.am): Likewise.
3344         * modules/getsubopt (Makefile.am): Likewise.
3345         * modules/gettime (Makefile.am): Likewise.
3346         * modules/gettimeofday (Makefile.am): Likewise.
3347         * modules/getugroups (Makefile.am): Likewise.
3348         * modules/getusershell (Makefile.am): Likewise.
3349         * modules/glob (Makefile.am): Likewise.
3350         * modules/group-member (Makefile.am): Likewise.
3351         * modules/hard-locale (Makefile.am): Likewise.
3352         * modules/hash (Makefile.am): Likewise.
3353         * modules/hmac-md5 (Makefile.am): Likewise.
3354         * modules/hmac-sha1 (Makefile.am): Likewise.
3355         * modules/human (Makefile.am): Likewise.
3356         * modules/idcache (Makefile.am): Likewise.
3357         * modules/imaxabs (Makefile.am): Likewise.
3358         * modules/imaxdiv (Makefile.am): Likewise.
3359         * modules/inet_ntop (Makefile.am): Likewise.
3360         * modules/inet_pton (Makefile.am): Likewise.
3361         * modules/inttostr (Makefile.am): Likewise.
3362         * modules/isapipe (Makefile.am): Likewise.
3363         * modules/lchown (Makefile.am): Likewise.
3364         * modules/long-options (Makefile.am): Likewise.
3365         * modules/lstat (Makefile.am): Likewise.
3366         * modules/malloc (Makefile.am): Likewise.
3367         * modules/mathl (Makefile.am): Likewise.
3368         * modules/mbchar (Makefile.am): Likewise.
3369         * modules/md2 (Makefile.am): Likewise.
3370         * modules/md4 (Makefile.am): Likewise.
3371         * modules/md5 (Makefile.am): Likewise.
3372         * modules/memcasecmp (Makefile.am): Likewise.
3373         * modules/memchr (Makefile.am): Likewise.
3374         * modules/memcmp (Makefile.am): Likewise.
3375         * modules/memcoll (Makefile.am): Likewise.
3376         * modules/memcpy (Makefile.am): Likewise.
3377         * modules/memmem (Makefile.am): Likewise.
3378         * modules/memmove (Makefile.am): Likewise.
3379         * modules/mempcpy (Makefile.am): Likewise.
3380         * modules/memrchr (Makefile.am): Likewise.
3381         * modules/memset (Makefile.am): Likewise.
3382         * modules/memxor (Makefile.am): Likewise.
3383         * modules/mkancesdirs (Makefile.am): Likewise.
3384         * modules/mkdir (Makefile.am): Likewise.
3385         * modules/mkdir-p (Makefile.am): Likewise.
3386         * modules/mkdtemp (Makefile.am): Likewise.
3387         * modules/mkstemp (Makefile.am): Likewise.
3388         * modules/mktime (Makefile.am): Likewise.
3389         * modules/modechange (Makefile.am): Likewise.
3390         * modules/mountlist (Makefile.am): Likewise.
3391         * modules/nanosleep (Makefile.am): Likewise.
3392         * modules/openat (Makefile.am): Likewise.
3393         * modules/pagealign_alloc (Makefile.am): Likewise.
3394         * modules/physmem (Makefile.am): Likewise.
3395         * modules/poll (Makefile.am): Likewise.
3396         * modules/posixtm (Makefile.am): Likewise.
3397         * modules/posixver (Makefile.am): Likewise.
3398         * modules/putenv (Makefile.am): Likewise.
3399         * modules/quote (Makefile.am): Likewise.
3400         * modules/quotearg (Makefile.am): Likewise.
3401         * modules/raise (Makefile.am): Likewise.
3402         * modules/read-file (Makefile.am): Likewise.
3403         * modules/readline (Makefile.am): Likewise.
3404         * modules/readlink (Makefile.am): Likewise.
3405         * modules/readtokens (Makefile.am): Likewise.
3406         * modules/readutmp (Makefile.am): Likewise.
3407         * modules/realloc (Makefile.am): Likewise.
3408         * modules/regex (Makefile.am): Likewise.
3409         * modules/rename (Makefile.am): Likewise.
3410         * modules/rename-dest-slash (Makefile.am): Likewise.
3411         * modules/rijndael (Makefile.am): Likewise.
3412         * modules/rmdir (Makefile.am): Likewise.
3413         * modules/rpmatch (Makefile.am): Likewise.
3414         * modules/safe-read (Makefile.am): Likewise.
3415         * modules/safe-write (Makefile.am): Likewise.
3416         * modules/same (Makefile.am): Likewise.
3417         * modules/save-cwd (Makefile.am): Likewise.
3418         * modules/savedir (Makefile.am): Likewise.
3419         * modules/setenv (Makefile.am): Likewise.
3420         * modules/settime (Makefile.am): Likewise.
3421         * modules/sha1 (Makefile.am): Likewise.
3422         * modules/sig2str (Makefile.am): Likewise.
3423         * modules/snprintf (Makefile.am): Likewise.
3424         * modules/stdlib-safer (Makefile.am): Likewise.
3425         * modules/stpcpy (Makefile.am): Likewise.
3426         * modules/stpncpy (Makefile.am): Likewise.
3427         * modules/strcase (Makefile.am): Likewise.
3428         * modules/strcasestr (Makefile.am): Likewise.
3429         * modules/strchrnul (Makefile.am): Likewise.
3430         * modules/strcspn (Makefile.am): Likewise.
3431         * modules/strdup (Makefile.am): Likewise.
3432         * modules/strerror (Makefile.am): Likewise.
3433         * modules/strftime (Makefile.am): Likewise.
3434         * modules/strndup (Makefile.am): Likewise.
3435         * modules/strnlen (Makefile.am): Likewise.
3436         * modules/strpbrk (Makefile.am): Likewise.
3437         * modules/strsep (Makefile.am): Likewise.
3438         * modules/strstr (Makefile.am): Likewise.
3439         * modules/strtod (Makefile.am): Likewise.
3440         * modules/strtoimax (Makefile.am): Likewise.
3441         * modules/strtok_r (Makefile.am): Likewise.
3442         * modules/strtol (Makefile.am): Likewise.
3443         * modules/strtoll (Makefile.am): Likewise.
3444         * modules/strtoul (Makefile.am): Likewise.
3445         * modules/strtoull (Makefile.am): Likewise.
3446         * modules/strtoumax (Makefile.am): Likewise.
3447         * modules/strverscmp (Makefile.am): Likewise.
3448         * modules/time_r (Makefile.am): Likewise.
3449         * modules/timegm (Makefile.am): Likewise.
3450         * modules/tmpfile-safer (Makefile.am): Likewise.
3451         * modules/unistd-safer (Makefile.am): Likewise.
3452         * modules/unlinkdir (Makefile.am): Likewise.
3453         * modules/userspec (Makefile.am): Likewise.
3454         * modules/utime (Makefile.am): Likewise.
3455         * modules/utimecmp (Makefile.am): Likewise.
3456         * modules/utimens (Makefile.am): Likewise.
3457         * modules/vasnprintf (Makefile.am): Likewise.
3458         * modules/vasprintf (Makefile.am): Likewise.
3459         * modules/vsnprintf (Makefile.am): Likewise.
3460         * modules/xalloc (Makefile.am): Likewise.
3461         * modules/xgetcwd (Makefile.am): Likewise.
3462         * modules/xnanosleep (Makefile.am): Likewise.
3463         * modules/xreadlink (Makefile.am): Likewise.
3464         * modules/xstrtod (Makefile.am): Likewise.
3465         * modules/xstrtol (Makefile.am): Likewise.
3466         * modules/xstrtold (Makefile.am): Likewise.
3467         * modules/yesno (Makefile.am): Likewise.
3468
3469 2006-10-12  Jim Meyering  <jim@meyering.net>
3470
3471         * m4/getloadavg.m4: Revert the change below.
3472
3473         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
3474         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
3475         fail with a symlink, which is what coreutils' ./bootstrap now
3476         creates by default.
3477
3478 2006-10-12  Bruno Haible  <bruno@clisp.org>
3479
3480         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
3481         mingw.
3482         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
3483         MSVC and mingw explicitly.
3484
3485 2006-10-11  Simon Josefsson  <jas@extundo.com>
3486             Bruno Haible  <bruno@clisp.org>
3487
3488         Add support for multiple gnulib-tool invocations in the scope of a
3489         single configure.ac file.
3490         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
3491         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
3492         with the same contents as the _LIBADD variable.
3493         (func_emit_initmacro_start, func_emit_initmacro_end,
3494         func_emit_initmacro_done): New functions.
3495         (func_import, func_create_testdir): Invoke them. Allow the identifiers
3496         gl_LIBOBJS and gl_LTLIBOBJS.
3497
3498 2006-10-11  Bruno Haible  <bruno@clisp.org>
3499
3500         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
3501         (func_create_testdir): Don't create po/Makefile.am, don't invoke
3502         autoreconf. Instead, invoke autopoint explicitly but move back the
3503         *.m4 files from gnulib.
3504
3505 2006-10-11  Bruno Haible  <bruno@clisp.org>
3506
3507         * gnulib-tool (func_usage): Make module names after --create-testdir
3508         optional.
3509         (func_create_testdir): If no module was specified, use nearly all
3510         modules.
3511
3512 2006-10-12  Jim Meyering  <jim@meyering.net>
3513
3514         Big performance improvement for fts-based tools that use FTS_NOSTAT.
3515         Avoid spurious inode-mismatch problems on non-POSIX file systems.
3516         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
3517         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
3518         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
3519         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
3520         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
3521         (fts_set_stat_required): New function.
3522         (fts_open): Defer the calls to fts_stat, if possible or requested.
3523         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
3524         into fts_stat itself.
3525         (fts_read): Perform any required (deferred) fts_stat call.
3526         (fts_build): Likewise, for the directory we're about to open and read.
3527         In the readdir loop, carefully decide whether each entry will require
3528         an eventual call to fts_stat, using dirent.d_type info if available.
3529         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
3530         a command line argument into this function.  Update all callers.
3531         Map a return value of FTS_DOT to FTS_D for a command line argument.
3532         * modules/fts (Depends-on): Add d-type.  Alphabetize.
3533         Thanks to Miklos Szeredi for his tenacity and for the initial
3534         bug report about "find" failing on a FUSE-based file system.
3535
3536         * lib/fts.c (fts_open): Use consistent indentation.
3537
3538 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
3539
3540         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
3541         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
3542         reported by Jim Meyering.  All uses of cache variables renamed
3543         to match Autoconf's.
3544         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
3545         the other one.
3546
3547         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
3548         Fix misspelling in diagnostic.
3549
3550 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
3551
3552         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
3553         defined.  Problem reported by Matthew Woehlke.
3554
3555         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
3556         Add support for Tandem NonStop R series.
3557         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
3558         Use new macro.
3559
3560         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
3561         (has_trailing_slash): Omit size arg; all callers changed.
3562         Omit 'inline', since it doesn't help performance and we'd
3563         need to configure it.
3564         Don't count //, ///, etc. as having a trailing slash.
3565         As a side effect, this removes a C99ism reported by Matthew Woehlke.
3566         (rpl_rename_dest_slash): On failure, use rename's errno rather
3567         than (in some cases) an incorrect or junk errno.
3568         Simplify code by removing need to compute length; this does
3569         cause it to make two passes instead of one over the file name,
3570         but it's worth it.
3571
3572         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
3573         change, since Autoconf's version may no longer be appropriate now
3574         that we are using CVS Autoconf's version.  Add support for Tandem.
3575
3576 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
3577             Bruno Haible  <bruno@clisp.org>
3578
3579         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
3580         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
3581         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
3582         gl_AC_TYPE_LONG_LONG.
3583
3584         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
3585         instead of HAVE_LONG_LONG.
3586         * lib/printf-args.c (printf_fetchargs): Likewise.
3587         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
3588         * lib/vasnprintf.c (VASNPRINTF): Likewise.
3589         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
3590         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
3591         gl_AC_TYPE_LONG_LONG.
3592
3593 2006-10-11  Bruno Haible  <bruno@clisp.org>
3594
3595         * m4/longlong.m4: Add comments.
3596         * m4/ulonglong.m4: Likewise.
3597
3598 2006-10-10  Bruno Haible  <bruno@clisp.org>
3599
3600         Make it possible to #define stpcpy, strdup to aliases.
3601         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
3602         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
3603
3604 2006-10-10  Bruno Haible  <bruno@clisp.org>
3605
3606         Make it possible to #define gcd to an alias.
3607         * lib/gcd.c: Include config.h.
3608
3609 2006-10-10  Bruno Haible  <bruno@clisp.org>
3610
3611         Make it possible to #define c_isascii to an alias.
3612         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
3613         defined. Undefine the macros before defining them, to avoid gcc
3614         warnings.
3615         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
3616         define NO_C_CTYPE_MACROS early.
3617
3618 2006-10-10  Bruno Haible  <bruno@clisp.org>
3619
3620         Make it possible to #define set_program_name to an alias.
3621         * lib/progname.c: Don't undefine set_program_name; instead, undefine
3622         ENABLE_RELOCATABLE early.
3623
3624 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
3625
3626         Port to Tandem NSK OSS, which has 64-bit signed int but at most
3627         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
3628         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
3629         More generally, don't assume that 64-bit signed int is available
3630         if unsigned int is, and vice versa.
3631         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
3632         unsigned symbols, not on their signed counterparts.
3633         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
3634         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
3635         (UINT64_C, UINTMAX_C):
3636         Likewise.
3637         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
3638         unsigned counterparts.
3639         (Have_long_long, Unsigned): New macros.
3640         (Int): Renamed from INT.
3641         (strtoimax): Use the new macros.
3642         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
3643         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
3644         * modules/inttypes (inttypes.h): Substitute
3645         HAVE_UNSIGNED_LONG_LONG_INT.
3646         * modules/stdint (stdint.h): Likewise.
3647         (Files): Add m4/ulonglong.m4.
3648
3649 2006-10-10  Bruno Haible  <bruno@clisp.org>
3650
3651         Fix a gcc -Wshadow warning.
3652         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
3653         to 'bucket'.
3654         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
3655         gl_linked_indexof_from_to): Likewise.
3656         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
3657         Likewise.
3658         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
3659         Likewise.
3660         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
3661         Reported by Eric Blake.
3662
3663 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
3664
3665         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
3666         for NetBSD.  Problem reported by Bruno Haible.
3667
3668 2006-10-09  Jim Meyering  <jim@meyering.net>
3669
3670         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
3671         Patch from Bruno Haible.
3672
3673 2006-10-09  Jim Meyering  <jim@meyering.net>
3674
3675         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
3676         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
3677         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
3678
3679 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
3680
3681         Don't include <config.h> twice; this doesn't work in some cases,
3682         e.g., when config.h has "#define intmax_t long long int" and
3683         we include <config.h>, <inttypes.h>, <config.h> in that order.
3684         Problem reported by Matthew Woehlke in:
3685         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
3686         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
3687         * lib/fts-cycle.c: Don't include config.h.
3688         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
3689         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
3690         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
3691         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
3692         inttypes.h.
3693         * lib/xstrtoumax.c: Likewise.
3694         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
3695         __strtol and the like, so that this module is more like its siblings.
3696         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
3697         Remove; no longer needed now that we assume gnulib inttypes.h.
3698
3699 2006-10-08  Bruno Haible  <bruno@clisp.org>
3700
3701         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
3702         option.
3703
3704 2006-10-07  Jim Meyering  <jim@meyering.net>
3705
3706         * modules/inttypes (inttypes.h): Revert what seems to have been
3707         an inadvertent part of today's change: use "|", not "/" in the
3708         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
3709
3710 2006-10-07  Bruno Haible  <bruno@clisp.org>
3711
3712         * modules/sublist: New file.
3713
3714 2006-10-07  Bruno Haible  <bruno@clisp.org>
3715
3716         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
3717         * modules/argz (argz.h): Likewise.
3718         * modules/arpa_inet (arpa/inet.h): Likewise.
3719         * modules/byteswap (byteswap.h): Likewise.
3720         * modules/configmake (configmake.h): Likewise.
3721         * modules/fcntl (fcntl.h): Likewise.
3722         * modules/fnmatch (fnmatch.h): Likewise.
3723         * modules/getopt (getopt.h): Likewise.
3724         * modules/glob (glob.h): Likewise.
3725         * modules/inttypes (inttypes.h): Likewise.
3726         * modules/netinet_in (netinet/in.h): Likewise.
3727         * modules/poll (poll.h): Likewise.
3728         * modules/stdbool (stdbool.h): Likewise.
3729         * modules/stdint (stdint.h): Likewise.
3730         * modules/sys_select (sys/select.h): Likewise.
3731         * modules/sys_socket (sys/socket.h): Likewise.
3732         * modules/sys_stat (sys/stat.h): Likewise.
3733         * modules/sysexits (sysexits.h): Likewise.
3734         * modules/unistd (unistd.h): Likewise.
3735         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
3736         Add a "DO NOT EDIT" comment to the generated file.
3737         (func_import): Likewise for gnulib-comp.m4.
3738
3739 2006-10-07  Bruno Haible  <bruno@clisp.org>
3740
3741         * lib/gl_sublist.h: New file.
3742         * lib/gl_sublist.c: New file.
3743
3744 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
3745
3746         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
3747         name (relative to the original working directory) and the file
3748         name component (relative to the temporary working directory).  All
3749         callers changed.
3750         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
3751         * lib/mkdir-p.c (make_dir_parents): Likewise.
3752         * lib/mkdir-p.h (make_dir_parents): Likewise.
3753
3754 2006-10-06  Eric Blake  <ebb9@byu.net>
3755
3756         Define several macros for use by the clean-temp module.
3757         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
3758         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
3759         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
3760
3761         * lib/clean-temp.h (close_stream_temp): New declaration.
3762         * lib/clean-temp.c (includes): Pull in headers according to what
3763         other modules are in use.
3764         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
3765
3766 2006-10-06  Bruno Haible  <bruno@clisp.org>
3767
3768         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
3769         instead of fopen, fwriteerror.
3770
3771 2006-10-06  Bruno Haible  <bruno@clisp.org>
3772
3773         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
3774         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
3775         int.
3776         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
3777         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
3778         Return an error indicator.
3779         Suggested by Eric Blake.
3780
3781 2006-10-06  Bruno Haible  <bruno@clisp.org>
3782
3783         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
3784         Reported by Eric Blake.
3785
3786 2006-10-06  Bruno Haible  <bruno@clisp.org>
3787
3788         * modules/closeout (Description): Mention stderr too.
3789
3790 2006-10-06  Bruno Haible  <bruno@clisp.org>
3791         and Paul Eggert  <eggert@cs.ucla.edu>
3792
3793         * lib/closeout.c (close_stdout): Also close stderr.
3794         * lib/closeout.h: Update comment.
3795
3796 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
3797
3798         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
3799         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
3800         * lib/dirchownmod.c: Include lchown.h.
3801         * lib/lchown.c: Don't include files that lchown.h now includes.
3802         Don't declare chown, since lchown.h now does that.
3803         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
3804         (lchown): Define to rpl_chown if lchown is declared but
3805         does not exist.  Declare using a prototype if lchown is not
3806         declared.  Add a copyright notice.
3807         * lib/mkstemp.h: Include <unistd.h>.
3808         * lib/openat.c: Include lchown.h.
3809
3810         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
3811         we now test for that separately.
3812         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
3813         rather than O_NOFOLLOW, when testing whether it's possible to
3814         avoid a race condition reliably.
3815         * lib/savewd.c (savewd_chdir): Likewise.
3816
3817         Remove macros that are no longer needed now that stdint.h is
3818         reliable.
3819         * lib/fsusage.c (UINTMAX_MAX): Remove.
3820         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
3821         * lib/utimecmp.c (SIZE_MAX): Remove.
3822
3823         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
3824
3825         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
3826         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
3827         O_NOATIME works.
3828
3829 2006-10-05  Bruno Haible  <bruno@clisp.org>
3830
3831         * lib/gl_list.h (gl_sortedlist_search_from_to,
3832         gl_sortedlist_indexof_from_to): New declarations.
3833         (gl_list_implementation): New fields sortedlist_search_from_to,
3834         sortedlist_indexof_from_to.
3835         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
3836         inline functions.
3837         * lib/gl_list.c (gl_sortedlist_search_from_to,
3838         gl_sortedlist_indexof_from_to): New functions.
3839         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
3840         function.
3841         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
3842         (gl_array_sortedlist_search_from_to): New function.
3843         (gl_array_list_implementation): Update.
3844         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
3845         function.
3846         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
3847         (gl_carray_sortedlist_search_from_to): New function.
3848         (gl_carray_list_implementation): Update.
3849         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
3850         gl_linked_sortedlist_indexof_from_to): New functions.
3851         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
3852         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
3853         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
3854         gl_tree_sortedlist_indexof_from_to): New functions.
3855         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
3856         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
3857         Update.
3858         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
3859         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
3860         Update.
3861
3862 2006-10-05  Bruno Haible  <bruno@clisp.org>
3863
3864         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
3865         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
3866         (struct gl_list_implementation): Add fields search_from_to,
3867         indexof_from_to. Remove fields search, indexof.
3868         (gl_list_search): Use the search_from_to method.
3869         (gl_list_search_from, gl_list_search_from_to): New functions.
3870         (gl_list_indexof): Use the indexof_from_to method.
3871         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
3872         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
3873         (gl_list_search_from, gl_list_search_from_to): New functions.
3874         (gl_list_indexof): Use the indexof_from_to method.
3875         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
3876         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
3877         gl_array_indexof. Add start_index, end_index arguments.
3878         (gl_array_search_from_to): Renamed from gl_array_search. Add
3879         start_index, end_index arguments.
3880         (gl_array_remove, gl_array_list_implementation): Update.
3881         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
3882         gl_carray_indexof. Add start_index, end_index arguments.
3883         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
3884         start_index, end_index arguments.
3885         (gl_carray_remove, gl_carray_list_implementation): Update.
3886         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
3887         gl_linked_search. Add start_index, end_index arguments.
3888         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
3889         start_index, end_index arguments.
3890         (gl_linked_remove): Update.
3891         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
3892         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
3893         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
3894         field to 'size_t'.
3895         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
3896         gl_tree_search. Add start_index, end_index arguments.
3897         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
3898         start_index, end_index arguments.
3899         (gl_tree_remove): Update.
3900         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
3901         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
3902         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
3903         function.
3904         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
3905         gl_tree_search. Add start_index, end_index arguments.
3906         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
3907         start_index, end_index arguments.
3908         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
3909         Update.
3910         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
3911
3912 2006-10-05  Bruno Haible  <bruno@clisp.org>
3913
3914         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
3915
3916         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
3917         fwriteerror_temp): New declarations.
3918         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
3919         (descriptors): New variable.
3920         (cleanup): First, close the descriptors.
3921         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
3922         fclose_temp, fwriteerror_temp): New functions.
3923
3924 2006-10-04  Jim Meyering  <jim@meyering.net>
3925
3926         * lib/fts.c (fts_open): Tiny comment change.
3927
3928 2006-10-04  Bruno Haible  <bruno@clisp.org>
3929
3930         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
3931         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
3932         gl_LOCK_BODY.
3933         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
3934         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
3935         gl_LOCK_EARLY_BODY.
3936         (gl_LOCK): Require gl_LOCK_BODY.
3937
3938 2006-10-04  Bruno Haible  <bruno@clisp.org>
3939
3940         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
3941         (gl_oset_search_atleast): New declaration.
3942         (struct gl_oset_implementation): Add field 'search_atleast'.
3943         (gl_oset_search_atleast): New inline function.
3944         * lib/gl_oset.c (gl_oset_search_atleast): New function.
3945         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
3946         (gl_array_oset_implementation): Update.
3947         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
3948         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
3949         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
3950
3951 2006-10-04  Bruno Haible  <bruno@clisp.org>
3952
3953         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
3954
3955 2006-10-03  Bruno Haible  <bruno@clisp.org>
3956
3957         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
3958         from gl_avltreehash_list_implementation.
3959
3960 2006-10-03  Bruno Haible  <bruno@clisp.org>
3961
3962         * lib/gl_oset.c (gl_oset_add): Fix return type.
3963
3964 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
3965
3966         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
3967
3968 2006-10-02  Eric Blake  <ebb9@byu.net>
3969
3970         * modules/strnlen (Depends-on): Add extensions.
3971
3972 2006-10-02  Eric Blake  <ebb9@byu.net>
3973
3974         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
3975         definition in 2.60+.
3976
3977 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
3978
3979         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
3980         checks.
3981
3982 2006-10-02  Bruno Haible  <bruno@clisp.org>
3983
3984         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
3985         to the AUTOMAKE_OPTIONS.
3986         Reported by Jim Meyering.
3987
3988 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
3989
3990         Work around bug in Solaris 10 /proc file system:
3991         /proc/self/fd/NNN/.. isn't the parent directory of
3992         the directory whose file descriptor is NNN.  This needs to
3993         be worked around at run time, not compile time, since a
3994         program might be built on Solaris 8, where things work, and
3995         run on Solaris 10.
3996         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
3997         to use the following interface instead:
3998         (OPENAT_BUFFER_SIZE): New macro.
3999         (openat_proc_name): New function.
4000         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
4001         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
4002         Likewise.
4003         * lib/openat-proc.c: New file.
4004         * modules/openat (Files): Add lib/openat-proc.c.
4005         (Depends-on): Add same-inode, stdbool.
4006         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
4007
4008 2006-09-29  Bruno Haible  <bruno@clisp.org>
4009
4010         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
4011         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
4012         argument. Set stdout_closed before testing for ferror, not after.
4013         (fwriteerror, fwriteerror_no_ebadf): New functions.
4014
4015 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4016
4017         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
4018
4019 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
4020
4021         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
4022         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
4023
4024 2006-09-28  Jim Meyering  <jim@meyering.net>
4025
4026         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
4027         Include <unistd.h>.
4028
4029 2006-09-28  Bruno Haible  <bruno@clisp.org>
4030
4031         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
4032         * modules/linkedhash-list (Depends-on): Likewise.
4033         * modules/rbtreehash-list (Depends-on): Likewise.
4034
4035 2006-09-28  Bruno Haible  <bruno@clisp.org>
4036
4037         * lib/strndup.h: Simplify the redefinition of strndup.
4038         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
4039         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
4040
4041 2006-09-28  Bruno Haible  <bruno@clisp.org>
4042
4043         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
4044         * lib/gl_linkedhash_list.c: Likewise.
4045         * lib/gl_rbtreehash_list.c: Likewise.
4046
4047 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
4048
4049         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
4050         getaddrinfo.
4051
4052         * lib/__fpending.h: Don't include <stdio_ext.h> unless
4053         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
4054         it causes <stdio_ext.h> to cause a compile-time error.
4055         Problem reported by Nelson H. F. Beebe.
4056         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
4057         of HAVE_DECL___PENDING.
4058
4059         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
4060         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
4061         declaration.
4062
4063 2006-09-27  Jim Meyering  <jim@meyering.net>
4064
4065         This file could end up with a definition for a function
4066         named __strndup, rather than rpl_strndup on a system with
4067         incomplete weak_alias support.
4068         * lib/strndup.c (strndup): Rename from __strndup.
4069         Remove #defines that used to map __strndup to strndup.
4070         Don't use K&R prototypes.
4071         Remove LIBC-related code, since this file is not sync'd with glibc.
4072         * lib/strndup.h: Revamp, accordingly.
4073         * m4/strndup.m4: Modernize.
4074
4075 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
4076
4077         * modules/savewd (Depends-on): Add 'raise'.
4078         * lib/savewd.c: Include <signal.h>, for 'raise'.
4079
4080 2006-09-26  Jim Meyering  <jim@meyering.net>
4081
4082         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
4083         when we detect Darwin 8.7.0's acl_get_file bug.
4084         Rearrange to perform the new (below) run-test while $LIBS
4085         contains any acl-related library.  Set USE_ACL at the end.
4086         (gl_ACL_GET_FILE): New function.
4087
4088 2006-09-26  Eric Blake  <ebb9@byu.net>
4089
4090         * lib/verror.c: Include <config.h> unconditionally.
4091
4092 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
4093
4094         * modules/clock-time (Maintainer): Add self.
4095         * modules/getlogin_r (Depends-on): Add extensions.
4096
4097 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4098
4099         * modules/clock-time: New module.
4100         * modules/nanosleep (Depends-on): Add clock-time.
4101         * modules/gethrxtime (Depends-on): Likewise.
4102         * modules/gettime (Depends-on): Likewise.
4103         * modules/settime (Depends-on): Likewise.
4104
4105         * modules/fts-lgpl: Depend on openat.
4106         * modules/mkancesdirs: Depend on savewd.
4107         * modules/mkdir-p: Likewise.
4108
4109 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4110
4111         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
4112
4113         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
4114         `gl_have_arbitrary_file_name_length_limit' to
4115         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
4116         actually works between configure runs.
4117
4118 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4119             Bruno Haible  <bruno@clisp.org>
4120
4121         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
4122
4123 2006-09-25  Jim Meyering  <jim@meyering.net>
4124
4125         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
4126         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
4127
4128 2006-09-25  Eric Blake  <ebb9@byu.net>
4129
4130         * gnulib-tool (func_import, func_create_testdir): Fix typos in
4131         exec's in 2006-09-18 patch when shuffling fds.
4132
4133 2006-09-25  Bruno Haible  <bruno@clisp.org>
4134
4135         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
4136         Reported by Jim Meyering.
4137
4138 2006-09-24  Jim Meyering  <jim@meyering.net>
4139
4140         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
4141         compare a pointer against a literal "0".  That caused failures with
4142         at least HP-UX's hpcc.
4143
4144 2006-09-22  Simon Josefsson  <jas@extundo.com>
4145
4146         * modules/gc-sha1:
4147         * modules/gc-md4:
4148         * modules/gc-hmac-sha1:
4149         * modules/gc-hmac-md5:
4150         * modules/gc-des:
4151         * modules/gc-arcfour: Distribute more files.
4152
4153 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4154
4155         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
4156         (gl_linked_iterator_from_to): Initialize struct completely.
4157         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
4158         (gl_tree_iterator_from_to): Likewise
4159         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
4160         * lib/gl_array_list.c [lint] (gl_array_iterator)
4161         (gl_array_iterator_from_to): Likewise.
4162         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
4163         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
4164         (gl_carray_iterator_from_to): Likewise.
4165
4166         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
4167         * lib/md4.c (md4_process_block): Remove unused variable.
4168         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
4169         parentheses for clarity.
4170
4171 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4172
4173         * modules/bison-i18n (Depends-on): Add gettext.
4174
4175 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4176
4177         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
4178         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
4179         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
4180         also add missing comma that caused broken test.
4181         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
4182         stdlib.h, for `abort'.
4183         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
4184         variables.
4185         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
4186         include unistd.h if present, for `rmdir'.
4187         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
4188         variables.
4189         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
4190         in the process include standard headers for prototypes.
4191         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
4192         gets declared on GNU/Linux.
4193         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
4194         unistd.h, for `rmdir'.
4195         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
4196
4197         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
4198         always true.
4199         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
4200
4201         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
4202
4203 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4204
4205         * gnulib-tool (func_version): Create output all at once.  This
4206         may help avoid triggering unnecessary SIGPIPEs, and at any
4207         rate it doesn't hurt.
4208
4209 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4210             Bruno Haible  <bruno@clisp.org>
4211
4212         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
4213         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
4214         * m4/signed.m4 (bh_C_SIGNED): Likewise.
4215
4216         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
4217         (gl_FUNC_VASPRINTF): Invoke it.
4218
4219 2006-09-22  Bruno Haible  <bruno@clisp.org>
4220
4221         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
4222         getloadavg.c as first argument.
4223
4224 2006-09-22  Bruno Haible  <bruno@clisp.org>
4225
4226         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
4227         at the beginning of the gl_INIT macro.
4228         * modules/getloadavg (configure.ac): Pass $gl_source_base to
4229         gl_GETLOADAVG.
4230
4231 2006-09-22  Bruno Haible  <bruno@clisp.org>
4232
4233         * gnulib-tool (func_create_megatestdir): Don't include the config-h
4234         module.
4235         Suggested by Ralf Wildenhues.
4236
4237 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
4238
4239         Import this patch from libc:
4240
4241         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
4242
4243         * lib/regex_internal.c (re_string_reconstruct): Handle
4244         offset < pstr->valid_raw_len && pstr->offsets_needed case.
4245         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
4246         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
4247         re_string_context_at.
4248
4249         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
4250         now requires it.
4251         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
4252         gl_REGEX now does it for us.
4253         (gl_REGEX): Add test taken from
4254         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
4255
4256         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
4257         Check that large offsets work.  Modernize Autoconf usages.
4258         Prefer "yes" to mean a good thing rather than a bad.
4259         Don't put "#define mkstemp" in config.h, as this might interfere
4260         with standard system headers that "#define mkstemp mkstemp64".
4261
4262         * modules/mkstemp (Depends-on): Add extensions, so that
4263         mkstemp is visible on some platforms.
4264         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
4265         (Include): Change to "mkstemp.h" from <stdlib.h>.
4266         (Files): Add mkstemp.h.
4267
4268         * lib/mkstemp.h: New file, since some standard headers
4269         #define mkstemp.
4270         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
4271         Include "mkstemp.h".
4272         Make the _LIBC code resemble glibc original more,
4273         e.g., use K&R style.
4274         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
4275         (mkstemp): Remove, since mkstemp.h does this for us.
4276         * lib/stdlib--.h: Include mkstemp.h.
4277
4278         Import this patch from libc:
4279
4280         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
4281
4282         * lib/tempname.c (__gen_tempname): Change attempts_min
4283         into a macro.  Use preprocessor to decide how to initialize
4284         attempts [Coverity CID 67].
4285
4286 2006-09-20  Bruno Haible  <bruno@clisp.org>
4287
4288         * lib/mkdtemp.c: Import from libc.
4289         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
4290                 * sysdeps/posix/tempname.c (__gen_tempname): Change
4291                 attempts_min into a macro.  Use preprocessor to decide how to
4292                 initialize attempts [Coverity CID 67].
4293         2001-11-27  Paul Eggert  <eggert@twinsun.com>
4294                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
4295                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
4296
4297 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4298
4299         * gnulib-tool (func_exit): New function, to allow to pass the
4300         exit status portably through the trap.  Use everywhere.
4301         (--help, --version): Signal a write error.
4302         (trap): catch SIGPIPE, for write errors.
4303         Exit at the end of the trap, with the correct exit status.
4304
4305 2006-09-19  Karl Berry  <karl@gnu.org>
4306
4307         * doc/gnulib.texi: note about the license texinfo files.
4308
4309 2006-09-19  Eric Blake  <ebb9@byu.net>
4310
4311         * gnulib-tool: Avoid space-tab.
4312
4313 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
4314
4315         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
4316         that prevented coreutils 6.1 from building.  Problem reported
4317         by Petter Reinholdtsen.
4318
4319 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
4320
4321         * gnulib-tool (avoidlist): Fix typo that broke options like
4322         --avoid=lock that are used by coreutils bootstrap.
4323
4324 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
4325
4326         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
4327         more systematically.
4328
4329 2006-09-18  Jim Meyering  <jim@meyering.net>
4330
4331         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
4332
4333 2006-09-18  Bruno Haible  <bruno@clisp.org>
4334
4335         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
4336
4337 2006-09-18  Bruno Haible  <bruno@clisp.org>
4338
4339         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
4340         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
4341         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
4342         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
4343         * m4/gettext.m4: Require autoconf >= 2.52.
4344         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
4345         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
4346         of gl_cv_header_inttypes_h.
4347
4348 2006-09-18  Bruno Haible  <bruno@clisp.org>
4349
4350         * lib/javaversion.c: Include configmake.h.
4351
4352 2006-09-18  Bruno Haible  <bruno@clisp.org>
4353
4354         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
4355         avoid that the while loops be executed in a subshell.
4356
4357 2006-09-18  Bruno Haible  <bruno@clisp.org>
4358
4359         * MODULES.html.sh (func_module): Break long lines.
4360         Suggested by Bruce Korb <bkorb@gnu.org>.
4361
4362 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4363
4364         Speed up by a factor of 1.12.
4365         * gnulib-tool (nl): New variable.
4366         (func_import): Rewrite include directive extraction to only read each
4367         directive once.
4368
4369 2006-09-17  Bruno Haible  <bruno@clisp.org>
4370
4371         * modules/javaversion (Makefile.am): Remove DEFS setting.
4372         (Depends-on): Add configmake, for PKGDATADIR definition.
4373
4374 2006-09-17  Bruno Haible  <bruno@clisp.org>
4375
4376         * gnulib-tool (func_create_testdir): Rewrite all files at once.
4377
4378 2006-09-17  Bruno Haible  <bruno@clisp.org>
4379
4380         * gnulib-tool (func_append): New function, stolen from libtool.m4.
4381         (func_modules_transitive_closure, func_modules_add_dummy,
4382         func_modules_to_filelist, func_import, func_create_testdir,
4383         func_create_megatestdir, ...): Use it wherever possible.
4384         Suggested by Ralf Wildenhues.
4385
4386 2006-09-16  Karl Berry  <karl@gnu.org>
4387
4388         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
4389         to avoid sectioning errors.
4390         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
4391         [ifinfo]: blank line after @center-ed titles.
4392         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
4393         Spell FSF address consistently with others.
4394         (These changes approved by rms.)
4395
4396 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4397
4398         Speed up by a factor of 1.61.
4399         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
4400         already checked module names again.
4401
4402 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4403
4404         Speed up by a factor of 1.13.
4405         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
4406         for new_files, and the input to func_add_or_update.
4407
4408 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4409
4410         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
4411         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
4412
4413 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4414
4415         * modules/mkancesdirs (Depends-on): Add fcntl.
4416         * modules/savewd: New file.
4417         * MODULES.html.sh (File system functions): Add savewd.
4418
4419         * modules/configmake (Makefile.am): Add support for the
4420         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
4421
4422 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4423
4424         * m4/savewd.m4: New file.
4425
4426 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
4427
4428         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
4429         (dirchownmod): New arg FD.  All callers changed.
4430         Use FD rather than opening the directory ourself, as opening is
4431         now the caller's responsibility.
4432         * lib/dirchownmod.h: Likewise.
4433         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
4434         hosts that require <sys/types.h> before <sys/stat.h>.  Include
4435         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
4436         (test_dir): Remove.
4437         (mkancesdirs): Return length of prefix of FILE that has already
4438         been made, or -2 if there is a child doing the work.  Redo
4439         algorithm so that it is O(N) rather than O(N**2).  Optimize away
4440         ".", and treat ".." specially since it might stray back into
4441         already-created areas.  Use a subprocess if necessary.  New arg
4442         WD; all users changed.  MAKE_DIR function should now return 1
4443         if it creates a directory that is not readable.  Return -2 if
4444         a child process is spun off.
4445         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
4446         Adjust signature to match code.
4447         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
4448         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
4449         all users changed.
4450         * lib/savewd.c, lib/savewd.h: New files.
4451
4452 2006-09-15  Jim Meyering  <jim@meyering.net>
4453
4454         * modules/rename-dest-slash: New module.
4455         * MODULES.html.sh (posix_compat): Add it here.
4456
4457         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
4458
4459 2006-09-15  Jim Meyering  <jim@meyering.net>
4460
4461         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
4462         file.
4463
4464         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
4465
4466 2006-09-15  Jim Meyering  <jim@meyering.net>
4467
4468         * lib/rename-dest-slash.c (has_trailing_slash): Use
4469         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
4470         (rpl_rename_dest_slash): Perform the cheaper trailing slash
4471         test before testing whether SRC is a directory.
4472         Suggestions from Bruno Haible.
4473
4474         Avoid a warning about an unused variable.
4475         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
4476         into the #ifdef block where it's used.
4477
4478         * lib/rename-dest-slash.c: New file.
4479
4480 2006-09-14  Bruno Haible  <bruno@clisp.org>
4481
4482         * lib/allocsa.c: Include <config.h> unconditionally.
4483         * lib/asnprintf.c: Likewise.
4484         * lib/asprintf.c: Likewise.
4485         * lib/c-strcasecmp.c: Likewise.
4486         * lib/c-strcasestr.c: Likewise.
4487         * lib/c-strncasecmp.c: Likewise.
4488         * lib/c-strstr.c: Likewise.
4489         * lib/classpath.c: Likewise.
4490         * lib/clean-temp.c: Likewise.
4491         * lib/concatpath.c: Likewise.
4492         * lib/copy-file.c: Likewise.
4493         * lib/csharpcomp.c: Likewise.
4494         * lib/csharpexec.c: Likewise.
4495         * lib/execute.c: Likewise.
4496         * lib/fatal-signal.c: Likewise.
4497         * lib/findprog.c: Likewise.
4498         * lib/fwriteerror.c: Likewise.
4499         * lib/gl_array_list.c: Likewise.
4500         * lib/gl_array_oset.c: Likewise.
4501         * lib/gl_avltree_list.c: Likewise.
4502         * lib/gl_avltree_oset.c: Likewise.
4503         * lib/gl_avltreehash_list.c: Likewise.
4504         * lib/gl_carray_list.c: Likewise.
4505         * lib/gl_linked_list.c: Likewise.
4506         * lib/gl_linkedhash_list.c: Likewise.
4507         * lib/gl_list.c: Likewise.
4508         * lib/gl_oset.c: Likewise.
4509         * lib/gl_rbtree_list.c: Likewise.
4510         * lib/gl_rbtree_oset.c: Likewise.
4511         * lib/gl_rbtreehash_list.c: Likewise.
4512         * lib/imaxabs.c: Likewise.
4513         * lib/imaxdiv.c: Likewise.
4514         * lib/javacomp.c: Likewise.
4515         * lib/javaexec.c: Likewise.
4516         * lib/javaversion.c: Likewise.
4517         * lib/linebreak.c: Likewise.
4518         * lib/localcharset.c: Likewise.
4519         * lib/lock.c: Likewise.
4520         * lib/mbchar.c: Likewise.
4521         * lib/mbswidth.c: Likewise.
4522         * lib/mkdtemp.c: Likewise.
4523         * lib/pipe.c: Likewise.
4524         * lib/printf-args.c: Likewise.
4525         * lib/printf-parse.c: Likewise.
4526         * lib/progname.c: Likewise.
4527         * lib/progreloc.c: Likewise.
4528         * lib/readlink.c: Likewise.
4529         * lib/sh-quote.c: Likewise.
4530         * lib/stpcpy.c: Likewise.
4531         * lib/stpncpy.c: Likewise.
4532         * lib/strcasecmp.c: Likewise.
4533         * lib/strcasestr.c: Likewise.
4534         * lib/strcspn.c: Likewise.
4535         * lib/striconv.c: Likewise.
4536         * lib/strncasecmp.c: Likewise.
4537         * lib/strnlen1.c: Likewise.
4538         * lib/strstr.c: Likewise.
4539         * lib/strtok_r.c: Likewise.
4540         * lib/tls.c: Likewise.
4541         * lib/tmpdir.c: Likewise.
4542         * lib/unicodeio.c: Likewise.
4543         * lib/unsetenv.c: Likewise.
4544         * lib/vasnprintf.c: Likewise.
4545         * lib/vasprintf.c: Likewise.
4546         * lib/wait-process.c: Likewise.
4547         * lib/xallocsa.c: Likewise.
4548         * lib/xsetenv.c: Likewise.
4549         * lib/xstriconv.c: Likewise.
4550
4551 2006-09-13  Simon Josefsson  <jas@extundo.com>
4552
4553         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
4554         that internally, suggested by Ralf Wildenhues
4555         <Ralf.Wildenhues@gmx.de>.
4556
4557 2006-09-13  Simon Josefsson  <jas@extundo.com>
4558
4559         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
4560         @LIBOBJS@.
4561         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4562
4563 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
4564
4565         * lib/_fpending.c: Include <config.h> unconditionally, since we no
4566         longer worry about uses that don't define HAVE_CONFIG_H.
4567         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
4568         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
4569         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
4570         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
4571         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
4572         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
4573         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
4574         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
4575         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
4576         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
4577         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
4578         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
4579         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
4580         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
4581         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
4582         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
4583         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
4584         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
4585         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
4586         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
4587         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
4588         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
4589         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
4590         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
4591         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
4592         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
4593         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
4594         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
4595         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
4596         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
4597         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
4598         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
4599         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
4600         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
4601         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
4602         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
4603         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
4604         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
4605         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
4606         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
4607         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
4608         Likewise.
4609
4610 2006-09-13  Eric Blake  <ebb9@byu.net>
4611
4612         * lib/getopt.c: Fix typo in last commit.
4613
4614 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
4615
4616         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
4617         dgettext.
4618
4619 2006-09-12  Jim Meyering  <jim@meyering.net>
4620
4621         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
4622         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
4623         Reported by Nelson H. F. Beebe.
4624
4625 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
4626
4627         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
4628         program_invocation_name and program_invocation_short_name are
4629         initialized.
4630         * lib/argp-namefrob.h: Move declarations of program_invocation_name
4631         and program_invocation_short_name to argp.h, so they are visible
4632         to user programs.
4633         * lib/argp.h: Likewise
4634
4635 2006-09-10  Bruno Haible  <bruno@clisp.org>
4636
4637         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4638         m4/inttypes_h.m4, m4/uintmax_t.m4.
4639
4640 2006-09-10  Bruno Haible  <bruno@clisp.org>
4641
4642         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
4643         gl_AC_TYPE_UINTMAX_T.
4644
4645 2006-09-10  Bruno Haible  <bruno@clisp.org>
4646
4647         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
4648
4649 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
4650
4651         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
4652         convention.  Text proposed by Bruno Haible.
4653         (struct argp_option): Document the use of N_() wrappers.
4654
4655         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
4656         '\v', and translate the two parts separately, instead of feeding
4657         the whole string to gettext.  This allows to exclude
4658         '\v' from the strings visible to the translator by writing doc
4659         strings as N_("..") "\v" N_("..").
4660
4661 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
4662
4663         * config/srclist.txt: Undo latest change; the bug was fixed.
4664
4665 2006-09-09  Bruno Haible  <bruno@clisp.org>
4666
4667         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
4668         assignments if building a library without libtool.
4669         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
4670         in func_emit_lib_Makefile_am.
4671         (func_import): When building a static library libfoo.a, arrange to
4672         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
4673         (func_create_testdir): Likewise.
4674         * modules/gc (configure.ac, Makefile.am): If building statically,
4675         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
4676         * modules/iconvme (configure.ac, Makefile.am): Likewise.
4677         * modules/striconv (configure.ac, Makefile.am): Likewise.
4678         Based on a suggestion by Ralf Wildenhues.
4679
4680 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4681
4682         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
4683         Check for unistd.h too, since Autoconf doesn't assume POSIX.
4684         Also:
4685
4686         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4687         Add year_2050_test to catch glibc bug 2821
4688         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
4689
4690         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
4691         Prefer #ifdef to #if.
4692
4693         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
4694         Return from 'main' instead of calling 'exit'.
4695
4696 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4697
4698         * lib/mktime.c (guess_time_tm): Fix bug where mktime
4699         returned the maximum time_t value rather than (time_t) -1.
4700         Problem originally reported by William Bardwell
4701         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
4702
4703         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
4704         Moved to here ...
4705         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
4706         ... from here.
4707
4708 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
4709
4710         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
4711         2821 is fixed.
4712
4713 2006-09-08  Jim Meyering  <jim@meyering.net>
4714
4715         Don't make generated files read-only.  That would bother too many
4716         people.  However, do retain the ability to work when targets are
4717         read-only: remove the destination and temporary files before writing
4718         them (when generated via sed or echo), or by using the -f option for
4719         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
4720         * modules/alloca-opt, modules/argz, modules/arpa_inet:
4721         * modules/byteswap, modules/configmake, modules/fcntl:
4722         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
4723         * modules/localcharset, modules/netinet_in, modules/poll:
4724         * modules/stdbool, modules/stdint, modules/sys_select:
4725         * modules/sys_socket, modules/sys_stat, modules/sysexits:
4726
4727 2006-09-08  Jim Meyering  <jim@meyering.net>
4728
4729         Avoid new build failure on FreeBSD 6.0.
4730         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
4731         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
4732         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
4733
4734 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4735
4736         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
4737
4738 2006-09-07  Jim Meyering  <jim@meyering.net>
4739
4740         Fix global typo in last change: use chmod u-w, not chmod u-x.
4741         Spotted by Paul Eggert and Bruce Korb.
4742         * modules/alloca-opt, modules/argz, modules/arpa_inet:
4743         * modules/byteswap, modules/configmake, modules/fcntl:
4744         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
4745         * modules/localcharset, modules/netinet_in, modules/poll:
4746         * modules/stdbool, modules/stdint, modules/sys_select:
4747         * modules/sys_socket, modules/sys_stat, modules/sysexits:
4748
4749 2006-09-06  Jim Meyering  <jim@meyering.net>
4750
4751         Make generated files be read-only.
4752         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
4753         Ensure that each generated file is now read-only.
4754         * modules/argz: Likewise.
4755         * modules/arpa_inet: Likewise.
4756         * modules/byteswap: Likewise.
4757         * modules/configmake: Likewise.
4758         * modules/fcntl: Likewise.
4759         * modules/fnmatch: Likewise.
4760         * modules/getopt: Likewise.
4761         * modules/glob: Likewise.
4762         * modules/inttypes: Likewise.
4763         * modules/netinet_in: Likewise.
4764         * modules/poll: Likewise.
4765         * modules/stdbool: Likewise.
4766         * modules/stdint: Likewise.
4767         * modules/sys_select: Likewise.
4768         * modules/sys_socket: Likewise.
4769         * modules/sys_stat: Likewise.
4770         * modules/sysexits: Likewise.
4771         * modules/localcharset: Same as above, but continue using temporary
4772         file named "t-$@" (why different?) rather than the "$@-t" used
4773         everywhere else.
4774
4775         * modules/sysexits (Makefile.am): Replace literal occurrences
4776         of "sysexit.h" more readable, and more consistent, "$@".
4777
4778 2006-09-06  Bruno Haible  <bruno@clisp.org>
4779
4780         * modules/striconv: New file.
4781         * modules/xstriconv: New file.
4782         * MODULES.html.sh (Internationalization functions): Add striconv,
4783         xstriconv.
4784
4785 2006-09-06  Bruno Haible  <bruno@clisp.org>
4786
4787         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
4788         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
4789         not using libtool correctly.
4790
4791 2006-09-06  Bruno Haible  <bruno@clisp.org>
4792
4793         * lib/striconv.h: New file.
4794         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
4795         iconvstring.c.
4796         * lib/xstriconv.h: New file.
4797         * lib/xstriconv.c: New file.
4798
4799 2006-09-06  Bruno Haible  <bruno@clisp.org>
4800
4801         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4802         lib_..._LDFLAGS.
4803
4804 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4805
4806         * lib/argz_.h: Sync from Libtool.
4807
4808         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
4809                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4810
4811         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
4812
4813 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
4814
4815         * modules/trim: New file.
4816
4817 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
4818
4819         * lib/trim.h: New file.
4820         * lib/trim.c: New file.
4821
4822 2006-09-05  Bruno Haible  <bruno@clisp.org>
4823
4824         * MODULES.html.sh (String handling): Add trim.
4825
4826 2006-09-04  Karl Berry  <karl@gnu.org>
4827
4828         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
4829         until next release.
4830
4831 2006-09-03  Bruno Haible  <bruno@clisp.org>
4832
4833         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
4834         correctly.
4835
4836 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4837
4838         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
4839         not gl_GETLOADAVG.  Omit unneeded semicolons.
4840         Problems reported by Ralf Wildenhues in
4841         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
4842         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
4843         at the end, which is the usual gnulib style.
4844
4845         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
4846         of doing all the work ourselves.
4847         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
4848         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
4849
4850 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4851
4852         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
4853         Problem reported by Ralf Wildenhues in
4854         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
4855
4856         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
4857         HAVE_STRUCT_STATFS_F_FSTYPENAME.
4858
4859 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4860
4861         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
4862         yesterday's patch by changing test -n to test -z.
4863
4864 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4865
4866         * modules/getloadavg (Files): Add m4/getloadavg.m4.
4867         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
4868         the former is now obsolescent.
4869
4870         * modules/chdir-long (Depends-on): Add fcntl.
4871
4872 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4873
4874         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
4875         obsolescent, and programs should use gnulib instead.
4876         * m4/getloadavg.m4: New file, with contents taken from Autoconf
4877         but with prefixes changed.
4878
4879 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4880
4881         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
4882         or stdbool.h, because they might not exist while configuring.
4883
4884         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
4885         Don't include unistd.h or limits.h; not needed, since chdir-long.h
4886         does that for us.
4887         (O_DIRECTORY): Remove.
4888
4889 2006-08-31  Eric Blake  <ebb9@byu.net>
4890
4891         * gnulib-tool: Don't let emacs change spaces to TAB.
4892
4893 2006-08-31  Bruno Haible  <bruno@clisp.org>
4894
4895         * gnulib-tool: When calling func_import more than once, do it in a
4896         subshell.
4897         Reported by Eric Blake <ebb9@byu.net>.
4898
4899 2006-08-31  Bruno Haible  <bruno@clisp.org>
4900
4901         * gnulib-tool (nl): Remove variable.
4902         (sed_transform_lib_file): Use more robust test for config-h module.
4903         (func_import): Fix typo in 2006-08-25 patch.
4904
4905 2006-08-31  Bruno Haible  <bruno@clisp.org>
4906
4907         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
4908         specified, augment Makefile.am variables instead of assigning them.
4909
4910 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4911
4912         Work around a bug in both the Linux and SunOS 64-bit kernels:
4913         nanosleep mishandles sleeps for longer than 2**31 seconds.
4914         Problem reported by Frank v Waveren in
4915         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
4916         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
4917         Check for nanosleep bug.
4918         (LIB_NANOSLEEP): Append clock_gettime library if needed.
4919
4920 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4921
4922         Work around a bug in both the Linux and SunOS 64-bit kernels:
4923         nanosleep mishandles sleeps for longer than 2**31 seconds.
4924         Problem reported by Frank v Waveren in
4925         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
4926         * lib/nanosleep.c (BILLION): New constant.
4927         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
4928         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
4929         implementation.
4930
4931 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4932
4933         * modules/nanosleep (Depends-on): Add gettime.
4934
4935 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4936         and Simon Josefsson  <jas@extundo.com>
4937         and Oskar Liljeblad  <oskar@osk.mine.nu>
4938
4939         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
4940         * gnulib-tool (func_import): New license type 'unmodifiable license
4941         text'.
4942         * modules/fdl: Use it.  Longer description.
4943         * module/gpl, module/lgpl: New files.
4944
4945 2006-08-30  Jim Meyering  <jim@meyering.net>
4946
4947         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
4948         shadowing the parameter.
4949
4950 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4951
4952         Sync from Libtool:
4953
4954         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4955
4956         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
4957         sharing with gnulib.  Report by Eric Blake.
4958
4959 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4960
4961         * modules/isapipe: New file.
4962         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
4963
4964 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4965
4966         * modules/configmake (Makefile.am): Add a comment, and omit
4967         the CONFIGMAKE_ prefix from generated macro names.  Suggested
4968         by Bruno Haible.
4969
4970 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4971
4972         * m4/isapipe.m4: New file.
4973
4974 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4975
4976         * lib/isapipe.c, lib/isapipe.h: New files.
4977
4978 2006-08-29  Jim Meyering  <jim@meyering.net>
4979
4980         * modules/configmake (Makefile.am): Make configmake.h depend on
4981         Makefile.  Otherwise, a stale configmake.h could hang around.
4982
4983 2006-08-29  Eric Blake  <ebb9@byu.net>
4984
4985         * lib/error.c (error_at_line, print_errno_message): Match libc, after
4986         resolution of upstream bug 3044.
4987
4988 2006-08-29  Bruno Haible  <bruno@clisp.org>
4989
4990         * modules/localcharset (Depends-on): Add configmake.
4991         (Makefile.am): Remove setting of LIBDIR through DEFS.
4992
4993 2006-08-29  Bruno Haible  <bruno@clisp.org>
4994
4995         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
4996         defined.
4997
4998 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4999
5000         * modules/fcntl: New file.
5001         * modules/chdir-safer (Depends-on): Add fcntl.
5002         * modules/fts: Likewise.
5003         * modules/mkdir-p: Likewise.
5004
5005         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
5006         This undoes the most recent change, since we're now addressing the
5007         problem in a different way.
5008
5009         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
5010         into output, since the output might be called Makefile.am even
5011         if $makefile_name is something different.
5012         (func_import): Use $makefile_am rather than
5013         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
5014         empty.
5015
5016         * modules/inttypes (Files): Add m4/inttypes-h.m4.
5017
5018 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5019
5020         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
5021         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
5022         recent change to stdint.m4, since we're now addressing the problem in a
5023         different way.
5024
5025 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5026
5027         * m4/fcntl_h.m4: New file.
5028
5029 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
5030
5031         * lib/fcntl_.h: New file.
5032         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
5033         the fcntl module.
5034         * lib/dirchownmod.c: Likewise.
5035         * lib/fts.c: Likewise.
5036
5037         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
5038         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
5039         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
5040         just before including <inttypes.h>, to avoid circular inclusion.
5041
5042 2006-08-28  Jim Meyering  <jim@meyering.net>
5043
5044         * doc/visibility.texi: Actually read and correct the grammar of the
5045         sentence affected by yesterday's change.
5046
5047 2006-08-28  Eric Blake  <ebb9@byu.net>
5048
5049         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
5050         needs wrapper.
5051
5052 2006-08-28  Eric Blake  <ebb9@byu.net>
5053
5054         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
5055
5056 2006-08-28  Eric Blake  <ebb9@byu.net>
5057
5058         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
5059
5060 2006-08-28  Bruno Haible  <bruno@clisp.org>
5061
5062         * modules/c-strstr: New file, from GNU gettext.
5063         * MODULES.html.sh (String handling): Add c-strstr.
5064
5065 2006-08-28  Bruno Haible  <bruno@clisp.org>
5066
5067         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
5068         macros.
5069         Reported by Eric Blake.
5070
5071 2006-08-28  Bruno Haible  <bruno@clisp.org>
5072
5073         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
5074         (VASNPRINTF): Return a string of length > INT_MAX without failing.
5075         * lib/vasprintf.c: Include errno.h, limits.h.
5076         (EOVERFLOW): New fallback definition.
5077         (vasprintf): Test here whether the string length is > INT_MAX.
5078         * lib/vsnprintf.c: Include errno.h, limits.h.
5079         (EOVERFLOW): New fallback definition.
5080         (vsnprintf): Fix bug when generated string was too long for the buffer.
5081         Test here whether the string length is > INT_MAX.
5082
5083 2006-08-28  Bruno Haible  <bruno@clisp.org>
5084
5085         * lib/inttypes_.h (SCNX*): Remove definitions.
5086         Reported by Eric Blake.
5087
5088 2006-08-28  Bruno Haible  <bruno@clisp.org>
5089
5090         * lib/c-strstr.h: New file, from GNU gettext.
5091         * lib/c-strstr.c: New file, from GNU gettext.
5092
5093 2006-08-28  Bruno Haible  <bruno@clisp.org>
5094
5095         * gnulib-tool: Reorder some statements.
5096
5097 2006-08-28  Bruno Haible  <bruno@clisp.org>
5098
5099         * gnulib-tool: New option --makefile-name.
5100         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
5101         $makefile_name.
5102         (func_import): Write $makefile_name to the cache file, and read it from
5103         there unless explicitly specified. Use $makefile_name as file name
5104         instead of Makefile.am. Adjust the recommendations accordingly.
5105
5106 2006-08-28  Bruno Haible  <bruno@clisp.org>
5107
5108         * gnulib-tool (func_verify_module): Check against misapplying patch.
5109
5110 2006-08-28  Bruno Haible  <bruno@clisp.org>
5111
5112         * gnulib-tool (func_relativize, func_relconcat): New functions.
5113         Give an error if --local-dir is given with --update.
5114         Remove trailing slashes from $local_gnulib_dir.
5115         (func_import): Store the relativized $local_gnulib_dir in
5116         gnulib-cache.m4, and read it from there if not specified explicitly.
5117
5118 2006-08-28  Bruno Haible  <bruno@clisp.org>
5119
5120         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
5121         is the current directory. Respect also $local_gnulib_dir.
5122
5123 2006-08-28  Bruno Haible  <bruno@clisp.org>
5124             Simon Josefsson  <jas@extundo.com>
5125
5126         BeOS portability.
5127         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
5128
5129 2006-08-27  Jim Meyering  <jim@meyering.net>
5130
5131         * doc/visibility.texi: Remove duplicate word: "pointer".
5132
5133 2006-08-26  Bruno Haible  <bruno@clisp.org>
5134
5135         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
5136         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
5137         (Makefile.am): Create inttypes.h from inttypes_.h.
5138         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
5139
5140         * modules/imaxabs: New file.
5141
5142         * modules/imaxdiv: New file.
5143
5144 2006-08-26  Bruno Haible  <bruno@clisp.org>
5145
5146         * m4/inttypes.m4: New file.
5147         * m4/_inttypes_h.m4: Remove file.
5148         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
5149         PRI_MACROS_BROKEN.
5150         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
5151
5152         * m4/imaxabs.m4: New file.
5153
5154         * m4/imaxdiv.m4: New file.
5155
5156 2006-08-26  Bruno Haible  <bruno@clisp.org>
5157
5158         * lib/inttypes_.h: New file.
5159         * lib/inttypes.h: Remove file.
5160         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
5161
5162         * lib/imaxabs.c: New file.
5163
5164         * lib/imaxdiv.c: New file.
5165
5166 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
5167
5168         New config-h module, so that "make" output needn't be cluttered
5169         by -DHAVE_CONFIG_H.
5170         * MODULES.html.sh (Support for building libraries and executables):
5171         Add config-h.
5172         * modules/config-h: New file.
5173         * gnulib-tool (nl, sed_transform_lib_file): New vars.
5174         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
5175         the config-h module is used.
5176
5177         New configmake module, so that "make" output needn't be cluttered
5178         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
5179         * MODULES.html.sh (Support for building libraries and executables):
5180         Add configmake.
5181         * modules/configmake: New file.
5182
5183 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
5184
5185         * m4/config-h.m4: New file.
5186
5187 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
5188
5189         * config/srclist.txt: Add elisp-comp.
5190
5191 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
5192
5193         * MODULES.html.sh (Support for building libraries and executables):
5194         Add elisp-comp.
5195         * build-aux/elisp-comp: New file.
5196         * modules/elisp-comp: New file.
5197
5198 2006-08-24  Bruno Haible  <bruno@clisp.org>
5199
5200         * gnulib-tool (func_create_testdir): Use non-default values of
5201         sourcebase and m4base.
5202
5203 2006-08-24  Bruno Haible  <bruno@clisp.org>
5204
5205         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
5206         HTML structure.
5207
5208 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
5209
5210         * modules/openat (Depends-on): Add lchown.
5211
5212 2006-08-23  Bruno Haible  <bruno@clisp.org>
5213
5214         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
5215         of gl_LOCK_EARLY instead of gl_LOCK.
5216
5217 2006-08-23  Bruno Haible  <bruno@clisp.org>
5218
5219         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
5220         on OSF/1 to no.
5221         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
5222
5223 2006-08-23  Bruno Haible  <bruno@clisp.org>
5224
5225         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
5226         as unusable.
5227
5228         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
5229         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
5230         (gl_LOCK): New macro.
5231
5232 2006-08-22  Simon Josefsson  <jas@extundo.com>
5233
5234         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
5235         to md5 module.
5236
5237 2006-08-22  Simon Josefsson  <jas@extundo.com>
5238
5239         * MODULES.html.sh: Add "Support for maintaining and release
5240         projects".
5241
5242         * build-aux/gnupload: New file, from coreutils.
5243
5244 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5245
5246         Avoid the need for AC_LIBSOURCES in m4 macros.
5247         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
5248         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
5249         * modules/check-version (EXTRA_DIST): Add check-version.h.
5250         * modules/crc (EXTRA_DIST): Add crc.h.
5251         * modules/des (EXTRA_DIST): Add des.h.
5252         * modules/gc (EXTRA_DIST): Add gc.h.
5253         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
5254         * modules/getline (EXTRA_DIST): Add getline.h.
5255         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
5256         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
5257         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
5258         * modules/md2 (EXTRA_DIST): Add md2.h.
5259         * modules/md4 (EXTRA_DIST): Add md4.h.
5260         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
5261         * modules/read-file (EXTRA_DIST): Add read-file.h.
5262         * modules/readline (EXTRA_DIST): Add readline.h.
5263         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
5264         rijndael-api-fst.h.
5265
5266 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5267
5268         * m4/rijndael.m4 (gl_ARCFOUR):
5269         * m4/arctwo.m4 (gl_ARCTWO):
5270         * m4/check-version.m4 (gl_CHECK_VERSION):
5271         * m4/crc.m4 (gl_CRC):
5272         * m4/des.m4 (gl_DES):
5273         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
5274         * m4/gc.m4 (gl_GC):
5275         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
5276         * m4/getline.m4 (gl_FUNC_GETLINE):
5277         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
5278         * m4/hmac-md5.m4 (gl_HMAC_MD5):
5279         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
5280         * m4/md2.m4 (gl_MD2):
5281         * m4/md4.m4 (gl_MD4):
5282         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
5283         * m4/read-file.m4 (gl_FUNC_READ_FILE):
5284         * m4/readline.m4 (gl_FUNC_READLINE):
5285         * m4/rijndael.m4 (gl_RIJNDAEL):
5286         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
5287         to get the necessary .h files and whatnot.
5288
5289 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
5290
5291         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
5292         gnulib rather than the other way around.
5293         * config/srclistvars.sh (COREUTILS): Remove.
5294
5295 2006-08-22  Jim Meyering  <jim@meyering.net>
5296
5297         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
5298
5299         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
5300
5301 2006-08-22  Eric Blake  <ebb9@byu.net>
5302
5303         * modules/regexprops-generic: New file.
5304         * MODULES.html.sh (Support for building documentation): List it.
5305
5306 2006-08-22  Eric Blake  <ebb9@byu.net>
5307
5308         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
5309         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
5310         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
5311         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
5312
5313 2006-08-22  Bruno Haible  <bruno@clisp.org>
5314
5315         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
5316         and lib_LTLIBRARIES like the other lib_* variables.
5317
5318 2006-08-22  Bruno Haible  <bruno@clisp.org>
5319
5320         * build-aux/x-to-1.in: New file, from GNU gettext.
5321
5322 2006-08-22  Bruno Haible  <bruno@clisp.org>
5323
5324         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
5325         <utmpx.h> exists.
5326
5327 2006-08-22  Bruno Haible  <bruno@clisp.org>
5328
5329         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
5330         <utmpx.h> exists.
5331
5332 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5333
5334         BeOS portability.
5335         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
5336         exist.
5337         Problem reported by Bruno Haible.
5338
5339 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5340
5341         Avoid the need for AC_LIBSOURCES in m4 macros.
5342         * modules/acl (EXTRA_DIST): Add acl.h.
5343         * modules/argmatch (Files): Add m4/argmatch.m4.
5344         (configure.ac): Add gl_ARGMATCH.
5345         (EXTRA_DIST): Renamed from lib_SOURCES, for
5346         consistency with the other modules.  Remove argmatch.c.
5347         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
5348         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
5349         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
5350         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
5351         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
5352         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
5353         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
5354         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
5355         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
5356         * modules/closeout (EXTRA_DIST): Add closeout.h.
5357         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
5358         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
5359         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
5360         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
5361         dirname.h; remove basename.c and stripslash.c.
5362         * modules/exclude (EXTRA_DIST): Add exclude.h.
5363         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
5364         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
5365         * modules/file-type (EXTRA_DIST): Add file-type.h.
5366         * modules/filemode (EXTRA_DIST): Add filemode.h.
5367         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
5368         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
5369         * modules/fpending (EXTRA_DIST): Add __fpending.h.
5370         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
5371         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
5372         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
5373         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
5374         * modules/getdate (EXTRA_DIST): Add getdate.c.
5375         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
5376         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
5377         * modules/getpass (EXTRA_DIST): Add getpass.h.
5378         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
5379         * modules/group-member (EXTRA_DIST): Add group-member.h.
5380         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
5381         * modules/hash (EXTRA_DIST): Add hash.h.
5382         * modules/human (EXTRA_DIST): Add human.h.
5383         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
5384         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
5385         * modules/lchown (EXTRA_DIST): Add lchown.h.
5386         * modules/long-options (EXTRA_DIST): Add long-options.h.
5387         * modules/lstat (EXTRA_DIST): Add lstat.h.
5388         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
5389         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
5390         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
5391         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
5392         * modules/memxor (EXTRA_DIST): Add memxor.h.
5393         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
5394         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
5395         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
5396         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
5397         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
5398         * modules/physmem (EXTRA_DIST): Add physmem.h.
5399         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
5400         * modules/posixver (EXTRA_DIST): Add posixver.h.
5401         * modules/quote (EXTRA_DIST): Add quote.h.
5402         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
5403         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
5404         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
5405         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
5406         regex_internal.h regexec.c.
5407         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
5408         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
5409         * modules/same (EXTRA_DIST): Add same.h.
5410         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
5411         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
5412         * modules/savedir (EXTRA_DIST): Add savedir.h.
5413         * modules/sha1 (EXTRA_DIST): Add sha1.h.
5414         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
5415         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
5416         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
5417         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
5418         * modules/strdup (EXTRA_DIST): Add strdup.h.
5419         * modules/strftime (EXTRA_DIST): Add strftime.h.
5420         * modules/strndup (EXTRA_DIST): Add strndup.h.
5421         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
5422         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
5423         * modules/time_r (EXTRA_DIST): Add time_r.h.
5424         * modules/timespec (EXTRA_DIST): Add timespec.h.
5425         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
5426         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
5427         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
5428         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
5429         * modules/userspec (EXTRA_DIST): Add userspec.h.
5430         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
5431         * modules/utimens (EXTRA_DIST): Add utimens.h.
5432         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
5433         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
5434         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
5435         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
5436         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
5437         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
5438         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
5439         * modules/yesno (EXTRA_DIST): Add yesno.h.
5440
5441 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
5442
5443         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
5444
5445         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
5446         * m4/dev-ino.m4, same-inode.m4: Remove.
5447
5448         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
5449         * m4/acl.m4 (AC_FUNC_ACL):
5450         * m4/backupfile.m4 (gl_BACKUPFILE):
5451         * m4/c-strtod.m4 (gl_C99_STRTOLD):
5452         * m4/canon-host.m4 (gl_CANON_HOST):
5453         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
5454         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
5455         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
5456         * m4/cloexec.m4 (gl_CLOEXEC):
5457         * m4/close-stream.m4 (gl_CLOSE_STREAM):
5458         * m4/closeout.m4 (gl_CLOSEOUT):
5459         * m4/dirfd.m4 (gl_FUNC_DIRFD):
5460         * m4/dirname.m4 (gl_DIRNAME):
5461         * m4/exclude.m4 (gl_EXCLUDE):
5462         * m4/exitfail.m4 (gl_EXITFAIL):
5463         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
5464         * m4/file-type.m4 (gl_FILE_TYPE):
5465         * m4/filemode.m4 (gl_FILEMODE):
5466         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
5467         * m4/fpending.m4 (gl_FUNC_FPENDING):
5468         * m4/fprintftime.m4 (gl_FPRINTFTIME):
5469         * m4/fts.m4 (gl_FUNC_FTS):
5470         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
5471         * m4/getdate.m4 (gl_GETDATE):
5472         * m4/gethrxtime.m4 (gl_GETHRXTIME):
5473         * m4/getpagesize.m4 (gl_GETPAGESIZE):
5474         * m4/getpass.m4 (gl_FUNC_GETPASS):
5475         * m4/gettime.m4 (gl_GETTIME):
5476         * m4/getugroups.m4 (gl_GETUGROUPS):
5477         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
5478         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
5479         * m4/hard-locale.m4 (gl_HARD_LOCALE):
5480         * m4/hash.m4 (gl_HASH):
5481         * m4/idcache.m4 (gl_IDCACHE):
5482         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
5483         * m4/lchown.m4 (gl_FUNC_LCHOWN):
5484         * m4/long-options.m4 (gl_LONG_OPTIONS):
5485         * m4/lstat.m4 (gl_FUNC_LSTAT):
5486         * m4/md5.m4 (gl_MD5):
5487         * m4/memcasecmp.m4 (gl_MEMCASECMP):
5488         * m4/memcoll.m4 (gl_MEMCOLL):
5489         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
5490         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
5491         * m4/memxor.m4 (gl_MEMXOR):
5492         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
5493         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
5494         * m4/modechange.m4 (gl_MODECHANGE):
5495         * m4/mountlist.m4 (gl_MOUNTLIST):
5496         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5497         * m4/openat.m4 (gl_FUNC_OPENAT):
5498         * m4/pathmax.m4 (gl_PATHMAX):
5499         * m4/physmem.m4 (gl_PHYSMEM):
5500         * m4/posixtm.m4 (gl_POSIXTM):
5501         * m4/posixver.m4 (gl_POSIXVER):
5502         * m4/quote.m4 (gl_QUOTE):
5503         * m4/quotearg.m4 (gl_QUOTEARG):
5504         * m4/readtokens.m4 (gl_READTOKENS):
5505         * m4/readutmp.m4 (gl_READUTMP):
5506         * m4/regex.m4 (gl_REGEX):
5507         * m4/safe-read.m4 (gl_SAFE_READ):
5508         * m4/safe-write.m4 (gl_SAFE_WRITE):
5509         * m4/same.m4 (gl_SAME):
5510         * m4/save-cwd.m4 (gl_SAVE_CWD):
5511         * m4/savedir.m4 (gl_SAVEDIR):
5512         * m4/settime.m4 (gl_SETTIME):
5513         * m4/sha1.m4 (gl_SHA1):
5514         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
5515         * m4/stat-macros.m4 (gl_STAT_MACROS):
5516         * m4/stat-time.m4 (gl_STAT_TIME):
5517         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
5518         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
5519         * m4/strdup.m4 (gl_FUNC_STRDUP):
5520         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
5521         * m4/strndup.m4 (gl_FUNC_STRNDUP):
5522         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
5523         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
5524         * m4/time_r.m4 (gl_TIME_R):
5525         * m4/timespec.m4 (gl_TIMESPEC):
5526         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
5527         * m4/unlinkdir.m4 (gl_UNLINKDIR):
5528         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
5529         * m4/userspec.m4 (gl_USERSPEC):
5530         * m4/utimecmp.m4 (gl_UTIMECMP):
5531         * m4/utimens.m4 (gl_UTIMENS):
5532         * m4/xalloc.m4 (gl_XALLOC):
5533         * m4/xgetcwd.m4 (gl_XGETCWD):
5534         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
5535         * m4/xreadlink.m4 (gl_XREADLINK):
5536         * m4/xstrtod.m4 (gl_XSTRTOD):
5537         * m4/yesno.m4 (gl_YESNO):
5538         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
5539         to get the necessary .h files and whatnot.
5540
5541 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
5542             Bruno Haible  <bruno@clisp.org>
5543
5544         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
5545         /bin/sh understanding of '!' conditional negation.
5546
5547 2006-08-21  Jim Meyering  <jim@meyering.net>
5548
5549         * modules/openat (Depends-on): Really alphabetize.
5550
5551         * modules/acl (Depends-on): Add error and quote.
5552
5553         * check-module (find_included_lib_files): Add at-func.c to the
5554         ok-to-include-more-than-once white list.
5555
5556         * modules/openat (Depends-on): Add lstat.  Alphabetize.
5557
5558 2006-08-21  Bruno Haible  <bruno@clisp.org>
5559
5560         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5561         Emit a pkgdata_DATA variable only if some snippets add contents to it.
5562         Reported by Martin Lambers <marlam@marlam.de>.
5563
5564 2006-08-21  Bruno Haible  <bruno@clisp.org>
5565
5566         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
5567         specify an installation location, don't emit a noinst_LIBRARIES or
5568         noinst_LTLIBRARIES assignment.
5569
5570 2006-08-21  Bruno Haible  <bruno@clisp.org>
5571
5572         BeOS portability.
5573         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
5574         BeOS has mbrtowc() but no <wctype.h>.
5575
5576 2006-08-21  Bruno Haible  <bruno@clisp.org>
5577
5578         BeOS portability.
5579         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
5580         exist.
5581
5582 2006-08-21  Bruno Haible  <bruno@clisp.org>
5583
5584         BeOS portability.
5585         * lib/mbchar.h: Include <wctype.h> only if it exists.
5586
5587 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
5588
5589         Remove files that are no longer needed by their respective modules.
5590         * m4/obstack.m4: Remove.
5591         * m4/strerror_r.m4: Remove.
5592         * m4/uint32_t.m4: Remove.
5593         * m4/uintptr_t.m4: Remove.
5594         * m4/ullong_max.m4: Remove.
5595         * m4/xstrtoimax.m4: Remove.
5596         * m4/xstrtoumax.m4: Remove.
5597
5598         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
5599         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
5600         dependencies now capture this.
5601
5602         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
5603         Do not use AC_LIBSOURCES, since gnulib modules now do this.
5604         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
5605         * m4/human.m4 (gl_HUMAN): Likewise.
5606         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
5607         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
5608
5609         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
5610
5611         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
5612         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
5613         stdint.
5614         * m4/human.m4 (gl_HUMAN): Likewise.
5615         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
5616         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
5617         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
5618         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
5619         * m4/xstrtol (gl_XSTRTOL): Likewise.
5620
5621         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
5622         AC_TYPE_LONG_LONG_INT.
5623         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
5624         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
5625         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
5626         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
5627
5628         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
5629         on stdbool.
5630
5631         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
5632         (gl_PREREQ_XSTRTOUL): Remove.
5633
5634         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
5635
5636         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
5637         mode.
5638
5639 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
5640
5641         Add and change modules to make it easier for coreutils to use
5642         gnulib-tool.
5643         * modules/backupfile (Files): Remove m4/d-ino.m4.
5644         (Depends-on): Add d-ino.
5645         * modules/cycle-check (Depends-on): Add stdint.
5646         (lib_SOURCES): Add cycle-check.h.
5647         * modules/d-ino: New module.
5648         * modules/d-type: New module.
5649         * modules/error (Files): Remove m4/strerror_r.m4.
5650         * modules/filemode (Files): Add m4/st_dm_mode.m4.
5651         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
5652         m4/inttypes_h.m4, m4/uintmax_t.m4.
5653         (Depends-on): Add stdint.
5654         (lib_SOURCES): Add fsusage.h.
5655         * modules/getcwd (Files): Remove d-ino.m4.
5656         (Depends-on): Add d-ino.
5657         * modules/getndelim2 (Depends-on): Add stdint.
5658         * modules/glob (Files): Remove m4/d-type.m4.
5659         (Depends-on): Add d-type.
5660         * modules/host-os: New module.
5661         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
5662         m4/inttypes_h.m4, m4/uintmax_t.m4.
5663         * Depends-on: Add stdint.
5664         (lib_SOURCES): Add human.h.
5665         * modules/inttostr (Files): Remove m4/intmax_t.m4,
5666         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
5667         m4/uintmax_t.m4, m4/ulonglong.m4.
5668         (Depends-on): Add stdint.
5669         (EXTRA_DIST): Add inttostr.h.
5670         * modules/lchmod: New module.
5671         * modules/link-follow: New module.
5672         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
5673         (Depends-on): Add lchmod.
5674         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
5675         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
5676         (Depends-on): Add stdint.
5677         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
5678         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
5679         (Depends-on): Add stdint.
5680         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
5681         * modules/perl: New module.
5682         * modules/regex (Depends-on): Add stdint.
5683         * modules/rmdir-errno: New module.
5684         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
5685         m4/intmax_t.m4.
5686         (Depends-on): Add stdint.
5687         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
5688         m4/uintmax_t.m4.
5689         (Depends-on): Add stdint.
5690         * modules/unlink-busy: New module.
5691         * modules/utimecmp (Depends-on): Add stdint.
5692         * modules/uptime: New module.
5693         * modules/winsz-ioctl: New module.
5694         * modules/winsz-termios: New module.
5695         * modules/xnanosleep (Depends-on): Add nanosleep.
5696         * modules/ullong_max: Remove.
5697         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
5698         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
5699         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
5700         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
5701         (Depends-on): Add inttypes.
5702         (lib_SOURCES): Add xstrtol.h.
5703         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
5704         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
5705         * MODULES.html.sh: Move 'assert' into the assert section.
5706         Move 'dummy' into the linking section.
5707         Remove ullong_max.
5708         Add section for compatibility checks for POSIX:2001 functions,
5709         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
5710         winsz-ioctl, and winsz-termios into it.
5711         Add lchmod.
5712         Add top-level Misc section and put host-os, perl, and uptime
5713         into it.
5714
5715 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
5716
5717         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
5718         now assume the stdint module.  Do not include inttypes.h.
5719         * lib/fsusage.h: Likewise.
5720         * lib/getndelim2.c: Likewise.
5721         * lib/human.h: Likewise.
5722         * lib/inttostr.h: Likewise.
5723         * lib/obstack.c: Likewise.
5724         * lib/regex_internal.h: Likewise.
5725         * lib/tempname.c: Likewise.
5726         * lib/utimecmp.c: Likewise.
5727         * lib/xstrtol.h: Likewise.
5728
5729         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
5730
5731         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
5732         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
5733         * lib/xtime.h: Likewise.
5734
5735 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
5736
5737         * modules/openat (Files): Add lib/fchmodat.c.
5738         Fixes problem reported by Jay Youngman.
5739
5740 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
5741
5742         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
5743         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
5744
5745 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
5746             Bruno Haible  <bruno@clisp.org>
5747
5748         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
5749         and is a script that invokes bison. Tighten the code. Add comments.
5750
5751 2006-08-18  Jim Meyering  <jim@meyering.net>
5752
5753         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
5754         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
5755         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
5756         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
5757
5758 2006-08-18  Bruno Haible  <bruno@clisp.org>
5759
5760         * modules/bison-i18n: New file.
5761         * MODULES.html.sh (Internationalization functions): Add it.
5762
5763 2006-08-18  Bruno Haible  <bruno@clisp.org>
5764
5765         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
5766         sys/statvfs.h. When getmntinfo was found, check its declaration and
5767         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
5768
5769 2006-08-18  Bruno Haible  <bruno@clisp.org>
5770
5771         * m4/bison-i18n.m4: New file, from bison.
5772
5773 2006-08-18  Bruno Haible  <bruno@clisp.org>
5774
5775         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
5776         (ME_DUMMY): Treat "kernfs" as a dummy.
5777         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
5778
5779 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
5780
5781         Update from coreutils.
5782
5783         2006-08-15  Jim Meyering  <jim@meyering.net>
5784
5785         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
5786
5787         2006-01-17  Jim Meyering  <jim@meyering.net>
5788
5789         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
5790
5791         2006-01-11  Jim Meyering  <jim@meyering.net>
5792
5793         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
5794         Check for the lchmod function.
5795
5796 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
5797
5798         Update from coreutils.
5799
5800         * lib/__fpending.h: Add copyright notice.
5801         * lib/fprintftime.h: Likewise.
5802         * lib/savedir.c: Use (C) in copyright notice.
5803         * lib/savedir.h: Likewise.
5804
5805         2006-08-15  Jim Meyering  <jim@meyering.net>
5806
5807         * lib/at-func.c: New file, with the logic of all emulated at-functions.
5808         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
5809         in support of the EXPECTED_ERRNO macro.
5810         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
5811         definitions.  Instead, define the appropriate symbols and include
5812         "at-func.c".
5813         * lib/mkdirat.c (mkdirat): Likewise.
5814         * lib/fchmodat.c (fchmodat): Likewise.
5815         (ENOSYS): Remove definition.
5816         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
5817         it.  Don't include "unistd--.h" -- it wasn't ever used.
5818
5819         2006-01-17  Jim Meyering  <jim@meyering.net>
5820
5821         Rewrite fts.c not to change the current working directory,
5822         by using openat, fstatat, fdopendir, etc..
5823
5824         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
5825         (HAVE_OPENAT_SUPPORT): Define.
5826         [_LIBC] (fchdir): Don't undef or define; no longer used.
5827         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
5828         Now, this `function' always succeeds, and consumes its file descriptor
5829         parameter -- so callers must not close such FDs.  Update callers.
5830         (diropen_fd, opendirat, cwd_advance_fd): New functions.
5831         (diropen): Add parameter, SP.  Adjust all callers.
5832         Implement using diropen_fd, rather than open.
5833         (fts_open): Initialize new member, fts_cwd_fd.
5834         Remove fts_rft-setting code.
5835         (fts_close): Close fts_cwd_fd, if necessary.
5836         (__opendir2): Define in terms of opendir or opendirat,
5837         depending on whether the FST_NOCHDIR flag is set.
5838         (fts_build): Since fts_safe_changedir consumes its FD, and since
5839         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
5840         and close the dup'd file descriptor upon failure.
5841         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
5842         (fts_safe_changedir): Tweak semantics to reflect that this function
5843         now calls cwd_advance_fd and hence consumes its FD argument.
5844         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
5845         [struct FTS] (fts_rft): Remove now-unused member.
5846         [struct FTS] (fts_cycle.state): Improve comment.
5847
5848         * lib/openat.c (openat_needs_fchdir): New function.
5849         * lib/openat.h (openat_needs_fchdir): Declare it.
5850
5851 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
5852
5853         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
5854         Problem and fix reported by Pádraig Brady in
5855         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
5856
5857 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5858
5859         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
5860
5861 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5862
5863         * lib/memcoll.c (memcoll): Optimize for the common case where the
5864         arguments are bytewise equal.
5865
5866 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5867
5868         * doc/regexprops-generic.texi: Add a copyright notice.
5869
5870 2006-08-15  Bruno Haible  <bruno@clisp.org>
5871
5872         * modules/tmpdir (License): Change to LGPL.
5873
5874 2006-08-15  Bruno Haible  <bruno@clisp.org>
5875
5876         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
5877         module.
5878
5879 2006-08-14  Simon Josefsson  <jas@extundo.com>
5880
5881         * config/srclist.txt: Add gnupload.
5882
5883 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5884
5885         Change copyright notice from LGPL 2 to GPL 2, since that's the
5886         standard form used in the gnulib repository.
5887         * tests/test-lock.c: Likewise.
5888         * tests/test-stdint.c: Likewise.
5889         * tests/test-tls.c: Likewise.
5890
5891         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
5892         prelude-manager.  User shorter URLs for GNU projects, without '?'.
5893         Add copyright notice.
5894
5895         * check-module: Add copyright notice.  Output a copyright
5896         notice if "--version" is specified.
5897         * modules/COPYING: New file.
5898         * tests/test-getaddrinfo.c: Add copyright notice.
5899         * tests/test-verify.c: Likewise.
5900
5901 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5902
5903         Change copyright notice from LGPL 2 to GPL 2, since that's the
5904         standard form used in the gnulib repository.
5905         * lib/lock.c: LGPL -> GPL.
5906         * lib/lock.h: Likewise.
5907         * lib/strnlen1.c: Likewise.
5908         * lib/strnlen1.h: Likewise.
5909         * lib/tls.c: Likewise.
5910         * lib/tls.h: Likewise.
5911         * lib/tmpdir.c: Likewise.
5912
5913         * lib/TODO: Remove; this belongs only in coreutils.
5914
5915 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5916
5917         Add copyright notices to long-enough files that lack them, since
5918         otherwise the files aren't clearly free.  Use the same notice that
5919         getdate.texi already uses.
5920         * doc/alloca-opt.texi: Add copyright notice.
5921         * doc/alloca.texi: Likewise.
5922         * doc/ctime.texi: Likewise.
5923         * doc/functions.texi: Likewise.
5924         * doc/gcd.texi: Likewise.
5925         * doc/gnulib-tool.texi: Likewise.
5926         * doc/inet_ntoa.texi: Likewise.
5927         * doc/visibility.texi: Likewise.
5928
5929         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
5930         * doc/quote.texi: Add copyright notice.
5931
5932         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
5933         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
5934         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
5935         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
5936         is now obsolete, and give a pointer to the Sun list.
5937         Add copyright notice.
5938
5939 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5940
5941         * config/srclistvars.sh: Add copyright notice.
5942
5943 2006-08-14  Eric Blake  <ebb9@byu.net>
5944
5945         Import the following change from libc:
5946
5947         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
5948
5949         Upstream bug 2997.
5950         * lib/misc/error.c: Add space between program name and message if file
5951         name is missing.
5952
5953 2006-08-12  Karl Berry  <karl@gnu.org>
5954
5955         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
5956         remove, these originate in gnulib now.
5957
5958 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5959
5960         * doc/Makefile (standards.info standards.html standards.dvi):
5961         Also depend on make-stds.texi.
5962
5963 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
5964
5965         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
5966         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
5967
5968         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
5969         in wchar_t.  Problem reported by Eric Blake.
5970
5971         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
5972         LEN is smaller than SIZE.  Suggested by Bruno Haible.
5973         Also, help the compiler to keep LEN in a register.
5974
5975 2006-08-11  Eric Blake  <ebb9@byu.net>
5976
5977         * users.txt: Sort.  Add tar.
5978
5979 2006-08-11  Bruno Haible  <bruno@clisp.org>
5980
5981         * users.txt: New file.
5982
5983 2006-08-11  Bruno Haible  <bruno@clisp.org>
5984
5985         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
5986         before <wchar.h>. Needed for OSF/1 and BSD/OS.
5987
5988 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5989
5990         * modules/snprintf (Depends-on): Remove minmax.
5991         (Maintainer): Add self and Bruno.
5992
5993 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5994
5995         * lib/.cppi-disable: Add snprintf.h, socket_.h.
5996         * lib/snprintf.c: Include <errno.h> and <limits.h>.
5997         (EOVERFLOW): Define if the system does not.
5998         Do not include "minmax.h"; it wasn't used.
5999         (snprintf): Don't assume size_t promotes to an unsigned type.
6000         Fix bug when generated string was too long for the buffer: the
6001         buffer's contents are supposed to be the initial prefix of the
6002         output.  Don't assume vasnprintf returns EOVERFLOW if the size
6003         exceeds INT_MAX; do the check ourselves.
6004
6005         Import the following changes from libc:
6006
6007         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
6008
6009         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
6010         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
6011         set wc to the byte which couldn't be converted.
6012         (re_string_reconstruct): Don't clear valid_raw_len before calling
6013         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
6014         tip_context using re_string_context_at.
6015
6016         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
6017
6018         * lib/posix/regex.h: g++ still cannot handled [restrict].
6019
6020         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
6021
6022         * lib/posix/regex.h: Remove special handling for VMS.
6023
6024 2006-08-10  Jim Meyering  <jim@meyering.net>
6025
6026         * modules/same-inode: New module.
6027         * modules/dev-ino: New module.
6028         * modules/cycle-check: Depend on these modules, rather than simply
6029         including their .h files.
6030         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
6031         required via m4/cycle-check.m4.
6032         * modules/same: Depend on new same-inode module, rather than
6033         including same-inode.h.
6034         * modules/chdir-safer: New file.
6035
6036         * modules/chown (Depends-on): Add stat-macros.
6037
6038 2006-08-10  Jim Meyering  <jim@meyering.net>
6039
6040         * m4/cycle-check.m4: New file.
6041         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
6042         * m4/dev-ino.m4, m4/same-inode.m4: New files.
6043
6044 2006-08-10  Eric Blake  <ebb9@byu.net>
6045
6046         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
6047         in from original proposal.
6048
6049 2006-08-10  Eric Blake  <ebb9@byu.net>
6050         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
6051
6052         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
6053         namespace.
6054
6055 2006-08-10  Bruno Haible  <bruno@clisp.org>
6056
6057         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
6058         as well.
6059
6060 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6061
6062         Sync from coreutils.
6063
6064         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
6065
6066         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
6067         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
6068
6069 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6070
6071         * modules/restrict: Remove; no longer needed now that we assume
6072         Autoconf 2.59 or later.
6073         * MODULES.html.sh: Remove 'restrict'.
6074         * modules/argp (Depends-on): Remove 'restrict'.
6075         * modules/base64 (Depends-on): Likewise.
6076         * modules/gc (Depends-on): Likewise.
6077         * modules/getaddrinfo (Depends-on): Likewise.
6078         * modules/glob (Depends-on): Likewise.
6079         * modules/inet_ntop (Depends-on): Likewise.
6080         * modules/inet_pton (Depends-on): Likewise.
6081         * modules/memxor (Depends-on): Likewise.
6082         * modules/regex (Depends-on): Likewise.
6083         * modules/strtok_r (Depends-on): Likewise.
6084         * modules/time_r (Depends-on): Likewise.
6085
6086 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
6087
6088         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
6089         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
6090         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6091         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
6092         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
6093         * m4/memxor.m4 (gl_MEMXOR): Likewise.
6094         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
6095         gl_C_RESTRICT replaced by AC_C_RESTRICT.
6096
6097         Merge from coreutils.
6098         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
6099         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
6100         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6101         * m4/time_r.m4 (gl_TIME_R): Likewise.
6102
6103 2006-08-09  Karl Berry  <karl@gnu.org>
6104
6105         * config/srclist.txt: no more gettext-tools, per Bruno.
6106
6107 2006-08-08  Eric Blake  <ebb9@byu.net>
6108
6109         * modules/verror: New module.
6110         * MODULES.html.sh: Document it.
6111
6112 2006-08-08  Eric Blake  <ebb9@byu.net>
6113
6114         * lib/verror.h, lib/verror.c: New files.
6115
6116 2006-08-08  Eric Blake  <ebb9@byu.net>
6117
6118         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
6119         verror_at_line output complies with GNU Coding Standards even when
6120         file is NULL.
6121
6122 2006-08-07  Bruno Haible  <bruno@clisp.org>
6123
6124         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
6125         versions of AIX.
6126         Reported by Ralf Wildenhues.
6127
6128 2006-08-07  Bruno Haible  <bruno@clisp.org>
6129
6130         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
6131         in an AC_DEFUN. Needed so that the autoconf snippets can use
6132         AC_REQUIRE.
6133
6134 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6135
6136         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6137         Initialize pkgdata_DATA.
6138         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
6139         overriding it.
6140
6141 2006-08-06  Eric Blake  <ebb9@byu.net>
6142
6143         * lib/error.h: Fold in some upstream changes from glibc.
6144         * lib/error.c: Likewise.
6145
6146 2006-08-04  Bruno Haible  <bruno@clisp.org>
6147
6148         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6149         Make the mostlyclean-local rule depend on mostlyclean-generic.
6150         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
6151
6152 2006-07-31  Bruno Haible  <bruno@clisp.org>
6153
6154         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
6155         <stdlib.h>, <string.h>.
6156
6157 2006-07-30  Bruno Haible  <bruno@clisp.org>
6158
6159         * modules/readlink (License): Change to LGPL.
6160
6161 2006-07-30  Bruno Haible  <bruno@clisp.org>
6162
6163         * modules/javaversion (Makefile.am): Distribute javaversion.java and
6164         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
6165         set PKGDATADIR to point to it.
6166
6167 2006-07-30  Bruno Haible  <bruno@clisp.org>
6168
6169         * modules/csharpexec (configure.ac): Comment out macro invocation.
6170         * modules/javaexec (configure.ac): Likewise.
6171         * modules/javacomp-script (configure.ac): Likewise.
6172
6173         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
6174
6175 2006-07-30  Bruno Haible  <bruno@clisp.org>
6176
6177         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
6178         linked-list.
6179
6180 2006-07-30  Bruno Haible  <bruno@clisp.org>
6181
6182         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
6183
6184 2006-07-30  Bruno Haible  <bruno@clisp.org>
6185
6186         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6187         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
6188         get removed.
6189
6190 2006-07-29  Bruno Haible  <bruno@clisp.org>
6191
6192         Make it possible for gnulib-tool to work with locally modified or
6193         augmented gnulib repositories.
6194         * gnulib-tool (func_usage): Document --local-dir option.
6195         (local_gnulib_dir): New variable.
6196         Handle --local-dir option.
6197         (func_lookup_file): New function.
6198         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
6199         (func_get_description, func_get_filelist, func_get_description,
6200         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
6201         func_get_automake_snippet, func_get_include_directive,
6202         func_get_license, func_get_maintainer): Use func_lookup_file.
6203         (func_import, func_create_testdir): Use func_lookup_file.
6204
6205 2006-07-29  Bruno Haible  <bruno@clisp.org>
6206
6207         * modules/setenv (Depends-on): Add unistd.
6208
6209 2006-07-29  Bruno Haible  <bruno@clisp.org>
6210
6211         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
6212
6213 2006-07-29  Bruno Haible  <bruno@clisp.org>
6214
6215         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
6216
6217 2006-07-29  Bruno Haible  <bruno@clisp.org>
6218
6219         * gnulib-tool (import, update): If there is no Makefile.am, look at
6220         aclocal.m4, instead of bailing out.
6221
6222 2006-07-29  Bruno Haible  <bruno@clisp.org>
6223
6224         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
6225         Categorize the options by when they are useful.
6226
6227 2006-07-29  Bruno Haible  <bruno@clisp.org>
6228
6229         * gnulib-tool (func_usage): Document option --no-libtool.
6230         Handle option --no-libtool.
6231         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
6232         for changed semantics of $libtool variable.
6233         (func_import): Likewise. If libtool is not used, show this through
6234         an option --no-libtool.
6235         (func_create_testdir): Update.
6236
6237 2006-07-29  Bruno Haible  <bruno@clisp.org>
6238
6239         * gnulib-tool (func_import): Extend error message about missing
6240         --doc-base.
6241
6242 2006-07-29  Bruno Haible  <bruno@clisp.org>
6243
6244         * gnulib-tool (func_import): Don't create the $docbase directory if
6245         there is no file to store there.
6246
6247 2006-07-29  Bruno Haible  <bruno@clisp.org>
6248
6249         * gnulib-tool (autoconf_minversion): If a --dir option is given and
6250         relevant, look for configure.ac there, not in the current directory.
6251         Also use a simple search for AC_PREREQ, not "autoconf --trace".
6252
6253 2006-07-29  Bruno Haible  <bruno@clisp.org>
6254
6255         * gnulib-tool (SORT): New variable.
6256         (func_usage): Undocument --assume-autoconf option.
6257         Remove --assume-autoconf option handling.
6258         (autoconf_minversion): Determine from the contents of configure.ac.
6259         (func_import): Remove autoconf_minversion handling.
6260         Suggested by Eric Blake.
6261
6262 2006-07-29  Bruno Haible  <bruno@clisp.org>
6263
6264         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
6265
6266 2006-07-29  Bruno Haible  <bruno@clisp.org>
6267
6268         * config/srclist.txt (*setenv.[ch]): Remove rules.
6269
6270 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6271
6272         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
6273
6274 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6275
6276         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
6277         arpa/inet.h.
6278
6279 2006-07-28  Simon Josefsson  <jas@extundo.com>
6280
6281         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
6282         * modules/inet_pton (Depends-on): Likewise.
6283
6284 2006-07-28  Simon Josefsson  <jas@extundo.com>
6285
6286         * m4/netinet_in_h.m4: New file.
6287
6288 2006-07-28  Simon Josefsson  <jas@extundo.com>
6289
6290         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
6291         #include's.
6292
6293 2006-07-28  Simon Josefsson  <jas@extundo.com>
6294
6295         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
6296         #include's.
6297
6298 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
6299
6300         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
6301         setgid on directories only if they set these bits.
6302         * lib/modechange.h: Remove obsolete comment about masks.
6303
6304 2006-07-28  Eric Blake  <ebb9@byu.net>
6305
6306         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
6307         macro expansion.
6308
6309 2006-07-28  Bruno Haible  <bruno@clisp.org>
6310
6311         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
6312
6313 2006-07-28  Bruno Haible  <bruno@clisp.org>
6314
6315         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
6316
6317 2006-07-28  Bruno Haible  <bruno@clisp.org>
6318
6319         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
6320         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
6321         Define fallbacks.
6322         Avoids link error on FreeBSD 4.x.
6323         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
6324
6325         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
6326         encoding.
6327         * lib/mbswidth.c (iswcntrl): Likewise.
6328
6329 2006-07-27  Bruno Haible  <bruno@clisp.org>
6330
6331         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
6332         test.
6333
6334 2006-07-27  Bruno Haible  <bruno@clisp.org>
6335
6336         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
6337         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
6338         defined.
6339
6340 2006-07-26  Eric Blake  <ebb9@byu.net>
6341
6342         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
6343
6344 2006-07-26  Eric Blake  <ebb9@byu.net>
6345
6346         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
6347         like mingw that lack mkstemp.
6348         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
6349         avoid compilation warning on mingw.
6350
6351 2006-07-26  Bruno Haible  <bruno@clisp.org>
6352
6353         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
6354         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
6355         INT_FAST*_MIN, INTPTR_MIN.
6356
6357 2006-07-25  Bruno Haible  <bruno@clisp.org>
6358
6359         * modules/version-etc (Depends-on): Add stdarg.
6360
6361 2006-07-25  Bruno Haible  <bruno@clisp.org>
6362
6363         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
6364         complex commands.
6365
6366 2006-07-25  Bruno Haible  <bruno@clisp.org>
6367
6368         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
6369         defined in <stdarg.h> or config.h.
6370
6371 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
6372
6373         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
6374         (gl_STDIO_SAFER): Remove.
6375
6376 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
6377
6378         * MODULES.html.sh (File stream based Input/Output):
6379         Add fopen-safer, tmpfile-safer; remove stdio-safer.
6380         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
6381         * modules/fopen-safer, modules/tmpfile-safer: New files.
6382         * modules/stdio-safer: Remove.
6383
6384 2006-07-24  Bruno Haible  <bruno@clisp.org>
6385
6386         * modules/tmpdir: New file.
6387         * MODULES.html.sh (File system functions): Add it.
6388
6389 2006-07-24  Bruno Haible  <bruno@clisp.org>
6390
6391         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
6392         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
6393
6394 2006-07-24  Bruno Haible  <bruno@clisp.org>
6395
6396         * modules/clean-temp: New file.
6397
6398 2006-07-24  Bruno Haible  <bruno@clisp.org>
6399
6400         * m4/tmpdir.m4: New file, from GNU gettext.
6401
6402 2006-07-24  Bruno Haible  <bruno@clisp.org>
6403
6404         * lib/tmpdir.h: New file, from GNU gettext.
6405         * lib/tmpdir.c: New file, from GNU gettext.
6406
6407 2006-07-24  Bruno Haible  <bruno@clisp.org>
6408
6409         * lib/clean-temp.h: New file, from GNU gettext.
6410         * lib/clean-temp.c: New file, from GNU gettext.
6411
6412 2006-07-23  Eric Blake  <ebb9@byu.net>
6413
6414         * modules/stdio-safer (Files): Add tmpfile-safer.c.
6415         (Depends-on): Add binary-io.
6416
6417 2006-07-23  Eric Blake  <ebb9@byu.net>
6418
6419         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
6420
6421 2006-07-23  Eric Blake  <ebb9@byu.net>
6422
6423         * lib/tmpfile-safer.c: New file.
6424         * lib/stdio-safer.h (fopen_safer): Add prototype.
6425         * lib/stdio--.h (tmpfile): Make safer.
6426
6427 2006-07-23  Bruno Haible  <bruno@clisp.org>
6428
6429         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
6430         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
6431         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
6432         gl_linked_remove_at): Use it.
6433
6434 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6435         and Simon Josefsson <jas@extundo.com>
6436
6437         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
6438
6439         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
6440
6441 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6442
6443         * modules/close-stream: New file.
6444         * modules/closeout (Description): Make it clear that it exits
6445         with a diagnostic on error.
6446         (Depends-on): Add close-stream.  Remove fpending, stdbool.
6447         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
6448
6449 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6450
6451         * m4/close-stream.m4: New file.
6452
6453 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
6454
6455         * lib/close-stream.c, lib/close-stream.h: New files.
6456
6457 2006-07-22  Bruno Haible  <bruno@clisp.org>
6458
6459         Merge from GNU gettext 0.15.
6460
6461         2006-05-01  Bruno Haible  <bruno@clisp.org>
6462
6463                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
6464
6465         2006-07-22  Bruno Haible  <bruno@clisp.org>
6466
6467                 * modules/javaversion: New file.
6468                 * MODULES.html.sh (Java): Add javaversion.
6469
6470         2006-03-12  Bruno Haible  <bruno@clisp.org>
6471
6472                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
6473
6474         2005-12-04  Bruno Haible  <bruno@clisp.org>
6475
6476                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
6477                 (untested).
6478
6479         2006-06-21  Bruno Haible  <bruno@clisp.org>
6480
6481                 Avoid warnings from recent versions of mcs.
6482                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
6483                 -o, -L, -r any more. Use options documented since mcs-1.0
6484                 instead. Similarly for -g.
6485
6486         2005-12-04  Bruno Haible  <bruno@clisp.org>
6487
6488                 * build-aux/csharpcomp.sh.in: Suffix for resources is
6489                 .resources, not .resource.
6490
6491         2005-07-09  Bruno Haible  <bruno@clisp.org>
6492
6493                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
6494                 add a .dll suffix.
6495                 Reported by Mark Junker <mjscod@gmx.de>.
6496
6497         2006-07-22  Bruno Haible  <bruno@clisp.org>
6498
6499                 * modules/gettext: Upgrade to gettext-0.15.
6500                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
6501                 m4/visibility.m4.
6502                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
6503
6504 2006-07-22  Bruno Haible  <bruno@clisp.org>
6505
6506         Merge from GNU gettext 0.15.
6507
6508         2006-03-25  Bruno Haible  <bruno@clisp.org>
6509
6510                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
6511
6512         2006-07-21  Bruno Haible  <bruno@clisp.org>
6513
6514                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
6515                 "1.1".
6516
6517         2006-05-09  Bruno Haible  <bruno@clisp.org>
6518
6519                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
6520                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
6521                 for the conftestver execution.
6522
6523         2006-05-01  Bruno Haible  <bruno@clisp.org>
6524
6525                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
6526                 optional target-version argument. Verify that the compiler
6527                 groks source of the specified source-version, or add -source
6528                 option as necessary. Verify that the compiler produces
6529                 bytecode in the specified target-version, or add -target and
6530                 -source options as necessary. Make the result of the test
6531                 available as variable CONF_JAVAC. Also log error output in
6532                 config.log.
6533
6534         2006-03-11  Bruno Haible  <bruno@clisp.org>
6535
6536                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
6537
6538         2006-05-09  Bruno Haible  <bruno@clisp.org>
6539
6540                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
6541                 CLASSPATH_SEPARATOR to a semicolon.
6542
6543         2006-03-12  Bruno Haible  <bruno@clisp.org>
6544
6545                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
6546                 available as variable CONF_JAVA, for subsequent autoconf
6547                 tests. Also log error output in config.log.
6548
6549         2006-07-19  Bruno Haible  <bruno@clisp.org>
6550
6551                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
6552                 that getline works on glibc2 systems. Needed to avoid trouble
6553                 in relocatable.c.
6554                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
6555
6556         2005-12-04  Bruno Haible  <bruno@clisp.org>
6557
6558                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
6559                 launcher (untested).
6560
6561         2005-12-04  Bruno Haible  <bruno@clisp.org>
6562
6563                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
6564
6565         2006-07-22  Bruno Haible  <bruno@clisp.org>
6566
6567                 * gettext.m4: Update from GNU gettext-0.15.
6568                 * nls.m4: Likewise.
6569                 * po.m4: Likewise.
6570                 * inttypes-pri.m4: Likewise.
6571                 * inttypes-h.m4: Renamed from inttypes.m4.
6572                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
6573
6574 2006-07-22  Bruno Haible  <bruno@clisp.org>
6575
6576         Merge from GNU gettext 0.15.
6577
6578         2005-07-05  Bruno Haible  <bruno@clisp.org>
6579
6580                 * printf-args.c (printf_fetchargs): Work around broken
6581                 definition of wint_t on mingw.
6582
6583         2005-02-12  Bruno Haible  <bruno@clisp.org>
6584
6585                 * xallocsa.h: Add extern "C" for C++.
6586
6587         2006-05-17  Bruno Haible  <bruno@clisp.org>
6588
6589                 Cygwin portability.
6590                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
6591
6592         2006-04-30  Bruno Haible  <bruno@clisp.org>
6593
6594                 * progreloc.c: Include <mach-o/dyld.h> if available.
6595                 (find_executable): Use _NSGetExecutablePath when possible.
6596
6597         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6598
6599                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
6600                 function.
6601
6602         2005-12-29  Bruno Haible  <bruno@clisp.org>
6603
6604                 * progreloc.c (set_program_name_and_installdir): Fix
6605                 compilation error.
6606
6607         2005-12-04  Bruno Haible  <bruno@clisp.org>
6608
6609                 Cygwin portability.
6610                 * progreloc.c: Include <windows.h> also on Cygwin.
6611                 (find_executable): Add support for Cygwin.
6612                 (set_program_name_and_installdir): Handle also platforms with
6613                 nonempty EXEEXT.
6614
6615         2006-07-11  Bruno Haible  <bruno@clisp.org>
6616
6617                 * javacomp.c: Fix a comment.
6618                 Reported by Jim Meyering.
6619
6620         2006-04-30  Bruno Haible  <bruno@clisp.org>
6621
6622                 * javacomp.h (compile_java_class): Add source_version,
6623                 target_version arguments.
6624                 * javacomp.c: Rewritten to choose only a compiler that
6625                 respects the specified source_version and target_version.
6626
6627         2006-06-27  Bruno Haible  <bruno@clisp.org>
6628
6629                 Assume correct S_ISDIR macro.
6630                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
6631
6632         2006-07-22  Bruno Haible  <bruno@clisp.org>
6633
6634                 * javaversion.h: New file, from GNU gettext.
6635                 * javaversion.c: New file, from GNU gettext.
6636                 * javaversion.java: New file, from GNU gettext.
6637                 * javaversion.class: New file, from GNU gettext.
6638
6639         2006-05-17  Bruno Haible  <bruno@clisp.org>
6640
6641                 Cygwin portability.
6642                 * javaexec.c (execute_java_class): Test for jview program
6643                 also on Cygwin.
6644
6645         2006-04-09  Bruno Haible  <bruno@clisp.org>
6646
6647                 * fatal-signal.c: Don't include string.h.
6648                 (at_fatal_signal): Use a copying loop instead of memcpy.
6649
6650         2005-12-04  Bruno Haible  <bruno@clisp.org>
6651
6652                 * csharpexec.c: Add support for 'clix' launcher (untested).
6653                 (execute_csharp_using_sscli): New function.
6654                 (execute_csharp_program): Call it.
6655
6656         2006-06-21  Bruno Haible  <bruno@clisp.org>
6657
6658                 Avoid warnings from recent versions of mcs.
6659                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
6660                 -o, -L, -r any more. Use options documented since mcs-1.0
6661                 instead. Similarly for -g.
6662
6663         2005-07-09  Bruno Haible  <bruno@clisp.org>
6664
6665                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
6666                 add a .dll suffix.
6667                 Reported by Mark Junker <mjscod@gmx.de>.
6668
6669         2006-06-17  Bruno Haible  <bruno@clisp.org>
6670
6671                 * config.charset: Update for NetBSD 3.0.
6672
6673         2006-05-17  Bruno Haible  <bruno@clisp.org>
6674
6675                 Cygwin portability.
6676                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
6677
6678         2006-05-16  Bruno Haible  <bruno@clisp.org>
6679
6680                 * localcharset.c [CYGWIN]: Include <windows.h>.
6681                 (get_charset_aliases): For Cygwin, return the same CPxxx
6682                 aliases list as under WIN32.
6683                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
6684                 the environment variables. Fall back to GetACP().
6685
6686         2006-04-05  Bruno Haible  <bruno@clisp.org>
6687
6688                 * config.charset: Update Juan Manuel Guerrero's address.
6689
6690         2005-02-12  Bruno Haible  <bruno@clisp.org>
6691
6692                 * allocsa.h: Add extern "C" for C++.
6693
6694         2005-02-10  Bruno Haible  <bruno@clisp.org>
6695
6696                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
6697                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
6698
6699         2006-07-22  Bruno Haible  <bruno@clisp.org>
6700
6701                 * gettext.h: Update to GNU gettext-0.15.
6702
6703 2006-07-22  Bruno Haible  <bruno@clisp.org>
6704
6705         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
6706         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
6707         lib-prefix.m4, longdouble.m4, ssize_t.m4.
6708
6709 2006-07-21  Eric Blake  <ebb9@byu.net>
6710
6711         * modules/stdlib-safer: New file.
6712         * MODULES.html.sh (File stream based Input/Output): Add
6713         stdlib-safer.
6714
6715 2006-07-21  Eric Blake  <ebb9@byu.net>
6716
6717         * lib/stdlib-safer.h: New file from coreutils, required by
6718         stdlib--.h.
6719
6720 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
6721
6722         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
6723
6724 2006-07-20  Bruno Haible  <bruno@clisp.org>
6725
6726         * gnulib-tool: Recognize new option --assume-autoconf.
6727         (autoconf_minversion): New variable.
6728         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
6729
6730 2006-07-20  Bruno Haible  <bruno@clisp.org>
6731
6732         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
6733
6734 2006-07-19  Derek R. Price  <derek@ximbiot.com>
6735
6736         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
6737         Reindent and repaginate.
6738
6739 2006-07-19  Derek Price  <derek@ximbiot.com>
6740
6741         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
6742         Correct grammar.
6743
6744 2006-07-17  Bruno Haible  <bruno@clisp.org>
6745
6746         * modules/list: New file.
6747         * modules/array-list: New file.
6748         * modules/carray-list, modules/carray-list-tests: New files.
6749         * modules/linked-list, modules/linked-list-tests: New files.
6750         * modules/avltree-list, modules/avltree-list-tests: New files.
6751         * modules/rbtree-list, modules/rbtree-list-tests: New files.
6752         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
6753         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
6754         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
6755         * modules/oset: New file.
6756         * modules/array-oset: New file.
6757         * modules/avltree-oset, modules/avltree-oset-tests: New files.
6758         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
6759         * tests/test-carray_list.c: New file.
6760         * tests/test-linked_list.c: New file.
6761         * tests/test-avltree_list.c: New file.
6762         * tests/test-rbtree_list.c: New file.
6763         * tests/test-linkedhash_list.c: New file.
6764         * tests/test-avltreehash_list.c: New file.
6765         * tests/test-rbtreehash_list.c: New file.
6766         * tests/test-avltree_oset.c: New file.
6767         * tests/test-rbtree_oset.c: New file.
6768         * MODULES.html.sh (Container data structures): New section.
6769
6770 2006-07-17  Bruno Haible  <bruno@clisp.org>
6771
6772         * m4/gl_list.m4: New file.
6773
6774 2006-07-17  Bruno Haible  <bruno@clisp.org>
6775
6776         * lib/gl_list.h: New file.
6777         * lib/gl_list.c: New file.
6778         * lib/gl_array_list.h: New file.
6779         * lib/gl_array_list.c: New file.
6780         * lib/gl_carray_list.h: New file.
6781         * lib/gl_carray_list.c: New file.
6782         * lib/gl_linked_list.h: New file.
6783         * lib/gl_linked_list.c: New file.
6784         * lib/gl_anylinked_list1.h: New file.
6785         * lib/gl_anylinked_list2.h: New file.
6786         * lib/gl_avltree_list.h: New file.
6787         * lib/gl_avltree_list.c: New file.
6788         * lib/gl_anyavltree_list1.h: New file.
6789         * lib/gl_anyavltree_list2.h: New file.
6790         * lib/gl_rbtree_list.h: New file.
6791         * lib/gl_rbtree_list.c: New file.
6792         * lib/gl_anyrbtree_list1.h: New file.
6793         * lib/gl_anyrbtree_list2.h: New file.
6794         * lib/gl_anytree_list1.h: New file.
6795         * lib/gl_anytree_list2.h: New file.
6796         * lib/gl_linkedhash_list.h: New file.
6797         * lib/gl_linkedhash_list.c: New file.
6798         * lib/gl_anyhash_list1.h: New file.
6799         * lib/gl_anyhash_list2.h: New file.
6800         * lib/gl_avltreehash_list.h: New file.
6801         * lib/gl_avltreehash_list.c: New file.
6802         * lib/gl_rbtreehash_list.h: New file.
6803         * lib/gl_rbtreehash_list.c: New file.
6804         * lib/gl_anytreehash_list1.h: New file.
6805         * lib/gl_anytreehash_list2.h: New file.
6806
6807         * lib/gl_oset.h: New file.
6808         * lib/gl_oset.c: New file.
6809         * lib/gl_array_oset.h: New file.
6810         * lib/gl_array_oset.c: New file.
6811         * lib/gl_avltree_oset.h: New file.
6812         * lib/gl_avltree_oset.c: New file.
6813         * lib/gl_rbtree_oset.h: New file.
6814         * lib/gl_rbtree_oset.c: New file.
6815         * lib/gl_anytree_oset.h: New file.
6816
6817 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6818
6819         * m4/mkancesdirs.m4: New file.
6820         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
6821         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
6822         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
6823         it.
6824
6825 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6826
6827         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
6828         * lib/mkancesdirs.h: New files.
6829         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
6830         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
6831         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
6832         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
6833         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
6834         callers changed.  Revamp internals significantly, by not
6835         attempting to create directories that are temporarily more
6836         permissive than the final results.  Do not attempt to use
6837         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
6838         This removes some race conditions, fixes some bugs, and simplifies
6839         things.  Use new dirchownmod function to do owner and mode changes.
6840         * lib/mkdir-p.h: Likewise.
6841         * lib/modechange.c (octal_to_mode): New function.
6842         (struct mode_change): New member mentioned.
6843         (make_node_op_equals): New arg mentioned.  All callers changed.
6844         (mode_compile): Keep track of which mode bits the user has explicitly
6845         mentioned.
6846         (mode_adjust): New arg DIR, so that we implement the X op correctly.
6847         New arg PMODE_BITS, to keep track of which mode bits the user
6848         mentioned; it treats S_ISUID and S_ISGID speciall.
6849         All callers changed.
6850         * lib/modechange.h: Likewise.
6851
6852 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6853
6854         * MODULES.html.sh: Add mkancestors.
6855         * modules/mkancesdirs: New module.
6856         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
6857         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
6858         The chdir-safer and afs files are now orphans; I'll remove them
6859         unless someone speaks up.
6860         Add lib/dirchownmod.c, lib/dirchownmod.h.
6861         (Depends-on): Remove alloca, chown, save-cwd, dirname.
6862         Add lchown, mkancesdirs.
6863         (Maintainer): Add self.
6864
6865 2006-07-15  Karl Berry  <karl@gnu.org>
6866
6867         * gnulib-tool: help message wording/arrangement.
6868
6869 2006-07-14  Simon Josefsson  <jas@extundo.com>
6870
6871         * doc/gnulib.texi (Libtool and Windows): New section.
6872
6873 2006-07-12  Simon Josefsson  <jas@extundo.com>
6874
6875         * modules/gendocs (License): Fix license, approved by Karl.
6876
6877 2006-07-12  Eric Blake  <ebb9@byu.net>
6878
6879         * MODULES.html.sh: Add gendocs.
6880
6881 2006-07-11  Eric Blake  <ebb9@byu.net>
6882
6883         * modules/fdl: New module, to install doc/fdl.texi.
6884         * MODULES.html.sh: Add new section for documentation modules.
6885         * gnulib-tool: Avoid space-tab.
6886         (--doc-base): New option, to manage files from doc.
6887
6888 2006-07-11  Eric Blake  <ebb9@byu.net>
6889
6890         * m4/absolute-header.m4: Fix comments to match recent change.
6891
6892 2006-07-11  Eric Blake  <ebb9@byu.net>
6893
6894         * gnulib-tool: List --doc-base before --tests-base.
6895
6896 2006-07-11  Derek R. Price  <derek@ximbiot.com>
6897
6898         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
6899
6900 2006-07-11  Bruno Haible  <bruno@clisp.org>
6901
6902         * README: Mention where to put documentation.
6903
6904 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6905
6906         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
6907
6908 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
6909
6910         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
6911         to stdint.m4.
6912
6913 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
6914
6915         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
6916         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
6917         "no/such/file/stdint.h" when there is no such file, so that
6918         the resulting C code can be parsed by dodgy compilers.
6919         Problems reported by Bob Proulx.
6920
6921 2006-07-10  Derek R. Price  <derek@ximbiot.com>
6922
6923         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
6924         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
6925         macros into the GNU _D_EXACT_NAMLEN.
6926         * lib/savedir.c:  Likewise.
6927         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
6928
6929 2006-07-10  Derek R. Price  <derek@ximbiot.com>
6930         and Paul Eggert  <eggert@cs.ucla.edu>
6931
6932         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
6933         * m4/savedir.m4:
6934         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
6935         macros into the GNU _D_EXACT_NAMLEN.
6936
6937 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6938
6939         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
6940         around the absolute name, to work around a problem with the HP-UX
6941         11.23 native C compiler, reported by Bob Proulx.
6942
6943 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6944
6945         * doc/maintain.texi, make-stds.texi: Sync from
6946         <http://savannah.gnu.org/projects/gnustandards>.
6947
6948 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6949
6950         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
6951
6952 2006-07-09  Jim Meyering  <jim@meyering.net>
6953
6954         * m4/glob.m4: Remove a doubled word in a comment.
6955
6956 2006-07-09  Jim Meyering  <jim@meyering.net>
6957
6958         * lib/argp-pv.c: Remove a doubled word in a comment.
6959         * lib/check-version.c (check_version): Likewise.
6960         * lib/javacomp.c (compile_java_class): Likewise.
6961
6962 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
6963
6964         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
6965         for the benefit of people using Autoconf 2.60.  If you want to
6966         support older Autoconf versions you can copy m4/onceonly_2_57.m4
6967         (or m4/onceonly.m4, if pre-2.57) manually.
6968
6969 2006-07-08  Jim Meyering  <jim@meyering.net>
6970
6971         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
6972         comment.
6973         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
6974         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
6975         comment.
6976
6977 2006-07-08  Jim Meyering  <jim@meyering.net>
6978
6979         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
6980
6981 2006-07-07  Simon Josefsson  <jas@extundo.com>
6982
6983         * tests/test-crc.c: Change expected crc value, the test vector
6984         were probably computed using the old broken crc.c?
6985
6986 2006-07-06  Simon Josefsson  <jas@extundo.com>
6987
6988         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
6989         now the canonical place for the M4 file).
6990
6991         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
6992         from the sys_socket dependency now.
6993
6994         * modules/inet_pton (Files): Ditto.
6995
6996         * modules/inet_ntop (Files): Ditto.
6997
6998 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
6999
7000         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
7001         not gl_PREREQ_GETUSERSHELL.
7002
7003 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7004
7005         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
7006         with only one argument, for Autoconf 2.60.
7007         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
7008         expand to nothing, so add a shell command to avoid syntax error.
7009         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7010
7011 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7012
7013         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
7014
7015 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7016
7017         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
7018         no longer needed.  Check for isblank decl.
7019         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
7020         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
7021         of existence.
7022
7023 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7024
7025         * lib/getloadavg.c: Use __VMS, not VMS.
7026         * lib/getopt.c: Likewise.
7027         * lib/getpagesize.h: Likewise.
7028         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
7029         and probably does not work.
7030
7031 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
7032
7033         * lib/.cppi-disable: Add wcwidth.
7034         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
7035         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
7036         (ISGRAPH): Remove.  All uses changed to isgraph.
7037         (FOLD) [!defined _LIBC]: Remove special case.
7038         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
7039         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
7040         HAVE_ISBLANK.
7041         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
7042         case.
7043
7044 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
7045
7046         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
7047         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
7048         brackets.  Other minor changes to suppress some compiler
7049         warnings.
7050
7051 2006-07-06  Derek R. Price  <derek@ximbiot.com>
7052         and Paul Eggert  <eggert@cs.ucla.edu>
7053
7054         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
7055         of invoking obsolescent AC_HEADER_DIRENT macro.
7056         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
7057         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
7058         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
7059         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
7060         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
7061         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
7062         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
7063         * m4/readdir.m4: Remove; no longer needed.
7064
7065 2006-07-06  Derek R. Price  <derek@ximbiot.com>
7066         and Paul Eggert  <eggert@cs.ucla.edu>
7067
7068         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
7069         Don't worry about this obsolete case any more.
7070         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
7071         directories.
7072         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
7073         worry about this obsolete case any more.
7074         * lib/fts.c: Likewise.
7075         * lib/getcwd.c: Likewise.
7076         * lib/glob.h: Likewise.
7077         * lib/savedir.c: Likewise.
7078
7079 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
7080
7081         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
7082         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
7083         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
7084         needed.
7085         All uses removed.
7086         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7087         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
7088         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
7089         needed.
7090         * m4/getdate.m4 (gl_GETDATE): Likewise.
7091         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
7092         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
7093         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
7094         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7095         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
7096         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
7097         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
7098         needed.
7099
7100 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
7101
7102         * lib/memcasecmp.c: Include <limits.h>.
7103         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
7104         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
7105         Don't assume isdigit succeeds only on '0' through '9'.
7106
7107 2006-07-05  Eric Blake  <ebb9@byu.net>
7108
7109         * modules/getaddrinfo (Depends-on): Add snprintf.
7110
7111 2006-07-05  Eric Blake  <ebb9@byu.net>
7112
7113         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
7114         to avoid 'header present but could not be compiled' on cygwin.
7115
7116 2006-07-05  Eric Blake  <ebb9@byu.net>
7117
7118         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
7119         missing from netdb.h.
7120         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
7121
7122 2006-07-05  Derek R. Price  <derek@ximbiot.com>
7123
7124         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
7125         no longer needed.
7126         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
7127         * m4/getdate.m4 (gl_GETDATE): Likewise.
7128         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
7129         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
7130         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
7131         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
7132         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
7133
7134 2006-07-05  Derek R. Price  <derek@ximbiot.com>
7135
7136         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
7137         All uses of is_space replaced by isspace.
7138         * lib/exit.h: Don't talk about STDC_HEADERS.
7139         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
7140         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
7141         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
7142         replaced by isprint etc.
7143         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
7144         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
7145         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
7146         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
7147         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
7148         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
7149
7150 2006-07-05  Bruno Haible  <bruno@clisp.org>
7151
7152         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
7153         the function exists, before testing against AIX.
7154         Reported by Martin Lambers <marlam@marlam.de>.
7155
7156 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
7157
7158         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
7159         From Mark D. Baushke.
7160
7161 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
7162
7163         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
7164         to the absolute name, not just one, to bypass Sun C 5.8's
7165         "warning: #include of /usr/include/... may be non-portable".
7166
7167 2006-07-04  Eric Blake  <ebb9@byu.net>
7168
7169         * modules/dirname-tests: New test module.
7170         * tests/test-dirname.c: New file, replacing dirname.c
7171         TEST_DIRNAME section that was recently deleted.
7172
7173 2006-07-04  Bruno Haible  <bruno@clisp.org>
7174
7175         Assume ANSI C header files and <ctype.h> functions.
7176         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
7177         (mbsnwidth): Use isprint, iscntrl instead.
7178
7179 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7180
7181         Merge from coreutils.
7182         * MODULES.html.sh: Add xstrtold.
7183         * modules/xstrtold: New file.
7184         * modules/cycle-check (Files): Add lib/same-inode.h.
7185         * modules/dirname (Files): Add m4/double-slash-root.m4.
7186         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
7187         * modules/mkdir-p (Files): Add lib/same-inode.h.
7188         * modules/same (Files): Add lib/same-inode.h.
7189
7190 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7191
7192         * m4/absolute-header.m4: Renamed from full-header-path.m4.
7193         This is to keep the terminology clean; POSIX talks about
7194         "absolute pathnames", not "full pathnames", but the GNU
7195         Coding Standards say to use "path" for something else;
7196         so use "absolute" to keep both sides happy.
7197         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
7198         Set gl_absolute_header, not gl_full_header_path.
7199         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
7200         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
7201         All uses changed.
7202
7203         Merge from coreutils.
7204
7205         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
7206
7207         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
7208         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
7209         want to require the building of c-strtod.o.
7210         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
7211         needs -lm directly.
7212         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
7213
7214         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
7215
7216         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
7217         --as-needed option if available.  Problem reported by Albert Chin in
7218         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
7219         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
7220         cc merely issues a bunch of annoying warnings for --as-needed
7221         (this problem was reported by Bob Proulx).  Also, try linking with
7222         -lm to detect a bug in binutils 2.16 (this problem was reported
7223         by Ralf Wildenhues).
7224
7225         2006-06-18  Jim Meyering  <jim@meyering.net>
7226
7227         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
7228         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
7229         macro.
7230         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
7231         also check for glibc-2.4's abort-inducing bug.
7232
7233         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
7234         Low-probability clean-up should be to use rmdir to get rid of
7235         the just-created directory, not unlink.
7236
7237         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
7238         configure fail, and request a bug report to inform us about it.
7239         Add a comment that, barring reports to the contrary, in 2007 we'll
7240         assume ftruncate is universally available.
7241
7242         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
7243
7244         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
7245
7246         2006-03-12  Jim Meyering  <jim@meyering.net>
7247
7248         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
7249         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
7250         * m4/same.m4 (gl_SAME): Likewise.
7251         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
7252
7253         2006-03-11  Eric Blake  <ebb9@byu.net>
7254
7255         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
7256         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
7257         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
7258         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
7259
7260 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
7261
7262         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
7263         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
7264         reported by Mark D. Baushke, one in
7265         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
7266
7267         Merge from coreutils.
7268
7269         * lib/.cppi-disable: Add stdint_.h.
7270         * lib/.cvsignore: Add stdint.h.
7271
7272         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
7273
7274         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
7275         both double and long double versions.
7276         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
7277         * lib/xstrtold.c: New file.
7278         * lib/xstrtod.h (xstrtold): New decl.
7279
7280         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
7281
7282         * lib/filemode.c (setst): Remove.
7283         (strmode): Rewrite to avoid setst.  This makes the code shorter,
7284         (arguably) clearer, and the generated code is a bit smaller on my
7285         Debian GNU/Linux stable x86 host.
7286
7287         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
7288
7289         * lib/filemode.c: Include "filemode.h" first, to test the interface.
7290         Assume that filemode.h includes sys/types.h and sys/stat.h.
7291         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
7292         (ftypelet): Reorder to put common cases first, for efficiency.
7293         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
7294         to do 'M'.
7295         (strmode): Renamed from mode_string, and now stores 12 bytes instead
7296         of 10, for compatibility with FreeBSD.  All callers changed.
7297         (filemodestring): Now stores 12 bytes instead of 10, and sets file
7298         types that can't be deduced solely from st_mode.  First arg is now a
7299         const pointer.
7300         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
7301         (strmode): Renamed from mode_string.
7302         (filemodestring): New decl.
7303         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
7304         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
7305         needed.
7306         (S_ISPORT, S_ISWHT): New macros, if not already defined.
7307
7308         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
7309
7310         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
7311         fsusage.h now does that.  Include fsusage.h first, to test interface.
7312         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
7313         at most one method (the old code could have generated decls that
7314         didn't conform to C89, not that this was ever exercised).
7315         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
7316
7317         2006-03-19  Jim Meyering  <jim@meyering.net>
7318
7319         Work even in a chroot where d_ino values for entries in "/"
7320         don't match the stat.st_ino values for the same names.
7321         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
7322         number, iterate through all entries again, using lstat instead.
7323         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
7324         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
7325
7326         * lib/getcwd.c (__getcwd): Clarify a comment.
7327         Use memcpy in place of a call to strcpy.
7328
7329         2006-03-12  Jim Meyering  <jim@meyering.net>
7330
7331         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
7332         matches that of the current directory (which we're about to chdir ".."
7333         out of), then save the dev-ino of the parent, instead.
7334
7335         * lib/same-inode.h (SAME_INODE): New file/macro.
7336         * lib/chdir-safer.c (SAME_INODE): Remove definition.
7337         Include "same-inode.h", instead.
7338         * lib/same.c: Likewise.
7339         * lib/cycle-check.h: Include "same-inode.h".
7340         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
7341         * lib/cycle-check.c (SAME_INODE): Remove definition.
7342         * lib/root-dev-ino.h: Include "same-inode.h".
7343
7344         2006-03-11  Eric Blake  <ebb9@byu.net>
7345
7346         * lib/same.c (same_name): s/base_name/last_component/
7347         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
7348         * lib/filenamecat.c (file_name_concat): Likewise.
7349
7350         2006-03-11  Eric Blake  <ebb9@byu.net>,
7351                     Paul Eggert  <eggert@cs.ucla.edu>
7352
7353         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
7354         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
7355         drive prefix.
7356         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
7357         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
7358         (last_component): New method.
7359         * lib/dirname.c (dir_len): Determine when drive letters need a
7360         subsequent slash.  Preserve // when it is special.
7361         (dir_name): Don't append dot when drive letter is absolute.
7362         [TEST_DIRNAME]: Move into a full-blown gnulib test.
7363         * lib/basename.c (base_name): New semantics - malloc the result.
7364         Preserve // when it is special.  Preserve relative files that look
7365         like drive letters.
7366         (base_len): Preserve // when it is special.
7367         (last_component): New method, similar to old base_name semantics.
7368         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
7369         base_name.  Strip redundant slashes from ///.
7370
7371 2006-07-03  Jim Meyering  <jim@meyering.net>
7372
7373         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
7374         macro is used before the first cycle_check call.
7375
7376 2006-07-03  Eric Blake  <ebb9@byu.net>
7377
7378         * modules/dirname (Depends-on): Add xstrndup.
7379
7380 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
7381
7382         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
7383         test cases, so that config.log is a bit easier to follow.
7384
7385 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
7386
7387         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
7388         both are 64 bits, since this seems to be the tradition, and this
7389         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
7390         we ever run into a host that prefers long long to long in this
7391         case, we'll need another configure-time test.  Problem reported by
7392         Jim Meyering.
7393
7394 2006-07-02  Eric Blake  <ebb9@byu.net>
7395
7396         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
7397
7398 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7399
7400         * modules/inttypes (Depends-on): No longer depends on stdint.
7401         * modules/stdint (Description): Say more about assumptions.
7402         Say that the fast types might differ.  Say macros are used.
7403         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
7404         (Makefile.am): Revise list of substituted symbols to match
7405         new stdint.m4.
7406         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
7407         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
7408         * tests/test-stdint.c (verify_same_types)
7409         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
7410         the code conforms to C99/C89.
7411         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
7412         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
7413
7414 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7415
7416         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
7417         but fix a bug, by requiring at least 64 bits.
7418         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
7419         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
7420         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
7421         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
7422
7423         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
7424         changes.  Make 2.59 a prerequisite.  Check and substitute for
7425         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
7426         inttypes.h.  Do not use special include files; just use the
7427         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
7428         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
7429         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
7430         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
7431         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
7432         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
7433         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
7434         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
7435         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
7436         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
7437         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
7438         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
7439         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
7440         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
7441         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
7442         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
7443         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
7444         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
7445         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
7446         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
7447         WINT_MAX.  Check for C99 conformance more strictly, by detecting
7448         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
7449         not check for things that C99 does not require, e.g., int8_t.  If
7450         a test isn't needed unless <stdint.h> isn't working, and is
7451         unlikely to be needed for any other reason, then don't do it
7452         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
7453         size_t, since we assume C89 freestanding at least.  Do not check
7454         for sig_atomic_t, wchar_t, or wint_t, since the code now does
7455         the right thing even if the types are not defined.  Instead use:
7456         (gl_STDINT_TYPE_PROPERTIES): New macro.
7457         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
7458         testing whether <sys/types.h> clashes, as Autoconf does this for
7459         us now.  All uses removed.
7460         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
7461         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
7462         (gl_CHECK_TYPE_SAME):
7463         Remove; no longer needed.
7464         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
7465         exists, since we'll return 0 anyway in that case.
7466         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
7467
7468 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
7469
7470         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
7471         possible collision with system files.
7472         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
7473         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
7474         WCHAR_MIN and WCHAR_MAX in this case.
7475         (<stddef.h>): Do not include; no longer needed.
7476         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
7477         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
7478         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
7479         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
7480         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
7481         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
7482         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
7483         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
7484         !defined(__c99))]: Include in this case too, since it's harmless
7485         now.
7486         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
7487         dangerous to do so.
7488         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
7489         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
7490         (_STDINT_MIN, _STDINT_MAX): New macros.
7491         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
7492         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
7493         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
7494         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
7495         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
7496         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
7497         macros, not typedefs; this simplifies things quite a bit.
7498         Use long int for all types narrower than int64_t.
7499         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
7500         Define in terms of long long int or int64_t or long int,
7501         not int64_t or int32_t.  This saves some compile-time testing.
7502         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
7503         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
7504         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
7505         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
7506         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
7507         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
7508         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
7509         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
7510         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
7511         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
7512         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
7513         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
7514         undef any previous version and define our own version, for
7515         simplicity and consistency with the new macros for types.
7516         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
7517         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
7518         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
7519         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
7520         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
7521         @WINT_T_SUFFIX@ to keep things simple here.
7522         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
7523         Simplify by assuming typical 8/16/32/64 host, since we're
7524         already doing that elsewhere anyway.
7525         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
7526         and assume long long int is 64 bits if available.  This
7527         speeds up 'configure'.
7528
7529 2006-07-01  Eric Blake  <ebb9@byu.net>
7530
7531         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
7532         Reported by Andreas Buening.
7533
7534 2006-07-01  Eric Blake  <ebb9@byu.net>
7535
7536         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
7537
7538 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
7539
7540         * lib/getaddrinfo.c: fixed typo
7541
7542 2006-06-29  Jim Meyering  <jim@meyering.net>
7543
7544         * modules/strftime (Maintainer): Add my name, since with the
7545         FPRINTFTIME changes strftime.c has forked from glibc.
7546
7547 2006-06-29  Eric Blake  <ebb9@byu.net>
7548
7549         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
7550
7551 2006-06-29  Eric Blake  <ebb9@byu.net>
7552
7553         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
7554
7555 2006-06-29  Eric Blake  <ebb9@byu.net>
7556
7557         * lib/stat_.h: New file.
7558
7559 2006-06-29  Eric Blake  <ebb9@byu.net>
7560
7561         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
7562         unused static function.
7563
7564 2006-06-29  Eric Blake  <ebb9@byu.net>
7565
7566         * doc/functions.texi (Function Portability): Document missing lstat
7567         on mingw.
7568
7569 2006-06-29  Eric Blake  <ebb9@byu.net>
7570
7571         * MODULES.html.sh: Add sys_stat.
7572         * modules/sys_stat: New module.
7573         * modules/mkstemp (Depends-on): Add sys_stat.
7574
7575 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7576
7577         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
7578
7579 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7580
7581         * m4/c-bs-a.m4: Removed.
7582
7583 2006-06-29  Derek R. Price  <derek@ximbiot.com>
7584
7585         * lib/strftime.c: Assume strftime() exists.
7586
7587 2006-06-29  Derek Price  <derek@ximbiot.com>
7588
7589         * modules/c-bs-a: Removed - \a is C89.
7590         * MODULES.html.sh: Remove c-bs-a.
7591
7592 2006-06-29  Bruno Haible  <bruno@clisp.org>
7593
7594         * modules/wcwidth (License): Change to LGPL.
7595
7596 2006-06-28  Simon Josefsson  <jas@extundo.com>
7597
7598         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
7599         on _WIN32.
7600
7601         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
7602         getnameinfo.
7603
7604 2006-06-28  Simon Josefsson  <jas@extundo.com>
7605
7606         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
7607
7608 2006-06-28  Simon Josefsson  <jas@extundo.com>
7609
7610         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
7611         functions there.  It will succeed on Windows XP, but on Windows
7612         2000 and (presumably) earlier, it will fail, and use the internal
7613         re-implementation.
7614         (use_win32_p): New function.
7615         (getaddrinfo): Use strtoul on servname, to support numeric ports.
7616         Support AI_NUMERICSERV to disable getservbyname.
7617         (getnameinfo): New function, only supports
7618         NI_NUMERICHOST|NI_NUMERICSERV for now.
7619
7620         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
7621         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
7622         getnameinfo.
7623
7624 2006-06-28  Eric Blake  <ebb9@byu.net>
7625
7626         * modules/wcwidth: New file.
7627         * modules/mbchar (Depends-on): Add wcwidth.
7628         * modules/mbswidth (Depends-on): Add wcwidth.
7629         * MODULES.html.sh: Add wcwidth.
7630
7631 2006-06-28  Eric Blake  <ebb9@byu.net>
7632
7633         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
7634         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
7635
7636 2006-06-28  Eric Blake  <ebb9@byu.net>
7637
7638         * lib/xvasprintf.h: Fix comments.
7639
7640 2006-06-28  Eric Blake  <ebb9@byu.net>
7641
7642         * lib/mbchar.h (wcwidth): Include wcwidth.h.
7643         * lib/mbswidth.c (wcwidth): Move from here...
7644         * lib/wcwidth.h: ...to this new file.
7645
7646 2006-06-28  Derek R. Price  <derek@ximbiot.com>
7647
7648         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
7649
7650         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
7651         it's obsolete.
7652         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
7653
7654 2006-06-28  Derek R. Price  <derek@ximbiot.com>
7655
7656         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
7657         Autoconf 2.60 says this stuff was obsolete.
7658
7659 2006-06-28  Bruno Haible  <bruno@clisp.org>
7660
7661         * modules/wcwidth (Files): Add m4/wchar_t.m4.
7662
7663 2006-06-28  Bruno Haible  <bruno@clisp.org>
7664
7665         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
7666         gt_TYPE_WCHAR_T.
7667
7668 2006-06-28  Bruno Haible  <bruno@clisp.org>
7669
7670         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
7671         declaration for wcwidth.
7672         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
7673
7674 2006-06-28  Bruno Haible  <bruno@clisp.org>
7675
7676         * lib/mkdtemp.c [MINGW]: Include <io.h>.
7677         (mkdir): Define using _mkdir.
7678
7679 2006-06-28  Bruno Haible  <bruno@clisp.org>
7680
7681         * lib/getaddrinfo.h: Fix POSIX URL.
7682         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
7683         _WIN32.
7684         (use_win32_p): Make static.
7685         (getaddrinfo): Reject service name if it is empty or does not consist
7686         solely of decimal digits, or if its value is > 65535.
7687         (getnameinfo): Remove useless casts.
7688
7689 2006-06-27  Simon Josefsson  <jas@extundo.com>
7690
7691         * modules/sys_select: New file, suggested by Bruno Haible, Paul
7692         Eggert and Martin Lambers.
7693
7694 2006-06-27  Simon Josefsson  <jas@extundo.com>
7695
7696         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
7697         Eggert and Martin Lambers.
7698
7699 2006-06-27  Bruno Haible  <bruno@clisp.org>
7700
7701         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
7702         result to 0, not to empty.
7703         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
7704
7705 2006-06-27  Bruno Haible  <bruno@clisp.org>
7706
7707         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
7708
7709 2006-06-26  Simon Josefsson  <jas@extundo.com>
7710
7711         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
7712         present.
7713
7714 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
7715
7716         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
7717         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
7718         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
7719
7720 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
7721
7722         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
7723
7724 2006-06-26  Bruno Haible  <bruno@clisp.org>
7725
7726         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
7727
7728 2006-06-26  Bruno Haible  <bruno@clisp.org>
7729
7730         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
7731
7732 2006-06-26  Bruno Haible  <bruno@clisp.org>
7733
7734         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
7735         SGI C compiler in pre-C99 mode.
7736         Suggested by Mark D. Baushke and Larry Jones.
7737
7738 2006-06-26  Bruno Haible  <bruno@clisp.org>
7739
7740         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
7741         WCHAR_MAX.
7742         Reported by Mark D. Baushke and Larry Jones.
7743
7744 2006-06-26  Bruno Haible  <bruno@clisp.org>
7745
7746         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
7747         in pre-C99 mode.
7748         Suggested by Mark D. Baushke and Larry Jones.
7749
7750 2006-06-23  Simon Josefsson  <jas@extundo.com>
7751             Bruno Haible  <bruno@clisp.org>
7752
7753         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
7754         Emit mostlyclean-local rule.
7755         (func_emit_tests_Makefile_am): Likewise.
7756         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
7757
7758 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
7759
7760         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
7761
7762 2006-06-23  Bruno Haible  <bruno@clisp.org>
7763
7764         * tests/test-stdint.c: Update to match ISO C 99 Technical
7765         Corrigendum 1.
7766
7767 2006-06-23  Bruno Haible  <bruno@clisp.org>
7768
7769         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
7770
7771 2006-06-23  Bruno Haible  <bruno@clisp.org>
7772
7773         * lib/stdint_.h: Treat IRIX like OpenBSD.
7774
7775 2006-06-23  Bruno Haible  <bruno@clisp.org>
7776
7777         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
7778         ISO C 99 Technical Corrigendum 1.
7779
7780 2006-06-22  Simon Josefsson  <jas@extundo.com>
7781
7782         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
7783         MinGW.
7784
7785 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
7786
7787         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
7788         needed.  Some compiler complained about some of them.  Problem reported
7789         by Larry Jones in
7790         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
7791
7792 2006-06-21  Simon Josefsson  <jas@extundo.com>
7793
7794         * tests/test-getaddrinfo.c: New file.
7795
7796         * modules/getaddrinfo-tests: New file.
7797
7798         * MODULES.html.sh: Add inet_pton.
7799
7800         * modules/inet_pton: New file.
7801
7802 2006-06-21  Simon Josefsson  <jas@extundo.com>
7803
7804         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
7805         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
7806         of using the (limited) gnulib implementation on Windows XP.
7807
7808         * m4/inet_pton.m4: New file.
7809
7810 2006-06-21  Simon Josefsson  <jas@extundo.com>
7811
7812         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
7813         variable.
7814
7815         * lib/socket_.h: Don't define WINVER.
7816
7817         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
7818         slightly modified to work in gnulib.
7819
7820 2006-06-21  Simon Josefsson  <jas@extundo.com>
7821
7822         * doc/gnulib.texi (Windows sockets): Add.
7823
7824 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
7825
7826         * lib/read-file.c (fread_file): Start with buffer allocation of
7827         0 bytes rather than 1 byte; this simplifies the code.
7828         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
7829         code to free buffer and save/restore errno.
7830         (internal_read_file): Remove unused local.
7831
7832 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
7833
7834         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
7835         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
7836         Problem reported by Denis Excoffier in
7837         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
7838
7839 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7840
7841         * modules/sys_socket, modules/socklen: Include sys/types since
7842         FreeBSD 4.x's sys/socket.h needs it.
7843
7844 2006-06-19  Simon Josefsson  <jas@extundo.com>
7845
7846         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
7847
7848 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
7849
7850         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
7851
7852 2006-06-19  Bruno Haible  <bruno@clisp.org>
7853
7854         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
7855         and FULL_PATH_INTTYPES_H in angle brackets.
7856         Reported by Mark D. Baushke <mdb@gnu.org>.
7857
7858 2006-06-17  Eric Blake  <ebb9@byu.net>
7859
7860         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
7861         errno.
7862
7863 2006-06-17  Bruno Haible  <bruno@clisp.org>
7864
7865         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
7866         <sys/inttypes.h>.
7867
7868 2006-06-17  Bruno Haible  <bruno@clisp.org>
7869
7870         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
7871         whether errno is declared. Assume <errno.h> declares errno.
7872
7873 2006-06-17  Bruno Haible  <bruno@clisp.org>
7874
7875         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
7876
7877 2006-06-17  Bruno Haible  <bruno@clisp.org>
7878
7879         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
7880         problem on Solaris 2.5.1.
7881
7882 2006-06-16  Eric Blake  <ebb9@byu.net>
7883
7884         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
7885         * lib/unicodeio.c [!defined errno]: Likewise.
7886         * lib/strtol.c [!defined errno]: Likewise.
7887         * lib/strtod.c [!defined errno]: Likewise.
7888
7889 2006-06-15  Eric Blake  <ebb9@byu.net>
7890
7891         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
7892
7893 2006-06-15  Eric Blake  <ebb9@byu.net>
7894
7895         * config/srclist.txt (ssize_t.m4): Lose sync.
7896
7897 2006-06-15  Bruno Haible  <bruno@clisp.org>
7898
7899         * modules/stdint (Files): Include m4/full-header-path.m4,
7900         m4/size_max.m4, m4/wchar_t.m4.
7901         (Makefile.am): Many more substitutions.
7902         * modules/stdint-tests: New file.
7903         * tests/test-stdint.c: New file.
7904
7905 2006-06-15  Bruno Haible  <bruno@clisp.org>
7906
7907         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
7908         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
7909         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
7910         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
7911         gl_CHECK_TYPE_SAME): New macros.
7912
7913 2006-06-15  Bruno Haible  <bruno@clisp.org>
7914
7915         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
7916
7917 2006-06-15  Bruno Haible  <bruno@clisp.org>
7918
7919         * lib/stdint_.h: Rewritten to be fully auto-configured.
7920         Fixes bug on HP-UX/IA64.
7921
7922 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
7923
7924         * lib/getdate.y (__attribute__): Don't define if already defined.
7925         Problem reported by Larry Jones.
7926         * lib/utimens.c (__attribute__): Likewise.
7927
7928 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
7929
7930         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
7931         reported by Andreas Schwab.
7932
7933 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7934             Bruno Haible  <bruno@clisp.org>
7935
7936         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
7937         check for the declaration of strnlen and a run test that exposes the
7938         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
7939         rpl_strndup.
7940
7941 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7942             Bruno Haible  <bruno@clisp.org>
7943
7944         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
7945
7946 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7947
7948         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
7949         compile test, for Tru64 4.0D.
7950
7951 2006-05-28  Karl Berry  <karl@gnu.org>
7952
7953         * config/srclist.txt (printf-args.c): lose sync.
7954
7955 2006-05-26  Martin Lambers  <marlam@marlam.de>
7956
7957         * lib/getpass.c: Updates the test for the native W32 API, and adds
7958         missing includes, thus fixing compilation warnings.
7959
7960 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7961
7962         * lib/exclude.c (exclude_fnmatch): New function.
7963         (excluded_file_name): Call exclude_fnmatch.
7964         * lib/exclude.h (excluded_file_name): New prototype
7965
7966 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
7967
7968         * lib/tempname.c (small_open, large_open): New macros.
7969         (__open, __open64) [!_LIBC]: Remove.
7970         (__gen_tempname): Use small_open and large_open instead of __open
7971         and __open64.  This fixes a portability bug on HP-UX 11.11i
7972         reported by Simon Wing-Tang in
7973         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
7974
7975 2006-05-24  Bruno Haible  <bruno@clisp.org>
7976
7977         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
7978         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
7979         Reported by Thorsten Maerz <torte@netztorte.de> via
7980         Aaron Stone <aaron@serendipity.cx>.
7981
7982 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7983
7984         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
7985         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
7986         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
7987         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
7988         not really conditional on the cache.
7989         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
7990
7991 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7992
7993         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
7994         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
7995         (my_usleep): Don't mishandle maximum value.
7996
7997 2006-05-19  Jim Meyering  <jim@meyering.net>
7998
7999         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
8000
8001 2006-05-17  Bruno Haible  <bruno@clisp.org>
8002
8003         Cygwin portability.
8004         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
8005
8006 2006-05-17  Bruno Haible  <bruno@clisp.org>
8007
8008         * lib/stdint_.h: Fix recognition of Cygwin.
8009
8010 2006-05-15  Bruno Haible  <bruno@clisp.org>
8011
8012         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
8013         on libtool patch by Ralf Wildenhues.
8014
8015 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
8016
8017         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
8018         test for C99 conformance; (bool) 0.5 is an integer constant
8019         expression, but (bool) -0.5 is not.  Problem reported by Fedor
8020         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
8021
8022 2006-05-11  Simon Josefsson  <jas@extundo.com>
8023
8024         * m4/xvasprintf.m4: Fix obvious typo.
8025
8026 2006-05-11  Jim Meyering  <jim@meyering.net>
8027
8028         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
8029         James Lemley.
8030
8031 2006-05-10  Simon Josefsson  <jas@extundo.com>
8032
8033         * lib/md4.c: Typo fix, update copyright years.
8034         (K1, K2): Don't use L because it turn computations into 64-bit on
8035         64-bit platforms.
8036
8037 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
8038
8039         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
8040         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
8041         unwanted sign propagation, e.g., on hosts with 64-bit int.
8042         There still are some problems with reeelly weird theoretical hosts
8043         (e.g., 33-bit int) but it's not worth worrying about now.
8044         * lib/sha1.c (rol): Likewise.
8045         (K1, K2, K3, K4): Remove unnecessary L suffix.
8046
8047 2006-05-10  Bruno Haible  <bruno@clisp.org>
8048
8049         * lib/des.c: Cast to avoid warnings.
8050
8051 2006-05-09  Bruno Haible  <bruno@clisp.org>
8052
8053         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
8054         (Depends-on): Depend also on xsize, stdarg.
8055         (configure.ac): Add gl_XVASPRINTF.
8056
8057 2006-05-09  Bruno Haible  <bruno@clisp.org>
8058
8059         * m4/xvasprintf.m4: New file.
8060
8061 2006-05-09  Bruno Haible  <bruno@clisp.org>
8062
8063         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
8064         (EOVERFLOW): Define fallback value.
8065         (xstrcat): New function.
8066         (xvasprintf): Recognize the special case of a string concatenation.
8067
8068 2006-05-08  Eric Blake  <ebb9@byu.net>
8069
8070         * gnulib-tool (func_version): Base copyright year on CVS date.
8071         (func_emit_copyright_notice): New function.
8072         (func_emit_lib_Makefile_am): Use it.
8073         (func_emit_tests_Makefile_am): Likewise.
8074         (func_import): Likewise.
8075
8076 2006-05-08  Bruno Haible  <bruno@clisp.org>
8077
8078         * modules/stdarg: New file.
8079         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
8080
8081 2006-05-08  Bruno Haible  <bruno@clisp.org>
8082
8083         * m4/stdarg.m4: New file, from GNU gettext.
8084
8085 2006-05-08  Bruno Haible  <bruno@clisp.org>
8086
8087         * config/srclist.txt (build-aux/config.rpath): different from latest
8088         release.
8089
8090 2006-05-08  Bruno Haible  <bruno@clisp.org>
8091
8092         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
8093
8094 2006-05-05  Jim Meyering  <jim@meyering.net>
8095
8096         * m4/warning.m4: New file, derived from bison's file by the same name.
8097
8098 2006-05-03  Bruno Haible  <bruno@clisp.org>
8099
8100         * lib/stdint_.h: Shorter URL.
8101         * lib/inttypes.h: Likewise.
8102
8103 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8104
8105         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
8106
8107 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8108
8109         * lib/verify.h: Document the internals better.  Most of this change
8110         was written by Bruno Haible.
8111
8112 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
8113
8114         * doc/verify.texi: New file, partly based on a proposal by
8115         Bruno Haible.
8116
8117 2006-05-02  Bruno Haible  <bruno@clisp.org>
8118
8119         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
8120         test from here...
8121         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
8122
8123 2006-04-29  Bruno Haible  <bruno@clisp.org>
8124
8125         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
8126         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
8127
8128 2006-04-29  Bruno Haible  <bruno@clisp.org>
8129
8130         * gnulib-tool: Make --update option actually work.
8131
8132 2006-04-29  Bruno Haible  <bruno@clisp.org>
8133
8134         * doc/gcd.texi: New file.
8135         * doc/gnulib.texi: Include it.
8136
8137 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
8138
8139         * lib/getdate.y (get_date): When adding relative date, start with the
8140         initial time, not with the result of the first mktime call.
8141
8142 2006-04-25  Bruno Haible  <bruno@clisp.org>
8143
8144         * gnulib-tool (func_import): Output the include directives in three
8145         blocks, sorted separately.
8146         Reported by Ben Pfaff <blp@cs.stanford.edu>.
8147
8148 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
8149
8150         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
8151         to define main with arguments, for C++.  Reported by Eric Blake.
8152         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
8153         Prefer 'int main ()' to 'int main (void)', for C++.
8154         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
8155         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
8156         for 'main', for C99 and C++.
8157
8158 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
8159
8160         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
8161         Don't assume that exit status -1 is valid.
8162         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
8163         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
8164         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
8165         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
8166         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
8167         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
8168         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
8169         functions can be used without declaring them, or that you can
8170         exit with status -1.
8171         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
8172
8173 2006-04-24  Karl Berry  <karl@gnu.org>
8174
8175         * config/srclist.txt (longdouble.m4): sync lost.
8176
8177 2006-04-24  Eric Blake  <ebb9@byu.net>
8178
8179         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
8180
8181 2006-04-24  Bruno Haible  <bruno@clisp.org>
8182
8183         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
8184         poll() implementation in AIX.
8185         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8186
8187 2006-04-24  Bruno Haible  <bruno@clisp.org>
8188
8189         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
8190         assigned exactly once.
8191
8192 2006-04-23  Claudio Fontana  <claudio@gnu.org>
8193             Bruno Haible  <bruno@clisp.org>
8194
8195         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
8196         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
8197         for AM_CPPFLAGS.
8198
8199 2006-04-23  Bruno Haible  <bruno@clisp.org>
8200
8201         * modules/copy-file: Depend on unistd.
8202         * modules/execute: Likewise.
8203         * modules/fatal-signal: Likewise.
8204         * modules/findprog: Likewise.
8205         * modules/mkdtemp : Likewise.
8206         * modules/pipe: Likewise.
8207         * modules/wait-process: Likewise.
8208
8209 2006-04-23  Bruno Haible  <bruno@clisp.org>
8210
8211         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
8212         condition was already detected.
8213         Reported by Ben Pfaff <blp@cs.stanford.edu>.
8214
8215 2006-04-23  Bruno Haible  <bruno@clisp.org>
8216
8217         * lib/copy-file.c: Include <unistd.h> unconditionally.
8218         * lib/execute.c: Likewise.
8219         * lib/fatal-signal.c: Likewise.
8220         * lib/findprog.c: Likewise.
8221         * lib/mkdtemp.c: Likewise.
8222         * lib/pipe.h: Likewise.
8223         * lib/pipe.c: Likewise.
8224         * lib/wait-process.h: Likewise.
8225
8226 2006-04-23  Bruno Haible  <bruno@clisp.org>
8227
8228         * gnulib-tool (func_usage): Fix --import description. Document
8229         --update.
8230         (func_import): Create temporary file in a temporary directory, if
8231         --dry-run is specified. Silence errors from 'grep' when there are no
8232         m4 files in $m4dir.
8233         (func_create_testdir): Silence errors from 'grep' when there are no
8234         m4 files in $m4dir.
8235         Reported by Karl Berry <karl@freefriends.org>.
8236
8237 2006-04-20  Bruno Haible  <bruno@clisp.org>
8238
8239         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
8240         one argument, so that the code will be portable to Autoconf 2.60.
8241         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
8242         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
8243         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
8244
8245 2006-04-19  Derek Price  <derek@ximbiot.com>
8246             Eric Blake  <ebb9@byu.net>
8247
8248         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
8249         rather than "/full/path.h".  Update comment to match.  Shorten &
8250         generalize m4_translit call via AS_TR_CPP.
8251
8252 2006-04-19  Derek Price  <derek@ximbiot.com>
8253             Eric Blake  <ebb9@byu.net>
8254
8255         * lib/inttypes.h: Correct grammar in comment.
8256
8257 2006-04-18  Derek Price  <derek@ximbiot.com>
8258             Paul Eggert  <eggert@cs.ucla.edu>
8259
8260         * modules/inttypes: New file.
8261         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
8262
8263 2006-04-18  Derek Price  <derek@ximbiot.com>
8264             Paul Eggert  <eggert@cs.ucla.edu>
8265
8266         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
8267         New files.
8268
8269 2006-04-18  Derek Price  <derek@ximbiot.com>
8270             Paul Eggert  <eggert@cs.ucla.edu>
8271
8272         * lib/inttypes.h: New file.
8273         * lib/strtoimax.c: Assume <inttypes.h>.
8274
8275 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
8276
8277         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
8278         isn't mounted.  Problem reported by Kir Kolyshkin.
8279
8280 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
8281
8282         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
8283         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
8284         Derek R. Price.
8285         * lib/regex.h (RE_DUP_MAX): Update comment to match current
8286         implementation.
8287
8288 2006-04-12  Eric Blake  <ebb9@byu.net>
8289
8290         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
8291         is now done automatically by the corresponding Autoconf macro.
8292
8293 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
8294
8295         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
8296         time_r.h.
8297
8298 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8299
8300         Merge regex changes from libc, removing some of our
8301         POSIX-conformance changes that were rejected and redoing them in a
8302         less-intrusive way.
8303
8304         * lib/regcomp.c (re_compile_internal, init_dfa):
8305         Length arg is now size_t, not Idx.  All uses changed.
8306         (peek_token): Forward decl now says internal_function.
8307         (__re_error_msgid, __re_error_msgid_idx):
8308         Now static rather than extern with attribute_hidden.
8309         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
8310         For some reason libc prefers K&R style defns for external functions.
8311         (regerror) [!defined _LIBC]: Likewise.
8312         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
8313         (seek_collating_symbol_entry, lookup_collation_sequence_value):
8314         (build_range_exp, build_collating_symbol):
8315         Use K&R-style defn.
8316         (re_compile_fastmap): Use '\0' to memset, not 0.
8317         (utf8_sb_map): Make the calculations more obvious.
8318         (init_dfa, parse_bracket_exp, build_charclass_op):
8319         Call calloc and cast result, as glibc does.
8320         (init_word_char, fetch_token, peek_token, peek_token_bracket):
8321         (build_range_exp, build_collating_symbol):
8322         Now internal functions.
8323
8324         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
8325
8326         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
8327         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
8328         Don't depend on VMS; depend on __VMS instead, for POSIX
8329         namespace cleanness.
8330         (regoff_t): Define to ssize_t, not long int.
8331
8332         Remove the REG_ macros named below.  Instead, make the old names
8333         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
8334         __USE_GNU_REGEX.
8335         (REG_BACKSLASH_ESCAPE_IN_LISTS):
8336         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
8337         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
8338         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
8339         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
8340         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
8341         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
8342         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
8343         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
8344         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
8345         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
8346         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
8347         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
8348         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
8349         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
8350         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
8351         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
8352         (REG_NREGS):
8353         Remove.  All uses replaced by the old RE_* names.
8354         (RE_BACKSLASH_ESCAPE_IN_LISTS):
8355         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
8356         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
8357         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
8358         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
8359         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
8360         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
8361         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
8362         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
8363         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
8364         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
8365         Don't bother having these macros be independent of each others'
8366         values, since they no longer exist in the POSIX name space.
8367
8368         Rename the following member names back to their old names,
8369         unless !__USE_GNU_REGEX.  All uses changed back.
8370         (buffer): Renamed from re_buffer.
8371         (allocated): Renamed from re_allocated.
8372         (used): Renamed from re_used.
8373         (syntax): Renamed from re_syntax.
8374         (fastmap): Renamed from re_fastmap.
8375         (translate): Renamed from re_translate.
8376         (can_be_null): Renamed from re_can_be_null.
8377         (regs_allocated): Renamed from re_regs_allocated.
8378         (fastmap_accurate): Renamed from re_fastmap_accurate.
8379         (no_sub): Renamed from re_no_sub.
8380         (not_bol): Renamed from re_not_bol.
8381         (not_eol): Renamed from re_not_eol.
8382         (newline_anchor): Renamed from re_newline_anchor.
8383         (num_regs): Renamed from rm_num_regs.
8384         (start): Renamed from rm_start.
8385         (end): Renamed from rm_end.
8386
8387         (free_state): Move up a bit.
8388
8389         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
8390         #define to be empty.
8391         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
8392         when that is what is intended.
8393         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
8394         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
8395         (MAX): New macro.
8396         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
8397         All uses changed back to re_malloc, etc.  It's now the caller's
8398         responsibility to check for overflow; all callers changed.
8399         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
8400         (re_x2nrealloc): Remove.
8401         (free_state): Remove decl.
8402
8403         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
8404         (re_set_registers, re_exec):
8405         Use K&R-style defn.
8406
8407         2006-01-31  Roland McGrath  <roland@redhat.com>
8408
8409         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
8410         Reported by Mike Frysinger <vapier@gentoo.org>.
8411
8412         2006-01-15  Andreas Jaeger  <aj@suse.de>
8413
8414         [BZ #1950]
8415         * lib/regex_internal.c (re_string_reconstruct): Adjust for
8416         build_wcs_upper_buffer change.
8417         (build_wcs_upper_buffer): Change return type.
8418
8419         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
8420
8421         * lib/regex_internal.h: Include <stdint.h> if available.
8422
8423         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
8424
8425         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
8426
8427         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
8428
8429         * lib/regcomp.c: Adjust for changed secondary hash function.
8430
8431         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
8432
8433         * lib/regex.h: Pretty printing.
8434         Clean up namespace a bit.
8435
8436         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
8437
8438         * lib/regexec.c (update_cur_sifted_state, check_arrival,
8439         check_arrival_add_next_nodes): Avoid using uninitialized variable.
8440
8441         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
8442                     Ulrich Drepper  <drepper@redhat.com>
8443
8444         [BZ #1302]
8445         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
8446         changed.
8447         (bitset_word_t): Renamed from bitset_word.  All uses changed.
8448
8449         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
8450
8451         [BZ #281]
8452         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
8453         * lib/regcomp.c: Remove unnecessary uses of
8454         unsigned RE_TRANSLATE_TYPE.
8455         * lib/regex_internal.h: Likewise.
8456         * lib/regex_internal.c: Likewise.
8457         * lib/regexec.c: Likewise.
8458         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
8459
8460         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
8461
8462         * lib/regexec.c (find_recover_state): Remove unnecessary
8463         initialization.
8464         (transit_state_bkref): Make DFA a const pointer.
8465         (get_subexp): Likewise.
8466         (check_arrival): Likewise.
8467         (update_cur_sifted_state): Likewise.
8468         (re_search_internal): Likewise.
8469         (prune_impossible_nodes): Likewise.
8470         (acquire_init_state_context): Likewise.
8471         (proceed_next_node): Likewise.
8472         (set_regs): Likewise.
8473         (free_fail_stack_return): Likewise.
8474         (check_arrival_expand_ecl): Mark DFA parameter as const.
8475         (check_arrival_expand_ecl_sub): Likewise.
8476         (check_subexp_limits): Likewise.
8477         (sub_epsilon_src_nodes):  Likewise.
8478         (add_epsilon_src_nodes):  Likewise.
8479         (merge_state_array): Likewise.
8480         (update_regs): Likewise.
8481         (build_trtable): Likewise.
8482         (sift_states_backward): Mark MCTX parameter as const.
8483         (build_sifted_states): Likewise.
8484         (update_cur_sifted_state): Likewise.
8485         (sift_states_mkref): Likewise.
8486         (check_arrival_expand_ecl): Mark eclosure as const.
8487         (check_dst_limits_calc_pos_1): Likewise.
8488         * lib/regex_internal.h (re_match_context_t): Make dfa a const
8489         pointer.
8490
8491         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
8492
8493         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
8494         (transit_state_sb): Likewise.
8495         (transit_state_mb): Likewise.
8496         (sift_states_iter_mb): Likewise.
8497         (check_arrival_add_next_nodes): Likewise.
8498         (check_node_accept_bytes): Change first parameter to pointer-to-const.
8499         [_LIBC] (re_search_2_stub): Use mempcpy.
8500
8501         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
8502         mbrtowc for very simple UTF-8 case.
8503
8504         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
8505         a pointer-to-const.
8506         (re_acquire_state_context): Likewise.
8507         * lib/regex_internal.h: Adjust prototypes.
8508
8509         * lib/regex.c: Prevent using C++ compilers.
8510
8511         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
8512         (re_acquire_state_context): Likewise.
8513
8514 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8515
8516         * modules/regex (Depends-on): Add ssize_t.
8517
8518 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8519
8520         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
8521         translation table.
8522
8523 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
8524
8525         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
8526
8527 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
8528             Bruno Haible  <bruno@clisp.org>
8529
8530         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
8531         <sys/types.h> and <inttypes.h>.
8532
8533 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8534
8535         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
8536         `__error_t_defined', so argp.h will not typedef the former.
8537
8538 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
8539
8540         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
8541         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
8542         glibc names.  Even if glibc is changed to conform to POSIX, the
8543         traditional names will be available anyway, since regex depends on
8544         the extensions module.  Also, fix a longstanding typo in the
8545         implementation of Spencer ERE test #75 from grep 2.3.  Problems
8546         reported by Emanuele Giaquinta.  Also, change sense of cached
8547         variable, so that the message makes sense.
8548
8549 2006-03-24  Simon Josefsson  <jas@extundo.com>
8550
8551         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
8552         including some doc fixes.
8553         (base64_encode_alloc): Fix +1 bug on allocation failures.
8554
8555 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8556
8557         * lib/base64.c (base64_encode): Do not read past end of array with
8558         unsanitized input on systems with CHAR_BIT > 8.
8559
8560 2006-03-24  Eric Blake  <ebb9@byu.net>
8561
8562         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
8563
8564 2006-03-22  Karl Berry  <karl@gnu.org>
8565
8566         * config/srclist.txt (*setenv.[ch]): get from coreutils.
8567         * config/srclistvars.sh (COREUTILS): new var.
8568
8569 2006-03-17  Jim Meyering  <jim@meyering.net>
8570
8571         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
8572         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
8573
8574 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
8575
8576         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
8577         no longer needs it.  Instead, check that regoff_t is as least
8578         as wide as ptrdiff_t.
8579
8580         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
8581         so that our regex.h stays compatible with the installed regex.
8582         This is helpful for installers who configure --without-included-regex.
8583         Problem reported by Emanuele Giaquinta.
8584
8585 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
8586
8587         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
8588         Typedef to long int, not to off_, as POSIX will likely change
8589         in that direction.
8590
8591 2006-03-15  Eric Blake  <ebb9@byu.net>
8592
8593         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
8594
8595 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
8596
8597         * lib/argp-help.c (validate_uparams): Fix typo
8598         * lib/argp-parse.c (argp_default_options): Consistently begin help
8599         messages with a lowercase letter.
8600
8601 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
8602
8603         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
8604         overrun buffers and shouldn't be used (much as gets shouldn't be
8605         used).
8606         * lib/time_r.c (asctime_r, ctime_r): Likewise.
8607
8608 2006-03-08  Simon Josefsson  <jas@extundo.com>
8609
8610         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
8611         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8612
8613 2006-03-08  Simon Josefsson  <jas@extundo.com>
8614
8615         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
8616         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8617
8618 2006-03-08  Simon Josefsson  <jas@extundo.com>
8619
8620         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
8621         signal that configure disabled the device.
8622
8623 2006-03-08  Simon Josefsson  <jas@extundo.com>
8624
8625         * build-aux/maint.mk: Fix refresh-po, to handle no translated
8626         languages.
8627
8628 2006-03-07  Simon Josefsson  <jas@extundo.com>
8629
8630         * modules/getopt (Depends-on): Add unistd.
8631
8632         * modules/unistd: New file.
8633
8634 2006-03-07  Simon Josefsson  <jas@extundo.com>
8635
8636         * modules/gc-random: New file.
8637
8638 2006-03-07  Simon Josefsson  <jas@extundo.com>
8639
8640         * m4/unistd_h.m4: New file.
8641
8642 2006-03-07  Simon Josefsson  <jas@extundo.com>
8643
8644         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
8645         test to be side-effect free by storing the result in the cache
8646         variable gl_cv_lib_readline, and moving the assignment of
8647         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
8648         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8649
8650 2006-03-07  Simon Josefsson  <jas@extundo.com>
8651
8652         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
8653         error on missing devices (the functions will return an error).
8654
8655         * m4/gc.m4: Move random stuff to gc-random.m4
8656
8657 2006-03-07  Simon Josefsson  <jas@extundo.com>
8658
8659         * lib/unistd_.h: New file.
8660
8661 2006-03-07  Simon Josefsson  <jas@extundo.com>
8662
8663         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
8664
8665 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8666
8667         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
8668         Problem reported by Juan Manuel Guerrero.
8669
8670 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8671
8672         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
8673         the unistd module.
8674         * lib/getlogin_r.c: Likewise.
8675         * lib/getlogin_r.h: Likewise.
8676         * lib/glob.c: Likewise.
8677         * lib/pagealign_alloc.c: Likewise.
8678         * lib/unistd_.h: Remove; no longer needed.
8679
8680 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
8681
8682         * MODULES.html.sh (Support for systems lacking POSIX:2001):
8683         Add unistd.
8684         * modules/c-stack (Depends-on): Add unistd.
8685         * modules/getlogin_r: Likewise.
8686         * modules/glob: Likewise.
8687         * modules/pagealign_alloc: Likewise.
8688         * modules/unistd (Files): Remove lib/unistd_.h.
8689         (EXTRA_DIST): Remove.
8690         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
8691         need unistd_.h.
8692         (MOSTLYCLEANFILES): Remove unistd.h-t.
8693
8694 2006-03-03  Simon Josefsson  <jas@extundo.com>
8695
8696         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
8697
8698 2006-03-03  Simon Josefsson  <jas@extundo.com>
8699
8700         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
8701         libidn and bison.
8702
8703 2006-03-03  Simon Josefsson  <jas@extundo.com>
8704
8705         * build-aux/maint.mk: Add indent target.
8706
8707 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
8708
8709         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
8710         our replacement poll.h in any case, to avoid a differing
8711         declaration from a system header.  Seen on AIX.
8712
8713 2006-03-01  Simon Josefsson  <jas@extundo.com>
8714
8715         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
8716         <kasal@ucw.cz>.
8717
8718 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
8719
8720         * modules/gettime (Depends-on): Add extensions module.
8721         * modules/nanosleep (Depends-on): Likewise.
8722         * modules/settime (Depends-on): Likewise.
8723
8724 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
8725
8726         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
8727         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
8728         pedantically.
8729         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
8730         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
8731
8732         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
8733         not "==".  Reported by Ralf Wildenhues.
8734
8735 2006-03-01  Karl Berry  <karl@gnu.org>
8736
8737         * doc/Copyright/request-*: new files, synced from gnuorg.
8738
8739 2006-03-01  Karl Berry  <karl@gnu.org>
8740
8741         * config/srclist.txt (Copyright/*): new entries.
8742
8743 2006-02-28  Simon Josefsson  <jas@extundo.com>
8744
8745         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
8746
8747 2006-02-27  Simon Josefsson  <jas@extundo.com>
8748
8749         * lib/base64.h: Indent #define's.  From Jim Meyering
8750         <jim@meyering.net>.
8751
8752 2006-02-27  Jim Meyering  <jim@meyering.net>
8753
8754         Revert the change of 2006-02-24, so these files can continue
8755         to be sync'd from gettext.
8756         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
8757         of `config.h'.
8758
8759 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
8760
8761         * modules/intprops: New file.
8762         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
8763         Add intprops.
8764         * modules/getloadavg (Files): Remove lib/intprops.h.
8765         (Depends-on): Add intprops.
8766         * modules/human: Likewise.
8767         * modules/inttostr: Likewise.
8768         * modules/openat: Likewise.
8769         * modules/sig2str: Likewise.
8770         * modules/userspec: Likewise.
8771         * modules/utimecmp: Likewise.
8772         * modules/xnanosleep: Likewise.
8773         * modules/xstrtol: Likewise.
8774
8775 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
8776
8777         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
8778         * modules/lock-tests (TESTS): Use $(EXEEXT).
8779         * modules/tls-tests: Likewise.
8780         * modules/argp-tests: Likewise.
8781         (check_PROGRAMS): New var, replacing...
8782         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
8783
8784 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8785
8786         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
8787         `config.h'.
8788
8789 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
8790
8791         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
8792
8793 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8794
8795         Sync from coreutils.
8796         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
8797         gl_CHDIR_SAFER.
8798
8799 2006-02-22  Jim Meyering  <jim@meyering.net>
8800
8801         Sync from coreutils.
8802         * m4/chdir-safer.m4: New file.
8803
8804 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
8805
8806         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
8807         AT_FDCWD exceeds INT_MAX.
8808         * lib/openat.h (AT_FDCWD): Likewise.
8809
8810 2006-02-17  Eric Blake  <address@hidden>
8811
8812         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
8813
8814 2006-02-16  Simon Josefsson  <jas@extundo.com>
8815
8816         * modules/getaddrinfo (Depends-on): Add sys_socket.
8817
8818 2006-02-15  Simon Josefsson  <jas@extundo.com>
8819
8820         * build-aux/maint.mk: Add dsyntax-check rule.
8821
8822 2006-02-15  Eric Blake  <ebb9@byu.net>
8823
8824         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
8825         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
8826         'present but cannot compile' warnings on cygwin.
8827         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
8828         use ws2tcpip.h if sys/socket.h works.
8829         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
8830         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
8831
8832 2006-02-14  Simon Josefsson  <jas@extundo.com>
8833
8834         * modules/maintainer-makefile (Files): Rename.
8835
8836         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
8837         and (the local) Makefile.cfg to maint-cfg.mk.
8838
8839         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
8840         to the latter.
8841
8842         * modules/maintainer-makefile: New module.
8843
8844         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
8845         severaly stripped to make it possible to build it up from scratch
8846         with reliable tests.
8847
8848         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
8849         fixes to permit overriding the default actions when configure and
8850         makefile are not available.
8851
8852 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
8853
8854         Sync from coreutils.
8855         * modules/lstat (Depends-on): Don't depend on xalloc.
8856         (License): Change from GPL to LGPL, since this is now simply a
8857         replacement for a libc function.
8858
8859 2006-02-14  Jim Meyering  <jim@meyering.net>
8860
8861         Sync from coreutils.
8862
8863         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
8864         failure on deficient systems, and simplify gnulib lgpl dependencies.
8865         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
8866         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
8867
8868         * lib/xalloc-die.c: Remove unused definition of N_.
8869
8870 2006-02-14  Jim Meyering  <jim@meyering.net>
8871
8872         Sync from coreutils.
8873         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
8874         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
8875         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
8876         double-quote uses of that variable, to accommodate the rare case in
8877         which getmntent is available in none of the libraries checked.  This
8878         happens at least on FreeBSD 5.0.
8879
8880 2006-02-13  Simon Josefsson  <jas@extundo.com>
8881
8882         * gnulib-tool (Usage): Fix --import, from
8883         karl@freefriends.org (Karl Berry).
8884
8885 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
8886
8887         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
8888
8889 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
8890
8891         * lib/argp-namefrob.h: Restore changes accidentally lost during the
8892         "autoupdate" on 2005-12-12.
8893
8894 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
8895
8896         * modules/closeout (Depends-on): Remove atexit.
8897
8898 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
8899
8900         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
8901         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
8902
8903 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
8904
8905         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
8906         __EXTENSIONS__ if this causes compilation to fail.  Problem
8907         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
8908         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
8909
8910 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
8911
8912         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
8913         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
8914         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
8915         All uses changed.
8916
8917 2006-01-26  Simon Josefsson  <jas@extundo.com>
8918
8919         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
8920         prototype is visible on mingw32.
8921
8922         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
8923         for mingw32.
8924
8925         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
8926         mingw32).
8927
8928 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
8929
8930         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
8931         attempt to open for write; this always fails, at least on POSIX
8932         hosts.  This reinstates the 2006-01-09 change, which was
8933         inadvertently removed.
8934
8935 2006-01-26  Bruno Haible  <bruno@clisp.org>
8936
8937         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
8938         Reported by Paul Eggert.
8939
8940 2006-01-26  Bruno Haible  <bruno@clisp.org>
8941             Paul Eggert  <eggert@cs.ucla.edu>
8942
8943         * lib/stdbool_.h (_Bool)
8944         [(! (defined __cplusplus || defined __BEOS__)
8945           && !defined __GNUC__
8946           && !(defined __HP_cc || defined __xlc__
8947                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
8948                || defined __sgi))]:
8949         #define to signed char in these cases too; this simplifies
8950         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
8951         etc., separately) and makes it more conservative.
8952
8953 2006-01-25  Simon Josefsson  <jas@extundo.com>
8954
8955         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
8956         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
8957         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
8958
8959 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
8960
8961         * lib/argp-namefrob.h: Bugfix. Remove stray #
8962
8963 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
8964
8965         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
8966         so that we test the test.
8967         Check for yet another HP-UX cc bug involving *bool |= bool.
8968
8969 2006-01-25  Karl Berry  <karl@gnu.org>
8970
8971         * config/srclist.txt (vasnprintf.c): sync lost.
8972
8973 2006-01-25  Jim Meyering  <jim@meyering.net>
8974
8975         Sync from the stable (b5) branch of coreutils:
8976
8977         * lib/fts.c (fts_children): Don't let close() clobber errno from
8978         failed fchdir().
8979
8980         * lib/fts.c (fts_stat): When following a symlink-to-directory,
8981         don't necessarily interpret stat-fails+lstat-succeeds as indicating
8982         a dangling symlink.  That can also happen at least for ELOOP.
8983         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
8984         FYI, this bug predates the inclusion of fts.c in coreutils.
8985
8986         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
8987         in their own block, so pre-c99 compilers don't object.
8988
8989         Avoid the double-free (first in fts_read, second in fts_close) that
8990         would occur when an `active' directory is made inaccessible (e.g.,
8991         via chmod a-x) during a traversal.
8992         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8993         before returning.  Reproduce this failure by
8994         mkdir -p a/b; cd a; chmod a-x . b
8995         Reported by Stavros Passas.
8996
8997 2006-01-25  Jim Meyering  <jim@meyering.net>
8998
8999         * lib/fileblocks.c: Remove more useless parentheses.
9000         * lib/readutmp.h: Likewise.
9001
9002 2006-01-25  Bruno Haible  <bruno@clisp.org>
9003
9004         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
9005         warnings.
9006         Reported by Paul Eggert.
9007
9008 2006-01-25  Bruno Haible  <bruno@clisp.org>
9009
9010         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
9011         rid of a trap command. For Solaris sh.
9012         Reported by Mark D. Baushke <mdb@gnu.org>.
9013
9014 2006-01-24  Simon Josefsson  <jas@extundo.com>
9015
9016         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
9017         Bruno.
9018
9019 2006-01-24  Karl Berry  <karl@gnu.org>
9020
9021         * config/srclist.txt (argp-namefrob.h): sync lost.
9022
9023 2006-01-24  Jim Meyering  <jim@meyering.net>
9024
9025         * modules/openat (Files): Add lib/intprops.h.
9026         From Mark D. Baushke.
9027
9028 2006-01-24  Jim Meyering  <jim@meyering.net>
9029
9030         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
9031         Reported by Mark D. Baushke.
9032
9033 2006-01-24  Jim Meyering  <jim@meyering.net>
9034
9035         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
9036
9037 2006-01-24  Bruno Haible  <bruno@clisp.org>
9038
9039         * modules/strnlen (Maintainer): Change from glibc to all.
9040
9041 2006-01-24  Bruno Haible  <bruno@clisp.org>
9042
9043         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
9044         Patch by Paul Eggert.
9045
9046 2006-01-24  Bruno Haible  <bruno@clisp.org>
9047
9048         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
9049         already has it.
9050         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
9051         2005-11-26.
9052
9053         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
9054         'signed char' to avoid problems with the built-in _Bool type.
9055         Reported by Paul Eggert on 2005-11-26.
9056
9057 2006-01-24  Bruno Haible  <bruno@clisp.org>
9058
9059         * gnulib-tool (func_import): Avoid constructing complicated sed
9060         expressions inside backquote.
9061         Report and solution by Mark D. Baushke <mdb@gnu.org>.
9062
9063 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
9064
9065         These changes imported from libc.
9066         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
9067         test and two separate function calls.
9068         * lib/strndup.c (__strndup): Add libc_hidden_def.
9069
9070 2006-01-23  Simon Josefsson  <jas@extundo.com>
9071
9072         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
9073         Remove the test_*_SOURCES variable: automake infers it by default.
9074         * modules/tls-tests: Likewise.
9075
9076 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9077
9078         Work around porting bugs reported by Dieter in
9079         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
9080         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
9081         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
9082         Include "getopt.h" first, to check interface.
9083         (getenv): Declare only if defined HAVE_DECL_GETENV &&
9084         !HAVE_DECL_GETENV.
9085         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
9086         (__strndup): Revert to K&R-style function dfns, the glibc style.
9087         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
9088         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
9089         Include strnlen.h first, to get prototype properly.
9090         (strnlen): Renamed from __strnlen.
9091         Remove weak alias.
9092
9093 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9094
9095         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
9096
9097 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
9098
9099         * config/srclist.txt: Adjust to reflect glibc reorganization.
9100         This affects only comments.
9101
9102 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
9103
9104          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
9105          Reported by Bruce Korb <bkorb@gnu.org>.
9106
9107 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
9108
9109         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
9110         to pacify gcc -Wswitch-default.
9111
9112 2006-01-22  Bruno Haible  <bruno@clisp.org>
9113
9114         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
9115         temporary buffer for sprintf, take into account the precision also
9116         for 'd', 'i', 'u', 'o', 'x', 'X'.
9117
9118 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
9119
9120         * modules/argp-tests: New module
9121         * tests/test-argp.c: New file
9122         * tests/test-argp-2.sh: New file
9123
9124 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
9125
9126         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
9127         (__argp_base_name): Removed
9128         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
9129         typo.
9130         (__argp_base_name): Provide macro definition or extern declaration
9131         depending on the configuration
9132
9133 2006-01-20  Simon Josefsson  <jas@extundo.com>
9134
9135         * modules/inet_ntop (Depends-on): Depend on sys_socket.
9136
9137 2006-01-20  Simon Josefsson  <jas@extundo.com>
9138
9139         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
9140
9141 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
9142
9143         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
9144         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
9145         Suggested by Bruno Haible.
9146
9147 2006-01-20  Karl Berry  <karl@gnu.org>
9148
9149         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
9150         until changes propagate, I guess.
9151
9152 2006-01-19  Simon Josefsson  <jas@extundo.com>
9153
9154         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
9155
9156 2006-01-19  Simon Josefsson  <jas@extundo.com>
9157
9158         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
9159
9160 2006-01-19  Simon Josefsson  <jas@extundo.com>
9161
9162         * gnulib-tool: Set check_PROGRAMS.
9163
9164         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
9165         modules/des-tests, modules/gc-arcfour-tests,
9166         modules/gc-arctwo-tests, modules/gc-des-tests,
9167         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
9168         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
9169         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
9170         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
9171         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
9172         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
9173         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
9174         test_*_SOURCES.
9175
9176 2006-01-18  Simon Josefsson  <jas@extundo.com>
9177
9178         * modules/socklen (Depends-on): Depend on sys_socket.
9179
9180 2006-01-18  Simon Josefsson  <jas@extundo.com>
9181
9182         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
9183         modules/des-tests, modules/gc-arcfour-tests,
9184         modules/gc-arctwo-tests, modules/gc-des-tests,
9185         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
9186         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
9187         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
9188         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
9189         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
9190         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
9191         $(EXEEXT) to automake TESTS variable, for mingw32.
9192
9193 2006-01-17  Simon Josefsson  <jas@extundo.com>
9194
9195         * modules/socklen (Include): Need sys/socket.h.
9196
9197 2006-01-17  Bruno Haible  <bruno@clisp.org>
9198
9199         * modules/ssize_t (Include): Add <sys/types.h>.
9200
9201 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
9202
9203         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
9204         it's not portable and it doesn't work with cross-compiles.
9205         Problem reported by Bruno Haible.  Fix missing-$ typo in
9206         'test "gl_cv_ignore_unused_libraries" ...' that prevented
9207         -zignore from being used with Sun's C compiler.
9208
9209 2006-01-12  Simon Josefsson  <jas@extundo.com>
9210
9211         * lib/base64.c: Fix warning, reported by Bruno Haible
9212         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
9213
9214 2006-01-12  Bruno Haible  <bruno@clisp.org>
9215
9216         * modules/ldd: New file.
9217         * build-aux/ldd.sh.in: New file.
9218         * MODULES.html.sh (Support for building libraries and executables): Add
9219         ldd.
9220
9221 2006-01-12  Bruno Haible  <bruno@clisp.org>
9222
9223         * m4/ldd.m4: New file.
9224
9225 2006-01-12  Bruno Haible  <bruno@clisp.org>
9226
9227         * gnulib-tool (func_import, func_create_testdir): Don't go into an
9228         endless loop while replacing $auxdir with build-aux.
9229
9230 2006-01-11  Simon Josefsson  <jas@extundo.com>
9231
9232         * lib/stdint_.h (SIZE_MAX): Add missing (.
9233
9234 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
9235
9236         Sync from coreutils.
9237         * lib/md5.c: Fix commentary typos.
9238         (alignof, UNALIGNED_P): No need for a GCC-specific version.
9239         * lib/md5.h (__attribute__): Remove; unused.
9240         * lib/sha1.c: Fix commentary to match md5 better.
9241         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
9242         so that we don't need to worry about alignment.  All uses changed.
9243         This merges the 2005-10-28 md5 change into sha1.
9244
9245 2006-01-11  Jim Meyering  <jim@meyering.net>
9246
9247         Sync from coreutils.
9248         * lib/md5.c (OP): Fix spacing.
9249
9250 2006-01-11  Bruno Haible  <bruno@clisp.org>
9251
9252         Ensure automatic ordering between gl_LOCK and gl_ARGP.
9253         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
9254         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
9255
9256 2006-01-11  Bruno Haible  <bruno@clisp.org>
9257
9258         Ensure automatic ordering between gl_LOCK and gl_ARGP.
9259         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
9260         the "early" section as well.
9261
9262 2006-01-11  Bruno Haible  <bruno@clisp.org>
9263
9264         Avoid "ar: no archive members specified" error on MacOS X.
9265         * gnulib-tool (func_modules_add_dummy): New function.
9266         (func_import, func_create_testdir): Invoke it.
9267
9268 2006-01-11  Bruno Haible  <bruno@clisp.org>
9269
9270         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
9271         with $auxdir in AC_CONFIG_FILES statements.
9272
9273 2006-01-11  Bruno Haible  <bruno@clisp.org>
9274
9275         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9276         Initialize also noinst_HEADERS to empty.
9277
9278 2006-01-11  Bruno Haible  <bruno@clisp.org>
9279
9280         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
9281         variables.
9282         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
9283         autoreconf.
9284
9285 2006-01-11  Bruno Haible  <bruno@clisp.org>
9286
9287         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
9288         overridable by the user.
9289         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9290
9291 2006-01-10  Simon Josefsson  <jas@extundo.com>
9292
9293         * modules/sys_socket: New file.
9294
9295 2006-01-10  Simon Josefsson  <jas@extundo.com>
9296
9297         * m4/sys_socket_h.m4: New file.
9298
9299 2006-01-10  Simon Josefsson  <jas@extundo.com>
9300
9301         * lib/socket_.h: New file.
9302
9303 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9304
9305         * modules/readutmp (Maintainer): Add myself.
9306
9307 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9308
9309         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
9310         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
9311         People who are still concerned with buggy memcmp implementations
9312         can invoke gl_FUNC_MEMCMP themselves.
9313
9314 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
9315
9316         * lib/regex_internal.h (BITSET_WORD_BITS):
9317         Work around a bug in 64-bit PGC (before version 6.1-2), where the
9318         preprocessor mishandles large unsigned values as if they were signed.
9319         Problem reported by Claudio Fontana in
9320         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
9321
9322 2006-01-10  Jim Meyering  <jim@meyering.net>
9323
9324         Avoid the double-free (first in fts_read, second in fts_close) that
9325         would occur when an `active' directory is made inaccessible (e.g.,
9326         via chmod a-x) during a traversal.
9327         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
9328         before returning.  Reproduce this failure by
9329         mkdir -p a/b; cd a; chmod a-x . b
9330         Reported by Stavros Passas.
9331
9332         Sync from coreutils.
9333         * lib/sha1.c: Tweak grammar in a comment.
9334
9335 2006-01-10  Jim Meyering  <jim@meyering.net>
9336
9337         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
9338         Patch by Joerg Sonnenberger.
9339
9340 2006-01-10  Bruno Haible  <bruno@clisp.org>
9341
9342         * modules/readutmp: Depend on module free.
9343         * modules/strtok_r: Depend on module restrict.
9344
9345 2006-01-10  Bruno Haible  <bruno@clisp.org>
9346
9347         * modules/gettext (configure.ac): Add an invocation of
9348         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
9349
9350 2006-01-10  Bruno Haible  <bruno@clisp.org>
9351
9352         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
9353         Reported by Werner Lemberg <wl@gnu.org>.
9354
9355 2006-01-10  Bruno Haible  <bruno@clisp.org>
9356
9357         * lib/localcharset.c: Update from GNU gettext.
9358
9359 2006-01-10  Bruno Haible  <bruno@clisp.org>
9360
9361         * lib/argp.h (__const): Remove macro. Use const instead.
9362         * lib/argp-fmtstream.h (__const): Likewise.
9363         * lib/glob_.h (__const): Remove macro.
9364         * lib/glob-libc.h: Use const instead of __const.
9365
9366 2006-01-10  Bruno Haible  <bruno@clisp.org>
9367
9368         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
9369         variable.
9370         Needed to avoid an automake error regarding the 'gettext' module.
9371
9372 2006-01-09  Simon Josefsson  <jas@extundo.com>
9373
9374         * modules/inet_ntop (Depends-on): Add restrict.
9375
9376 2006-01-09  Simon Josefsson  <jas@extundo.com>
9377
9378         * modules/gc-rijndael-tests (License): Put under LGPL.
9379
9380         * modules/gc-des-tests (License): Likewise.
9381
9382         * modules/gc-arcfour-tests (License): Likewise.
9383
9384         * modules/gc-arctwo-tests (License): Likewise.
9385
9386         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
9387
9388         * modules/gc-hmac-sha1-tests (Files): Likewise.
9389
9390         * modules/gc-hmac-md5-tests (License): Likewise.
9391
9392         * modules/gc-sha1-tests (License): Likewise.
9393
9394         * modules/gc-md5-tests (License): Likewise.
9395
9396         * modules/gc-md4-tests (License): Likewise.
9397
9398         * modules/gc-md2-tests (License): Likewise.
9399
9400         * modules/gc-tests (License): Likewise.
9401
9402         * modules/des-tests (License): Likewise.
9403
9404         * modules/md4-tests (License): Likewise.
9405
9406         * modules/md2-tests (License): Likewise.
9407
9408 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9409
9410         Sync from coreutils:
9411
9412         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
9413         * modules/lib-ignore: New file.
9414         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
9415         chdir-safer.m4, lchmod.m4.
9416         * modules/openat: Add mkdirat.c, openat-priv.h.
9417
9418 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9419
9420         Sync from coreutils.
9421         * m4/lib-ignore.m4: New file.
9422         * m4/lchmod.m4: New file.
9423
9424 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9425
9426         Sync from coreutils.
9427         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
9428         for write access: POSIX says that must fail.
9429         * lib/fts.c (diropen): Likewise.
9430         * lib/save-cwd.c (save_cwd): Likewise.
9431         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
9432         well, for minor improvements on hosts that lack O_DIRECTORY.
9433         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
9434         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
9435         Fall back on chown if open failed with EACCES.
9436
9437         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
9438         Report an error at compile-time if only a 1-second nominal clock
9439         resolution is found.
9440
9441         * lib/lchmod.h: New file.
9442         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
9443         (make_dir_parents): Use lchown rather than chown, and
9444         lchmod rather than chmod.
9445
9446         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
9447         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
9448         "proc" reported by n0dalus.
9449
9450         * lib/mountlist.c: Include <limits.h>.
9451         (dev_from_mount_options)
9452         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
9453         New function.  It no longer assumes "dev=" has the System V meaning
9454         on Linux (since it doesn't).  It also parses "dev=" more carefully.
9455         (read_file_system_list)
9456         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
9457         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
9458         dev= in that case.
9459
9460         * lib/posixtm.h (PDS_PRE_2000): New macro.
9461         * lib/posixtm.c (year): Arg is now syntax_bits rather than
9462         allow_century.  All usages changed.  Reject dates outside the range
9463         1969-1999 if PDS_PRE_2000 is used.
9464
9465 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
9466
9467         Sync from coreutils.
9468         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
9469         (Time of day items): Mention the possibility of leap seconds.
9470         Problem reported by Dr. David Alan Gilbert.
9471
9472 2006-01-09  Jim Meyering  <jim@meyering.net>
9473
9474         Sync from coreutils.
9475
9476         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
9477
9478         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
9479
9480         * lib/modechange.c (mode_compile): Reject an invalid mode string
9481         that starts with an octal digit.  From Andreas Gruenbacher.
9482
9483         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
9484         and dup to open_safer and dup_safer, respectively.
9485         (openat_permissive): Fix typo in comment.
9486
9487         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
9488         "gettext.h"; either no longer needed or are guaranteed by openat.h.
9489         (_): Remove; no longer needed.
9490         (openat): Renamed from rpl_openat; no need for rpl_openat
9491         since openat.h renames openat for us.
9492         Replace most of the body with a call to openat_permissive,
9493         to avoid duplicate code.
9494         Port to (probably hypothetical) environments were mode_t is
9495         wider than int.
9496         (openat_permissive): Require mode arg, so that we can check
9497         types better.  Put it just after flags.  Change cwd failure
9498         indicator from pointer-to-bool to pointer-to-errno-value.
9499         All callers changed.
9500         Invoke openat_save_fail and/or openat_restore_fail if
9501         cwd_errno is null, so that openat can call us.
9502         (openat_permissive, fdopendir, fstatat, unlinkat):
9503         Simplify errno handling to avoid some duplicate code,
9504         as it's OK to set errno on success.
9505         * lib/openat.h: Revamp code so that function macros depend on
9506         __OPENAT_PREFIX only, not also on AT_FDCWD.
9507         (openat_ro): Remove.  Caller changed to use openat_permissive.
9508         (openat_permissive): Now a macro, if not a function.
9509         (openat_restore_fail, openat_save_fail): Now always functions,
9510         since mkdirat needs them even if __OPENAT_PREFIX is defined.
9511
9512         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
9513         and openat.c.
9514         * lib/mkdirat.c: Include openat-priv.h.
9515         Remove definitions of macros defined therein.
9516         * lib/openat.c: Likewise.
9517
9518         * lib/mkdirat.c (mkdirat): New file and function.
9519         * lib/openat.h (mkdirat): Declare.
9520
9521         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
9522
9523         * lib/openat.h (openat_permissive): Declare.
9524         (openat_ro): Define.
9525
9526         * lib/openat.c (EXPECTED_ERRNO): New macro.
9527         (openat_permissive): New function -- used in remove.c rewrite.
9528         (all functions): Set errno just before returning, only if there
9529         was an actual failure.
9530         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
9531
9532         Emulate openat-family functions using Linux's procfs, if possible.
9533         Idea and some code based on Ulrich Drepper's glibc changes.
9534
9535         * lib/openat.c: (BUILD_PROC_NAME): New macro.
9536         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
9537         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
9538         before falling back on save_cwd and restore_cwd.
9539         (fdopendir, fstatat, unlinkat): Likewise.
9540
9541         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
9542         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
9543
9544         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
9545         as second argument to va_arg.  Otherwise, some versions of gcc
9546         warn that `if this code is reached, the program will abort'.
9547
9548 2006-01-09  Jim Meyering  <jim@meyering.net>
9549
9550         Sync from coreutils.
9551         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
9552         Require openat-priv.h.
9553
9554 2006-01-09  Bruno Haible  <bruno@clisp.org>
9555
9556         * modules/strnlen (Include): Use strnlen.h.
9557
9558 2006-01-09  Bruno Haible  <bruno@clisp.org>
9559
9560         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
9561
9562 2006-01-09  Bruno Haible  <bruno@clisp.org>
9563
9564         * lib/sysexit_.h (EX_OK): New macro.
9565         Suggested by Martin Lambers <marlam@marlam.de>.
9566
9567 2006-01-09  Bruno Haible  <bruno@clisp.org>
9568
9569         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
9570         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
9571
9572 2006-01-09  Bruno Haible  <bruno@clisp.org>
9573
9574         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
9575         numbers.
9576
9577 2006-01-09  Bruno Haible  <bruno@clisp.org>
9578
9579         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
9580         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
9581         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
9582         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
9583
9584 2006-01-09  Bruno Haible  <bruno@clisp.org>
9585
9586         * build-aux/javacomp.sh.in: New file, moved from lib/.
9587         * modules/javacomp-script (Files): Update.
9588         (configure.ac): Add AC_CONFIG_FILES invocation.
9589         (EXTRA_DIST): Remove variable.
9590
9591         * build-aux/javaexec.sh.in: New file, moved from lib/.
9592         * modules/javaexec (Files): Update.
9593         (configure.ac): Add AC_CONFIG_FILES invocation.
9594         (EXTRA_DIST): Remove javaexec.sh.in.
9595
9596         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
9597         * modules/csharpcomp-script (Files): Update.
9598         (configure.ac): Add AC_CONFIG_FILES invocation.
9599         (EXTRA_DIST): Remove variable.
9600
9601         * build-aux/csharpexec.sh.in: New file, moved from lib/.
9602         * modules/csharpexec (Files): Update.
9603         (configure.ac): Add AC_CONFIG_FILES invocation.
9604         (EXTRA_DIST): Remove csharpexec.sh.in.
9605
9606 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
9607
9608         Sync from coreutils.
9609
9610         Add POSIX ACL support
9611         * lib/acl.h (copy_acl, set_acl): Add declarations.
9612         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
9613         systems other than Linux.
9614         (chmod_or_fchmod): New function: use fchmod when possible,
9615         and chmod otherwise.
9616         (file_has_acl): Add a POSIX ACL implementation, with a
9617         Linux-specific subcase.
9618         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
9619         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
9620         acls are unsupported.
9621         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
9622         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
9623         are unsupported.
9624
9625 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
9626
9627         Sync from coreutils.
9628         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
9629
9630 2006-01-07  Bruno Haible  <bruno@clisp.org>
9631
9632         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
9633         gl_EARLY.
9634
9635 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
9636
9637         * lib/strftime.c (tzname): Don't declare if it is already #defined.
9638         Problem reported for Mingw by Mark Junker.
9639
9640 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
9641
9642         * README: Gnulib normally doesn't generate a tarball.
9643
9644 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
9645
9646         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
9647         long int, not int, for nanosecond counts, so that people who are
9648         used to POSIX struct timespec won't be surprised.  Reported by Jim
9649         Meyering.
9650
9651 2005-12-28  Bruno Haible  <bruno@clisp.org>
9652
9653         * build-aux/config.rpath: Update from GNU gettext.
9654
9655 2005-12-16  Jim Meyering  <jim@meyering.net>
9656
9657         * modules/fprintftime: New module.
9658         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
9659
9660 2005-12-16  Jim Meyering  <jim@meyering.net>
9661
9662         * m4/fprintftime.m4: New file.
9663
9664 2005-12-16  Jim Meyering  <jim@meyering.net>
9665
9666         * lib/fprintftime.c, lib/fprintftime.h: New files.
9667
9668 2005-12-15  Simon Josefsson  <jas@extundo.com>
9669
9670         * modules/socklen (configure.ac): Fix M4 macro name, to align with
9671         new m4/socklen.m4.
9672
9673 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
9674
9675         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
9676         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
9677
9678 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
9679
9680         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
9681         * lib/argp-help.c (fill_in_uparams): Check if the constructed
9682         struct uparams is valid. Fall back to the default values if it is
9683         not.
9684
9685 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9686
9687         * modules/argp (Files): Add argp-pin.c
9688         (Depends-on): dirname
9689         (lib_SOURCES): Add argp-pin.c
9690
9691 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9692
9693         * m4/argp.m4:  Check if program_invocation_name and
9694         program_invocation_short_name are declared and define appropriate
9695         macros if they are not.
9696
9697 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9698
9699         * lib/argp-help.c (__argp_base_name): New function
9700         (__argp_short_program_name): Rewrite using __argp_base_name
9701         * lib/argp-namefrob.h: Define program_invocation_name and
9702         program_invocation_short_name if requested
9703         (__argp_base_name): Add prototype
9704         * lib/argp-parse.c (argp_def): Use gettext wrappers
9705         (argp_default_parser): Use __argp_base_name
9706         * lib/argp-pin.c: New file. Defines program_invocation_name and
9707         program_invocation_short_name on systems that lack them.
9708
9709 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
9710
9711         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
9712         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
9713         porting problem reported by Georg Schwarz in
9714         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
9715
9716 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
9717
9718         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
9719         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
9720         porting problem reported by Georg Schwarz in
9721         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
9722
9723 2005-12-05  Bruno Haible  <bruno@clisp.org>
9724
9725         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
9726         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
9727         Reported by Mark Junker <mjscod@gmx.de>.
9728
9729 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
9730
9731         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
9732         Use implementation from Albert Chin, with some
9733         comments/corrections by Stepan Kasal and myself.
9734
9735 2005-12-02  Bruno Haible  <bruno@clisp.org>
9736
9737         * gnulib-tool (func_import): Accept GPLed build tool modules when
9738         --lgpl is given.
9739         * modules/csharpcomp-script: New file.
9740         * modules/csharpcomp: Depend on it.
9741         * modules/javacomp-script: New file.
9742         * modules/javacomp: Depend on it.
9743         Suggested by Simon Josefsson.
9744
9745 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
9746
9747         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
9748         statement, to work around an HP-UX 10.20 compiler bug reported by
9749         Peter O'Gorman.
9750
9751 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
9752
9753         * modules/savedir (Depends-on): Add openat.
9754
9755 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
9756
9757         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
9758         (uintmax_t) [defined uintmax_t]: Do not declare.
9759         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
9760         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
9761         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
9762         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
9763         sake of portability to weird hosts that C allows (though we don't
9764         know of any practical examples).
9765
9766         * lib/savedir.h (fdsavedir): New decl.
9767         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
9768         contains most of the former guts of savedir.
9769         (savedir): Use savedirstream.
9770         Include "openat.h".
9771
9772 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
9773
9774         * modules/obstack (Files): Add m4/ulonglong.m4.
9775         Problem reported by Davide Angelocola.
9776
9777 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
9778
9779         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
9780         coreutils no longer futzes with rounding modes.
9781
9782 2005-11-14  Jim Meyering  <jim@meyering.net>
9783
9784         * lib/mkstemp-safer.c: Include <config.h>, required for possible
9785         replacement of mkstemp.
9786
9787 2005-11-10  Simon Josefsson  <jas@extundo.com>
9788
9789         * lib/readline.c: Remove EOL.
9790
9791 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9792
9793         * modules/gethrxtime (Depends-on): Add gettime.
9794
9795 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9796
9797         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
9798         or gettimeofday; no longer needed.
9799
9800 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9801
9802         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
9803         time business.
9804         (gethrxtime) [! (HAVE_NANOUPTIME
9805         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
9806         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
9807         our own approximation.
9808
9809 2005-11-08  Eric Blake  <ebb9@byu.net>
9810
9811         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
9812
9813 2005-11-08  Eric Blake  <ebb9@byu.net>
9814
9815         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
9816
9817 2005-11-04  Bruno Haible  <bruno@clisp.org>
9818
9819         * gnulib-tool: Implement --update mode.
9820
9821 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
9822
9823         Fix porting problem reported by Theodoros V. Kalamatianos.
9824         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
9825         Don't assume that futimes failing means we must fail.
9826
9827 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
9828
9829         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
9830         variables to suggest the intended function of the PATH_MAX check.
9831
9832 2005-10-30  Kean Johnston  <jkj@sco.com>
9833
9834         Trivial changes to support SCO systems.
9835         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
9836         as PATH_MAX.
9837         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
9838         where __ptr is null when no I/O is pending.
9839
9840 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
9841
9842         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
9843         leave errno alone.  Problem reported by Dmitry V. Levin.
9844
9845 2005-10-28  Simon Josefsson  <jas@extundo.com>
9846
9847         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
9848         Test more.
9849
9850         * tests/test-gc-md2.c, tests/test-md2.c: New files.
9851
9852         * modules/md2, modules/md2-tests: New files.
9853
9854 2005-10-28  Simon Josefsson  <jas@extundo.com>
9855
9856         * m4/inet_ntop.m4: More tests.
9857
9858         * m4/gc-md2.m4, md2.m4: New file.
9859
9860 2005-10-28  Simon Josefsson  <jas@extundo.com>
9861
9862         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
9863         "restrict" keywords, as per POSIX.  Protect the function
9864         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
9865         Don't use K&R prototypes.  Check the sprintf return values.
9866         Re-define EAFNOSUPPORT if not present.  Indent.
9867
9868         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
9869         suggested by Bruno Haible <bruno@clisp.org>.
9870
9871         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
9872
9873         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
9874
9875         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
9876         libgcrypt).
9877
9878         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
9879
9880         * lib/md2.h, lib/md2.c: New files.
9881
9882 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
9883
9884         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
9885         errno alone.  Problem reported by Frederic Jolliton.
9886
9887 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
9888
9889         * modules/verify (License): Change from GPL to LGPL.  This is a
9890         tiny module and there are apparently near-equivalents that are
9891         under the BSD license.
9892
9893 2005-10-24  Simon Josefsson  <jas@extundo.com>
9894
9895         * modules/sha1: Relicense to LGPL.
9896
9897 2005-10-24  Simon Josefsson  <jas@extundo.com>
9898
9899         * lib/md4.h: Shrink buffer size, now that we changed the type.
9900
9901 2005-10-23  Simon Josefsson  <jas@extundo.com>
9902
9903         * gnulib-tool (func_import): Fix --tests-base.
9904
9905 2005-10-22  Simon Josefsson  <jas@extundo.com>
9906
9907         * modules/arcfour (Depends-on): Need stdint.
9908
9909 2005-10-22  Simon Josefsson  <jas@extundo.com>
9910
9911         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
9912         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
9913
9914 2005-10-22  Simon Josefsson  <jas@extundo.com>
9915
9916         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
9917         suggested by Bruno Haible <bruno@clisp.org>.
9918
9919 2005-10-22  Simon Josefsson  <jas@extundo.com>
9920
9921         * lib/crc.h: Include stddef.h, for size_t.
9922
9923 2005-10-22  Simon Josefsson  <jas@extundo.com>
9924
9925         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
9926         arcfour_context struct (simplify test vector testing in GNU
9927         Shishi).
9928
9929 2005-10-21  Simon Josefsson  <jas@extundo.com>
9930
9931         * modules/des, modules/des-tests: New files.
9932
9933         * modules/gc-des, modules/gc-des-tests: New files.
9934
9935         * tests/test-des.c, tests/test-gc-des.c: New file.
9936
9937 2005-10-21  Simon Josefsson  <jas@extundo.com>
9938
9939         * modules/arctwo, modules/arctwo-tests: New files.
9940
9941         * tests/test-arctwo.c: New file.
9942
9943         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
9944
9945         * tests/test-gc-arctwo.c: New file.
9946
9947 2005-10-21  Simon Josefsson  <jas@extundo.com>
9948
9949         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
9950         Bruno Haible <bruno@clisp.org>.
9951
9952         * m4/gc-des.m4: New file.
9953
9954 2005-10-21  Simon Josefsson  <jas@extundo.com>
9955
9956         * m4/arctwo.m4: New file.
9957
9958         * m4/gc-arctwo.m4: New file.
9959
9960 2005-10-21  Simon Josefsson  <jas@extundo.com>
9961
9962         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
9963         block.
9964
9965 2005-10-21  Simon Josefsson  <jas@extundo.com>
9966
9967         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
9968         <bruno@clisp.org>.
9969
9970         * lib/hmac-sha1.c (hmac_sha1): Likewise.
9971
9972         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
9973         Bruno Haible <bruno@clisp.org>.
9974
9975         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
9976         <bruno@clisp.org>.
9977
9978 2005-10-21  Simon Josefsson  <jas@extundo.com>
9979
9980         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
9981
9982 2005-10-21  Simon Josefsson  <jas@extundo.com>
9983
9984         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
9985
9986 2005-10-21  Simon Josefsson  <jas@extundo.com>
9987
9988         * lib/des.h, lib/des.c: New files.
9989
9990         * lib/gc-gnulib.c: Support DES.c
9991
9992 2005-10-21  Simon Josefsson  <jas@extundo.com>
9993
9994         * lib/arctwo.h, lib/arctwo.c: New files.
9995
9996         * lib/gc-gnulib.c: Support ARCTWO.
9997
9998 2005-10-21  Simon Josefsson  <jas@extundo.com>
9999
10000         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
10001         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10002
10003 2005-10-21  Simon Josefsson  <jas@extundo.com>
10004
10005         * gnulib-tool (func_import, func_create_testdir): Define automake
10006         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
10007         Makefile.am snippet),
10008         suggested by Bruno Haible <bruno@clisp.org>.
10009
10010         * modules/gc (Makefile.am): Use it.
10011
10012 2005-10-21  Bruno Haible  <bruno@clisp.org>
10013
10014         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
10015         patch.
10016
10017 2005-10-19  Simon Josefsson  <jas@extundo.com>
10018
10019         * tests/test-gc-rijndael.c: New file.
10020
10021         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
10022
10023 2005-10-19  Simon Josefsson  <jas@extundo.com>
10024
10025         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
10026         interface too.
10027
10028 2005-10-19  Simon Josefsson  <jas@extundo.com>
10029
10030         * tests/test-gc-arcfour.c: New file.
10031
10032         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
10033
10034 2005-10-19  Simon Josefsson  <jas@extundo.com>
10035
10036         * modules/gc-md4, modules/gc-md4-tests: New file.
10037
10038         * tests/test-gc-md4.c: New file.
10039
10040 2005-10-19  Simon Josefsson  <jas@extundo.com>
10041
10042         * m4/gc-md4.m4: New file.
10043
10044 2005-10-19  Simon Josefsson  <jas@extundo.com>
10045
10046         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
10047         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
10048         <kasal@ucw.cz>.
10049
10050 2005-10-19  Simon Josefsson  <jas@extundo.com>
10051
10052         * m4/gc-arcfour.m4: New file.
10053
10054         * m4/gc-rijndael.m4: New file.
10055
10056 2005-10-19  Simon Josefsson  <jas@extundo.com>
10057
10058         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
10059
10060 2005-10-19  Simon Josefsson  <jas@extundo.com>
10061
10062         * lib/gc-gnulib.c: Support ARCFOUR.
10063
10064 2005-10-19  Simon Josefsson  <jas@extundo.com>
10065
10066         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
10067         support.
10068
10069         * lib/gc.h: Add ECB enum type.
10070
10071         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
10072
10073 2005-10-18  Simon Josefsson  <jas@extundo.com>
10074
10075         * tests/test-md5.c: New file.
10076
10077         * modules/md5-tests: New file.
10078
10079 2005-10-18  Simon Josefsson  <jas@extundo.com>
10080
10081         * tests/test-md4.c: New file.
10082
10083         * modules/md4, modules/md4-tests: New files.
10084
10085 2005-10-18  Simon Josefsson  <jas@extundo.com>
10086
10087         * m4/md4.m4: New file.
10088
10089 2005-10-18  Simon Josefsson  <jas@extundo.com>
10090
10091         * lib/md4.h, lib/md4.c: New files, based on md5.?.
10092
10093 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
10094
10095         * gnulib-tool (func_create_testdir): Omit the second check whether
10096         BUILT_SOURCES in nonempty.
10097
10098 2005-10-17  Simon Josefsson  <jas@extundo.com>
10099
10100         * tests/test-rijndael.c: New file.
10101
10102 2005-10-17  Simon Josefsson  <jas@extundo.com>
10103
10104         * modules/sha1: Depend on stdint instead of md5.
10105
10106         * modules/md5: Depend on stdint, remove uint32_t.
10107
10108 2005-10-17  Simon Josefsson  <jas@extundo.com>
10109
10110         * modules/gc-sha1-tests: New file.
10111
10112         * tests/test-gc-sha1.c: New file.
10113
10114 2005-10-17  Simon Josefsson  <jas@extundo.com>
10115
10116         * m4/md5.m4: Remove call to uint32_t.m4.
10117
10118 2005-10-17  Simon Josefsson  <jas@extundo.com>
10119
10120         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
10121
10122         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
10123         md5.h.
10124
10125         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
10126
10127         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
10128
10129 2005-10-17  Simon Josefsson  <jas@extundo.com>
10130
10131         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
10132
10133 2005-10-17  Simon Josefsson  <jas@extundo.com>
10134
10135         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
10136
10137 2005-10-17  Simon Josefsson  <jas@extundo.com>
10138
10139         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
10140
10141         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
10142
10143 2005-10-17  Bruno Haible  <bruno@clisp.org>
10144
10145         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
10146         that it can also be used in a test.
10147
10148 2005-10-16  Bruno Haible  <bruno@clisp.org>
10149
10150         * gnulib-tool (func_emit_tests_Makefile_am): Also define
10151         TESTS_ENVIRONMENT, so that individual tests can augment it.
10152
10153         * gnulib-tool (func_create_testdir): Use an intermediate target for
10154         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
10155         macros, like $(ALLOCA_H), which cannot be passed through the command
10156         line.
10157
10158 2005-10-15  Simon Josefsson  <jas@extundo.com>
10159
10160         * modules/rijndael-tests: New file.
10161
10162         * modules/rijndael: New file.
10163
10164 2005-10-15  Simon Josefsson  <jas@extundo.com>
10165
10166         * m4/rijndael.m4: New file.
10167
10168 2005-10-15  Simon Josefsson  <jas@extundo.com>
10169
10170         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
10171
10172         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
10173
10174 2005-10-14  Simon Josefsson  <jas@extundo.com>
10175
10176         * tests/test-arcfour.c: New file.
10177
10178         * modules/arcfour, modules/arcfour-tests: New files.
10179
10180 2005-10-14  Simon Josefsson  <jas@extundo.com>
10181
10182         * m4/arcfour.m4: New file.
10183
10184 2005-10-14  Simon Josefsson  <jas@extundo.com>
10185
10186         * lib/arcfour.h, lib/arcfour.c: New files.
10187
10188 2005-10-14  Roland McGrath  <roland@redhat.com>
10189
10190         Import from libc.  [BZ #1331]
10191         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
10192         macro argument.
10193         Reported by Matej Vela <vela@debian.org>.
10194
10195 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
10196
10197         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
10198         include <wchar.h>; no longer needed.
10199
10200 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
10201
10202         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
10203
10204 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
10205         and  Ulrich Drepper  <drepper@redhat.com>
10206
10207         Import from libc.
10208         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
10209         instead of inline stream orientation test and two separate
10210         function calls.  Pay no attention to USE_IN_LIBIO.
10211
10212 2005-10-13  Simon Josefsson  <jas@extundo.com>
10213
10214         * modules/gc-hmac-md5-tests: New file.
10215
10216         * tests/test-gc-hmac-sha1.c: New file.
10217
10218         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
10219
10220         * modules/gc-hmac-md5-tests: New file.
10221
10222         * tests/test-gc-md5.c: New file.
10223
10224         * modules/gc-md5-tests: New file.
10225
10226 2005-10-13  Simon Josefsson  <jas@extundo.com>
10227
10228         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
10229         Move memory allocation outside of loop.
10230
10231 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
10232
10233         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
10234         intermediate directory is in a read-only file system.  Problem
10235         reported by Eric Blake.
10236
10237 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
10238
10239         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
10240
10241 2005-10-12  Simon Josefsson  <jas@extundo.com>
10242
10243         * tests/test-hmac-sha1.c: New file.
10244
10245         * modules/hmac-sha1-tests: New file.
10246
10247         * modules/hmac-sha1: New file.
10248
10249 2005-10-12  Simon Josefsson  <jas@extundo.com>
10250
10251         * modules/gc-sha1: New file.
10252
10253 2005-10-12  Simon Josefsson  <jas@extundo.com>
10254
10255         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
10256
10257         * tests/test-gc-pbkdf2-sha1.c: New file.
10258
10259 2005-10-12  Simon Josefsson  <jas@extundo.com>
10260
10261         * modules/gc-md5, modules/gc-hmac-md5: New files.
10262
10263         * modules/gc (Files): Remove md5, memxor and hmac files.
10264
10265 2005-10-12  Simon Josefsson  <jas@extundo.com>
10266
10267         * m4/gc-pbkdf2-sha1.m4: New file.
10268
10269         * m4/gc-hmac-sha1.m4: New file.
10270
10271         * m4/gc-sha1: New file.
10272
10273         * m4/hmac-sha1.m4: New file.
10274
10275 2005-10-12  Simon Josefsson  <jas@extundo.com>
10276
10277         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
10278
10279         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
10280
10281 2005-10-12  Simon Josefsson  <jas@extundo.com>
10282
10283         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
10284         suggested by Bruno Haible <bruno@clisp.org>.
10285
10286 2005-10-12  Simon Josefsson  <jas@extundo.com>
10287
10288         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
10289
10290 2005-10-12  Simon Josefsson  <jas@extundo.com>
10291
10292         * lib/gc-pbkdf2-sha1.c: New file.
10293
10294         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
10295
10296 2005-10-12  Simon Josefsson  <jas@extundo.com>
10297
10298         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
10299
10300         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
10301
10302 2005-10-12  Simon Josefsson  <jas@extundo.com>
10303
10304         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
10305         GC_USE_HMAC_MD5, respectively.
10306
10307         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
10308         (gc_md5): Fix typo.
10309
10310         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
10311
10312         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
10313
10314         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
10315
10316 2005-10-12  Bruno Haible  <bruno@clisp.org>
10317
10318         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
10319         Reported by Stepan Kasal <kasal@ucw.cz>.
10320
10321 2005-10-11  Simon Josefsson  <jas@extundo.com>
10322
10323         * tests/test-crc.c: New file.
10324
10325         * modules/crc, modules/crc-tests: New files.
10326
10327 2005-10-11  Simon Josefsson  <jas@extundo.com>
10328
10329         * m4/crc.m4: New file.
10330
10331 2005-10-11  Simon Josefsson  <jas@extundo.com>
10332
10333         * lib/gc.h: Add gc_hash and gc_hash_buffer.
10334
10335         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
10336
10337         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
10338
10339 2005-10-11  Simon Josefsson  <jas@extundo.com>
10340
10341         * lib/crc.h, lib/crc.c: New files.
10342
10343         * lib/gc.h (gc_hash_buffer): Add doc.
10344
10345 2005-10-11  Bruno Haible  <bruno@clisp.org>
10346
10347         * modules/c-strcasestr: New file.
10348         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
10349
10350 2005-10-11  Bruno Haible  <bruno@clisp.org>
10351
10352         * modules/c-strcase: New file.
10353         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
10354
10355 2005-10-11  Bruno Haible  <bruno@clisp.org>
10356
10357         * lib/strcasecmp.c: Include limits.h.
10358         (strcasecmp): Avoid integer overflow on exotic platforms.
10359         * lib/strncasecmp.c: Include limits.h.
10360         (strncasecmp): Avoid integer overflow on exotic platforms.
10361         Reported by Paul Eggert.
10362
10363 2005-10-11  Bruno Haible  <bruno@clisp.org>
10364
10365         * lib/c-strcasestr.h: New file, from GNU gettext.
10366         * lib/c-strcasestr.c: New file, from GNU gettext.
10367
10368 2005-10-11  Bruno Haible  <bruno@clisp.org>
10369
10370         * lib/c-strcase.h: New file, from GNU gettext.
10371         * lib/c-strcasecmp.c: New file, from GNU gettext.
10372         * lib/c-strncasecmp.c: New file, from GNU gettext.
10373
10374 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
10375
10376         * modules/mempcpy (License): GPL -> LGPL.
10377         * modules/strchrnul (License): Likewise.
10378         * modules/sysexits (License): Likewise.
10379
10380 2005-10-08  Simon Josefsson  <jas@extundo.com>
10381
10382         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
10383
10384 2005-10-07  Simon Josefsson  <jas@extundo.com>
10385
10386         * m4/memxor.m4: Remove gl_C_RESTRICT call.
10387
10388 2005-10-06  Simon Josefsson  <jas@extundo.com>
10389
10390         * tests/test-hmac-md5.c: New file.
10391
10392         * modules/hmac-md5-tests: New file.
10393
10394         * modules/hmac-md5: New file.
10395
10396 2005-10-06  Simon Josefsson  <jas@extundo.com>
10397
10398         * m4/hmac-md5.m4: New file.
10399
10400         * m4/memxor.m4: Require gl_C_RESTRICT.
10401
10402 2005-10-06  Simon Josefsson  <jas@extundo.com>
10403
10404         * lib/memxor.c (memxor): Avoid casts and warnings.
10405
10406 2005-10-06  Simon Josefsson  <jas@extundo.com>
10407
10408         * lib/hmac-md5.c: New file.
10409
10410         * lib/hmac.h: New file.
10411
10412 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10413
10414         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
10415         promotes to int, not unsigned int, to catch the AIX 5.3
10416         compiler bug.
10417
10418 2005-10-05  Simon Josefsson  <jas@extundo.com>
10419
10420         * modules/memxor: New file.
10421
10422         * modules/iconv (Files): Move config.rpath to havelib, it is used
10423         there.
10424
10425         * modules/havelib (Files): Add config.rpath.
10426
10427 2005-10-05  Simon Josefsson  <jas@extundo.com>
10428
10429         * m4/memxor.m4: New file.
10430
10431 2005-10-05  Simon Josefsson  <jas@extundo.com>
10432
10433         * lib/memxor.c (memxor): Fix compiler error.
10434
10435         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
10436         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
10437
10438         * lib/memxor.h, lib/memxor.c: New files.
10439
10440         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
10441         we assume all systems have it, suggested by Jim Meyering
10442         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
10443         any systems lack sys/socket.h; mingw32 is known to lack it, but we
10444         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
10445         same reasons.
10446
10447 2005-10-05  Simon Josefsson  <jas@extundo.com>
10448
10449         * config/srclist.txt: Add glibc bug 1423 for md5.h.
10450
10451 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10452
10453         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
10454         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
10455         needed, since the source code now assumes these .h files.
10456
10457 2005-10-05  Derek Price  <derek@ximbiot.com>
10458
10459         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
10460
10461 2005-10-05  Bruno Haible  <bruno@clisp.org>
10462
10463         * modules/stdint (License): Change to LGPL.
10464
10465 2005-10-04  Simon Josefsson  <jas@extundo.com>
10466
10467         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
10468         D. Baushke" <mdb@gnu.org>.
10469
10470 2005-10-04  Bruno Haible  <bruno@clisp.org>
10471
10472         * lib/verify.h (verify_true): Provide alternative definition for C++.
10473
10474 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
10475
10476         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
10477         (SSIZE_MAX): New macro, if not already defined.
10478         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
10479         than 2 GiB.
10480
10481 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10482
10483         Sync from coreutils.
10484         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
10485         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
10486         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
10487         ULLONG_MAX doesn't work with 2.7.2.1.
10488
10489 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10490
10491         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
10492         From Ben Pfaff.
10493
10494         * modules/exclude (Depends-on): Depend on verify.
10495         * modules/strtoimax (Depends-on): Likewise.
10496         * modules/utimecmp (Depends-on): Likewise.
10497
10498 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
10499
10500         * lib/exclude.c: Include verify.h.
10501         (verify): Remove.  All callers changed to use verify.h's version.
10502         * lib/strtoimax.c: Likewise.
10503         * lib/utimecmp.c: Likewis.e
10504
10505         Sync from coreutils.
10506         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
10507         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
10508         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
10509         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
10510         bother returning ENOSYS if settimeofday or stime fails; just let
10511         them return whatever errno they want to return.
10512         * lib/utimens.c: Include unistd.h, for dup2.
10513         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
10514         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
10515
10516 2005-10-02  Jim Meyering  <jim@meyering.net>
10517
10518         Sync from coreutils.
10519         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
10520         from glibc-2.2.5 that fails for read-only files.
10521
10522 2005-10-02  Jim Meyering  <jim@meyering.net>
10523
10524         Sync from coreutils.
10525         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
10526         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
10527         `#if HAVE_CONFIG_H'.
10528         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
10529         Remove AT_FDCWD test.
10530         Do not consume the fd unless successful.
10531         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
10532         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
10533         block, so that we don't even try to compile it if settimeofday is
10534         available.  This works around a compilation failure on OSF1 V5.1,
10535         due to stime requiring a `long int*' while tv_sec is `int'.
10536
10537 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
10538
10539         Sync from coreutils.
10540         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
10541         against `yes', rather than just testing for nonempty.
10542
10543 2005-10-01  Simon Josefsson  <jas@extundo.com>
10544
10545         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
10546         and Darwin.
10547
10548         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
10549         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
10550         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
10551         freeaddrinfo and gai_strerror are declared by the POSIX headers.
10552         Check if struct addrinfo is declared.
10553
10554 2005-10-01  Simon Josefsson  <jas@extundo.com>
10555
10556         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
10557         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
10558         AI_* and EAI_* definitions.  Protect function declarations.
10559
10560 2005-10-01  Jim Meyering  <jim@meyering.net>
10561
10562         Sync from coreutils.
10563
10564         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
10565         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
10566         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
10567         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
10568         in the inet and nsl libraries.  Required on Solaris 5.7.
10569
10570 2005-10-01  Jim Meyering  <jim@meyering.net>
10571
10572         Sync from coreutils.
10573         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
10574         in the inet and nsl libraries.  Required on Solaris 5.7.
10575
10576 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
10577
10578         * lib/getdelim.c (getdelim): Remove unused variables.
10579
10580 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10581
10582         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
10583         so that the code works even with ancient cpp.  Portability problem
10584         with GCC 2.7.2.1 reported by Thomas M.Ott.
10585
10586 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10587
10588         * modules/regex (Depends-on): Add strcase.
10589
10590         * modules/gethostname (Licence): Change from GPL to LGPL, since
10591         gethostname.c is a trivial implementation of a standard library
10592         function.
10593         * modules/poll (License): Change from GPL to LGPL, since it's
10594         derived from LGPL code.
10595
10596 2005-09-27  Jim Meyering  <jim@meyering.net>
10597
10598         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
10599         HAVE_CONFIG_H.
10600
10601         * lib/intprops.h (signed_type_or_expr__): Define.
10602         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
10603         for unsigned types.
10604
10605 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10606
10607         * lib/verify.h (verify_expr): Remove, replacing with:
10608         (verify_true): New macro that returns true instead of void.
10609         (verify_type__): Remove.
10610         (verify): Use verify_true rather than verify_type__.
10611
10612 2005-09-26  Bruno Haible  <bruno@clisp.org>
10613
10614         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
10615         is necessary.
10616         (lib_SOURCES): Remove mbchar.c.
10617         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
10618         (Files): Add m4/mbrtowc.m4.
10619         * modules/mbiter: Likewise.
10620         * modules/mbuiter: Likewise.
10621
10622 2005-09-26  Bruno Haible  <bruno@clisp.org>
10623
10624         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
10625         compile mbchar.c if they are not both present.
10626         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
10627         * m4/mbiter.m4 (gl_MBITER): Likewise.
10628         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
10629         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
10630         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
10631
10632 2005-09-25  Jim Meyering  <jim@meyering.net>
10633
10634         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
10635         also uses socklen_t.
10636
10637 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
10638
10639         * lib/utimens.c (ENOSYS): Define if not already defined.
10640         (futimens): Support having a null PATH if the file descriptor
10641         is nonnegative.
10642
10643         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
10644         Remove.
10645         (__attribute): Define to empty unless GCC 3.1 or later.
10646         This works around a core dump on OpenBSD 3.4, which has GCC
10647         2.95.3, which dumps core when given __attribute__(()).  It also
10648         simplifies other tests, since we really don't want to bother with
10649         worrying about which ancient version of GCC supported what.
10650         Original problem reported by Yoann Vandoorselaere, with part of
10651         the fix suggested by Derek Price.
10652
10653 2005-09-24  Jim Meyering  <jim@meyering.net>
10654
10655         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
10656         so we can once again use a positive bitfield width of 1 -- now we
10657         don't have to explain why we were using a bitfield width of 2.
10658
10659 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
10660
10661         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
10662         and similarly for the other external symbols.  Problem reported
10663         by James Gallager.
10664
10665         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
10666         bug reported by Jim Meyering.
10667
10668         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
10669         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
10670         not needed, since socklen is a prerequisite module.
10671
10672 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
10673
10674         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
10675         Problem reported by Eric Blake.
10676         (getaddrinfo): Initialize se so that it's not garbage.
10677         Redo internal storage allocation so that it doesn't make unportable
10678         assumptions about alignment.
10679         Fix a memory leak.
10680
10681         * lib/utimens.c (futimens): Use futimesat if available.
10682         Prefer it to futimes since it doesn't have the futimes bug.
10683
10684         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
10685         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
10686         Instead, declare a function that returns a pointer to an array,
10687         and use verify_type__ to declare the size of the array.
10688         Problem and germ of a solution reported by Bruno Haible.
10689         (verify_type__): Use 2, not 1, for bitfield size, to avoid
10690         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
10691
10692 2005-09-23  Jim Meyering  <jim@meyering.net>
10693
10694         Sync from coreutils.
10695         Correct build failure (socklen_t not defined) on at least
10696         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
10697         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
10698
10699 2005-09-23  Jim Meyering  <jim@meyering.net>
10700
10701         * modules/getaddrinfo (Depends-on): Add socklen.
10702
10703 2005-09-23  Bruno Haible  <bruno@clisp.org>
10704
10705         * tests/test-verify.c: New file.
10706
10707 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10708
10709         Sync from coreutils.
10710
10711         * modules/argmatch (Depends-on): Add verify.
10712         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
10713         unistd-safer.
10714         * modules/save-cwd (Depends-on): Likewise.
10715
10716         * modules/openat (Files): Add lib/openat-die.c.
10717         (Depends-on): Remove error, exitfail.
10718         Add dirname.
10719
10720         * modules/verify: New file.
10721         * MODULES.html.sh (Diagnostics <assert.h>): New section,
10722         with "verify" module.
10723
10724 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10725
10726         Sync from coreutils.
10727
10728         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
10729         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
10730         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
10731         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
10732         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
10733         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
10734         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
10735         Don't bother checking for string.h, stdlib.h, unistd.h.
10736         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
10737         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
10738         module's job.
10739         * m4/jm-macros.m4 (gl_MACROS): Likewise.
10740         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
10741
10742         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
10743         (gl_GETDATE): Use it.
10744
10745         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
10746
10747 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10748
10749         Sync from coreutils.
10750
10751         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
10752         stat-time.h.
10753         * lib/argmatch.h: Include verify.h
10754         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
10755         (ARGMATCH_ASSERT): Remove; unused.
10756         * lib/canonicalize.c: Assume STDC_HEADERS.
10757         * lib/exclude.c: Include "strcase.h".
10758         * lib/regex_internal.h [!defined _LIBC]: Likewise.
10759         * lib/getusershell.c: Include stdio--.h rather than stdio.h
10760         and stdio-safer.h.
10761         (getusershell): Call fopen, not fopen_safer.
10762         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
10763         Do not include unistd-safer.h.
10764         (save_cwd): Don't call fd_safer; no longer needed
10765         now that we include fcntl--.h.
10766
10767         * lib/getdate.y (relative_time): New type.
10768         (RELATIVE_TIME_0): New constant.
10769         (parser_control): Use relative_time instead of doing it ourselves.
10770         (%union): Add new relative_time rel member.
10771         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
10772         Now typeless.
10773         (relunit, relunit_snumber): Now of type rel.
10774         (zone, rel, relunit, get_date): Adjust to above changes.
10775
10776         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
10777         Do not include unistd-safer.h.
10778         (getloadavg): Don't call fd_safer; no longer needed
10779         now that we include fcntl--.h.
10780
10781         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
10782         (make_dir_parents): Treat ENOSYS like EEXIST.
10783
10784         Improve quality of diagnostics on restore_cwd failure.
10785         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
10786         (make_dir_parents): Last arg is now int * (for errno), not bool *.
10787         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
10788         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
10789         each time through the loop.  Do not diagnose restore_cwd failure;
10790         that is the caller's job (and perhaps the caller does not care).
10791
10792         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
10793         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
10794         If the file already exists but is not a directory, don't bother
10795         to try to make its parents.
10796         Close potential file descriptor leak if we can't chdir("/") (!).
10797         Don't always return true if chdir($PWD) fails; return true only
10798         if the requested action was done successfully (except for the
10799         chdir($PWD)).
10800         Don't log final directory unless we actually made it.
10801         Refactor to avoid duplicate code to fix up permissions.
10802         Don't attempt to fix up parent permissions if chdir($PWD) fails.
10803
10804         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
10805         to make it a bit faster and (I hope) clearer.
10806         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
10807         Fix bug in formats like %2N.
10808
10809         * lib/verify.h: New file.
10810
10811 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10812
10813         Sync from coreutils.
10814         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
10815
10816 2005-09-22  Jim Meyering  <jim@meyering.net>
10817
10818         Sync from coreutils.
10819
10820         * m4/lstat.m4 (gl_FUNC_LSTAT):
10821         Use AC_LIBSOURCES to require lstat.c and lstat.h.
10822         Remove obsolete comment.
10823         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
10824         * m4/xstrtod.m4: Likewise.
10825
10826         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
10827
10828 2005-09-22  Jim Meyering  <jim@meyering.net>
10829
10830         Sync from coreutils.
10831
10832         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
10833
10834         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
10835         the .tm_year member, since otherwise gcc-4.0 would now warn about
10836         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
10837
10838         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
10839         order to avoid an unsuppressible warning from gcc on 64-bit systems.
10840
10841         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
10842         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
10843         when run in a time zone for which daylight savings time is in effect
10844         for the starting date.
10845
10846         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
10847         stop us from restricting permissions of just-created absolute-named
10848         directories.
10849         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
10850         to restore initial working directory.
10851         * lib/mkdir-p.c (make_dir_parents): New parameter:
10852         different_working_dir, to tell caller if/when we change the working
10853         directory and are unable to return to the initial one.
10854         * lib/mkdir-p.h (make_dir_parents): Update prototype.
10855         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
10856         `return false'.  This fixes a bug introduced on 2004-07-30.
10857
10858         * lib/openat.c (fdopendir): Be sure to close the supplied
10859         file descriptor before returning.  This makes our replacement
10860         implementation a little closer to Solaris's, where fdopendir
10861         ties the file descriptor to the returned DIR* pointer.
10862         * lib/openat.c (unlinkat): New function.
10863         * lib/openat.h (unlinkat): Add prototype.
10864         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
10865         (openat_restore_fail): Rename from openat_restore_die.
10866         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
10867
10868         Provide an alternative to exiting immediately upon save_cwd or
10869         restore_cwd failure.  Now, an application can arrange e.g.,
10870         to perform a longjump in that case.
10871         * lib/openat.c: Include dirname.h.
10872         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
10873         (rpl_openat, fdopendir, fstatat): Call openat_save_die
10874         and openat_restore_die rather than calling error directly.
10875         Don't include "error.h" or "exitfail.h"; they're no longer needed.
10876
10877         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
10878         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
10879         define.
10880
10881         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
10882         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
10883                             int utc, int nanoseconds);
10884         Background:
10885         date should not have to allocate a megabyte of virtual memory to
10886         handle a format argument like +%1048575T.  When implemented with
10887         strftime, it must allocate such a buffer, use strftime to fill it
10888         in, print it, then free it.
10889         With fprintftime, it simply prints everything and exits.
10890         With no need for memory allocation, that's one fewer way to fail.
10891         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
10892         optional field width, not before, so we accept %9:z, not %:9z.
10893         (my_strftime): Be sure to use L_('x') for literals.
10894
10895         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
10896         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
10897         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
10898         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
10899         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
10900         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
10901         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
10902         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
10903         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
10904         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
10905         * lib/xgethostname.c, lib/xreadlink.c:
10906         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
10907
10908         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
10909         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
10910         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
10911         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
10912         and don't include <sys/file.h>).
10913
10914 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
10915
10916         Sync from coreutils.
10917
10918         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
10919         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
10920         [!LDAV_DONE]: Avoid unused variable warning.
10921
10922 2005-09-21  Bruno Haible  <bruno@clisp.org>
10923
10924         * lib/unicodeio.h (unicode_to_mb): New declaration.
10925
10926 2005-09-20  Derek Price  <derek@ximbiot.com>
10927
10928         * lib/getaddrinfo.c: Don't include <netdb.h> included from
10929         getaddrinfo.h.
10930
10931 2005-09-20  Bruno Haible  <bruno@clisp.org>
10932
10933         * gnulib-tool: Remove trailing slashes from the values specified for
10934         --source-base, --m4-base, --tests-base, --aux-dir.
10935         Suggested by Simon Josefsson <jas@extundo.com>.
10936
10937 2005-09-20  Bruno Haible  <bruno@clisp.org>
10938
10939         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
10940         func_modules_to_filelist, func_import, func_create_testdir): Make all
10941         sorting results locale-independent, so that gnulib-cache.m4 doesn't
10942         change when gnulib-tool is invoked in a different locale.
10943
10944 2005-09-19  Simon Josefsson  <jas@extundo.com>
10945
10946         * m4/socklen.m4: Fix typo.
10947
10948 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10949
10950         Use a consistent style for including <config.h>.
10951         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
10952         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
10953         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
10954         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
10955         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
10956         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
10957         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
10958         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
10959         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
10960         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
10961         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
10962         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
10963         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
10964         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
10965         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
10966         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
10967         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
10968         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
10969         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
10970         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
10971         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
10972         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
10973         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
10974         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
10975         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
10976         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
10977         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
10978         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
10979         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
10980         lib/xstrtoumax.c, lib/yesno.c:
10981         Standardize inclusion of config.h.
10982         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
10983         lib/inttostr.h:  Removed inclusion of config.h from header files.
10984         * lib/inttostr.c:  Adjusted in-tree users.
10985         * lib/timespec.h: Remove superfluous warning to include config.h.
10986         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
10987         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
10988         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
10989         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
10990         config.h with HAVE_CONFIG_H.
10991
10992 2005-09-19  Jim Meyering  <jim@meyering.net>
10993
10994         * modules/pathmax (License): Change to LGPL.
10995
10996 2005-09-19  Derek Price  <derek@ximbiot.com>
10997
10998         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
10999
11000 2005-09-19  Bruno Haible  <bruno@clisp.org>
11001
11002         * gnulib-tool (import): Provide default for --tests-base.
11003
11004 2005-09-19  Bruno Haible  <bruno@clisp.org>
11005
11006         * doc/quote.texi: New file, extracted from gnulib.texi.
11007         * doc/ctime.texi: New file, extracted from gnulib.texi.
11008         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
11009         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
11010         * doc/gnulib.texi: Include them.
11011
11012 2005-09-18  Bruno Haible  <bruno@clisp.org>
11013
11014         Portability fix.
11015         * gnulib-tool (func_readlink): New function.
11016         (func_ln_if_changed): Use it.
11017
11018 2005-09-18  Bruno Haible  <bruno@clisp.org>
11019
11020         * gnulib-tool: Support --with-tests also with --import.
11021         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
11022         (func_import): Use variables $testsbase and $inctests. Emit a
11023         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
11024         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
11025         SUBDIRS += $testsdir.
11026         (func_create_testdir): Update.
11027
11028 2005-09-18  Bruno Haible  <bruno@clisp.org>
11029
11030         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
11031         instead of $dry_run.
11032         (func_cp_if_changed, func_mv_if_changed): Remove functions.
11033         (func_ln_if_changed): Don't handle dry-run here.
11034         (func_import): In dry-run mode, detect more precisely which actions
11035         would be performed, and don't use "...ing" verbs.
11036
11037 2005-09-18  Bruno Haible  <bruno@clisp.org>
11038
11039         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
11040         (func_import): Use join on two temporary files instead of three nested
11041         loops, in order to determine which files are new or old.
11042
11043 2005-09-18  Bruno Haible  <bruno@clisp.org>
11044
11045         * gnulib-tool (func_import): Comment out code that spits out the
11046         new files with --dry-run.
11047
11048 2005-09-18  Bruno Haible  <bruno@clisp.org>
11049
11050         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
11051
11052 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11053
11054         * lib/stat-time.h: New file.
11055         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
11056         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
11057         in a different way.
11058         (timespec_cmp): New function.
11059         * lib/utimecmp.c: Include stat-time.h.
11060         (SYSCALL_RESOLUTION): Depend on whether various struct stat
11061         members exist, not on the obsolescent ST_MTIM_NSEC.
11062         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
11063
11064 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11065
11066         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
11067
11068 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
11069
11070         * MODULES.html.sh (File system functions): Add stat-time.
11071         * modules/stat-time: New file.
11072         * modules/timespec (Files): Remove m4/st_mtim.m4; this
11073         is now done in a different way, by the stat-time module.
11074         * modules/utimecmp (Depends-on): Add stat-time.
11075
11076 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11077
11078         * m4/st_mtim.m4: Remove.  Superseded by...
11079         * m4/stat-time.m4: New file.
11080         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
11081         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
11082
11083 2005-09-15  Derek Price  <derek@ximbiot.com>
11084
11085         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
11086
11087 2005-09-15  Derek Price  <derek@ximbiot.com>
11088
11089         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
11090         * lib/regex_internal.c: Ditto, using this...
11091         (__GNUC_PREREQ): ...new macro.
11092         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
11093         using...
11094         (__GNUC_PREREQ): ...this new macro.
11095
11096         * lib/strstr.h: Include string.h. Define strstr as a macro here.
11097
11098 2005-09-15  Derek Price  <derek@ximbiot.com>
11099             Paul Eggert  <eggert@cs.ucla.edu>
11100
11101         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
11102         changes, consolidating in...
11103         * lib/regex_internal.h: ...this file.
11104
11105 2005-09-13  Jim Meyering  <jim@meyering.net>
11106
11107         * lib/canon-host.c: Filter through gnu indent and reword comments
11108         slightly.
11109         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
11110
11111 2005-09-13  Derek Price  <derek@ximbiot.com>
11112
11113         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
11114         failure.
11115         Reported by Jim Meyering  <jim@meyering.net>.
11116
11117 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11118
11119         * lib/base64.c: Typo.
11120         (base64_encode): Put b64str in initialized data section.
11121
11122 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
11123
11124         Merge glibc and coreutils changes into gnulib, plus a few
11125         extra fixes.
11126         * lib/md5.c: Use #error rather than a string.
11127         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
11128         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
11129         (__attribute__): Define to empty for non recent-GCC.
11130         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
11131         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
11132         Renamed from their non-__ counterparts, with new macros replacing
11133         them if not _LIBC.  Add __THROW attribute.
11134         (rol): Remove.
11135         (struct md5_ctx): Align buffer if using GCC.
11136         * lib/sha1.h (struct sha1_ctx): Likewise.
11137         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
11138         The old name was backwards.
11139         (NOTSWAP): Remove; not used.
11140         (rol): New macro, moved here from md5.h.
11141         (sha1_process_block): Remove a FIXME that doesn't make sense.
11142
11143 2005-09-12  Derek Price  <derek@ximbiot.com>
11144
11145         Return usable errors from canon-host.
11146         * lib/canon-host.h: New file.
11147         * lib/canon-host.c (canon_host): Wrap...
11148         (canon_host_r): ...this new function, which now relies exclusively on
11149         getaddrinfo.
11150         (ch_strerror): New function.
11151         (last_cherror): New global.
11152         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
11153         interface.
11154         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
11155         void *.
11156         (freeaddrinfo): Free ai->ai_canonname when set.
11157
11158 2005-09-12  Derek Price  <derek@ximbiot.com>
11159
11160         Make canon-host require getaddrinfo.
11161         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
11162         AC_LIBSOURCE canon-host.h.  Call...
11163         (gl_PREREQ_CANON_HOST): ...this new function, which requires
11164         gl_GETADDRINFO.
11165         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
11166
11167 2005-09-12  Derek Price  <derek@ximbiot.com>
11168
11169         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
11170         LGPL.
11171         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
11172
11173 2005-09-12  Derek Price  <derek@ximbiot.com>
11174
11175         * lib/gai_strerror.c: Include config.h when available.  Include
11176         getaddrinfo.h before other headers to test interface.
11177         Reported by Larry Jones <lawrence.jones@ugs.com>.
11178
11179 2005-09-12  Derek Price  <derek@ximbiot.com>
11180             Paul Eggert  <eggert@cs.ucla.edu>
11181
11182         * modules/glob (Files): Add glob-libc.h.
11183
11184 2005-09-12  Derek Price  <derek@ximbiot.com>
11185             Paul Eggert  <eggert@cs.ucla.edu>
11186
11187         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
11188         glob_.h, glob-libc.h.
11189         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
11190
11191 2005-09-12  Derek Price  <derek@ximbiot.com>
11192             Paul Eggert  <eggert@cs.ucla.edu>
11193
11194         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
11195         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
11196         protecting things that should be done only in gnulib contexts.
11197         * lib/glob_.h: New file, containing only the glob things needed for
11198         gnulib.
11199         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
11200         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
11201         (glob, globfree, glob_pattern_p): Now defined simply in terms of
11202         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
11203         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
11204         and to respect the namespace rules better.
11205
11206 2005-09-08  Simon Josefsson  <jas@extundo.com>
11207
11208         * modules/socklen: New file.
11209
11210 2005-09-08  Simon Josefsson  <jas@extundo.com>
11211
11212         * m4/socklen.m4: New file.
11213
11214 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11215
11216         * modules/utimens (Files): Add m4/utimbuf.m4, since
11217         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
11218         Reported by Sergey Poznyakoff.
11219
11220 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11221
11222         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
11223         definitions, since that's the preferred style in glibc.
11224         Fix a minor spacing issue, and update copyright notice to match
11225         glibc's.
11226
11227 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11228
11229         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
11230
11231 2005-09-06  Simon Josefsson  <jas@extundo.com>
11232
11233         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
11234         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
11235
11236 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11237
11238         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
11239         warning.
11240
11241 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11242
11243         * config/srclist.txt: Add glibc bug 1302.
11244
11245 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
11246
11247         Change bitset word type from unsigned int to unsigned long int,
11248         as this has better performance on typical 64-bit hosts.
11249         Port bitset code to hosts with unusual word sizes.
11250         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
11251         (build_collating_symbol):
11252         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
11253         argument is a bitset.  This is merely a style issue, but it makes
11254         it clearer that an entire array is expected.
11255         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
11256         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
11257         Port to the case where bitset_word is not the same as unsigned int.
11258         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
11259         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
11260         Likewise.
11261         * lib/regexec.c (check_dst_limits_calc_pos_1,
11262         check_subexp_matching_top):
11263         (build_trtable, group_nodes_into_DFAstates):
11264         Likewise.
11265         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
11266         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
11267         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
11268         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
11269         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
11270         * lib/regcomp.c (optimize_subexps, lower_subexp):
11271         Work even if bitset_word has holes in its bitwise representation.
11272         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
11273         * lib/regexec.c (check_dst_limits_calc_pos_1,
11274         check_subexp_matching_top):
11275         Likewise.
11276         * lib/regex_internal.c (re_string_reconstruct):
11277         Don't assume UCHAR_MAX == 255.
11278         * lib/regex_internal.h (bitset_set_all): Likewise.
11279         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
11280         All uses changed.
11281         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
11282         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
11283         All uses changed.
11284         (BITSET_WORD_MAX): New macro.
11285         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
11286         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
11287         (bitset_empty, bitset_copy):
11288         Prefer sizeof (bitset) to multiplying it out ourselves.
11289         (bitset_not_merge): Remove; unused.
11290         (bitset_contain): Return bool, not unsigned int with one bit on.
11291         All callers changed.
11292         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
11293         alignment than re_node_set; do this by defining a new internal
11294         type struct dests_alloc and using it to allocate memory.
11295
11296 2005-09-05  Bruno Haible  <bruno@clisp.org>
11297
11298         * gnulib-tool (func_import): Fix comparison in handling of symbolic
11299         links.
11300
11301 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
11302
11303         * modules/size_max (Makefile.am): Add size_max.h
11304
11305 2005-09-04  Derek Price  <derek@ximbiot.com>
11306
11307         * gnulib-tool (func_import): Fix reversed $symbolic logic.
11308
11309 2005-09-03  Simon Josefsson  <jas@extundo.com>
11310
11311         * gnulib-tool: Fix typo.
11312
11313 2005-09-03  Simon Josefsson  <jas@extundo.com>
11314
11315         * config/srclist.txt: Add glibc bug 1293.
11316
11317 2005-09-03  Derek Price  <derek@ximbiot.com>
11318
11319         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
11320         From Larry Jones <lawrence.jones@ugs.com>.
11321
11322 2005-09-02  Simon Josefsson  <jas@extundo.com>
11323
11324         * modules/socklen: New file.
11325
11326 2005-09-02  Simon Josefsson  <jas@extundo.com>
11327
11328         * modules/havelib: New module.
11329
11330         * modules/gettext, modules/iconv, modules/lock, modules/readline:
11331         Use havelib.
11332
11333 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
11334
11335         Check for arithmetic overflow when calculating sizes, to prevent
11336         some buffer-overflow issues.  These patches are conservative, in the
11337         sense that when I couldn't determine whether an overflow was possible,
11338         I inserted a run-time check.
11339         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
11340         macros.
11341         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
11342         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
11343         (re_xnrealloc, re_x2nrealloc): New inline functions.
11344         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
11345         parse_bracket_exp):
11346         (build_equiv_class, build_charclass): Check for arithmetic overflow
11347         in size expression calculations.
11348         * lib/regex_internal.c (re_string_realloc_buffers):
11349         (build_wcs_upper_buffer, re_node_set_add_intersect):
11350         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
11351         (re_dfa_add_node, register_state): Likewise.
11352         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
11353         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
11354         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
11355         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
11356
11357 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
11358
11359         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
11360         m4/ulonglong.m4.  Problem reported by Martin Lambers.
11361
11362 2005-09-02  Bruno Haible  <bruno@clisp.org>
11363
11364         Support for lib vs. lib64 distinction on biarch platforms.
11365         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
11366         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
11367         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
11368
11369 2005-09-02  Bruno Haible  <bruno@clisp.org>
11370
11371         * gnulib-tool (import): In the other first-use case, provide defaults
11372         as well.
11373
11374 2005-09-02  Bruno Haible  <bruno@clisp.org>
11375
11376         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
11377         patches not yet found in the latest gettext release.
11378
11379 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11380
11381         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
11382         to avoid a collision with bits/local_lim.h in glibc.
11383         All uses changed.  Problem reported by Dmitry V. Levin in
11384         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
11385
11386         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
11387         bugs in int versus size_t comparisons.
11388         (re_string_context_at): Fix bug where the code assumed that
11389         Idx is signed.
11390
11391         Use bool where appropriate.
11392         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
11393         All callers changed.
11394         (calc_eclosure_iter): Likewise, for ROOT arg.
11395         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
11396         (build_charclass_op): Likewise, for NON_MATCH arg.
11397         * lib/regex_internal.c (re_string_allocate, re_string_construct):
11398         (re_string_construct_common): Likewise, for ICASE arg.
11399         * lib/regexec.c (re_search_2_stub, re_search_stub):
11400         Likewise, for RET_LEN arg.
11401         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
11402         (set_regs): Likewise, for FL_BACKTRACK arg.
11403         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
11404         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
11405         (calc_eclosure_iter, parse_bracket_exp):
11406         Use bool for internal variables that are booleans.
11407         * lib/regexec.c (re_search_internal, check_matching,
11408         proceed_next_node):
11409         (set_regs, build_sifted_states, sift_states_bkref):
11410         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
11411         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11412         (find_collation_sequence_value):
11413         Likewise.
11414         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
11415         (re_node_set_compare):
11416         Return bool, not int. All callers changed.
11417         * lib/regexec.c (check_halt_node_context, check_dst_limits):
11418         (build_trtable, check_node_accept): Likewise.
11419         * lib/regex_internal.h: Include stdbool.h.
11420
11421         Fix bugs uncovered when converting to bool.
11422         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
11423         failure instead of charging ahead blindly.
11424         * lib/regex_internal.c (register_state): Likewise.
11425         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
11426         for freeing internal storage.
11427         (group_nodes_into_DFA_states): Use unsigned int, not int, for
11428         bitset pieces used as boolean, to avoid undefined behavior
11429         on hosts that do int overflow checking.
11430
11431 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11432
11433         * config/srclist.txt: Add glibc bugs 1285-1287.
11434
11435 2005-09-01  Jim Meyering  <jim@meyering.net>
11436
11437         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
11438         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
11439         Require gl_STAT_MACROS, too.
11440
11441 2005-09-01  Bruno Haible  <bruno@clisp.org>
11442
11443         * gnulib-tool (import): In the first-use case, provide defaults.
11444
11445 2005-09-01  Bruno Haible  <bruno@clisp.org>
11446
11447         * gnulib-tool (func_import): Remove the .tmp files.
11448
11449 2005-09-01  Bruno Haible  <bruno@clisp.org>
11450
11451         * gnulib-tool (func_import): Fix handling of symbolic links.
11452
11453 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11454
11455         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
11456         old glibc regex code mishandles strings longer than 2**31 bytes.
11457         This patch fixes this when the regex code is used in gnulib
11458         (i.e., outside glibc).
11459
11460         This patch should not affect the use of the regex code inside
11461         glibc.  No doubt this problem also needs to be handled for glibc
11462         as well, but the result will be an incompatible change to the
11463         glibc ABI, and the old ABI will have to be supported too.  That
11464         can be the the subject for another patch.
11465
11466         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
11467         governing whether the rest of this patch is active.  By default,
11468         the macro is disabled and the patch has no effect.
11469         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
11470         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
11471         (struct re_pattern_buffer, re_search, re_search_2, re_match):
11472         (re_match_2, re_set_registers): Use the new types.
11473         * lib/regex_internal.h (Idx, re_hashval_t): New types.
11474         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
11475         New macros.
11476         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
11477         (re_string_context_at, bin_tree_t, re_dfastate_t):
11478         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
11479         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
11480         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
11481         (re_string_char_size_at, re_string_wchar_at):
11482         (re_string_elem_size_at):
11483         Use the new types and macros to port to 64-bit hosts.
11484         Use unsigned types for internal values, so that the code
11485         mostly works even for arrays larger than SSIZE_MAX.
11486         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
11487         (search_duplicated_node, calc_eclosure_iter, fetch_number):
11488         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
11489         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
11490         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
11491         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
11492         (calc_inveclosure, parse_dup_op, build_range_exp):
11493         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
11494         (fetch_number, create_token_tree, mark_opt_subexp):
11495         Likewise.
11496         * lib/regex_internal.c (re_string_construct_common,
11497         create_ci_newstate):
11498         (create_cd_newstate, re_string_allocate, re_string_construct):
11499         (re_string_realloc_buffers, build_wcs_upper_buffer):
11500         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11501         (re_string_reconstruct, re_string_peek_byte_case):
11502         (re_string_fetch_byte_case, re_string_context_at):
11503         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11504         (re_node_set_init_copy, re_node_set_add_intersect):
11505         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11506         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11507         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11508         (re_acquire_state, re_acquire_state_context, register_state):
11509         Likewise.
11510         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
11511         search_cur_bkref_entry):
11512         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
11513         (re_search_internal, re_search_2_stub, re_search_stub)
11514         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
11515         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
11516         (update_cur_sifted_state, check_dst_limits):
11517         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
11518         (check_subexp_limits, sift_states_bkref, merge_state_array):
11519         (check_subexp_matching_top, get_subexp, get_subexp_sub):
11520         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
11521         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11522         (expand_bkref_cache, check_node_accept_bytes):
11523         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
11524         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
11525         (acquire_init_state_context, check_halt_node_context):
11526         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
11527         (sift_states_backward, clean_state_log_if_needed):
11528         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
11529         (find_recover_state, transit_state_sb, transit_state_mb):
11530         (transit_state_bkref, build_trtable, match_ctx_clean):
11531         Likewise.
11532         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
11533         to work around an assumption that REG_MISSING is negative.
11534
11535         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
11536         (seek_collating_symbol_entry) [defined _LIBC]:
11537         (lookup_collation_sequence_value) [defined _LIBC]:
11538         (build_range_exp, build_collating_symbol) [defined _LIBC]:
11539         Use prototypes rather than old-style function definitions.
11540         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
11541         (transit_state_sb) [0]:
11542         (find_collation_sequence_value) [defined _LIBC]: Likewise.
11543
11544         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
11545         rm_eo.
11546
11547         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
11548         (optimize_subexps, lower_subexp):
11549         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
11550         since the signed shift might overflow.  Use 1u<<31 instead.
11551         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
11552         Likewise.
11553         * lib/regexec.c (check_dst_limits_calc_pos_1,
11554         check_subexp_matching_top): Likewise.
11555
11556         * lib/regcomp.c (optimize_subexps, lower_subexp):
11557         Use CHAR_BIT rather than 8, for clarity.
11558         * lib/regexec.c (check_dst_limits_calc_pos_1):
11559         (check_subexp_matching_top): Likewise.
11560         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
11561         have to worry about portability issues when shifting it left.
11562         Remove no-longer-needed test for table_size > 0.
11563         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
11564         in a word, as the resulting behavior is undefined.
11565         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
11566         in one case, a <= should have been an <, and in another case the
11567         whole test was missing.
11568         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
11569         the standard name CHAR_BIT.
11570         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
11571         this is not true on one's complement and signed-magnitude hosts.
11572
11573         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
11574         next_last_offset.
11575         (struct re_dfa_t): Remove unused member states_alloc.
11576         * lib/regcomp.c (init_dfa): Don't initialize unused members.
11577
11578 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11579
11580         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
11581         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
11582         and large-file glibc and in 32-bit large-file Solaris.
11583
11584 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11585
11586         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
11587         lengths fit in regoff_t; this isn't true if regoff_t is the same
11588         width as size_t.
11589         * lib/regex.c (re_search_internal): 5th arg is LAST_START
11590         (= START + RANGE) instead of RANGE.  This avoids overflow
11591         problems when regoff_t is the same width as size_t.
11592         All callers changed.
11593         (re_search_2_stub): Check for overflow when adding the
11594         sizes of the two strings.
11595         (re_search_stub): Check for overflow when adding START
11596         to RANGE; if it occurs, substitute the extreme value.
11597
11598 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11599
11600         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
11601
11602 2005-08-31  Jim Meyering  <jim@meyering.net>
11603
11604         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
11605         a pointer-to-const.
11606         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
11607         (register_state): Likewise.
11608         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
11609         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
11610         (group_nodes_into_DFAstates): Likewise.
11611
11612 2005-08-31  Jim Meyering  <jim@meyering.net>
11613
11614         * check-module: Add a FIXME comment.
11615
11616 2005-08-31  Eric Blake  <ebb9@byu.net>
11617
11618         * modules/unistd-safer (Files): Add unistd--.h.
11619         * modules/stdio-safer (Files): Add stdio--.h.
11620
11621 2005-08-31  Derek Price  <derek@ximbiot.com>
11622
11623         * lib/getdelim.c (getdelim): Return EOF on EOF.
11624         Reported by Larry Jones <lawrence.jones@ugs.com>.
11625
11626 2005-08-31  Bruno Haible  <bruno@clisp.org>
11627
11628         Avoid unnecessary diffs in the generated lib/Makefile.am.
11629         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
11630         the generated files.
11631         (func_import): Don't set cmd.
11632
11633 2005-08-31  Bruno Haible  <bruno@clisp.org>
11634
11635         * lib/strstr.c: Include <stddef.h>, for NULL.
11636         * lib/strcasestr.c: Likewise.
11637         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
11638
11639 2005-08-31  Bruno Haible  <bruno@clisp.org>
11640
11641         * gnulib-tool: New option --macro-prefix.
11642         (func_import): Use macro_prefix.
11643         (import): Handle option --macro-prefix.
11644
11645 2005-08-31  Bruno Haible  <bruno@clisp.org>
11646
11647         * gnulib-tool (import): Rename most ac_* variables to cached_*.
11648         Also use new variables cached_lgpl, cached_libtool.
11649
11650 2005-08-31  Bruno Haible  <bruno@clisp.org>
11651
11652         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
11653         always instantiating them.
11654
11655 2005-08-31  Bruno Haible  <bruno@clisp.org>
11656
11657         * gnulib-tool (func_import): Read the previous cached settings
11658         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
11659         earlier added by gnulib but are now dropped. Warn when a gnulib file
11660         overwrites a non-gnulib file.
11661
11662 2005-08-31  Bruno Haible  <bruno@clisp.org>
11663
11664         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
11665         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
11666         projects that don't keep autogenerated files in CVS. Put into
11667         actioncmd only the specified modules, not the transitive closure.
11668
11669 2005-08-31  Bruno Haible  <bruno@clisp.org>
11670
11671         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
11672         Create directories that shall be filled.
11673         (import): Don't look for gl_* macros in configure.ac. Recurse across
11674         all directories containing a gnulib-cache.m4 files, if meaningful.
11675
11676 2005-08-31  Bruno Haible  <bruno@clisp.org>
11677
11678         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
11679         (import): Set seen_libtool when we see gl_LIBTOOL.
11680
11681 2005-08-31  Bruno Haible  <bruno@clisp.org>
11682
11683         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
11684         declaration macro definitions from generated gnulib.m4.
11685
11686 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
11687
11688         * lib/iconvme.h: Add prototype for iconv_alloc.
11689
11690 2005-08-29  Simon Josefsson  <jas@extundo.com>
11691
11692         * lib/iconvme.c: Fix errno.
11693
11694 2005-08-29  Bruno Haible  <bruno@clisp.org>
11695
11696         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
11697         that it works when the directory contains spaces.
11698
11699 2005-08-29  Bruno Haible  <bruno@clisp.org>
11700
11701         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
11702
11703 2005-08-29  Bruno Haible  <bruno@clisp.org>
11704
11705         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
11706         Emit more advice.
11707
11708 2005-08-29  Bruno Haible  <bruno@clisp.org>
11709         and Stepan Kasal  <kasal@ucw.cz>
11710
11711         * check-module: If more parameters are given, check each of them
11712         separately; add more exceptions, as noted by Jim Meyering.
11713         (check_module): New procedure.
11714         (%exempt_header): Now contains all exceptions.
11715
11716 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
11717
11718         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
11719
11720 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
11721
11722         * lib/iconvme.c: Split iconv_string into iconv_alloc.
11723
11724 2005-08-28  Bruno Haible  <bruno@clisp.org>
11725
11726         * m4/gnulib-tool.m4: New file.
11727
11728 2005-08-27  Jim Meyering  <jim@meyering.net>
11729
11730         * modules/unistd-safer (Files): Add pipe-safer.c.
11731         * modules/fcntl-safer (Files): Add creat-safer.c.
11732
11733 2005-08-27  Jim Meyering  <jim@meyering.net>
11734
11735         * m4/stdlib-safer.m4: New file.  From coreutils.
11736         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
11737         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
11738         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
11739         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
11740         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
11741
11742 2005-08-27  Jim Meyering  <jim@meyering.net>
11743
11744         * lib/fopen-safer.c: Merge minor changes from coreutils.
11745         * lib/dup-safer.c: Likewise.
11746         * lib/fd-safer.c: Likewise.
11747
11748         Merge from coreutils.
11749         * lib/stdio--.h: New file.
11750         * lib/stdlib--.h: New file.
11751         * lib/mkstemp-safer.c: New file.
11752
11753         GNU tar needs these.
11754         * lib/pipe-safer.c: New file.
11755         * lib/creat-safer.c: New file.
11756         * lib/fcntl--.h (creat): Define to creat_safer.
11757         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
11758         * lib/unistd--.h (pipe): Define to pipe_safer.
11759         * lib/unistd-safer.h: Declare pipe_safer.
11760
11761 2005-08-26  Simon Josefsson  <jas@extundo.com>
11762
11763         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
11764         Haible <bruno@clisp.org>.
11765
11766 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
11767
11768         * lib/regex_internal.h: Remove all references to
11769         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
11770         or better.
11771         (bitset_not, bitset_merge, bitset_not_merge):
11772         (bitset_mask, re_string_allocate, re_string_construct):
11773         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
11774         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
11775         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
11776         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
11777         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11778         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11779         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
11780         (re_acquire_state_context):
11781         Remove unnecessary forward decls.
11782         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
11783         Put __attribute at function definition,
11784         now that the function decl has been removed.
11785         * lib/regex_internal.c (re_string_peek_byte_case):
11786         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
11787         Likewise.
11788
11789 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
11790
11791         * m4/regex.m4: Add AC_PREREQ(2.50).
11792         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
11793
11794 2005-08-25  Simon Josefsson  <jas@extundo.com>
11795
11796         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
11797         __fsetlocking.
11798
11799 2005-08-25  Simon Josefsson  <jas@extundo.com>
11800
11801         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
11802         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
11803         GLIBC specific code.
11804
11805 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11806
11807         Make regex safe for g++.  This fixes one real bug (an "err"
11808         that should have been "*err").  g++ problem reported by
11809         Sam Steingold.
11810         * lib/regex_internal.h (re_calloc): New macro, consistent with
11811         re_malloc etc.  All callers of calloc changed to use re_calloc.
11812         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
11813         not int.  All callers changed.
11814         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
11815         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
11816         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
11817         (find_recover_state): Change "err" to "*err"; this fixes what
11818         appears to be a real bug.
11819         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
11820         versus int.
11821
11822 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11823
11824         * modules/regex (Depends-on): Add malloc, since the code
11825         assumes that !malloc(0) means failure.
11826
11827 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11828
11829         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
11830
11831         alloca modernization/simplification for regex.
11832         * lib/regex.c: Remove portability cruft for alloca.  This no longer
11833         needs to be at the start of the file, and can be moved into
11834         regex_internal.h and simplified.
11835         * lib/regex_internal.h: Include <alloca.h>.
11836         (__libc_use_alloca) [!defined _LIBC]: New macro.
11837         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
11838         now works outside glibc.
11839
11840 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11841
11842         * config/srclist.txt: Add glibc bugs 1241, 1245.
11843
11844 2005-08-25  Jim Meyering  <jim@meyering.net>
11845
11846         * lib/open-safer.c: Include <config.h>.
11847         Otherwise, we'd lose LARGEFILE support in any file using
11848         e.g. "fcntl--.h"
11849
11850 2005-08-25  Bruno Haible  <bruno@clisp.org>
11851
11852         * m4/minmax.m4: Require autoconf 2.52.
11853         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
11854         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
11855         alternatives of translit over the alphabet.
11856         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
11857
11858 2005-08-24  Simon Josefsson  <jas@extundo.com>
11859
11860         * tests/test-getpass.c: New file.
11861
11862 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11863
11864         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
11865         for GNU regex features.
11866
11867 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11868
11869         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
11870         * lib/regex.h (regerror): Likewise.
11871
11872         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
11873         requires this.  (The code never needed it.)
11874
11875         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
11876         All uses of recently-renamed identifiers changed to use the new,
11877         POSIX-compliant names.  The code will build and run just fine
11878         without these changes, but it's better to eat our own dog food
11879         and use the standard-conforming names.
11880
11881         * lib/regex.h: Fix a multitude of POSIX name space violations.
11882         These changes have an effect only for programs that define
11883         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
11884         do not change anything for programs compiled in the normal way.
11885         Also, there is no effect on the ABI.
11886
11887         (_REGEX_SOURCE): New macro.
11888         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
11889         defined and _GNU_SOURCE is not; this fixes a name space violation.
11890
11891         Rename the following macros to obey POSIX requirements.
11892         The old names are still visible as macros if _REGEX_SOURCE is defined.
11893         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
11894         RE_BACKSLASH_ESCAPE_IN_LISTS.
11895         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
11896         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
11897         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
11898         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
11899         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
11900         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
11901         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
11902         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
11903         (REG_INTERVALS): renamed from RE_INTERVALS.
11904         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
11905         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
11906         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
11907         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
11908         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
11909         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
11910         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
11911         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
11912         RE_UNMATCHED_RIGHT_PAREN_ORD.
11913         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
11914         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
11915         (REG_DEBUG): renamed from RE_DEBUG.
11916         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
11917         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
11918         unusual, since we can't clash with the POSIX REG_ICASE.
11919         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
11920         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
11921         (REG_NO_SUB): renamed from RE_NO_SUB.
11922         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
11923         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
11924         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
11925         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
11926         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
11927         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
11928         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
11929         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
11930         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
11931         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
11932         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
11933         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
11934         RE_SYNTAX_POSIX_MINIMAL_BASIC.
11935         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
11936         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
11937         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
11938         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
11939         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
11940         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
11941         (REG_FIXED): Renamed from REGS_FIXED.
11942         (REG_NREGS): Renamed from RE_NREGS.
11943
11944         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
11945         of other REG_* macros, since POSIX says the user is allowed to
11946         #undef these macros selectively.
11947
11948         (reg_errcode_t): Update comment stating what other tables need
11949         to be consistent.
11950
11951         Rename the following enum values to obey POSIX requirements.
11952         The old names are still visible as macros.
11953         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
11954         is not defined, since GNU is supposed to be a superset of POSIX as
11955         much as possible, and since we want reg_errcode_t to be a signed
11956         type for implementation consistency.
11957         (_REG_NOERROR): Renamed from REG_NOERROR.
11958         (_REG_NOMATCH): Renamed from REG_NOMATCH.
11959         (_REG_BADPAT): Renamed from REG_BADPAT.
11960         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
11961         (_REG_ECTYPE): Renamed from REG_ECTYPE.
11962         (_REG_EESCAPE): Renamed from REG_EESCAPE.
11963         (_REG_ESUBREG): Renamed from REG_ESUBREG.
11964         (_REG_EBRACK): Renamed from REG_EBRACK.
11965         (_REG_EPAREN): Renamed from REG_EPAREN.
11966         (_REG_EBRACE): Renamed from REG_EBRACE.
11967         (_REG_BADBR): Renamed from REG_BADBR.
11968         (_REG_ERANGE): Renamed from REG_ERANGE.
11969         (_REG_ESPACE): Renamed from REG_ESPACE.
11970         (_REG_BADRPT): Renamed from REG_BADRPT.
11971         (_REG_EEND): Renamed from REG_EEND.
11972         (_REG_ESIZE): Renamed from REG_ESIZE.
11973         (_REG_ERPAREN): Renamed from REG_ERPAREN.
11974         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
11975         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
11976         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
11977         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
11978
11979         (_REG_RE_NAME, _REG_RM_NAME): New macros.
11980         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
11981         changed.  But support the old name if the new one is not defined
11982         and if _REGEX_SOURCE.
11983
11984         Change the following member names in struct re_pattern_buffer.
11985         The old names are still supported if !_REGEX_SOURCE.
11986         The new names are always supported, regardless of _REGEX_SOURCE.
11987         (re_buffer): Renamed from buffer.
11988         (re_allocated): Renamed from allocated.
11989         (re_used): Renamed from used.
11990         (re_syntax): Renamed from syntax.
11991         (re_fastmap): Renamed from fastmap.
11992         (re_translate): Renamed from translate.
11993         (re_can_be_null): Renamed from can_be_null.
11994         (re_regs_allocated): Renamed from regs_allocated.
11995         (re_fastmap_accurate): Renamed from fastmap_accurate.
11996         (re_no_sub): Renamed from no_sub.
11997         (re_not_bol): Renamed from not_bol.
11998         (re_not_eol): Renamed from not_eol.
11999         (re_newline_anchor): Renamed from newline_anchor.
12000
12001         Change the following member names in struct re_registers.
12002         The old names are still supported if !_REGEX_SOURCE.
12003         The new names are always supported, regardless of _REGEX_SOURCE.
12004         (rm_num_regs): Renamed from num_regs.
12005         (rm_start): Renamed from start.
12006         (rm_end): Renamed from end.
12007
12008         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
12009         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
12010         Prepend __ to parameter names.
12011
12012         Undo yesterday's changes.
12013
12014 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
12015
12016         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
12017         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
12018         lib/regex.c.
12019
12020 2005-08-24  Jim Meyering  <jim@meyering.net>
12021
12022         Sync from coreutils.
12023         * m4/fcntl-safer.m4: New file.
12024
12025         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
12026         and object files for this module.
12027
12028 2005-08-24  Jim Meyering  <jim@meyering.net>
12029
12030         Sync from coreutils.
12031         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
12032
12033 2005-08-24  Jim Meyering  <jim@meyering.net>
12034
12035         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
12036         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
12037
12038 2005-08-24  Jim Meyering  <jim@meyering.net>
12039
12040         * modules/fcntl-safer: New module.
12041         * modules/fts (Depends-on): Add fcntl-safer.
12042         * MODULES.html.sh (File descriptor based Input/Output):
12043         Add fcntl-safer.
12044
12045 2005-08-24  Bruno Haible  <bruno@clisp.org>
12046
12047         Support for unit test modules.
12048         * modules/README: Mention tests modules.
12049         * modules/TEMPLATE-TESTS: New file.
12050         * gnulib-tool: New options --extract-tests-module, --with-tests and
12051         --tests-base (unused for the moment).
12052         (testsbase, inctests): New variables.
12053         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
12054         (func_verify_module): Exclude TEMPLATE-TESTS.
12055         (func_verify_nontests_module, func_verify_tests_module): New functions.
12056         (func_get_dependencies): Add implicit dependency for tests modules.
12057         (func_get_tests_module): New function.
12058         (func_modules_transitive_closure): When --with-tests was specified,
12059         include the unit tests as well, unless explicitly avoided.
12060         (func_emit_lib_Makefile_am): Ignore the tests modules here.
12061         (func_emit_tests_Makefile_am): New function.
12062         (func_create_testdir): When --with-tests was specified, emit a
12063         tests/ directory.
12064         * MODULES.html.sh (Future developments): Update.
12065
12066 2005-08-24  Bruno Haible  <bruno@clisp.org>
12067
12068         * modules/tls-tests: New file.
12069         * tests/test-tls.c: New file, from GNU gettext.
12070
12071 2005-08-24  Bruno Haible  <bruno@clisp.org>
12072
12073         * modules/lock-tests: New file.
12074         * tests/test-lock.c: New file, from GNU gettext.
12075
12076 2005-08-24  Bruno Haible  <bruno@clisp.org>
12077
12078         * lib/lock.h: Add multiple inclusion guard.
12079         * lib/tls.h: Add multiple inclusion guard.
12080
12081 2005-08-24  Bruno Haible  <bruno@clisp.org>
12082
12083         * gnulib-tool: Add support for the --aux-dir option to
12084         --create-testdir, --create-megatestdir, --test, --megatest.
12085         (func_create_testdir, func_create_megatestdir): Optionally emit a
12086         AC_CONFIG_AUX_DIR directive.
12087         (create-testdir, create-megatestdir, test, megatest): Provide a
12088         default value for $auxdir.
12089
12090 2005-08-24  Bruno Haible  <bruno@clisp.org>
12091
12092         * gnulib-tool (import): Use compound statement instead of subshell
12093         where possible.
12094
12095 2005-08-24  Bruno Haible  <bruno@clisp.org>
12096
12097         * gnulib-tool (import): Change --aux-dir default to "build-aux".
12098
12099 2005-08-24  Bruno Haible  <bruno@clisp.org>
12100
12101         * gnulib-tool (func_version): Update.
12102
12103 2005-08-24  Bruno Haible  <bruno@clisp.org>
12104
12105         * gnulib-tool (func_import, func_create_testdir,
12106         func_create_megatestdir): Quote all autoconf macro arguments.
12107
12108 2005-08-24  Bruno Haible  <bruno@clisp.org>
12109
12110         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
12111         option --force, because --force causes the aclocal.m4 of each
12112         subdirectory to be newer than the corresponding config.h.in.
12113
12114 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12115
12116         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
12117         All contents moved to gl_REGEX.
12118         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
12119         assume that it does.
12120
12121 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12122
12123         * lib/regex.h (REG_NOSYS)
12124         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
12125         Define, since POSIX requires it as of 2001.
12126         (_REG_ENOSYS)
12127         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
12128         New private symbol, used to keep the enum signed in all cases.
12129         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
12130         Youngman in
12131         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
12132
12133         * lib/regex_internal.c (re_string_skip_chars, register_state):
12134         (calc_state_hash):
12135         Remove forward decls; no longer needed now that we use prototypes.
12136         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
12137         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
12138         (clean_state_log_if_needed): Likewise.
12139
12140 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
12141
12142         * config/srclist.txt: Add glibc bugs 1231-1233.
12143
12144 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12145
12146         Fix problems reported by Sam Steingold in
12147         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
12148         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
12149         assumed that reg_errcode_t is a signed type, which is not
12150         necessarily true if _XOPEN_SOURCE is not defined.
12151         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
12152         since some compilers warn about it otherwise.
12153
12154 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12155
12156         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
12157         (init_word_char, create_initial_state, duplicate_node_closure):
12158         (fetch_token, peek_token_bracket, build_range_exp):
12159         (build_collating_symbol): Remove forward decls; no longer needed
12160         now that we use prototypes.
12161
12162         * lib/regcomp.c:
12163         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
12164         (re_compile_fastmap_iter, regcomp, regerror, regfree):
12165         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
12166         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
12167         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
12168         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
12169         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
12170         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
12171         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
12172         (build_range_exp, build_collating_symbol, parse_bracket_exp):
12173         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
12174         (build_charclass, build_charclass_op, fetch_number, create_tree):
12175         (create_token_tree, mark_opt_subexp, duplicate_tree):
12176         Use prototypes rather than old-style definitions.
12177
12178         * lib/regex_internal.c:
12179         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
12180         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
12181         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
12182         (re_string_reconstruct, re_string_peek_byte_case):
12183         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
12184         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
12185         (re_node_set_init_copy, re_node_set_add_intersect):
12186         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
12187         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
12188         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
12189         (re_acquire_state, re_acquire_state_context, register_state):
12190         (create_ci_newstate, create_cd_newstate, free_state):
12191         Likewise.
12192         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
12193         re_search_2):
12194         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
12195         (re_search_internal, prune_impossible_nodes):
12196         (acquire_init_state_context, check_matching, static):
12197         (check_halt_node_context, check_halt_state_context, proceed_next_node):
12198         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
12199         (update_regs, sift_states_backward, build_sifted_states):
12200         (clean_state_log_if_needed, merge_state_array):
12201         (update_cur_sifted_state, add_epsilon_src_nodes):
12202         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
12203         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
12204         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
12205         (find_recover_state, check_subexp_matching_top, transit_state_mb):
12206         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
12207         (check_arrival, check_arrival_add_next_nodes):
12208         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
12209         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
12210         (check_node_accept_bytes, check_node_accept, extend_buffers):
12211         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
12212         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
12213         (sift_ctx_init):
12214         Likewise.
12215
12216         * lib/regex_internal.h:
12217         (re_string_allocate, re_string_construct, re_string_reconstruct):
12218         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
12219         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
12220         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
12221         (re_string_context_at, re_string_peek_byte_case):
12222         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
12223         is defined, since we now use prototypes always.
12224
12225         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
12226         C89 or better.  All uses removed.
12227
12228 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12229
12230         * config/srclist.txt: Add glibc bugs 1220-1227.
12231
12232 2005-08-20  Jim Meyering  <jim@meyering.net>
12233
12234         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
12235         of unused local, dfa.
12236
12237 2005-08-20  Bruno Haible  <bruno@clisp.org>
12238
12239         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
12240
12241 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12242
12243         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
12244         (re_node_set_insert_last, re_dfa_add_node):
12245         Rename local variables to avoid GCC shadowing warnings.
12246
12247 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12248
12249         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
12250         [defined lint]: Suppress bogus uninitialized-variable warnings.
12251
12252         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
12253         and let the caller return REG_ESPACE if out of space.  This
12254         removes an uninitialied-variable warning with GCC 4.0.1, and also
12255         avoids taking the address of a local variable.  All callers
12256         changed.
12257
12258 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12259
12260         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
12261         $LIBCSRC/posix/regexec.c.
12262         Add glibc bug 1217 for regcomp.c.
12263
12264 2005-08-19  Jim Meyering  <jim@meyering.net>
12265
12266         * lib/regexec.c (proceed_next_node): Redo local variables to
12267         avoid GCC shadowing warnings.
12268
12269 2005-08-18  Bruno Haible  <bruno@clisp.org>
12270
12271         * lib/strstr.c (strstr): Fix return value in multibyte case.
12272         * lib/strcasestr.c (strcasestr): Likewise.
12273
12274 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12275
12276         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
12277
12278 2005-08-17  Jim Meyering  <jim@meyering.net>
12279
12280         Make the %s format (seconds since the epoch) work for a negative
12281         number and when used with a zero-padded field width, e.g. %015s.
12282
12283         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
12284         label so that it precedes the code to set `digits'.  Otherwise,
12285         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
12286         print `00-22'.  Now, it prints `-0022', as it should.
12287
12288 2005-08-17  Bruno Haible  <bruno@clisp.org>
12289
12290         * modules/strstr (Files): Add m4/mbrtowc.m4.
12291         (Depends-on): Add mbuiter.
12292
12293 2005-08-17  Bruno Haible  <bruno@clisp.org>
12294
12295         * modules/strcasestr: New file.
12296         * MODULES.html.sh (String handling, based on ANSI C 89): Add
12297         strcasestr.
12298
12299 2005-08-17  Bruno Haible  <bruno@clisp.org>
12300
12301         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
12302
12303 2005-08-17  Bruno Haible  <bruno@clisp.org>
12304
12305         * modules/mbuiter: New file.
12306         * MODULES.html.sh (Extended multibyte and wide character utilities):
12307         Add mbuiter.
12308
12309 2005-08-17  Bruno Haible  <bruno@clisp.org>
12310
12311         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
12312         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
12313
12314 2005-08-17  Bruno Haible  <bruno@clisp.org>
12315
12316         * m4/strcasestr.m4: New file.
12317
12318 2005-08-17  Bruno Haible  <bruno@clisp.org>
12319
12320         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
12321         * lib/strstr.c: Completely rewritten, with multibyte locale support.
12322
12323 2005-08-17  Bruno Haible  <bruno@clisp.org>
12324
12325         * lib/strcasestr.h: New file.
12326         * lib/strcasestr.c: New file.
12327
12328 2005-08-17  Bruno Haible  <bruno@clisp.org>
12329
12330         * lib/strcasecmp.c: Use mbuiter.h.
12331
12332 2005-08-17  Bruno Haible  <bruno@clisp.org>
12333
12334         * lib/mbuiter.h: New file.
12335
12336 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12337
12338         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
12339         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
12340         and gl_GETOPT are both invoked via different paths (as happens
12341         with GNU tar CVS because it uses both argp and getopt), the former
12342         wins.
12343
12344 2005-08-16  Bruno Haible  <bruno@clisp.org>
12345
12346         * modules/tls: New file.
12347         * MODULES.html.sh (Multithreading): Add tls.
12348
12349 2005-08-16  Bruno Haible  <bruno@clisp.org>
12350
12351         * modules/strnlen1: New file.
12352         * MODULES.html.sh (String handling): Add strnlen1.
12353
12354 2005-08-16  Bruno Haible  <bruno@clisp.org>
12355
12356         * modules/strcase (Files): Add m4/mbrtowc.m4.
12357         (Depends-on): Add strnlen1, mbchar.
12358
12359 2005-08-16  Bruno Haible  <bruno@clisp.org>
12360
12361         * modules/mbiter: New file.
12362         * MODULES.html.sh (Extended multibyte and wide character utilities):
12363         Add mbiter.
12364
12365 2005-08-16  Bruno Haible  <bruno@clisp.org>
12366
12367         * modules/mbfile: New file.
12368         * MODULES.html.sh (Extended multibyte and wide character utilities):
12369         Add mbfile.
12370
12371 2005-08-16  Bruno Haible  <bruno@clisp.org>
12372
12373         * modules/mbchar: New file.
12374         * MODULES.html.sh (Extended multibyte and wide character utilities):
12375         New section.
12376
12377 2005-08-16  Bruno Haible  <bruno@clisp.org>
12378
12379         * m4/tls.m4: New file, from GNU gettext.
12380
12381 2005-08-16  Bruno Haible  <bruno@clisp.org>
12382
12383         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
12384         always.
12385         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
12386
12387 2005-08-16  Bruno Haible  <bruno@clisp.org>
12388
12389         * m4/mbiter.m4: New file.
12390
12391 2005-08-16  Bruno Haible  <bruno@clisp.org>
12392
12393         * m4/mbfile.m4: New file.
12394
12395 2005-08-16  Bruno Haible  <bruno@clisp.org>
12396
12397         * m4/mbchar.m4: New file.
12398
12399 2005-08-16  Bruno Haible  <bruno@clisp.org>
12400
12401         * lib/tls.h: New file, from GNU gettext.
12402         * lib/tls.c: New file, from GNU gettext.
12403
12404 2005-08-16  Bruno Haible  <bruno@clisp.org>
12405
12406         * lib/strnlen1.h: New file.
12407         * lib/strnlen1.c: New file.
12408
12409 2005-08-16  Bruno Haible  <bruno@clisp.org>
12410
12411         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
12412         (mbi_init): Update.
12413         (mbi_avail, mbi_advance): Let the iteration end before the terminating
12414         NUL byte, not after it.
12415
12416 2005-08-16  Bruno Haible  <bruno@clisp.org>
12417
12418         * lib/strcase.h (strcasecmp): Add note in comments.
12419         * lib/strncasecmp.c: Use code from strcasecmp.c.
12420         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
12421         (strcasecmp): Work correctly in multibyte locales.
12422
12423 2005-08-16  Bruno Haible  <bruno@clisp.org>
12424
12425         * lib/mbiter.h: New file.
12426
12427 2005-08-16  Bruno Haible  <bruno@clisp.org>
12428
12429         * lib/mbfile.h: New file.
12430
12431 2005-08-16  Bruno Haible  <bruno@clisp.org>
12432
12433         * lib/mbchar.h: New file.
12434         * lib/mbchar.c: New file.
12435
12436 2005-08-16  Bruno Haible  <bruno@clisp.org>
12437
12438         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
12439         the valid ones. Makes the comparison operations transitive:
12440         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
12441         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
12442
12443 2005-08-15  Simon Josefsson  <jas@extundo.com>
12444
12445         * modules/ssize_t (License): Change to 'unlimited'.
12446
12447         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
12448
12449 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12450
12451         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
12452         Add comments for each pending glibc patch.
12453
12454 2005-08-15  Bruno Haible  <bruno@clisp.org>
12455
12456         * lib/regex.h (__restrict_arr): Don't define to __restrict if
12457         __cplusplus is defined.
12458
12459 2005-08-14  Jim Meyering  <jim@meyering.net>
12460
12461         Sync from coreutils.
12462
12463         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
12464         Use the hash-table-based cycle-detection code not just when
12465         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
12466         Reported by James Youngman in
12467         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
12468         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
12469         FTS_TIGHT_CYCLE_CHECK.
12470         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
12471         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
12472         once again.
12473         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
12474         * lib/fts.c (fd_safer): Remove decl.
12475         Include fcntl--.h rather than unistd-safer.h
12476         (fts_safe_changedir): Don't call fd_safer; no longer needed
12477         now that we include fcntl--.h.
12478
12479 2005-08-12  Simon Josefsson  <jas@extundo.com>
12480
12481         * modules/getndelim2: Use ssize_t module.
12482         * modules/getnline: Likewise.
12483         * modules/safe-read: Likewise.
12484         * modules/xreadlink: Likewise.
12485
12486         * modules/ssize_t: New file.
12487
12488 2005-08-12  Simon Josefsson  <jas@extundo.com>
12489
12490         * m4/readline.m4: Look for termcap, curses or ncurses if required.
12491
12492 2005-08-12  Simon Josefsson  <jas@extundo.com>
12493
12494         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12495         ssize_t.
12496
12497 2005-08-12  Simon Josefsson  <jas@extundo.com>
12498
12499         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
12500         readline, getdelim and check_version.
12501         (Support for systems lacking ISO C 99: Sizes of integer types):
12502         Add size_max.
12503
12504 2005-08-12  Bruno Haible  <bruno@clisp.org>
12505
12506         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
12507
12508 2005-08-11  Simon Josefsson  <jas@extundo.com>
12509
12510         * modules/readline: New file.
12511
12512         * modules/strnlen (Files): Add strnlen.h.
12513
12514 2005-08-11  Simon Josefsson  <jas@extundo.com>
12515
12516         * m4/readline.m4: New file.
12517
12518 2005-08-11  Simon Josefsson  <jas@extundo.com>
12519
12520         * lib/readline.h, readline.c: New file.
12521
12522 2005-08-11  Simon Josefsson  <jas@extundo.com>
12523
12524         * doc/gnulib.texi (Initial import, Finishing touches): Mention
12525         gl_AVOID.
12526
12527 2005-08-11  Bruno Haible  <bruno@clisp.org>
12528
12529         * lib/strnlen.h (strnlen): Change parameter name to match comment.
12530
12531 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
12532
12533         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
12534
12535 2005-08-10  Simon Josefsson  <jas@extundo.com>
12536
12537         * tests/test-iconvme.c: New file.
12538
12539 2005-08-10  Simon Josefsson  <jas@extundo.com>
12540
12541         * m4/strnlen.m4: New file.
12542
12543         * m4/strndup.m4: Don't check for strnlen declaration, done in
12544         strnlen.m4.
12545
12546 2005-08-10  Simon Josefsson  <jas@extundo.com>
12547
12548         * lib/strndup.c: Use strnlen.h.
12549
12550         * lib/strnlen.h: New file.
12551
12552 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12553
12554         * README: Typos.
12555
12556 2005-08-02  Simon Josefsson  <jas@extundo.com>
12557
12558         * modules/readline: New file.
12559
12560 2005-08-02  Simon Josefsson  <jas@extundo.com>
12561
12562         * modules/getdelim: New file.
12563
12564         * modules/getline: Rewrite, don't use getndelim2.
12565
12566 2005-08-02  Simon Josefsson  <jas@extundo.com>
12567
12568         * m4/getline.m4: Separate out getdelim stuff into separate module.
12569
12570         * m4/getdelim.m4: New file.
12571
12572 2005-08-02  Simon Josefsson  <jas@extundo.com>
12573
12574         * lib/getline.h, getline.c: Rewrite.
12575
12576         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
12577
12578 2005-07-31  Bruno Haible  <bruno@clisp.org>
12579
12580         * lib/lock.h (gl_lock_initializer): New macro.
12581         (gl_lock_define_initialized): Use it.
12582         (gl_rwlock_initializer): New macro.
12583         (gl_rwlock_define_initialized): Use it.
12584         (gl_recursive_lock_initializer): New macro.
12585         (gl_recursive_lock_define_initialized): Use it.
12586
12587 2005-07-30  Karl Berry  <karl@gnu.org>
12588
12589         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
12590         Report from Ben Pfaff, regarding getopt.
12591
12592 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
12593
12594         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
12595         normal way.
12596         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
12597         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
12598         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
12599         (gl_GETOPT): Use the new macros.  Most of the implementation
12600         is moved to the new macros.  This is for programs like Emacs
12601         that don't want all the functionality of gl_GETOPT.
12602
12603 2005-07-26  Bruno Haible  <bruno@clisp.org>
12604
12605         * m4/lock.m4: Update from GNU gettext.
12606
12607 2005-07-26  Bruno Haible  <bruno@clisp.org>
12608
12609         * lib/lock.h: Update from GNU gettext.
12610         * lib/lock.c: Update from GNU gettext.
12611
12612 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
12613
12614         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
12615         obsolescent AC_TRY_RUN.  Include the default includes files, for
12616         'exit'.
12617
12618 2005-07-24  Bruno Haible  <bruno@clisp.org>
12619
12620         * modules/visibility: New file.
12621         * MODULES.html.sh (Misc): Add visibility.
12622
12623 2005-07-24  Bruno Haible  <bruno@clisp.org>
12624
12625         * m4/visibility.m4: New file.
12626
12627 2005-07-24  Bruno Haible  <bruno@clisp.org>
12628
12629         * doc/visibility.texi: New file.
12630
12631 2005-07-22  Bruno Haible  <bruno@clisp.org>
12632
12633         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
12634         $(ALLOCA_H), redundant through BUILT_SOURCES.
12635         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
12636         redundant through BUILT_SOURCES.
12637         * modules/byteswap (Makefile.am): Remove explicit dependency on
12638         $(BYTESWAP_H), redundant through BUILT_SOURCES.
12639         * modules/fnmatch (Makefile.am): Remove explicit dependency on
12640         $(FNMATCH_H), redundant through BUILT_SOURCES.
12641         * modules/getopt (Makefile.am): Remove explicit dependency on
12642         $(GETOPT_H), redundant through BUILT_SOURCES.
12643         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
12644         redundant through BUILT_SOURCES.
12645         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
12646         redundant through BUILT_SOURCES.
12647         * modules/stdbool (Makefile.am): Remove explicit dependency on
12648         $(STDBOOL_H), redundant through BUILT_SOURCES.
12649         * modules/stdint (Makefile.am): Remove explicit dependency on
12650         $(STDINT_H), redundant through BUILT_SOURCES.
12651         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
12652         Remove explicit dependency on $(SYSEXITS_H).
12653         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
12654
12655 2005-07-18  Simon Josefsson  <jas@extundo.com>
12656
12657         * lib/check-version.c (check_version): Accept identical versions too.
12658
12659 2005-07-18  Bruno Haible  <bruno@clisp.org>
12660
12661         * modules/lock: New file.
12662         * MODULES.html.sh (Multithreading): New section.
12663
12664 2005-07-18  Bruno Haible  <bruno@clisp.org>
12665
12666         * m4/lock.m4: New file, from GNU gettext.
12667
12668 2005-07-18  Bruno Haible  <bruno@clisp.org>
12669
12670         * lib/lock.h: New file, from GNU gettext.
12671         * lib/lock.c: New file, from GNU gettext.
12672
12673 2005-07-18  Bruno Haible  <bruno@clisp.org>
12674
12675         * lib/lock.h (gl_once_t): New type.
12676         (gl_once_define, gl_once): New macros.
12677         * lib/lock.c (fresh_once): New variable.
12678         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
12679         functions.
12680
12681 2005-07-16  Simon Josefsson  <jas@extundo.com>
12682
12683         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
12684         workaround, suggested by Bruno.
12685
12686 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
12687
12688         * modules/xalloc (Depends-on): Add xalloc-die.
12689         * modules/xvasprintf (Depends-on): Add xalloc-die.
12690
12691 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
12692
12693         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
12694         with a minor change.
12695
12696 2005-07-15  Bruno Haible  <bruno@clisp.org>
12697
12698         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
12699         When using lib/poll.c, define poll as rpl_poll.
12700
12701 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
12702
12703         * modules/argp (Depends-on): Remove unlocked-io.
12704
12705 2005-07-14  Derek Price  <derek@ximbiot.com>
12706
12707         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
12708         for glob symlink bug.
12709
12710 2005-07-14  Bruno Haible  <bruno@clisp.org>
12711
12712         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
12713         Instead, test for *_unlocked function declarations directly.
12714
12715 2005-07-11  Simon Josefsson  <jas@extundo.com>
12716
12717         * modules/size_max: New file.
12718
12719         * modules/xsize: Depend on size_max module for size_max.m4.
12720
12721 2005-07-11  Simon Josefsson  <jas@extundo.com>
12722
12723         * lib/size_max.h: New file.
12724
12725 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
12726
12727         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
12728         copyright symbol and the year.
12729         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
12730         (version_etc_va): Use parameterized copyright notice.
12731         Reword to conform to the current GNU coding standards.
12732
12733 2005-07-11  Karl Berry  <karl@gnu.org>
12734
12735         * doc/gnulib.texi (Quoting): new node.
12736         (Initial import): more info, from Patrice.
12737
12738 2005-07-11  Bruno Haible  <bruno@clisp.org>
12739
12740         * gnulib-tool (func_usage): Document option --avoid.
12741         (Command line options): Handle --avoid.
12742         (func_acceptable): New function.
12743         (func_modules_transitive_closure): Use it.
12744
12745 2005-07-11  Bruno Haible  <bruno@clisp.org>
12746
12747         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
12748         Reported by Jim Meyering.
12749
12750 2005-07-10  Bruno Haible  <bruno@clisp.org>
12751
12752         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
12753         Needed when size_t is smaller than 'unsigned int'.
12754         Reported by Paul Eggert.
12755
12756 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12757
12758         * modules/argp (Depends-on): Add unlocked-io
12759
12760 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12761
12762         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
12763         block of defines.
12764
12765 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
12766
12767         * config/srclist.txt: Comment out regcomp.c, since we have a porting
12768         fix now.
12769
12770 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
12771         and Paul Eggert  <eggert@cs.ucla.edu>
12772
12773         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
12774         in wint_t, not wchar_t.  Remove now-unnecessary cast.
12775
12776 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12777
12778         * modules/regex (Files): Add lib/regex_internal.c,
12779         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
12780         (Depends-on): Add extensions.
12781         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
12782
12783 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12784
12785         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
12786         pathconf.
12787         * m4/same.m4 (gl_SAME): Likewise.
12788         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
12789
12790         * m4/regex.m4: Adjust to new libc regex implementation.
12791         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
12792         all the .c and .h parts of (the new) regex.
12793         Quote the m4 stuff better.
12794         Check for RE_ICASE bug of old gnulib.
12795         Check for REG_STARTEND of recent libc.
12796         Rename local variables from jm_* to gl_*.
12797         Quote operand of "test -f".
12798         Say "recent enough" version of libc, not "version 2".
12799         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
12800         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
12801         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
12802         Remove check for btowc, isascii.
12803         Require AM_LANGINFO_CODESET.
12804
12805 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12806
12807         * lib/regex.c, regex.h: Sync from libc.
12808         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
12809         * lib/regexec.c:
12810         New files, synced from libc, except that regex_internal.h
12811         currently has a small porting fix.
12812
12813 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12814
12815         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
12816         regex_internal.c, regexec.c.
12817         Add regex_internal.h too, but as a comment, since the libc version
12818         is currently broken in gnulib mode.
12819
12820 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12821
12822         Support programs like Emacs that use gnulib but not gettext.
12823         * MODULES.html.sh (Internationalization functions): Add gettext-h.
12824         * modules/gettext-h: New file.
12825         * modules/gettext (Files): Remove lib/gettext.h.
12826         (Depends-on): Add gettext-h.
12827         (Makefile.am): Remove lib_SOURCES.
12828         * modules/argmatch, modules/c-stack, modules/closeout:
12829         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
12830         * modules/execute, modules/file-type, modules/getaddrinfo:
12831         * modules/getopt, modules/human, modules/javacomp:
12832         * modules/javaexec, modules/mkdir-p, modules/obstack:
12833         * modules/openat, modules/pagealign_alloc, modules/pipe:
12834         * modules/quotearg, modules/regex, modules/rpmatch:
12835         * modules/unicodeio, modules/userspec, modules/version-etc:
12836         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
12837         * modules/xsetenv:
12838         Depend on gettext-h, not gettext.
12839
12840 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
12841
12842         * gnulib-tool (func_import): Add support for 'public domain' license.
12843         * modules/alloca, modules/atexit, modules/memmove:
12844         Now public domain, not GPL.
12845         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
12846         * modules/realloc, modules/strerror, modules/strtod:
12847         Now LGPL, not GPL.
12848
12849 2005-07-05  Bruno Haible  <bruno@clisp.org>
12850
12851         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
12852         autoconf CVS. Needed for mingw.
12853
12854 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12855
12856         Remove the dependency of the strftime module on the tzset module.
12857         * modules/strftime (Depends-on): Remove dependency on tzset.
12858
12859 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12860
12861         Remove the dependency of the strftime module on the tzset module.
12862         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
12863         gl_FUNC_TZSET_CLOBBER.
12864
12865 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12866
12867         Remove the dependency of the strftime module on the tzset module.
12868         * lib/strftime.c (my_strftime)
12869         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
12870         Copy the input structure, to work around some of the bug with
12871         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
12872         Solaris releases, you should also use the tzset module, but we won't
12873         require it as a dependency any more since we don't want LGPLed code
12874         to depend on GPLed code.
12875
12876 2005-07-02  Jim Meyering  <jim@meyering.net>
12877
12878         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
12879         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
12880         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
12881         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
12882
12883 2005-07-02  Jim Meyering  <jim@meyering.net>
12884
12885         * lib/backupfile.c (backup_args): Change a `0' to NULL.
12886
12887 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
12888
12889         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
12890         declares only 'struct timespec;' (!).
12891
12892 2005-07-01  Jim Meyering  <jim@meyering.net>
12893
12894         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
12895         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
12896         * lib/save-cwd.c, tempname.c:
12897         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
12898         and don't include <sys/file.h>).
12899
12900 2005-06-29  Jim Meyering  <jim@meyering.net>
12901
12902         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
12903         type name.  Use the variable name instead.
12904         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
12905         Likewise.
12906
12907 2005-06-28  Simon Josefsson  <jas@extundo.com>
12908
12909         * modules/check-version (Files): Add check-version.m4.
12910
12911 2005-06-28  Simon Josefsson  <jas@extundo.com>
12912
12913         * m4/check-version.m4: New file, suggested by Jim Meyering
12914         <jim@meyering.net>.
12915
12916 2005-06-28  Simon Josefsson  <jas@extundo.com>
12917
12918         * lib/check-version.h, lib/check-version.c: New files.
12919
12920 2005-06-28  Simon Josefsson  <jas@extundo.com>
12921
12922         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
12923         collision with global variable.  Better indentation.  Don't
12924         increment buffer pointer beyond buffer end.  Based on comments
12925         from Paul Eggert <eggert@cs.ucla.edu>.
12926
12927         * lib/base64.h: Indent.
12928
12929 2005-06-28  Simon Josefsson  <jas@extundo.com>
12930
12931         * doc/gnulib.texi (Library version handling): New section.
12932
12933 2005-06-28  Jim Meyering  <jim@meyering.net>
12934
12935         * check-module (find_included_lib_files): Hard-code another
12936         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
12937         but modules/fts-lgpl (correctly) does not list those files.
12938
12939         * modules/canonicalize (Files): Add lib/pathmax.h.
12940
12941 2005-06-25  Simon Josefsson  <jas@extundo.com>
12942
12943         * modules/check-version: New file.
12944
12945 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
12946
12947         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
12948         initializer of struct addrinfo, as an indication that we don't
12949         care how many members the structure has.
12950
12951 2005-06-24  Derek Price  <derek@ximbiot.com>
12952         and Bruno Haible  <bruno@clisp.org>
12953
12954         Remove stat module & update lstat.
12955         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
12956         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
12957         * m4/stat.m4: Remove this file.
12958
12959 2005-06-24  Derek Price  <derek@ximbiot.com>
12960         and Bruno Haible  <bruno@clisp.org>
12961
12962         Remove stat module & update lstat.
12963         * lib/stat.c: Remove this file...
12964         (slash_aware_lstat): ...moving this content and its support...
12965         * lib/lstat.c (rpl_lstat): ...into here.
12966         * lib/lstat.h: New file.
12967
12968 2005-06-24  Derek Price  <derek@ximbiot.com>
12969         and Bruno Haible  <bruno@clisp.org>
12970
12971         Remove stat module & update lstat.
12972         * config/srclist.txt (libc sources): Remove stat.
12973
12974 2005-06-24  Derek Price  <derek@ximbiot.com>
12975         and Bruno Haible  <bruno@clisp.org>
12976
12977         Remove stat module & update lstat.
12978         * MODULES.html.sh (stat): Remove.
12979         * MODULES.html: Regenerated.
12980         * modules/lstat (Description): Correct function name.
12981         (Files): Add "lstat.h".
12982         (Depends-on): Remove stat, add xalloc, stat-macros.
12983         * modules/stat: Remove this file.
12984         (Include): Add "lstat.h", remove <sys/stat.h>.
12985
12986 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
12987
12988         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
12989         (ranged_convert): Don't save conversion in a temporary struct.
12990         This causes a warning with GCC 4.0.0, and anyway in the typical
12991         case it's not worth the extra 100 bytes or so of code.
12992         (ranged_convert, __mktime_internal): When calling a function via a
12993         pointer P, use P () rather than (*P) (), as we now assume C89 or
12994         better.
12995
12996 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12997
12998         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
12999         "who -r" failed to give output.  Problem reported by Tim Waugh.
13000
13001         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
13002         (xcalloc): Use it to avoid needless tests.
13003         Problem reported by Jim Meyering.
13004
13005 2005-06-20  Derek Price  <derek@ximbiot.com>
13006
13007         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
13008         unnecessary for Autoconfs > 2.59c.
13009
13010 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13011
13012         * lib/argp.h (__option_is_short): Check upper limit of
13013         __key. Isprint() requires its argument to have the value
13014         of an unsigned char or EOF.
13015
13016 2005-06-16  Jim Meyering  <jim@meyering.net>
13017
13018         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
13019         when either N or S is zero.
13020
13021 2005-06-16  Derek Price  <derek@ximbiot.com>
13022
13023         * m4/bison.m4: Declare YACC & YFLAGS precious.
13024
13025 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
13026
13027         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
13028         multibyte string or pattern, fall back on unibyte matching.
13029         Problem reported by James Youngman.
13030
13031 2005-06-08  Bruno Haible  <bruno@clisp.org>
13032
13033         * modules/csharpcomp: New file.
13034         * MODULES.html.sh (C#): Add csharpcomp.
13035
13036 2005-06-08  Bruno Haible  <bruno@clisp.org>
13037
13038         * m4/csharpcomp.m4: New file, from GNU gettext.
13039
13040 2005-06-08  Bruno Haible  <bruno@clisp.org>
13041
13042         * lib/csharpcomp.h: New file, from GNU gettext.
13043         * lib/csharpcomp.c: New file, from GNU gettext.
13044         * lib/csharpcomp.sh.in: New file, from GNU gettext.
13045
13046 2005-06-08  Bruno Haible  <bruno@clisp.org>
13047
13048         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
13049         warning on mingw.
13050
13051 2005-06-07  Derek Price  <derek@ximbiot.com>
13052
13053         Sync from CVS.
13054         * lib/glob_.h: Indent nested #ifdef.
13055
13056 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13057
13058         Sync from coreutils.
13059         Use "file name" when talking about file names, instead of "filename"
13060         or "path", as per the GNU coding standards.
13061         * lib/mkdir-p.c: Renamed from makepath.c.
13062         (make_dir_parents): Renamed from make_path.  All callers changed.
13063         * lib/mkdir-p.h: Likewise.  All includers changed.
13064         * lib/filenamecat.c: Renamed from path-concat.c.
13065         (file_name_concat): Renamed from path_concat.  All callers changed.
13066         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
13067         * lib/filenamecat.h: Likewise.  All includers changed.
13068         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
13069         in comments or local variable names.
13070         * lib/basename.c: Likewise.
13071         * lib/canonicalize.c, canonicalize.h: Likewise.
13072         * lib/dirname.c, dirname.h: Likewise.
13073         * lib/euidaccess.c: Likewise.
13074         * lib/exclude.c: Likewise
13075         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
13076         * lib/fsusage.c, fsuage.h: Likewise.
13077         * lib/fts.c, fts_.h: Likewise.
13078         * lib/getcwd.c: Likewise.
13079         * lib/getloadavg.c: Likewise.
13080         * lib/mkstemp.c: Likewise.
13081         * lib/mountlist.c, mountlist.h: Likewise.
13082         * lib/openat.c, openat.h: Likewise.
13083         * lib/readlink-stub.c: Likewise.
13084         * lib/readutmp.c, readutmp.h: Likewise.
13085         * lib/rename.c: Likewise.
13086         * lib/rmdir.c: Likewise.
13087         * lib/same.c: Likewise.
13088         * lib/savedir.c: Likewise.
13089         * lib/stripslash.c: Likewise.
13090         * lib/tempname.c: Likewise.
13091         * lib/xreadlink.c: Likewise.
13092         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
13093         All uses changed.
13094         * lib/exclude.h: Likewise.
13095
13096         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
13097         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13098         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
13099         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13100         * lib/pathmax.h: Include <limits.h> unconditionally, since other
13101         files have been getting away with it for years (MORE/BSD 4.3
13102         is extinct now).
13103         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
13104         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
13105
13106         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
13107         Define to 256, not 255, as per modern POSIX.
13108
13109 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13110
13111         Sync from coreutils.
13112         Use "file name" when talking about file names, instead of "filename"
13113         or "path", as per the GNU coding standards.
13114         * MODULES.html.sh: mkdir-p renamed from makepath.
13115         filenamecat renamed from path-concat.
13116         * modules/filenamecat: Renamed from modules/path-concat.
13117         (Files): filenamecat.h and filenamecat.c renamed from
13118         path-concat.h and path-concat.c.
13119         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
13120         (Include): filenamecat.h, not path-concat.h.
13121         * modules/mkdir-p: Renamed from modules/makepath.
13122         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
13123         makepath.c.
13124         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
13125         (Include): mkdir-p.h, not makepath.h.
13126
13127 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
13128
13129         Sync from coreutils.
13130         * m4/mkdir-p.m4: Renamed from makepath.m4.
13131         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
13132         Rename files from makepath.c to mkdir-p.c, and from
13133         makepath.h to mkdir-p.h.
13134         * m4/filenamecat.m4: Renamed from path-concat.m4.
13135         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
13136         Rename files from path-concat.c to filenamecat.c,
13137         and from path-concat.h to filenamecat.h.
13138         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
13139         "file name" in local variables or comments.
13140         * m4/rename.m4: Likewise.
13141
13142 2005-06-01  Bruno Haible  <bruno@clisp.org>
13143
13144         * modules/csharpexec: New file.
13145         * MODULES.html.sh (C#): New section.
13146
13147 2005-06-01  Bruno Haible  <bruno@clisp.org>
13148
13149         * m4/csharp.m4: New file, from GNU gettext.
13150         * m4/csharpexec.m4: New file, from GNU gettext.
13151
13152 2005-06-01  Bruno Haible  <bruno@clisp.org>
13153
13154         * lib/csharpexec.h: New file, from GNU gettext.
13155         * lib/csharpexec.c: New file, from GNU gettext.
13156         * lib/csharpexec.sh.in: New file, from GNU gettext.
13157
13158 2005-05-31  Derek Price  <derek@ximbiot.com>
13159             Paul Eggert  <eggert@cs.ucla.edu>
13160
13161         Sync from cvs.
13162         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
13163
13164 2005-05-31  Derek Price  <derek@ximbiot.com>
13165             Paul Eggert  <eggert@cs.ucla.edu>
13166
13167         Sync from cvs.
13168         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
13169
13170 2005-05-29  Derek Price  <derek@ximbiot.com>
13171
13172         * config/srclist.txt (glob_.h, glob.c): Add these files.
13173
13174 2005-05-29  Derek Price  <derek@ximbiot.com>
13175
13176         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
13177         * modules/glob: New file.
13178         * modules/getlogin_r: Add link to POSIX spec in description.
13179
13180 2005-05-29  Derek Price  <derek@ximbiot.com>
13181             Paul Eggert  <eggert@cs.ucla.edu>
13182
13183         * m4/glob.m4: New file.
13184
13185 2005-05-29  Derek Price  <derek@ximbiot.com>
13186             Paul Eggert  <eggert@cs.ucla.edu>
13187
13188         * lib/glob_.h, lib/glob.c: New files.
13189
13190 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13191
13192         * modules/fts (Files): Remove m4/inttypes-pri.m4.
13193         * modules/fts-lgpl (Depends-on): Remove gettext.
13194
13195 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13196
13197         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
13198         and don't require gt_INTTYPES_PRI.
13199
13200 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
13201
13202         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
13203
13204         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
13205         the configuration hassle isn't worth it.
13206         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
13207         (LONGEST_MODIFIER, PRIuMAX): Remove.
13208
13209 2005-05-27  Bruno Haible  <bruno@clisp.org>
13210
13211         * lib/getlogin_r.h: Remove second include of <stddef.h>.
13212
13213 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
13214
13215         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
13216         _POSIX_PTHREAD_SEMANTICS for Solaris.
13217
13218 2005-05-25  Derek Price  <derek@ximbiot.com>
13219
13220         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
13221
13222 2005-05-25  Derek Price  <derek@ximbiot.com>
13223             Paul Eggert  <eggert@cs.ucla.edu>
13224
13225         * modules/getlogin_r, m4/getlogin_r.m4: New files.
13226         * lib/getlogin_r.c, getlogin_r.h: New files.
13227
13228 2005-05-25  Bruno Haible  <bruno@clisp.org>
13229             Derek Price  <derek@ximbiot.com>
13230
13231         * lib/getlogin_r.h: Simplify API documentation.
13232
13233 2005-05-23  Derek Price  <derek@ximbiot.com>
13234
13235         * modules/minmax (Files): Add m4/minmax.m4.
13236         (configure.ac): Add gl_MINMAX.
13237
13238 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13239
13240         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
13241         so that unistd-safer.h (GPL'ed code) need not be included.
13242
13243 2005-05-22  Bruno Haible  <bruno@clisp.org>
13244
13245         * m4/minmax.m4: New file.
13246         Based on a patch by Derek Price <derek@ximbiot.com>.
13247
13248 2005-05-22  Bruno Haible  <bruno@clisp.org>
13249
13250         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
13251         (INT64_MIN): Fix definition.
13252         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
13253
13254         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
13255         NEED_SIGNED_INT_TYPES.
13256
13257         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
13258         HAVE_SYSTEM_INTTYPES.
13259
13260 2005-05-22  Bruno Haible  <bruno@clisp.org>
13261
13262         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
13263         Also include <sys/param.h> if it defines MIN, MAX.
13264         Based on a patch by Derek Price <derek@ximbiot.com>.
13265
13266 2005-05-21  Jim Meyering  <jim@meyering.net>
13267
13268         * modules/fts (Files): Add m4/inttypes-pri.m4.
13269         (Depends-on): Add lstat and remove gettext.  Alphabetize.
13270
13271 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13272
13273         New fts module.
13274         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
13275         (setup_dir, free_dir): New functions.
13276         (enter_dir, leave_dir): Define trivial
13277         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
13278         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
13279         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
13280         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
13281         Move to fts-cycle.c.
13282         (fts_open): Use setup_dir.
13283         (fts_close): Use free_dir.
13284         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
13285         This adds a label and some gotos, but the alternatives were messier.
13286         Check for memory allocation failure when entering a dir.
13287         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
13288         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
13289         (FTS): New member fts_cycle, that is a union that contains the
13290         old active_dir_ht and cycle_state.  All uses changed to mention
13291         fts_cycle.ht and fts_cycle.state.
13292         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
13293         fts.c, with the following changes:
13294         (setup_dir, free_dir): New functions.
13295         (enter_dir): Now returns bool.  Return true if successful, false
13296         if memory exhausted.  All callers changed.
13297         Do not bother partly cleaning up on
13298         memory allocation failure; that is free_dir's job.
13299         However, free ad if hash_insert fails, to avoid memory leak.
13300         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
13301         fts->fts_options to see which union member to use.
13302
13303 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13304
13305         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
13306         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
13307
13308 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
13309
13310         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
13311
13312 2005-05-20  Jim Meyering  <jim@meyering.net>
13313
13314         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
13315         Now a macro, to pacify GCC.
13316
13317 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
13318
13319         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
13320         of -1.
13321
13322 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
13323
13324         * lib/chown.c (rpl_chown): Return -1 on failure.
13325
13326 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
13327
13328         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
13329         Don't check for stddef.h.
13330         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
13331         don't use its results.
13332         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
13333         since we include them unconditionally.  Don't require
13334         AM_STDBOOL_H, since stdbool is a prerequisite.
13335         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
13336         since we assume C89 or better.
13337         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
13338         as we don't use their results.
13339         Don't check for fchdir, memmove, memset, strrchr, as we use
13340         them unconditionally.
13341         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
13342         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
13343
13344 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
13345
13346         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
13347         Include <stddef.h> unconditionally, since we assume C89 now.
13348         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
13349         * lib/fts.c: Include fts_.h first, to check interface.
13350         Do not include intprops.h; no longer needed.
13351         Include cycle-check.h and hash.h, since fts_.h no longer does.
13352         Remove unnecessary casts of closedir to void.
13353         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
13354         decide whether to decrement nlinks.
13355         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
13356         (FTS): Use struct hash_table * instead of Hash_table, so that
13357         we no longer need to include hash.h here.
13358
13359 2005-05-18  Jim Meyering  <jim@meyering.net>
13360
13361         * modules/dirfd (License): Change to LGPL.  Most of the code
13362         is already in the public domain.
13363
13364 2005-05-18  Jim Meyering  <jim@meyering.net>
13365
13366         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
13367         Reported by Yoann Vandoorselaere.
13368
13369 2005-05-17  Jim Meyering  <jim@meyering.net>
13370
13371         * m4/fts.m4: New file, from coreutils.
13372
13373 2005-05-17  Jim Meyering  <jim@meyering.net>
13374
13375         * lib/fts.c, lib/fts_.h: New files, from coreutils.
13376
13377 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13378
13379         Sync from coreutils.
13380         * m4/unlinkdir.m4: New file.
13381
13382 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13383
13384         Sync from coreutils.
13385         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
13386         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
13387         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
13388         White space changes only.
13389         * lib/makepath.c (make_path): Port to hosts where leading "//" is
13390         special.
13391         * lib/yesno.c: Include getline.h, not ctype.h.
13392         (yesno): Don't remove leading white space; POSIX doesn't allow it.
13393         Use getline to remove arbitrary restriction on response length.
13394
13395 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13396
13397         * config/srclist-update: Spell out "Street" in FSF postal
13398         mail address; this is the style the FSF seems to prefer.
13399
13400         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
13401         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
13402         this updates FSF postal mail address.
13403
13404         Sync from coreutils.
13405         * modules/unlinkdir: New file.
13406         * modules/yesno (Depends-on): Add getline.
13407         * MODULES.html.sh (File system functions): Add unlinkdir.
13408
13409 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
13410
13411         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
13412         lib/strsep.h:
13413         Change the initial comment to refer to GPL, not LGPL.
13414         gnulib-tool will change it to LGPL as needed.
13415
13416         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
13417         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
13418         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
13419         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
13420         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
13421         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
13422         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
13423         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
13424         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
13425         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
13426         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
13427         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
13428         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
13429         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
13430         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
13431         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
13432         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
13433         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
13434         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
13435         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
13436         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
13437         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
13438         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
13439         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
13440         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
13441         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
13442         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
13443         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
13444         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
13445         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
13446         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
13447         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
13448         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
13449         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
13450         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
13451         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
13452         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
13453         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
13454         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
13455         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
13456         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
13457         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
13458         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
13459         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
13460         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
13461         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
13462         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
13463         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
13464         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
13465         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
13466         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
13467         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
13468         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
13469         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
13470         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
13471         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
13472         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
13473         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
13474         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
13475         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
13476         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
13477         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
13478         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
13479         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
13480         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
13481         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
13482         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
13483         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
13484         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
13485         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
13486         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
13487         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
13488         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
13489         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
13490         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
13491         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
13492         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
13493         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
13494         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
13495         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
13496         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
13497         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
13498         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
13499         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
13500         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
13501         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
13502         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
13503         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
13504         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
13505         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
13506         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
13507         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
13508         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
13509         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
13510         lib/yesno.c, lib/yesno.h:
13511         Update FSF postal mail address.
13512
13513 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
13514
13515         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
13516         tests/test-memmem.c, tests/test-stpncpy.c:
13517         Update FSF postal mail address.
13518
13519 2005-05-13  Bruno Haible  <bruno@clisp.org>
13520
13521         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
13522         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
13523         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
13524         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
13525         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
13526         Add support for 64-bit integers in the MSVC compiler.
13527
13528 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13529
13530         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
13531
13532 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
13533
13534         * gnulib-tool (func_import): Sort and uniquify recommended includes.
13535
13536 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
13537
13538         * doc/getdate.texi (General date syntax): Don't say that date
13539         date --iso-8601=ns generates acceptable dates; it doesn't yet.
13540         Problem reported by Nic Ferrier.
13541
13542 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13543
13544         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
13545         specified in ai_socktype. Fix invalid ai_protocol
13546         check. ai_protocol is usually set to 0 or depending on
13547         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
13548         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
13549         ai_socktype / ai_protocol in the returned addrinfo structure.
13550
13551 2005-05-10  Simon Josefsson  <jas@extundo.com>
13552
13553         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
13554         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
13555
13556 2005-05-10  Karl Berry  <karl@gnu.org>
13557
13558         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
13559         (from http://www.gnu.org/licenses).
13560         * doc/COPYING.LIB: also rename to COPYING.LESSER.
13561         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
13562         fdl.texi suffices.
13563
13564 2005-05-10  Karl Berry  <karl@gnu.org>
13565
13566         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
13567         (COPYING.DOC): remove.
13568
13569         * config/srclist-update: new FSF address.
13570
13571 2005-05-10  Derek Price  <derek@ximbiot.com>
13572
13573         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
13574         possible.
13575
13576 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13577             Bruno Haible  <bruno@clisp.org>
13578
13579         * modules/inet_ntop: New file.
13580         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
13581         inet_ntop.
13582
13583 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13584             Bruno Haible  <bruno@clisp.org>
13585
13586         * m4/inet_ntop.m4: New file.
13587
13588 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13589             Bruno Haible  <bruno@clisp.org>
13590
13591         * lib/inet_ntop.h: New file.
13592         * lib/inet_ntop.c: New file, from glibc with modifications.
13593
13594 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
13595
13596         * modules/time_r (License): Change to LGPL.
13597         * modules/extensions (License): Change to LGPL.  Actually,
13598         the license is more permissive than that, but currently gnulib-tool
13599         doesn't know how to handle more-permissive licenses.
13600
13601         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
13602         Problem reported by Dave Love.
13603
13604 2005-05-08  Jim Meyering  <jim@meyering.net>
13605
13606         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
13607         blank.
13608
13609 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
13610
13611         * modules/argmatch (Depends-on): Add stdbool.
13612         * modules/backupfile (Depends-on): Likewise.
13613         * modules/chdir-long (Depends-on): Likewise.
13614         * modules/closeout (Depends-on): Likewise.
13615         * modules/cycle-check (Depends-on): Likewise.
13616         * modules/dirname (Depends-on): Likewise.
13617         * modules/fnmatch (Depends-on): Likewise.
13618         * modules/fsusage (Depends-on): Likewise.
13619         * modules/fwriteerror (Depends-on): Likewise.
13620         * modules/getcwd (Depends-on): Likewise.
13621         * modules/getloadavg (Depends-on): Likewise.
13622         * modules/hard-locale (Depends-on): Likewise.
13623         * modules/makepath (Depends-on): Likewise.
13624         * modules/mountlist (Depends-on): Likewise.
13625         * modules/nanosleep (Depends-on): Likewise.
13626         * modules/posixtm (Depends-on): Likewise.
13627         * modules/quotearg (Depends-on): Likewise.
13628         * modules/readtokens (Depends-on): Likewise.
13629         * modules/readtokens0 (Depends-on): Likewise.
13630         * modules/readutmp (Depends-on): Likewise.
13631         * modules/save-cwd (Depends-on): Likewise.
13632         * modules/strftime (Depends-on): Likewise.
13633         * modules/userspec (Depends-on): Likewise.
13634         * modules/utimecmp (Depends-on): Likewise.
13635         * modules/xgetcwd (Depends-on): Likewise.
13636         * modules/xnanosleep (Depends-on): Likewise.
13637         * modules/xstrtod (Depends-on): Likewise.
13638         * modules/yesno (Depends-on): Likewise.
13639
13640 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
13641
13642         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
13643         needless checks.
13644
13645 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13646
13647         Merge from coreutils.  Among other things,
13648         add bulletproofing for cases where stdin, stdout, or stderr are closed.
13649         * lib/fd-safer.c: New file.
13650         * lib/fcntl-safer.h, open-safer.c: Remove.
13651         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
13652         * lib/dup-safer.c: Include unistd-safer.h first.
13653         Don't include errno.h.
13654         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
13655         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
13656         * lib/file-type.c: Rely on file-type.h change.
13657         * lib/getloadavg.c: Include unistd-safer.h.
13658         (getloadavg): Use safer open.
13659         * lib/getusershell.c: Include "stdio-safer.h".
13660         (getusershell): Use safer fopen.
13661         * lib/long-options.c (long_options): Use NULL rather than 0.
13662         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
13663         'free'.
13664         * lib/modechange.c: Likewise.
13665         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
13666         (MODE_DONE): New constant.
13667         (struct mode_change): Remove 'next' member.
13668         (make_node_op_equals): New function; like the old one of the
13669         same name, except it allocates an array.
13670         (mode_compile, mode_create_from_ref): Use it.
13671         (mode_compile): Allocate result as an array, not a linked list.
13672         Parse octal string ourself, so that we catch mistakes like "+0".
13673         (mode_adjust): Arg is an array, not a linked list.
13674         * lib/modechange.c: Include stat-macros.h, xalloc.h.
13675         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
13676         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
13677         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
13678         Remove.  This is now stat-macros.h's job.
13679         (talloc): Remove.  All callers replaced by xalloc, so that
13680         our invokers don't have to worry about reporting memory failures.
13681         (make_node_op_equals): Remove.
13682         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
13683         New constants.
13684         (struct mode_change): Moved here from modechange.h.
13685         (mode_append_entry): Remove.
13686         (mode_compile): Remove MASKED_OPS arg, since it encouraged
13687         apps to have incorrect behavior.  Use simpler algorithm for head
13688         and tail.  Don't futz with umask; that's now the job of mode_adjust.
13689         Detect more invalid usages rather than having somewhat-random behavior.
13690         Don't insert an "a=" action, as that leads to incorrect behavior.
13691         (mode_compile, mode_create_from_ref): Return NULL on error instead
13692         of an enum, since now there's only one way to have an error.  All
13693         callers changed.
13694         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
13695         at the correct time.  Simplify calculation of "+u" and its ilk.
13696         Don't mishandle "+X".
13697         (mode_free): Remove "register" and localize decls.
13698         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
13699         (struct mode_change): Move to modechange.c; callers don't
13700         need to see this stuff.
13701         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
13702         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
13703         (mode_change, mode_adjust): Reflect the new signatures noted above.
13704         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
13705         that might redefine system include files.
13706         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
13707         (my_usleep): Use NULL rather than (void *) 0.
13708         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
13709         Use siginterrupt to specify that system calls should be interrupted.
13710         (rpl_nanosleep): Move initialization of suspended closer to call of
13711         my_usleep.
13712         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
13713         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
13714         (desirable_utmp_entry): New function.
13715         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
13716         using x2nrealloc, to simplify logic.
13717         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
13718         size calculation.  Do not assume utmp file is a regular file.
13719         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
13720         (READ_UTMP_CHECK_PIDS): New constant.
13721         * lib/save-cwd.c: Include unistd-safer.h.
13722         (save_cwd): Use fd_safer.
13723         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
13724         [!_LIBC] Include "stat-macros.h" instead.
13725         * lib/unistd-safer.h (fd_safer): New decl.
13726
13727 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13728
13729         * modules/getloadavg (Depends-on): Add unistd-safer.
13730         * modules/getusershell (Depends-on): Add stdio-safer.
13731         * modules/lstat (Depends-on): Remove xalloc.
13732         * modules/mkstemp (Depends-on): Add stat-macros.
13733         * modules/modechange (Depends-on): Remove xstrtol.
13734         Add stat-macros, xalloc.
13735         * modules/save-cwd (Depends-on): Add unistd-safer.
13736         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
13737         * modules/unistd-safer (Files): Add lib/fd-safer.c
13738         (Makefile.am): Remove lib_SOURCES.
13739
13740         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
13741         Remove fcntl-safer; unistd-safer supersedes it.
13742
13743 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13744
13745         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
13746         AC_HEADER_STAT.
13747         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
13748         (gl_PREREQ_CHOWN): Remove.
13749         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
13750         it.  Don't require AC_HEADER_STAT.
13751         (gl_PREREQ_LSTAT): Remove.
13752         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
13753         Don't require AC_HEADER_STAT.
13754         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
13755         (gl_PREREQ_RMDIR): Remove.
13756         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
13757         mention stat-macros.h or AC_HEADER_STAT, since we'll make
13758         the stat-macros module a prerequisite.
13759         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
13760         * m4/filemode.m4 (gl_FILEMODE): Likewise.
13761         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
13762         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
13763         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
13764         variable names.
13765         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
13766         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
13767         variable prefixes.
13768         * m4/fcntl-safer.m4: Remove.
13769         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
13770         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
13771         Invoke gl_PREREQ_FD_SAFER.
13772         (gl_PREREQ_FD_SAFER): New macro.
13773         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
13774         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
13775         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
13776         Remove duplicate call to AC_LIBOBJ(readutmp).
13777         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
13778
13779         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
13780         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
13781
13782 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13783
13784         * MODULES.html.sh (Misc): Add byteswap.
13785
13786 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13787
13788         * modules/getcwd (Depends-on): Add extensions.
13789         * modules/openat (Depends-on): Likewise.
13790
13791 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13792
13793         * modules/byteswap: New file.
13794
13795 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13796
13797         * m4/byteswap.m4: New file.
13798
13799 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13800
13801         * lib/byteswap_.h: New file.
13802
13803 2005-04-25  Karl Berry  <karl@gnu.org>
13804
13805         * m4/gettext.m4: Update from GNU gettext 0.14.4.
13806
13807 2005-04-25  Albert Chin  <china@thewrittenword.com>
13808
13809         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
13810         Toolkit C bug.
13811
13812 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
13813
13814         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
13815         (func_ln_if_changed) Remove forcibly for no error message
13816         in case file does not exist.
13817
13818 2005-04-19  Simon Josefsson  <jas@extundo.com>
13819
13820         * gnulib-tool (Options): Make --symlink mean --symbolic.
13821
13822 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
13823
13824         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
13825
13826 2005-04-16  Simon Josefsson  <jas@extundo.com>
13827
13828         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
13829
13830 2005-04-15  Simon Josefsson  <jas@extundo.com>
13831
13832         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
13833
13834 2005-04-15  Simon Josefsson  <jas@extundo.com>
13835
13836         * gnulib-tool: Rename --symlink to --symbolic.
13837
13838 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
13839
13840         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
13841         symbolic links to files instead of copying/moving.  Add --aux-dir,
13842         specifying directory relative --dir where auxiliary build tools
13843         are placed.
13844
13845 2005-04-14  Bruno Haible  <bruno@clisp.org>
13846
13847         * modules/allocsa (License): Change to LGPL.
13848         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
13849
13850 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
13851
13852         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
13853         that "UTC +1 second" continues to work.  Problem reported
13854         by Dmitry V. Levin.
13855         (relunit_snumber): New rule.
13856         (relunit): Use it.
13857
13858 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13859
13860         * lib/getdate.y (universal_time_zone_table): New constant.
13861         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
13862         universal_time_zone_table.
13863         (lookup_zone): Prefer universal_time_zone_table to
13864         local_time_zone_table, so that "GMT" time stamps are allowed in
13865         London during the summer.  Problem reported by Ian Abbott.
13866
13867 2005-04-12  Jim Meyering  <jim@meyering.net>
13868
13869         * lib/human.c (humblock): Set *options even when returning due to
13870         xstrtoumax conversion failure.  Thanks to a used-uninitialized
13871         warning from gcc-4.
13872
13873 2005-04-09  Jim Meyering  <jim@meyering.net>
13874
13875         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
13876         -Wuninitialized: initialize tm0.tm_year.
13877
13878 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
13879
13880         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
13881         count, since there's no maximum.  All uses changed.
13882         Add member dsts_seen.
13883         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
13884         not being INT_MAX.
13885         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
13886         Use pc_rels_seen to decide whther a date is absolute.
13887
13888         * lib/getdate.y (number): Don't overwrite year.
13889         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
13890         check.
13891
13892 2005-04-02  Simon Josefsson  <jas@extundo.com>
13893
13894         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
13895         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
13896
13897 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
13898
13899         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
13900         where no absolute path name can be longer than PATH_MAX.
13901
13902 2005-03-27  Jim Meyering  <jim@meyering.net>
13903
13904         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
13905
13906 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
13907
13908         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
13909         "one's complement" -> "ones' complement" in comment, as per Knuth.
13910         "value of type" -> "type or expression" in comment.
13911         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
13912
13913 2005-03-26  Jim Meyering  <jim@meyering.net>
13914
13915         Comment nits.
13916         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
13917         Correct typos: s/or/of/.
13918
13919 2005-03-26  Jim Meyering  <jim@meyering.net>
13920
13921         * modules/check-include-files: Move to ../ and rename to...
13922         * check-module: ...this.
13923
13924 2005-03-25  Jim Meyering  <jim@meyering.net>
13925
13926         * modules/xvasprintf (Files): Add xalloc.h.
13927
13928 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
13929
13930         * modules/gettext (Files): config/config.rpath ->
13931         build-aux/config.rpath
13932         * modules/iconv (Files): Likewise.
13933         Problem reported by Oskar Liljeblad.
13934
13935 2005-03-23  Jim Meyering  <jim@meyering.net>
13936
13937         * modules/check-include-files: New script to check for
13938         missing dependencies, multiple includes, etc.
13939
13940         * modules/c-strtold (Depends-on): Add xalloc.
13941         * modules/c-strtod (Depends-on): Add xalloc.
13942         * modules/hash (Depends-on): Add xalloc.
13943         (Files): Remove lib/xalloc.h.
13944
13945         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
13946         * modules/userspec (Files): Add lib/inttostr.h.
13947
13948 2005-03-23  Jim Meyering  <jim@meyering.net>
13949
13950         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
13951
13952 2005-03-22  Jim Meyering  <jim@meyering.net>
13953
13954         * modules/stat-macros: New module.
13955         * modules/canonicalize, modules/euidaccess, modules/file-type,
13956         * modules/filemode, modules/lchown, modules/makepath,
13957         * modules/rmdir, modules/stat: Depend on new stat-macros module
13958         rather than listing lib/stat-macros.h manually.
13959         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
13960
13961 2005-03-22  Jim Meyering  <jim@meyering.net>
13962
13963         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
13964
13965 2005-03-22  Bruno Haible  <bruno@clisp.org>
13966
13967         * config/srclist.txt: Replace target directory 'config' with
13968         'build-aux'.
13969         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
13970         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
13971         ../build-aux/.
13972
13973 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
13974
13975         * modules/chdir-long (Depends-on): Add mempcpy.
13976
13977         * modules/acl, modules/backupfile, modules/c-strtod,
13978         modules/c-strtold, modules/canon-host, modules/canonicalize,
13979         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
13980         modules/exclude, modules/exitfail, modules/file-type,
13981         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
13982         modules/getdate, modules/getline, modules/getpagesize,
13983         modules/getpass, modules/getugroups, modules/group-member,
13984         modules/hard-locale, modules/hash, modules/human, modules/idcache,
13985         modules/inttostr, modules/long-options, modules/makepath,
13986         modules/md5, modules/memcasecmp, modules/memcoll,
13987         modules/modechange, modules/mountlist, modules/path-concat,
13988         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
13989         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
13990         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
13991         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
13992         modules/strftime, modules/strndup, modules/strverscmp,
13993         modules/timespec, modules/unlocked-io, modules/userspec,
13994         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
13995         modules/yesno:
13996         Remove lib_SOURCES line from Makefile.am section, as this is now
13997         done automatically by the corresponding Autoconf macro.
13998
13999 2005-03-21  Jim Meyering  <jim@meyering.net>
14000
14001         Changes imported from coreutils.
14002
14003         * lib/cycle-check.c: Don't include xalloc.h.
14004
14005         * lib/path-concat.c: Don't include assert.h.
14006         (path_concat): Remove assertion that would have triggered
14007         for ABASE starting with more than one slash.
14008         Reported by Andreas Schwab.
14009
14010         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
14011         properly when ABASE is an absolute file name.
14012         Correct the description of this function.
14013         Include <assert.h>.
14014         Add an assertion and a test driver.
14015         This fixes a bug introduced on 2004-07-02.
14016         Andreas Schwab reported the resulting failure of cp --parents:
14017         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
14018
14019 2005-03-21  Jim Meyering  <jim@meyering.net>
14020
14021         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
14022         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
14023
14024 2005-03-21  Jim Meyering  <jim@meyering.net>
14025         and  Paul Eggert  <eggert@cs.ucla.edu>
14026
14027         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
14028         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
14029         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
14030         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
14031         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
14032         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
14033         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
14034         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
14035         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
14036         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
14037         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
14038         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
14039         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
14040         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
14041         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
14042         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
14043         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
14044         for these modules.
14045
14046 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
14047
14048         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
14049         (which shouldn't happen), generate nothing instead of returning 0
14050         immediately, so that nstrftime (NULL, ...) doesn't return 0.
14051
14052 2005-03-16  Bruno Haible  <bruno@clisp.org>
14053
14054         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
14055         HAVE_LONGLONG_64BIT.
14056
14057 2005-03-16  Bruno Haible  <bruno@clisp.org>
14058
14059         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
14060         HAVE_LONGLONG_64BIT.
14061
14062 2005-03-16  Bruno Haible  <bruno@clisp.org>
14063
14064         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
14065         HAVE_LONGLONG_64BIT.
14066
14067 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
14068
14069         * lib/strftime.c (my_strftime): Prepend space to format so that we can
14070         reliably distinguish strftime failure from empty output on POSIX
14071         hosts.
14072
14073 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
14074
14075         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
14076         (iconv_string): Don't guess a size-zero buffer, as that might cause
14077         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
14078         result would be 'too large', where 'too large' is (heuristically)
14079         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
14080         overflow concerns.  This will prevent some unwanted malloc failures
14081         when the inputs are very large.
14082
14083 2005-03-15  Karl Berry  <karl@gnu.org>
14084
14085         * config/srclist.txt (config.rpath): from gettext.
14086         * config/config.rpath: update.
14087
14088 2005-03-15  Bruno Haible  <bruno@clisp.org>
14089
14090         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
14091         to 'negate'.
14092
14093         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
14094         variable.
14095
14096         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
14097         results.
14098
14099 2005-03-14  Simon Josefsson  <jas@extundo.com>
14100
14101         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
14102         <fx@gnu.org>.
14103
14104 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
14105
14106         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
14107         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
14108         intprops.h.
14109         * lib/strtol.c: Likewise.
14110
14111 2005-03-14  Jim Meyering  <jim@meyering.net>
14112
14113         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
14114         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
14115         to be nonzero so that we (and caller) can detect the difference
14116         between a valid zero-length expansion and an error return, even
14117         when the underlying strftime fails before writing anything into
14118         that location.
14119
14120 2005-03-14  Bruno Haible  <bruno@clisp.org>
14121
14122         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
14123         Update from GNU gettext 0.14.3.
14124
14125 2005-03-10  Jim Meyering  <jim@meyering.net>
14126
14127         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
14128
14129 2005-03-10  Jim Meyering  <jim@meyering.net>
14130
14131         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
14132         so that this module works on systems without fchdir.
14133
14134 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
14135
14136         Factor int-properties macros into a single file, except for
14137         glibc-related files.
14138         * lib/intprops.h: New file.
14139         * lib/getloadavg.c: Include it instead of limits.h.
14140         (INT_STRLEN_BOUND): Remove.
14141         * lib/human.c: Include intprops.h.
14142         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
14143         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
14144         302/1000.
14145         * lib/inttostr.h: Include intprops.h instead of limits.h.
14146         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
14147         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
14148         for consistency with intprops.h.
14149         (time_t_is_integer, twos_complement_arithmetic): Use them.
14150         * lib/sig2str.h: Include <signal.h>, intprops.h.
14151         (INT_STRLEN_BOUND): Remove.
14152         * lib/strftime.c (TYPE_SIGNED): Remove.
14153         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
14154         * lib/strtol.c: Adjust comments to match intprops.h.
14155         * lib/userspec.c: Include intprops.h.
14156         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
14157         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
14158         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
14159         instead of rolling our own expressions.
14160         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
14161
14162         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
14163         instead of int.
14164         (my_strftime): Do not mishandle years close to INT_MAX, by doing
14165         the right thing even if adding 1900 would overflow.  Similarly
14166         for tm_mon + 1 and tm_yday + 1.
14167         Make %Y always equivalent to %C%y, and similarly for %G and %g.
14168         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
14169         (DO_SIGNED_NUMBER): New macro.
14170         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
14171
14172 2005-03-07  Bruno Haible  <bruno@clisp.org>
14173
14174         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
14175
14176 2005-03-07  Bruno Haible  <bruno@clisp.org>
14177
14178         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
14179
14180 2005-03-04  Derek R. Price  <derek@ximbiot.com>
14181
14182         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
14183         (func_import): Only replace files via --import when they have actually
14184         changed.
14185
14186 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14187
14188         * m4/mmap-anon.m4: New file.
14189         * m4/pagealign_alloc.m4: New file.
14190
14191 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14192             Bruno Haible  <bruno@clisp.org>
14193
14194         * modules/pagealign_alloc: New file.
14195         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
14196
14197 2005-03-03  Derek R. Price  <derek@ximbiot.com>
14198             Bruno Haible  <bruno@clisp.org>
14199
14200         * lib/pagealign_alloc.h: New file.
14201         * lib/pagealign_alloc.c: New file.
14202
14203 2005-03-03  Bruno Haible  <bruno@clisp.org>
14204
14205         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
14206         Use an all-permissive copyright notice, recommended by RMS.
14207
14208 2005-03-02  Bruno Haible  <bruno@clisp.org>
14209
14210         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
14211         of AIX, the replacement has to be done only after <string.h> is
14212         included, therefore not in config.h. stpncpy.h does the replacement,
14213         and stpncpy.c uses it.
14214
14215 2005-03-02  Bruno Haible  <bruno@clisp.org>
14216
14217         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
14218         stpncpy.c uses it.
14219
14220 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14221
14222         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
14223         The workaround isn't strictly needed for POSIX conformance, and
14224         it's too much of a pain to configure and maintain.  We'll ask
14225         people to fix their kernels instead.
14226         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
14227         (NANOSLEEP_BUG_WORKAROUND): Remove.
14228         (xnanosleep): Remove the workaround.
14229
14230 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14231
14232         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
14233         Reported by Derek Price.
14234         (Include): Add "timespec.h".
14235
14236         * modules/xnanosleep (Depends-on): Remove gethrxtime.
14237
14238 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14239
14240         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
14241         to detect nanosleep bug.
14242
14243 2005-03-01  Bruno Haible  <bruno@clisp.org>
14244
14245         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
14246
14247 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
14248
14249         * modules/gethrxtime: New file.
14250         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
14251         (Depends-on): Add gethrxtime.
14252         (configure.ac): Add gl_XNANOSLEEP.
14253         (Makefile.am): Remove lib_SOURCES line.
14254
14255 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
14256
14257         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
14258         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
14259
14260 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
14261
14262         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
14263         * lib/timespec.h (gettime): Return void, since it always
14264         succeeds now.  All uses changed.
14265         * lib/gettime.c (gettime) Likewise.
14266         [HAVE_NANOTIME]: Prefer nanotime.
14267         Assume gettimeofday succeeds, as POSIX requires.
14268         Assime time () succeeds, since other code already does.
14269         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
14270         (timespec_subtract): Remove.
14271         (NANOSLEEP_BUG_WORKAROUND): New constant.
14272         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
14273         things considerably.  Use it only on GNU/Linux hosts, since the
14274         workaround shouldn't be needed elsewhere.
14275
14276 2005-02-24  Bruno Haible  <bruno@clisp.org>
14277
14278         * modules/gettext (Files): Add m4/glibc2.m4.
14279
14280 2005-02-24  Bruno Haible  <bruno@clisp.org>
14281
14282         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
14283         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
14284         * m4/progtest.m4:
14285         Update from GNU gettext 0.14.2.
14286         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
14287
14288 2005-02-24  Bruno Haible  <bruno@clisp.org>
14289
14290         * lib/localcharset.c: Update from GNU gettext 0.14.2.
14291         * lib/config.charset: Update from GNU gettext 0.14.2.
14292
14293 2005-02-24  Bruno Haible  <bruno@clisp.org>
14294
14295         * lib/gettext.h: Update from GNU gettext 0.14.2.
14296
14297 2005-02-23  Simon Josefsson  <jas@extundo.com>
14298
14299         * m4/iconvme.m4: New file.
14300
14301 2005-02-23  Jim Meyering  <jim@meyering.net>
14302
14303         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
14304         change.
14305         Thanks to Bruno Haible for catching it.
14306
14307 2005-02-22  Simon Josefsson  <jas@extundo.com>
14308
14309         * modules/iconvme: New file.
14310
14311         * MODULES.html.sh: Add iconvme.
14312
14313 2005-02-22  Simon Josefsson  <jas@extundo.com>
14314
14315         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
14316
14317 2005-02-22  Simon Josefsson  <jas@extundo.com>
14318
14319         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
14320
14321 2005-02-22  Jim Meyering  <jim@meyering.net>
14322
14323         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
14324         s/ifndef/ifdef/.
14325
14326 2005-02-20  Neil Conway  <neilc@samurai.com>
14327
14328         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
14329         returned by OSX/Darwin if the specified buffer is not large
14330         enough for the hostname.
14331
14332 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14333
14334         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
14335         pass it to _help, otherwise the latter coredumps trying to
14336         dereference state.root_argp.
14337
14338 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14339
14340         * modules/chdir-long (Depends-on): Add memrchr.
14341         * modules/memrchr (Files): Add lib/memrchr.h.
14342         (Include): "memrchr.h".
14343
14344 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14345
14346         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
14347
14348 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
14349
14350         * lib/memrchr.h: New file.
14351         * lib/chdir-long.c: Include it.
14352         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
14353         Don't bother including stddef.h.
14354
14355 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
14356
14357         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
14358         inclusion.
14359         Include <sys/types.h>, for dev_t.
14360         (ME_DUMMY, ME_REMOTE): Move from here....
14361         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
14362         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
14363         Dmitry V. Levin.
14364         Include mountlist.h first, to test the interface.
14365
14366 2005-01-29  Bruno Haible  <bruno@clisp.org>
14367
14368         * lib/progname.c (program_name): Initialize.
14369         Needed when linking statically on MacOS X.
14370
14371 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
14372
14373         Sync from coreutils.
14374         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
14375         (Depends-on): Add c-strtod.
14376         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
14377
14378 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
14379
14380         Sync from coreutils.
14381         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
14382
14383         Remove files that are specific to coreutils.
14384         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
14385
14386 2005-01-28  Bruno Haible  <bruno@clisp.org>
14387
14388         * modules/javacomp: New file.
14389         * MODULES.html.sh (Java): Add javacomp.
14390
14391 2005-01-28  Bruno Haible  <bruno@clisp.org>
14392
14393         * m4/javacomp.m4: New file, from GNU gettext.
14394
14395 2005-01-28  Bruno Haible  <bruno@clisp.org>
14396
14397         * lib/javacomp.sh.in: New file, from GNU gettext.
14398         * lib/javacomp.h: New file, from GNU gettext.
14399         * lib/javacomp.c: New file, from GNU gettext.
14400
14401 2005-01-26  Simon Josefsson  <jas@extundo.com>
14402
14403         * lib/gai_strerror.c: Use GPL in header.
14404
14405 2005-01-26  Bruno Haible  <bruno@clisp.org>
14406
14407         * modules/javaexec: New file.
14408         * MODULES.html.sh (Java): Add javaexec.
14409
14410 2005-01-26  Bruno Haible  <bruno@clisp.org>
14411
14412         * m4/javaexec.m4: New file, from GNU gettext.
14413
14414 2005-01-26  Bruno Haible  <bruno@clisp.org>
14415
14416         * lib/javaexec.sh.in: New file, from GNU gettext.
14417         * lib/javaexec.h: New file, from GNU gettext.
14418         * lib/javaexec.c: New file, from GNU gettext.
14419
14420 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14421
14422         * modules/lchown (Depends-on): Remove lchown.h
14423
14424 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14425
14426         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
14427         must be defined if the header file was not found, in order
14428         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
14429
14430 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14431
14432         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
14433         initializers for struct pentry_state.
14434         (__argp_error): Check return value of __asprintf
14435         (__argp_failure): Translate error message
14436
14437         * lib/argp-parse.c: Removed braces around the expansion of N_()
14438
14439 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
14440
14441         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
14442         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
14443         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
14444         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
14445         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
14446         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
14447         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
14448         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
14449         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
14450         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
14451         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
14452         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
14453         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
14454         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
14455         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
14456         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
14457         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
14458         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
14459         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
14460         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
14461         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
14462         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
14463         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
14464         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
14465         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
14466         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
14467         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
14468         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
14469         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
14470         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
14471         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
14472         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
14473         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
14474         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
14475         xstrtol.m4, xstrtoumax.m4, yesno.m4:
14476         Use an all-permissive copyright notice, recommended by RMS.
14477
14478 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
14479
14480         * modules/chdir-long (Depends-on): Remove mempcpy.
14481
14482 2005-01-21  Jim Meyering  <jim@meyering.net>
14483
14484         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
14485         same value as for Solaris 9.
14486
14487         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
14488         component length.  This included changing the parameter to be
14489         of type `char *' rather than `char const *'.
14490         * lib/chdir-long.h (chdir_long): Update prototype.
14491
14492         * lib/openat.c (fdopendir, fstatat): New functions.
14493         * lib/openat.h: Include headers required for use of DIR and struct
14494         stat.
14495         [AT_SYMLINK_NOFOLLOW]: Define.
14496         (fdopendir, fstatat): Add prototypes.
14497
14498 2005-01-21  Bruno Haible  <bruno@clisp.org>
14499
14500         * modules/classpath: New file.
14501         * MODULES.html.sh (Java): Add classpath.
14502
14503 2005-01-21  Bruno Haible  <bruno@clisp.org>
14504
14505         * lib/classpath.h: New file, from GNU gettext.
14506         * lib/classpath.c: New file, from GNU gettext.
14507
14508 2005-01-20  Simon Josefsson  <jas@extundo.com>
14509
14510         * modules/version-etc-fsf: New file.
14511
14512 2005-01-20  Simon Josefsson  <jas@extundo.com>
14513
14514         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
14515         * lib/version-etc.c: Remove version_etc_copyright.
14516         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
14517         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
14518
14519 2005-01-20  Simon Josefsson  <jas@extundo.com>
14520
14521         * lib/base64.h (isbase64): Add.
14522
14523         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
14524         using a unsigned prototype, don't inline.
14525         (base64_decode): Use it.
14526
14527 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14528
14529         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
14530         it.
14531
14532 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14533
14534         * lib/save-cwd.c (save_cwd): Remove code to support the case
14535         where fchdir is missing or flaky.
14536
14537 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
14538
14539         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
14540
14541 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
14542
14543         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
14544         AC_LIBSOURCES now does this.
14545         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
14546         with new ullong_max module.
14547
14548 2005-01-19  Bruno Haible  <bruno@clisp.org>
14549
14550         * modules/sh-quote: New file.
14551         * MODULES.html.sh (Executing programs): Add sh-quote.
14552
14553 2005-01-19  Bruno Haible  <bruno@clisp.org>
14554
14555         * lib/sh-quote.h: New file, from GNU gettext.
14556         * lib/sh-quote.c: New file, from GNU gettext.
14557
14558 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14559
14560         Merge from coreutils.
14561         * m4/ullong_max.m4: New file.
14562         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
14563         (gl_MACROS): Assume localeconv exists.
14564
14565 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14566
14567         Merge changes from coreutils, as described below in several
14568         changelogs dated today.
14569
14570         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
14571         (O_DIRECTORY): Remove; not needed here, since "." must be
14572         a directory.  All uses removed.
14573         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
14574         universal on Suns, and we also need to test for IRIX.
14575         Revamp code to use 'if' rather than '#if'.
14576         Avoid unnecessary comparison of cwd->desc to 0.
14577
14578         * lib/utimens.c (futimens): Robustify the previous patch, by checking
14579         for known valid error numbers rather than observed invalid ones.
14580
14581 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
14582
14583         * modules/ullong_max: New file.
14584
14585         * modules/chdir-long, modules/openat: New files.
14586         * modules/save-cwd (Depends-on): Depend on chdir-long.
14587         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
14588
14589 2005-01-18  Jim Meyering  <jim@meyering.net>
14590
14591         Merge from coreutils.
14592         * m4/chdir-long.m4, m4/openat.m4: New files.
14593         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
14594         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
14595         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
14596         is sane and DOES follow symlinks.  Besides, testing 20 different
14597         systems found no broken chown implementations.
14598         Prompted by a change in rsync's copy of this macro.
14599         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
14600
14601         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
14602
14603         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
14604         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
14605         NULL-means-set-to-current-time semantics.
14606         Remove temporary file immediately, rather than waiting
14607         for configure's at-exit trap code to do it.
14608
14609 2005-01-18  Jim Meyering  <jim@meyering.net>
14610
14611         * lib/version-etc.c (version_etc_copyright): Update copyright date.
14612
14613         * lib/utimens.c (futimens): Account for the fact that futimes
14614         can also fail with errno == ENOSYS or errno == ENOENT.
14615         Patch from Dmitry V. Levin.
14616
14617         Change the name of the robust chdir function from chdir to chdir_long.
14618         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
14619         (restore_cwd): Use chdir_long, not chdir.
14620         * lib/chdir-long.c: Renamed from chdir.c.
14621         * lib/chdir-long.h: Renamed from chdir.h.
14622         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
14623         Hurd.
14624
14625 2005-01-18  Bruno Haible  <bruno@clisp.org>
14626
14627         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
14628         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
14629         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
14630         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
14631         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
14632         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
14633         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
14634         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
14635         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
14636         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
14637         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
14638         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
14639         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
14640         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
14641         Use an all-permissive copyright notice, recommended by RMS.
14642
14643 2005-01-18  Bob Proulx  <bob@proulx.com>
14644
14645         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
14646         simplify offsetof() macro construct to avoid compile failure with
14647         native HP-UX 11.0 ANSI C compiler.
14648
14649 2005-01-17  Bruno Haible  <bruno@clisp.org>
14650
14651         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
14652         redundant because stpncpy.m4 takes care of it.
14653
14654 2005-01-17  Bruno Haible  <bruno@clisp.org>
14655
14656         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
14657
14658 2005-01-17  Bruno Haible  <bruno@clisp.org>
14659
14660         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
14661         used.
14662
14663 2005-01-17  Bruno Haible  <bruno@clisp.org>
14664
14665         * lib/fwriteerror.h (fwriteerror): Change specification to include
14666         fclose.
14667         * lib/fwriteerror.c: Include <stdbool.h>.
14668         (fwriteerror): At the end, close the file stream. Record whether
14669         stdout was already closed.
14670
14671 2005-01-17  Bruno Haible  <bruno@clisp.org>
14672
14673         * lib/execute.c (environ): Declare if needed.
14674         * lib/pipe.c (environ): Likewise.
14675         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
14676
14677 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14678
14679         * modules/argp: Depend on vsnprintf
14680
14681 2005-01-10  Jim Meyering  <jim@meyering.net>
14682
14683         * modules/closeout (Depends-on): Add atexit.
14684
14685 2005-01-06  Bruno Haible  <bruno@clisp.org>
14686
14687         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
14688
14689 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
14690
14691         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
14692         definitions to be after all include files, to avoid collisions.
14693         Problem reported by Bob Proulx.
14694
14695 2005-01-04  Jim Meyering  <jim@meyering.net>
14696
14697         Changes imported from coreutils.
14698         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
14699         as the mkstemp template, use a temporary directory and an
14700         8.3-friendly template to avoid trouble on systems like DJGPP.
14701         Reported by Juan M. Guerrero via Stepan Kasal.
14702         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
14703         close. Remove the temporary directory right away, rather than waiting
14704         for configure's at-exit trap code to do it.
14705         Suggestion from Stepan Kasal.
14706
14707 2005-01-01  Simon Josefsson  <jas@extundo.com>
14708
14709         * gnulib-tool: Print #include directives when --import'ing.
14710
14711 2004-12-28  Simon Josefsson  <jas@extundo.com>
14712
14713         * tests/test-base64.c: Include required header files.  Remove
14714         unused variables.
14715
14716 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
14717
14718         * modules/error (Depends-on): Remove gettext.
14719
14720 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
14721
14722         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
14723         not needed.  This removes a dependency on the gettext module.
14724         [defined _LIBC]: Do not include <libintl.h>; not needed.
14725
14726 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
14727
14728         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
14729         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
14730
14731 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
14732
14733         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
14734         HAVE_DECL_STRTOLD.
14735
14736 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14737
14738         * modules/getdate (Depends-on): Remove alloca-opt.
14739
14740 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14741
14742         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
14743
14744 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14745
14746         * lib/argp-parse.c: Include <stddef.h>.
14747         (alignof, alignto): New macros.
14748         (parser_init): Don't assume that void * is aligned sufficiently
14749         for struct option.
14750
14751         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
14752         need to extend the stack.
14753         (YYINITDEPTH): New macro, so that the initial stack isn't overly
14754         large.
14755
14756 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14757
14758         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
14759
14760 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
14761
14762         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
14763         (2004-10-24) change.  Apparently this was a false alarm.
14764
14765         * modules/getdate: Depend on alloca-opt, not alloca.
14766
14767 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
14768
14769         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
14770         Remove now-obsolete comment about AIX.
14771         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
14772         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
14773         (YYMAXDEPTH): New macro.
14774
14775 2004-12-18  Simon Josefsson  <jas@extundo.com>
14776
14777         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
14778
14779 2004-12-18  Bruno Haible  <bruno@clisp.org>
14780
14781         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
14782
14783 2004-12-18  Bruno Haible  <bruno@clisp.org>
14784
14785         * lib/fatal-signal.c (fatal_signals): Make non-const.
14786         (init_fatal_signals): New function.
14787         (uninstall_handlers, install_handlers): Ignore signals that were set to
14788         SIG_IGN.
14789         (at_fatal_signal): Call init_fatal_signals.
14790         (init_fatal_signal_set): Likewise. Ignore signals that were set to
14791         SIG_IGN.
14792         Reported by Paul Eggert.
14793
14794 2004-12-18  Bruno Haible  <bruno@clisp.org>
14795
14796         * doc/alloca.texi: New file.
14797         * doc/alloca-opt.texi: New file.
14798
14799 2004-12-17  Jim Meyering  <jim@meyering.net>
14800
14801         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
14802         Otherwise, install-sh could exit with improper exit status when
14803         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
14804
14805 2004-12-16  Simon Josefsson  <jas@extundo.com>
14806
14807         * tests/test-base64.c: Add license.
14808
14809 2004-12-15  Stepan Kasal  <address@hidden>
14810
14811         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
14812
14813 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
14814
14815         * modules/getcwd (Files): Add m4/d-ino.m4.
14816         Suggested by Mark D. Baushke.
14817
14818 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
14819
14820         * lib/getdate.y (textint): New member "negative".
14821         (time_zone_hhmm): New function.
14822         Expect 14 shift-reduce conflicts, not 13.
14823         (o_colon_minutes): New rule.
14824         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
14825         (yylex): Set the "negative" member of signed numbers.
14826
14827 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
14828
14829         * doc/getdate.texi (Time of day items, Time zone items):
14830         Describe new formats +00:00, UTC+00:00.
14831
14832 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
14833
14834         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
14835         spurious "-l"s.  Problem reported by Stepan Kasal.
14836
14837 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
14838
14839         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
14840         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
14841
14842 2004-12-04  Simon Josefsson  <jas@extundo.com>
14843
14844         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
14845         Vandoorselaere <yoann@prelude-ids.org>.
14846
14847 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14848
14849         Changes imported from coreutils.
14850         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
14851         exist.
14852         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
14853
14854 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14855
14856         Changes imported from coreutils.
14857         * lib/hard-locale.c: Assume <locale.h> exists.
14858         Include "strdup.h".
14859         (GLIBC_VERSION): New macro.
14860         (hard_locale): Assume setlocale exists.
14861         Rewrite to avoid #ifdef.
14862         Use strdup rather than malloc + strcpy.
14863         * lib/human.c: Assume <locale.h> exists.
14864         (human_readable): Assume localeconv exists.
14865
14866 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14867
14868         * modules/hard-locale (Depends-on): Add strdup.
14869
14870 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
14871
14872         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
14873         convert T2, not T.  (Imported from libc.)
14874
14875 2004-11-30  Simon Josefsson  <jas@extundo.com>
14876
14877         * modules/restrict (License): Change to LGPL.
14878
14879 2004-11-30  Simon Josefsson  <jas@extundo.com>
14880
14881         * m4/restrict.m4: Add copyright and copying conditions.
14882
14883 2004-11-30  Simon Josefsson  <jas@extundo.com>
14884
14885         * m4/base64.m4: New file.
14886
14887 2004-11-30  Simon Josefsson  <jas@extundo.com>
14888
14889         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
14890         base64.
14891
14892         * tests/test-base64.c: New file.
14893
14894         * modules/base64: New file.
14895
14896 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
14897
14898         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
14899         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
14900
14901         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
14902
14903 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
14904
14905         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
14906         (__getcwd.c): Don't restore errno; glibc doesn't.
14907         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
14908         first, falling back to our code only if its results look suspicious.
14909         Ensure that the resulting buffer is only as large as necessary.
14910
14911         * lib/readutmp.c: Include readutmp.h first.
14912         Include <errno.h>, since readutmp.h no longer does that.
14913         * lib/readutmp.h: Don't include <errno.h>,
14914         <sys/param.h>, <time.h>; not needed to establish interface.
14915         (errno): Remove decl.
14916         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
14917         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
14918         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
14919
14920 2004-11-28  Simon Josefsson  <jas@extundo.com>
14921
14922         * lib/base64.h, base64.c: New file.
14923
14924 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
14925
14926         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
14927
14928 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
14929
14930         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
14931         (Depends-on): Remove pathmax, same.  Add mempcpy.
14932         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
14933         (Makefile.am): Append getcwd.h to lib_SOURCES.
14934         (Include): Add getcwd.h.
14935         (Maintainer): Change from Jim Meyering to "all, glibc",
14936         since getdate now uses intended-for-glibc code.
14937         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
14938         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
14939
14940 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14941
14942         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
14943         HP's ANSI C compiler.
14944         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
14945         Declaring int functions causes warnings on some modern systems and
14946         shouldn't be needed to compile on ancient ones.
14947         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
14948         defined.
14949
14950         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
14951         with the following changes.
14952         (__set_errno): Parenthesize properly.
14953         Include <stdbool.h>.
14954         (MIN, MAX, MATCHING_INO): New macros.
14955         (__getcwd): Define with prototype, not K&R form.
14956         Use heuristics to allocate default buffer on stack if possible.
14957         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
14958         behavior, and to avoid the PATH_MAX limit when computing
14959         ../../../../...
14960         Use MATCHING_INO to compare inode number to file.
14961         Check for arithmetic overflow in size calculations.
14962         Fix bug in reallocation of dot array that caused getcwd to fail
14963         on directories nested deeper than 75.
14964         Be more careful about saving errno on error.
14965         Do not use realloc; use only free+malloc, as this is a bit
14966         more flexible and avoids a needless copy operation.
14967         Do not inspect st_dev and st_ino for symbolic links; POSIX
14968         doesn't specify the latter.
14969         Check for closedir errors.
14970         Avoid needless casts.
14971         Use "#ifdef weak_alias" around weak_alias, to be like other
14972         glibc code.
14973         The following changes to getcwd.c have effect only when used in
14974         gnulib; they have no effect inside glibc proper.
14975         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
14976         as alloca isn't used.
14977         (alloca, __alloca): Likewise.
14978         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
14979         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
14980         unconditionally, as gnulib assumes C89 or better.
14981         Do not include <sys/param.h>.
14982         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
14983         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
14984         better.
14985         (NULL) [!defined NULL]: Remove; we assume C89 or better.
14986         Include <dirent.h> in a way that is compatible with modern Autoconf.
14987         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
14988         New macros, if not already defined.
14989         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
14990         Use "_LIBC", not "defined _LIBC", for consistency.
14991         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
14992         a mempcpy module.
14993         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
14994         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
14995         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
14996         credit only to Jim Meyering and adjust the copyright dates.
14997         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
14998         <stdlib.h>, <unistd.h>, "pathmax.h".
14999         Instead, include "xgetcwd.h" (first) and "getcwd.h".
15000         (INITIAL_BUFFER_SIZE): Remove.
15001         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
15002
15003 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
15004
15005         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
15006         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
15007         Use the _ONCE methods, for efficiency.
15008         Check for fcntl.h.  In test program, include <errno.h>
15009         and <fcntl.h> if available.  Remove old K&R cruft from
15010         test program.  Check for common errors in GNU/Linux,
15011         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
15012         don't do AC_LIBOBJ, as that's getcwd.m4's job.
15013         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
15014         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
15015         name accordingly.
15016         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
15017         accommodate new getcwd.c.
15018         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
15019         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
15020         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
15021         that's all we need now.
15022
15023 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15024
15025         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
15026         argp-parse.c depends on getopt internals, that means we should
15027         always use our getopt, to be on the safe side.
15028         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
15029         order not to spoil the result of an eventual previous invocation
15030         of gl_GETOPT_SUBSTITUTE.
15031
15032 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15033
15034         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
15035         redefinition warnings. To avoid them, include the defines
15036         in `#if !defined __need_getopt ... #endif'. The only place
15037         where __getopt_argv_const is used is in definitions
15038         of getopt_long and getopt_long_only below, which are as well
15039         protected by `#ifndef __need_getopt'.
15040         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
15041         __need_getopt after including <stdio.h> and <unistd.h> These
15042         headers might have defined it.
15043
15044 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
15045
15046         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
15047
15048 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
15049
15050         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
15051         (futimens): New function, which uses futimes if available.
15052         (futimens, utimens): Support timespec==NULL, with same semantics
15053         as utime and utimens.
15054         * lib/utimens.h (futimens): New decl.
15055
15056 2004-11-23  Jim Meyering  <jim@meyering.net>
15057
15058         * lib/getopt_.h: Remove trailing blanks.
15059
15060 2004-11-23  Jim Meyering  <jim@meyering.net>
15061
15062         * lib/__fpending.c: Add comment.
15063
15064 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
15065
15066         * modules/canonicalize (Depends-on): Add xreadlink.
15067         Problem reported by James Youngman.
15068
15069 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
15070
15071         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
15072         New macros.
15073         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
15074         optopt): Use them instead of invoking ## directly; otherwise, the
15075         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
15076
15077 2004-11-19  Bruno Haible  <bruno@clisp.org>
15078
15079         * lib/strtok_r.c: Move comments from here...
15080         * lib/strtok_r.h: ... to here.
15081
15082 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
15083
15084         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
15085         implementations that mishandle size_t overflow.
15086
15087 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
15088
15089         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
15090         might fail.  Problem reported by Yoann Vandoorselaere.
15091         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
15092         implementations that mishandle size_t overflow.
15093
15094 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15095
15096         * modules/canon-host (Depends-on): Add strdup.
15097
15098 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15099
15100         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
15101
15102 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15103
15104         * lib/canon-host.c: Include "strdup.h".
15105         (canon_host): Use getaddrinfo if available, so that IPv6 works.
15106         Use strdup instead of malloc/strcpy to duplicate strings.
15107
15108         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
15109         (human_space_before_unit): New constant.
15110         * lib/human.c (human_readable): Support it.
15111
15112         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
15113         (xgetcwd): Set errno correctly when failing.
15114         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
15115         the failure is actually due to a PATH_MAX problem.
15116
15117         Further getopt changes to make it more likely that glibc will
15118         buy the changes back.
15119         * lib/getopt.c (POSIXLY_CORRECT): New constant.
15120         (getopt): Use it, so to preserve glibc semantic
15121         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
15122         when compiling for libc.
15123         * lib/getopt_.h (__getopt_argv_const): Bring it back.
15124         (getopt_long, getopt_long_only): Use it.
15125
15126         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
15127         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
15128         (getopt): Argv is now char * const *, as per standard.
15129         (_getopt_internal_r, _getopt_internal): Argv is now char **,
15130         not char *__getopt_argv_const *.
15131         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
15132         _getopt_long_only_r): Likewise.
15133         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
15134         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
15135         _getopt_long_r, _getopt_long_only_r): Likewise.
15136         * lib/getopt_.h (__getopt_argv_const): Remove.
15137         (getopt): Argv is now char * const *, as per standard.
15138
15139         * lib/getdate.y (tORDINAL): New token.
15140         (day, relunit): Allow it for relative times.
15141         (relative_time_table): Use tORDINAL for ordinals.
15142
15143 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
15144
15145         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
15146         Document that "second" isn't allowed as an ordinal number.
15147
15148 2004-11-16  Jim Meyering  <jim@meyering.net>
15149
15150         * modules/closeout (Depends-on): Add fpending.
15151
15152 2004-11-15  Jim Meyering  <jim@meyering.net>
15153
15154         * lib/closeout.c: Include "__fpending.h" once again.
15155         Include <stdbool.h>.
15156         (close_stdout): Don't fail just because stdout was closed initially,
15157         since some programs don't write to stdout in the normal course of
15158         operation (other than --version and --help), and we don't want this
15159         function to make e.g. `touch file >&-' fail.
15160         But do fail if it was closed and someone has tried to write to it.
15161         E.g., `printf foo >&-' must fail.
15162
15163 2004-11-13  Jim Meyering  <jim@meyering.net>
15164
15165         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
15166
15167 2004-11-12  Simon Josefsson  <jas@extundo.com>
15168
15169         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
15170         small doc fix is still pending.
15171
15172 2004-11-11  Simon Josefsson  <jas@extundo.com>
15173
15174         * modules/strtok_r: New file.
15175
15176         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15177         strtok_r.
15178
15179 2004-11-11  Simon Josefsson  <jas@extundo.com>
15180
15181         * m4/strtok_r.m4: New file.
15182
15183         * m4/getopt.m4: Replace opterr.
15184
15185 2004-11-11  Simon Josefsson  <jas@extundo.com>
15186
15187         * lib/strtok_r.h, strtok_r.c: New file.
15188
15189 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
15190
15191         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
15192         of replacing opterr, getopt, etc.  This should handle the
15193         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
15194
15195 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
15196
15197         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
15198         we can stop lying to compilers about the constness of argv when we
15199         are compiled outside glibc.
15200         (getopt, getopt_long, getopt_long_only): Use it.
15201         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
15202         _getopt_internal, getopt): Likewise.
15203         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
15204         _getopt_long_only_r): Likewise.
15205         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
15206         _getopt_long_r, _getopt_long_only_r): Likewise.
15207
15208         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
15209         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
15210         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
15211         the other external symbols.
15212         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
15213         declaration, since the above renaming now works around collisions.
15214
15215 2004-11-11  Jim Meyering  <jim@meyering.net>
15216
15217         * lib/linebreak.c: Remove trailing blanks.
15218         * lib/alloca_.h: Likewise.
15219         * lib/acosl.c: Likewise.
15220         * lib/euidaccess.c: Likewise.
15221         * lib/allocsa.h: Likewise.
15222
15223 2004-11-10  Simon Josefsson  <jas@extundo.com>
15224
15225         * m4/getaddrinfo.m4: New file.
15226
15227 2004-11-10  Simon Josefsson  <jas@extundo.com>
15228
15229         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
15230
15231 2004-11-10  Simon Josefsson  <jas@extundo.com>
15232
15233         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15234         getaddrinfo.
15235
15236         * modules/getaddrinfo: New file.
15237
15238 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15239
15240         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
15241
15242 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15243
15244         * lib/mktime.c (SHR): New macro, which is a portable
15245         substitute for >> that should work even on Crays.
15246         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
15247         Problem reported by Mark D. Baushke in
15248         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
15249         * lib/getdate.y (SHR): Likewise.
15250         (tm_diff): Use it.
15251         * lib/strftime.c (SHR): Likewise.
15252         (tm_diff): Use it.
15253         * lib/quotearg.c (struct quoting_options): Use unsigned int for
15254         quote_these_too, so that right shifts are well defined.  All uses
15255         changed.
15256
15257 2004-11-10  Jim Meyering  <jim@meyering.net>
15258
15259         Ensure that no close failure goes unreported.
15260         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
15261         return early when it seems there's nothing to flush.
15262         Don't include __fpending.h.
15263
15264 2004-11-10  Jim Meyering  <jim@meyering.net>
15265
15266         * modules/closeout (Depends-on): Remove fpending.
15267
15268 2004-11-10  Jim Meyering  <jim@meyering.net>
15269
15270         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
15271
15272 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
15273
15274         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
15275         gl_FUNC_STRFTIME.
15276         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
15277         and AC_REQUIRE when possible, to avoid duplicate checks.
15278         Check for <wchar.h>.
15279
15280 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
15281
15282         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
15283
15284 2004-11-09  Bruno Haible  <bruno@clisp.org>
15285
15286         * m4/sockpfaf.m4: New file.
15287
15288 2004-11-05  Bruno Haible  <bruno@clisp.org>
15289
15290         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
15291         Reported by Mark D. Baushke <mdb@cvshome.org>.
15292
15293 2004-11-04  Bruno Haible  <bruno@clisp.org>
15294
15295         2004-09-11  Bruno Haible  <bruno@clisp.org>
15296                 * allocsa.valgrind: New file.
15297         2004-02-06  Bruno Haible  <bruno@clisp.org>
15298                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
15299                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
15300                 Reported by Christopher Seip <chris.seip@hp.com>.
15301
15302 2004-11-04  Bruno Haible  <bruno@clisp.org>
15303
15304         * modules/allocsa (Files): Add lib/allocsa.valgrind.
15305         (Makefile.am): Distribute it.
15306
15307 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
15308
15309         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
15310         with errno == ERANGE if the buffer is too small.
15311         Problem reported by Mark D. Baushke.
15312
15313 2004-11-03  Albert Chin  <china@thewrittenword.com>
15314             Paul Eggert  <eggert@cs.ucla.edu>
15315
15316         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
15317         equivalent, substitute $ac_type for equivalent type rather than
15318         blindly using uint32_t *always* which won't work if uint32_t is not
15319         available.  Define _UINT32_T to work around typedef of uint32_t if
15320         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
15321         2.5.1.
15322
15323 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15324
15325         * m4/jm-macros.m4: Sync from coreutils.
15326         (gl_MACROS): Check for mbrlen, for pathchk.
15327         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
15328
15329 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15330
15331         * lib/xreadlink.c (MAXSIZE): New macro.
15332         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
15333         size does not exceed MAXSIZE.  Avoid cast.
15334         As suggested by Mark D. Baushke in
15335         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
15336         if readlink fails with buffer size just under MAXSIZE, try again
15337         with MAXSIZE.
15338
15339 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
15340
15341         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
15342
15343 2004-11-02  Derek R. Price  <derek@ximbiot.com>
15344         and  Paul Eggert  <eggert@cs.ucla.edu>
15345
15346         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
15347         (get_date): Overparenthesize to avoid GCC warning.
15348
15349 2004-11-02  Bruno Haible  <bruno@clisp.org>
15350
15351         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
15352         returns void.
15353
15354 2004-11-02  Bruno Haible  <bruno@clisp.org>
15355
15356         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
15357         function returns void.
15358
15359 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
15360
15361         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
15362         fflush_unlocked, flockfile, funlockfile, funlockfile,
15363         fputs_unlocked, putc_unlocked.
15364
15365 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
15366
15367         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
15368         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
15369         already declared.
15370
15371 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15372
15373         * modules/getdate (Files): Add doc/getdate.texi.
15374         (Depends-on): Add setenv, xalloc.
15375
15376 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15377
15378         * lib/getdate.y: Add support for TZ="foo" within a date string.
15379         Fix some bugs near time_t boundaries.  Reject dates with
15380         out-of-range components, e.g., "Sept 31".
15381         Include <stdlib.h>, "setenv.h", "xalloc.h".
15382         (ISDIGIT_LOCALE): Remove; unused.
15383         Note that the TZ and time functions used here are not reentrant.
15384         (mktime_ok, get_tz): New functions.
15385         (TZBUFSIZE): New constant.
15386         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
15387         This requires that we sometimes generate our own TZ="XXX..." setting.
15388
15389 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15390
15391         * doc/getdate.texi: New file, from coreutils with modifications for
15392         the new TZ parsing.
15393
15394 2004-10-27  Derek R. Price  <derek@ximbiot.com>
15395
15396         * lib/mktime.c (not_equal_tm): Remove redundant check.
15397
15398 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
15399
15400         * modules/regex (lib_SOURCES): Add regex.c.
15401         Reported by James Youngman in
15402         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
15403
15404 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
15405
15406         * lib/getdate.y: Use Bison 1.875 features, and some minor
15407         code cleanups.  This change does not affect semantics.
15408         Don't include <stdlib.h>; no longer needed.
15409         Don't include unlocked-io.h; only the "#if TEST" code uses
15410         stdio, and performance isn't crucial there.
15411         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
15412         Bison 1.875 features as described below.
15413         All uses of "PC." replaced by "pc->".
15414         (YYSTYPE): Add a forward declaration.
15415         (yylex, yyerror): Use full prototypes in forward decls.
15416         Use "%pure-parser" rather than obsolescent "%pure_parser".
15417         Use %parse-param and %lex-param instead of obsolescent
15418         YYPARSE_PARAM and YYLEX_PARAM.
15419         (meridian_table, month_and_day_table, time_units_table,
15420         relative_time_table, time_zone_table, military_table,
15421         lookup_zone, lookup_word, get_date):
15422         Use NULL instead of 0 where appropriate.
15423         (to_hour): Avoid abort (), to avoid a dependency on
15424         stdlib.h.
15425         (yyerror, yylex): Now accepts parser_control * arg.
15426         (main) [TEST]: Use '\0' rather than 0 for char.
15427
15428 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
15429
15430         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
15431
15432 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
15433
15434         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
15435         It's now the caller's responsibility to handle the case where
15436         !HAVE_GETPAGESIZE && !defined getpagesize.
15437
15438         * lib/mktime.c (leapyear): Arg is long int, not int.
15439
15440 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
15441
15442         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
15443
15444 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
15445
15446         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
15447         missing.  Problem reported by James Youngman.
15448
15449 2004-10-16  Simon Josefsson  <jas@extundo.com>
15450
15451         * gnulib-tool: Fix comments.  Fix parse problem.
15452         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
15453
15454 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
15455
15456         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
15457         implementation of getopt_long.  Problem reported by Alexander Taler in:
15458         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
15459
15460 2004-10-15  Bruno Haible  <bruno@clisp.org>
15461
15462         * gnulib-tool: Untabify. Initialize supplied_libname.
15463         (func_usage): More homogenous output.
15464         (func_modules_transitive_closure, func_modules_to_filelist,
15465         func_emit_lib_Makefile_am): New functions.
15466         (func_import): New function, extracted from big case statement. Use
15467         func_get_license, func_modules_transitive_closure,
15468         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
15469         opt_lgpl. Don't use test -a, as it's not portable.
15470         (func_create_testdir): Use func_modules_transitive_closure,
15471         func_modules_to_filelist, func_emit_lib_Makefile_am.
15472
15473 2004-10-15  Bruno Haible  <bruno@clisp.org>
15474
15475         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
15476
15477 2004-10-15  Bruno Haible  <bruno@clisp.org>
15478
15479         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
15480         the portions belonging to each module.
15481         Suggested by Derek Robert Price <derek@ximbiot.com>.
15482
15483 2004-10-12  Simon Josefsson  <jas@extundo.com>
15484
15485         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
15486         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
15487         to real functions.
15488
15489 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15490
15491         * modules/vsnprintf: New file.
15492
15493 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15494
15495         * m4/vsnprintf.m4: New file.
15496
15497 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15498
15499         * lib/vsnprintf.h: New file.
15500         * lib/vsnprintf.c: New file.
15501
15502 2004-10-11  Bruno Haible  <bruno@clisp.org>
15503
15504         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
15505         vsnprintf.
15506
15507 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
15508
15509         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
15510
15511 2004-10-07  Bruno Haible  <bruno@clisp.org>
15512
15513         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
15514         fits into the provided buffer.
15515
15516 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
15517
15518         * lib/diacrit.c, diacrit.h: Add GPL notice.
15519
15520         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
15521         notice.
15522         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
15523         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
15524         This avoids a potential constant-folding bug.
15525
15526 2004-10-05  Bruno Haible  <bruno@clisp.org>
15527
15528         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
15529         for the declaration of strsep.
15530
15531 2004-10-05  Bruno Haible  <bruno@clisp.org>
15532
15533         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
15534
15535 2004-10-04  Simon Josefsson  <jas@extundo.com>
15536
15537         * modules/memmem: New file.
15538         * tests/test-memmem.c: New file.
15539         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
15540
15541 2004-10-04  Simon Josefsson  <jas@extundo.com>
15542
15543         * m4/memmem.m4: New file.
15544
15545 2004-10-04  Simon Josefsson  <jas@extundo.com>
15546
15547         * lib/memmem.h: New file.
15548         * lib/memmem.c: New file, taken from glibc.
15549
15550 2004-10-04  Simon Josefsson  <jas@extundo.com>
15551
15552         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
15553         '#ifdef USE_UNLOCKED_IO'.
15554
15555 2004-10-04  Simon Josefsson  <jas@extundo.com>
15556
15557         * config/srclist.txt: Add memmem from glibc.
15558
15559 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15560
15561         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
15562
15563         * modules/argmatch, modules/argp, modules/closeout, modules/error,
15564         modules/exclude, modules/getdate, modules/getline,
15565         modules/getndelim2, modules/getpass, modules/getpass-gnu,
15566         modules/getusershell, modules/linebuffer, modules/md5,
15567         modules/mountlist, modules/posixtm, modules/readtokens,
15568         modules/readutmp, modules/regex, modules/sha1,
15569         modules/version-etc, modules/yesno:
15570         Remove dependency on unlocked-io.
15571
15572 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15573
15574         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
15575
15576         * m4/unlocked-io.m4: Add copyright notice.
15577         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
15578
15579 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15580
15581         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
15582         * lib/xmalloc.c (xmemdup): Likewise.
15583         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
15584         XFREE): Remove these long-obsolescent macros.
15585         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
15586         * lib/xstrdup.c: Remove.
15587
15588         * lib/regex.c (re_comp): Cast gettext return value to char *,
15589         Problem reported by Martin Neitzel via Mark D. Baushke.
15590
15591 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
15592
15593         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
15594         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
15595         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
15596         regex.c, sha1.c, version-etc.c, yesno.c:
15597         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
15598         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
15599         the includer's responsibility.
15600
15601         Sync from coreutils.
15602
15603         * lib/modechange.c (mode_compile): Don't decrement a pointer that
15604         points to the start of a string, as the C Standard says the
15605         resulting behavior is undefined.
15606
15607         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
15608         simple -> simple_backups, numbered_existing ->
15609         numbered_existing_backups, numbered -> numbered_backups
15610         to avoid shadowing problems.  All uses changed.
15611         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
15612         * lib/backupfile.c (check_extension, numbered_backup):
15613         Rename locals to avoid shadowing 'basename'.
15614         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
15615         once.
15616
15617         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
15618         * lib/.cvsignore: Add getopt.h.
15619
15620 2004-10-04  Bruno Haible  <bruno@clisp.org>
15621
15622         * modules/README: New file.
15623         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
15624         not a module.
15625
15626 2004-10-02  Jim Meyering  <jim@meyering.net>
15627
15628         * lib/dirfd.h, getpagesize.h: Add copyright notice.
15629
15630 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15631
15632         * modules/strsep: New file.
15633
15634 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15635
15636         * m4/strsep.m4: New file.
15637
15638 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
15639
15640         * lib/strsep.h: New file.
15641         * lib/strsep.c: New file.
15642
15643 2004-10-01  Simon Josefsson  <jas@extundo.com>
15644
15645         * lib/snprintf.c (snprintf): Handle size==0.
15646
15647 2004-10-01  Simon Josefsson  <jas@extundo.com>
15648             Bruno Haible  <bruno@clisp.org>
15649
15650         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
15651         (snprintf): Declare 'args'.
15652
15653 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
15654
15655         * lib/snprintf.c: Remove comments as to why each header is needed.
15656
15657 2004-10-01  Bruno Haible  <bruno@clisp.org>
15658
15659         * MODULES.html.sh: Add strsep.
15660
15661 2004-09-30  Simon Josefsson  <jas@extundo.com>
15662
15663         * modules/snprintf: New file.
15664
15665 2004-09-30  Simon Josefsson  <jas@extundo.com>
15666
15667         * m4/snprintf.m4: New file.
15668
15669 2004-09-30  Simon Josefsson  <jas@extundo.com>
15670
15671         * lib/snprintf.h, lib/snprintf.c: New files.
15672
15673 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15674
15675         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
15676         (hol_entry_help): Never translate an empty string.
15677         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
15678         * lib/argp.h (OPTION_NO_TRANS): New option.
15679
15680 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
15681
15682         * modules/argp (Maintainer): Replace Simon Josefsson
15683         by Sergey Poznyakoff.
15684
15685 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
15686
15687         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
15688         changes merged back into glibc.
15689
15690 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
15691
15692         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
15693
15694 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
15695
15696         * lib/xvasprintf.c: Include xalloc.h.
15697         (xvasprintf): Use xalloc_die, not xmalloc_die.
15698
15699 2004-09-29  Bruno Haible  <bruno@clisp.org>
15700
15701         * modules/alloca-opt: New file, derived from modules/alloca.
15702         * modules/allocsa: Depend on alloca-opt instead of alloca.
15703         * modules/setenv: Likewise.
15704         * modules/vasnprintf: Likewise.
15705         * MODULES.html.sh: Add alloca-opt.
15706
15707 2004-09-28  Simon Josefsson  <jas@extundo.com>
15708
15709         * gnulib-tool: New parameter --lgpl, to asseert that modules are
15710         LGPL, and to replace license template from GPL to LGPL.
15711
15712 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
15713
15714         * modules/dummy: Change license to LGPL.
15715
15716 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
15717
15718         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
15719
15720 2004-09-24  Simon Josefsson  <jas@extundo.com>
15721
15722         * modules/minmax (License): Change from GPL to LGPL.
15723
15724 2004-09-23  Simon Josefsson  <jas@extundo.com>
15725
15726         * gnulib-tool (--import): Typo.
15727
15728 2004-09-23  Simon Josefsson  <jas@extundo.com>
15729
15730         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
15731
15732 2004-09-22  Bruno Haible  <bruno@clisp.org>
15733
15734         * modules/*: Add 'License' field.
15735         * gnulib-tool: Accept --extract-license option.
15736         (func_get_license): New function.
15737
15738 2004-09-21  Bruno Haible  <bruno@clisp.org>
15739
15740         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
15741         Reported by Simon Josefsson.
15742
15743 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
15744
15745         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
15746         gl_AC_TYPE_LONG_LONG.
15747
15748 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
15749
15750         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
15751
15752 2004-09-18  Simon Josefsson  <jas@extundo.com>
15753         and  Paul Eggert  <eggert@cs.ucla.edu>
15754
15755         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
15756         calls with autoreconf.  Define GL_LIB.
15757
15758 2004-09-14  Karl Berry  <karl@gnu.org>
15759
15760         * config/srclist.txt: unsync setenv.c, sigh.
15761
15762 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
15763
15764         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
15765         Problem reported by Bruno Haible in:
15766         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
15767
15768 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
15769
15770         * config/srclist.txt: Comment out argp-pvh.c.
15771
15772 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
15773
15774         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
15775         in case some system header has #define'd it.  Problem reported by
15776         Soeren D. Schulze in
15777         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
15778
15779 2004-09-09  Karl Berry  <karl@gnu.org>
15780
15781         * regex.[ch]: delete from the root.  These were supposed to be
15782                 synced with emacs cvs, but this has not happened for about
15783                 a year, and anyway nothing else uses emacs regex.[ch].
15784                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
15785                 lib/regex[.ch] is untouched.
15786
15787 2004-09-09  Bruno Haible  <bruno@clisp.org>
15788
15789         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
15790
15791 2004-09-09  Bruno Haible  <bruno@clisp.org>
15792
15793         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
15794         modifications.
15795         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
15796
15797 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
15798
15799         * modules/xvasprintf: New file.
15800         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
15801
15802 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
15803
15804         * lib/xvasprintf.h: New file.
15805         * lib/xvasprintf.c: New file.
15806         * lib/xasprintf.c: New file.
15807
15808 2004-09-08  Bruno Haible  <bruno@clisp.org>
15809
15810         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
15811
15812 2004-09-08  Bruno Haible  <bruno@clisp.org>
15813
15814         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
15815         length is > INT_MAX.
15816         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
15817         more.
15818
15819 2004-09-08  Bruno Haible  <bruno@clisp.org>
15820
15821         * lib/stdint_.h: New file, taken from GNU clisp.
15822
15823 2004-09-08  Bruno Haible  <bruno@clisp.org>
15824             Oskar Liljeblad  <oskar@osk.mine.nu>
15825
15826         * modules/stdint: New file.
15827         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
15828
15829 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15830
15831         Import from coreutils.
15832         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
15833         strings on unbounded length.  alloca's performance benefits aren't
15834         that important here.
15835         (V_STRDUP): Remove.
15836         (parse_with_separator): New function, with most of the internals
15837         of the old parse_user_spec.  Allow user to omit both user and group,
15838         for compatibility with FreeBSD.
15839         Clone only the user name, not the entire spec.
15840         Do not set *uid, *gid unless entirely successful.
15841         Avoid memory leak in some failing cases.
15842         Fix regression for USER.GROUP reported by Dmitry V. Levin in
15843         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
15844         (parse_user_spec): Rewrite to use parse_with_separator.
15845
15846 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15847
15848         * modules/userspec: Don't depend on alloca.
15849
15850 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15851
15852         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
15853
15854 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15855
15856         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
15857         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
15858         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
15859
15860 2004-08-16  Simon Josefsson  <jas@extundo.com>
15861
15862         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
15863         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
15864         Add --dry-run for --import.
15865         Let user provided command line parameters override configure.ac
15866         settings.
15867
15868 2004-08-12  Simon Josefsson  <jas@extundo.com>
15869
15870         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
15871         as discussed with Paul Eggert in threads rooted at
15872         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
15873         and
15874         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
15875         Before, the test was empty, and relied on ELIDE_CODE in source
15876         code.)
15877         (gl_PREREQ_GETOPT): New macro.
15878         (gl_GETOPT): Use them.
15879
15880 2004-08-12  Simon Josefsson  <jas@extundo.com>
15881
15882         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
15883         * lib/getopt_.h: Renamed from getopt.h.
15884
15885 2004-08-12  Simon Josefsson  <jas@extundo.com>
15886
15887         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
15888         Change default library name from libfoo to libgnu.
15889         Now, if you have a configure.ac that says:
15890                 gl_SOURCE_BASE(gl)
15891                 gl_M4_BASE(gl/m4)
15892                 gl_MODULES(error getopt etcetera)
15893                 gl_INIT
15894         you can import all you need by running:
15895                 ../gnulib/gnulib-tool --import
15896
15897         * modules/getopt (Files): Rename getopt.h to getopt_.h.
15898         (Makefile.am): Rewrite, use logic from argz.
15899         (Include): Use <getopt.h> instead of "getopt.h".
15900
15901 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15902
15903         * modules/argp (Files): Add m4/unlocked-io.m4.
15904         (Depends-on): Add extensions.
15905
15906 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15907
15908         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
15909         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
15910         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
15911         Check for program_invocation_name, program_invocation_short_name,
15912         flockfile, funlockfile, features.h, _getopt_long_only_r.
15913
15914 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15915
15916         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
15917         its complicated substitute.
15918         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
15919         and program_invocation_name.
15920         (__argp_basename) [!_LIBC]: Remove; the only use was
15921         replaced by its body.
15922         (__argp_short_program_name): Change condition from
15923         !defined __argp_short_program_name to
15924         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
15925         to match argp-namefrob.h.
15926         (__argp_failure): Don't assume strerror_r returns char *.
15927         * lib/argp-parse.c (N_): Define unconditionally.
15928         (argp_default_options): Fill out initializers with 0 to avoid
15929         gcc warnings.
15930
15931 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15932
15933         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
15934         getopt1.c.
15935
15936 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15937
15938         Merge from coreutils.
15939
15940         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
15941
15942         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
15943         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
15944
15945 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15946
15947         Merge from coreutils.
15948
15949         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
15950         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
15951         for Reliant Unix 5.43.
15952
15953         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
15954         (union fooround): Use uintmax_t, not long int.
15955         The rest is a merge from libc:
15956         [defined _LIBC]: Include <shlib-compat.h>.
15957         (_obstack) [defined _LIBC]: Remove after 2.3.4.
15958
15959         * lib/settime.c (settime): Recode to avoid warning with
15960         Sun Forte C 6U2.
15961
15962         * lib/strverscmp.c: Convert to UTF-8.
15963
15964 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15965
15966         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
15967         m4/uintmax_t.m4.
15968
15969 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15970
15971         * modules/xalloc-die: New file.
15972         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
15973
15974         * modules/md5 (Files): Add m4/uint32_t.m4.
15975         * modules/sha1: Renamed from modules/sha.
15976         (Files):
15977         Rename lib/sha.h to lib/sha1.h.
15978         Rename lib/sha.c to lib/sha1.c.
15979         Rename m4/sha.m4 to m4/sha1.m4.
15980         (lib_SOURCES): Likewise.
15981         (configure.ac): Rename gl_SHA to gl_SHA1.
15982         (Include): sha.h -> sha1.h.
15983
15984 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15985
15986         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
15987         * m4/sha1.m4: Renamed from sha.m4.
15988         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
15989
15990 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15991
15992         * lib/obstack.h (obstack_empty_p):
15993         Don't assume that chunk->contents is suitably aligned.
15994         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
15995         Likewise. Problem reported by Benno in
15996         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
15997
15998         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
15999         readable.  This could be improved further but it'd take some work.
16000
16001 2004-08-08  Simon Josefsson  <jas@extundo.com>
16002
16003         * modules/xgethostname (Depends-on): Remove exit and error (not
16004         used).
16005
16006         * modules/getpass-gnu: Add getpass.h.
16007         (Depends-on): Add stdbool.
16008         * modules/getpass: Add getpass.h.
16009
16010 2004-08-08  Simon Josefsson  <jas@extundo.com>
16011
16012         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
16013         Check getpass declaration.
16014
16015 2004-08-08  Simon Josefsson  <jas@extundo.com>
16016
16017         * lib/xgethostname.c: Don't include error.h (not used).
16018
16019         * lib/getpass.h: Add.
16020         * lib/getpass.c: Include getpass.h first.
16021
16022 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
16023
16024         * lib/xalloc-die.c: New file.
16025         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
16026         All uses removed.
16027         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
16028         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
16029         xalloc-die.c.
16030         (_, N_, xalloc_die): Move to xalloc-die.c.
16031         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
16032         so that we needn't mess with xalloc_msg_memory_exhausted.
16033
16034         * lib/sha1.h: Renamed from sha.h.
16035         (SHA1_H): Renamed from _SHA_H.
16036         (sha1_ctx): Renamed from sha_ctx.
16037         (sha1_init_ctx): Renamed from sha_init_ctx.
16038         (sha1_process_block): Renamed from sha_process_block.
16039         (sha1_process_bytes): Renamed from sha_process_bytes.
16040         (sha1_finish_ctx): Renamed from sha_finish_ctx.
16041         (sha1_read_ctx): Renamed from sha_read_ctx.
16042         (sha1_stream): Renamed from sha_stream.
16043         (sha1_buffer): Renamed from sha_buffer.
16044         * lib/sha1.c: Likewise; renamed from sha.c.
16045         Do not include <sys/types.h>.
16046         Include <stddef.h> rather than <stdlib.h>.
16047
16048 2004-08-08  Bruno Haible  <bruno@clisp.org>
16049
16050         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
16051         FILESYSTEM_PREFIX_LEN.
16052         * lib/progreloc.c: Likewise.
16053         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
16054
16055 2004-08-06  Simon Josefsson  <jas@extundo.com>
16056
16057         * modules/progname (Depends-on): Don't depend on stdbool.
16058
16059 2004-08-06  Simon Josefsson  <jas@extundo.com>
16060
16061         * modules/getsubopt: New file.
16062         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16063         getsubopt.
16064
16065 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16066
16067         More merge from coreutils.
16068
16069         * m4/utimens.m4, m4/utimecmp.m4: New files.
16070         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
16071         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
16072         prereq.m4, sha.m4: Import changes from coreutils.
16073
16074 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16075
16076         More merge from coreutils.
16077         * modules/raise, modules/readtokens0, modules/utimens:
16078         * modules/utimecmp, module/xnanosleep: New files.
16079         * modules/strftime: Add lib/strftime.h.
16080         Change include from <time.h> to "strftime.h".
16081         * modules/yesno: Add lib/yesno.h.
16082         * modules/backupfile: Remove lib/addext.c.
16083         * modules/euidaccess: Add stat-macros.h.
16084         * modules/canonicalize, modules/euidaccess,
16085         modules/filemode, modules/lchown, modules/makepath,
16086         modules/rmdir, modules/stat: Likewise.
16087
16088 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
16089
16090         Merge from tar.
16091         * lib/argp-help.c (make_hol, hol_append): Don't assume that
16092         SIZE_MAX is a valid preprocessor constant.
16093         (__argp_basename): Change from "#ifndef _LIBC"
16094         to "#ifndef __argp_short_program_name", so that
16095         we don't compile these functions for tar.
16096
16097         More merges from coreutils.
16098         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
16099         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
16100         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
16101         * lib/addext.c: Remove; no longer needed.
16102         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
16103         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
16104         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
16105         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
16106         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
16107         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
16108         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
16109         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
16110         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
16111         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
16112         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
16113         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
16114         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
16115         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
16116         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
16117         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
16118         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
16119         Import changes from coreutils.
16120
16121 2004-08-05  Simon Josefsson  <jas@extundo.com>
16122
16123         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
16124
16125 2004-08-05  Simon Josefsson  <jas@extundo.com>
16126
16127         * m4/getsubopt.m4: New file.
16128
16129 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16130
16131         Merge from coreutils.
16132
16133         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
16134         * m4/getcwd-path-max.m4: New files.
16135
16136         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
16137         FILESYSTEM_PREFIX_LEN ->
16138         FILE_SYSTEM_PREFIX_LEN.
16139         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
16140         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
16141         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
16142         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
16143
16144         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
16145         prerequisite modules now handle the DOS stuff.
16146         Don't check for unistd.h.
16147
16148 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16149
16150         Merge from coreutils.
16151
16152         * lib/.gdb-history: Remove; this doesn't belong here.
16153
16154         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
16155         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
16156         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
16157         * lib/getcwd.c: New files.
16158
16159         * lib/dirname.h: Include <stdbool.h>.
16160         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
16161         for consistency with POSIX terminology.  All uses changed.
16162         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
16163         (strip_trailing_slashes): Use bool for booleans.
16164         * lib/stripslash.c (strip_trailing_slashes): Likewise.
16165
16166         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
16167         sometimes returns a positive errno value even when it succeeds.
16168         (print_errno_message) [!LIBC]: Fall back on strerror if
16169         __strerror_r fails.
16170
16171         * lib/path-concat.c (mempcpy): Don't define if a system header defines
16172         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
16173         (longest_relative_suffix): New function.
16174         (path_concat): Use it.  Assume first argument is not NULL.
16175         Port to DOS.  Omit redundant separators.
16176         Report an error instead of returning NULL.
16177         Use mempcpy instead of memcpy.
16178         (xpath_concat): Remove: not declared or used.
16179
16180         * lib/same.h: Include <stdbool.h>
16181         (same_name): Return bool, not int.
16182         * lib/same.c (same_name): Likewise.
16183         (errno): Don't declare; we assume C89 or better now.
16184
16185         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
16186         if not already defined.
16187
16188         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
16189         * lib/dup-safer.c (errno): Likewise.
16190
16191 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
16192
16193         Merge from coreutils.
16194         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
16195         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
16196         * modules/path-concat: Don't depend on strdup.
16197
16198 2004-08-03  Simon Josefsson  <jas@extundo.com>
16199
16200         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
16201         * lib/progname.h: Don't include stdbool.h.
16202
16203 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16204
16205         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
16206         * MODULES.html.sh (func_all_modules): Remove fatal.
16207
16208 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16209
16210         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
16211
16212 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
16213
16214         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
16215         working.
16216
16217 2004-08-02  Simon Josefsson  <jas@extundo.com>
16218
16219         * lib/getsubopt.h: New file, with comments from Bruno Haible.
16220         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
16221         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
16222
16223 2004-08-01  Simon Josefsson  <jas@extundo.com>
16224
16225         * lib/xgetdomainname.c: Include stdlib.h, for free().
16226
16227 2004-07-19  Bruno Haible  <bruno@clisp.org>
16228
16229         * MODULES.html.sh (func_all_modules): Add dummy.
16230
16231 2004-07-16  Simon Josefsson  <jas@extundo.com>
16232
16233         * modules/dummy: New file.
16234
16235 2004-07-16  Simon Josefsson  <jas@extundo.com>
16236
16237         * lib/dummy.c: New file.
16238
16239 2004-07-16  Bruno Haible  <bruno@clisp.org>
16240
16241         * lib/backupfile.h: Add extern "C" for C++.
16242         * lib/closeout.h: Likewise.
16243         * lib/copy-file.h: Likewise.
16244         * lib/findprog.h: Likewise.
16245         * lib/full-write.h: Likewise.
16246         * lib/pathname.h: Likewise.
16247         * lib/progname.h: Likewise.
16248         * lib/stpcpy.h: Likewise.
16249         * lib/stpncpy.h: Likewise.
16250         * lib/strcase.h: Likewise.
16251         * lib/strstr.h: Likewise.
16252         * lib/xalloc.h: Likewise.
16253
16254         * lib/mbswidth.h: Add extern "C" for C++.
16255         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
16256
16257 2004-07-13  Robert Millan  <robertmh@gnu.org>
16258
16259         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
16260
16261 2004-07-09  Simon Josefsson  <jas@extundo.com>
16262
16263         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
16264         failed without this.)
16265
16266 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
16267
16268         * modules/chown (Files): Add lib/fchown-stub.c, since
16269         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
16270
16271 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
16272
16273         * lib/fchown-stub.c: New file.
16274
16275 2004-06-24  Jim Meyering  <jim@meyering.net>
16276
16277         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
16278
16279 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16280
16281         * modules/argz: Omit "#include".
16282
16283         * MODULES.html.sh (func_all_modules): Add calloc, to match
16284         2004-06-01 addition of calloc module.
16285
16286 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16287
16288         * m4/argz.m4: New file, which is autoupdated from libtool.
16289
16290 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16291
16292         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
16293         libtool.
16294
16295 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16296
16297         * config/srclist-update: Don't insist on "USA." before the
16298         close-comment, as libtool omits the period and puts the */ on a
16299         separate line.
16300         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
16301         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
16302
16303 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
16304
16305         * modules/argz: New file.
16306         * MODULES.html.sh (func_all_modules): Add argz.
16307
16308 2004-06-12  Jim Meyering  <jim@meyering.net>
16309         and  Paul Eggert  <eggert@cs.ucla.edu>
16310
16311         * modules/hash (Files): Add lib/xalloc.h.
16312         * modules/pipe (Depends-on): Add wait-process.
16313         * modules/stat (Depends-on): Add xalloc.
16314         * modules/userspec (Files): Add lib/userspec.h.
16315         * modules/xstrto
16316
16317         Upgrade from gettext-0.13.
16318         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
16319         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
16320         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
16321
16322 2004-06-10  Jim Meyering  <jim@meyering.net>
16323
16324         * lib/calloc.c: New file.
16325
16326 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
16327
16328         * lib/getdate.y (yylex): Allow space between sign and number.
16329         Problem reported by Dan Jacobson.
16330
16331 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
16332
16333         Merge from coreutils CVS.
16334
16335         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
16336         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
16337         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
16338         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
16339         xstrtol.m4: Fix copyright date and/or serial number.
16340
16341         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
16342         See if we need an fchown replacement.
16343         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
16344         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
16345         and use the replacement function if we detect either defect.
16346
16347         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
16348         gl_UTIMECMP.
16349
16350 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
16351         and  Jim Meyering  <jim@meyering.net>
16352
16353         Merge from coreutils CVS.
16354
16355         * lib/stat-macros.h: New file, with contents from file-type.h
16356         and coreutils' system.h.
16357         * lib/file-type.c: Include "stat-macros.h".
16358         * lib/file-type.h (file_type): Move all macro definitions to new file,
16359         stat-macros.h.
16360
16361         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
16362         Wrap old code with this conditional.
16363         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
16364         function that does not dereference symlinks.
16365         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
16366
16367         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
16368         dependency problems.
16369         (xreadlink): Accept new arg SIZE, for efficiency.
16370         All decls and uses changed.
16371         * lib/xreadlink.h: Include <stddef.h>, for size_t.
16372
16373         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
16374         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
16375
16376         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
16377         sysexits.h.
16378
16379 2004-06-01  Jim Meyering  <jim@meyering.net>
16380
16381         * m4/calloc.m4: New file.
16382
16383 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
16384
16385         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
16386         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
16387         Also, fix a typo in a diagnostic.
16388
16389 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
16390
16391         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
16392         or AC_FUNC_REALLOC.
16393
16394 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
16395
16396         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
16397         macros to be defined.
16398         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
16399         the allocator returns NULL because the requested size is zero.
16400
16401 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16402
16403         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
16404         var.  Add comment explaining why libc still defines it.  This
16405         merges the following patch from glibc:
16406         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
16407
16408 2004-05-20  Andreas Schwab  <schwab@suse.de>
16409
16410         * m4/free.m4: Replace free if it not known to work, not the other
16411         way round.
16412
16413 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
16414
16415         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
16416         present in glibc since revision 1.1 of this file.
16417         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
16418         obstack_alignment_mask, obstack_alloc, obstack_base,
16419         obstack_blank, obstack_blank_fast, obstack_chunk_size,
16420         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
16421         obstack_grow0, obstack_init, obstack_int_grow,
16422         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
16423         obstack_next_free, obstack_object_size, obstack_ptr_grow,
16424         obstack_ptr_grow_fast, obstack_room): Remove declarations of
16425         nonexistent functions.
16426
16427 2004-05-18  Karl Berry  <karl@gnu.org>
16428
16429         * config/srclist.txt: break link for vasnprintf.c.
16430
16431 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
16432
16433         Port obstack to the AS/400, where pointers are 16 bytes wide and
16434         you cannot cast an integer to a valid pointer.  This patch is
16435         currently waiting to be integrated into glibc; see
16436         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
16437
16438         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
16439         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
16440         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
16441         (struct obstack): temp member is now a union of a pointer and
16442         an integer, instead of an integer.  All integer uses changed.
16443         This does not affect the physical layout of struct obstack,
16444         except on hosts (like the AS/400) where the size or alignment of
16445         void * is greater than that of ptrdiff_t.
16446         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
16447         __STDC__)]: Store temporary in pointer member of union, not
16448         integer member.
16449         * lib/obstack.c: Include <stddef.h>, for offsetof.
16450         (struct fooalign): Remove; it doesn't need a name.
16451         (union fooround): Change double to long double, and add void *.
16452         (DEFAULT_ALIGNMENT): Use offsetof to compute.
16453         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
16454         not a macro.  Hence the values are always int; so remove all
16455         casts-to-int in uses.
16456
16457 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
16458
16459         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
16460         we can get this patch merged into glibc.
16461
16462 2004-05-17  Derek R. Price  <derek@ximbiot.com>
16463             Paul Eggert  <eggert@cs.ucla.edu>
16464
16465         * m4/argp: Depend on alloca.
16466
16467 2004-05-17  Derek R. Price  <derek@ximbiot.com>
16468             Paul Eggert  <eggert@cs.ucla.edu>
16469
16470         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
16471         freecoding.
16472
16473 2004-05-17  Bruno Haible  <bruno@clisp.org>
16474
16475         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
16476         precision that consists of a '.' followed by an empty digit string.
16477         Patch by Tor Lillqvist <tml@iki.fi>.
16478
16479 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
16480
16481         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
16482         for backward compatibility with older code.  We need our own
16483         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
16484         it under some other name, and our alloca.h will define it.
16485
16486 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
16487             Derek Price  <derek@ximbiot.com>
16488
16489         * lib/alloca.c: Include <alloca.h>, to get our interface.
16490         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
16491         include <alloca.h> first.  Use C89 prototype for alloca; this
16492         requires including <stddef.h> for size_t.  Use extern "C" if C++.
16493         Use #elif for simplicity, since we can assume C89 now.
16494         Don't try to source the system alloca.h since it will not be found
16495         and to prevent recursively including its replacement.
16496         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
16497         * lib/regex.c: Likewise.
16498
16499 2004-05-16  Derek Price  <derek@ximbiot.com>
16500             Paul Eggert  <eggert@cs.ucla.edu>
16501
16502         getline cleanup.  This changes the getndelim2 API: both order of
16503         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
16504         no delimiter).
16505
16506         * lib/getline.c: Don't include stddef.h or stdio.h, since our
16507         interface does that.
16508         (getline): Always use getdelim, so that we don't have two
16509         copies of this code.
16510         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
16511         if available.
16512         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
16513         (GETNDELIM2_MAXIMUM): New macro.
16514         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
16515         instead of the old practice of delim2==0.  All callers changed.
16516         Return -1 on overflow, instead of returning junk.
16517         Do not set *linesize unless allocation succeeds.
16518         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
16519         that we include sys/types.h.
16520         * lib/getnline.h: Likewise.
16521         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
16522         (getndelim2): Reorder arguments.
16523         * lib/getnline.c (getnline, getndelim):
16524         Don't discard the NMAX argument.
16525         (getnline): Invoke getndelim, to avoid code duplication.
16526         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
16527         of (size_t) -1 by callers of the getnline family.
16528
16529 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16530
16531         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
16532         Check for gettimeofday.
16533         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
16534         Check for settimeofday, stime.
16535
16536 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16537
16538         * lib/nanosleep.c (suspended): Change its type from int to
16539         sig_atomic_t volatile.
16540         (first_call): Make it private to rpl_nanosleep, and have it
16541         be zero initially as that's a bit faster.
16542         (my_usleep): Round up fractional times instead of truncating them,
16543         as this is the usual meaning for 'sleep'.
16544
16545         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
16546         doesn't work.
16547         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
16548         (ENOSYS): Define if not defined.
16549         (settime): Fall back on stime if it exists and settimeofday fails.
16550         But don't bother with fallbacks if a method fails with errno == EPERM.
16551
16552 2004-05-11  Jim Meyering  <jim@meyering.net>
16553
16554         Prior to this change, the save_cwd caller required read access to the
16555         current directory on most systems (ones with the fchdir function).
16556
16557         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
16558         fails, try write-only, and finally, resort to using xgetcwd.
16559
16560 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
16561
16562         * lib/obstack.c, obstack.h: Import changes from libc.
16563
16564 2004-04-28  Bruno Haible  <bruno@clisp.org>
16565
16566         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
16567         also implicitly appends .exe to executables.
16568         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
16569         accepts Windows pathnames.
16570         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
16571         Treat Cygwin like Windows, since it now accepts Windows pathnames.
16572         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
16573         Treat Cygwin like Windows, since it now accepts Windows pathnames.
16574         Reported by Derek Robert Price <derek@ximbiot.com>.
16575
16576 2004-04-21  Karl Berry  <karl@gnu.org>
16577
16578         * config/srclist.txt (localcharset.c): break sync.
16579
16580 2004-04-20  Paul Eggert  <eggert@twinsun.com>
16581
16582         * m4/host-os.m4: Add a copyright notice.
16583
16584 2004-04-20  Jim Meyering  <jim@meyering.net>
16585
16586         Change UTILS_ to gl_ in AC_DEFINE'd names.
16587         Change utils_- and jm_-prefixed variables, too.
16588         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
16589         UTILS_FUNC_MKDIR_TRAILING_SLASH.
16590         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
16591
16592         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
16593         Don't emit trailing blanks.
16594         Also rename jm_-prefixed variables to have gl_ prefix.
16595
16596         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
16597         Also rename jm_-prefixed variables to have gl_ prefix.
16598
16599         * m4/jm-macros.m4: Reflect the renamings.
16600         * m4/prereq.m4: Likewise.
16601
16602 2004-04-20  Jim Meyering  <jim@meyering.net>
16603
16604         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
16605         memory.
16606
16607 2004-04-20  Jim Meyering  <jim@meyering.net>
16608             Bruno Haible  <bruno@clisp.org>
16609
16610         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
16611         memory when realloc fails.
16612
16613 2004-04-19  Jim Meyering  <jim@meyering.net>
16614
16615         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
16616         now that readutmp.c may call `free (0)'.
16617
16618 2004-04-19  Bruno Haible  <bruno@clisp.org>
16619
16620         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
16621         * m4/inttypes_h.m4: Likewise.
16622         * m4/stdint_h.m4: Likewise.
16623         * m4/intmax_t.m4: Likewise.
16624         * m4/uintmax_t.m4: Likewise.
16625
16626 2004-04-18  Jim Meyering  <jim@meyering.net>
16627
16628         * m4/prereq.m4: Don't forbid jm_ prefix.
16629
16630         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
16631         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
16632         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
16633         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
16634         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
16635         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
16636         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
16637         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
16638         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
16639         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
16640         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
16641         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
16642         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
16643         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
16644         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
16645         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
16646         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
16647         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
16648         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
16649
16650 2004-04-18  Jim Meyering  <jim@meyering.net>
16651
16652         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
16653         failure, don't leak memory and do call END_UTMP_ENT.
16654
16655 2004-04-16  Jim Meyering  <jim@meyering.net>
16656
16657         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
16658         coreutils' stat program.
16659         (gl_PREREQ): Don't require jm_PREREQ_STAT.
16660
16661 2004-04-11  Paul Eggert  <eggert@twinsun.com>
16662
16663         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
16664         C89.
16665         (CHAR_BIT): Remove, since we assume C89.
16666         Include <stdint.h> if available, as per current Autoconf CVS advice.
16667
16668 2004-03-31  Jim Meyering  <jim@meyering.net>
16669
16670         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
16671         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
16672         * m4/xalloc.m4: Likewise.
16673
16674 2004-03-30  Paul Eggert  <eggert@twinsun.com>
16675
16676         Merge from coreutils.
16677
16678         * m4/inttostr.m4: New file.
16679         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
16680         Require AM_STDBOOL_H and gl_TIMESPEC instead.
16681         Require gl_CLOCK_TIME.
16682         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
16683
16684 2004-03-30  Paul Eggert  <eggert@twinsun.com>
16685
16686         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
16687         not bool, to be more consistent with Unix conventions.
16688         Suggested by Bruno Haible.
16689
16690         Merge from coreutils.
16691
16692         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
16693         * lib/umaxtostr.c: New files.
16694
16695         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
16696         the usual <time.h> dance.
16697         (get_date): Change signature to support fractional time stamps.
16698         All callers changed.
16699         * lib/getdate.y: Include "getdate.h" first, as we can now
16700         assume C89 and don't need to worry about 'const'.
16701         Similarly, include "unlocked-io.h" near start, not in middle.
16702         Include <limits.h>.
16703         (textint.value): Use long int rather than int.
16704         (textint.digits): Use size_t rather than int.
16705         (BILLION, LOG10_BILLION): New constants.
16706         (parser_control): New member rel_ns.  Members day_ordinal,
16707         time_zone, month, day, hour, minutes, rel_year, rel_month,
16708         rel_day, rel_hour, rel_minutes, rel_seconds
16709         are now long int, not int.  Member seconds is now struct timespec,
16710         not int.  New member timespec_seen.  Members dates_seen, days_seen,
16711         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
16712         not int.
16713         (%union.intval): Now long int, not int.
16714         New member timespec.
16715         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
16716         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
16717         (spec): Now is a timespec or an item list.
16718         (timespec, items): New nonterminals.
16719         (time, rel, relunit, number, get_date):
16720         Add support for fractional seconds.
16721         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
16722         (gmtime, localtime, mktime): Remove decls; not needed with C89.
16723         (to_hour): First arg is now long int, not int.
16724         (to_year): Returns long int, not int.
16725         Don't treat year -70 like 70.
16726         (tm_diff): Returns long int, not int.
16727         (lookup_word): Use bool instead of int when appropriate.
16728         (yylex): Use size_t for count, not int.
16729         Detect overflow when parsing large integer constants.
16730         Add support for fractions.
16731         (get_date): Make pointers 'const' if possible.
16732         Use more-portable code to detect integer overflow.
16733         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
16734         Don't use ctime; it's not reliable if the year has >4 digits.
16735
16736         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
16737         This is for compatibility with BSD.
16738
16739         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
16740         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
16741         From coreutils' system.h.
16742
16743         * lib/userspec.c: Don't include "posixver.h".
16744         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
16745         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
16746         compatible extension.  Simplify code by removing a boolean int
16747         that was always nonzero if a string was nonnull.
16748
16749 2004-03-30  Jim Meyering  <jim@meyering.net>
16750
16751         Merge from coreutils.
16752
16753         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
16754         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
16755         on some systems one must include <grp.h> before it.
16756         Reported by Christian Krackowizer.
16757
16758 2004-03-30  Jim Meyering  <jim@meyering.net>
16759
16760         Merge from coreutils.
16761
16762         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
16763
16764         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
16765         an empty input stream.
16766
16767         * lib/readtokens.c: Include <stdbool.h>.
16768         (readtoken): Use `size_t' rather than int/long.
16769         All callers adjusted.
16770         Use `bool' rather than `int' where appropriate.
16771         Use memset rather than an explicit loop.
16772         Use x2nrealloc rather than xrealloc.
16773         Allow the use of `\0' as a delimiter.
16774         (readtokens): Likewise.
16775         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
16776
16777 2004-03-30  Jim Meyering  <jim@meyering.net>
16778
16779         * m4/realloc.m4: Remove file, since now it does no more than
16780         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
16781         the `configure.ac' section of module/realloc.
16782         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
16783
16784 2004-03-30  Bruno Haible  <bruno@clisp.org>
16785
16786         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
16787         nonnull.
16788
16789 2004-03-29  Paul Eggert  <eggert@twinsun.com>
16790
16791         Merge changes to getloadavg.c from coreutils and Emacs.
16792
16793         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
16794         Define to an expression, not to the empty string.
16795         Include cloexec.h and xalloc.h.
16796         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
16797         Use set_cloexec_flag rather than rolling our own.
16798         * lib/cloexec.c, lib/cloexec.h: New files.
16799
16800 2004-03-29  Paul Eggert  <eggert@twinsun.com>
16801
16802         * m4/cloexec.m4: New file.
16803
16804 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16805
16806         * lib/getopt.h: Sync with libc CVS.
16807
16808 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16809             Bruno Haible  <bruno@clisp.org>
16810
16811         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
16812         mbswidth.
16813
16814 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16815             Bruno Haible  <bruno@clisp.org>
16816
16817         * lib/mbswidth.h: Include <wchar.h> only if
16818         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
16819         <wchar.h>.
16820         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
16821
16822 2004-03-09  Paul Eggert  <eggert@twinsun.com>
16823
16824         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
16825         Sync with libc CVS.
16826         * lib/getopt_int.h: New file, also synced from libc.
16827
16828 2004-03-09  Paul Eggert  <eggert@twinsun.com>
16829
16830         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
16831         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
16832         Bring back getopt.c, getopt.h, getopt1.c.
16833
16834 2004-03-07  Paul Eggert  <eggert@twinsun.com>
16835
16836         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
16837         All uses changed.  Check for sa_sigaction member; this fixes
16838         a bug first reported by Jason Andrade in
16839         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
16840
16841 2004-03-07  Paul Eggert  <eggert@twinsun.com>
16842
16843         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
16844         '#if' expressions.  Unlike the code it replaces, it does not
16845         depend on (defined _SC_PAGESIZE).  However, it does depend on
16846         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
16847         first reported by Jason Andrade in
16848         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
16849
16850 2004-02-25  Simon Josefsson  <jas@extundo.com>
16851
16852         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
16853
16854 2004-02-25  Simon Josefsson  <jas@extundo.com>
16855
16856         * lib/strdup.h: New file.
16857         * lib/strdup.c: Include it.
16858         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
16859         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
16860
16861 2004-02-23  Karl Berry  <karl@gnu.org>
16862
16863         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
16864         (from fencepost.gnu.org:/gd/gnuorg).
16865
16866 2004-02-23  Karl Berry  <karl@gnu.org>
16867
16868         * config/srclistvars.sh (GNUORG) [karl]: redefine.
16869         * config/srclist.txt: add maintain/standards documents.
16870
16871 2004-02-18  Bruno Haible  <bruno@clisp.org>
16872
16873         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
16874         Reported by Derek Robert Price <derek@ximbiot.com>.
16875
16876 2004-02-16  Karl Berry  <karl@gnu.org>
16877
16878         * config/mkinstalldirs, install-sh: update from automake.
16879
16880 2004-02-06  Karl Berry  <karl@gnu.org>
16881
16882         * m4/po.m4: update from gettext 0.14.1.
16883
16884 2004-02-06  Karl Berry  <karl@gnu.org>
16885
16886         * lib/config.charset: update from gettext 0.14.1.
16887
16888 2004-02-05  Paul Eggert  <eggert@twinsun.com>
16889
16890         Add comments and code, prompted by suggestions from Bruno Haible
16891         for sh-quote.
16892         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
16893         describing the enum quoting_style values.
16894         * lib/quotearg.c (quotearg_alloc): New function.
16895         (quotearg_buffer_restyled): Treat lone { and } as special.
16896         Treat = as special.  Work around bug with older shells
16897         that "see" a '\' that is really the 2nd byte of a multibyte char.
16898         Quote empty string with shell_quoting_style.
16899
16900 2004-02-03  Bruno Haible  <bruno@clisp.org>
16901
16902         * m4/pipe.m4: New file, from GNU gettext.
16903
16904 2004-02-03  Bruno Haible  <bruno@clisp.org>
16905
16906         * lib/pipe.h: New file, from GNU gettext.
16907         * lib/pipe.c: New file, from GNU gettext.
16908
16909 2004-01-27  Bruno Haible  <bruno@clisp.org>
16910
16911         * m4/execute.m4: New file, from GNU gettext.
16912
16913 2004-01-27  Bruno Haible  <bruno@clisp.org>
16914
16915         * lib/execute.h: New file, from GNU gettext.
16916         * lib/execute.c: New file, from GNU gettext.
16917         * lib/w32spawn.h: New file, from GNU gettext.
16918
16919 2004-01-24  Paul Eggert  <eggert@twinsun.com>
16920
16921         Merge from diffutils.
16922
16923         * lib/file-type.c (file_type): Add typed memory objects.
16924         * lib/file-type.h (S_TYPEISTMO): New macro.
16925
16926         * lib/c-stack.h (c_stack_action): Remove argv argument.
16927         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
16928         (die): Don't calculate message unless segv_action returns.
16929         (get_stack_location, min_address_from_argv, max_address_from_argv,
16930         volatile stack_base, volatile_stack_size): Remove.
16931         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
16932         that every segmentation violation is a stack overflow.  (Ouch!)
16933         See Debian bug 136249 (still outstanding) for more info about why
16934         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
16935
16936 2004-01-24  Paul Eggert  <eggert@twinsun.com>
16937
16938         Exit-status fix from coreutils.
16939
16940         Use exit_failure consistently in place of EXIT_FAILURE,
16941         so that program exit statuses are consistent on failure.
16942
16943         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
16944         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
16945         * lib/argmatch.h: Comment fix to match the above.
16946         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
16947         Now a macro referring to exit_failure, instead of a separate
16948         variable.  Include "exitfail.h" to get it.
16949         * lib/xstrtol.h: Include "exitfail.h".
16950         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
16951
16952         * lib/long-options.c (parse_long_options): Use prototype
16953         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
16954         for clarity.
16955
16956 2004-01-21  Jim Meyering  <jim@meyering.net>
16957
16958         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
16959         so as not to conflict with a different-sized __mktime_internal
16960         function in GNU libc.
16961         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
16962         Problem building statically-linked `ls' reported by Michael Brunnbauer.
16963
16964 2004-01-20  Karl Berry  <karl@gnu.org>
16965
16966         * config/config.guess: update from config.
16967
16968         * config/srclistvars.sh: GNUWWWLICENSES for karl.
16969
16970 2004-01-20  Bruno Haible  <bruno@clisp.org>
16971
16972         Safer stack allocation.
16973         * lib/setenv.c: Include allocsa.h.
16974         (alloca): Remove fallback definition.
16975         (freea): Remove macro.
16976         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
16977         instead of freea.
16978
16979 2004-01-20  Bruno Haible  <bruno@clisp.org>
16980
16981         * m4/eealloc.m4: New file, from GNU gettext.
16982
16983 2004-01-20  Bruno Haible  <bruno@clisp.org>
16984
16985         * m4/allocsa.m4: New file, from GNU gettext.
16986
16987 2004-01-20  Bruno Haible  <bruno@clisp.org>
16988
16989         * lib/xallocsa.h: New file, from GNU gettext.
16990         * lib/xallocsa.c: New file, from GNU gettext.
16991
16992 2004-01-20  Bruno Haible  <bruno@clisp.org>
16993
16994         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
16995
16996 2004-01-20  Bruno Haible  <bruno@clisp.org>
16997
16998         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
16999         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
17000         specially.
17001
17002 2004-01-20  Bruno Haible  <bruno@clisp.org>
17003
17004         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
17005         patch.
17006
17007 2004-01-20  Bruno Haible  <bruno@clisp.org>
17008
17009         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
17010
17011 2004-01-20  Bruno Haible  <bruno@clisp.org>
17012
17013         * lib/eealloc.h: New file.
17014
17015 2004-01-20  Bruno Haible  <bruno@clisp.org>
17016
17017         * lib/binary-io.h: Avoid warnings on Cygwin.
17018
17019 2004-01-20  Bruno Haible  <bruno@clisp.org>
17020
17021         * lib/allocsa.h: New file, from GNU gettext.
17022         * lib/allocsa.c: New file, from GNU gettext.
17023
17024 2004-01-18  Karl Berry  <karl@gnu.org>
17025
17026         * doc/gpl.texi, doc/lgpl.texi: new files.
17027
17028 2004-01-18  Karl Berry  <karl@gnu.org>
17029
17030         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
17031         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
17032
17033 2004-01-15  Paul Eggert  <eggert@twinsun.com>
17034
17035         Merge from coreutils.
17036
17037         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
17038         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
17039         (gl_DEFAULT_POSIX2_VERSION): Move
17040         the documentation from 'configure' into 'config.hin',
17041         so that 'configure --help' isn't burdened by it and
17042         we don't have to worry about its formatting there.
17043         Reword the documentation so that it's more succinct
17044         and can be run together into a single paragraph.
17045         * m4/same.m4 (gl_SAME): Check for pathconf.
17046
17047 2004-01-15  Paul Eggert  <eggert@twinsun.com>
17048
17049         Merge from coreutils.
17050
17051         * lib/posixver.c: Include posixver.h.
17052
17053         * lib/same.c: Include <stdbool.h>, <limits.h>.
17054         (_POSIX_NAME_MAX): Define if not defined.
17055         (MIN): New macro.
17056         (same_name): If file names are silently truncated, report
17057         that the file names are the same if they are the same after
17058         the silent truncation.
17059
17060         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
17061         conversion function.
17062         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
17063         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
17064         longer needed.
17065
17066 2004-01-15  Jim Meyering  <jim@meyering.net>
17067
17068         Merge from coreutils.
17069
17070         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
17071         if no library is required.
17072         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
17073         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
17074         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
17075         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
17076         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
17077         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
17078         value, $ac_cv_search_crypt, if it's "none required".
17079         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
17080         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
17081         not gl_FUNC_GETLOADAVG.
17082         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
17083         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
17084
17085 2004-01-15  Jim Meyering  <jim@meyering.net>
17086
17087         Merge from coreutils.
17088
17089         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
17090         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
17091         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
17092
17093         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
17094         optional configure-time default.
17095
17096         * lib/version-etc.c (version_etc_copyright): Update copyright date.
17097
17098         * lib/xreadlink.c (xreadlink): Correct outdated comment.
17099
17100 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
17101
17102         Merge from coreutils.
17103
17104         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
17105         value, $ac_cv_search_nanosleep, if it's "none required".
17106
17107 2004-01-14  Paul Eggert  <eggert@twinsun.com>
17108
17109         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
17110         with like-named macro in fnmatch.c.
17111         (EXT): Use an internal constant instead.
17112
17113         Merge fnmatch patches from glibc.
17114         * lib/fnmatch.c (mbsinit): Remove define.
17115         Add libc_hidden_ver (__fnmatch, fnmatch).
17116         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
17117         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
17118
17119 2004-01-14  Karl Berry  <karl@gnu.org>
17120
17121         * config/install-sh: update from automake.
17122
17123 2004-01-13  Karl Berry  <karl@gnu.org>
17124
17125         * config/install-sh: update from automake.
17126
17127 2004-01-09  Karl Berry  <karl@gnu.org>
17128
17129         * config/install-sh: update from automake.
17130
17131 2004-01-05  Karl Berry  <karl@gnu.org>
17132
17133         * config/config.{sub,guess}: update from config.
17134
17135 2003-12-31  Karl Berry  <karl@gnu.org>
17136
17137         * config/depcomp: update from automake.
17138
17139 2003-12-14  Karl Berry  <karl@gnu.org>
17140
17141         * lib/config.charset: update from gettext-runtime.
17142
17143 2003-12-03  Paul Eggert  <eggert@twinsun.com>
17144
17145         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
17146         Bug reported by Alfred M. Szmidt.
17147
17148 2003-12-03  Bruno Haible  <bruno@clisp.org>
17149
17150         * m4/gettext.m4: Upgrade from gettext-0.13.
17151         * m4/po.m4: Upgrade from gettext-0.13.
17152         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
17153         * m4/intmax.m4: New file, from gettext-0.13.
17154         * m4/printf-posix.m4: New file, from gettext-0.13.
17155
17156 2003-11-29  Karl Berry  <karl@gnu.org>
17157
17158         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
17159
17160 2003-11-25  Paul Eggert  <eggert@twinsun.com>
17161             Bruno Haible  <bruno@clisp.org>
17162
17163         * lib/printf-parse.h: Don't include sys/types.h.
17164         (ARG_NONE): New macro.
17165         (char_directive): Change type of *arg_index fields to size_t.
17166         * lib/printf-parse.c: Don't include sys/types.h.
17167         (SSIZE_MAX): Remove macro.
17168         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
17169         Remove unnecessary overflow check.
17170         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
17171         fields.
17172
17173 2003-11-25  Bruno Haible  <bruno@clisp.org>
17174
17175         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
17176
17177 2003-11-25  Bruno Haible  <bruno@clisp.org>
17178
17179         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
17180         gt_TYPE_SSIZE_T.
17181
17182 2003-11-24  Paul Eggert  <eggert@twinsun.com>
17183
17184         * modules/alloca: Remove dependency on xalloc.
17185
17186 2003-11-24  Paul Eggert  <eggert@twinsun.com>
17187
17188         * lib/alloca.c: Remove dependency on xalloc module.
17189         (xalloc_die): Remove.
17190         (memory_full) [!defined emacs]: New macro.
17191         [!defined emacs]: Don't include xalloc.h.
17192         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
17193         address arithmetic overflows.  Change datatypes a bit to avoid
17194         unnecessary casts.
17195
17196 2003-11-22  Jim Meyering  <jim@meyering.net>
17197
17198         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
17199         s/size/size_t/.
17200
17201 2003-11-21  Karl Berry  <karl@gnu.org>
17202
17203         * config/config.{sub,guess}: update from config.
17204
17205 2003-11-18  Karl Berry  <karl@gnu.org>
17206
17207         * config/config.{sub,guess}: update from config.
17208
17209         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
17210
17211 2003-11-17  Paul Eggert  <eggert@twinsun.com>
17212
17213         * README: Mention that S+T cannot overflow if S is the size of
17214         an existing object and T is sufficiently small.
17215
17216 2003-11-17  Jim Meyering  <jim@meyering.net>
17217
17218         On systems without utime and without a utimes function capable of
17219         dealing with a NULL struct utimbuf* argument, this utime replacement
17220         could -- in unusual circumstances -- leak a file descriptor.
17221         * lib/utime.c: Include <unistd.h> and <errno.h>.
17222         (utime_null): Be sure to close `fd' and to preserve errno.
17223         Reported by Geoff Collyer via Arnold Robbins.
17224
17225 2003-11-17  Bruno Haible  <bruno@clisp.org>
17226
17227         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
17228         (Depends-on): Add xsize.
17229
17230 2003-11-17  Bruno Haible  <bruno@clisp.org>
17231
17232         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
17233
17234 2003-11-17  Bruno Haible  <bruno@clisp.org>
17235
17236         * lib/vasnprintf.c (alloca): Remove fallback definition.
17237         (freea): Remove definition.
17238         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
17239         Reported by Paul Eggert.
17240
17241 2003-11-16  Paul Eggert  <eggert@twinsun.com>
17242             Bruno Haible  <bruno@clisp.org>
17243
17244         Protect against address arithmetic overflow.
17245         * lib/printf-args.h: Include stddef.h.
17246         (arguments): Change type of field 'count' to size_t.
17247         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
17248         'unsigned int' where appropriate.
17249         * lib/printf-parse.h: Include sys/types.h.
17250         (char_directive): Change type of *arg_index fields to ssize_t.
17251         (char_directives): Change type of fields 'count', max_*_length to
17252         size_t.
17253         * lib/printf-parse.c: Include sys/types.h and xsize.h.
17254         (SSIZE_MAX): Define fallback value.
17255         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
17256         instead of 'int' where appropriate. Check a_allocated, d_allocated
17257         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
17258         * lib/vasnprintf.c: Include xsize.h.
17259         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
17260         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
17261         overflow. Avoid wraparound when converting a width or precision from
17262         decimal to binary.
17263
17264 2003-11-16  Bruno Haible  <bruno@clisp.org>
17265
17266         Update from GNU gettext.
17267         * lib/printf-parse.c: Generalize to it can be compiled for wide
17268         strings.
17269         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
17270         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
17271         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
17272         SNPRINTF): New macros.
17273         Don't include <alloca.h> if the file is used inside libintl.
17274         (local_wcslen): New function, for Solaris 2.5.1.
17275         (VASNPRINTF): Use it instead of wcslen.
17276
17277 2003-11-16  Bruno Haible  <bruno@clisp.org>
17278
17279         * lib/xsize.h (xmax): New function.
17280         (xsum, xsum3, xsum4): Declare as "pure" functions.
17281
17282 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17283
17284         * modules/xalloc (Files): Undo latest change, since xalloc.h
17285         no longer needs SIZE_MAX or PTRDIFF_MAX.
17286
17287 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17288
17289         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
17290         gl_PTRDIFF_MAX.
17291
17292 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17293
17294         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
17295         "return", to pacify some unknown compiler.  Problem reported
17296         by Joerg Schilling.
17297
17298 2003-11-12  Paul Eggert  <eggert@twinsun.com>
17299
17300         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
17301         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
17302         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
17303         heuristic is just as accurate as far as we know, and it removes a
17304         dependency on size_max.m4 and ptrdiff_max.m4.
17305
17306 2003-11-11  Bruno Haible  <bruno@clisp.org>
17307
17308         * modules/xsize (Files): Add m4/size_max.m4.
17309         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
17310
17311 2003-11-11  Bruno Haible  <bruno@clisp.org>
17312
17313         * m4/size_max.m4: New file.
17314         * m4/ptrdiff_max.m4: New file.
17315         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
17316         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
17317         (gl_XALLOC): Invoke it.
17318
17319 2003-11-11  Bruno Haible  <bruno@clisp.org>
17320
17321         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
17322         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
17323         defined.
17324
17325 2003-11-10  Paul Eggert  <eggert@twinsun.com>
17326
17327         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
17328         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
17329         rejected some allocations of exactly SIZE_MAX - 2 bytes.
17330         From Bruno Haible.
17331         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
17332         not (size_t) -1, since it's defined here.
17333
17334 2003-11-09  Karl Berry  <karl@gnu.org>
17335
17336         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
17337
17338 2003-11-06  Paul Eggert  <eggert@twinsun.com>
17339
17340         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
17341         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
17342         Reject sizes of exactly SIZE_MAX bytes.
17343         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
17344         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
17345
17346 2003-11-05  Bruno Haible  <bruno@clisp.org>
17347
17348         * lib/xsize.h: Include limits.h, to avoid a possible collision with
17349         SIZE_MAX defined in <limits.h> on Solaris.
17350
17351 2003-11-04  Jim Meyering  <jim@meyering.net>
17352
17353         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
17354         variable names, rather than @VAR@.
17355         * modules/poll: Likewise.
17356
17357 2003-11-04  Bruno Haible  <bruno@clisp.org>
17358
17359         * modules/xsize: New file.
17360         * modules/linebreak: Depend on xsize.
17361         * MODULES.html.sh (func_all_modules): Add xsize.
17362
17363 2003-11-04  Bruno Haible  <bruno@clisp.org>
17364
17365         * m4/xsize.m4: New file.
17366
17367 2003-11-04  Bruno Haible  <bruno@clisp.org>
17368
17369         * lib/xsize.h: New file.
17370         * lib/linebreak.c: Include xsize.h.
17371         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
17372         argument for overflow.
17373         Suggested by Paul Eggert.
17374
17375 2003-11-03  Karl Berry  <karl@gnu.org>
17376
17377         * config/config.{guess,sub}: update from config.
17378
17379 2003-11-03  Jim Meyering  <jim@meyering.net>
17380
17381         * modules/userspec (lib_SOURCES): Add userspec.h.
17382         (Include): Add "userspec.h".
17383         Improve description.
17384
17385 2003-11-03  Jim Meyering  <jim@meyering.net>
17386
17387         * lib/userspec.c: Include "userspec.h".
17388         * lib/userspec.h: New file.
17389
17390 2003-11-03  Bruno Haible  <bruno@clisp.org>
17391
17392         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
17393
17394 2003-11-03  Bruno Haible  <bruno@clisp.org>
17395
17396         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
17397         available, to avoid (extremely rare) race condition.
17398         Suggested by Paul Eggert.
17399
17400 2003-11-02  Karl Berry  <karl@gnu.org>
17401
17402         * config/srclist.txt (vasprintf.c): sync broken, sigh.
17403
17404 2003-10-31  Paul Eggert  <eggert@twinsun.com>
17405
17406         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
17407         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
17408         (read_filesystem_list): Set and use me_type_malloced.
17409         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
17410         whatever the type happens to be), for brevity and consistency.
17411         Check for size calculation overflow on Alphas running OSF/1.
17412
17413 2003-10-31  Jim Meyering  <jim@meyering.net>
17414
17415         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
17416
17417         * lib/linebuffer.c: Include <string.h> for declaration of memset.
17418
17419 2003-10-30  Paul Eggert  <eggert@twinsun.com>
17420             Bruno Haible  <bruno@clisp.org>
17421
17422         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
17423         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
17424
17425 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
17426
17427         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
17428         netbsd*-gnu*.  Suggested by Robert Millan.
17429
17430 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17431
17432         * modules/group-member: Depend on stdbool.
17433
17434 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17435
17436         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
17437
17438 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17439
17440         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
17441         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
17442         after the 'gnu' in these cases.  This fixes some bugs in the
17443         previous change, and is based on suggestions by Robert Millan.
17444
17445 2003-10-29  Paul Eggert  <eggert@twinsun.com>
17446
17447         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
17448         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
17449         no longer needed.
17450         * lib/quotearg.c (quotearg_n_options): Use it.
17451         * lib/group-member.c: Include <stdbool.h>.
17452         (free_group_info): Arg is now const *; don't free arg.
17453         (get_group_info): Now returns bool and accepts struct group_info *,
17454         rather than returning a malloc'ed struct group_info *.
17455         All uses changed.  Check for overflow in internal size calculation.
17456
17457         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
17458         rather than xmalloc/xrealloc.
17459         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
17460         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
17461         conformance bug: the old code used a pointer after freeing the
17462         storage that it addressed.
17463         * lib/hash.c (hash_initialize): Simplify the code by using
17464         xalloc_oversized rather than doing it by hand.
17465         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
17466         the buffer preserved.  Use free and xmalloc instead.
17467         * lib/quotearg.c (quotearg_n_options): Likewise.
17468         Use a simpler test for size overflow.  Don't use xalloc_oversized
17469         because unsigned int might be wider than size_t (!); this suggests
17470         that we should switch from unsigned int to size_t for slot numbers.
17471
17472 2003-10-28  Paul Eggert  <eggert@twinsun.com>
17473
17474         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
17475         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
17476         NetBSD kernels.  Requested by Richard Stallman.
17477
17478 2003-10-27  Paul Eggert  <eggert@twinsun.com>
17479
17480         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
17481         to allocate the returned structure.  Do not allocate a subarray,
17482         as x2nrealloc will do that.
17483         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
17484         instead of xnrealloc.
17485         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
17486
17487 2003-10-27  Bruno Haible  <bruno@clisp.org>
17488
17489         * lib/stdbool_.h: Better support for BeOS.
17490
17491 2003-10-26  Paul Eggert  <eggert@twinsun.com>
17492
17493         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
17494         now uses inline.
17495
17496 2003-10-26  Paul Eggert  <eggert@twinsun.com>
17497
17498         * lib/xalloc.h (xalloc_oversized): New static inline function, for
17499         callers that want to do their own size-overflow checking.  Include
17500         <stdbool.h>, since xalloc_oversized returns bool.
17501         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
17502         to use xalloc_oversized.
17503
17504         Add two functions x2realloc, x2nrealloc, for programs that grow
17505         arrays dynamically by doubling their sizes.
17506         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
17507         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
17508         New functions.
17509
17510         Port to C99 semantics for 'inline' of external functions.
17511         Bug reported by Bruno Haible.
17512         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
17513         with the old contents of xnmalloc.
17514         (xnmalloc, xmalloc): Use it.
17515         (xnrealloc_inline): New static inline function,
17516         with the old contents of xnrealloc.
17517         (xnrealloc, xrealloc): Use it.
17518
17519         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
17520         that.
17521
17522 2003-10-26  Karl Berry  <karl@gnu.org>
17523
17524         * config/srclist.txt (COPYING.DOC): no longer available from
17525         /gd/gnuorg; don't know where the ultimate source is.
17526
17527 2003-10-25  Paul Eggert  <eggert@twinsun.com>
17528
17529         Fix several address-calculation bugs in the hash modules,
17530         plus some minor code cleanup.
17531
17532         * lib/hash.h: Include <stdbool.h>, for bool.
17533         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
17534         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
17535         hash_get_n_entries, hash_get_max_bucket_length,
17536         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
17537         hash_rehash): Use size_t rather than unsigned.
17538         * lib/hash.c (struct hash_table, hash_get_n_buckets,
17539         hash_get_n_buckets_used, hash_get_n_entries,
17540         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
17541         hash_get_entries, hash_do_for_each, hash_string, is_prime,
17542         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
17543         Likewise.
17544         (SIZE_MAX): Define if not defined.
17545         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
17546         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
17547         hash_print):
17548         Use const * when possible.
17549         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
17550         (check_tuning): Fix bug: if tuning parameters were very close to
17551         0 or 1, rounding errors could have caused subscript violations.
17552         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
17553         (hash_initialize): Add 'fail:' label
17554         to free table and return NULL, and use it to simplify code.
17555         Use calloc rather than clearing the storage ourself.
17556         (hash_initialize, hash_rehash): Check for arithmetic overflow in
17557         buffer size calculations.
17558         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
17559         Include <stddef.h>, for size_t.
17560         * lib/hash-pjw.c (hash_pjw): Likewise.
17561         Switch to method described by Bruno Haible.
17562         Include <limits.h>, for CHAR_BIT.
17563         (SIZE_BITS): New macro.
17564
17565 2003-10-23  Paul Eggert  <eggert@twinsun.com>
17566
17567         * m4/getline.m4 (AM_FUNC_GETLINE):
17568         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
17569         hosts.  Problem reported by Derek Robert Price in
17570         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
17571         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
17572         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
17573
17574 2003-10-21  Paul Eggert  <eggert@twinsun.com>
17575
17576         * lib/getndelim2.c (getndelim2): When size calculation overflows,
17577         ceiling the allocation at NMAX bytes rather than silently
17578         discarding input bytes before NMAX is reached.  This makes
17579         a difference only if NMAX exceeds SIZE_MAX / 2.
17580
17581         * lib/obstack.c: Merge from glibc.
17582         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
17583         Add libc_hidden_def (_obstack_newchunk).
17584         (_obstack_free) [! defined _LIBC]: Remove.
17585         [defined _LIBC]: Make a strong alias from obstack_free, rather than
17586         a clone of the function body.
17587         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
17588         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
17589
17590         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
17591         glibc.
17592         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
17593         arg to memcpy.
17594
17595         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
17596         (obstack_ptr_grow_fast, obstack_int_grow_fast):
17597         Don't use lvalue casts, as GCC plans to remove support for them
17598         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
17599         was also present in the non-GCC version, indicating that this
17600         code had always been buggy and had never been widely used.
17601         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
17602         Use the fast variant of each macro, rather than copying the
17603         definiens of the fast variant; that way, we'll be more likely to
17604         catch future bugs in the fast variants.
17605
17606 2003-10-20  Bruno Haible  <bruno@clisp.org>
17607
17608         * modules/wait-process: New file.
17609         * MODULES.html.sh (func_all_modules): Add wait-process.
17610
17611 2003-10-20  Bruno Haible  <bruno@clisp.org>
17612
17613         * m4/wait-process.m4: New file.
17614
17615 2003-10-20  Bruno Haible  <bruno@clisp.org>
17616
17617         * lib/wait-process.h: New file, from GNU gettext.
17618         * lib/wait-process.c: New file, from GNU gettext.
17619
17620 2003-10-19  Jim Meyering  <jim@meyering.net>
17621
17622         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
17623         HPUX 10.20.
17624
17625 2003-10-18  Karl Berry  <karl@gnu.org>
17626
17627         * config/config.guess: update from config.
17628
17629 2003-10-16  Paul Eggert  <eggert@twinsun.com>
17630
17631         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
17632         (getgroups): First arg is int, not size_t.
17633         Don't let 'free' mangle errno.
17634
17635 2003-10-16  Paul Eggert  <eggert@twinsun.com>
17636
17637         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
17638
17639 2003-10-16  Karl Berry  <karl@gnu.org>
17640
17641         * config/config.{guess,sub}: update from config.
17642
17643 2003-10-16  Jim Meyering  <jim@meyering.net>
17644
17645         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
17646         memcpy.
17647
17648 2003-10-15  Paul Eggert  <eggert@twinsun.com>
17649
17650         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
17651         (SIZE_MAX): Remove.
17652         (new_exclude, add_exclude_file): Initial size no longer needs to
17653         be a power of 2.
17654         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
17655         our own address arithmetic overflow checking.
17656
17657         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
17658         (fnmatch): Do not alloca more than 2000 wide characters;
17659         instead, use malloc for large buffers.
17660         Check for address arithmetic overflow, and return -1
17661         with errno set to ENOMEM in that case.
17662         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
17663         (NEW_PATTERN): Do not alloca more than 8000 bytes;
17664         instead, return -1.  Check for address arithmetic overflow.
17665
17666 2003-10-14  Paul Eggert  <eggert@twinsun.com>
17667
17668         Handle invalid suffixes and overflow independently, so that
17669         callers can treat them independently as needed.  Fix some bugs in
17670         suffix handling, e.g., "100k@" was not diagnosed as an invalid
17671         suffix for a human-readable blocksize.  The major caller-visible
17672         change is the addition of a new
17673         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
17674         that both overflow and suffix chars were found.
17675
17676         * lib/human.c (humblock): Don't check separately for invalid suffix
17677         char; that is xstrtoumax's job (now that its bug is fixed).
17678         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
17679         INTMAX_MAX]: New macros.
17680         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
17681         TYPE_MAXIMUM): New macros.
17682         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
17683         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
17684         if overflow occurs, as it's what __strtol does and it's more useful
17685         in practice.
17686         (__xstrtol): If __strtol reports some error other than ERANGE,
17687         reflect it to the caller as LONGINT_INVALID.  If it reports
17688         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
17689         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
17690         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
17691         value.
17692         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
17693         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
17694         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
17695         [defined UINTMAX_MAX]: New macros.
17696
17697 2003-10-14  Bruno Haible  <bruno@clisp.org>
17698
17699         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
17700
17701 2003-10-14  Bruno Haible  <bruno@clisp.org>
17702
17703         * m4/sig_atomic_t: New file, from GNU gettext.
17704         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
17705
17706 2003-10-14  Bruno Haible  <bruno@clisp.org>
17707
17708         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
17709         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
17710         Also use volatile where needed.
17711
17712 2003-10-12  Paul Eggert  <eggert@twinsun.com>
17713
17714         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
17715         Change maintainer from Bruno Haible to 'all'.
17716
17717 2003-10-12  Paul Eggert  <eggert@twinsun.com>
17718
17719         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
17720
17721 2003-10-12  Paul Eggert  <eggert@twinsun.com>
17722
17723         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
17724         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
17725         and define in terms of the other primitives.
17726         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
17727         (SIZE_MAX): Define if not already defined.
17728         (array_size_overflow): New function.
17729         (xalloc_die): Abort instead of exiting if 'error' returns.
17730         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
17731         (xmalloc, xrealloc): Use them.
17732         (xcalloc): Check for address arithmetic overflow.
17733         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
17734         a bit faster than strcpy.
17735
17736 2003-10-10  Simon Josefsson  <jas@extundo.com>
17737
17738         * modules/argp (Depends-on): Add restrict and strcase.
17739
17740 2003-10-10  Simon Josefsson  <jas@extundo.com>
17741
17742         * m4/argp.m4: Add AC_C_INLINE.
17743
17744 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17745
17746         Merge getpass from libc, plus a few fixes.
17747
17748         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
17749         Include <stdbool.h>.
17750         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
17751         __fsetlocking to empty.
17752         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
17753         do include <bits/libc-lock.h>.
17754         Do not include <fcntl.h>; not needed.
17755         [_LIBC]: Include <wchar.h>.
17756         (NOTCANCEL_MODE): New macro.
17757         (flockfile, funlockfile) [_LIBC]: New macros.
17758         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
17759         [!_LIBC]: New macros.
17760         (call_fclose): New function.
17761         (getpass): Use it.  Save tty stream separately; this simplifies the
17762         code and makes it more reliable if stdin happens to equal stdout.
17763         Invoke __fsetlocking on tty.
17764         Handle thread cancellation if needed.
17765         Namespace cleanup (use __tcgetattr, __getline).
17766         Use bool for Booleans.
17767         [USE_IN_LIBIO]: Handle wide streams.
17768         [!_LIBC]: Unconditionally do the fseek, since we don't know what
17769         stream might go where.
17770
17771         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
17772         doesn't have to include <stdio.h> before us.
17773         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
17774         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
17775         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
17776         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
17777         if not declared, so that we can use getpass.c code from libc without
17778         rewriting it.
17779         (flockfile, ftrylockfile, funlockfile): New macros.
17780
17781 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17782
17783         * modules/getpass: Depend on stdbool.
17784
17785 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17786
17787         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
17788
17789 2003-10-07  Karl Berry  <karl@gnu.org>
17790
17791         * config/config.{guess,sub}: update from config.
17792
17793 2003-10-06  Jim Meyering  <jim@meyering.net>
17794             Bruno Haible  <bruno@clisp.org>
17795
17796         This lets translators provide better translations for the
17797         "Written by ..." part of --version output.
17798         * lib/version-etc.h: Include stdarg.h.
17799         (version_etc_copyright): Declare as readonly.
17800         (version_etc): Make this function variadic with a NULL-terminated list
17801         of author name strings.
17802         (version_etc_va): New declaration.
17803         * lib/version-etc.c: Include stdarg.h, stdlib.h.
17804         (version_etc_copyright): Declare as readonly.
17805         (version_etc_va): New function. Provide a different translatable string
17806         for each possible number of authors < 10. Abbreviate when there are 10
17807         authors or more.
17808         (version_etc): Make this function variadic. Call version_etc_va.
17809         Suggestion from Gary V. Vaughan.
17810
17811         * lib/long-options.h (parse_long_options): Change prototype: the
17812         authors string is moved to the end and becomes variadic.
17813         * lib/long-options.c: Include stdarg.h.
17814         (parse_long_options): Make this function variadic, too.
17815         Call version_etc_va, not version_etc.
17816
17817 2003-10-06  Bruno Haible  <bruno@clisp.org>
17818
17819         * modules/version-etc-2: Remove file.
17820         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
17821
17822 2003-10-06  Bruno Haible  <bruno@clisp.org>
17823
17824         * modules/fatal-signal: New file.
17825         * MODULES.html.sh (func_all_modules): Add fatal-signal.
17826
17827 2003-10-06  Bruno Haible  <bruno@clisp.org>
17828
17829         * m4/fatal-signal.m4: New file.
17830         * m4/signalblocking.m4: New file, from GNU gettext.
17831
17832 2003-10-06  Bruno Haible  <bruno@clisp.org>
17833
17834         * lib/version-etc-2.h: Remove file.
17835         * lib/version-etc-2.c: Remove file.
17836
17837 2003-10-06  Bruno Haible  <bruno@clisp.org>
17838
17839         * lib/fatal-signal.h: New file, from GNU gettext.
17840         * lib/fatal-signal.c: New file, from GNU gettext.
17841
17842 2003-10-05  Paul Eggert  <eggert@twinsun.com>
17843
17844         * README: Rework advice for preventing empty .o files.
17845         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
17846         not <sys/types.h>.
17847
17848 2003-10-04  Karl Berry  <karl@gnu.org>
17849
17850         * lib/argp*: update from libc.
17851
17852 2003-10-04  Karl Berry  <karl@gnu.org>
17853
17854         * config/config.{guess,sub}: update from config.
17855
17856 2003-10-02  Bruno Haible  <bruno@clisp.org>
17857
17858         * modules/lchown (Include): Add lchown.h.
17859         * modules/time_r (Include): Use "..." syntax.
17860         * modules/xgetdomainname (Include): Add xgetdomainname.h.
17861
17862 2003-10-01  Simon Josefsson  <jas@extundo.com>
17863
17864         * MODULES.html.sh (func_all_modules): Move gethostname from section
17865         'based on' to section 'lacking' POSIX:2001.
17866
17867 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
17868
17869         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
17870         to output mode on the same stream.
17871
17872 2003-09-29  Paul Eggert  <eggert@twinsun.com>
17873
17874         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
17875         Fix arg typo in previous patch.
17876
17877 2003-09-28  Jim Meyering  <jim@meyering.net>
17878
17879         * lib/error.c: Correct cpp indentation.
17880
17881 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17882
17883         * modules/free: New file.
17884
17885 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17886
17887         * m4/free.m4: New file.
17888
17889 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17890
17891         * lib/minmax.h (MIN, MAX)
17892         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
17893         Omit the special code that used __typeof__, since we worry that
17894         it could be more trouble than it's worth.  See:
17895         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
17896         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
17897
17898         * lib/free.c: New file.
17899
17900 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
17901
17902         Trivial fixes to Makefile.am parts of module listings.
17903         * modules/strstr: Append strstr.h to lib_SOURCES.
17904         * modules/strcase: Likewise, for strcase.h.
17905
17906 2003-09-27  Karl Berry  <karl@gnu.org>
17907
17908         * config/mkinstalldirs: update from automake.
17909
17910 2003-09-26  Paul Eggert  <eggert@twinsun.com>
17911
17912         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
17913         (error_tail): Do not loop, reallocating temporary buffer, since
17914         the output cannot contain more wide characters than the input
17915         contains bytes, the size must be big enough already.  This avoids
17916         one potential size overflow calculation.  Check for size overflow
17917         when calculating temporary buffer size.  Free temporary buffer
17918         when done, if it was allocated with malloc; this plugs a memory
17919         leak.  Remove casts from void * to pointers, that are no longer
17920         needed now that we're assuming C89 or better.
17921
17922         Merge error changes from glibc.
17923
17924         * lib/error.c, error.h: Update copyright notice header to match glibc.
17925         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
17926         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
17927         Disable cancellation while printing error.
17928         * lib/error.h: Prepend __ to parameter names.
17929
17930 2003-09-26  Jim Meyering  <jim@meyering.net>
17931
17932         * lib/error.c (error_tail): Move some declarations
17933         into inner scope where the local variables are used.
17934
17935 2003-09-26  Bruno Haible  <bruno@clisp.org>
17936
17937         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
17938         stpncpy().
17939         Don't define stpncpy through config.h; it's now done through stpncpy.h.
17940
17941 2003-09-26  Bruno Haible  <bruno@clisp.org>
17942
17943         * lib/stpncpy.h (gnu_stpncpy): New declaration.
17944         (stpncpy): Define as alias for gnu_stpncpy.
17945         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
17946
17947 2003-09-25  Simon Josefsson  <jas@extundo.com>
17948
17949         * lib/xgetdomainname.h: New file.
17950         * lib/xgetdomainname.c: New file.
17951
17952 2003-09-25  Simon Josefsson  <jas@extundo.com>
17953             Bruno Haible  <bruno@clisp.org>
17954
17955         * modules/getdomainname: New file.
17956         * modules/xgetdomainname: New file.
17957         * MODULES.html.sh (func_all_modules): Add getdomainname,
17958         xgetdomainname.
17959
17960 2003-09-25  Simon Josefsson  <jas@extundo.com>
17961             Bruno Haible  <bruno@clisp.org>
17962
17963         * m4/getdomainname.m4: New file.
17964
17965 2003-09-25  Simon Josefsson  <jas@extundo.com>
17966             Bruno Haible  <bruno@clisp.org>
17967
17968         * lib/getdomainname.h: New file.
17969         * lib/getdomainname.c: New file.
17970
17971 2003-09-25  Karl Berry  <karl@gnu.org>
17972
17973         * lib/argp-fmtstream.c, argp-help.c: update from libc.
17974
17975 2003-09-25  Karl Berry  <karl@gnu.org>
17976
17977         * config/install-sh: update from automake.
17978
17979 2003-09-25  Bruno Haible  <bruno@clisp.org>
17980
17981         * modules/version-etc-2: New file, from modules/version-etc with
17982         modifications.
17983         * MODULES.html.sh (func_all_modules): Add version-etc-2.
17984
17985 2003-09-25  Bruno Haible  <bruno@clisp.org>
17986
17987         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
17988         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
17989
17990 2003-09-24  Simon Josefsson  <jas@extundo.com>
17991
17992         * modules/xgethostname: Add xgethostname.h.
17993
17994 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17995
17996         * lib/linebuffer.c (freebuffer): Don't free the argument, just
17997         the buffer associated with the argument.  Bug reported by
17998         Simon Josefsson.
17999
18000 2003-09-24  Paul Eggert  <eggert@twinsun.com>
18001
18002         * README: Document assumptions that 'int' is at least 32 bits
18003         wide, that integer arithmetic is 2's complement without overflow,
18004         that there are no holes in integer values, that adding sizes of
18005         two nonoverlapping objects can't overflow, and that all-bits-zero
18006         yields scalar zero.  Fix spelling and capitalization typos.
18007
18008 2003-09-19  Karl Berry  <karl@gnu.org>
18009
18010         * lib/argp.h: update from libc.
18011
18012 2003-09-17  Paul Eggert  <eggert@twinsun.com>
18013
18014         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
18015         to avoid spurious warnings like "AC_RUN_IFELSE was called before
18016         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
18017
18018 2003-09-17  Paul Eggert  <eggert@twinsun.com>
18019
18020         * gnulib-tool: Use "test -h", not "test -L", for portability
18021         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
18022         (tags_regexp): Remove, since \| doesn't conform to POSIX.
18023         (sed_extract_prog): Issue s commands one-by-one, rather than
18024         using \| in one s command.
18025
18026 2003-09-16  Paul Eggert  <eggert@twinsun.com>
18027
18028         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
18029         input error, instead of returning NULL the next time we are called
18030         (and therefore losing track of errno).
18031
18032 2003-09-16  Bruno Haible  <bruno@clisp.org>
18033
18034         * gnulib-tool (func_create_testdir): Warn about duplicated
18035         dependencies.
18036
18037 2003-09-15  Paul Eggert  <eggert@twinsun.com>
18038
18039         * modules/argmatch, modules/fatal, modules/obstack,
18040         modules/xalloc, modules/xgethostname: Sort dependencies by
18041         importance, not alphabetically.
18042
18043 2003-09-15  Paul Eggert  <eggert@twinsun.com>
18044
18045         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
18046         fails, so that the caller gets the proper errno.
18047
18048         * lib/readutmp.c (read_utmp): Likewise.
18049         Check for fstat error.  Close stream and free storage
18050         when failing.
18051
18052 2003-09-14  Karl Berry  <karl@gnu.org>
18053
18054         * config/srclist.txt (strdup.c): disable for c89 changes.
18055
18056 2003-09-14  Jim Meyering  <jim@meyering.net>
18057
18058         * lib/getloadavg.c: Correct cpp indentation.
18059         * lib/strdup.c: Likewise.
18060         * lib/vasnprintf.c: Likewise.
18061
18062 2003-09-14  Bruno Haible  <bruno@clisp.org>
18063
18064         * modules/fwriteerror: New file.
18065         * MODULES.html.sh (func_all_modules): Add fwriteerror.
18066
18067 2003-09-14  Bruno Haible  <bruno@clisp.org>
18068
18069         * lib/fwriteerror.h: New file.
18070         * lib/fwriteerror.c: New file.
18071
18072 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18073
18074         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
18075         modules/xgethostname, modules/xalloc: Depend on exit.
18076
18077 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18078
18079         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
18080
18081         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
18082         and AC_MINIX, too, so that their extensions are available.
18083
18084         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
18085         This macro has been superseded by gl_BACKUPFILE.
18086
18087         More patches to assume C89 or better.
18088
18089         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
18090
18091         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
18092         unconditionally.
18093         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
18094         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
18095         Include <string.h>, <stdlib.h> unconditionally.
18096         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
18097         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
18098         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
18099         headers or for string.h.
18100         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
18101         or strtoul.
18102
18103         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
18104         headers.
18105         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
18106         * m4/userspec.m4 (gl_USERSPEC): Likewise.
18107         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
18108         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
18109         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
18110         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
18111         memcpy, memset.
18112         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
18113         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
18114         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
18115         strtol.
18116         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
18117         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
18118         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
18119         strtoul.
18120
18121 2003-09-12  Paul Eggert  <eggert@twinsun.com>
18122
18123         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
18124         * lib/obstack.c [!defined _LIBC]: Likewise.
18125         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
18126         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
18127         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
18128
18129         More changes to assume C89 or better.
18130
18131         * lib/error.c (error_tail): Assume vprintf.
18132
18133         * lib/argmatch.c (getenv): Remove decl.
18134         * lib/progreloc.c (get_full_program_name): Define via prototype.
18135         * lib/setenv.c (clearenv): Likewise.
18136         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
18137         needed.
18138         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
18139         (malloc, memcpy): Remove decls.
18140         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
18141         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
18142         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
18143         (memcpy): Remove macro.
18144         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
18145         (__P): Remove.  All uses removed.
18146         (PTR): Remove.  All uses changed to void *.
18147         (CHAR_BIT, NULL): Remove.
18148         (spaces, zeros, memset_space, memset_zero)
18149         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
18150         Remove.
18151         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
18152         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
18153         Define with prototype.
18154         Remove now-unnecessary prototype decl.
18155         (extra_args_spec): Assume ANSI C.  All uses changed.
18156         (extra_args_spec_iso): Remove.
18157         (my_strftime, emacs_strftimeu): Define via prototype.
18158         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
18159         unconditionally.
18160         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
18161         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
18162         (strtoul, strtol): Remove decls.
18163         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
18164         LONG_MAX): Remove.
18165         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
18166         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
18167         (LOCALE_PARAM_PROTO): New macro.
18168         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
18169         (INTERNAL (strtol), strtol): Define with a prototype.
18170         (PARAMS): Remove.  All uses removed.
18171         * lib/tempname.c: Include <string.h> unconditionally.
18172         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
18173         * lib/xgethostname.c (main): Define with a prototype.
18174         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
18175         Include <stdlib.h> unconditionally.
18176         (calloc, malloc, realloc, free): Remove decls.
18177         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
18178         Include <stdlib.h> unconditionally.  Sort include file names.
18179         (strtod): Remove.
18180         (xstrtod): Define with a prototype.
18181         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
18182         (strtol, strtoul): Remove decls.
18183
18184 2003-09-11  Paul Eggert  <eggert@twinsun.com>
18185
18186         More patches to assume C89 or better.
18187         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
18188         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
18189         string.h, memchr, STDC_HEADERS.
18190
18191 2003-09-11  Paul Eggert  <eggert@twinsun.com>
18192
18193         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
18194         Include <stdlib.h>, <string.h> unconditionally.
18195         Remove now-unnecessary cast to char *.
18196         * lib/strnlen.c: Include <string.h> unconditionally.
18197         * lib/yesno.c (yesno): Define with a prototype.
18198
18199 2003-09-11  Bruno Haible  <bruno@clisp.org>
18200
18201         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
18202
18203 2003-09-10  Jim Meyering  <jim@meyering.net>
18204
18205         * lib/error.c: Correct indentation of cpp directives.
18206
18207 2003-09-10  Bruno Haible  <bruno@clisp.org>
18208
18209         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
18210         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
18211         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
18212         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
18213         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
18214         <stdlib.h> and <string.h> checks.
18215         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
18216         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
18217
18218 2003-09-10  Bruno Haible  <bruno@clisp.org>
18219
18220         * lib/strcspn.c: Include <string.h> unconditionally.
18221         * lib/strpbrk.c: Include <string.h> unconditionally.
18222         * lib/strstr.c: Include <string.h> unconditionally.
18223         * lib/unicodeio.c: Include <string.h> unconditionally.
18224         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
18225         * lib/unsetenv.c: Likewise.
18226         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
18227         * lib/yesno.c: Include <stdlib.h> unconditionally.
18228         (rpmatch): Add prototype.
18229
18230 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18231
18232         More patches to assume C89 or better.
18233         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
18234         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
18235         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
18236         or for string.h.
18237         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
18238         stdlib.h.
18239         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
18240         C headers.
18241         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
18242         string.h.
18243         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
18244         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
18245         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
18246         or for string.h.
18247         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
18248         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
18249         C headers.
18250         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
18251         memcpy.
18252         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
18253         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
18254         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
18255         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
18256         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
18257         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
18258         string.h, free.
18259         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
18260         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
18261         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
18262         C headers, or for string.h.
18263         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
18264         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
18265         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
18266         headers, memory.h, stdlib.h, string.h, strings.h.
18267         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
18268         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
18269         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
18270         strchr.
18271         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
18272         headers, memory.h, string.h.
18273         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
18274         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
18275         free.
18276         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
18277         headers.
18278         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
18279         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
18280         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
18281         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
18282         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
18283
18284 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18285
18286         More K&R removal.
18287
18288         * lib/acosl.c (main): Use a prototype.
18289         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
18290         tanl.c: Likewise.
18291
18292         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
18293
18294         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
18295         (getopt, etopt_long, getopt_long_only, _getopt_internal)
18296         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
18297         with a prototype.
18298         * lib/getopt.c (const): Remove macro.
18299         Include <string.h> unconditionally.
18300         (my_index): Remove; all uses changed to strchr.
18301         (strlen): Remove decl.
18302         (exchange): Remove forward decl; no longer needed.
18303         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
18304         Define with prototype.
18305         * lib/getopt1.c (const): Remove macro.
18306         (getopt_long, getopt_long_only, main): Define with prototype.
18307
18308         * lib/getugroups.c: Include <string.h> unconditionally.
18309
18310         * lib/getusershell.c: Include <stdlib.h> unconditionally.
18311         (getusershell, setusershell, endusershell, readname, main):
18312         Define with prototypes.
18313
18314         * lib/group-member.c: Include group-member.h first.
18315         Include <stdlib.h> unconditionally.
18316
18317         * lib/hard-locale.c: Include hard-locale.h first.
18318         Include <stdlib.h>, <string.h> unconditionally.
18319
18320         * lib/hash.c (free, malloc): Remove decls.
18321         Include <stdlib.h> unconditionally.
18322
18323         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
18324         (getenv): Do not declare.
18325
18326         * lib/idcache.c: Include <string.h> unconditionally.
18327
18328         * lib/long-options.c: Include long-options.h first, to test interface.
18329         Include <stdlib.h> unconditionally.
18330
18331         * lib/makepath.c: Include makepath.h first, to test interface.
18332         Include <stdlib.h> and <string.h> unconditionally.
18333
18334         * lib/linebuffer.c: Include <stdlib.h>.
18335         (free): Remove decl.
18336
18337         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
18338         stddef.h. rpl_malloc returns void *, not char *.
18339         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
18340         prototype.
18341
18342         * lib/md5.h: Include <limits.h> unconditionally.
18343         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
18344         (__P): Remove; all uses removed.
18345         * lib/md5.c: Include "md5.h" first.
18346         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
18347         md5_buffer, md5_process_bytes, md5_process_block):
18348         Define with prototypes.
18349         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
18350         * lib/sha.c: Include "sha.h" first.
18351         Include <stdlib.h>, <string.h> unconditionally.
18352
18353         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
18354         * lib/memcmp.c (__ptr_t): Likewise.
18355         * lib/memrchr.c (__ptr_t): Likewise.
18356         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
18357         Include <string.h> unconditionally.
18358         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
18359         * lib/memchr.c: Include <stdlib.h> unconditionally.
18360         * lib/memchr.c (LONG_MAX): Remove.
18361         * lib/memrchr.c (LONG_MAX): Likewise.
18362         * lib/memchr.c (__memchr): Define via a prototype.
18363         * lib/memrchr.c (__memrchr): Likewise.
18364         * lib/memcmp.c (__P): Remove, and remove all uses.
18365         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
18366         Remove forward decls; no longer needed.
18367         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
18368         Use types required by C89 in prototype.
18369
18370         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
18371         * lib/savedir.c: Likewise.
18372         * lib/mkdir.c (free): Remove decl.
18373         * lib/rmdir.c (rmdir): Define with a prototype.
18374         * lib/savedir.c: Include savedir.h first, to test interface.
18375
18376         * lib/mktime.c (STDC_HEADERS): Remove.
18377         Include <stdlib.h>, <string.h> unconditionally.
18378
18379         * lib/modechange.c: Include <stdlib.h> unconditionally.
18380         (malloc): Remove decl.
18381
18382         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
18383         (free): Remove decl.
18384
18385         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
18386         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
18387         (This type really should be intptr_t, but that's a C99ism.)
18388         (_obstack_memcpy): Remove: all uses changed to memcpy.
18389         Include <string.h> unconditionally.
18390         (struct obstack): Assume __STDC__ for types of members
18391         chunkfun, freefun, extra_arg.
18392         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
18393         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
18394         obstack_begin, obstack_specify_allocation,
18395         obstack_specify_allocation_with_arg, obstack_chunkfun,
18396         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
18397         Remove unprototyped decls and the macros that use them.
18398         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
18399         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
18400         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
18401         (defined __STDC__ && __STDC__)]:
18402         Remove nonprototyped code.
18403         Include <stdlib.h> unconditionally.
18404         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
18405         _obstack_allocated_p, _obstack_free, obstack_free,
18406         _obstack_memory_used, print_and_abort):
18407         Define using prototypes.
18408         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
18409         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
18410         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
18411         obstack_next_free, obstack_object_size, obstack_room) [0]:
18412         Remove unused, unprototyped code.
18413
18414         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
18415
18416         * lib/physmem.c (physmem_total, physmem_available, main): Define
18417         with prototypes.
18418
18419         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
18420         (main): Define with a prototype.
18421
18422         * lib/posixver.c (getenv): Remove decl.
18423
18424         * lib/putenv.c (malloc): Returns void *, not char *.
18425         Include <string.h> unconditionally.
18426         (strchr, memcpy, NULL): Do not define.
18427
18428         * lib/readtokens.c: Include readtokens.h first, to test interface.
18429         Include <stdlib.h>, <string.h> unconditionally.
18430         (init_tokenbuffer): Define with a prototype.
18431
18432         * lib/regex.c (PARAMS): Remove.  All uses removed.
18433         All uses of _RE_ARGS removed, too.
18434         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
18435         unconditionally.
18436         (bzero): Assume memset exists.
18437         (memcmp, memcpy, NULL): Remove.
18438         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
18439         char, or assignments to local vars of type signed char.
18440         (init_syntax_once, PREFIX(extract_number_and_incr),
18441         PREFIX(print_partial_compiled_pattern),
18442         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
18443         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
18444         PREFIX(regex_grow_registers), PREFIX(regex_compile),
18445         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
18446         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
18447         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
18448         wcs_compile_range, byte_compile_range, truncate_wchar,
18449         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
18450         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
18451         count_mbs_length, wcs_re_match_2_internal,
18452         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
18453         PREFIX(alt_match_null_string_p),
18454         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
18455         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
18456         regfree, PREFIX(extract_number)): Define with prototype.  Remove
18457         now-unnecessary declaration, if any.
18458         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
18459         regcomp, regexec):
18460         Remove now-unnecessary casts among pointer types.
18461         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
18462
18463         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
18464         (free): Remove decl.
18465
18466         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
18467
18468         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
18469         (free): Remove decl.
18470
18471         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
18472         * lib/xgetcwd.c: Likewise.
18473
18474         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
18475         (free): Remove decl.
18476
18477         * lib/strchrnul.c (strchrnul): Define with a prototype.
18478         Fix bug: c_in was not converted to char before searching.
18479
18480         The following changes are not K&R related:
18481
18482         * lib/group-member.h: Include <sys/types.h>, so that this file is
18483         self-contained.
18484         * lib/makepath.h: Likewise.
18485
18486         * lib/getusershell.c (readname, default_index, line_size, readname):
18487         Use size_t, not int, for sizes.
18488         (readname): If the size overflows, report an error instead of
18489         looping forever.
18490
18491 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18492
18493         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
18494         libc.
18495
18496 2003-09-09  Paul Eggert  <eggert@twinsun.com>
18497
18498         * README: New section: portability guidelines.
18499
18500 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
18501
18502         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
18503         C89 spec.
18504
18505 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
18506
18507         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
18508
18509 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18510
18511         Assume C89 or better; remove K&R cruft.
18512         A few of these changes were first proposed by Derek Robert Price
18513         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
18514
18515         * lib/addext.c: Include <string.h> unconditionally.
18516         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
18517         Don't declare getenv or malloc.
18518
18519         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
18520         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
18521         (NULL): Remove.
18522         (find_stack_direction, alloca): Use prototypes.
18523
18524         * lib/atexit.c (atexit): Define using a prototype.
18525
18526         * lib/basename.c, dirname.c, stripslash.c:
18527         Include <string.h> unconditionally.
18528
18529         * lib/bcopy.c: Include <stddef.h>.
18530         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
18531
18532         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
18533
18534         * lib/error.h (error, error_at_line, error_print_progname)
18535         [! (defined (__STDC__) && __STDC__)]: Remove decls.
18536         * lib/error.c: Include error.h first, to check interface.
18537         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
18538         (VA_START): Remove; all uses changeed to va_start.
18539         (exit, strerror): Remove decls.
18540         (error_print_progname): Prototype uncondionally.
18541         Don't include <errno.h>; no longer needed.
18542         (private_strerror): Remove.
18543         (error_tail): Always define.
18544         (error, error_at_line): Assume C89 or better; always use prototypes.
18545         * lib/fatal.c: Include "fatal.h" first, to test interface.
18546         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
18547         (VA_START): Remove; all uses changed to va_start.
18548         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
18549         this case.
18550         (exit): Remove decl.
18551         (fatal): Prototype unconditionally.  Assume va_start works.
18552         Abort at end, to pacify gcc.
18553
18554         * lib/euidaccess.c (main): Define with a prototype.
18555
18556         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
18557
18558         * lib/exitfail.c: Include <stdlib.h> unconditionally.
18559
18560         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
18561         prototypes.
18562         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
18563         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
18564         (getenv): Remove decl.
18565         (fnmatch): Define using a prototype.
18566         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
18567         (FCT): Define using a prototype.
18568
18569         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
18570
18571         * lib/gethostname.c: Include <stddef.h>.
18572         (gethostname): Define with prototype.  Length is size_t, not int.
18573
18574 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18575
18576         Assume C89 or better; remove K&R cruft.
18577         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
18578         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
18579         string.h, getenv, malloc.
18580         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
18581         headers.
18582         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
18583         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
18584         do not check for strerror.
18585         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
18586         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
18587         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
18588         do not check for doprnt or vprintf.
18589         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
18590         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
18591
18592 2003-09-08  Paul Eggert  <eggert@twinsun.com>
18593
18594         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
18595         getversion.c should have been removed then, but was accidentally
18596         preserved.
18597
18598         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
18599         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
18600
18601 2003-09-08  Karl Berry  <karl@gnu.org>
18602
18603         * config/config.sub, config.guess, srclistvars.sh: update from savannah
18604                 config, forget about prep.
18605
18606         * config/depcomp, missing: update from automake.
18607
18608 2003-09-07  Paul Eggert  <eggert@twinsun.com>
18609
18610         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
18611         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
18612
18613 2003-09-07  Paul Eggert  <eggert@twinsun.com>
18614
18615         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
18616         copy_tm_result.  Bug reported by Simon Josefsson in
18617         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
18618
18619 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18620
18621         * m4/time_r.m4: New file.
18622         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
18623         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
18624         is. Check for timegm declaration.
18625         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
18626         Do not check for gmtime_r.
18627         Replace mktime if __mktime_internal does not exist and if mktime
18628         hasn't been replaced already.
18629
18630 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18631
18632         * lib/time_r.c, lib/time_r.h: New files.
18633
18634         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
18635         __localtime_r.
18636         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
18637         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
18638
18639         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
18640         __gmtime_r.
18641         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
18642         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
18643         Include <time_r.h>.
18644
18645         * lib/timegm.c: Switch to glibc implementation, with the following
18646         changes:
18647         [defined HAVE_CONFIG_H]: Include <config.h>.
18648         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
18649         (__mktime_internal) [!defined _LIBC]: New decl.
18650         (__gmtime_r) [!defined _LIBC]: New macro and function.
18651         (timegm): Use a prototype, since gnulib assumes C89.
18652         Do not bother declaring tmp to be const, as it's not really usefu.
18653         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
18654         (timegm): Declare only if HAVE_DECL_TIMEGM.
18655
18656 2003-09-06  Paul Eggert  <eggert@twinsun.com>
18657
18658         * MODULES.html.sh (func_all_modules): Add time_r.
18659         * modules/time_r: New file.
18660         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
18661         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
18662
18663 2003-09-03  Paul Eggert  <eggert@twinsun.com>
18664
18665         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
18666         Bug reported by Lute Kamstra in
18667         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
18668
18669         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
18670         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
18671         course with correspondingly smaller numbers for tomorrow and
18672         yesterday.  From Tadayoshi Funaba.  Originally installed into
18673         sh-utils on 1999-08-07, but the patch got lost (I guess during the
18674         coreutils merge?).
18675
18676 2003-08-31  Simon Josefsson  <jas@extundo.com>
18677
18678         * modules/timegm: New file.
18679         * MODULES.html.sh (func_all_modules): Add timegm.
18680
18681 2003-08-31  Simon Josefsson  <jas@extundo.com>
18682
18683         * m4/timegm.m4: New file.
18684
18685 2003-08-31  Simon Josefsson  <jas@extundo.com>
18686
18687         * lib/timegm.h: New file.
18688         * lib/timegm.c: New file.  Based on
18689         wget-1.8.2/src/http.c:mktime_from_utc.
18690
18691 2003-08-31  Karl Berry  <karl@gnu.org>
18692
18693         * lib/argp.h: update from libc.
18694
18695 2003-08-28  Bruno Haible  <bruno@clisp.org>
18696
18697         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
18698         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
18699         followed by '#define fnmatch fnmatch_posix' gives an error.
18700
18701 2003-08-28  Bruno Haible  <bruno@clisp.org>
18702
18703         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
18704         warning on QNX, which defines O_BINARY to 000000.
18705
18706 2003-08-27  Jim Meyering  <jim@meyering.net>
18707
18708         * m4/mkstemp.m4: Require that the system mkstemp be able to create
18709         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
18710         would fail after 32.  Reported by Danny Levinson.  Details here:
18711         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
18712
18713 2003-08-24  Bruno Haible  <bruno@clisp.org>
18714
18715         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
18716         MSVC7 <stdio.h> is included later.
18717
18718 2003-08-22  Simon Josefsson  <jas@extundo.com>
18719
18720         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
18721
18722 2003-08-20  Karl Berry  <karl@gnu.org>
18723
18724         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
18725
18726 2003-08-20  Bruno Haible  <bruno@clisp.org>
18727
18728         * modules/progname: New file.
18729         * MODULES.html.sh (func_all_modules): Add progname.
18730
18731 2003-08-20  Bruno Haible  <bruno@clisp.org>
18732
18733         * lib/progname.h: New file, from GNU gettext.
18734         * lib/progname.c: New file, from GNU gettext.
18735         * lib/progreloc.c: New file, from GNU gettext.
18736
18737 2003-08-19  Jim Meyering  <jim@meyering.net>
18738
18739         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
18740         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
18741
18742 2003-08-19  Bruno Haible  <bruno@clisp.org>
18743
18744         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
18745         more.
18746
18747 2003-08-19  Bruno Haible  <bruno@clisp.org>
18748
18749         * lib/xstrdup.c: Assume <string.h> exists.
18750
18751 2003-08-18  Paul Eggert  <eggert@twinsun.com>
18752
18753         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
18754         in makefile rules.
18755
18756 2003-08-18  Jim Meyering  <jim@meyering.net>
18757
18758         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
18759         * m4/lib-ld.m4: Likewise.
18760
18761 2003-08-18  Jim Meyering  <jim@meyering.net>
18762
18763         * lib/setenv.h: Indent nested cpp directive.
18764         * lib/vasnprintf.c: Remove trailing blanks.
18765
18766 2003-08-17  Simon Josefsson  <jas@extundo.com>
18767
18768         * modules/xstrndup: New file.
18769         * MODULES.html.sh (func_all_modules): Add xstrndup.
18770
18771 2003-08-17  Simon Josefsson  <jas@extundo.com>
18772
18773         * modules/argp: Fix autoconf macro name. Add more dependencies.
18774
18775 2003-08-17  Simon Josefsson  <jas@extundo.com>
18776
18777         * m4/xstrndup.m4: New file.
18778
18779 2003-08-17  Simon Josefsson  <jas@extundo.com>
18780
18781         * m4/argp.m4: New file.
18782
18783 2003-08-17  Simon Josefsson  <jas@extundo.com>
18784             Bruno Haible  <bruno@clisp.org>
18785
18786         * lib/xstrndup.h: New file.
18787         * lib/xstrndup.c: New file.
18788
18789 2003-08-17  Bruno Haible  <bruno@clisp.org>
18790
18791         * modules/strndup (Files, Include): Add lib/strndup.h.
18792
18793 2003-08-17  Bruno Haible  <bruno@clisp.org>
18794
18795         * modules/euidaccess (Files): Add lib/euidaccess.h.
18796
18797 2003-08-17  Bruno Haible  <bruno@clisp.org>
18798
18799         * lib/strndup.h: New file.
18800
18801 2003-08-17  Bruno Haible  <bruno@clisp.org>
18802
18803         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
18804         like AC_GNU_SOURCE.
18805         * modules/extensions (configure.ac): Comment out the invocation of
18806         gl_USE_SYSTEM_EXTENSIONS.
18807
18808 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18809
18810         Merges from coreutils, etc.
18811         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
18812         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
18813         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
18814         fixing a typo.
18815         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
18816         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
18817
18818 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18819
18820         Document merge from coreutils.
18821         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
18822         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
18823         * modules/utime: Add m4/utimes-null.m4.
18824
18825 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18826
18827         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
18828         space, undoing this 2003-08-12 change:
18829         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
18830
18831 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18832
18833         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
18834         strtoul.c from libc, undoing this 2003-08-12 change:
18835         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
18836
18837 2003-08-16  Jim Meyering  <jim@meyering.net>
18838
18839         Merges from coreutils.
18840         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
18841         prefix.  Adjust cache variables similarly.  Create 500 rather than
18842         just 300 files, to exercise bug on Darwin6.5, too.
18843         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
18844         $missing_dir.
18845         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
18846         AM_SYS_POSIX_TERMIOS.
18847         Reported by mkc@mathdogs.com.
18848         Also change use of $am_cv_sys_posix_termios
18849         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
18850         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
18851         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
18852         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
18853         in /proc/mounts until it finds one with matching device number.  This
18854         is unnecessary when the FILE argument *is* a mount point.  No stat call
18855         is necessary in that case.  So, disable the statvfs-testing code on
18856         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
18857         as RedHat bug# 84846.
18858         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
18859         to 1MB, so as not to render systems with no stack size limit (e.g.,
18860         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
18861         Include <unistd.h>.  On some systems,
18862         it is required for the definition of _SC_PAGESIZE.
18863
18864 2003-08-16  Jim Meyering  <jim@meyering.net>
18865
18866         Merge from coreutils.
18867         * lib/xstrtoimax.c: #else #if -> #elif.
18868         * lib/xstrtoumax.c: Likewise.
18869
18870 2003-08-16  Jim Meyering  <jim@meyering.net>
18871
18872         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
18873         * m4/utimes.m4: Removed.
18874         * m4/utimes-null.m4: Renamed from utimes.m4.
18875
18876         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
18877         to 1MB, so as not to render systems with no stack size limit (e.g.,
18878         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
18879         Include <unistd.h>.  On some systems,
18880         it is required for the definition of _SC_PAGESIZE.
18881
18882 2003-08-16  Jim Meyering  <jim@meyering.net>
18883         and Paul Eggert  <eggert@cs.ucla.edu>
18884
18885         Merges from coreutils, etc.
18886
18887         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
18888         using the latest version from cvs.  This avoids problems with #line
18889         directives using a vendor (Sun) compiler.
18890         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
18891         Don't set GETGROUPS_LIB here; now it's
18892         done via getgroups.m4's wrapper function.
18893         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
18894         rather than just in sh-util/configure.in, so that the
18895         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
18896         same.
18897         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
18898         AC_FUNC_GETLOADAVG where to find getloadavg.c.
18899         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
18900         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
18901         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
18902         Remove code that is now done by the newly-required macros.
18903         Append $(EXEEXT) to DF_PROG.
18904         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
18905         Do not invoke or require the following here,
18906         since prereq.m4 or some gnulib .m4 now does this for us:
18907         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
18908         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
18909         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
18910         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
18911         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
18912         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
18913         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
18914         AC_FUNC_OBSTACK.
18915         Do not replace the following functions, as this is now the job
18916         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
18917         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
18918         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
18919         atexit getpass, strdup, getpagesize.
18920         Replace 'raise'.
18921         Do not check for the following functions, as this is now the job
18922         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
18923         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
18924         setregid.
18925         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
18926         Check for sys/sysctl.h.
18927         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
18928         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
18929         of checking for ssize_t ourselves.
18930
18931         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
18932         Require every macro that gnulib/modules/* suggests for us.
18933         (jm_PREREQ_ADDEXT): New macro.
18934         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
18935         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
18936
18937         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
18938         (gl_PHYSMEM): Use it.
18939         Also check for `table' function.
18940         Check for new headers and functions.
18941         Add check for sys/sysmp.h.
18942         With suggestions from Kaveh Ghazi.
18943         Ignore headers that are present but cannot be compiled.  This
18944         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
18945         C 5.4.
18946
18947 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18948
18949         Document merge from coreutils.
18950         * modules/userspec: Depend on posixver.
18951         * modules/strftime: Depend on tzset.
18952
18953 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18954
18955         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
18956         rather than tab, after '#' in shell-script copyright notices.
18957         Suggested by Bruno Haible.
18958
18959 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18960
18961         * config/srclist-update: Use three spaces, rather than tab, after '#'
18962         in shell-script copyright notices.  Suggested by Bruno Haible.
18963         Remove unnecessary parenthesization in regular expression.
18964
18965 2003-08-15  Jim Meyering  <jim@meyering.net>
18966
18967         Merge from coreutils.
18968         * lib/xgethostname.c: Include <stdlib.h>.
18969         (xghostname): Don't exit for anything other than memory-related
18970         failure; just return NULL.
18971         * lib/userspec.c: Include "posixver.h".
18972         (parse_user_spec): Accept `.' as a separator only
18973         in pre-POSIX-200112 mode.
18974         * lib/strtoimax.c: Use #elif rather than #else #if.
18975         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
18976         Remove function, now that we can rely on a working tzset function.
18977         [!_LIBC]: Ensure that the required autoconf test has been run.
18978         [!defined _NL_CURRENT && HAVE_STRFTIME]:
18979         Use underlying_strftime for %r.
18980         * lib/sha.c: Merge in some clean-up and optimization changes from
18981         glibc.
18982         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
18983         Ensure that it is a multiple of 64.
18984         Rearrange loop exit tests so as to avoid performing an
18985         additional fread after encountering an error or EOF.
18986         * lib/realloc.c: Update copyright date.
18987
18988 2003-08-15  Jim Meyering  <jim@meyering.net>
18989         and Paul Eggert  <eggert@twinsun.com>
18990
18991         Merge from coreutils.
18992         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
18993         member but strut utmpx does not.  Needed for AIX 4.3.3.
18994         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
18995
18996 2003-08-15  Jim Meyering  <jim@meyering.net>
18997         and Paul Eggert  <eggert@cs.ucla.edu>
18998
18999         Merges from coreutils, etc.
19000         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
19001         Require gl_FUNC_TZSET_CLOBBER.
19002         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
19003         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
19004         members.
19005
19006 2003-08-14  Paul Eggert  <eggert@twinsun.com>
19007
19008         Help the merge from coreutils.
19009         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
19010         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
19011         * m4/tzset.m4: Use it too.
19012
19013 2003-08-14  Paul Eggert  <eggert@twinsun.com>
19014
19015         * modules/tzset: New file.
19016
19017 2003-08-14  Jim Meyering  <jim@meyering.net>
19018
19019         Merges from coreutils.
19020         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
19021         variable names, rather than @FNMATCH_H@.
19022         * modules/alloca: Likewise for $(ALLOCA_H).
19023
19024         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
19025         the three copies of the literal target, `fnmatch.h'.
19026         * modules/alloca (alloca.h): Likewise.
19027
19028 2003-08-14  Jim Meyering  <jim@meyering.net>
19029
19030         Merge from coreutils.
19031         * m4/tzset.m4: New file.
19032         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
19033         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
19034         otherwise, AIX 5.1 systems would end up using the latter.
19035         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
19036         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
19037         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
19038         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
19039
19040 2003-08-14  Jim Meyering  <jim@meyering.net>
19041
19042         Merge from coreutils.
19043         * lib/obstack.h: Whitespace changes.
19044         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
19045         and xcalloc return values.
19046         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
19047         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
19048         hang on OSF/1 5.1 for DIR on both local and remote file systems.
19049         Reported by (and fix confirmed by) Nelson H. F. Beebe.
19050         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19051         error from mntctl.
19052         Use mntctl's return value to drive the entry-processing loop, since
19053         we can't rely on the value of the vmt_length member in the last
19054         entry.  On some systems doing so could result in exhausting
19055         virtual memory.  Based in part on a patch from Mike Jetzer.
19056
19057 2003-08-14  Jim Meyering  <jim@meyering.net>
19058         and Paul Eggert  <eggert@twinsun.com>
19059
19060         Merges from coreutils, plus other fixes.
19061         * lib/physmem.c: Merge in portability changes from gcc/libiberty
19062         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
19063         for credits and details.  Thanks to Kaveh Ghazi for helping
19064         to keep these files in sync.
19065         (ARRAY_SIZE): Define it.
19066         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
19067         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
19068         (memcasecmp): Don't assume size_t fits in unsigned int.
19069         Remove casts and duplicate code.
19070         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
19071         (memcpy): Remove definition.
19072         Merge in some clean-up and optimization changes from glibc.
19073         [BLOCKSIZE]: Move definition to top of file.
19074         Ensure that it is a multiple of 64.
19075         Rearrange loop exit tests so as to avoid performing an
19076         additional fread after encountering an error or EOF.
19077         * lib/md5.h (md5_uintptr): Define.
19078         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
19079         return to the initial working directory.  Preserve errno
19080         for caller.
19081         * lib/idcache.c: Include "xalloc.h".
19082         (xmalloc, xrealloc): Remove decls.
19083         (getuser): Remove casts no longer required in C89.
19084         * lib/human.c: Include stdio.h, for sprintf.
19085         * lib/group-member.c: Include "xalloc.h".
19086         (xmalloc, xrealloc): Remove decls.
19087         (get_group_info): Remove casts no longer required in C89.
19088         * lib/getusershell.c (readname): Remove casts no longer required in
19089         C89.
19090         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
19091         * lib/getline.c: Whitespace fix, from coreutils.
19092
19093 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19094
19095         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
19096         Check for isascii.
19097
19098         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
19099         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
19100         Undo previous (whitespace-only) change.
19101
19102 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19103
19104         * lib/exclude.c: Include <ctype.h>
19105         (IN_CTYPE_DOMAIN): New macro.
19106         (is_space): New fn.
19107         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
19108         and empty lines.
19109
19110         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
19111         Undo previous (whitespace-only) change.
19112
19113 2003-08-13  Paul Eggert  <eggert@twinsun.com>
19114
19115         * config/srclist-update: Change update back to the old behavior,
19116         leaving whitespace alone.  Use one 'sed' command rather than a
19117         pipeline.
19118         (fixlicense): Now a variable, not a function.
19119         (remove_trailing_blanks): Remove.
19120         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
19121         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
19122         Undo previous (whitespace-only) change.
19123
19124 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19125
19126         Merge from coreutils.
19127         * modules/euidaccess: Add lib_SOURCES, include for new
19128         file euidaccess.h
19129
19130 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19131
19132         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
19133         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
19134         Normalize leading white space and remove trailing white space.
19135
19136         Merge from coreutils
19137         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
19138
19139         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
19140         0.12.1.  These files are now being upgraded automatically by
19141         ../config/srclist-update.
19142
19143 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19144
19145         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
19146         Normalize leading white space and remove trailing white space.
19147         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
19148         notice, as per ../config/srclist-update.
19149
19150         Merge from coreutils.
19151         * lib/euidaccess.h: New file.
19152         * lib/euidaccess.c: Include it.
19153         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
19154         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
19155         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
19156
19157 2003-08-12  Paul Eggert  <eggert@twinsun.com>
19158
19159         * config/srclist-update: Add copyright notice.
19160         (remove_id_lines, remove_trailing_blanks): New constants.
19161         (fixfile): Use them to normalize spacing a bit in copied files.
19162         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
19163         Normalize leading white space and remove trailing white space.
19164
19165         * config/texinfo.tex: Sync with texinfo.
19166
19167         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
19168         strtoul.c from libc, to merge coreutils whitespace changes.
19169
19170         * config/srclist.txt: Get the following m4 files from gettext:
19171         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
19172         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
19173         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
19174         wint_t.m4.
19175
19176 2003-08-12  Karl Berry  <karl@gnu.org>
19177
19178         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
19179         been made.
19180
19181 2003-08-11  Paul Eggert  <eggert@twinsun.com>
19182
19183         * modules/gnu-source, m4/gnu-source.m4:
19184         Remove; we're assuming Autoconf 2.54 or later now.
19185         Suggested by Bruno Haible.
19186         * MODULES.html.sh (func_all_modules): Remove gnu-source.
19187
19188 2003-08-11  Bruno Haible  <bruno@clisp.org>
19189
19190         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
19191
19192 2003-08-11  Bruno Haible  <bruno@clisp.org>
19193
19194         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
19195         (vasnprintf): Use it instead of wcslen.
19196
19197 2003-08-11  Bruno Haible  <bruno@clisp.org>
19198
19199         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
19200         value to ensure that _Bool promotes to int. Use #define for _Bool when
19201         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
19202
19203 2003-08-10  Karl Berry  <karl@gnu.org>
19204
19205         * lib/regex.h: update from libc (whitespace fix).
19206
19207 2003-08-09  Paul Eggert  <eggert@twinsun.com>
19208
19209         Merge some files from coreutils.  These changes were
19210         originally made by Jim Meyering.
19211         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
19212         many older Unixes require this.
19213         * lib/alloca.c (alloca): Remove cast to argument of free;
19214         no longer needed in C89.
19215         * lib/alloca_.h, regex.h: Fix white space to match
19216         what GNU indent does.
19217
19218 2003-08-09  Paul Eggert  <eggert@twinsun.com>
19219
19220         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
19221         apparently Emacs's Unicode mode got confused before my 2003-08-05
19222         checkin.
19223
19224 2003-08-08  Paul Eggert  <eggert@twinsun.com>
19225
19226         * m4/extensions.m4: New file.
19227         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
19228         Require gl_USE_SYSTEM_EXTENSIONS.
19229         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
19230         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
19231
19232 2003-08-08  Paul Eggert  <eggert@twinsun.com>
19233
19234         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
19235         * modules/extensions, modules/gnu-source: New files.
19236         * modules/timespec, modules/unlocked-io: Depend on extensions.
19237
19238 2003-08-07  Paul Eggert  <eggert@twinsun.com>
19239
19240         * modules/restrict: New file.
19241         * MODULES.html.sh (func_all_modules): Add restrict.
19242         * modules/regex: Depend on restrict.
19243
19244 2003-08-07  Paul Eggert  <eggert@twinsun.com>
19245
19246         * m4/restrict.m4: New file.
19247         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
19248
19249 2003-08-07  Bruno Haible  <bruno@clisp.org>
19250
19251         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
19252         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
19253
19254 2003-08-07  Bruno Haible  <bruno@clisp.org>
19255
19256         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
19257         makes the module 'getndelim2' compatible with the module 'getline'.
19258
19259 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19260
19261         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
19262         byte with "\201" to avoid glitches when editing that source file
19263         with multi-gnome-terminal.
19264
19265 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19266
19267         * lib/bumpalloc.h: Remove.
19268
19269 2003-08-05  Paul Eggert  <eggert@twinsun.com>
19270
19271         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
19272         * modules/bumpalloc: Remove.
19273
19274 2003-08-04  Paul Eggert  <eggert@twinsun.com>
19275
19276         * lib/getloadavg.c: Change copyright notice and spacing to conform to
19277         GNU coding style.
19278
19279         Merge from coreutils.
19280         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
19281         1. From glibc.
19282         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
19283         from Karl Berry, implemented by Jim Meyering.
19284         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
19285         from Dmitry V. Levin.
19286         Remove anachronistic cast of xrealloc.
19287         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
19288         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
19289         type. Otherwise, it wouldn't compile with at least /bin/cc on
19290         ymp-cray-unicos9.0.2.X.
19291         Combine two mostly-identical uses of alloca into one.
19292         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
19293
19294 2003-08-04  Dave Love  <d.love@dl.ac.uk>
19295
19296         [From Emacs.]
19297
19298         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
19299         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
19300         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
19301         obsolete NLIST_NAME_UNION.
19302         [__GNU__]: Undef BSD and FSCALE.
19303         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
19304
19305 2003-08-03  Paul Eggert  <eggert@twinsun.com>
19306
19307         * lib/stdbool_.h (_Bool): Make it signed char, instead of
19308         an enum type, so that it's guaranteed to promote to int.  See:
19309         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
19310
19311 2003-08-03  Karl Berry  <karl@gnu.org>
19312
19313         * config/depcomp: update from automake.
19314
19315 2003-07-31  Paul Eggert  <eggert@twinsun.com>
19316
19317         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
19318         (strerror): Don't assume that a printable int fits in 14 bytes.
19319
19320 2003-07-31  Bruno Haible  <bruno@clisp.org>
19321
19322         * modules/getpass-gnu: New file.
19323         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
19324
19325 2003-07-31  Bruno Haible  <bruno@clisp.org>
19326
19327         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
19328
19329 2003-07-24  Karl Berry  <karl@gnu.org>
19330
19331         * config/missing: update from automake.
19332
19333 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
19334             Bruno Haible  <bruno@clisp.org>
19335
19336         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
19337         * lib/getline.c (getline, getdelim): Likewise.
19338         Remove _GNU_SOURCE define; now it's defined in config.h through
19339         m4/getline.m4.
19340
19341 2003-07-23  Karl Berry  <karl@gnu.org>
19342
19343         * config/config.sub: update from prep.
19344
19345 2003-07-22  Paul Eggert  <eggert@twinsun.com>
19346
19347         * modules/xalloc (Depends-on): Add exitfail.
19348         * modules/xmemcoll: Likewise.
19349
19350 2003-07-22  Paul Eggert  <eggert@twinsun.com>
19351
19352         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
19353         over-parenthesization in macros.
19354
19355         Sync with coreutils.
19356
19357         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
19358         required by C99.
19359
19360         Use `exit_failure' for xalloc and xmemcoll instead of their own
19361         private exit-failure variables.
19362         * lib/xalloc.h (xalloc_exit_failure): Remove.
19363         * lib/xmalloc.c: Likewise.  Include exitfail.h.
19364         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
19365         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
19366         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
19367         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
19368
19369 2003-07-20  Jim Meyering  <jim@meyering.net>
19370
19371         * modules/closeout (Depends-on): Add exitfail.
19372         Suggestion from Bruno Haible.
19373
19374 2003-07-19  Karl Berry  <karl@gnu.org>
19375
19376         * config/config.sub: update from prep.
19377
19378 2003-07-18  Paul Eggert  <eggert@twinsun.com>
19379
19380         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
19381         Remove.
19382         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
19383         to test that it can stand by itself.  Include "exitfail.h".
19384         Clients should set exit_failure instead.
19385         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
19386
19387 2003-07-18  Bruno Haible  <bruno@clisp.org>
19388
19389         * modules/getndelim2: New file.
19390         * modules/getline: Share files with module getndelim2.
19391         * modules/getnline: Depend on getndelim2 instead of sharing files with
19392         it. Add getnline.c to lib_SOURCES.
19393         * MODULES.html.sh (func_all_modules): Add getndelim2.
19394
19395 2003-07-18  Bruno Haible  <bruno@clisp.org>
19396
19397         * m4/getndelim2.m4: New file.
19398         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
19399         invoke gl_PREREQ_GETNDELIM2.
19400         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
19401         gl_PREREQ_GETNDELIM2.
19402         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
19403         gl_GETNDELIM2.
19404
19405 2003-07-18  Bruno Haible  <bruno@clisp.org>
19406
19407         * lib/getndelim2.h: New file.
19408         * lib/getndelim2.c: Make into a module of its own. Include config.h,
19409         getndelim2.h.
19410         (getndelim2): Make non-static. Change return type to ssize_t.
19411         * lib/getline.h: Change argument names.
19412         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
19413         * lib/getnline.c: Include getndelim2.h.
19414
19415 2003-07-18  Andreas Schwab  <schwab@suse.de>
19416
19417         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
19418
19419 2003-07-17  Karl Berry  <karl@gnu.org>
19420
19421         * config/config.sub: update from prep.
19422
19423 2003-07-17  Bruno Haible  <bruno@clisp.org>
19424
19425         * modules/getnline: New file.
19426         * modules/getline: Add lib/getndelim2.c to source file list.
19427         * MODULES.html.sh (func_all_modules): Add getnline.
19428
19429 2003-07-17  Bruno Haible  <bruno@clisp.org>
19430
19431         * m4/getnline.m4: New file.
19432
19433 2003-07-17  Bruno Haible  <bruno@clisp.org>
19434
19435         * m4/Makefile.am.in: Remove file.
19436         * m4/Makefile.am: Remove file.
19437         * m4/Makefile.in: Remove file.
19438
19439 2003-07-17  Bruno Haible  <bruno@clisp.org>
19440
19441         * lib/getnline.h: New file.
19442         * lib/getnline.c: New file.
19443         * lib/getndelim2.c: New file, extracted from getline.c.
19444         (getndelim2): Renamed from getdelim2, with added nmax argument.
19445         * lib/getline.c: Include getndelim2.c.
19446         (getdelim2): Moved out to getndelim2.c.
19447         (getline, getdelim): Update.
19448
19449 2003-07-17  Bruno Haible  <bruno@clisp.org>
19450
19451         * lib/Makefile.am: Remove file.
19452         * lib/Makefile.in: Remove file.
19453
19454 2003-07-17  Bruno Haible  <bruno@clisp.org>
19455
19456         * configure.in: Remove file.
19457         * Makefile.in: Remove file.
19458
19459 2003-07-17  Bruno Haible  <bruno@clisp.org>
19460
19461         * MODULES.html.sh: Put the </BODY> right before </HTML>.
19462
19463 2003-07-16  Karl Berry  <karl@gnu.org>
19464
19465         * config/srclist-update: was running fixlicense twice, which caused
19466                 texinfo.tex to be nullified for some reason.  Simplify,
19467                 $gplsrc is no longer needed as far as I can see?
19468
19469 2003-07-16  Jim Meyering  <jim@meyering.net>
19470
19471         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
19472
19473 2003-07-15  Paul Eggert  <eggert@twinsun.com>
19474
19475         * config/srclist.txt: Get the following files from gettext-runtime/intl
19476         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
19477         ref-del.sin.  From Bruno Haible.
19478         * config/srclist-update (fixfile): Change grep pattern again, since the
19479         previous fix didn't work (there was another trailing $).  Use
19480         '[$]' to escape the $s.
19481
19482 2003-07-15  Karl Berry  <karl@gnu.org>
19483
19484         * lib/vasnprintf.c: update from gettext.
19485
19486 2003-07-15  Karl Berry  <karl@gnu.org>
19487
19488         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
19489         gets expanded when surrounded by '$'.
19490
19491 2003-07-15  Jim Meyering  <jim@meyering.net>
19492
19493         * modules/save-cwd: Don't depend on error.  From Derek Price.
19494
19495 2003-07-15  Jim Meyering  <jim@meyering.net>
19496
19497         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
19498
19499 2003-07-14  Simon Josefsson  <jas@extundo.com>
19500
19501         * modules/mempcpy: New file.
19502         * MODULES.html.sh (func_all_modules): Add mempcpy.
19503
19504 2003-07-14  Simon Josefsson  <jas@extundo.com>
19505
19506         * m4/mempcpy.m4: New file.
19507
19508 2003-07-14  Simon Josefsson  <jas@extundo.com>
19509
19510         * lib/mempcpy.h: New file.
19511         * lib/mempcpy.c: New file.
19512
19513 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19514
19515         * modules/getdate, modules/posixtm: Depend on mktime.
19516
19517 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19518
19519         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
19520         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
19521         unicodeio.c, unicodeio.h, unlocked-io.h:
19522         Switch from LGPL to GPL.
19523
19524 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19525
19526         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
19527         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
19528         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
19529         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
19530         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
19531         updated automatically by ../config/srclist-update.  This changes
19532         their license from LPGL to GPL.
19533
19534 2003-07-14  Paul Eggert  <eggert@twinsun.com>
19535
19536         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
19537         assumed to refer to the root of the most recent stable gettext version.
19538         * config/srclistvars.sh: Add defaults for eggert.
19539         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
19540         Match "This program" as well as "The program".  This is needed
19541         for gettext.
19542
19543 2003-07-14  Jim Meyering  <jim@meyering.net>
19544
19545         Don't emit diagnostics.  Let callers do that.
19546         * lib/save-cwd.c: Don't include "error.h".
19547         (save_cwd): Don't call error.  Ensure that errno is valid
19548         when returning nonzero.
19549
19550         * lib/save-cwd.h (restore_cwd): Update prototype.
19551         * lib/save-cwd.c (restore_cwd): Remove two parameters.
19552         Simplify.  Don't call error upon failure.  Let callers do that.
19553         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
19554         when auditing is enabled.  But don't bother updating the #if.
19555
19556 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
19557
19558         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
19559         it breaks C++ compilation.
19560         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
19561
19562 2003-07-10  Simon Josefsson  <jas@extundo.com>
19563
19564         * modules/strchrnul (Makefile.am): Add strchrnul.h.
19565
19566 2003-07-10  Jim Meyering  <jim@meyering.net>
19567
19568         * m4/clock_time.m4: Remove trailing blank.
19569         * m4/intmax_t.m4: Likewise.
19570
19571 2003-07-10  Jim Meyering  <jim@meyering.net>
19572
19573         * lib/vasnprintf.c: Remove trailing blanks.
19574         Make cpp indentation consistent.
19575
19576 2003-07-09  Paul Eggert  <eggert@twinsun.com>
19577
19578         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
19579         posixver.c, strftime.c, strnlen.c, strverscmp.c:
19580         Switch from LGPL to GPL.
19581
19582 2003-07-09  Paul Eggert  <eggert@twinsun.com>
19583
19584         * config/srclist.txt: Sort sublists.  Add
19585         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
19586         that differ from gnulib for one reason or another; we'd like this list
19587         to be smaller but for now let's document what we have.
19588
19589 2003-07-08  Paul Eggert  <eggert@twinsun.com>
19590
19591         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
19592         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
19593         and sweeter "eval x=$x".
19594         * config/srclist.txt: Get lib/argp* from glibc.
19595
19596 2003-07-07  Paul Eggert  <eggert@twinsun.com>
19597
19598         * lib/mktime.c: Fix some boundary cases and remove need for floating
19599         point.
19600
19601         Issue a compile-time diagnostic if time_t is floating point, or if
19602         two's complement arithmetic is not in effect, or if arithmetic
19603         right shift does not propagate the sign.  These assumptions were
19604         all in the original code but they weren't checked.
19605
19606         (TIME_T_MIDPOINT, verify): New macros.
19607         (__isleap): Remove; it has integer overflow problems.
19608         (leapyear): New function, without those problems.
19609         (ydhms_tm_diff): Remove; splitting into two parts.
19610         (ydhms_diff): New function, containing the arithmetic part of
19611         the old ydhms_tm_diff function.  Issue a compile-time
19612         diagnostic if we are not using C99 integer division.
19613         Avoid casts when possible.
19614         (guess_time_tm): New function, containing the checking part of
19615         the old ydhms_tm_diff function.  Return the new value, rather than
19616         the difference between it and the old.  Accept a new argument T
19617         so that *T specifies the old value.  Check for overflow in the result.
19618
19619         (__mktime_internal): Use a time_t offset, not a long int offset.
19620         This undoes the 2003-06-04 change, which is no longer needed now
19621         that we have better overflow checking.
19622         (localtime_offset): Likewise.
19623
19624         (__mktime_internal): Avoid harmful overflow on hosts where time_t
19625         and long are 64-bit but int is only 32-bit.
19626         (ydhms_diff): Use long int to store year1 and yday1.
19627         Issue a compile-time diagnostic if long int is not wide enough.
19628
19629         (__mktime_internal): Use long int to store adjusted year and yday.
19630         Use plain C rather than preprocessor commands, if that doesn't
19631         affect efficiency.
19632         Check for overflow (and try to repair) after each probe
19633         rather than checking only at the very end.  This avoids some bugs
19634         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
19635         does not equal GMT offset at maximum time).
19636         Use integer to check for overflow rather than floating point; this
19637         is more portable to non-IEEE hosts, and is a tad faster.
19638         When we detect that we are oscillating between two values,
19639         don't check whether tm_isdst has the requested value, since
19640         we already know the answer.  When tm_isdst has the wrong value,
19641         use a different heuristic to find the right one, based on the
19642         extreme values actually observed in practice in tz2003a,
19643         rather than the (overly optimistic) "previous 3 calendar quarters".
19644
19645         (not_equal_tm, print_tm, check_result): Use "const T" rather than
19646         "T const" to accommodate glibc style.
19647         (check_result): Use less-confusing report format.  "long" -> "long int.
19648         (main): Likewise.
19649         Don't loop if the iteration overflows time_t.
19650         Allow a negative step in the iteration.
19651
19652 2003-07-06  Karl Berry  <karl@gnu.org>
19653
19654         * config/depcomp: update from automake.
19655         * config/config.sub: update from prep.
19656
19657 2003-07-03  Karl Berry  <karl@gnu.org>
19658
19659         * config/config.guess: update from prep.
19660
19661 2003-07-01  Paul Eggert  <eggert@twinsun.com>
19662
19663         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
19664         xreadlink.c now includes it unconditionally.
19665
19666 2003-07-01  Paul Eggert  <eggert@twinsun.com>
19667
19668         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
19669         having it depend on HAVE_SYS_TYPES_H.
19670
19671 2003-07-01  Bruno Haible  <bruno@clisp.org>
19672
19673         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
19674         <sys/types.h> should be sufficient.
19675         Reported by Paul Eggert.
19676
19677 2003-06-26  Karl Berry  <karl@gnu.org>
19678
19679         * config/depcomp: update from automake.
19680
19681 2003-06-26  Bruno Haible  <bruno@clisp.org>
19682
19683         * modules/human: Depend on module stdbool.
19684
19685 2003-06-25  Bruno Haible  <bruno@clisp.org>
19686
19687         * modules/readlink: New file.
19688         * modules/xreadlink: Depend on it.
19689         * MODULES.html.sh (func_all_modules): Add readlink.
19690
19691 2003-06-25  Bruno Haible  <bruno@clisp.org>
19692
19693         * m4/readlink.m4: New file.
19694
19695 2003-06-25  Bruno Haible  <bruno@clisp.org>
19696
19697         * lib/readlink.c: New file.
19698
19699 2003-06-22  Karl Berry  <karl@gnu.org>
19700
19701         * config/srclist.txt: update mkinstalldirs from automake.
19702         * config/mkinstalldirs: update.
19703
19704 2003-06-22  Bruno Haible  <bruno@clisp.org>
19705
19706         Portability to mingw32.
19707         * m4/ssize_t.m4: New file, from GNU gettext.
19708         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
19709         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
19710
19711 2003-06-22  Bruno Haible  <bruno@clisp.org>
19712
19713         * modules/safe-read: Add m4/ssize_t.m4.
19714         * modules/xreadlink: Add m4/ssize_t.m4.
19715
19716 2003-06-20  Bruno Haible  <bruno@clisp.org>
19717
19718         Assume C89, so PARAMS isn't needed.
19719         * lib/unicodeio.h (PARAMS): Remove.
19720         * lib/unicodeio.c: Don't use PARAMS.
19721
19722 2003-06-18  Karl Berry  <karl@gnu.org>
19723
19724         * config/config.{guess,sub}: update from prep.
19725
19726 2003-06-18  Jim Meyering  <jim@meyering.net>
19727
19728         Merge changes from coreutils.
19729         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
19730         Remove explicit declarations of xmalloc and realloc.
19731         Include xalloc.h.
19732         (read_utmp): Remove anachronistic cast of xmalloc.
19733
19734 2003-06-17  Paul Eggert  <eggert@twinsun.com>
19735
19736         Assume C89, so PARAMS isn't needed.
19737         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
19738         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
19739         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
19740         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
19741         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
19742         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
19743         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
19744         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
19745         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
19746         lib/xstrtod.h, lib/xstrtol.h: Likewise.
19747         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
19748         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
19749         no longer needed. Anyway, config.h should always be included before any
19750         other file.
19751
19752 2003-06-11  Simon Josefsson  <jas@extundo.com>
19753
19754         * modules/sysexits: New file.
19755         * MODULES.html.sh (func_all_modules): Add sysexits.
19756
19757 2003-06-11  Simon Josefsson  <jas@extundo.com>
19758
19759         * lib/sysexit_.h: New file.
19760
19761 2003-06-11  Derek Price  <derek@ximbiot.com>
19762
19763         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
19764         necessary.
19765
19766 2003-06-11  Bruno Haible  <bruno@clisp.org>
19767
19768         * m4/sysexits.m4: New file.
19769
19770 2003-06-10  Simon Josefsson  <jas@extundo.com>
19771
19772         * lib/argp.h: New file, from glibc.
19773         * lib/argp-ba.c: New file, from glibc.
19774         * lib/argp-eexst.c: New file, from glibc.
19775         * lib/argp-fmtstream.c: New file, from glibc.
19776         * lib/argp-fmtstream.h: New file, from glibc.
19777         * lib/argp-fs-xinl.c: New file, from glibc.
19778         * lib/argp-help.c: New file, from glibc.
19779         * lib/argp-namefrob.h: New file, from glibc.
19780         * lib/argp-parse.c: New file, from glibc.
19781         * lib/argp-pv.c: New file, from glibc.
19782         * lib/argp-pvh.c: New file, from glibc.
19783         * lib/argp-xinl.c: New file, from glibc.
19784
19785 2003-06-10  Simon Josefsson  <jas@extundo.com>
19786
19787         * modules/strchrnul: New file.
19788
19789 2003-06-10  Simon Josefsson  <jas@extundo.com>
19790
19791         * modules/argp: New file.
19792
19793 2003-06-10  Simon Josefsson  <jas@extundo.com>
19794
19795         * m4/strchrnul.m4: New file.
19796
19797 2003-06-10  Simon Josefsson  <jas@extundo.com>
19798
19799         * lib/strchrnul.h: New file.
19800         * lib/strchrnul.c: New file.
19801
19802 2003-06-10  Bruno Haible  <bruno@clisp.org>
19803
19804         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
19805
19806 2003-06-07  Karl Berry  <karl@gnu.org>
19807
19808         * config/config.{guess,sub}: update from prep.
19809
19810 2003-06-07  Jim Meyering  <jim@meyering.net>
19811
19812         * modules/strtod: Use $(...) notation, not @...@ for
19813         AC_REPLACE'd variables.
19814         * modules/localcharset: Likewise.
19815
19816 2003-06-07  Jim Meyering  <jim@meyering.net>
19817
19818         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
19819         in place of my name in the copyright comment.
19820         Remove definition and uses of __P.
19821
19822         From coreutils.
19823         * lib/stat.c: Don't declare xmalloc explicitly.
19824         Instead, include "xalloc.h".
19825         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
19826         xrealloc, and xcalloc return values.
19827         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
19828         Improve comment.
19829         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
19830
19831 2003-06-07  Bruno Haible  <bruno@clisp.org>
19832
19833         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
19834         avoid AC_CONFIG_LINKS.
19835         * modules/fnmatch (Makefile.am): Use explicit creation rule for
19836         fnmatch.h, to avoid AC_CONFIG_LINKS.
19837         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
19838
19839 2003-06-07  Bruno Haible  <bruno@clisp.org>
19840
19841         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
19842         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
19843         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
19844         directory.
19845         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
19846         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
19847         directory.
19848
19849 2003-06-06  Jim Meyering  <jim@meyering.net>
19850
19851         Merge from coreutils.
19852         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
19853         Consolidate declarations and initializations of *_base* locals.
19854
19855         Merge from coreutils.
19856         This avoids a core dump on systems without GNU putenv,
19857         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
19858         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
19859         (unsetenv): New static function, from GNU libc.
19860         (rpl_putenv): Use it.
19861
19862         * lib/modechange.c: Remove trailing blanks.
19863
19864         Merge from coreutils.
19865         * lib/fsusage.c: Remove declaration of statfs.
19866         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
19867
19868         * lib/posixtm.c: Include <stdbool.h> unconditionally.
19869
19870 2003-06-06  Jim Meyering  <jim@meyering.net>
19871
19872         * lib/stdbool_.h: Renamed from stdbool.h.in.
19873
19874 2003-06-06  Jim Meyering  <jim@meyering.net>
19875             Bruno Haible  <bruno@clisp.org>
19876
19877         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
19878         Adjust Makefile.am snippet not to redirect directly to target.
19879         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
19880
19881 2003-06-05  Paul Eggert  <eggert@twinsun.com>
19882
19883         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
19884         mismatch, look in future quarters as well as past.  This fixes a
19885         bug when processing fall-backwards gaps immediately after a long
19886         period of daylight-saving time.
19887
19888         * lib/mktime.c: Assume freestanding C89 or better.
19889         (HAVE_LIMITS_H): Remove.  Assume it's 1.
19890         (__P): Remove; not used.
19891         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
19892         (mktime, not_equal_tm, print_tm, check_result,
19893         main): Use prototypes.  Use const * where appropriate.
19894         (main): Fix typo in testing code that uncovered by above changes.
19895         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
19896
19897 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19898
19899         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
19900         locale.h, localeconv.  This merges changes from coreutils.
19901
19902         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
19903         It can be removed after the next Autoconf is released.
19904         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
19905         needed.
19906
19907 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19908
19909         * lib/mktime.c: Fix Debian bug 177940
19910         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
19911         (localtime_offset): Now long int, not time_t, because we want it
19912         to be guaranteed to be signed.  All uses changed.
19913         (__mktime_internal): If overflow would occur when adding offset,
19914         don't add it.
19915
19916         Merge 'human' changes from coreutils.  Rewrite to support
19917         locale-specific notations like thousands separators.
19918         * lib/human.c: Simplify authorship notice.
19919         Include human.h immediately after config.h.
19920         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
19921         <limits.h>: Do not include, since human.h does.
19922         (SIZE_MAX, UINTMAX_MAX): New macros.
19923         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
19924         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
19925         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
19926         (power_letter): Renamed from suffixes.
19927         (generate_suffix_backwards): Remove.
19928         (adjust_value): Now takes int style (because of human.h changes)
19929         and long double value (for greater precision on some platforms).
19930         (group_number): New function.
19931         (human_readable): Use it.  Use integer options, not enum.
19932         Put the options before the sizes in the arg list.
19933         Support all the new options.
19934         The old human_readable function has been removed;
19935         use inttostr.h instead.
19936         (human_readable, default_block_size, humblock):
19937         Use uintmax_t, not int, for block sizes.
19938         (human_readable_inexact, block_size_types): Remove.
19939         (block_size_opts): New constant.
19940         (human_options): Renamed from human_block_size, with new signature
19941         that allows block sizes up to UINTMAX_MAX.  All callers changed.
19942         * lib/human.h: Add copyright and authorship notice.
19943         Include <limits.h> and <stdbool.h> unconditionally.
19944         (PARAMS): Remove.  All uses removed.
19945         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
19946         (enum human_inexact_style): Remove tag; now a nameless enum.
19947         (human_floor, human_ceiling, human_round_to_even): Now have
19948         values 2, 0, 1 rather than -1, 1, 0.
19949         (human_group_digits, human_suppress_point_zero, human_autoscale,
19950         human_base_1024, human_SI, human_B): New constants.
19951         (human_readable_inexact, human_block_size): Remove.
19952         (human_readable): Size args are now uintmax_t, not int.
19953         (human_options): New decl.
19954
19955         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
19956         unnecessary now that we assume C89 or better.  This change
19957         imported from coreutils.
19958
19959         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19960         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
19961         in the 2003-05-30 sync from glibc.
19962
19963         .h files should stand alone, but we shouldn't include <sys/types.h>
19964         if we can get away with just <stddef.h>.
19965
19966         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
19967         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
19968         rather than <sys/types.h>, as we merely need size_t.
19969         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
19970         to get size_t.
19971         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
19972         Include <stdio.h>, to get FILE.
19973         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
19974         memcasecmp.h has included <stddef.h> and all we need is size_t.
19975         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
19976         our interface, instead of including <sys/types.h>
19977
19978 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19979
19980         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
19981         now, as glibc mktime is buggy on non-glibc systems.
19982
19983 2003-06-03  Karl Berry  <karl@gnu.org>
19984
19985         * config/config.sub: update from prep.
19986
19987 2003-06-02  Paul Eggert  <eggert@twinsun.com>
19988
19989         [from coreutils]
19990         Fix some minor time-related bugs with POSIX time arguments.
19991         Some valid time stamps were being rejected (notably -1, and
19992         time stamps before 1900 on 64-bit hosts).  And some invalid
19993         time stamps were being accepted, e.g. September 31.
19994
19995         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
19996         that we can return (time_t) -1 successfully.
19997         * lib/posixtm.c: Likewise.
19998         [HAVE_STDBOOL_H]: Include <stdbool.h>.
19999         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
20000         (t): Remove static var.
20001         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
20002         of static var.  All uses changed.
20003         (year): Do not reject years before 1900; they can occur with
20004         64-bit time_t.
20005         (posix_time_parse): Do not check for out-of-range components;
20006         that is now the caller's responsibility, since our checks were
20007         only approximations.
20008         (posixtime): Use mktime to check for out-of-range components,
20009         since it knows them exactly.
20010         If mktime returns (time_t) -1, check whether an error actually occurred
20011         by invoking localtime on -1.
20012         (main) [TEST_POSIXTIME]: Check for input data errors, and report
20013         posixtime failures better.
20014         Improve the test data (in comments only).
20015
20016 2003-06-02  Karl Berry  <karl@gnu.org>
20017
20018         * config/mkinstalldirs (version): new variable.
20019         (--version): new option.
20020         (usage): improve message.
20021
20022 2003-05-30  Karl Berry  <karl@gnu.org>
20023
20024         * lib/mktime.c: update from libc.
20025
20026 2003-05-30  Bruno Haible  <bruno@clisp.org>
20027
20028         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
20029         * config/config.rpath: Upgrade to gettext-0.12.1.
20030
20031 2003-05-30  Bruno Haible  <bruno@clisp.org>
20032
20033         * m4/gettext.m4: Upgrade to gettext-0.12.1.
20034         * m4/nls.m4: New file, from gettext-0.12.1.
20035         * m4/po.m4: New file, from gettext-0.12.1.
20036         * m4/progtest.m4: Upgrade to gettext-0.12.1.
20037
20038 2003-05-30  Bruno Haible  <bruno@clisp.org>
20039
20040         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
20041         * lib/localcharset.h: Likewise.
20042         * lib/localcharset.c: Likewise.
20043
20044 2003-05-29  Karl Berry  <karl@gnu.org>
20045
20046         * config/config.rpath: update from gettext.
20047
20048 2003-05-28  Paul Eggert  <eggert@twinsun.com>
20049
20050         Assume the headers required for C89 freestanding compilers.
20051         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
20052         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
20053         * m4/human.m4 (gl_HUMAN): Likewise.
20054         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
20055         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
20056         * m4/userspec.m4 (gl_USERSPEC): Likewise.
20057         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
20058         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
20059         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
20060
20061 2003-05-28  Paul Eggert  <eggert@twinsun.com>
20062
20063         Assume the headers required for C89 freestanding compilers.
20064         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
20065         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
20066         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
20067         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
20068         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
20069         define, since <limits.h> is guaranteed to do that.
20070         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
20071         * lib/exclude.c: Include <stdbool.h> unconditionally.
20072         * lib/tempname.c: Include <stddef.h> unconditionally.
20073         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
20074         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
20075         <stddef.h> does that.
20076         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
20077         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
20078         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
20079         needed.
20080         * lib/xstrtol.c: Likewise.
20081         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
20082         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
20083
20084         * lib/addext.c (addext): Use assignment rather than cast, to avoid
20085         warnings on some platforms.
20086
20087         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
20088         arbitrarily.
20089
20090 2003-05-26  Jim Meyering  <jim@meyering.net>
20091
20092         Merge in a change from coreutils:
20093         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
20094         that is guaranteed to be `no'.  Use `no_such_member' to indicate
20095         that condition, rather than `-1' which is slightly misleading.
20096         Change the name of the cache variable to have the gl_ prefix.
20097         Prompted by a patch from Richard Dawe for DJGPP.
20098
20099 2003-05-24  Karl Berry  <karl@gnu.org>
20100
20101         * config/config.guess: update from prep.
20102
20103 2003-05-22  Karl Berry  <karl@gnu.org>
20104
20105         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
20106
20107 2003-05-20  Karl Berry  <karl@gnu.org>
20108
20109         * config/config.guess: update from prep.
20110
20111 2003-05-18  Karl Berry  <karl@gnu.org>
20112
20113         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
20114         might actually be set by the user.
20115
20116         * config/depcomp, install-sh, mdate-sh: update from automake.
20117
20118 2003-05-17  Bruno Haible  <bruno@clisp.org>
20119
20120         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
20121         invalid expansion for AC_EGREP_CPP.
20122         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
20123         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
20124         Suggested by Akim Demaille <akim@epita.fr> in
20125         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
20126
20127 2003-05-12  Jim Meyering  <jim@meyering.net>
20128
20129         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
20130         the space-padded-by-default conversion specifiers, %e, %k, %l.
20131
20132 2003-05-12  Bruno Haible  <bruno@clisp.org>
20133
20134         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
20135         the string is longer than 4 KB.
20136
20137 2003-05-11  Karl Berry  <karl@gnu.org>
20138
20139         * config/config.{guess,sub}: update from prep.
20140
20141 2003-05-09  Bruno Haible  <bruno@clisp.org>
20142
20143         * modules/error: Add m4/strerror_r.m4 to file list.
20144
20145 2003-05-03  Bruno Haible  <bruno@clisp.org>
20146
20147         Upgrade to Unicode-4.0.
20148         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
20149         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
20150         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
20151         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
20152         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
20153         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
20154         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
20155         Change width of U+E0100..U+E01EF from 1 to 0.
20156
20157 2003-04-25  Jim Meyering  <jim@meyering.net>
20158
20159         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
20160         of type size_t, not int.
20161
20162 2003-04-25  Bruno Haible  <bruno@clisp.org>
20163
20164         * lib/copy-file.c: Include <stddef.h>, for size_t.
20165
20166 2003-04-21  Paul Eggert  <eggert@twinsun.com>
20167
20168         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
20169         code which expansion is under static control.  Patch imported from
20170         Akim Demaille's patch to Bison; see
20171         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
20172
20173 2003-04-14  Bruno Haible  <bruno@clisp.org>
20174
20175         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
20176
20177 2003-04-11  Jim Meyering  <jim@meyering.net>
20178
20179         Merge changes from Coreutils.
20180
20181         2003-03-22  Jim Meyering  <jim@meyering.net>
20182
20183         * lib/strftime.c (widen): Cast alloca return value to proper type.
20184
20185         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
20186
20187         From GNU libc.
20188         * lib/strftime.c (my_strftime): Handle very large width
20189         specifications for numeric values correctly.  Improve checks for
20190         overflow.
20191
20192         2003-01-19  Jim Meyering  <jim@meyering.net>
20193
20194         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
20195         definitions.
20196         (nl_get_alt_digit) [! defined my_strftime]: Define.
20197         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
20198         _nl_get_alt_digit and _nl_get_walt_digit.
20199
20200         * lib/strftime.c (my_strftime): Merge in locale-related changes from
20201         libc. These changes have no effect outside of _LIBC.
20202
20203 2003-04-10  Bruno Haible  <bruno@clisp.org>
20204
20205         * modules/findprog: New file.
20206         * MODULES.html.sh (func_all_modules): Add it.
20207
20208 2003-04-10  Bruno Haible  <bruno@clisp.org>
20209
20210         * m4/findprog.m4: New file.
20211         * m4/eaccess.m4: New file.
20212
20213 2003-04-10  Bruno Haible  <bruno@clisp.org>
20214
20215         * lib/findprog.h: New file, from GNU gettext.
20216         * lib/findprog.c: New file, from GNU gettext.
20217
20218 2003-04-05  Jim Meyering  <jim@meyering.net>
20219
20220         Merge changes from Coreutils.
20221
20222         * lib/exclude.h (PARAMS): Remove definition and uses.
20223         * lib/exclude.c: Remove uses of `PARAMS'.
20224
20225         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
20226         Add test-cases for DOS filenames. Declare program_name.
20227         (main): Set up program_name.  Patch by Rich Dawe.
20228
20229         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
20230         error from mntctl.
20231         Use mntctl's return value to drive the entry-processing loop, since
20232         we can't rely on the value of the vmt_length member in the last
20233         entry.  On some systems doing so could result in exhausting
20234         virtual memory.  Based in part on a patch from Mike Jetzer.
20235
20236 2003-04-04  Bruno Haible  <bruno@clisp.org>
20237
20238         * modules/linebreak: New file.
20239         * MODULES.html.sh (func_all_modules): Add it.
20240
20241 2003-04-04  Bruno Haible  <bruno@clisp.org>
20242
20243         * m4/linebreak.m4: New file.
20244
20245 2003-04-04  Bruno Haible  <bruno@clisp.org>
20246
20247         * lib/linebreak.h: New file, from GNU gettext.
20248         * lib/linebreak.c: New file, from GNU gettext with slight
20249         modifications.
20250         * lib/lbrkprop.h: New file, from GNU gettext.
20251
20252 2003-04-03  Bruno Haible  <bruno@clisp.org>
20253
20254         * modules/utf8-ucs4: New file.
20255         * modules/utf16-ucs4: New file.
20256         * modules/ucs4-utf8: New file.
20257         * modules/ucs4-utf16: New file.
20258         * MODULES.html.sh (func_all_modules): Add them.
20259
20260 2003-04-03  Bruno Haible  <bruno@clisp.org>
20261
20262         * m4/utf-ucs4.m4: New file.
20263         * m4/ucs4-utf.m4: New file.
20264
20265 2003-04-03  Bruno Haible  <bruno@clisp.org>
20266
20267         * lib/utf8-ucs4.h: New file, from GNU gettext.
20268         * lib/utf16-ucs4.h: New file, from GNU gettext.
20269         * lib/ucs4-utf8.h: New file, from GNU gettext.
20270         * lib/ucs4-utf16.h: New file, from GNU gettext.
20271
20272 2003-04-02  Bruno Haible  <bruno@clisp.org>
20273
20274         * modules/binary-io: New file.
20275         * MODULES.html.sh (func_all_modules): Add it.
20276
20277 2003-04-02  Bruno Haible  <bruno@clisp.org>
20278
20279         * lib/binary-io.h: New file, from GNU gettext.
20280
20281 2003-04-01  Bruno Haible  <bruno@clisp.org>
20282
20283         * modules/pathname: New file.
20284         * MODULES.html.sh (func_all_modules): Add it.
20285
20286 2003-04-01  Bruno Haible  <bruno@clisp.org>
20287
20288         * lib/pathname.h: New file, from GNU gettext.
20289         * lib/concatpath.c: New file, from GNU gettext.
20290
20291 2003-03-30  Bruno Haible  <bruno@clisp.org>
20292
20293         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
20294
20295 2003-03-30  Bruno Haible  <bruno@clisp.org>
20296
20297         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
20298         function chown() doesn't exist.
20299
20300 2003-03-28  Bruno Haible  <bruno@clisp.org>
20301
20302         * modules/copy-file: New file.
20303         * MODULES.html.sh (func_all_modules): Add it.
20304
20305 2003-03-28  Bruno Haible  <bruno@clisp.org>
20306
20307         * m4/copy-file.m4: New file.
20308
20309 2003-03-28  Bruno Haible  <bruno@clisp.org>
20310
20311         * lib/copy-file.h: New file, from GNU gettext.
20312         * lib/copy-file.c: New file, from GNU gettext.
20313
20314 2003-03-18  Jim Meyering  <jim@meyering.net>
20315
20316         * lib/quote.c (quote_n): Fix typo in comment.
20317
20318 2003-03-18  Bruno Haible  <bruno@clisp.org>
20319
20320         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
20321         checking.
20322         * m4/onceonly_2_57.m4: Likewise.
20323
20324 2003-03-17  Bruno Haible  <bruno@clisp.org>
20325
20326         * m4/onceonly.m4: Require autoconf 2.54 or newer.
20327         (m4_quote): Remove macro.
20328         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
20329
20330 2003-03-14  Jim Meyering  <jim@meyering.net>
20331
20332         Merge changes from Coreutils.
20333         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
20334         to be const, in order to avoid warnings.
20335         (obstack_room): Likewise.
20336         (obstack_empty_p): Likewise.
20337
20338 2003-03-14  Bruno Haible  <bruno@clisp.org>
20339
20340         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
20341         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
20342
20343 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20344
20345         Merge changes from Bison.
20346         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
20347         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
20348         when compiling Bison 1.875's `bitset bset = obstack_alloc
20349         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
20350         * lib/hash.c: Include <stdbool.h> unconditionally.
20351
20352 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20353
20354         * m4/onceonly.m4 (m4_quote): New macro.
20355         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
20356         Quote AC_FOREACH variable-expansions properly.
20357
20358 2003-03-13  Paul Eggert  <eggert@twinsun.com>
20359
20360         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
20361
20362 2003-03-09  Paul Eggert  <eggert@twinsun.com>
20363
20364         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
20365         Reported by Bruce Becker; see:
20366         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
20367
20368 2003-03-03  Paul Eggert  <eggert@twinsun.com>
20369             Bruno Haible  <bruno@clisp.org>
20370
20371         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
20372         Reported by John Hughes, see
20373         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
20374
20375 2003-02-20  Bruno Haible  <bruno@clisp.org>
20376
20377         * MODULES.html.sh (func_all_modules): Add poll.
20378
20379 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20380
20381         * modules/poll: New file.
20382
20383 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20384
20385         * lib/poll_.h: New file.
20386         * lib/poll.c: New file.
20387
20388 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
20389
20390         * m4/poll.m4: New file.
20391
20392 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20393
20394         * modules/mathl: New file.
20395
20396 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20397
20398         * lib/mathl.h: New file.
20399         * lib/acosl.c: New file.
20400         * lib/asinl.c: New file.
20401         * lib/atanl.c: New file.
20402         * lib/ceill.c: New file.
20403         * lib/cosl.c: New file.
20404         * lib/expl.c: New file.
20405         * lib/floorl.c: New file.
20406         * lib/frexpl.c: New file.
20407         * lib/ldexpl.c: New file.
20408         * lib/logl.c: New file.
20409         * lib/sincosl.c: New file.
20410         * lib/sinl.c: New file.
20411         * lib/sqrtl.c: New file.
20412         * lib/tanl.c: New file.
20413         * lib/trigl.c: New file.
20414         * lib/trigl.h: New file.
20415
20416 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
20417
20418         * m4/mathl.m4: New file.
20419
20420 2003-02-18  Bruno Haible  <bruno@clisp.org>
20421
20422         * MODULES.html.sh (func_all_modules): Add mathl.
20423
20424 2003-02-17  Bruno Haible  <bruno@clisp.org>
20425
20426         * modules/mkdtemp: New module.
20427         * MODULES.html.sh (func_all_modules): Add it.
20428
20429 2003-02-17  Bruno Haible  <bruno@clisp.org>
20430
20431         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
20432
20433 2003-02-17  Bruno Haible  <bruno@clisp.org>
20434
20435         * lib/mkdtemp.h: New file, from GNU gettext.
20436         * lib/mkdtemp.c: New file, from GNU gettext.
20437
20438 2003-02-02  Jim Meyering  <jim@meyering.net>
20439
20440         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
20441         e.g. glibc-2.2.93.
20442
20443 2003-01-31  Bruno Haible  <bruno@clisp.org>
20444
20445         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
20446         'rpl_rename'.
20447         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
20448         'rpl_strnlen'.
20449         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
20450         'rpl_strtod'.
20451         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
20452         'rpl_utime'.
20453
20454 2003-01-31  Bruno Haible  <bruno@clisp.org>
20455
20456         * lib/rename.c: #undef rename before defining rpl_rename.
20457         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
20458
20459 2003-01-30  Bruno Haible  <bruno@clisp.org>
20460
20461         * modules/vasnprintf, modules/vasprintf: New modules.
20462         * MODULES.html.sh (func_all_modules): Add them.
20463
20464 2003-01-30  Bruno Haible  <bruno@clisp.org>
20465
20466         * m4/signed.m4: New file, from GNU gettext.
20467         * m4/longdouble.m4: New file, from GNU gettext.
20468         * m4/wchar_t.m4: New file, from GNU gettext.
20469         * m4/wint_t.m4: New file, from GNU gettext.
20470         * m4/vasnprintf.m4: New file.
20471         * m4/vasprintf.m4: New file.
20472
20473 2003-01-30  Bruno Haible  <bruno@clisp.org>
20474
20475         * lib/printf-args.h: New file, from GNU gettext.
20476         * lib/printf-args.c: New file, from GNU gettext.
20477         * lib/printf-parse.h: New file, from GNU gettext.
20478         * lib/printf-parse.c: New file, from GNU gettext.
20479         * lib/vasnprintf.h: New file, from GNU gettext.
20480         * lib/vasnprintf.c: New file, from GNU gettext.
20481         * lib/asnprintf.c: New file, from GNU gettext.
20482         * lib/vasprintf.h: New file, from GNU gettext with modifications.
20483         * lib/vasprintf.c: New file, from GNU gettext.
20484         * lib/asprintf.c: New file, from GNU gettext.
20485
20486 2003-01-29  Bruno Haible  <bruno@clisp.org>
20487
20488         * modules/stpncpy: New module.
20489         * MODULES.html.sh (func_all_modules): Add it.
20490
20491 2003-01-29  Bruno Haible  <bruno@clisp.org>
20492
20493         * m4/stpncpy.m4: New file.
20494
20495 2003-01-29  Bruno Haible  <bruno@clisp.org>
20496
20497         * lib/stpncpy.h: New file, from GNU gettext with modifications.
20498         * lib/stpncpy.c: New file, from GNU gettext with modifications.
20499
20500 2003-01-28  Bruno Haible  <bruno@clisp.org>
20501
20502         * modules/c-ctype: New module.
20503         * MODULES.html.sh (func_all_modules): Add it.
20504
20505 2003-01-28  Bruno Haible  <bruno@clisp.org>
20506
20507         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
20508         Paul Eggert.
20509         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
20510         Paul Eggert.
20511
20512 2003-01-27  Bruno Haible  <bruno@clisp.org>
20513
20514         * modules/xsetenv: New module.
20515         * MODULES.html.sh (func_all_modules): Add it.
20516
20517 2003-01-27  Bruno Haible  <bruno@clisp.org>
20518
20519         * lib/xsetenv.h: New file, from GNU gettext.
20520         * lib/xsetenv.c: New file, from GNU gettext.
20521
20522 2003-01-23  Jim Meyering  <jim@meyering.net>
20523
20524         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
20525         from working on systems without dirfd (at least Irix and OSF1/Tru64).
20526
20527 2003-01-23  Bruno Haible  <bruno@clisp.org>
20528
20529         * modules/minmax: New module.
20530         * MODULES.html.sh (func_all_modules): Add it.
20531
20532 2003-01-23  Bruno Haible  <bruno@clisp.org>
20533
20534         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
20535         Eggert.
20536
20537 2003-01-22  Bruno Haible  <bruno@clisp.org>
20538
20539         * modules/exit: New module.
20540         * MODULES.html.sh (func_all_modules): Add it.
20541
20542 2003-01-22  Bruno Haible  <bruno@clisp.org>
20543
20544         * lib/exit.h: New file, from GNU gettext.
20545
20546 2003-01-19  Bruno Haible  <bruno@clisp.org>
20547
20548         * gnulib-tool: Recognize option --extract-maintainer.
20549         (func_get_maintainer): New function.
20550         * modules/*: Add Maintainer entry.
20551
20552 2003-01-16  Jim Meyering  <jim@meyering.net>
20553
20554         * m4/regex.m4: The `regex' struct is both input and output.
20555         Initialize it before each use.  Patch by Tim Waugh.
20556
20557 2003-01-16  Bruno Haible  <bruno@clisp.org>
20558
20559         * MODULES.html.sh: Add a table of contents. Add the module name as
20560         leftmost column. Add hyperlinks.
20561
20562 2003-01-15  Bruno Haible  <bruno@clisp.org>
20563
20564         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
20565
20566 2003-01-15  Bruno Haible  <bruno@clisp.org>
20567
20568         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
20569         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
20570         suffix.
20571
20572 2003-01-15  Bruno Haible  <bruno@clisp.org>
20573
20574         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
20575
20576 2003-01-15  Bruno Haible  <bruno@clisp.org>
20577
20578         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
20579         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
20580
20581 2003-01-14  Jim Meyering  <jim@meyering.net>
20582
20583         * lib/same.c (same_name): Tweak a comment.
20584
20585 2003-01-14  Bruno Haible  <bruno@clisp.org>
20586
20587         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
20588         when a string comparison is sufficient.
20589
20590 2003-01-14  Bruno Haible  <bruno@clisp.org>
20591
20592         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
20593         'unsigned int'.
20594
20595 2003-01-14  Bruno Haible  <bruno@clisp.org>
20596
20597         * lib/hash-pjw.c: Add comment about low quality of this function.
20598
20599 2003-01-13  Bruno Haible  <bruno@clisp.org>
20600
20601         * modules/stpcpy: Distribute lib/stpcpy.h.
20602         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
20603
20604 2003-01-13  Bruno Haible  <bruno@clisp.org>
20605
20606         * modules/*: Add a description.
20607         * modules/strpbrk: Fix Makefile.am snippet.
20608         * modules/strtoimax: Fix dependencies.
20609         * modules/strtoumax: Likewise.
20610
20611 2003-01-13  Bruno Haible  <bruno@clisp.org>
20612
20613         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
20614         * modules/alloca (Makefile.am): All object files depend on alloca.h.
20615         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
20616
20617 2003-01-13  Bruno Haible  <bruno@clisp.org>
20618
20619         * gnulib-tool (func_create_testdir): Store config/* files in the main
20620         directory.
20621         * config.rpath: Move to ...
20622         * config/config.rpath: ... here.
20623         * modules/gettext: Contains config/config.rpath, not config.rpath.
20624         * modules/iconv: Likewise.
20625
20626 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20627
20628         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20629         to avoid collisions with libcurses and libreadline.
20630
20631         * m4/getstr.m4: Remove.
20632         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
20633
20634 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20635
20636         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20637         to avoid collisions with libcurses and libreadline.
20638
20639         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
20640         * lib/getstr.h, getstr.c: Remove.
20641         * lib/getline.c: Include "getline.h", to check interface.
20642         Move body of old getstr.c here: this defines MIN_CHUNK and
20643         declares getdelim2, which is renamed from getstr.
20644         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
20645
20646         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
20647         All uses changed.
20648         * lib/linebuffer.h: Likewise.
20649         (readline): Remove backward-compatibility macro.
20650
20651 2003-01-12  Paul Eggert  <eggert@twinsun.com>
20652
20653         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
20654         to avoid collisions with libcurses and libreadline.
20655         * getstr: Remove.
20656         * MODULES.html.sh: Remove getstr.
20657         * modules/getline: Depend on unlocked-io, not getstr.
20658
20659 2003-01-12  Jim Meyering  <jim@meyering.net>
20660
20661         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
20662
20663 2003-01-10  Bruno Haible  <bruno@clisp.org>
20664
20665         * modules/alloca: Change Makefile.am requirements. Simplify Include
20666         requirements. Add lib/alloca_.h to file list.
20667
20668 2003-01-10  Bruno Haible  <bruno@clisp.org>
20669
20670         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
20671
20672 2003-01-10  Bruno Haible  <bruno@clisp.org>
20673
20674         * lib/alloca_.h: New file.
20675         * lib/getdate.y: Unconditionally include alloca.h.
20676         * lib/makepath.c: Likewise.
20677         * lib/setenv.c: Likewise.
20678         * lib/userspec.c: Likewise.
20679
20680 2003-01-09  Karl Berry  <karl@gnu.org>
20681
20682         * MODULES.html.sh: include `dirname $0` in PATH, to find
20683         gnulib-tool.
20684
20685 2003-01-09  Bruno Haible  <bruno@clisp.org>
20686
20687         * modules/stdbool: Change configure.ac, Makefile.am requirements.
20688         Simplify Include requirements. Add lib/stdbool.h.in to file list.
20689
20690 2003-01-09  Bruno Haible  <bruno@clisp.org>
20691
20692         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
20693
20694 2003-01-09  Bruno Haible  <bruno@clisp.org>
20695
20696         * lib/stdbool.h.in: New file.
20697
20698 2003-01-09  Bruno Haible  <bruno@clisp.org>
20699
20700         * gnulib-tool (func_all_modules): Ignore files ending in ~.
20701         * MODULES.html.sh: Likewise.
20702
20703 2003-01-08  Jim Meyering  <jim@meyering.net>
20704
20705         * lib/full-write.c: Undefine and define-away `const' after inclusion
20706         of errno.h, not before.  Suggestion from Bruno Haible.
20707
20708 2003-01-08  Bruno Haible  <bruno@clisp.org>
20709
20710         * modules/full-read: Depend on full-write.
20711
20712 2003-01-08  Bruno Haible  <bruno@clisp.org>
20713
20714         * lib/safe-read.c: Include specification header first, to ensure its
20715         selfcontainedness.
20716         * lib/full-write.c: Likewise.
20717
20718 2003-01-07  Jim Meyering  <jim@meyering.net>
20719
20720         * lib/full-write.c: Rework so that it may serve to define full_read,
20721         too.
20722         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
20723
20724 2003-01-07  Bruno Haible  <bruno@clisp.org>
20725
20726         * lib/strtoimax.c: Include <stdint.h> as an alternative to
20727         <inttypes.h>.
20728         * lib/xstrtol.h: Likewise.
20729         * lib/xstrtoimax.c: Likewise.
20730         * lib/xstrtoumax.c: Likewise.
20731         * lib/human.h: Likewise.
20732
20733         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
20734         on systems that have <inttypes.h> but not <stdint.h>.
20735
20736 2003-01-07  Bruno Haible  <bruno@clisp.org>
20737
20738         * MODULES.html.sh: Add copyright notice.
20739         (missed_files): Omit CVS directory entries.
20740         (func_module): Make it work with sed-3.02.
20741         * MODULES.txt: Remove file.
20742
20743 2003-01-06  Jim Meyering  <jim@meyering.net>
20744
20745         * lib/version-etc.c: Update year in translatable copyright string.
20746
20747 2003-01-03  Karl Berry  <karl@gnu.org>
20748
20749         * config/config.{guess,sub}: update from prep.
20750
20751 2003-01-02  Karl Berry  <karl@gnu.org>
20752
20753         * doc/COPYING.DOC: belatedly updated to 1.2.
20754
20755 2003-01-01  Karl Berry  <karl@gnu.org>
20756
20757         * gnulib-tool (func_verify_module): report module name $module in
20758         error message, not $1.
20759         * gnulib-tool (create-testdir): don't complain if destdir couldn't
20760         be created, only if it doesn't exist.
20761         * gnulib-tool (last_checkin_date): don't expand the $Date here.
20762
20763 2002-12-31  Paul Eggert  <eggert@twinsun.com>
20764
20765         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
20766
20767 2002-12-31  Paul Eggert  <eggert@twinsun.com>
20768
20769         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
20770         memcmp if strcoll doesn't work.
20771
20772 2002-12-31  Bruno Haible  <bruno@clisp.org>
20773
20774         * lib/utime.c (utime_null): No need to call ftruncate if the file was
20775         nonempty.
20776
20777 2002-12-31  Bruno Haible  <bruno@clisp.org>
20778
20779         * lib/memcoll.c (STRCOLL): New macro.
20780         (memcoll): Use it.
20781
20782 2002-12-31  Bruno Haible  <bruno@clisp.org>
20783
20784         * lib/localcharset.h: New file.
20785         * lib/localcharset.c: Include it.
20786         * lib/unicodeio.c: Likewise.
20787
20788 2002-12-31  Bruno Haible  <bruno@clisp.org>
20789
20790         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
20791         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
20792
20793 2002-12-31  Bruno Haible  <bruno@clisp.org>
20794
20795         * lib/getline.h: Include <stddef.h>, for size_t.
20796
20797         * lib/unicodeio.h: Include <stddef.h>, for size_t.
20798         * lib/unicodeio.c: Don't include <stddef.h>.
20799
20800 2002-12-31  Bruno Haible  <bruno@clisp.org>
20801
20802         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
20803         HAVE_TM_ZONE.
20804
20805 2002-12-24  Karl Berry  <karl@gnu.org>
20806
20807         * config/config.guess: update from prep.
20808
20809 2002-12-24  Bruno Haible  <bruno@clisp.org>
20810
20811         General infrasructure.
20812         * m4/README: Rewritten.
20813         * m4/onceonly.m4: New file.
20814         * m4/onceonly_2_57.m4: New file.
20815
20816         Module atexit.
20817         * m4/atexit.m4: New file.
20818
20819         Module strtod.
20820         * m4/strtod.m4: New file.
20821
20822         Module strtol.
20823         * m4/strtol.m4: New file.
20824
20825         Module strtoul.
20826         * m4/strtoul.m4: New file.
20827
20828         Module memchr.
20829         * m4/memchr.m4: New file.
20830
20831         Module memcmp.
20832         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
20833         (jm_FUNC_MEMCMP): Invoke it.
20834
20835         Module memcpy.
20836         * m4/memcpy.m4: New file.
20837
20838         Module memmove.
20839         * m4/memmove.m4: New file.
20840
20841         Module memset.
20842         * m4/memset.m4: New file.
20843
20844         Module strcspn.
20845         * m4/strcspn.m4: New file.
20846
20847         Module strpbrk.
20848         * m4/strpbrk.m4: New file.
20849
20850         Module strstr.
20851         * m4/strstr.m4: New file.
20852
20853         Module strerror.
20854         * m4/strerror.m4: New file.
20855
20856         Module mktime.
20857         * m4/mktime.m4: Renamed from jm-mktime.m4.
20858         (gl_PREREQ_MKTIME): New macro.
20859         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
20860
20861         Module malloc.
20862         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
20863         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
20864         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
20865
20866         Module realloc.
20867         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
20868         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
20869         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
20870
20871         Module strftime.
20872         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
20873         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
20874         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
20875         gl_TM_GMTOFF.
20876         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
20877
20878         Module xalloc.
20879         * m4/xalloc.m4: New file.
20880
20881         Module alloca.
20882         * m4/alloca.m4: New file.
20883
20884         Module putenv.
20885         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
20886         (jm_FUNC_PUTENV): Invoke it.
20887
20888         Module setenv.
20889         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
20890         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
20891         when invoked twice.
20892         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
20893         gt_FUNC_SETENV.
20894
20895         Module memrchr.
20896         * m4/memrchr.m4: New file.
20897
20898         Module stpcpy.
20899         * m4/stpcpy.m4: New file.
20900
20901         Module strcase.
20902         * m4/strcase.m4: New file.
20903
20904         Module strdup.
20905         * m4/strdup.m4: New file.
20906
20907         Module strnlen.
20908         * m4/strnlen.m4: New file.
20909
20910         Module strndup.
20911         * m4/strndup.m4: New file.
20912
20913         Module xstrtod.
20914         * m4/xstrtod.m4: New file.
20915
20916         Module xstrtol.
20917         * m4/xstrtol.m4: New file.
20918
20919         Module getdate.
20920         * m4/getdate.m4: New file.
20921
20922         Module unlocked-io.
20923         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
20924         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
20925         * m4/jm-glibc-io.m4n: Remove file.
20926
20927         Module long-options.
20928         * m4/long-options.m4: New file.
20929
20930         Module md5.
20931         * m4/md5.m4: New file.
20932
20933         Module sha.
20934         * m4/sha.m4: New file.
20935
20936         Module getstr.
20937         * m4/getstr.m4: New file.
20938
20939         Module getline.
20940         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
20941         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
20942         <sys/types.h>, for size_t. Use the function name gnu_getline, not
20943         simply getline. Infoke gl_PREREQ_GETLINE.
20944
20945         Module obstack.
20946         * m4/obstack.m4: New file.
20947
20948         Module hash.
20949         * m4/hash.m4: New file.
20950
20951         Module readtokens.
20952         * m4/readtokens.m4: New file.
20953
20954         Module strverscmp.
20955         * m4/strverscmp.m4: New file.
20956
20957         Module stdbool.
20958         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
20959         OSF/1.
20960
20961         Module strtoll.
20962         * m4/strtoll.m4: New file.
20963
20964         Module strtoull.
20965         * m4/strtoull.m4: New file.
20966
20967         Module strtoimax.
20968         * m4/strtoimax.m4: New file.
20969
20970         Module strtoumax.
20971         * m4/strtoumax.m4: New file.
20972
20973         Module xstrtoimax.
20974         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
20975         jm_AC_PREREQ_XSTRTOIMAX.
20976         Moved the strtol prerequisites to strtol.m4.
20977         Moved the strtoll prerequisites to strtoll.m4.
20978         Moved the strtoimax prerequisites to strtoimax.m4.
20979
20980         Module xstrtoumax.
20981         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
20982         jm_AC_PREREQ_XSTRTOUMAX.
20983         Moved the strtoul prerequisites to strtoul.m4.
20984         Moved the strtoull prerequisites to strtoull.m4.
20985         Moved the strtoumax prerequisites to strtoumax.m4.
20986
20987         Module chown.
20988         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
20989         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
20990
20991         Module dup2.
20992         * m4/dup2.m4: New file.
20993
20994         Module ftruncate.
20995         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
20996         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
20997
20998         Module getgroups.
20999         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
21000         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
21001
21002         Module gettimeofday.
21003         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
21004         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
21005         gl_PREREQ_GETTIMEOFDAY.
21006
21007         Module mkdir.
21008         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
21009         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
21010
21011         Module mkstemp.
21012         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
21013         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
21014         jm_AC_TYPE_UINTMAX_T.
21015         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
21016
21017         Module stat.
21018         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
21019         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
21020
21021         Module lstat.
21022         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
21023         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
21024
21025         Module timespec.
21026         * m4/timespec.m4 (gl_TIMESPEC): New macro.
21027         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
21028         * m4/st_mtim.m4: Indentation.
21029
21030         Module nanosleep.
21031         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
21032         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
21033         gl_PREREQ_NANOSLEEP.
21034
21035         Module regex.
21036         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
21037         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
21038         (gl_REGEX): New macro.
21039
21040         Module rename.
21041         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
21042         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
21043
21044         Module rmdir.
21045         * m4/rmdir.m4: New file.
21046
21047         Module utime.
21048         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
21049         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
21050         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
21051
21052         Module dirname.
21053         * m4/dirname.m4: New file.
21054
21055         Module getopt.
21056         * m4/getopt.m4: New file.
21057
21058         Module unistd-safer.
21059         * m4/unistd-safer.m4: New file.
21060
21061         Module fnmatch.
21062         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
21063         declaration.
21064         (gl_PREREQ_FNMATCH_EXTRA): New macro.
21065         (gl_FUNC_FNMATCH_POSIX): New macro.
21066         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
21067         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
21068         simply fnmatch.
21069
21070         Module exclude.
21071         * m4/exclude.m4: New file.
21072
21073         Module human.
21074         * m4/human.m4: New file.
21075
21076         Module acl.
21077         * m4/acl.m4: Nop.
21078
21079         Module backupfile.
21080         * m4/backupfile.m4: New file.
21081         * m4/d-ino.m4: Indentation.
21082
21083         Module fsusage.
21084         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
21085         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
21086         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
21087
21088         Module dirfd.
21089         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
21090         requirements.
21091
21092         Module euidaccess.
21093         * m4/euidaccess.m4: New file.
21094
21095         Module file-type.
21096         * m4/file-type.m4: New file.
21097
21098         Module fileblocks.
21099         * m4/fileblocks.m4: New file.
21100
21101         Module filemode.
21102         * m4/filemode.m4: New file.
21103
21104         Module isdir.
21105         * m4/isdir.m4: New file.
21106
21107         Module lchown.
21108         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
21109         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
21110
21111         Module makepath.
21112         * m4/makepath.m4: New file.
21113
21114         Module modechange.
21115         * m4/modechange.m4: New file.
21116
21117         Module mountlist.
21118         * m4/mountlist.m4: New file.
21119         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
21120         Indentation.
21121
21122         Module path-concat.
21123         * m4/path-concat.m4: New file.
21124
21125         Module pathmax.
21126         * m4/pathmax.m4: New file.
21127
21128         Module same.
21129         * m4/same.m4: New file.
21130
21131         Module save-cwd.
21132         * m4/save-cwd.m4: New file.
21133
21134         Module savedir.
21135         * m4/savedir.m4: New file.
21136
21137         Module xgetcwd.
21138         * m4/xgetcwd.m4: New file.
21139         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
21140
21141         Module xreadlink.
21142         * m4/xreadlink.m4: New file.
21143
21144         Module safe-read.
21145         * m4/safe-read.m4: New file.
21146
21147         Module safe-write.
21148         * m4/safe-write.m4: New file.
21149
21150         Module closeout.
21151         * m4/closeout.m4: New file.
21152
21153         Module stdio-safer.
21154         * m4/stdio-safer.m4: New file.
21155
21156         Module getpass.
21157         * m4/getpass.m4: New file.
21158
21159         Module getugroups.
21160         * m4/getugroups.m4: New file.
21161
21162         Module group-member.
21163         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
21164         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
21165
21166         Module idcache.
21167         * m4/idcache.m4: New file.
21168
21169         Module userspec.
21170         * m4/userspec.m4: New file.
21171
21172         Module gettime.
21173         * m4/clock_time.m4: New file.
21174         * m4/gettime.m4: New file.
21175
21176         Module settime.
21177         * m4/settime.m4: New file.
21178
21179         Module posixtm.
21180         * m4/posixtm.m4: New file.
21181
21182         Module gethostname.
21183         * m4/gethostname.m4: New file.
21184
21185         Module canon-host.
21186         * m4/canon-host.m4: New file.
21187
21188         Module gettext.
21189         * m4/codeset.m4: New file, from gettext-0.11.5.
21190         * m4/gettext.m4: New file, from gettext-0.11.5.
21191         * m4/glibc21.m4: New file, from gettext-0.11.5.
21192         * m4/iconv.m4: New file, from gettext-0.11.5.
21193         * m4/intdiv0.m4: New file, from gettext-0.11.5.
21194         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
21195         * m4/inttypes.m4: New file, from gettext-0.11.5.
21196         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
21197         * m4/isc-posix.m4: New file, from gettext-0.11.5.
21198         * m4/lcmessage.m4: New file, from gettext-0.11.5.
21199         * m4/lib-ld.m4: New file, from gettext-0.11.5.
21200         * m4/lib-link.m4: New file, from gettext-0.11.5.
21201         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
21202         * m4/progtest.m4: New file, from gettext-0.11.5.
21203         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
21204         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
21205         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
21206
21207         Module localcharset.
21208         * m4/localcharset.m4: New file.
21209
21210         Module hard-locale.
21211         * m4/hard-locale.m4: New file.
21212
21213         Module mbswidth.
21214         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
21215         onceonly macros.
21216         * m4/mbrtowc.m4: Add comment.
21217
21218         Module memcasecmp.
21219         * m4/memcasecmp.m4: New file.
21220
21221         Module memcoll.
21222         * m4/memcoll.m4: New file.
21223
21224         Module unicodeio.
21225         * m4/unicodeio.m4: New file.
21226
21227         Module rpmatch.
21228         * m4/rpmatch.m4: New file.
21229
21230         Module yesno.
21231         * m4/yesno.m4: New file.
21232
21233         Module exitfail.
21234         * m4/exitfail.m4: New file.
21235
21236         Module c-stack.
21237         * m4/c-stack.m4 (gl_C_STACK): New macro.
21238         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
21239
21240         Module error.
21241         * m4/error.m4 (gl_ERROR): New macro.
21242         (jm_PREREQ_ERROR): Use onceonly macros.
21243
21244         Module fatal.
21245         * m4/fatal.m4: New file.
21246
21247         Module getloadavg.
21248         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
21249         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
21250
21251         Module getpagesize.
21252         * m4/getpagesize.m4: New file.
21253
21254         Module getusershell.
21255         * m4/getusershell.m4: New file.
21256
21257         Module physmem.
21258         * m4/physmem.m4: New file.
21259
21260         Module posixver.
21261         * m4/posixver.m4: New file.
21262
21263         Module quotearg.
21264         * m4/quotearg.m4: New file.
21265
21266         Module quote.
21267         * m4/quote.m4: New file.
21268
21269         Module readutmp.
21270         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
21271
21272         Module sig2str.
21273         * m4/sig2str.m4: New file.
21274
21275         Other.
21276         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
21277         ulonglong.m4.
21278         * m4/intmax_t.m4: New file.
21279         * m4/d-type.m4: Indentation.
21280         * m4/jm-macros.m4: Update.
21281         * m4/prereq.m4 (jm_PREREQ): Update.
21282         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
21283         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
21284         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
21285         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
21286         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
21287         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
21288         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
21289         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
21290         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
21291         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
21292         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
21293         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
21294         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
21295         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
21296         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
21297         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
21298         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
21299         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
21300         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
21301
21302 2002-12-24  Bruno Haible  <bruno@clisp.org>
21303
21304         * MODULES.txt: Update according to m4/ changes.
21305
21306         Module gettext.
21307         * config.rpath: New file, from gettext-0.11.5.
21308
21309         * modules/*: New module descriptions.
21310         * gnulib-tool: New file.
21311         * MODULES.html.sh: New file.
21312
21313 2002-12-21  Karl Berry  <karl@gnu.org>
21314
21315         * doc/fdl.texi: update to version 1.2.
21316
21317 2002-12-19  Karl Berry  <karl@gnu.org>
21318
21319         * config/config.guess: update from prep.
21320
21321 2002-12-18  Bruno Haible  <bruno@clisp.org>
21322
21323         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
21324         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
21325
21326 2002-12-17  Bruno Haible  <bruno@clisp.org>
21327
21328         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
21329         stdlib.h, string.h.
21330
21331 2002-12-17  Bruno Haible  <bruno@clisp.org>
21332
21333         * lib/canon-host.c (strdup): Remove unused declaration.
21334
21335         * lib/fsusage.c: Include full_read.h.
21336         (get_fs_usage): Use full_read instead of safe_read.
21337
21338         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
21339
21340 2002-12-12  Karl Berry  <karl@gnu.org>
21341
21342         * config/config.guess: update from prep.
21343
21344 2002-12-11  Bruno Haible  <bruno@clisp.org>
21345
21346         * m4/setenv.m4: New file, from gettext-0.11.5.
21347
21348 2002-12-11  Bruno Haible  <bruno@clisp.org>
21349
21350         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
21351         not unsetenv().
21352         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
21353         modifications:
21354
21355         2002-12-11  Bruno Haible  <bruno@clisp.org>
21356
21357                 * setenv.c (alloca): Fall back to malloc.
21358                 (freea): New macro.
21359                 (setenv): Use freea() to free memory allocated with alloca().
21360
21361         2002-11-13  Bruno Haible  <bruno@clisp.org>
21362
21363                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
21364                 function declarations.
21365                 * unsetenv.c (unsetenv): Likewise.
21366
21367         2002-03-04  Bruno Haible  <bruno@clisp.org>
21368
21369                 Portability to AIX 4.3.3.
21370                 * unsetenv.c: New file, extracted from setenv.c.
21371                 * setenv.c: Move the unsetenv() function to unsetenv.c.
21372
21373         2001-12-20  Bruno Haible  <bruno@clisp.org>
21374
21375                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
21376                 use malloc instead. For SunOS 4.
21377
21378         2001-12-11  Bruno Haible  <bruno@clisp.org>
21379
21380                 * setenv.c: Declare alloca.
21381                 (compar_fn_t): New typedef.
21382                 (KNOWN_VALUE, STORE_VALUE): Use it.
21383
21384         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
21385         setenv.h.
21386
21387 2002-12-10  Paul Eggert  <eggert@twinsun.com>
21388
21389         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
21390         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
21391         Choose values that are less likely to collide with system fnmatch
21392         options.
21393         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
21394         defined (e.g., a pure POSIX system).
21395         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
21396         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
21397
21398 2002-12-06  Paul Eggert  <eggert@twinsun.com>
21399
21400         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
21401         a pain in practice to deal with generated m4 files.  This change
21402         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
21403
21404         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
21405         and jm-glibc-io.m4, as they are no longer a special case.
21406         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
21407         kludge and the auto-generation stuff.  Check only whether the
21408         functions are declared, not whether they exist, since older hosts
21409         that don't declare the functions can't use the optimization anyway.
21410
21411 2002-12-06  Jim Meyering  <jim@meyering.net>
21412
21413         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
21414
21415         Merge in changes from libc's misc/error.c, in preparation
21416         for the merge of gnulib's changes back into libc.
21417
21418         * lib/error.c (_): Define only if not already defined.
21419         Move definition to follow all #include directives.
21420         Include unlocked-io.h only if !_LIBC.
21421         [_LIBC]: Include <libio/libioP.h>.
21422         [USE_IN_LIBIO]: Include <libio/iolibio.h>
21423         (fflush): Tweak definition to use INTUSE.
21424         (putc): Define.
21425
21426 2002-12-05  Paul Eggert  <eggert@twinsun.com>
21427
21428         * lib/alloca.c [defined emacs]: Include "lisp.h".
21429         (xalloc_die) [defined emacs]: New macro.
21430         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
21431         [! defined emacs]: Include <xalloc.h>.
21432         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
21433         (pointer): Typedef to POINTER_TYPE *.
21434         (malloc): Remove decl; we now always use xmalloc.
21435         (alloca): Use old-style definition, since Emacs needs this.
21436         Check for arithmetic overflow when computing combined size.
21437
21438 2002-12-04  Paul Eggert  <eggert@twinsun.com>
21439
21440         Do not generate unlocked-io.h automatically, since it's easier to
21441         maintain it by hand.
21442
21443         * lib/unlocked-io.h: New file, from GNU diffutils,
21444         but with proper copyright notice and attribution.
21445         * lib/gen-uio: Remove.
21446         * lib/Makefile.am: Add copyright notice.
21447         (libfetish_a_SOURCES): Add unlocked-io.h.
21448         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
21449         (DISTCLEANFILES, io_functions): Remove macros.
21450         (EXTRA_DIST): Remove gen_uio.
21451         (unlocked-io.h): Remove rule.
21452
21453 2002-12-04  Jim Meyering  <jim@meyering.net>
21454
21455         Reflect the fact that stat.c and lstat.c are no longer generated.
21456         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
21457         (DISTCLEANFILES): Likewise.
21458         (EXTRA_DIST): Likewise.
21459         (all_local): Don't depend on stat.c or lstat.c.
21460         (stat.c, lstat.c): Remove rules.
21461         (EXTRA_DIST): Remove xstat.in.
21462
21463         * lib/xstat.in: Remove file.  Contents moved into stat.c.
21464         * lib/stat.c: New file.  Contents mostly from xstat.in.
21465         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
21466         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
21467
21468         * lib/safe-read.c: Rework so that it may serve to define safe_write,
21469         too.
21470         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
21471
21472 2002-12-03  Jim Meyering  <jim@meyering.net>
21473
21474         * lib/safe-read.c, safe-write.c: Change variable names and comments,
21475         but not semantics, to minimize the differences between these two files.
21476         (safe_read): Change comment to mention SAFE_READ_ERROR.
21477
21478         * lib/safe-read.c (IS_EINTR): Define.
21479         (safe_read): Use IS_EINTR in place of in-function cpp directives.
21480
21481 2002-12-02  Jim Meyering  <jim@meyering.net>
21482
21483         * lib/safe-read.c (EINTR): Define.
21484         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
21485         (INT_MAX): Provide fallback.
21486         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
21487
21488         * lib/safe-read.h (SAFE_READ_ERROR): Define.
21489
21490 2002-12-02  Bruno Haible  <bruno@clisp.org>
21491
21492         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
21493         Define, taken from safe-read.c.
21494         (INT_MAX): Provide fallback.
21495         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
21496         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
21497
21498         * lib/safe-read.c (EINTR): Remove definition.
21499         (safe_read): Don't use EINTR if it is absent.
21500
21501 2002-12-01  Jim Meyering  <jim@meyering.net>
21502
21503         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
21504         zero.
21505         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
21506
21507 2002-11-27  Paul Eggert  <eggert@twinsun.com>
21508
21509         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
21510         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
21511         with `if (! (value < limit)) abort ();', for readability.
21512
21513 2002-11-26  Karl Berry  <karl@gnu.org>
21514
21515         * lib/strdup.c: copy from libc again, with jim's ok.
21516         * lib/.cppi-disable: re-add strdup.c
21517
21518 2002-11-25  Karl Berry  <karl@gnu.org>
21519
21520         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
21521         instead of "strtol.c".
21522
21523 2002-11-25  Karl Berry  <karl@gnu.org>
21524
21525         * config/install-sh: update from automake for variable quoting, $0 in
21526         error msgs, etc.
21527
21528         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
21529         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
21530         entry.
21531
21532 2002-11-25  Jim Meyering  <jim@meyering.net>
21533
21534         * lib/mktime.c: Sync from libc, now that it has the latest fix.
21535
21536 2002-11-24  Karl Berry  <karl@gnu.org>
21537
21538         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
21539         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
21540
21541 2002-11-24  Jim Meyering  <jim@meyering.net>
21542
21543         Update from coreutils:
21544
21545         * lib/mktime.c: Merge in changes from libc.
21546
21547         Avoid a link-time failure on some Linux systems.
21548         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
21549         (otherwise).
21550         (__mon_yday): Declare with the STATIC attribute.
21551         (__mktime_internal): Likewise.
21552         Based on a report from Greg Schafer.
21553
21554 2002-11-23  Jim Meyering  <jim@meyering.net>
21555
21556         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
21557         Use `unsigned', not `int', as type of index.
21558
21559         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
21560
21561         * lib/fsusage.c: Remove unneeded parentheses around operands of
21562         `defined'.
21563
21564 2002-11-22  Paul Eggert  <eggert@twinsun.com>
21565
21566         * lib/quotearg.h: Allow multiple inclusion by surrounding with
21567         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
21568         so that we can be included first.
21569         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
21570         * lib/quotearg.c: Include quotearg.h immediately after config.h.
21571         No need to include stddef.h or sys/types.h any more.
21572         Surround local include files with "", not "<>".
21573         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
21574         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
21575         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
21576         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
21577         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
21578         (ISPRINT): Remove; no longer needed now that we assume C89.
21579
21580         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
21581         Preserve errno.
21582
21583         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
21584         quotearg_char): Use SIZE_MAX rather than
21585         (size_t) -1 when we are talking about "infinity".
21586
21587         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
21588
21589 2002-11-22  Paul Eggert  <eggert@twinsun.com>
21590
21591         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
21592         hint that one should use `if (! x) abort ();' rather than `assert
21593         (x);', and anyway it's one less thing to worry about configuring.
21594         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
21595         hash_rehash, hash_insert): Use abort rather than assert.
21596
21597 2002-11-22  Bruno Haible  <bruno@clisp.org>
21598
21599         * lib/safe-read.h: Assume C89. Add comments.
21600         (safe_read): Change return type to size_t.
21601         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
21602         byte counts > SSIZE_MAX correctly.
21603         * lib/safe-write.h: New file.
21604         * lib/safe-write.c: New file.
21605         * lib/full-read.h: New file.
21606         * lib/full-read.c: New file.
21607         * lib/full-write.h: Assume C89. Add comments.
21608         * lib/full-write.c: Include safe-write.h.
21609         (full_write): Rewritten to use safe_write.
21610         Suggested by Jim Meyering and Paul Eggert.
21611
21612 2002-11-21  Jim Meyering  <jim@meyering.net>
21613
21614         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
21615
21616         Merge in changes from the coreutils.
21617
21618         2002-09-25  Paul Eggert  <eggert@twinsun.com>
21619         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
21620         <stdint.h>.
21621         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
21622         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
21623         int.  Work more efficiently if X is the same width as uintmax_t.
21624         Do not compare X to -1, to avoid bogus compiler warning.
21625         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
21626         Don't assume that f_frsize and f_bsize are the same type.
21627
21628         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
21629         warning on FreeBSD.
21630
21631         * lib/makepath.c (make_path): Restore umask *before* creating the final
21632         component.
21633         (make_path): Minor reformatting.
21634
21635         * lib/xmalloc.c: Adjust to work with new autoconf macros,
21636         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
21637         HAVE_MALLOC/HAVE_REALLOC.
21638
21639         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
21640         dummy ones.  At least on GNU/Linux systems, `auto' means something
21641         else.
21642         From Michael Stone.
21643
21644 2002-11-21  Bruno Haible  <bruno@clisp.org>
21645
21646         Remove case insensitive option matching.
21647         * lib/argmatch.h (argcasematch): Remove declaration.
21648         (ARGCASEMATCH): Remove macro.
21649         (__xargmatch_internal): Remove case_sensitive argument.
21650         (XARGMATCH): Update.
21651         (XARGCASEMATCH): Remove macro.
21652         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
21653         case_sensitive argument.
21654         (argcasematch): Remove function.
21655         (__xargmatch_internal): Remove case_sensitive argument.
21656         (main): Use XARGMATCH instead of XARGCASEMATCH.
21657
21658         * lib/xmalloc.c: Change compile-time error message. Add comment about
21659         required autoconf version.
21660
21661 2002-11-20  Paul Eggert  <eggert@twinsun.com>
21662
21663         Merge argmatch cleanups from Bison.  Assume C89.
21664
21665         * lib/argmatch.c: Include config.h here, not in argmatch.h.
21666         Include stdlib.h, for EXIT_FAILURE.
21667         Always include <string.h>, since we assume C89.
21668         (EXIT_FAILURE): Remove pre-C89 bug workaround.
21669         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
21670         Include <stddef.h> instead, since it's all we need for size_t.
21671         (PARAMS): Remove.  All uses removed.
21672         (ARRAY_CARDINALITY): Do not bother to #undef.
21673         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
21674         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
21675         Remove unnecessary parentheses.
21676         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
21677         Insert necessary parentheses.
21678         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
21679         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
21680
21681 2002-11-19  Bruno Haible  <bruno@clisp.org>
21682
21683         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
21684         * lib/mbswidth.h: Include <stddef.h>, for size_t.
21685
21686         * lib/mbswidth.h (PARAMS): Remove macro.
21687         (mbswidth, mbsnwidth): Use ANSI C function declarations.
21688         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
21689
21690         * lib/gcd.h (PARAMS): Remove macro.
21691         (gcd): Use ANSI C function declarations.
21692         * lib/gcd.c (gcd): Likewise.
21693
21694 2002-11-15  Bruno Haible  <bruno@clisp.org>
21695
21696         * lib/strcspn.c: Include <stddef.h>.
21697         (strcspn): Use ANSI C function declaration. Change return type to
21698         size_t. Use NULL.
21699         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
21700         (strpbrk): Use NULL.
21701         * lib/strpbrk.h (PARAMS): Remove macro.
21702         (strpbrk): Use ANSI C function declaration.
21703         * lib/strstr.c: Don't include <sys/types.h>.
21704         * lib/strstr.h (PARAMS): Remove macro.
21705         (strstr): Use ANSI C function declarations.
21706
21707 2002-11-14  Karl Berry  <karl@gnu.org>
21708
21709         * config/mkinstalldirs: `do' on separate line, instead of
21710         `for var; do'.
21711
21712 2002-11-06  Bruno Haible  <bruno@clisp.org>
21713
21714         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
21715         * lib/gcd.c (gcd): Likewise.
21716
21717 2002-11-05  Bruno Haible  <bruno@clisp.org>
21718
21719         * lib/gcd.h: New file, from gettext-0.11.5.
21720         * lib/gcd.c: New file, from gettext-0.11.5.
21721
21722 2002-11-05  Bruno Haible  <bruno@clisp.org>
21723
21724         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21725         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21726         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21727         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21728
21729         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
21730         <libintl.h>.
21731         * lib/makepath.c: Include gettext.h instead of <locale.h> and
21732         <libintl.h>.
21733
21734         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
21735         * lib/human.c: Include gettext.h instead of <libintl.h>.
21736         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
21737         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
21738         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
21739         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
21740         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
21741         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
21742         (textdomain): Remove definition.
21743         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
21744
21745         * lib/long-options.c: Remove include of <libintl.h> and definition of
21746         _.
21747         * lib/same.c: Remove include of <libintl.h> and definition of _.
21748
21749 2002-11-04  Owen Taylor  <otaylor@redhat.com>
21750
21751         * lib/config.charset: A few additions for Solaris.
21752
21753 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
21754
21755         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
21756         * lib/localcharset.c (locale_charset): Declare as extern "C".
21757
21758 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
21759
21760         * lib/config.charset: msdos in uk_UA uses CP1125.
21761
21762 2002-11-04  Bruno Haible  <bruno@clisp.org>
21763
21764         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
21765         * lib/strcase.h: New file, from GNU gettext-0.11.5.
21766         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
21767         * lib/strstr.h: New file, from GNU gettext-0.11.5.
21768         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
21769
21770 2002-11-04  Bruno Haible  <bruno@clisp.org>
21771
21772         * lib/localcharset.c (locale_charset): Don't return an empty string.
21773
21774 2002-11-04  Bruno Haible  <bruno@clisp.org>
21775
21776         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
21777         aliases.
21778
21779 2002-11-04  Bruno Haible  <bruno@clisp.org>
21780
21781         * lib/config.charset: Update for newest glibc. Add canonical names
21782         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
21783
21784 2002-11-04  Bruno Haible  <bruno@clisp.org>
21785
21786         * lib/config.charset: Add support for NetBSD.
21787
21788 2002-11-04  Bruno Haible  <bruno@clisp.org>
21789
21790         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
21791
21792 2002-11-01  Bruno Haible  <bruno@clisp.org>
21793
21794         * configure.in: Add AC_CONFIG_AUX_DIR call.
21795         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
21796         test/Makefile.
21797         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
21798
21799 2002-09-28  Karl Berry  <karl@gnu.org>
21800
21801         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
21802         installed automake until the next release, since changes have been
21803         made.
21804
21805 2002-09-25  Karl Berry  <karl@gnu.org>
21806
21807         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
21808         * lib/getopt*: copy from libc/posix.
21809         * lib/gettext.h: copy from gettext.
21810         * lib/.cppi-disable: add strdup.c, gettext.h.
21811
21812 2002-09-25  Karl Berry  <karl@gnu.org>
21813
21814         * config/srclist.txt: enable gettext.h check.
21815         * config/config.{guess,sub}: update from prep.
21816         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
21817                 from automake 1.6.3.
21818         See srclist*.
21819
21820 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
21821
21822         * regex.c (PATFETCH): Remove the translating fetch.
21823         (PATFETCH_RAW): Rename to PATFETCH.
21824         (set_image_of_range): New fun.
21825         (SET_RANGE_TABLE_WORK_AREA): Use it.
21826         (regex_compile): Don't translate the pattern chars so eagerly.
21827         Only do it when inserting an `exactn' bytecode or when handling
21828         a char-range.
21829         (mutually_exclusive_p): Avoid empty statement.
21830
21831 2002-07-06  Jim Meyering  <meyering@lucent.com>
21832
21833         * m4/README: Don't mention Makefile.am.in.
21834         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
21835
21836 2002-07-01  Jim Meyering  <meyering@lucent.com>
21837
21838         * lib/c-stack.c: Include sys/time.h.
21839         From Volker Borchert.
21840
21841 2002-06-26  Paul Eggert  <eggert@twinsun.com>
21842
21843         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
21844
21845 2002-06-26  Paul Eggert  <eggert@twinsun.com>
21846
21847         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
21848         New macro.  Use it uniformly instead of
21849         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
21850         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
21851         reported by Vin Shelton.
21852
21853 2002-06-22  Paul Eggert  <eggert@twinsun.com>
21854
21855         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
21856         Do not assume SA_SIGINFO behavior.
21857         Bug reported by Jim Meyering on NetBSD 1.5.2.
21858
21859 2002-06-22  Jim Meyering  <meyering@lucent.com>
21860
21861         * m4/c-stack.m4: New file, from diffutils-2.8.2.
21862         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
21863
21864         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
21865         now that configure.ac uses AC_GNU_SOURCE.
21866         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
21867         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
21868
21869         Update to latest tools.  Suggestions from Paul Eggert.
21870         * m4/stdbool.m4: New file, from diffutils-2.8.2.
21871         * m4/gnu-source.m4: Update from diffutils-2.8.2.
21872         * m4/fnmatch.m4: Likewise.
21873         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
21874         to AC_HEADER_STDBOOL
21875
21876 2002-06-22  Jim Meyering  <meyering@lucent.com>
21877
21878         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
21879         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
21880
21881 2002-06-22  Jim Meyering  <meyering@lucent.com>
21882
21883         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
21884
21885         * lib/exitfail.c, exitfail.h: Likewise.
21886         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
21887
21888         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
21889         of fnmatch.h.
21890         (EXTRA_DIST): Add fnmatch_loop.c.
21891         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
21892
21893         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
21894         * lib/fnmatch.c: Update from diffutils-2.8.2.
21895         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
21896         * lib/fnmatch.h: Remove file.
21897
21898 2002-06-21  Jim Meyering  <meyering@lucent.com>
21899
21900         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
21901         * m4/mbrtowc.m4: Likewise.
21902
21903         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
21904         * m4/mbswidth.m4: Reflect name change:
21905         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
21906         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
21907
21908         * m4/lib-link.m4: Update from gettext-0.11.2.
21909         * m4/gettext.m4: Likewise.
21910
21911         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
21912         From Alfred M. Szmidt.
21913
21914 2002-06-18  Paul Eggert  <eggert@twinsun.com>
21915
21916         * lib/file-type.h: Report an error if neither S_ISREG nor
21917         S_IFREG is defined, instead of using a test specific to glibc
21918         2.2.  This should be safe, since POSIX requires S_ISREG and
21919         Unix Version 7 had S_IFREG.  We don't need to check for
21920         <sys/types.h> since we don't use any symbols that it defines.
21921
21922 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
21923
21924         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
21925         $@-t, so that each temporary file name is unique and valid in the first
21926         8 characters, for operation under DOS.
21927
21928 2002-06-15  Paul Eggert  <eggert@twinsun.com>
21929
21930         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
21931
21932 2002-06-15  Jim Meyering  <meyering@lucent.com>
21933
21934         Work even with DJGPP 2.03, which lacks support for symlinks.
21935         From Richard Dawe.
21936         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
21937         is defined.
21938         * lib/lchown.c (S_ISLNK): Likewise.
21939
21940 2002-06-15  Jim Meyering  <meyering@lucent.com>
21941
21942         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
21943         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
21944         have been included before this file.
21945
21946 2002-06-14  Jim Meyering  <meyering@lucent.com>
21947
21948         * lib/file-type.h: Use the version from diffutils-2.8.2.
21949         * lib/file-type.c: Likewise.
21950
21951 2002-06-07  Jim Meyering  <meyering@lucent.com>
21952
21953         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
21954         They're needed at least for NetBSD 1.5.2.
21955         ($statxfs_includes): Include those same headers.
21956         ($statxfs_includes): Include sys/vfs.h if available.
21957         ($statxfs_includes): Likewise for sys/statvfs.h.
21958         Check for the following members in both structs statfs and statvfs:
21959         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
21960
21961 2002-06-01  Jim Meyering  <meyering@lucent.com>
21962
21963         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
21964         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
21965
21966 2002-05-28  Jim Meyering  <meyering@lucent.com>
21967
21968         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
21969         Reported by Volker Borchert.
21970
21971 2002-05-27  Jim Meyering  <meyering@lucent.com>
21972
21973         Fix a problem seen only on nonconforming systems whereby ls.c's
21974         use of localtime, and then of gettimeofday would cause trouble:
21975         the localtime call used to initialize rpl_gettimeofday's save
21976         mechanism would clobber ls's current local time information so
21977         that in any long listing the first file would always be listed
21978         with date 1970-01-01.  Analysis by Volker Borchert.
21979
21980         * lib/gettimeofday.c (localtime): Undefine.
21981         (rpl_localtime): New function.
21982
21983 2002-05-27  Jim Meyering  <meyering@lucent.com>
21984
21985         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
21986         localtime.
21987
21988         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
21989         use the replacement function; it wouldn't resolve at link time.
21990         Reported by Volker Borchert.
21991
21992 2002-05-22  Jim Meyering  <meyering@lucent.com>
21993
21994         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
21995         file-type.h.
21996         * lib/file-type.h: New file.
21997         * lib/file-type.c (file_type): New file/function.  Extracted from
21998         diffutils.
21999
22000 2002-04-30  Jim Meyering  <meyering@lucent.com>
22001
22002         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
22003
22004 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22005
22006         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
22007
22008 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22009
22010         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
22011         Do not check for alloca.h (no longer used) or stdbool.h (was never
22012         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
22013
22014 2002-04-29  Paul Eggert  <eggert@twinsun.com>
22015
22016         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
22017
22018 2002-04-29  Jim Meyering  <meyering@lucent.com>
22019
22020         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
22021         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
22022         Use AC_FUNC_STRNLEN here instead.
22023
22024         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
22025         With autoconf-2.53a, it's part of AC_PROG_CC.
22026
22027 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22028
22029         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
22030         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
22031
22032 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22033
22034         * lib/sig2str.h, lib/sig2str.c: New files.
22035         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
22036
22037 2002-04-28  Paul Eggert  <eggert@twinsun.com>
22038
22039         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
22040         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
22041         of 127, since 64 is the largest conceivable number for ancient
22042         nonstandard hosts.
22043         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
22044
22045 2002-04-28  Jim Meyering  <meyering@lucent.com>
22046
22047         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
22048
22049 2002-04-24  Jim Meyering  <meyering@lucent.com>
22050
22051         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
22052         (jm_PREREQ): Use it.
22053
22054         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
22055         mach/mach.h fcntl.h.
22056         Check for this function: setlocale.
22057
22058 2002-04-24  Jim Meyering  <meyering@lucent.com>
22059
22060         * lib/gettext.h: New file, from Gettext.
22061         * lib/Makefile.am (INCLUDES): Remove -I../intl.
22062         (libfetish_a_SOURCES): Add gettext.h.
22063
22064 2002-04-16  Jim Meyering  <meyering@lucent.com>
22065
22066         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
22067         ut_pid, ut_id, ut_exit.
22068
22069 2002-04-16  Jim Meyering  <meyering@lucent.com>
22070
22071         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
22072         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
22073         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
22074
22075 2002-04-12  Jim Meyering  <meyering@lucent.com>
22076
22077         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
22078         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
22079         existence of the getmntinfo function.  Needed for Darwin 5.3.
22080
22081         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
22082         This is necessary at least on Darwin 5.3.
22083
22084         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
22085         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
22086         strnlen.o in the library, and that makes some versions of ranlib
22087         object.
22088
22089 2002-04-12  Jim Meyering  <meyering@lucent.com>
22090
22091         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
22092
22093 2002-04-09  Jim Meyering  <meyering@lucent.com>
22094
22095         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
22096         to be more precise.  Rather than saying we're checking whether the
22097         function `works', say what we're testing.
22098         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
22099         Reported by Bruno Haible.
22100
22101 2002-03-10  Jim Meyering  <meyering@lucent.com>
22102
22103         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
22104         Suggestion from Santiago Vila.
22105
22106 2002-03-08  Jim Meyering  <meyering@lucent.com>
22107
22108         * lib/rename.c: Mention that this wrapper is needed also on
22109         mips-dec-ultrix4.4 systems.
22110
22111 2002-03-02  Jim Meyering  <meyering@lucent.com>
22112
22113         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
22114         not HAVE_CLOCK_SETTIME.
22115
22116 2002-02-27  Paul Eggert  <eggert@twinsun.com>
22117
22118         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
22119         Check for clock_settime.
22120
22121 2002-02-27  Paul Eggert  <eggert@twinsun.com>
22122
22123         * lib/nanosleep.h: Rename to....
22124         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
22125
22126         * lib/gettime.c: New file.
22127         * lib/settime.c: New file.
22128         * lib/stime.c: Remove.
22129
22130         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
22131         timespec.h.  Remove nanosleep.h.
22132
22133 2002-02-25  Paul Eggert  <eggert@twinsun.com>
22134
22135         * m4/acl.m4: New file.
22136         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
22137         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
22138
22139 2002-02-25  Paul Eggert  <eggert@twinsun.com>
22140
22141         * lib/acl.c, lib/acl.h: New files.
22142         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
22143
22144 2002-02-24  Jim Meyering  <meyering@lucent.com>
22145
22146         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
22147         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
22148         cause trouble.  Reported by Nelson Beebe.
22149
22150 2002-02-23  Paul Eggert  <eggert@twinsun.com>
22151
22152         * lib/path-concat.c (xpath_concat): Reorder code to pacify
22153         compilers that don't know that xalloc_die never returns.
22154
22155 2002-02-20  Jim Meyering  <meyering@lucent.com>
22156
22157         * lib/getdate.c: Regenerate using bison-1.33.
22158
22159 2002-02-17  Jim Meyering  <meyering@lucent.com>
22160
22161         * config/config.guess (main): Don't use `head -1'; it's no longer
22162         portable. Use `sed 1q' instead.
22163
22164 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
22165
22166         * m4/codeset.m4: Upgrade to gettext-0.11.
22167         * m4/gettext.m4: Upgrade to gettext-0.11.
22168         * m4/glibc21.m4: Upgrade to gettext-0.11.
22169         * m4/iconv.m4: Upgrade to gettext-0.11.
22170         * m4/isc-posix.m4: Upgrade to gettext-0.11.
22171         * m4/lcmessage.m4: Upgrade to gettext-0.11.
22172         * m4/lib-ld.m4: New file, from gettext-0.11.
22173         * m4/lib-link.m4: New file, from gettext-0.11.
22174         * m4/lib-prefix.m4: New file, from gettext-0.11.
22175         * m4/progtest.m4: Upgrade to gettext-0.11.
22176
22177 2002-02-15  Paul Eggert  <eggert@twinsun.com>
22178
22179         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
22180         (jm_PREREQ): Use it.
22181
22182 2002-02-15  Paul Eggert  <eggert@twinsun.com>
22183
22184         * lib/posixver.c, lib/posixver.h: New files.
22185         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
22186
22187 2002-02-02  Paul Eggert  <eggert@twinsun.com>
22188             Bruno Haible  <bruno@clisp.org>
22189
22190         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
22191         (fwrite_success_callback): New declaration.
22192         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
22193         print_unicode_char. Call failure callback instead of error.
22194         (fwrite_success_callback): New function.
22195         (exit_failure_callback): New function.
22196         (fallback_failure_callback): New function.
22197         (print_unicode_char): Call unicode_to_mb.
22198
22199 2002-01-26  Jim Meyering  <meyering@lucent.com>
22200
22201         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
22202         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
22203
22204 2002-01-26  Jim Meyering  <meyering@lucent.com>
22205
22206         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
22207
22208 2002-01-22  Paul Eggert  <eggert@twinsun.com>
22209
22210         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
22211
22212 2002-01-22  Jim Meyering  <meyering@lucent.com>
22213
22214         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
22215         Otherwise, some versions of automake would omit the rule that makes
22216         Makefile from Makefile.in.
22217
22218 2002-01-21  Paul Eggert  <eggert@twinsun.com>
22219
22220         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
22221         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
22222         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
22223         (memcoll): Set errno to zero if there is no error.
22224
22225         * lib/quotearg.c (quotearg_buffer_restyled):
22226         Fix bug with quoting buffers containing NUL when backslashing escapes.
22227         This bug was exposed by the other changes in this patch.
22228         (quotearg_n_options): New arg ARGSIZE.
22229         All callers changed.
22230         (quoting_options_from_style): New function.
22231         (quotearg_n_style): Use it.
22232         (quotearg_n_style_mem): New function.
22233
22234         * lib/quotearg.h (quotearg_n_style_mem): New function.
22235
22236 2002-01-19  Jim Meyering  <meyering@lucent.com>
22237
22238         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
22239         Remove useless quotes: DF_PROG="df".
22240         * m4/strnlen.m4: New file.
22241
22242 2002-01-16  Paul Eggert  <eggert@twinsun.com>
22243
22244         * lib/backupfile.c (ISDIGIT): Comment fix.
22245         * lib/getdate.y (ISDIGIT): Likewise.
22246         * lib/posixtm.c (ISDIGIT, year): Likewise.
22247         * lib/strverscmp.c (ISDIGIT): Likewise.
22248         * lib/userspec.c (ISDIGIT): Likewise.
22249
22250 2002-01-16  Jim Meyering  <meyering@lucent.com>
22251
22252         * lib/getdate.y: Add three semicolons, each just before a closing
22253         brace. Bison (as of version 1.31) no longer papers over that mistake.
22254
22255 2002-01-05  Jim Meyering  <meyering@lucent.com>
22256
22257         * lib/version-etc.c (version_etc_copyright): Update copyright year.
22258
22259 2001-12-19  Paul Eggert  <eggert@twinsun.com>
22260
22261         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
22262         not silently exit merely because the output buffer happens to
22263         have nothing pending.
22264
22265 2001-12-18  Paul Eggert  <eggert@twinsun.com>
22266
22267         See the big note in ../ChangeLog.
22268         * lib/human.c (suffixes): Prefer K to k for 1024.
22269         (generate_suffix_backwards): New function.
22270         (human_readable_inexact): Use it.
22271         * lib/xstrtol.c (__xstrtol): If there is no number but there
22272         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
22273         Accept 'K' as well as 'k'.
22274
22275 2001-12-15  Jim Meyering  <meyering@lucent.com>
22276
22277         * lib/regex.h (__restrict_arr): Update from libc.
22278
22279         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
22280         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
22281         (STREQ): Define.
22282
22283 2001-12-14  Jim Meyering  <meyering@lucent.com>
22284
22285         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
22286         Suggestion from Bruno Haible.
22287
22288 2001-12-10  Jim Meyering  <meyering@lucent.com>
22289
22290         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
22291         xrealloc, Instead, include "xalloc.h".
22292         (initbuffer): Don't cast xmalloc return value to char*.
22293         (readline): Reword comment.
22294         Don't cast xrealloc return value to char*
22295         Return NULL, not 0.
22296
22297 2001-12-09  Jim Meyering  <meyering@lucent.com>
22298
22299         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
22300         about `signed and unsigned type in conditional expression'.
22301         * lib/posixtm.c (posix_time_parse): Likewise.
22302
22303         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
22304
22305         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
22306         to avoid a pedantic warning.
22307
22308         * lib/getstr.c: Don't include assert.h.
22309         (getstr): Remove warning-evoking assertions.
22310         Return -1 if offset parameter is out of bounds.
22311         Change the type of a local from int to size_t.
22312
22313         * lib/strftime.c (my_strftime_localtime_r): Include this function
22314         definition in the `#if ! HAVE_TM_GMTOFF' block.
22315
22316         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
22317         Include xalloc.h instead.
22318
22319 2001-12-02  Jim Meyering  <meyering@lucent.com>
22320
22321         * lib/tempname.c: Don't declare getenv, thus reverting the change of
22322         2001-11-18.  It's no longer necessary, now that stdlib.h is always
22323         included.
22324
22325         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
22326         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
22327
22328 2001-11-30  Akim Demaille  <akim@epita.fr>
22329
22330         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
22331         before being defined.
22332
22333 2001-11-27  Paul Eggert  <eggert@twinsun.com>
22334
22335         * lib/quotearg.h (quotearg_n, quotearg_n_style):
22336         First arg is int, not unsigned.
22337         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
22338         (SIZE_MAX, UINT_MAX): New macros.
22339         (quotearg_n_options): Abort if N is negative.
22340         Avoid overflow check on hosts where size_t is 64 bits and int
22341         is 32 bits, as overflow is impossible there.
22342         Fix off-by-one typo that caused unnecessary reallocation.
22343
22344 2001-11-27  Jim Meyering  <meyering@lucent.com>
22345
22346         * lib/tempname.c: Merge with version from libc.
22347         * lib/regex.c: Likewise.
22348
22349         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
22350         systems for which STDC_HEADERS is 0, it was not included, resulting in
22351         a warning about an integer-to-pointer conversion problem with getenv.
22352         Reported by Volker Borchert.
22353
22354 2001-11-26  Jim Meyering  <meyering@lucent.com>
22355
22356         * lib/gtod.h: Remove file.
22357         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
22358         * lib/gettimeofday.c: Don't include gtod.h.
22359         (GTOD_init): Remove function.
22360         (rpl_gettimeofday): Do its job here instead, rather than aborting.
22361         Suggestion from Volker Borchert.
22362
22363 2001-11-23  Jim Meyering  <meyering@lucent.com>
22364
22365         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
22366         it.
22367         * lib/hash.c (struct hash_table): Define it here instead.
22368
22369 2001-11-22  Jim Meyering  <meyering@lucent.com>
22370
22371         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
22372
22373 2001-11-20  Jim Meyering  <meyering@lucent.com>
22374
22375         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
22376         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
22377
22378 2001-11-19  Jim Meyering  <meyering@lucent.com>
22379
22380         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
22381         directory.  Use "conftestXXXXXX" as the template.
22382         Suggestion from Paul Eggert.
22383
22384         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
22385         immediately, so the test doesn't mistakenly hit the max-open-files
22386         limit.
22387
22388 2001-11-18  Paul Eggert  <eggert@twinsun.com>
22389
22390         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
22391         (TEMPORARIES): New macro.
22392         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
22393         removes an artificial limitation (e.g. HP-UX 10.20, where
22394         TMP_MAX is 17576).
22395
22396 2001-11-18  Jim Meyering  <meyering@lucent.com>
22397
22398         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
22399
22400 2001-11-18  Jim Meyering  <meyering@lucent.com>
22401
22402         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
22403         on SunOS 4.
22404
22405         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
22406         files will be created before anything else.
22407
22408 2001-11-17  Paul Eggert  <eggert@twinsun.com>
22409
22410         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
22411         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
22412
22413 2001-11-17  Jim Meyering  <meyering@lucent.com>
22414
22415         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
22416         Prompted by a report from Bob Proulx.
22417
22418         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
22419         Instead, require UTILS_FUNC_MKSTEMP.
22420
22421 2001-11-17  Jim Meyering  <meyering@lucent.com>
22422
22423         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
22424         Now, that's done as part of AC_FUNC_STRTOD.
22425
22426 2001-11-17  Jim Meyering  <meyering@lucent.com>
22427
22428         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
22429         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
22430         rather than group writable.  Patch by Juan F. Codagnone.
22431
22432         * lib/readtokens.c: Remove explicit declarations of xmalloc and
22433         xrealloc, Instead, include "xalloc.h".
22434
22435         * lib/mountlist.c: Include unlocked-io.h after all system headers.
22436         Remove explicit declarations of xmalloc, xrealloc,
22437         and xstrdup.  Instead, include "xalloc.h".
22438
22439         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
22440         unlocked-io.h.
22441         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
22442         Likewise.
22443         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
22444
22445         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
22446         Reported by Padraig Brady.
22447
22448         * lib/mkstemp.c: #undef mkstemp.
22449         Include config.h.
22450         (rpl_mkstemp): Rename from mkstemp.
22451         Protoize.
22452
22453 2001-11-16  Jim Meyering  <meyering@lucent.com>
22454
22455         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
22456         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
22457         determine the amount of total physical memory, use pstat_getstatic.
22458         HPUX-11 doesn't define _SC_PHYS_PAGES.
22459         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
22460         If sysconf couldn't be used to determine the amount of available
22461         physical memory, use both pstat_getstatic and pstat_getdynamic.
22462         Based on a patch from Bob Proulx.
22463
22464 2001-11-10  Jim Meyering  <meyering@lucent.com>
22465
22466         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
22467         (jm_PREREQ): Use it.
22468
22469 2001-11-09  Jim Meyering  <meyering@lucent.com>
22470
22471         * m4/jm-macros.m4: Require autoconf-2.52f.
22472         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
22473         Use these AC_-prefixed names, not the AM_-prefixed ones.
22474
22475         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
22476
22477 2001-11-05  Jim Meyering  <meyering@lucent.com>
22478
22479         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
22480
22481 2001-11-04  Jim Meyering  <meyering@lucent.com>
22482
22483         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
22484         $DEFS.
22485
22486 2001-11-03  Jim Meyering  <meyering@lucent.com>
22487
22488         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
22489         of AC_DEFUN.
22490
22491         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
22492         know the name of the variable in the macro definition.
22493
22494 2001-11-03  Jim Meyering  <meyering@lucent.com>
22495
22496         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
22497         in argmatch_to_argument call.
22498
22499         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
22500         argument.
22501
22502         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
22503         e.g., a fault due to an attempt to free a NULL pointer.
22504
22505 2001-11-01  Jim Meyering  <meyering@lucent.com>
22506
22507         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
22508         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
22509
22510 2001-11-01  Jim Meyering  <meyering@lucent.com>
22511
22512         * lib/dirfd.c, lib/dirfd.h: New files.
22513         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
22514
22515         * lib/hash.c (hash_print) [TESTING]: Clean up.
22516
22517 2001-10-22  Paul Eggert  <eggert@twinsun.com>
22518
22519         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
22520         to avoid a warning if -Wall.
22521
22522 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
22523
22524         * README: New file
22525         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
22526         (per RMS's instructions, this is now the canonical source)
22527         * lgpl/, gpl/: New directories.
22528
22529 2001-10-21  Paul Eggert  <eggert@twinsun.com>
22530
22531         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
22532
22533 2001-10-21  Jim Meyering  <meyering@lucent.com>
22534
22535         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
22536         this code would end up calling gettext even in packages built
22537         with --disable-nls.
22538         * lib/getopt.c (_): Likewise.
22539         * lib/regex.c (_): Likewise.
22540
22541 2001-10-20  Paul Eggert  <eggert@twinsun.com>
22542
22543         * m4/error.m4 (jm_PREREQ_ERROR):
22544         Do not invoke AC_CHECK_FUNCS with strerror_r, as
22545         AC_FUNC_STRERROR_R does that.
22546         Check for strerror declaration.
22547
22548         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
22549         are supposed to have them these days.
22550         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
22551         Merge changes from latest Autoconf CVS.
22552         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
22553         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
22554         POSIX decided to standardize on the int flavor of strerror_r.
22555
22556 2001-10-20  Paul Eggert  <eggert@twinsun.com>
22557
22558         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
22559         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
22560         Use strerror_r that is only a macro, even if it is not a function.
22561         (strerror): Check for HAVE_DECL_STRERROR before declaring.
22562         (private_strerror): Use prototypes, not old-style function definition.
22563         (print_errno_message): New function.
22564         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
22565         char*-flavored one.
22566         (error_tail, error, error_at_line): Use it.
22567
22568 2001-10-11  Jim Meyering  <meyering@lucent.com>
22569
22570         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
22571         and quote_n (1, ... to avoid clobbering a buffer.
22572
22573 2001-10-05  Jim Meyering  <meyering@lucent.com>
22574
22575         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
22576         hash-pjw.h.
22577         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
22578         * lib/hash-pjw.h: New file.
22579
22580 2001-09-30  Jim Meyering  <meyering@lucent.com>
22581
22582         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
22583         `struct fsstat' has the `f_fstypename' member.
22584         Use that to define FS_TYPE, which is now used to make
22585         the getfsstat link test tighter.
22586
22587 2001-09-30  Jim Meyering  <meyering@lucent.com>
22588
22589         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
22590         Include <sys/ucred.h>, for Apple Darwin.
22591         Include sys/mount.h and sys/fs_types.h only if available.
22592         (FS_TYPE): Define.
22593         (read_filesystem_list): Use FS_TYPE.
22594
22595 2001-09-29  Paul Eggert  <eggert@twinsun.com>
22596
22597         * lib/exclude.c (excluded_filename): 0 -> false, since it's
22598         a boolean context.
22599
22600 2001-09-29  Jim Meyering  <meyering@lucent.com>
22601
22602         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
22603         [one-argument getmntent function]): Include stdio.h before mntent.h.
22604         SunOS 4.1.x needs it for the declaration of `FILE'.
22605         Patch by Volker Borchert.
22606
22607         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
22608         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
22609         sys/fs_types.h, and make the link-test for getfsstat guard #include
22610         directives with appropriate #if HAVE_*_H tests so that we can
22611         detect getfsstat on Apple Darwin1.3.7 systems.
22612         Reported by Nelson Beebe.
22613         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
22614
22615 2001-09-28  Paul Eggert  <eggert@twinsun.com>
22616
22617         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
22618         #defines strtoimax.  Also treat the other strto* functions
22619         like strtoimax.
22620
22621         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
22622         Check for strtoul and strtoumax,
22623         as those declarations are made even in the signed case.
22624         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
22625         Likewise, for strtol and strtoimax.
22626
22627 2001-09-28  Paul Eggert  <eggert@twinsun.com>
22628
22629         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
22630         #defines strtoimax.  Also treat the other strto* functions
22631         like strtoimax.
22632
22633         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
22634         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
22635         (strtoimax, strtoumax): Do not declare if already defined as a macro.
22636
22637 2001-09-26  Jim Meyering  <meyering@lucent.com>
22638
22639         Most macros in unlocked-io.h had the wrong number of arguments.
22640         * lib/gen-uio: New script.
22641         (USE_UNLOCKED_IO): Define to 1 if not already defined.
22642         * lib/unlocked-io.hin: Remove file.
22643         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
22644         rather than trying to embed it here.
22645         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
22646         Reported by Padraig Brady.
22647
22648 2001-09-25  Volker Borchert  <bt@teknon.de>
22649
22650         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
22651         `result'.
22652
22653 2001-09-24  Jim Meyering  <meyering@lucent.com>
22654
22655         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
22656
22657 2001-09-23  Jim Meyering  <meyering@lucent.com>
22658
22659         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
22660         instead of the mere test for existence of mntent.h.  The latter
22661         would get a false-positive on AIX 3.4 systems.
22662         In the outer getmntent if-block, don't die if neither of the getmntent
22663         tests succeeds.  Instead, just fall through and continue with the
22664         remaining tests.
22665
22666 2001-09-23  Jim Meyering  <meyering@lucent.com>
22667
22668         * lib/mountlist.c: Remove useless parentheses in #if directives.
22669         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
22670         the deprecated MOUNTED symbol is no longer defined in mntent.h.
22671
22672 2001-09-22  Jim Meyering  <meyering@lucent.com>
22673
22674         * m4/gettext.m4: New file.  From gettext.
22675         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
22676         * m4/progtest.m4: Likewise
22677         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
22678         * m4/glibc21.m4: Likewise.
22679
22680         * m4/libintl.m4: Remove.  No longer used.
22681
22682 2001-09-22  Jim Meyering  <meyering@lucent.com>
22683
22684         * lib/localcharset.c: Update from latest gettext.
22685         * lib/config.charset: Likewise.
22686
22687 2001-09-20  Jim Meyering  <meyering@lucent.com>
22688
22689         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
22690         strtoimax.
22691         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
22692         strtoumax.
22693
22694 2001-09-20  Jim Meyering  <meyering@lucent.com>
22695
22696         * lib/xstrtol.c (strtoimax): Guard declaration with
22697         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
22698         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
22699         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
22700         (strtoumax): Likewise, for completeness (it wasn't necessary).
22701
22702 2001-09-17  Paul Eggert  <eggert@twinsun.com>
22703
22704         * lib/strtoimax.c (HAVE_LONG_LONG):
22705         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
22706         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
22707         to work around bug in IBM C compiler.
22708
22709 2001-09-17  Jim Meyering  <meyering@lucent.com>
22710
22711         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
22712         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
22713         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
22714         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
22715         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
22716         whenever the right hand side need not be expanded by the shell.
22717
22718 2001-09-16  Paul Eggert  <eggert@twinsun.com>
22719
22720         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
22721         library.  It's not correct, as some older glibcs are buggy.
22722         fnmatch wasn't fixed until glibc 2.2.
22723
22724         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
22725         special shell magic here.
22726
22727 2001-09-16  Jim Meyering  <meyering@lucent.com>
22728
22729         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
22730         * m4/jm-macros.m4: Require it.
22731
22732 2001-09-16  Jim Meyering  <meyering@lucent.com>
22733
22734         * lib/mkdir.c: New file.
22735
22736 2001-09-15  Jim Meyering  <meyering@lucent.com>
22737
22738         * m4/jm-macros.m4: Check for help2man.
22739
22740 2001-09-11  Jim Meyering  <meyering@lucent.com>
22741
22742         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
22743         The body, by Paul Eggert, was moved here from configure.in.
22744         * m4/jm-macros.m4: Require UTILS_HOST_OS.
22745
22746 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22747
22748         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
22749         (jm_PREREQ): Use it.
22750
22751 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22752
22753         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
22754         Use ssize_t, not int, to store result of readlink.
22755         Check for ssize_t overflow as well as size_t overflow,
22756         as POSIX says the result of readlink is implementation-defined
22757         when ssize_t overflows.
22758         Remove unnecessary cast to char*.
22759         Use free+malloc instead of realloc, as the storage doesn't need
22760         to be preserved and it's clearer and can be more efficient that way.
22761         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
22762         * lib/xreadlink.h (xreadlink): Update prototype.
22763
22764 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22765
22766         * lib/xgetcwd.c: Revert some of the previous change; intead,
22767         fix the HAVE_GETCWD_NULL code to behave more like the
22768         !HAVE_GETCWD_NULL code used to.
22769
22770         Include "xalloc.h".
22771         (xgetcwd): Do not return NULL when memory is exhausted; instead,
22772         invoke xalloc_die.
22773
22774 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22775
22776         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
22777         sys/param.h, as pathmax.h includes them.
22778
22779 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22780
22781         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
22782         (jm_PREREQ_XGETCWD): New macro.
22783
22784         * m4/getcwd.m4: New file.
22785
22786 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22787
22788         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
22789         like the HAVE_GETCWD_NULL code.
22790         Include pathmax.h if not HAVE_GETCWD.
22791         Do not include xalloc.h.
22792         (INITIAL_BUFFER_SIZE): New symbol.
22793         Do not use xmalloc / xrealloc, since the caller is responsible for
22794         handling errors.  Preserve errno around `free' during failure.
22795         Do not overrun buffer when using getwd.
22796
22797 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22798
22799         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
22800         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
22801         getcwd (NULL, 0).
22802
22803 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22804
22805         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
22806         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
22807         spotted by Jim Meyering.
22808
22809 2001-09-03  Jim Meyering  <meyering@lucent.com>
22810
22811         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
22812         failure.
22813
22814 2001-09-02  Jim Meyering  <meyering@lucent.com>
22815
22816         * lib/error.c: Update from GNU libc.
22817
22818 2001-09-01  Jim Meyering  <meyering@lucent.com>
22819
22820         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
22821         Used by df.
22822
22823 2001-09-01  Jim Meyering  <meyering@lucent.com>
22824
22825         * lib/xreadlink.c: New file.
22826         * lib/xreadlink.h: New file.
22827         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
22828         xreadlink.h.
22829
22830         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
22831         doesn't conflict with sparc Solaris 7's definition in
22832         /usr/include/sys/int_types.h.
22833
22834         * lib/exclude.c: Use `""', not `<>' to #include non-system header
22835         files.
22836         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
22837         and strncasecmp as r-values.  Unixware didn't have declarations.
22838
22839 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22840
22841         * lib/xstrtol.h: Add copyright notice.
22842         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
22843         LONGINT_INVALID_SUFFIX_CHAR.
22844
22845 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22846
22847         * lib/xstrtol.c (strtoimax): New decl.
22848
22849 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22850
22851         * lib/xgetcwd.c: Don't include pathmax.h.
22852         Include stdlib.h and unistd.h if available.
22853         Include xalloc.h.
22854         (xmalloc, xstrdup, free): Remove decls.
22855         (xgetcwd): Don't assume sizes fit in unsigned.
22856         Check for overflow when computing sizes.
22857         Simplify reallocation code.
22858
22859 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22860
22861         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
22862         a directory's st_size can have an arbitrary value, so the old
22863         usage could waste an arbitrary amount of memory.  All uses
22864         changed.
22865         * lib/savedir.h: Update prototype.
22866
22867 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22868
22869         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
22870
22871         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
22872         old strtoimax.c.
22873
22874         Also, make the following further changes to make this file's
22875         configuration more similar to that of strtol.c:
22876         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
22877         (strtoumax, uintmax_t, strtoull, strtol): Remove.
22878         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
22879         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
22880         changed to signed values.
22881
22882         And make the following changes as well:
22883         Fix copyright notice, as 1999 was missing.
22884         (verify): New macro.
22885         (strtoimax): Check sizes at compile-time, not run-time.
22886         Prefer strtol to strtoll if both work.
22887         (main): Remove; it was not that useful and was a pain to maintain.
22888
22889         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
22890
22891 2001-08-31  Jim Meyering  <meyering@lucent.com>
22892
22893         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
22894         Use an initial, malloc'd, buffer of length 128 rather than
22895         a statically allocated one of length 1024.
22896
22897 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22898
22899         Simplify code, partly by assuming autoconf 2.52 semantics.
22900
22901         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
22902
22903         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
22904         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
22905         All uses removed.
22906         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
22907         Move AC_REQUIRE to next-to-top level, to avoid confusion.
22908         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
22909         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
22910         jm_AC_HEADER_INTTYPES_H.
22911         * m4/jm-macros.m4 (jm_MACROS): Likewise.
22912
22913         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
22914
22915         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
22916         Quote first arg of AC_DEFUN.
22917         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
22918         since they are needed to parse the include file even if we need
22919         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
22920         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
22921         but with opposite signedness.
22922
22923 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22924
22925         Merge 'exclude' changes from tar 1.13.22.
22926         This fixes one or two unlikely storage allocation overflow bugs,
22927         but doesn't change user-visible behavior otherwise.
22928
22929 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22930
22931         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
22932         (jm_PREREQ_EXCLUDE): New macro.
22933
22934 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22935
22936         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
22937         tm to be declared.
22938
22939 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22940
22941         * lib/hash.c: Remove '2001' from copyright notice.
22942
22943 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22944
22945         * lib/full-write.h: New file.
22946         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
22947         * lib/full-write.c: Correct credits, as cccp.c no longer
22948         exists and anyway it was so heavily changed from the old cccp
22949         code as to be unrecognizable.  Include full-write.h.
22950         (full_write) Return size_t, with short writes meaning failure.
22951         All callers changed.  This fixes a bug with large buffers
22952         on 64-bit hosts.
22953         * lib/utime.c: Include full-write.h.
22954
22955 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22956
22957         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
22958         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
22959         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
22960         Include if available.
22961         (<xalloc.h>): Include
22962         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
22963         (verify): New macro.  Use it to verify that EXCLUDE macros do not
22964         collide with FNM macros.
22965         (struct patopts): New struct.
22966         (struct exclude): Use it, as exclude patterns now come with options.
22967         (new_exclude): Support above changes.
22968         (new_exclude, add_exclude_file):
22969         Initial size must now be a power of two to simplify overflow checking.
22970         (free_exclude, fnmatch_no_wildcards): New function.
22971         (excluded_filename): No longer requires options arg, as the options
22972         are determined by add_exclude.  Now returns bool, not int.
22973         (excluded_filename, add_exclude):
22974         Add support for the fancy new exclusion options.
22975         (add_exclude, add_exclude_file): Now takes int options arg.
22976         Check for arithmetic overflow when computing sizes.
22977         (add_exclude_file): xrealloc might modify errno, so don't
22978         realloc until after errno might be used.
22979
22980         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
22981         New macros.
22982         (free_exclude): New decl.
22983         (add_exclude, add_exclude_file): Now takes int options arg.
22984         (excluded_filename): No longer requires options arg, as the options
22985         are determined by add_exclude.  Now returns bool, not int.
22986
22987 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22988
22989         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
22990
22991 2001-08-27  Jim Meyering  <meyering@lucent.com>
22992
22993         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
22994
22995         * lib/version-etc.c (N_): Remove definition.
22996         Revert most of last change.
22997         Instead, simply don't mark the `Copyright...' string for translation.
22998         Based on advice from Paul Eggert.
22999
23000         * lib/strtoxmax.c: Tweak comment.
23001
23002 2001-08-26  Jim Meyering  <meyering@lucent.com>
23003
23004         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
23005
23006         * m4/xstrtoimax.m4: New file.
23007         * m4/xstrtoumax.m4: Add comments explaining why we
23008         AC_REPLACE_FUNCS(strtol).
23009
23010 2001-08-26  Jim Meyering  <meyering@lucent.com>
23011
23012         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
23013         of copyright with `%s' so translators don't get an untranslated
23014         message in 2002.
23015         (COPYRIGHT_YEAR): Define.
23016         (version_etc): Use fprintf rather than fputs.
23017         Suggestion from Ulrich Drepper.
23018
23019         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
23020
23021         * lib/strtoll.c: New file, from GNU libc.
23022         * lib/xstrtoimax.c: New file.
23023
23024         * lib/xstrtol.h: Add xstrtoimax.
23025         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
23026         * lib/strtoimax.c: New file.  Likewise, but first define
23027         STRTOUXMAX_SIGNED.
23028
23029         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
23030         ...
23031         * lib/strtoxmax.c: ... then renamed to this.
23032
23033 2001-08-18  Paul Eggert  <eggert@twinsun.com>
23034
23035         * m4/inttypes.m4: Add AC_PREREQ(2.13).
23036         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
23037         (jm_AC_TYPE_INTMAX_T): New macro.
23038         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
23039
23040         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
23041
23042         * m4/longlong.m4: Renamed from ulonglong.m4.
23043         * m4/inttypes.m4: Renamed from inttypes_h.m4.
23044         * m4/uintmax_t.m4: Removed.
23045
23046 2001-08-13  Paul Eggert  <eggert@twinsun.com>
23047
23048         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
23049         Port to Solaris 8, where 'sed' requires a space after the 'r'
23050         command, and where sh dislikes "$/".  Clean up the spacing a bit.
23051         Redirect output to $tmp just once.
23052
23053 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
23054
23055         * lib/addext.c (<errno.h>): Include.
23056         (errno): Declare if not defined.
23057         (addext): Work correctly when pathconf returns -1 and leaves
23058         errno alone because there is no limit.  Also, work even if
23059         pathconf returns a value greater than SIZE_MAX.
23060
23061 2001-08-12  Jim Meyering  <meyering@lucent.com>
23062
23063         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
23064         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
23065         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
23066         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
23067         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
23068         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
23069         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
23070         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
23071         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
23072         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
23073         utime.m4, utimes.m4, xstrtoumax.m4:
23074         Quote the first argument in each use of AC_DEFUN.
23075
23076 2001-08-12  Jim Meyering  <meyering@lucent.com>
23077
23078         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
23079         Simply `return getcwd (NULL, 0);'.
23080         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
23081         Use 1300 as initial value for length, not PATH_MAX.
23082
23083         * lib/pathmax.h: Clean up cpp syntax.
23084
23085 2001-08-12  Jim Meyering  <meyering@lucent.com>
23086
23087         * lib/gettimeofday.c: New file.
23088         * lib/gtod.h: New file.
23089         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
23090
23091 2001-08-05  Jim Meyering  <meyering@lucent.com>
23092
23093         * m4/jm-macros.m4: Require autoconf-2.52.
23094
23095 2001-08-04  Jim Meyering  <meyering@lucent.com>
23096
23097         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
23098         stmt, to get in sync with glibc.
23099
23100 2001-08-03  Paul Eggert  <eggert@twinsun.com>
23101
23102         The following changes are from gettext 0.10.39 as maintained by
23103         Bruno Haible.
23104
23105         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
23106         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
23107         with inverted sense.  All uses changed.
23108
23109         * lib/mbswidth.c: Don't include <limits.h>.
23110         Include <stdlib.h> and <string.h> unconditionally.
23111         (iswcntrl, mbsinit, ISCNTRL): New macros.
23112         (mbsnwidth): Use K&R style function declarations.
23113         Don't bother checking for MB_LEN_MAX == 1, since the compiler
23114         can optimize it when MB_CUR_MAX == 1.
23115         The width of control characters is zero, not 1.
23116
23117 2001-08-03  Paul Eggert  <eggert@twinsun.com>
23118
23119         The following changes are from gettext 0.10.39 as maintained by
23120         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
23121
23122         * m4/codeset.m4: Upgrade to serial AM1.
23123         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
23124         all uses changed.  Quote first arg of AC_DEFUN.
23125         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
23126
23127         * m4/iconv.m4: Upgrade to serial AM2.
23128         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
23129         Add --with-libconv-prefix.
23130         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
23131         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
23132         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
23133         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
23134         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
23135
23136         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
23137         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
23138         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
23139         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
23140         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
23141         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
23142         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
23143         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
23144         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
23145
23146         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
23147         string.h any more.
23148
23149         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
23150         not the default value.
23151
23152         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
23153         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
23154         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
23155         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
23156         Also check for iswcntrl, used for wcwidth fallback.
23157         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
23158         to Autoconf 2.13.
23159
23160 2001-08-03  Jim Meyering  <meyering@lucent.com>
23161
23162         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
23163         as it was in the original.  Reported by Paul Eggert.
23164
23165 2001-07-16  Jim Meyering  <meyering@lucent.com>
23166
23167         * m4/gettimeofday.m4: New file.
23168         Prompted by a report from Bernhard Baehr.
23169
23170 2001-07-15  Jim Meyering  <meyering@lucent.com>
23171
23172         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
23173         stuff. Now it's in ../Makefile.cfg.
23174
23175 2001-07-15  Jim Meyering  <meyering@lucent.com>
23176
23177         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
23178         (BUILT_SOURCES): Add unlocked-io.h.
23179         (io_functions): Define.
23180         (unlocked-io.h): New rule.
23181         (DISTCLEANFILES): Add unlocked-io.h.
23182         (all-local): Depend on unlocked-io.h, to ensure it is created.
23183
23184         * lib/unlocked-io.hin: New file
23185
23186         * lib/regex.c: Update from glibc.
23187
23188 2001-07-05  Jim Meyering  <meyering@lucent.com>
23189
23190         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
23191         recommendation.
23192         (libfetish_a_SOURCES): Put all .h files here instead.
23193         Remove a thus-exposed (better checks in automake) duplicate and
23194         two unnecessary .h files.
23195
23196 2001-07-04  Jim Meyering  <meyering@lucent.com>
23197
23198         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
23199         that generates jm-glibc-io.m4 so that it doesn't trigger any make
23200         distcheck failure.
23201
23202 2001-07-02  Jim Meyering  <meyering@lucent.com>
23203
23204         The following changes were prompted by suggestions from Bruno Haible.
23205
23206         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
23207         is now generated.
23208         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
23209         definition of EXTRA_DIST.
23210         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
23211         ensure that the generated file is created/updated whenever the list
23212         of $(unlocked_functions) is changed.
23213         (jm-glibc-io.m4): New rule.
23214         (unlocked-io.h): New rule -- currently unused.
23215
23216 2001-06-24  Jim Meyering  <meyering@lucent.com>
23217
23218         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
23219         unmatched right bracket, rather than kludging it with an extra,
23220         falsely-matching quote in a comment.  Patch by Akim Demaille.
23221
23222 2001-06-11  Jim Meyering  <meyering@lucent.com>
23223
23224         * lib/regex.c: Update from GNU libc.
23225
23226 2001-05-27  Jim Meyering  <meyering@lucent.com>
23227
23228         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
23229         Check for ut_type in struct utmp.
23230
23231 2001-05-27  Jim Meyering  <meyering@lucent.com>
23232
23233         * lib/readutmp.h (UT_TYPE): Define.
23234
23235 2001-05-24  Jim Meyering  <meyering@lucent.com>
23236
23237         * lib/argmatch.c: Include "quote.h".
23238         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
23239         quote function.  Reported by Göran Uddeborg.
23240
23241 2001-05-22  Jim Meyering  <meyering@lucent.com>
23242
23243         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
23244         now that we use the package-supplied version unconditionally.
23245         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
23246
23247 2001-05-21  Jim Meyering  <meyering@lucent.com>
23248
23249         * m4/regex.m4: Change a couple backticks to single quotes to avoid
23250         shell syntax errors.
23251
23252 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
23253
23254         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
23255
23256 2001-05-20  Paul Eggert  <eggert@twinsun.com>
23257
23258         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
23259         Don't bother to check library strftime, since
23260         we'll be using our own my_strftime function anyway.
23261         Define my_strftime instead of strftime.
23262
23263 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
23264
23265         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
23266         which is not yet declared.
23267
23268 2001-05-15  Jim Meyering  <meyering@lucent.com>
23269
23270         * m4/regex.m4: Use proper quoting so brackets appear in the test
23271         program.
23272         Reported by, and with help from, Bruno Haible.
23273
23274 2001-05-13  Jim Meyering  <meyering@lucent.com>
23275
23276         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
23277         undefined.
23278
23279 2001-05-11  Paul Eggert  <eggert@twinsun.com>
23280
23281         dirname code cleanup.  base_name now behaves more compatibly
23282         with POSIX basename when given file names that have trailing
23283         slashes, and similarly for dir_name.  Add new primitives
23284         base_len and dir_len.  Put the directory-name-related decls
23285         into dirname.h.
23286
23287         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
23288         * lib/backupfile.c (base_name): Likewise.
23289         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
23290         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
23291         * lib/makepath.c (strip_trailing_slashes): Likewise.
23292         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
23293         ISSLASH): Likewise.
23294         * lib/rename.c (strip_trailing_slashes): Likewise.
23295         * lib/same.c (base_name): Likewise.
23296         * lib/stripslash.c (ISSLASH): Likewise.
23297
23298         * lib/addext.c: Include <dirname.h> after size_t is defined.
23299         * lib/backupfile.c: Likewise.
23300
23301         * lib/addext.c (addext): Use base_len to trim redundant
23302         trailing slashes instead of doing it ourselves.
23303         But do not trim the last slash if it is not redundant.
23304
23305         * lib/backupfile.c (find_backup_file_name,
23306         max_backup_version): Use base_len instead of rolling it ourselves.
23307         Handle the case of "" and (on DOS) "C:" correctly.
23308
23309         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
23310         needed. Include <string.h>, <dirname.h>.
23311         (base_name): Allow file names ending in slashes, other than names
23312         that are all slashes.  In this case, return the basename followed
23313         by the slashes.  This is more general, and can be used in places
23314         where the original base_name purposely had an assertion failure.
23315         (base_len): New function.
23316
23317         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
23318         Do not include <assert.h>; no longer needed.
23319         Include xalloc.h.
23320         (memrchr): Remove decl.
23321         (dir_name_r): Remove.
23322         (dir_len): Renamed from dirlen.  All callers changed.
23323         Rewrite in terms of base_name, for simplicity and consistency.
23324         (dir_name): Never return NULL.  All callers changed.
23325         Do not include <stdlib.h> in test program; no longer needed.
23326         return 0; is fine for test program.
23327
23328         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
23329         New macros.
23330         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
23331
23332         * lib/path-concat.c (path_concat): Use base_len to compute
23333         base length, not strlen; this means we cannot rely on memcpy
23334         to null-terminate.
23335
23336         * lib/same.c (STREQ): Remove.
23337         (same_name): Handle the case where the basename ends in trailing '/'.
23338
23339         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
23340         a slash was stripped.  Do not strip the last slash after a
23341         file system prefix.
23342
23343 2001-05-11  Paul Eggert  <eggert@twinsun.com>
23344
23345         * lib/Makefile.am (libfetish_a_SOURCES):
23346         Add strftime.c, since we now compile it on all hosts.
23347
23348         * lib/strftime.c (my_strftime):
23349         Define to nstrftime if emacs, but only if my_strftime is not defined.
23350         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
23351         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
23352         Add one more extra argument: a nanoseconds value.
23353         All uses changed.
23354         (ns): New macro.
23355         (my_strftime function): Add %N format.
23356         (emacs_strftimeu): Renamed from emacs_strftime,
23357         with extra ut argument.
23358
23359 2001-05-09  Paul Eggert  <eggert@twinsun.com>
23360
23361         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
23362
23363 2001-04-21  Jim Meyering  <meyering@lucent.com>
23364
23365         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
23366         doesn't interfere.
23367
23368 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
23369
23370         * m4/ftruncate.m4: Check for chsize.
23371         Link with ftruncate.o unconditionally if ftruncate is missing.
23372         This was required when cross-compiling to i586-mingw32msvc.
23373
23374 2001-04-08  Jim Meyering  <meyering@lucent.com>
23375
23376         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
23377         recomputed; that's necessary when the offset spans a DST transition.
23378         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
23379
23380 2001-04-02  Jim Meyering  <meyering@lucent.com>
23381
23382         * lib/regex.h, regex.c: Update from GNU libc.
23383
23384 2001-03-24  Jim Meyering  <meyering@lucent.com>
23385
23386         * m4/jm-macros.m4: Require autoconf-2.49d.
23387
23388 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
23389
23390         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
23391
23392 2001-03-19  Paul Eggert  <eggert@twinsun.com>
23393
23394         * lib/version-etc.c (version_etc_copyright): Update to 2001.
23395
23396 2001-03-17  Jim Meyering  <meyering@lucent.com>
23397
23398         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
23399         now that the version in autoconf is equivalent.
23400         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
23401
23402         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
23403         Suggestion from Akim Demaille.
23404
23405         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
23406         (jm_PREREQ_TEMPNAME): New function.
23407
23408 2001-03-16  Paul Eggert  <eggert@twinsun.com>
23409
23410         * lib/tempname.c (uint64_t): Define to uintmax_t if
23411         not defined, and if UINT64_MAX is not defined.
23412         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
23413         Reported by John David Anglin.
23414
23415 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
23416
23417         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
23418         resolve alias if codeset is empty.
23419         * lib/config.charset (BeOS): Use wildcard syntax.
23420
23421 2001-03-13  Jim Meyering  <meyering@lucent.com>
23422
23423         * lib/path-concat.c (path_concat)
23424         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
23425         concatenating e.g., `C:' and `foo'.
23426         From Bruno Haible.
23427
23428 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
23429
23430         * lib/localcharset.c (locale_charset): Don't use
23431         setlocale(LC_CTYPE,NULL). Don't return NULL.
23432         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
23433
23434 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
23435
23436         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
23437         support for DOS/DJGPP.
23438
23439 2001-03-01  Paul Eggert  <eggert@twinsun.com>
23440
23441         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
23442         lacks mkstemp.  Compile our own tempname.c if we compile our own
23443         mkstemp.c, as mkstemp relies on tempname.
23444
23445 2001-03-01  Jim Meyering  <meyering@lucent.com>
23446
23447         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
23448         AH_VERBATIM really does output its argument verbatim.
23449
23450 2001-02-28  Paul Eggert  <eggert@twinsun.com>
23451
23452         * lib/Makefile.am (libfetish_a_SOURCES):
23453         Add dup-safer.c, fopen-safer.c.
23454         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
23455
23456         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
23457         * lib/unistd-safer.h: New files.
23458
23459 2001-02-25  Paul Eggert  <eggert@twinsun.com>
23460
23461         The mkstemp replacement is taken from glibc 2.2.2, with some
23462         portability fixes for use outside glibc, as follows:
23463
23464         * lib/tempname.c (struct_stat64): New macro.
23465         (direxists, __gen_tempname): Use it.
23466         This avoids a portability problem with Solaris 8.
23467
23468         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
23469         (<stddef.h>, <stdint.h>, <string.h>):
23470         Include only if STDC_HEADERS || _LIBC.
23471         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
23472         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
23473         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
23474         (__set_errno): Define this macro if <errno.h> doesn't.
23475         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
23476         Define these macros if <stdio.h> doesn't.
23477         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
23478         Define these macros if <sys/stat.h>
23479         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
23480         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
23481         __xstat64): Define if not _LIBC.
23482         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
23483         (__gen_tempname): Invoke gettimeofday only if
23484         HAVE_GETTIMEOFDAY || _LIBC;
23485         otherwise, fall back on plain "time".
23486         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
23487
23488         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
23489
23490         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
23491
23492 2001-02-18  Paul Eggert  <eggert@twinsun.com>
23493
23494         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
23495
23496 2001-02-17  Paul Eggert  <eggert@twinsun.com>
23497
23498         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
23499         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
23500         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
23501         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
23502
23503 2001-02-17  Paul Eggert  <eggert@twinsun.com>
23504
23505         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
23506         Remove workaround macros for hosts that have mbrtowc but not
23507         mbstate_t, as we now insist on proper declarations for both
23508         before using mbrtowc.
23509
23510 2001-02-17  Jim Meyering  <meyering@lucent.com>
23511
23512         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
23513         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
23514         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
23515         UnixWare 7.1.1.
23516
23517         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
23518         rather than AC_CACHE_VAL.
23519
23520 2001-02-17  Jim Meyering  <meyering@lucent.com>
23521
23522         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
23523         around included file name.
23524
23525         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
23526
23527         * lib/strftime.c: Update from GNU libc (the only changes were to
23528         comments).
23529
23530 2001-02-17  Jim Meyering  <meyering@lucent.com>
23531
23532         * lib/regex.c: Update from libc.
23533
23534 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
23535
23536         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
23537         clash.
23538
23539 2001-02-16  Paul Eggert  <eggert@twinsun.com>
23540
23541         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
23542         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
23543         Reported by Mark Hounschell via Paul Eggert.
23544
23545 2001-02-07  Jim Meyering  <meyering@lucent.com>
23546
23547         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
23548
23549 2001-02-05  Jim Meyering  <meyering@lucent.com>
23550
23551         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
23552         it includes the patch required for `large file' support with at least
23553         HP-UX's 10.20 /bin/cc.
23554
23555 2001-02-03  Jim Meyering  <meyering@lucent.com>
23556
23557         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
23558         AS_IF, now that it works once again (mysteriously).
23559         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
23560
23561 2001-01-30  Jim Meyering  <meyering@lucent.com>
23562
23563         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
23564         * m4/chown.m4: Rename conftestchown to conftest.chown.
23565         * m4/rename.m4: s/conftestdir/conftest.d1/ and
23566         s/conftestdir2/conftest.d2/.
23567         * m4/utimes.m4: s/conftestdata/conftest.data/
23568         Inspired by Pavel Roskin's change in autoconf.
23569
23570 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
23571
23572         * lib/config.charset: Update for FreeBSD 4.2.
23573
23574 2001-01-27  Jim Meyering  <meyering@lucent.com>
23575
23576         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
23577         a use of AS_IF.
23578         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
23579
23580 2001-01-26  Jim Meyering  <meyering@lucent.com>
23581
23582         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
23583         quotearg.c includes it.
23584
23585 2001-01-26  Jim Meyering  <meyering@lucent.com>
23586
23587         * lib/quotearg.c: Include stddef.h.
23588         * lib/quote.c: Include stddef.h.
23589         Reported by Axel Kittenberger.
23590
23591         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
23592         line in double quotes so that it evokes a better diagnostic.
23593         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
23594         Reported by Axel Kittenberger.
23595
23596 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
23597
23598         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
23599         as if it was a `charset'.
23600
23601 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
23602
23603         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
23604         has const.
23605
23606 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
23607
23608         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
23609         to avoid a warning.  Add back 'const' to inptr.
23610
23611 2001-01-20  Jim Meyering  <meyering@lucent.com>
23612
23613         Be sure that headers are checked before used in code compiled
23614         for the type checks.
23615         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
23616         In place of that, invoke jm_CHECK_ALL_TYPES.
23617         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
23618         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
23619         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
23620         The check for ssize_t was mistakenly run before the test for unistd.h.
23621
23622         The configure-time check for stdbool.h was missing.
23623         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
23624         (jm_PREREQ_HASH): New function.
23625
23626 2001-01-17  Jim Meyering  <meyering@lucent.com>
23627
23628         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
23629         for autoconf-2.49c.
23630         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
23631
23632 2001-01-16  Jim Meyering  <meyering@lucent.com>
23633
23634         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
23635         From Bruno Haible.
23636
23637 2001-01-14  Jim Meyering  <meyering@lucent.com>
23638
23639         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
23640         foo and bar.  Create conftestdir/ in the script, not in the C code.
23641         Remove directories in the script, not in the C code.
23642         Remove conftestdir{,2} before trying to create the directory.
23643         Make the entire configure script fail if the mkdir fails.
23644
23645 2001-01-14  Jim Meyering  <meyering@lucent.com>
23646
23647         * lib/rename.c: New file.  From Volker Borchert.
23648         Include stdlib.h, string.h or strings.h, and xalloc.h.
23649         Use strip_trailing_slashes rather than open-coding it.
23650
23651 2001-01-03  Paul Eggert  <eggert@twinsun.com>
23652
23653         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
23654
23655 2001-01-03  Jim Meyering  <meyering@lucent.com>
23656
23657         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
23658         of local `inptr' to avoid warning with some system declarations of
23659         iconv.
23660
23661 2001-01-02  Volker Borchert  <bt@teknon.de>
23662
23663         * m4/rename.m4: New file.
23664         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
23665
23666 2001-01-01  Jim Meyering  <meyering@lucent.com>
23667
23668         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
23669         even on systems with utmpx.h.  It's necessary for the declaration of
23670         utmp's ut_user member.  Reported by Andreas Jaeger.
23671
23672         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
23673         available. They are required for the declarations of getgrgid and
23674         getpwuid resp.
23675         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
23676         Reported by Andreas Jaeger.
23677
23678 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
23679
23680         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
23681         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
23682         so `make install' also works in VPATH builds.
23683
23684 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
23685
23686         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
23687         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
23688         can be used in subdirectories.
23689
23690 2000-12-29  Paul Eggert  <eggert@twinsun.com>
23691
23692         * lib/modechange.c: Do not assume that mode_t uses the
23693         traditional octal encoding.  E.g. "chmod 1 FOO" should set
23694         the other-execute bit of FOO even if S_IXOTH != 1.
23695
23696         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
23697         WOTH, XOTH, ALLM): New macros.
23698         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
23699          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
23700         Use them.
23701         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
23702         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
23703         (mode_compile):
23704         No need to use uintmax_t; unsigned long is long enough.
23705         Don't bother to get suffix since we don't use it.
23706
23707 2000-12-26  Jim Meyering  <meyering@lucent.com>
23708
23709         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
23710         better with autoheader.
23711
23712 2000-12-24  Jim Meyering  <meyering@lucent.com>
23713
23714         * lib/hash.c (is_prime): Return explicit boolean values.
23715         (hash_get_first): Return NULL to appease Irix5.6's 89.
23716         Reported by Nelson Beebe.
23717
23718 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
23719
23720         * lib/localcharset.c (locale_charset): Add support for Win32.
23721
23722 2000-12-18  Paul Eggert  <eggert@twinsun.com>
23723
23724         * lib/physmem.h, lib/physmem.c: New files.
23725
23726         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
23727         (noinst_HEADERS): Add physmem.h.
23728
23729         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
23730         't' for compatibility with Solaris 8 sort.
23731
23732 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
23733
23734         * lib/config.charset: Add support for BeOS.
23735
23736 2000-12-17  Jim Meyering  <meyering@lucent.com>
23737
23738         * m4/dos.m4 (jm_AC_DOS): New file and macro.
23739         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
23740
23741 2000-12-16  Jim Meyering  <meyering@lucent.com>
23742
23743         This bug had a serious impact on chown: `chown N:M FILE' (for integer
23744         N and M) would have treated it like `chown N:N FILE'.
23745
23746         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
23747
23748 2000-12-16  Jim Meyering  <meyering@lucent.com>
23749
23750         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
23751         SHELLS_FILE to a file name that's useful on djgpp systems.
23752         Include stdlib.h.
23753         (ADDITIONAL_DEFAULT_SHELLS): Define.
23754         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
23755         Based mostly on a patch from Prashant TR.
23756
23757 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
23758
23759         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
23760         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
23761         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
23762
23763 2000-12-08  Andreas Schwab  <schwab@suse.de>
23764
23765         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
23766         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
23767
23768 2000-12-07  Jim Meyering  <meyering@lucent.com>
23769
23770         * lib/stripslash.c (ISSLASH): Define.
23771         (strip_trailing_slashes): Use ISSLASH rather than comparing against
23772         `/'.
23773         From Prashant TR.
23774
23775         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
23776         (dir_name_r): Declare this function as static.
23777         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
23778         manifest itself on a name containing a mix of slashes and
23779         backslashes.
23780         Make this function work with names starting with a DOS-style
23781         drive letter and colon prefix.
23782         (dir_name): Append `.' if necessary.
23783         Based mostly on patches from Prashant TR and Eli Zaretskii.
23784
23785         * lib/dirname.h (dir_name_r): Remove prototype.
23786
23787 2000-12-06  Paul Eggert  <eggert@twinsun.com>
23788
23789         * m4/off_t-format.m4: Remove this file.
23790         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
23791
23792 2000-12-06  Jim Meyering  <meyering@lucent.com>
23793
23794         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
23795         replacement strtoull, we may well need the replacement strtoul, too.
23796         Check for declarations of strtoul and strtoull.
23797         Check for strtol.  Mainly as a cue to cause automake to include
23798         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
23799         Check for limits.h -- strtol.c needs it.
23800
23801 2000-12-05  Jim Meyering  <meyering@lucent.com>
23802
23803         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
23804
23805 2000-12-04  Jim Meyering  <meyering@lucent.com>
23806
23807         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
23808         Also include memory.h, stdlib.h, unistd.h if appropriate.
23809         Reported by Andreas Jaeger (conflicting declaration of malloc).
23810
23811 2000-12-02  Jim Meyering  <meyering@lucent.com>
23812
23813         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
23814         * m4/jm-macros.m4 (jm_MACROS): require it.
23815
23816 2000-12-02  Jim Meyering  <meyering@lucent.com>
23817
23818         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
23819
23820 2000-12-01  Paul Eggert  <eggert@twinsun.com>
23821
23822         * lib/memrchr.c: Include <config.h> before any system include file.
23823
23824 2000-11-30  Jim Meyering  <meyering@lucent.com>
23825
23826         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
23827
23828 2000-11-30  Jim Meyering  <meyering@lucent.com>
23829
23830         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
23831
23832 2000-11-29  Paul Eggert  <eggert@twinsun.com>
23833
23834         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
23835
23836 2000-11-26  Jim Meyering  <meyering@lucent.com>
23837
23838         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
23839
23840 2000-11-22  Paul Eggert  <eggert@twinsun.com>
23841
23842         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
23843         size of (size_t) -1; it's not portable.
23844
23845 2000-11-17  Jim Meyering  <meyering@lucent.com>
23846
23847         * lib/strstr.c: Update from GNU libc.
23848
23849 2000-11-17  Akim Demaille  <akim@epita.fr>
23850
23851         * lib/obstack.h: Formatting changes.
23852         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
23853         prevent type checking.
23854         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
23855         cast the value to (void *): assigning a `foo *' to a `void *'
23856         variable is valid.
23857         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
23858
23859 2000-11-16  Jim Meyering  <meyering@lucent.com>
23860
23861         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
23862
23863 2000-11-11  Jim Meyering  <meyering@lucent.com>
23864
23865         * lib/error.c: Add a couple #includes, merging from GNU libc version.
23866
23867 2000-11-10  Jim Meyering  <meyering@lucent.com>
23868
23869         * lib/obstack.h: Update from GNU libc.
23870         * lib/obstack.c: Likewise.
23871
23872 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
23873
23874         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
23875
23876 2000-11-06  Paul Eggert  <eggert@twinsun.com>
23877
23878         * lib/getusershell.c (setusershell): Use rewind rather than
23879         fseek/fseeko, to avoid configuration hassles with fseeko.
23880         Don't bother opening SHELLS_FILE if shellstream is NULL;
23881         it's not necessary.
23882
23883 2000-11-05  Jim Meyering  <meyering@lucent.com>
23884
23885         * lib/makepath.h (make_dir): Declare.
23886         * lib/makepath.c (make_dir): Remove `static' attribute.
23887         Tweak a comment.
23888
23889 2000-11-04  Jim Meyering  <meyering@lucent.com>
23890
23891         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
23892
23893 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
23894
23895         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
23896         last one in a bucket, advance to the next bucket.
23897
23898 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
23899
23900         * lib/fnmatch.c: Do not comment out all the code if we are using
23901         the GNU C library, because in some cases we are replacing buggy
23902         code in the GNU C library itself.
23903
23904 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
23905
23906         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
23907         (regex_compile): Catch bogus \(\1\).
23908
23909 2000-10-30  Paul Eggert  <eggert@twinsun.com>
23910
23911         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
23912         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
23913         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
23914
23915 2000-10-30  Paul Eggert  <eggert@twinsun.com>
23916
23917         * lib/error.h, getline.h, modechange.h:
23918         Remove "2000" from Copyright line, as the file hasn't been
23919         changed this year other than in the copyright notice.
23920
23921         * lib/xalloc.h: Add "2000" to Copyright line, as this file
23922         was changed this year.
23923
23924 2000-10-29  Jim Meyering  <meyering@lucent.com>
23925
23926         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
23927         renaming.
23928         * m4/ls-mntd-fs.m4: Likewise
23929
23930 2000-10-29  Jim Meyering  <meyering@lucent.com>
23931
23932         * lib/xstat.in: Fix grammar in comment.
23933
23934 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
23935
23936         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
23937         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
23938         doesn't define __restrict_arr.
23939
23940 2000-10-28  Jim Meyering  <meyering@lucent.com>
23941
23942         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
23943         (jm_PREREQ_MEMCHR): New function.
23944
23945 2000-10-28  Jim Meyering  <meyering@lucent.com>
23946
23947         * lib/memchr.c: Update from libc.
23948         Adjust for portability:
23949         [HAVE_STDLIB_H]: Include stdlib.h.
23950         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
23951         Undef __memchr, too.
23952         [!weak_alias]: Define __memchr to memchr.
23953
23954         * lib/regex.c: Update from libc.
23955         * lib/regex.h: Likewise.
23956         * lib/getopt1.c: Likewise.
23957         * lib/memcmp.c: Likewise.
23958
23959         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
23960         Avoid using fseek, when possible -- it's broken by design.
23961         Patch by Ulrich Drepper.
23962
23963 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
23964
23965         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
23966         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
23967         Giving in to popular pressure to shut up the compiler with casts.
23968
23969 2000-10-26  Jim Meyering  <meyering@lucent.com>
23970
23971         * lib/strftime.c: Update from libc.
23972
23973 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
23974
23975         * regex.c: More `unsigned char' -> `re_char' changes.
23976         Also change several `int' into `re_wchar_t'.
23977         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
23978         (PUSH_FAILURE_POINTER): Don't cast any more.
23979         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
23980         We want GCC to complain, since this piece of code makes
23981         re_match non-reentrant, which *should* be fixed.
23982         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
23983         (EXTEND_BUFFER): Use RETALLOC.
23984         (SET_LIST_BIT): Don't cast.
23985         (re_wchar_t): New type.
23986         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
23987         that those two functions will always properly return.
23988         (IMMEDIATE_QUIT_CHECK): Cast to void.
23989         (analyse_first): Use recursion rather than an explicit stack.
23990         (re_compile_fastmap): Can't fail anymore.
23991         (re_search_2): Don't check re_compile_fastmap for failure.
23992         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
23993         Now also sets the new value (passed in a new argument).
23994         (re_match_2_internal): Use it.
23995         Also, use a new var `reg' of type size_t when looping through regs
23996         rather than reuse the inappropriate `mcnt'.
23997
23998 2000-10-25  Jim Meyering  <meyering@lucent.com>
23999
24000         * lib/obstack.c: Update from libc.
24001
24002 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
24003
24004         * regex.c (regex_compile): Change the way of handling a range from
24005         a char less than 256 to a char not less than 256.
24006
24007 2000-10-24  Andrew Innes  <andrewi@gnu.org>
24008
24009         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
24010         NT-Emacs only.
24011         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
24012         so that re_search functions only quit when callers expect them to.
24013
24014 2000-10-23  Jim Meyering  <meyering@lucent.com>
24015
24016         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
24017         wrong.  That set_locale call must not have any side effects.
24018         From Paul Eggert.
24019
24020 2000-10-22  Jim Meyering  <meyering@lucent.com>
24021
24022         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
24023         [CYCLIC]: Remove now-unused definition.
24024
24025         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
24026         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
24027         Suggestion from Ulrich Drepper.
24028
24029 2000-10-21  Jim Meyering  <meyering@lucent.com>
24030
24031         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
24032         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
24033         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
24034
24035 2000-10-21  Jim Meyering  <meyering@lucent.com>
24036
24037         * lib/dirname.c (memrchr): Declare if necessary.
24038         (dir_name): Remove the restriction that there be no
24039         trailing slashes.  Now, this code skips past them, effectively
24040         ignoring them.
24041         [TEST_DIRNAME] (main): New unit tests.
24042
24043         * lib/memrchr.c: New file from GNU libc.
24044         Undef __memrchr, too.
24045         [!weak_alias]: Define __memrchr to memrchr.
24046         Guard weak_alias use with `#ifdef weak_alias'.
24047
24048 2000-10-21  Jim Meyering  <meyering@lucent.com>
24049
24050         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
24051         (dir_name): Use dir_name_r.
24052         * lib/dirname.h (dir_name_r): Declare it.
24053
24054 2000-10-17  Jim Meyering  <meyering@lucent.com>
24055
24056         * lib/quote.h (PARAMS): Define and use.
24057         Reported by Akim Demaille.
24058
24059         * lib/getopt.c: Update from libc.
24060
24061 2000-10-16  Jim Meyering  <meyering@lucent.com>
24062
24063         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
24064         setlocale.
24065         From Jan Fedak.
24066
24067 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
24068
24069         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
24070
24071 2000-09-25  Jim Meyering  <meyering@lucent.com>
24072
24073         * lib/md5.h (rol): Define (from GnuPG).
24074
24075         * lib/sha.c: Give credit (GnuPG) where due.
24076         (M): Use rol rather than open-coding it.
24077         Add a FIXME comment.
24078
24079 2000-09-21  Jim Meyering  <meyering@lucent.com>
24080
24081         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
24082         Reported by Michael Stone.
24083
24084 2000-09-20  Jim Meyering  <meyering@lucent.com>
24085
24086         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
24087         (noinst_HEADERS): Add sha.h.
24088         Based on code from Scott G. Miller and from GnuPG.
24089
24090 2000-09-18  Jim Meyering  <meyering@lucent.com>
24091
24092         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
24093         LIBS. Otherwise, everyone ends up linking with -lelf for some
24094         configurations.
24095         Reported by Mike Stone.
24096
24097 2000-09-15  Jim Meyering  <meyering@lucent.com>
24098
24099         * lib/regex.c: Update from libc.
24100
24101 2000-09-10  Jim Meyering  <meyering@lucent.com>
24102
24103         * lib/getopt.c (_getopt_internal): Update from glibc.
24104
24105 2000-09-09  Jim Meyering  <meyering@lucent.com>
24106
24107         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
24108         think it should be used as a general replacement for isascii.
24109         * lib/fnmatch.c: Likewise.
24110         * lib/mbswidth.c: Likewise
24111         * lib/regex.c: Likewise.
24112
24113         Don't use atoi.
24114         * lib/userspec.c: Include sys/param.h and limits.h.
24115         Include xstrtol.h.
24116         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
24117         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
24118         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
24119         UID, GID.  Check range.
24120
24121 2000-09-06  Jim Meyering  <meyering@lucent.com>
24122
24123         * lib/getopt.c (_getopt_internal): Update from glibc.
24124
24125 2000-08-30  Jim Meyering  <meyering@lucent.com>
24126
24127         * lib/strftime.c: Merge in changes from GNU libc.
24128
24129 2000-08-26  Jim Meyering  <meyering@lucent.com>
24130
24131         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
24132         * m4/fpending.m4: New file.
24133
24134 2000-08-26  Jim Meyering  <meyering@lucent.com>
24135
24136         * lib/closeout.c: Include "__fpending.h".
24137         (close_stdout_status): Return right away if there's nothing to flush.
24138
24139         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
24140         * lib/__fpending.c: New file.
24141         * lib/__fpending.h: New file.
24142
24143 2000-08-20  Jim Meyering  <meyering@lucent.com>
24144
24145         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
24146         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
24147         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
24148
24149 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
24150
24151         Improve fileutils installation on systems where running
24152         programs (like install) can't be unlinked.
24153         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
24154         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
24155
24156 2000-08-07  Paul Eggert  <eggert@twinsun.com>
24157
24158         Standardize on "memory exhausted" instead of "Memory exhausted"
24159         or "virtual memory exhausted".
24160         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
24161         "virtual memory exhausted".
24162         * lib/same.c (same_name): Invoke xalloc_die instead of printing
24163         our own message.
24164         * lib/userspec.c (parse_user_spec): Likewise.
24165         * lib/bumpalloc.h: comment fix
24166         * lib/same.c, userspec.c: Include xalloc.h.
24167
24168         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
24169         not char *const and pointing to a constant array.
24170         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
24171         (xrealloc): Comment fix.
24172
24173         * lib/userspec.c (parse_user_spec):
24174         Don't translate a message until just before returning,
24175         to avoid unnecessary translation.
24176
24177 2000-08-07  Jim Meyering  <meyering@lucent.com>
24178
24179         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
24180         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
24181         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
24182         getgroups.c, gethostname.c, getopt.h, group-member.c,
24183         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
24184         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
24185         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
24186         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
24187         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
24188         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
24189         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
24190         yesno.c: Back out Copyright date changes for each file with no change
24191         this year.  This eases coordination with other programs using the same
24192         source code modules.  From Paul Eggert.
24193
24194 2000-08-06  Paul Eggert  <eggert@twinsun.com>
24195
24196         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
24197         not char, for compatibility with glibc 2.1.3 strftime.c.
24198
24199 2000-08-03  Greg McGary  <greg@mcgary.org>
24200
24201         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
24202         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
24203         (EXTEND_BUFFER): Use them.
24204
24205 2000-08-01  Jim Meyering  <meyering@lucent.com>
24206
24207         * lib/dirname.c (ISSLASH): Define.
24208         (BACKSLASH_IS_PATH_SEPARATOR): Define.
24209         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
24210         both `\' and `/' may be use as path separators.
24211         Based on a patch from Prashant TR.
24212
24213 2000-07-31  Paul Eggert  <eggert@twinsun.com>
24214
24215         * lib/quotearg.c (quotearg_n_options): Don't make the initial
24216         slot vector a constant, since it might get modified.
24217
24218 2000-07-31  Jim Meyering  <meyering@lucent.com>
24219
24220         * lib/xmalloc.c: Use `virtual memory exhausted', not
24221         `Memory exhausted'.
24222         * lib/obstack.c (print_and_abort): Likewise.
24223
24224 2000-07-30  Paul Eggert  <eggert@twinsun.com>
24225
24226         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
24227         buffer, so that the caller can always quote one small
24228         component of a "memory exhausted" message in slot 0.
24229         From a suggestion by Jim Meyering.
24230
24231 2000-07-30  Jim Meyering  <meyering@lucent.com>
24232
24233         * lib/makepath.c (make_path): Quote the other instance, too.
24234
24235         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
24236         (STATIC_BUF_SIZE): Define.
24237         (quotearg_n_options): Use only statically allocated storage when
24238         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
24239         than STATIC_BUF_SIZE.
24240
24241 2000-07-29  Jim Meyering  <meyering@lucent.com>
24242
24243         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
24244         * lib/dirname.c (dir_name): Likewise.
24245
24246         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
24247         `/'.
24248
24249         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
24250         (dir_name): Assert that there are no trailing slashes.
24251
24252 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
24253
24254         * lib/mbswidth.h (mbswidth): Add a flags argument.
24255         (mbswidth): New declaration.
24256         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
24257         * lib/mbswidth.c (mbswidth): Add a flags argument.
24258         (mbsnwidth): New function.
24259
24260 2000-07-24  Jim Meyering  <meyering@lucent.com>
24261
24262         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
24263
24264 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24265
24266         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
24267
24268 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24269
24270         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
24271         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
24272         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
24273         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
24274         invoke multibyte primitives.
24275
24276 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24277
24278         * lib/quotearg.c:
24279         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
24280         so that mbstate_t is always defined.
24281
24282         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
24283         be 1 in at least one GCC installation, and this configuration
24284         error is likely to be common.  Ignoring MB_LEN_MAX hurts
24285         performance on hosts that have mbrtowc but have only unibyte
24286         locales, but I assume these hosts are rare.
24287
24288 2000-07-23  Paul Eggert  <eggert@twinsun.com>
24289
24290         * lib/mbswidth.c (_XOPEN_SOURCE):
24291         Don't define; this causes problems on Solaris 7.
24292         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
24293
24294 2000-07-23  Jim Meyering  <meyering@lucent.com>
24295
24296         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
24297         too: getgrgid, getpwuid, getuid.
24298
24299 2000-07-23  Jim Meyering  <meyering@lucent.com>
24300
24301         * lib/basename.c (base_name): Add an assertion.
24302
24303 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
24304
24305         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
24306         shadow its mbsinit function.
24307
24308 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
24309
24310         * lib/mbswidth.h: New file.
24311         * lib/mbswidth.c: New file.
24312         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
24313         (noinst_HEADERS): Add mbswidth.h.
24314
24315 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
24316
24317         * lib/config.charset: Add support for FreeBSD. Improve support for
24318         HP-UX and IRIX 6.
24319
24320 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
24321
24322         * m4/mbswidth.m4: New file.
24323         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
24324
24325 2000-07-15  Jim Meyering  <meyering@lucent.com>
24326
24327         * lib/makepath.c: Include quote.h.
24328         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
24329         corresponding argument in a `quote (...)' call.
24330         Give better diagnostics.
24331
24332         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
24333         (noinst_HEADERS): Add quote.h.
24334
24335         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
24336         from tar's src/misc.c.
24337         * lib/quote.h: New file.  Prototypes for same.
24338
24339 2000-07-14  Paul Eggert  <eggert@twinsun.com>
24340
24341         From a suggestion by Bruno Haible.
24342         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
24343         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
24344         to decide whether to define the BeOS workaround macro;
24345         this adjusts to the change to AC_MBSTATE_T.
24346
24347 2000-07-14  Jim Meyering  <meyering@lucent.com>
24348
24349         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
24350         jm_AC_TYPE_UINTMAX_T.
24351
24352 2000-07-13  Paul Eggert  <eggert@twinsun.com>
24353
24354         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
24355
24356         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
24357         quotearg_buffer_restyled): Add support for
24358         clocale_quoting_style.  Undo previous change to
24359         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
24360         and "{RIGHT QUOTATION MARK}" msgids.
24361
24362 2000-07-10  Paul Eggert  <eggert@twinsun.com>
24363
24364         From a suggestion by Bruno Haible.
24365         * m4/mbstate_t.m4 (AC_MBSTATE_T):
24366         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
24367         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
24368         and mbstate_t, to a single-part test that simply defines mbstate_t.
24369         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
24370         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
24371
24372 2000-07-10  Jim Meyering  <meyering@lucent.com>
24373
24374         * m4/strerror_r.m4: Mirror the correction made in autoconf.
24375
24376         * m4/gnu-source.m4: Output to confdefs.h directly.
24377         Suggestion from Akim Demaille.
24378
24379 2000-07-09  Paul Eggert  <eggert@twinsun.com>
24380
24381         The old behavior of quoting `like this' doesn't look good with
24382         newer, ISO-style fonts.  See:
24383         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
24384
24385         Instead, quote "like this" by default.  Let the translator
24386         tailor the locale-specific quoting behavior by providing
24387         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
24388
24389         * lib/quotearg.c (N_): New macro.
24390         (gettext_default): New function.
24391         (quotearg_buffer_restyled): Use
24392         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
24393         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
24394
24395 2000-07-09  Jim Meyering  <meyering@lucent.com>
24396
24397         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
24398         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
24399
24400         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
24401         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
24402
24403 2000-07-09  Jim Meyering  <meyering@lucent.com>
24404
24405         * lib/Most files: Update copyright dates to include 2000.
24406
24407 2000-07-08  Jim Meyering  <meyering@lucent.com>
24408
24409         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
24410         if not defined.
24411         (xgethostname): Remove now-unnecessary #ifdef.
24412         Move declaration of `err' into loop where it's used.
24413
24414 2000-07-05  Paul Eggert  <eggert@twinsun.com>
24415         and Bruno Haible  <haible@clisp.cons.org>
24416
24417         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
24418         only if the test for an object-type mbstate_t fails.  This
24419         prevents us from mistakenly reporting that mbstate_t is a
24420         system object type after we "#define mbstate_t int" to work
24421         around its lack.
24422
24423 2000-07-05  Paul Eggert  <eggert@twinsun.com>
24424         and Bruno Haible  <haible@clisp.cons.org>
24425
24426         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
24427
24428 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24429
24430         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
24431         to strerror_r.
24432         Include <ctype.h> for use of isalpha.
24433
24434 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24435
24436         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
24437         by allocating a larger buffer. Test the gethostname return value for
24438         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
24439         returns an error and ENAMETOOLONG isn't defined.
24440
24441 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
24442
24443         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
24444         dimension.
24445
24446 2000-07-04  Jim Meyering  <meyering@lucent.com>
24447
24448         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
24449         of the deprecated AC_CHECKING.
24450
24451 2000-07-04  Jim Meyering  <meyering@lucent.com>
24452
24453         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
24454         Reported by Bruno Haible.
24455
24456 2000-07-04  Jim Meyering  <meyering@lucent.com>
24457
24458         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
24459         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
24460         lacks mbrtowc.
24461
24462 2000-07-03  Paul Eggert  <eggert@twinsun.com>
24463
24464         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
24465         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
24466
24467 2000-07-03  Paul Eggert  <eggert@twinsun.com>
24468         and Bruno Haible  <haible@clisp.cons.org>
24469
24470         * lib/quotearg.c (mbrtowc):
24471         Assign to *pwc, and return 1 only if result is nonzero.
24472         (iswprint): Use ISPRINT when substituting our own mbrtowc.
24473
24474 2000-07-03  Jim Meyering  <meyering@lucent.com>
24475
24476         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
24477
24478 2000-07-03  Jim Meyering  <meyering@lucent.com>
24479
24480         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
24481         This is necessary to get a definition of e.g., UTMP_FILE on
24482         HP-UX 10.20.
24483         From Bob Proulx.
24484
24485 2000-07-02  Jim Meyering  <meyering@lucent.com>
24486
24487         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
24488
24489         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
24490         AC_LIBOBJ(function_name).
24491         * m4/chown.m4: Likewise.
24492         * m4/fnmatch.m4: Likewise.
24493         * m4/ftruncate.m4: Likewise.
24494         * m4/getgroups.m4: Likewise.
24495         * m4/getline.m4: Likewise.
24496         * m4/group-member.m4: Likewise.
24497         * m4/jm-macros.m4: Likewise.
24498         * m4/lstat.m4: Likewise.
24499         * m4/malloc.m4: Likewise.
24500         * m4/memcmp.m4: Likewise.
24501         * m4/nanosleep.m4: Likewise.
24502         * m4/putenv.m4: Likewise.
24503         * m4/realloc.m4: Likewise.
24504         * m4/regex.m4: Likewise.
24505         * m4/stat.m4: Likewise.
24506         * m4/strftime.m4: Likewise.
24507
24508 2000-07-02  Jim Meyering  <meyering@lucent.com>
24509
24510         * lib/quotearg.c (mbstate_t): Don't define here.
24511
24512 2000-07-02  Jim Meyering  <meyering@lucent.com>
24513
24514         * lib/nanosleep.c (SIGCONT): Define if not already defined.
24515
24516 2000-07-01  Jim Meyering  <meyering@lucent.com>
24517
24518         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
24519
24520 2000-07-01  Jim Meyering  <meyering@lucent.com>
24521
24522         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
24523         problem.
24524
24525 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
24526
24527         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
24528         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
24529
24530 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
24531
24532         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
24533         per change in ../m4/ls-mntd-fs.m4.
24534         (read_filesystem_list): Ignore symbolic links.
24535
24536 2000-06-29  Jim Meyering  <meyering@lucent.com>
24537
24538         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
24539         for declaration of strcmp.
24540
24541         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
24542
24543         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
24544         Avoid warning by casting result to `char *' to remove `const'.
24545
24546 2000-06-28  Jim Meyering  <meyering@lucent.com>
24547
24548         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
24549         included by quotearg.c, for which we perform this test.  From
24550         Bruno Haible.
24551
24552 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
24553
24554         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
24555         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
24556         <utmpx.h> exists, put readutmp.o into LIBOBJS.
24557
24558 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
24559
24560         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
24561
24562 2000-06-26  Paul Eggert  <eggert@twinsun.com>
24563
24564         savedir now sets errno on failure and invokes xmalloc to get memory.
24565         Fix a couple of other minor bugs while we're at it.
24566
24567         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
24568         (NAMLEN): Remove macro.
24569         (malloc, realloc): Remove decls.
24570         (stpcpy): Likewise.
24571         ("xalloc.h"): Include.
24572         (NAME_SIZE_DEFAULT): New macro.
24573         (savedir): Use xmalloc / xrealloc to allocate memory.
24574         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
24575         Skip "" directory entries.
24576         Use strlen to calculate directory entry length, since the old method
24577         is rarely used these days and isn't worth supporting.
24578         Don't use a pointer after freeing it.
24579         Check for integer overflow when calculating allocation size.
24580         Use memcpy to copy entries, instead of stpcpy.
24581         Set errno properly when returning NULL.
24582         Check for readdir error.
24583
24584 2000-06-26  Jim Meyering  <meyering@lucent.com>
24585
24586         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
24587
24588 2000-06-25  Jim Meyering  <meyering@lucent.com>
24589
24590         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
24591         Linux header bug when _XOPEN_SOURCE is defined to 500.
24592
24593 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
24594
24595         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
24596         deficiency.
24597
24598 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
24599
24600         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
24601         Include xalloc.h.
24602         Don't include <stdlib.h>.  Don't declare malloc, realloc.
24603
24604 2000-06-24  Jim Meyering  <meyering@lucent.com>
24605
24606         * m4/strerror_r.m4: Revive this file -- to try out an experimental
24607         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
24608         for which strerror does return char*, but which lacks a conveniently
24609         accessible declaration of the function.  If the compile-test says
24610         strerror_r doesn't work, then resort to a `run'-test that works on
24611         BeOS and segfaults on DEC Unix.
24612
24613 2000-06-24  Jim Meyering  <meyering@lucent.com>
24614
24615         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
24616
24617 2000-06-23  Paul Eggert  <eggert@twinsun.com>
24618
24619         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
24620         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
24621
24622 2000-06-23  Paul Eggert  <eggert@twinsun.com>
24623
24624         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
24625         (mbrtowc, mbstate_t): Define substitutes if
24626         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
24627         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
24628         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
24629
24630 2000-06-23  Jim Meyering  <meyering@lucent.com>
24631
24632         * m4/afs.m4: Add missing AC_MSG_RESULT.
24633         Reported by Bruno Haible.
24634
24635         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
24636         Suggestion from Bruno Haible.
24637
24638 2000-06-23  Jim Meyering  <meyering@lucent.com>
24639
24640         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
24641
24642 2000-06-21  Jim Meyering  <meyering@lucent.com>
24643
24644         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
24645
24646 2000-06-21  Jim Meyering  <meyering@lucent.com>
24647
24648         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
24649         (noinst_HEADERS): Add getstr.h.
24650
24651         * lib/getline.c (getstr): Move into a separate file.
24652         * lib/getstr.c (getstr): New file, extracted from getline.c, with
24653         the following changes: new parameter, delim2; both delim[12]
24654         parameters have type `int', not `char'.  The latter would lose
24655         with 8-bit delimiters.
24656         * lib/getstr.h: New file.
24657
24658 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24659
24660         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
24661         than 1024, return a memory chunk of least possible size, instead
24662         of size PATH_MAX + 2. In the loop, increment the size proportionally.
24663         Use free/xmalloc instead of xrealloc to avoid copying for very long
24664         paths.
24665
24666 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24667
24668         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
24669         the empty string.
24670
24671 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
24672
24673         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
24674         address, not strdup.  Include <stdlib.h> and don't declare free().
24675
24676 2000-06-19  Jim Meyering  <meyering@lucent.com>
24677
24678         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
24679
24680 2000-06-18  Jim Meyering  <meyering@lucent.com>
24681
24682         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
24683
24684         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
24685         `checking whether...' message to be consistent with that of the
24686         lstat test.
24687
24688 2000-06-18  Jim Meyering  <meyering@lucent.com>
24689
24690         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
24691         Besides, these days every porting target provides a mkdir function.
24692
24693         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
24694         needed. (this snippet comes from src/system.h).
24695
24696 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
24697
24698         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
24699
24700 2000-06-15  Paul Eggert  <eggert@twinsun.com>
24701
24702         * lib/human.c (adjust_value): New function.
24703         (human_readable_inexact): Apply rounding style even when
24704         printing approximate values.
24705
24706 2000-06-14  Paul Eggert  <eggert@twinsun.com>
24707
24708         * lib/human.c (human_readable_inexact): Allow an input block
24709         size that is not a multiple of the output block size, and vice versa.
24710         Reported by Piergiorgio Sartor.
24711
24712 2000-06-14  Paul Eggert  <eggert@twinsun.com>
24713
24714         * lib/getdate.y (get_date): Apply relative times after time
24715         zone indicator, not before.  Reported by Todd A. Jacobs.
24716
24717 2000-06-13  Jim Meyering  <meyering@lucent.com>
24718
24719         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
24720
24721         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
24722
24723 2000-06-12  Paul Eggert  <eggert@twinsun.com>
24724
24725         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
24726
24727 2000-06-12  Jim Meyering  <meyering@lucent.com>
24728
24729         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
24730         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
24731         optional argument.
24732         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
24733         the optional argument, `lib'.
24734
24735 2000-06-08  Jim Meyering  <meyering@lucent.com>
24736
24737         * m4/largefile.m4: Remove file (now that it's part of autoconf).
24738
24739 2000-06-04  Paul Eggert  <eggert@twinsun.com>
24740
24741         Rewrite largefile configuration so that we don't need to run
24742         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
24743         AC_CANONICAL_HOST in configure.in -- jmm]
24744
24745         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
24746         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
24747         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
24748         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
24749         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
24750         All uses changed.
24751         Instead of inspecting the output of getconf, try to compile the
24752         test program without and with the macro definition.
24753         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
24754         for getconf.  Instead, check for the needed flags by compiling
24755         test programs.
24756
24757 2000-06-04  Paul Eggert  <eggert@twinsun.com>
24758
24759         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
24760
24761 2000-06-04  Jim Meyering  <meyering@lucent.com>
24762
24763         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
24764         SunOS 4.1.4 for which gid_t is an unsigned type.
24765
24766 2000-06-03  Jim Meyering  <meyering@lucent.com>
24767
24768         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
24769         now that autoconf requires that.
24770
24771         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
24772         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
24773         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
24774
24775 2000-06-03  Jim Meyering  <meyering@lucent.com>
24776
24777         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
24778
24779 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
24780
24781         * m4/glibc21.m4: New file.
24782         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
24783
24784 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
24785
24786         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
24787         newer, don't install charset.alias.
24788         * lib/config.charset: Change the Linux/glibc rules so they become empty
24789         on glibc-2.1 or newer.
24790
24791 2000-06-02  Jim Meyering  <meyering@lucent.com>
24792
24793         * lib/mountlist.c: Back out last change.  Instead, do this...
24794         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
24795         me_dummy member using the same `ignore'-testing code.
24796         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
24797         fs_type strings.
24798         From Mark D. Roth.
24799
24800 2000-05-29  Jim Meyering  <meyering@lucent.com>
24801
24802         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
24803         mounts with the `ignore' attribute.  Based on a patch from
24804         Mark D. Roth.
24805
24806 2000-05-28  Jim Meyering  <meyering@lucent.com>
24807
24808         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
24809         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24810         * m4/stat.m4: Likewise.
24811         * m4/lstat.m4: Likewise.
24812         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
24813
24814         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
24815         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
24816
24817 2000-05-26  Jim Meyering  <meyering@lucent.com>
24818
24819         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
24820
24821 2000-05-24  Jim Meyering  <meyering@lucent.com>
24822
24823         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
24824         autoconf requires that.
24825         * m4/lib-check.m4: Likewise.
24826         * m4/jm-macros.m4: Likewise.
24827         * m4/strftime.m4: Likewise.
24828
24829         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
24830         AC_CHECK_DECLS, now that autoconf requires that.
24831
24832 2000-05-22  Jim Meyering  <meyering@lucent.com>
24833
24834         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24835         * m4/lstat.m4: Likewise.
24836
24837 2000-05-22  Jim Meyering  <meyering@lucent.com>
24838
24839         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
24840
24841 2000-05-20  Jim Meyering  <meyering@lucent.com>
24842
24843         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
24844         (jm_PREREQ): Use it.
24845
24846 2000-05-18  Jim Meyering  <meyering@lucent.com>
24847
24848         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
24849         back, too, since it may have been modified by allocate_entry.
24850         (hash_delete): Rewrite to use neither the assignment operator
24851         nor the comma operator in an if-expression.
24852
24853 2000-05-15  Paul Eggert  <eggert@twinsun.com>
24854
24855         * lib/closeout.c:
24856         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
24857         Remove; no longer needed.
24858         "quotearg.h": Add include.
24859         (file_name): Do not bother to explicitly initialize to NULL; it's less
24860         efficient on some hosts.
24861         (close_stdout_status): Remove test as to whether stdout was already
24862         closed; it breaks for the case "echo x | sort >&-".
24863         Quote file name colons.
24864         Do not assume that _("write error") lacks format strings.
24865
24866 2000-05-15  Jim Meyering  <meyering@lucent.com>
24867
24868         * lib/version-etc.c (version_etc_copyright): Update the copyright
24869         string used in all --version output.
24870
24871 2000-05-14  Jim Meyering  <meyering@lucent.com>
24872
24873         * lib/closeout.c (close_stdout_set_file_name): New function.
24874         (close_stdout_status): Use new file-scoped global.
24875         Return right away if fstat says the stdout file descriptor is invalid.
24876         * lib/closeout.h (close_stdout_set_file_name): Declare.
24877
24878 2000-05-10  Jim Meyering  <meyering@lucent.com>
24879
24880         * lib/closeout.c [default_exit_status]: New file-scoped variable.
24881         (close_stdout_set_status): New function.
24882         * lib/closeout.h (close_stdout_set_status): Declare.
24883
24884 2000-05-09  Jim Meyering  <meyering@lucent.com>
24885
24886         * m4/gettext.m4: Rename this...
24887         * m4/libintl.m4: ...to this.
24888
24889 2000-05-08  Jim Meyering  <meyering@lucent.com>
24890
24891         * lib/long-options.c: Don't include closeout.h.
24892         (parse_long_options): Don't call close_stdout for --version.
24893
24894 2000-05-06  Paul Eggert  <eggert@twinsun.com>
24895
24896         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
24897         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
24898         2.1.3 bug.  This avoids a clash when files like regex.c define
24899         _GNU_SOURCE.
24900
24901 2000-05-06  Jim Meyering  <meyering@lucent.com>
24902
24903         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
24904         (AC_REPLACE_FUNCS): Add strnlen.
24905
24906         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
24907         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
24908
24909         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
24910         AC_SEARCH_LIBS call for nanosleep.
24911         (LIB_NANOSLEEP): Set and AC_SUBST.
24912
24913 2000-05-06  Jim Meyering  <meyering@lucent.com>
24914
24915         * lib/strnlen.c: Undefine __strnlen and strnlen.
24916         [!weak_alias]: Define __strnlen to strnlen.
24917
24918         * lib/atexit.c: New file, from libiberty.
24919
24920 2000-05-06  Jim Meyering  <meyering@lucent.com>
24921
24922         * lib/closeout.c (close_stdout_status): Also check for errors on the
24923         stderr stream.
24924
24925 2000-05-05  Jim Meyering  <meyering@lucent.com>
24926
24927         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
24928         AC_SEARCH_LIBS call for clock_gettime.
24929         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
24930
24931         * m4/search-libs.m4: Update from autoconf.
24932
24933         su doesn't work on Solaris 2.6.
24934         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
24935         <shadow.h>.  Reported by Dragos Harabor.
24936
24937 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
24938
24939         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
24940         memcpy instead of xmalloc, xrealloc, path_concat.
24941         (locale_charset): Treat empty environment variables as absent.
24942         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
24943
24944 2000-05-04  Jim Meyering  <meyering@lucent.com>
24945
24946         * lib/getopt.c: Update from glibc.
24947         * lib/obstack.c: Likewise.
24948         * lib/obstack.h: Likewise.
24949         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
24950         file
24951
24952         * lib/regex.h: Likewise.
24953         * lib/strndup.c: Likewise.
24954         * lib/strnlen.c: New file, from glibc.
24955
24956 2000-05-03  Jim Meyering  <meyering@lucent.com>
24957
24958         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
24959
24960 2000-05-02  Paul Eggert  <eggert@twinsun.com>
24961
24962         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
24963         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
24964         compile-time test, rather than inspecting host and OS, to
24965         decide whether to define _LARGEFILE_SOURCE.
24966
24967 2000-05-01  Jim Meyering  <meyering@lucent.com>
24968
24969         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
24970
24971         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
24972         Based on a patch from Bruno Haible.
24973
24974 2000-05-01  Jim Meyering  <meyering@lucent.com>
24975
24976         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
24977
24978 2000-04-29  Jim Meyering  <meyering@lucent.com>
24979
24980         * lib/path-concat.c: Declare strdup only if it's not defined.
24981         * lib/canon-host.c: Likewise.
24982
24983 2000-04-28  Jim Meyering  <meyering@lucent.com>
24984
24985         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
24986         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
24987         is included first, then limits.h is included by locale.h by libintl.h.
24988         From John David Anglin.
24989
24990 2000-04-25  Jim Meyering  <meyering@lucent.com>
24991
24992         * lib/makepath.c (S_IRWXUGO): Define.
24993         (make_path): Always perform explicit chmod if MODE specifies any
24994         of the `special' permission bits.  Prompted by a bug report against
24995         install from Mate Wierdl and Joost van Baal.
24996
24997 2000-04-18  Jim Meyering  <meyering@lucent.com>
24998
24999         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
25000         (jm_PREREQ): Use it.
25001
25002 2000-04-18  Jim Meyering  <meyering@lucent.com>
25003
25004         * lib/README: New file.
25005
25006         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
25007         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
25008
25009 2000-04-17  Jim Meyering  <meyering@lucent.com>
25010
25011         Get it right :-)
25012         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
25013         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
25014         Suggestion from Akim Demaille.
25015
25016 2000-04-17  Jim Meyering  <meyering@lucent.com>
25017
25018         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
25019         the definition of it to rpl_strftime also defined-away the system's
25020         declaration.
25021
25022 2000-04-15  Jim Meyering  <meyering@lucent.com>
25023
25024         Use `C' to denote so-called `contiguous' files, the same way
25025         that tar does.
25026         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
25027         (ftypelet): Use S_ISCTG.
25028         From Michael Deutschmann.
25029
25030 2000-04-14  Jim Meyering  <meyering@lucent.com>
25031
25032         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
25033         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
25034         clobbered.
25035
25036 2000-04-14  Jim Meyering  <meyering@lucent.com>
25037
25038         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
25039
25040 2000-04-13  Jim Meyering  <meyering@lucent.com>
25041
25042         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
25043         AH_VERBATIM to insert required #ifndef into config.h.in.
25044         Suggestion from Akim Demaille.
25045
25046 2000-04-12  Jim Meyering  <meyering@lucent.com>
25047
25048         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
25049         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
25050         Christian Krackowizer.
25051
25052         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
25053         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
25054         (AC_SYS_LARGEFILE): Require.
25055         (AM_C_PROTOTYPES): Require.
25056
25057 2000-04-08  Jim Meyering  <meyering@lucent.com>
25058
25059         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
25060         names don't conflict.  Reported by Eli Zaretskii.
25061
25062 2000-04-07  Jim Meyering  <meyering@lucent.com>
25063
25064         * lib/putenv.c: Move inclusion of errno.h so it follows that of
25065         sys/types.h, to work around system header problems on AIX 3.2.5.
25066         From Bruno Haible.
25067
25068 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
25069
25070         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
25071         bug.  Deal with the different error behavior of Irix iconv.
25072
25073 2000-04-05  Paul Eggert  <eggert@twinsun.com>
25074
25075         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
25076         IRIX if the installer said otherwise.
25077
25078 2000-04-05  Jim Meyering  <meyering@lucent.com>
25079
25080         Portability tweaks required for ultrix4.3.
25081         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
25082         (jm_CHECK_DECLS): Add getutent to the list of functions.
25083         (_jm_DECL_HEADERS): Add utmpx.h.
25084         From John David Anglin.
25085
25086         * m4/strftime.m4: Back out the 2000-04-02 change.
25087         Instead of that change, simply undefine putenv in the test program.
25088
25089 2000-04-05  Jim Meyering  <meyering@lucent.com>
25090
25091         Portability tweaks required for ultrix4.3.
25092         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
25093         getutent.
25094         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
25095         * lib/canon-host.c: Declare strdup.
25096         * lib/path-concat.c: Likewise.
25097         From John David Anglin.
25098
25099 2000-04-04  Jim Meyering  <meyering@lucent.com>
25100
25101         Be more DOS 8.3-friendly.
25102         * lib/ref-add.sin: Renamed from ref-add.sed.in.
25103         * lib/ref-del.sin: Renamed from ref-del.sed.in.
25104         * lib/Makefile.am: Reflect renaming.
25105         Reported by Eli Zaretskii.
25106
25107         Use a temporary file name that won't clash with `charset.alias'
25108         in the DOS 8.3 name space.
25109         * lib/Makefile.am (charset_tmp): Define.
25110         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
25111         (uninstall-local): Likewise.
25112         Reported by Eli Zaretskii.
25113
25114 2000-04-03  Jim Meyering  <meyering@lucent.com>
25115
25116         * m4/gettext.m4: Fix typo in comment.
25117
25118         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
25119         textutils/configure.in).  Suggestion from Paul Eggert.
25120         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
25121
25122 2000-04-02  Paul Eggert  <eggert@twinsun.com>
25123
25124         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
25125         variable in the shell rather than using putenv, which isn't
25126         portable.  This avoids the configure-time inter-test dependency
25127         on the potentially-renamed putenv function.
25128
25129 2000-03-30  Paul Eggert  <eggert@twinsun.com>
25130
25131         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
25132         before checking struct stat.st_blksize, so that
25133         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
25134
25135 2000-03-29  Paul Eggert  <eggert@twinsun.com>
25136
25137         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
25138         since strftime.c uses HAVE_STRFTIME to decide whether to use
25139         the underlying strftime.
25140
25141 2000-03-29  Paul Eggert  <eggert@twinsun.com>
25142
25143         * lib/time/strftime.c (my_strftime): Make sure we call the system
25144         strftime, not ourselves, when invoking the underlying strftime.
25145
25146 2000-03-24  Jim Meyering  <meyering@lucent.com>
25147
25148         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
25149         (charset_alias): Define.
25150         (install-exec-local): Factor out common code.
25151         (uninstall-local): Split lines longer than 80.
25152         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
25153         (SUFFIXES): Define.
25154         (.sed.in.sed): New rule.  Don't redirect directly to $@.
25155         (CLEANFILES): Add ref-add.sed and ref-del.sed.
25156
25157 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
25158
25159         * lib/config.charset: Output a line containing "Packages using this
25160         file".
25161         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
25162         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
25163         ref-del.sed): New rules.
25164
25165 2000-03-17  Jim Meyering  <meyering@lucent.com>
25166
25167         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
25168         Otherwise, include <strings.h>
25169
25170 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
25171
25172         * lib/unicodeio.c (utf8_wctomb): New function.
25173         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
25174         format instead of in UCS-4 with platform dependent endianness.
25175
25176 2000-03-10  Jim Meyering  <meyering@lucent.com>
25177
25178         * m4/lib-check.m4: Look for getspnam in -lgen, too.
25179         From Marco Franzen.
25180
25181 2000-03-07  Paul Eggert  <eggert@twinsun.com>
25182
25183         * lib/savedir.c (savedir): Work even if directory size is
25184         negative; this can happen with some screwy NFS configurations.
25185
25186 2000-03-06  Jim Meyering  <meyering@lucent.com>
25187
25188         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
25189         if it's NULL (because we ran out of memory).  From Bruno Haible.
25190
25191 2000-03-05  Jim Meyering  <meyering@lucent.com>
25192
25193         * lib/localcharset.c ("path-concat.h"): Include.
25194         (get_charset_aliases): Use path_concat instead of ANSI string
25195         concatenation.
25196
25197         * lib/unicodeio.h (PARAMS): Define.
25198         Use it to guard prototype.
25199
25200 2000-03-04  Jim Meyering  <meyering@lucent.com>
25201
25202         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
25203         for lib/localcharset.c.
25204
25205 2000-03-04  Jim Meyering  <meyering@lucent.com>
25206
25207         * lib/Makefile.am (install-exec-local): Create $(libdir) before
25208         installing into it.
25209         (uninstall-local): Uncomment this rule so `make distcheck' works
25210         once again.
25211
25212         * lib/unicodeio.c (<errno.h>): Include it.
25213         (errno): Declare if not defined.
25214
25215         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
25216
25217         * lib/config.charset: New version, incorporating remarks from a linux
25218         i18n mailing list.  From Bruno Haible.
25219
25220 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
25221
25222         * m4/codeset.m4: New file.
25223         * m4/iconv.m4: New file.
25224         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
25225
25226 2000-03-03  Jim Meyering  <meyering@lucent.com>
25227
25228         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
25229
25230 2000-03-02  Jim Meyering  <meyering@lucent.com>
25231
25232         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
25233         the messages come out on separate lines.
25234
25235         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
25236         rather than jm_CHECK_DECLARATIONS.
25237         * m4/decl.m4: Remove now-unused file.
25238
25239         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
25240         geteuid.
25241
25242 2000-03-02  Jim Meyering  <meyering@lucent.com>
25243
25244         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
25245
25246 2000-03-01  Jim Meyering  <meyering@lucent.com>
25247
25248         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
25249         * lib/unicodeio.c: Likewise.
25250
25251 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
25252
25253         * lib/config.charset: New file.
25254         * lib/localcharset.c: New file.
25255         * lib/unicodeio.h, lib/unicodeio.c: New files.
25256         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
25257         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
25258         (noinst_HEADERS): Add unicodeio.h.
25259         (all-local, install-exec-local, charset.alias): New targets.
25260
25261 2000-02-28  Paul Eggert  <eggert@twinsun.com>
25262
25263         * lib/quotearg.c (ALERT_CHAR): New macro.
25264         (quotearg_buffer_restyled): Use it.
25265
25266 2000-02-27  Jim Meyering  <meyering@lucent.com>
25267
25268         * m4/check-decl.m4: Add getenv to the list.
25269
25270 2000-02-27  Jim Meyering  <meyering@lucent.com>
25271
25272         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
25273         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
25274
25275         * lib/backupfile.c: Guard inclusion of stdlib.h with
25276         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
25277         Declare malloc if needed.
25278
25279         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
25280         `#ifndef HAVE_DECL..'
25281         now that autoconf always defines the HAVE_DECL_ symbols.
25282         * lib/human.c: Likewise.
25283         * lib/same.c: Likewise.
25284         * lib/strtoumax.c: Likewise.
25285
25286         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
25287         declaration check was not run.
25288         * lib/hash.c: Likewise.
25289         * lib/human.c: Likewise.
25290         * lib/same.c: Likewise.
25291         * lib/strtoumax.c: Likewise.
25292
25293         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
25294         `.', then first look up the entire `.'-containing string as a login
25295         name.
25296
25297 2000-02-23  Jim Meyering  <meyering@lucent.com>
25298
25299         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
25300         in place of my hack.
25301
25302 2000-02-18  Paul Eggert  <eggert@twinsun.com>
25303
25304         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
25305         (textint): New typedef.
25306         (parser_control): Member year changed from int to textint.
25307         All uses changed.
25308         (YYSTYPE): Removed; replaced by %union with int and textint members.
25309         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
25310         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
25311         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
25312         (tSNUMBER, tUNUMBER): Now of type <textintval>.
25313         (date, number, to_year): Use width of number in digits, not its value,
25314         to determine whether it's a 2-digit year, or a 2-digit time.
25315         (yylex): Store number of digits of numeric tokens.
25316         Reported by John Kendall.
25317
25318         (parser_control): Changed from struct parser_control to typedef (for
25319         consistency).  All uses changed.
25320
25321         (tID): Removed; not used.
25322         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
25323
25324 2000-02-14  Paul Eggert  <eggert@twinsun.com>
25325
25326         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
25327         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
25328
25329 2000-02-12  Jim Meyering  <meyering@lucent.com>
25330
25331         * lib/userspec.c (ISDIGIT): Define it.
25332         (isdigit): Remove definition.
25333         (is_number): Use ISDIGIT, not isdigit.
25334         <libintl.h>: Include.
25335         (_ and N_): Define.
25336         (parse_user_spec): Mark translatable strings.
25337
25338 2000-02-10  Jim Meyering  <meyering@lucent.com>
25339
25340         With these changes, nanosleep.[ch] are finally enough like the other
25341         lib/* replacement files to compile on a few more losing systems.
25342
25343         * lib/nanosleep.h: Don't include config.h.
25344         Remove prototype from declaration of nanosleep.
25345         (PARAMS): Remove now-unneeded definition.
25346         * lib/nanosleep.c: #undef nanosleep.
25347         (rpl_nanosleep): Rename from nanosleep.
25348
25349 2000-02-10  Jim Meyering  <meyering@lucent.com>
25350
25351         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
25352         gnu_nanosleep to rpl_nanosleep.
25353
25354 2000-02-09  Jim Meyering  <meyering@lucent.com>
25355
25356         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
25357         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
25358
25359 2000-02-08  Akim Demaille  <akim@epita.fr>
25360
25361         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
25362         `[' and `]' and remove uses of `changequote'.
25363         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
25364         (AC_SYS_LARGEFILE): Likewise.
25365         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
25366         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
25367         of changequote.
25368         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
25369         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
25370         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
25371         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
25372
25373 2000-02-05  Jim Meyering  <meyering@lucent.com>
25374
25375         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
25376         Remove explicit use of AC_HEADER_TIME.  It is required by
25377         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
25378         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
25379         in autoconf whereby the expansion of the latter ended up preceding
25380         the expansion of its prerequisite, AC_HEADER_TIME.
25381         Reported by Volker Borchert.
25382
25383 2000-02-03  Jim Meyering  <meyering@lucent.com>
25384
25385         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
25386
25387 2000-02-03  Jim Meyering  <meyering@lucent.com>
25388
25389         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
25390         rather than with `#if HAVE_UTMPNAME'.
25391
25392 2000-02-02  Jim Meyering  <meyering@lucent.com>
25393
25394         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
25395         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
25396         Reported by Eli Zaretskii.
25397
25398 2000-02-01  Jim Meyering  <meyering@lucent.com>
25399
25400         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
25401
25402 2000-01-31  Jim Meyering  <meyering@lucent.com>
25403
25404         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
25405         functions.  Add the time.h and sys/time.h headers along with the
25406         AC_REQUIRE'ment of AC_HEADER_TIME.
25407
25408 2000-01-31  Jim Meyering  <meyering@lucent.com>
25409
25410         * lib/nanosleep.h (nanosleep): Guard declaration with
25411         `#if ! HAVE_DECL_NANOSLEEP'.
25412         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
25413         the declaration in that vendor's sys/timers.h.
25414         Reported by Christian Krackowizer.
25415
25416         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
25417         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
25418         (ISPRINT): Likewise.
25419         Reported by Tom Tromey.
25420
25421 2000-01-30  Jim Meyering  <meyering@lucent.com>
25422
25423         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
25424
25425         * m4/prereq.m4 (utmp_includes): Define.
25426         Check for ut_user and ut_name members in both struct utmpx
25427         and struct utmp.
25428
25429 2000-01-30  Jim Meyering  <meyering@lucent.com>
25430
25431         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
25432         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
25433         header files where only utmpx.ut_user is declared.
25434
25435         * lib/readutmp.h (UT_USER): Define.
25436
25437 2000-01-29  Jim Meyering  <meyering@lucent.com>
25438
25439         * m4/lib-check.m4: New file containing library-related checks from
25440         fileutils and sh-utils (textutils had none).
25441
25442 2000-01-28  Jim Meyering  <meyering@lucent.com>
25443
25444         * m4/perl.m4: Change format of warning message to look more like that
25445         from the missing script.  Suggestion from François Pinard.
25446
25447 2000-01-25  Jim Meyering  <meyering@lucent.com>
25448
25449         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
25450         well as time.h in the compile check.
25451         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
25452         Fix typo in cross-compiling case: s/yes/no/.
25453
25454 2000-01-23  Jim Meyering  <meyering@lucent.com>
25455
25456         * m4/jm-macros.m4: Move df-related tests here from
25457         fileutils/configure.in
25458
25459         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
25460         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
25461
25462         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
25463         s/space/ac_fsusage_space/.
25464         (jm_FILE_SYSTEM_USAGE): Take two parameters.
25465
25466         * m4/ftruncate.m4: New file (derived from part of
25467         fileutils/configure.in).
25468         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
25469         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
25470
25471         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
25472         AC_SUBST these here, rather than just in sh-util/configure.in, so
25473         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
25474         all the same.
25475         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
25476         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
25477         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
25478         (AC_SUBST(POW_LIBM)): Likewise.
25479         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
25480
25481 2000-01-23  Jim Meyering  <meyering@lucent.com>
25482
25483         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
25484         obstack.c.
25485
25486 2000-01-22  Jim Meyering  <meyering@lucent.com>
25487
25488         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
25489
25490         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
25491
25492         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
25493         configure.in
25494         (AC_CHECK_HEADERS): Likewise for sh-utils.
25495         (AC_CHECK_HEADERS): Likewise for textutils.
25496         Merge the three lists of headers.
25497
25498         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
25499         from fileutils' configure.in.
25500
25501         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
25502         code. Moved tests into their own function (_jm_DECL_HEADERS) in
25503         check-decl.m4.
25504
25505         * m4/check-decl.m4: Use #if rather than #ifdef.
25506         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
25507         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
25508         (_jm_DECL_HEADERS): Define new function.
25509         (jm_CHECK_DECLARATIONS): Require it.
25510
25511 2000-01-22  Jim Meyering  <meyering@lucent.com>
25512
25513         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
25514         [! HAVE_DECL_STRTOULL]: Declare strtoull.
25515         Required for some AIX systems.  Reported by Christian Krackowizer.
25516         [TESTING] (main): New function.
25517
25518         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
25519         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
25520         letters.
25521
25522         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
25523         iswprint.
25524
25525         * lib/strverscmp.c (ISDIGIT): Define.
25526         (strverscmp): Use ISDIGIT, not isdigit.
25527
25528 2000-01-19  Jim Meyering  <meyering@lucent.com>
25529
25530         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
25531         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
25532         defines `struct timespec' in <sys/time.h>
25533
25534         * m4/c-bs-a.m4: Remove uses of changequote altogether.
25535         Thanks to Akim for explaining.
25536
25537 2000-01-17  Paul Eggert  <eggert@twinsun.com>
25538
25539         * lib/nanosleep.c (nanosleep):
25540         Don't use SA_INTERRUPT to decide whether to call sigaction, as
25541         POSIX.1 doesn't require SA_INTERRUPT and some systems
25542         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
25543         it's been part of POSIX.1 since day 1 (in 1988).
25544
25545 2000-01-17  Jim Meyering  <meyering@lucent.com>
25546
25547         * lib/interlock: Remove unused file.  Reported by François Pinard.
25548
25549 2000-01-16  Paul Eggert  <eggert@twinsun.com>
25550
25551         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
25552         alert, backslash, formfeed, and vertical tab unnecessarily in
25553         shell quoting style.
25554
25555 2000-01-16  Jim Meyering  <meyering@lucent.com>
25556
25557         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
25558         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
25559         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
25560         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
25561
25562 2000-01-16  Jim Meyering  <meyering@lucent.com>
25563
25564         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
25565         because the latter didn't work.
25566
25567 2000-01-15  Jim Meyering  <meyering@lucent.com>
25568
25569         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
25570         (AC_REPLACE_FUNCS): Add memcpy and memset.
25571         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
25572         Add strpbrk.
25573         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
25574
25575 2000-01-12  Jim Meyering  <meyering@lucent.com>
25576
25577         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
25578         (jm_PREREQ): Use it.
25579         (jm_PREREQ_READUTMP): New macro.
25580         (jm_PREREQ): Use it.
25581
25582 2000-01-11  Paul Eggert  <eggert@twinsun.com>
25583
25584         Quote multibyte characters correctly.
25585         * m4/c-bs-a.m4: New file.
25586         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
25587         (jm_PREREQ): Use it.
25588
25589 2000-01-11  Paul Eggert  <eggert@twinsun.com>
25590
25591         * m4/uintmax_t.m4: Port to autoconf 2.13.
25592
25593 2000-01-08  Jim Meyering  <meyering@ascend.com>
25594
25595         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
25596         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
25597
25598 2000-01-04  Jim Meyering  <meyering@ascend.com>
25599
25600         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
25601         jm_STRUCT_DIRENT_D_TYPE.
25602         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
25603         jm_STRUCT_DIRENT_D_INO.
25604         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
25605         jm_STRUCT_UTIMBUF.
25606         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
25607         renamings.
25608         * m4/utime.m4: Likewise.
25609
25610         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
25611         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
25612
25613 2000-01-03  Paul Eggert  <eggert@twinsun.com>
25614
25615         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
25616         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
25617
25618 2000-01-02  Jim Meyering  <meyering@ascend.com>
25619
25620         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
25621         remember if this is necessary.
25622
25623 1999-12-26  Jim Meyering  <meyering@ascend.com>
25624
25625         * m4/jm-macros.m4: Use it here.
25626         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
25627
25628 1999-12-23  Jim Meyering  <meyering@ascend.com>
25629
25630         * m4/jm-macros.m4: Check for clock_gettime (moved from
25631         fileutils/configure.in)
25632         Check for gettimeofday.
25633
25634 1999-12-20  Jim Meyering  <meyering@ascend.com>
25635
25636         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
25637         autoconf-2.14a-1999-12-20.
25638
25639 1999-12-19  Jim Meyering  <meyering@ascend.com>
25640
25641         * m4/lstat-slash.m4: New file.
25642         * m4/jm-macros.m4: Use the new macro:
25643         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
25644
25645 1999-12-07  Jim Meyering  <meyering@ascend.com>
25646
25647         * m4/perl.m4: Require that File::Compare be available, too.
25648         Too many systems seem to lack it.
25649
25650         * m4/strftime.m4: Add checks for most of the cpp macros tested in
25651         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
25652
25653 1999-11-18  Paul Eggert  <eggert@twinsun.com>
25654
25655         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
25656         problem with the QNX 4.25 shell, which doesn't propagate exit
25657         status of failed commands inside shell assignments.
25658
25659 1999-11-17  Jim Meyering  <meyering@ascend.com>
25660
25661         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
25662
25663 1999-11-07  Jim Meyering  <meyering@ascend.com>
25664
25665         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
25666
25667 1999-11-06  Jim Meyering  <meyering@ascend.com>
25668
25669         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
25670         * m4/jm-macros.m4 (jm_MACROS): Use it here.
25671
25672 1999-11-05  Jim Meyering  <meyering@ascend.com>
25673
25674         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
25675         configure.in of textutils, fileutils, and sh-utils into this one
25676         (shared between those packages) file.
25677         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
25678         AC_STRUCT_ST_BLKSIZE.
25679
25680 1999-11-03  Jim Meyering  <meyering@ascend.com>
25681
25682         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
25683         of AC_CHECK_TYPE checks includes unistd.h.
25684         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
25685         Suggestion from Akim Demaille.
25686
25687 1999-10-30  Jim Meyering  <meyering@ascend.com>
25688
25689         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
25690         m4-quoted string.
25691         * m4/ls-mntd-fs.m4: Likewise.
25692         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
25693         * m4/jm-winsz1.m4: Likewise.
25694
25695         * m4/const.m4: Remove file, since the fix made it into the experimental
25696         version of autoconf.
25697         * m4/mktime.m4: Likewise.
25698
25699         * m4/check-type.m4: Remove file, now that the latest version of
25700         AC_CHECK_TYPE takes a third arg to specify additional #includes.
25701
25702         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
25703         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
25704         AC_CHECK_TYPE.
25705
25706 1999-10-04  Jim Meyering  <meyering@ascend.com>
25707
25708         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
25709
25710 1999-09-22  Paul Eggert  <eggert@twinsun.com>
25711
25712         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
25713         2.95.1 bug with HP-UX 10.20.
25714
25715 1999-09-17  Jim Meyering  <meyering@ascend.com>
25716
25717         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
25718         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
25719         due to missing strdup (against sh-utils-2.0).
25720
25721 1999-08-29  Jim Meyering  <meyering@ascend.com>
25722
25723         * m4/jm-macros.m4: Require jm_BISON.
25724         * m4/bison.m4: New file.
25725
25726 1999-08-17  Paul Eggert  <eggert@twinsun.com>
25727
25728         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
25729         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
25730
25731 1999-08-05  Jim Meyering  <meyering@ascend.com>
25732
25733         * m4/getline.m4: Rename test file from conftestdata to conftest.data
25734         to avoid conflicts with `conftest' on 8+3 filesystems.
25735         Suggestion from Eli Zaretskii.
25736
25737 1999-08-04  Jim Meyering  <meyering@ascend.com>
25738
25739         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
25740         fileutils and sh-utils (textutils's getline test was inadequate).
25741         (AM_FUNC_GETLINE): Run this test.
25742         (AC_CHECK_FUNCS): Check for getdelim.
25743         Reported by Bob Proulx.
25744
25745 1999-08-02  Jim Meyering  <meyering@ascend.com>
25746
25747         * m4/jm-macros.m4: Add a comment.
25748
25749 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25750
25751         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
25752         <inttypes.h> defines strtoumax as a macro (and not as a
25753         function).
25754
25755 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25756
25757         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
25758         that we can shift, multiply and divide unsigned long long
25759         values; Ultrix cc can't do it.
25760
25761 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25762
25763         * m4/mktime.m4: New file, which is a preview of what should appear
25764         in the next public autoconf release.
25765
25766 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25767
25768         * m4/lfs.m4: Remove this file.
25769         * m4/largefile.m4: New file.  It contains the old contents of
25770         lfs.m4, except that all names with prefix AC_LFS have been
25771         changed to use the prefix AC_SYS_LARGEFILE instead, to be
25772         compatible with future autoconf versions.  Also, some minor m4
25773         quoting problems have been fixed.
25774
25775 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25776
25777         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
25778         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
25779         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
25780         and simplify the shell code.
25781
25782 1999-08-01  Jim Meyering  <meyering@ascend.com>
25783
25784         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
25785         m4.
25786
25787 1999-07-20  Jim Meyering  <meyering@ascend.com>
25788
25789         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
25790
25791 1999-07-15  Jim Meyering  <meyering@ascend.com>
25792
25793         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
25794
25795 1999-05-22  Jim Meyering  <meyering@ascend.com>
25796
25797         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
25798
25799 1999-05-20  Jim Meyering  <meyering@ascend.com>
25800
25801         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
25802         Add a colon after each `then' in case $4 is empty.
25803
25804 1999-05-16  Jim Meyering  <meyering@ascend.com>
25805
25806         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
25807
25808 1999-05-10  Jim Meyering  <meyering@ascend.com>
25809
25810         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
25811
25812         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
25813         AC_FUNC_MKTIME.
25814
25815 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
25816
25817         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
25818
25819 1999-05-04  Paul Eggert  <eggert@twinsun.com>
25820
25821         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
25822         not CPPFLAGS, so that linking works correctly in IRIX.
25823
25824 1999-04-30  Paul Eggert  <eggert@twinsun.com>
25825
25826         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
25827
25828 1999-04-20  Paul Eggert  <eggert@twinsun.com>
25829
25830         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
25831         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
25832         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
25833         jm_AC_TYPE_UNSIGNED_LONG_LONG.
25834         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
25835
25836         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
25837
25838 1999-04-20  Jim Meyering  <meyering@ascend.com>
25839
25840         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
25841         AC_REPLACE xstroull if necessary.  From Paul Eggert.
25842         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
25843
25844 1999-04-18  Jim Meyering  <meyering@ascend.com>
25845
25846         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
25847         * m4/jm-macros.m4: Use it.
25848
25849 1999-04-06  Jim Meyering  <meyering@ascend.com>
25850
25851         * m4/strftime.m4: Remove test for %f.
25852
25853 1999-03-29  Jim Meyering  <meyering@ascend.com>
25854
25855         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
25856         superset of the AC_TYPE_* checks in the textutils, fileutils,
25857         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
25858         AC_TYPE_PID_T.
25859
25860 1999-03-28  Jim Meyering  <meyering@ascend.com>
25861
25862         * m4/jm-macros.m4: Define GNU_PACKAGE here.
25863         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
25864         replaced e.g., in the *.sh files of the sh-utils.
25865
25866 1999-03-20  Jim Meyering  <meyering@ascend.com>
25867
25868         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
25869         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
25870         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
25871
25872 1999-03-19  Jim Meyering  <meyering@ascend.com>
25873
25874         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
25875
25876 1999-03-12  Jim Meyering  <meyering@ascend.com>
25877
25878         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
25879
25880 1999-03-07  Jim Meyering  <meyering@ascend.com>
25881
25882         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
25883         declared.
25884
25885 1999-02-17  Jim Meyering  <meyering@ascend.com>
25886
25887         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
25888         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
25889
25890 1999-02-07  Jim Meyering  <meyering@ascend.com>
25891
25892         * m4/group-member.m4: New file -- extracted from sh-utils'
25893         configure.in.
25894
25895         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
25896         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
25897
25898 1999-02-06  Jim Meyering  <meyering@ascend.com>
25899
25900         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
25901         * m4/fnmatch.m4: Likewise.
25902         * m4/getgroups.m4: Likewise.
25903         * m4/lstat.m4: Likewise.
25904         * m4/malloc.m4: Likewise.
25905         * m4/putenv.m4: Likewise.
25906         * m4/realloc.m4: Likewise.
25907         * m4/regex.m4: Likewise.
25908         * m4/stat.m4: Likewise.
25909         * m4/strftime.m4: Likewise.
25910         Suggestion from Alain Magloire.
25911
25912         * m4/chown.m4: Use `.$ac_objext', not `.o'.
25913         * m4/fnmatch.m4: Likewise.
25914         * m4/getgroups.m4: Likewise.
25915         * m4/getline.m4: Likewise.
25916         * m4/lstat.m4: Likewise.
25917         * m4/malloc.m4: Likewise.
25918         * m4/memcmp.m4: Likewise.
25919         * m4/putenv.m4: Likewise.
25920         * m4/realloc.m4: Likewise.
25921         * m4/regex.m4: Likewise.
25922         * m4/stat.m4: Likewise.
25923         * m4/strftime.m4: Likewise.
25924         Suggestion from Alain Magloire.
25925
25926         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
25927         an argument.
25928
25929         * m4/regex.m4: Add a run-time Test for proper operation of
25930         re_compile_pattern.
25931
25932 1999-01-31  Jim Meyering  <meyering@ascend.com>
25933
25934         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
25935
25936 1999-01-30  Jim Meyering  <meyering@ascend.com>
25937
25938         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
25939
25940         * m4/jm-mktime.m4: Make this a wrapper around the official
25941         AM_FUNC_MKTIME rather than my private copy, now that the official one
25942         is up to date.
25943         * m4/mktime.m4: Remove file.
25944
25945         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
25946         * m4/uptime.m4: Likewise.
25947         * m4/uintmax_t.m4: Likewise.
25948
25949 1999-01-28  Jim Meyering  <meyering@ascend.com>
25950
25951         * m4/jm-macros.m4: Use jm_AFS.
25952         * m4/afs.m4: New file (from fileutils' configure.in).
25953
25954         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
25955         * m4/chown.m4: Likewise.
25956         * m4/d-ino.m4: Likewise.
25957         * m4/d-type.m4: Likewise.
25958         * m4/fnmatch.m4: Likewise.
25959         * m4/getgroups.m4: Likewise.
25960         * m4/gettext.m4: Likewise.
25961         * m4/jm-mktime.m4: Likewise.
25962         * m4/jm-winsz2.m4: Likewise.
25963         * m4/lcmessage.m4: Likewise.
25964         * m4/ls-mntd-fs.m4: Likewise.
25965         * m4/malloc.m4: Likewise.
25966         * m4/memcmp.m4: Likewise.
25967         * m4/putenv.m4: Likewise.
25968         * m4/realloc.m4: Likewise.
25969         * m4/st_mtim.m4: Likewise.
25970         * m4/strftime.m4: Likewise.
25971
25972 1999-01-16  Jim Meyering  <meyering@ascend.com>
25973
25974         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
25975         (ARGMATCH_DIE_DECL): Define.
25976
25977 1999-01-12  Jim Meyering  <meyering@ascend.com>
25978
25979         * m4/Makefile.am.in: Rewrite to avoid using fmt.
25980         Reported by Lars Hecking.
25981
25982 1999-01-10  Jim Meyering  <meyering@ascend.com>
25983
25984         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
25985         gross kludge.
25986         * m4/inttypes_h.m4: Likewise.
25987         * m4/lstat.m4: Likewise.
25988         * m4/malloc.m4: Likewise.
25989         * m4/readdir.m4: Likewise.
25990         * m4/realloc.m4: Likewise.
25991         * m4/st_dm_mode.m4: Likewise.
25992         * m4/stat.m4: Likewise.
25993         * m4/utimbuf.m4: Likewise.
25994         * m4/utimes.m4: Likewise.
25995
25996         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
25997         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
25998         comments in config.h.in are meaningful.
25999
26000         * m4/jm-macros.m4: Require autoconf-2.13 here.
26001
26002         * m4/regex.m4: By default, don't use the included regex.c on systems
26003         with glibc 2.  Suggestion from Uli Drepper.
26004
26005 1999-01-02  Jim Meyering  <meyering@ascend.com>
26006
26007         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
26008
26009 1998-12-18  Jim Meyering  <meyering@ascend.com>
26010
26011         * m4/Makefile.am.in (Makefile.am): Simplify rule.
26012         Based on a suggestion from Lars Hecking.
26013
26014 1998-11-16  Paul Eggert  <eggert@twinsun.com>
26015
26016         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
26017
26018 1998-11-16  Jim Meyering  <meyering@ascend.com>
26019
26020         * m4/lfs.m4: Double-quote the `uname...` expression.
26021
26022 1998-11-14  Jim Meyering  <meyering@ascend.com>
26023
26024         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
26025         * m4/stat.m4: Likewise.
26026
26027 1998-11-03  Jim Meyering  <meyering@ascend.com>
26028
26029         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
26030         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
26031
26032 1998-10-18  Jim Meyering  <meyering@ascend.com>
26033
26034         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
26035
26036 1998-10-17  Jim Meyering  <meyering@ascend.com>
26037
26038         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
26039         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
26040         calls for those previously hard-coded headers.  Instead, take a new
26041         parameter.
26042         (jm_CHECK_DECLARATIONS): Reflect interface change.
26043         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
26044         (jm_CHECK_DECL_LOCALTIME_R): New macro.
26045
26046         * m4/mktime.m4: Test for spring-forward gap before long-running test.
26047
26048 1998-10-14  Jim Meyering  <meyering@ascend.com>
26049
26050         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
26051         instead of "TZ=America/Vancouver".  From Paul Eggert.
26052
26053 1998-10-11  Jim Meyering  <meyering@ascend.com>
26054
26055         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
26056         This adds a test for a recently added compatibility fix for mktime.c.
26057         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
26058
26059 1998-09-27  Jim Meyering  <meyering@ascend.com>
26060
26061         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
26062
26063         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
26064         ../configure.in, including a change from Gordon Matzigkeit to allow
26065         cross-compiling for the Hurd.
26066
26067         * m4/glibc.m4: New file/macro to test for the GNU C Library
26068         versions 1 and 2.  From Gordon Matzigkeit.
26069         Indent.
26070
26071 1998-09-21  Jim Meyering  <meyering@ascend.com>
26072
26073         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
26074
26075 1998-08-18  Paul Eggert  <eggert@twinsun.com>
26076
26077         Port nanosecond-resolution times to UnixWare 2.1.2 and
26078         pedantic Solaris 2.6.
26079
26080         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
26081         AC_STRUCT_ST_MTIM.
26082         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
26083         Generate name of ns member, instead of just 1 or undef.
26084         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
26085
26086 1998-08-15  Jim Meyering  <meyering@ascend.com>
26087
26088         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
26089         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
26090         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
26091         instead of jm_TYPE_SSIZE_T.
26092
26093 1998-08-12  Jim Meyering  <meyering@ascend.com>
26094
26095         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
26096
26097 1998-08-02  Jim Meyering  <meyering@ascend.com>
26098
26099         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
26100         in acconfig.h manually.
26101
26102 1998-07-31  Paul Eggert  <eggert@twinsun.com>
26103
26104         * m4/st_mtim.m4: New file.
26105
26106 1998-07-28  Jim Meyering  <meyering@ascend.com>
26107
26108         * m4/utimes.m4: Undef stat.
26109
26110 1998-07-25  Jim Meyering  <meyering@ascend.com>
26111
26112         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
26113         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
26114
26115 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
26116
26117         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
26118         uid and gid actually remain unchanged.
26119
26120 1998-07-07  Jim Meyering  <meyering@ascend.com>
26121
26122         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
26123
26124 1998-07-04  Jim Meyering  <meyering@ascend.com>
26125
26126         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
26127         to prove that this macro can be used in packages without regex.c.
26128
26129 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
26130
26131         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
26132         is to be used.
26133
26134 1998-07-03  Jim Meyering  <meyering@ascend.com>
26135
26136         * m4/gettext.m4: Add -lintl if it's found to be necessary.
26137
26138         * m4/gettext.m4: New file -- from gettext-0.10.35.
26139         * m4/lcmessage.m4: Likewise.
26140         * m4/progtest.m4: Likewise.
26141
26142         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
26143         * m4/jm-macros.m4: Require the new macro.
26144
26145 1998-06-29  Jim Meyering  <meyering@ascend.com>
26146
26147         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
26148         for the definition of NGROUPS (used in a system header included
26149         by sys/mount.h).
26150
26151 1998-06-28  Jim Meyering  <meyering@ascend.com>
26152
26153         * m4/ls-mntd-fs.m4: New file.
26154         * m4/fstypename.m4: New file.
26155
26156         * m4/jm-macros.m4: Require the new macro.
26157         * m4/jm-glibc-io.m4: New file.
26158
26159 1998-05-19  Jim Meyering  <meyering@ascend.com>
26160
26161         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
26162         * m4/lchown.m4: New file.
26163
26164         * m4/Makefile.am.in: New file.
26165         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
26166
26167 1998-05-14  Jim Meyering  <meyering@ascend.com>
26168
26169         * m4/Makefile.am (EXTRA_DIST): Add them.
26170         * m4/jm-macros.m4: New file.
26171         * m4/utimbuf.m4: New file.
26172
26173 1998-05-12  Jim Meyering  <meyering@ascend.com>
26174
26175         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
26176
26177 1998-05-11  Jim Meyering  <meyering@ascend.com>
26178
26179         * m4/isc-posix.m4: New file.
26180
26181 1998-05-10  Jim Meyering  <meyering@ascend.com>
26182
26183         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
26184
26185 1998-05-09  Jim Meyering  <meyering@ascend.com>
26186
26187         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
26188         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
26189         with automake.
26190
26191         * m4/ssize_t.m4: New file.
26192         * m4/mktime.m4: Remove file -- the new automake has this now.
26193
26194 1998-04-26  Jim Meyering  <meyering@ascend.com>
26195
26196         * m4/assert.m4: New file.
26197         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
26198
26199 1998-04-05  Jim Meyering  <meyering@ascend.com>
26200
26201         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
26202         (jm_PREREQ): Use it here.
26203
26204 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
26205
26206         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
26207         in acconfig.h.
26208
26209 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
26210
26211         * m4/prereq.m4: New file.
26212         * m4/error.m4: New file.
26213         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
26214
26215 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
26216
26217         * m4/getline.m4: Don't set am_cv_func_working_getline before the
26218         cache-check for the same variable -- that defeated the purpose of
26219         the test; the test program was never run.  This was a problem only
26220         on systems with losing getline functions -- HP-UX 10.20 is one.
26221         Reported by Bjorn Helgaas.
26222
26223 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
26224
26225         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
26226
26227 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
26228
26229         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
26230
26231         * m4/const.m4: New file.  Use an initializer in this declaration
26232         typedef int charset[2]; const charset x;
26233         Reported by Bob Glickstein.
26234
26235 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
26236
26237         * m4/chown.m4: Fix reversed types on -1 args to chown.
26238         From Kaveh Ghazi.
26239
26240 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
26241
26242         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
26243         Add lseek and memchr.
26244
26245         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
26246         T.E.Dickey <dickey@clark.net> said that some older preprocessors
26247         have a 20-character limit on names.
26248
26249 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
26250
26251         * m4/inttypes_h.m4: New file.
26252         * m4/uintmax_t.m4: New file.
26253         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
26254
26255 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
26256   Free Software Foundation, Inc.
26257 Copying and distribution of this file, with or without modification,
26258 are permitted provided the copyright notice and this notice are preserved.