25d46cda3013a4092ecc92e4b5cbf33b9d6de982
[gnulib.git] / ChangeLog
1 2007-01-18  Bruno Haible  <bruno@clisp.org>
2
3         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
4         gettimeofday.
5
6         * tests/test-gettimeofday.c: Include <time.h>.
7         (dummy): Remove variable.
8
9         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
10         gl_HEADER_SYS_TIME_H.
11         (gl_HEADER_SYS_TIME_H): New macro.
12
13         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
14         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
15         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
16         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
17         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
18         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
19         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
20         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
21         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
22         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
23         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
24
25         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
26         last change; it caused a compilation error when cross-compiling to
27         Cygwin.
28
29 2007-01-18  Jim Meyering  <jim@meyering.net>
30
31         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
32         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
33         than the race-prone "test -d sys || mkdir sys".
34         (configure.ac): Use AC_PROG_MKDIR_P.
35         * modules/sys_select: Likewise.
36         * modules/sys_socket: Likewise.
37         * modules/sys_time: Likewise.
38
39 2007-01-18  Eric Blake  <ebb9@byu.net>
40
41         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
42         replace gettimeofday.
43         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
44         name, to avoid infinite recursion.
45
46 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
47
48         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
49         module sys_time.
50         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
51         assume timespec.h defines struct timeval.
52         * lib/settime.c: Likewise.
53         * lib/utimens.c: Likewise.
54         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
55         since we now assume the gettimeofday module.
56         * lib/tempname.c (__gen_tempname): Likewise.
57         * lib/gettimeofday.h: Remove.
58         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
59         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
60         Include <time.h>, for 'time()'.
61         (localtime_buffer_addr): Also use this workaround if
62         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
63         to simplify the uses.  All uses changed.
64         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
65         that #undef is inside {}, and 'const' follows type name consistently.
66         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
67         (gettimeofday): Do not use the maximum possible value for
68         tv->tv_usec, since that might break usages other than ls.c.
69         Instead, we'll leave ls.c alone.  This undoes today's patch
70         by Bruno.  Add a compile-time warning for 1s-clock resolution;
71         we've never observed the problem but might as well keep the
72         canary.
73         * lib/nanosleep.c: Include timespec.h first, for interface check.
74         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
75         now assume the sys_time module.
76         * lib/tempname.c: Likewise.
77         * lib/timespec.h: Likewise.
78         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
79         needed.
80         * lib/strftime.c: Likewise.
81         * lib/timespec.h: Likewise.
82         * lib/posixtm.c: Include posixtm.h first, for interface check.
83         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
84         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
85         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
86         * lib/sys_time_.h: New file.
87         * lib/timespec.h (struct timespec): Use long int, not long.
88         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
89         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
90         Remove obsolescent call to AC_HEADER_TIME.
91         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
92         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
93         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
94         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
95         Likewise.
96         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
97         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
98         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
99         into the sys_time module.  Check for gettimeofday just once.
100         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
101         for gettimeofday signature to just check the signature.  Merely
102         compile it, since linking doesn't test signature.  Improve test for
103         whether gettimeofday.o is actually needed.
104         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
105         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
106         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
107         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
108         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
109         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
110         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
111         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
112         than worrying about sys/time.h.
113         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
114         Don't bother worrying about TIME_WITH_SYS_TIME.
115         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
116         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
117         * m4/sys_time_h.m4: New file.
118         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
119         Don't include sys/time.h.  Return from main rather than exiting.
120         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
121         all uses changed.
122         * modules/gethrxtime (Depends-on): Add sys_time.
123         * modules/gettime (Depends-on): Likewise.
124         * modules/gettimeofday (Depends-on): Likewise.
125         * modules/nanosleep (Depends-on): Likewise.
126         * modules/settime (Depends-on): Likewise.
127         * modules/tempname (Depends-on): Likewise.
128         * modules/utimens (Depends-on): Likewise.
129         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
130         (Include:) Change back to <sys/time.h>.
131         (Maintainer:) Add self.
132         * modules/sys_time: New file.
133         * modules/tempname (Depends-on): Add gettimeofday.
134         * tests/test-gettimeofday.c: Include <sys/time.h>
135         rather than gettimeofday.h.
136
137 2007-01-17  Bruno Haible  <bruno@clisp.org>
138
139         * gnulib-tool (func_get_license): Revert last patch. Instead, let
140         the license default to GPL.
141         (func_create_testdir): Don't complain if a module is LGPL and its
142         tests module depends on GPLed modules.
143
144 2007-01-17  Bruno Haible  <bruno@clisp.org>
145
146         * lib/gettimeofday.c (gettimeofday): Add code for the case
147         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
148         maximum possible value for tv->tv_usec, rather than the minimum one.
149
150 2005-10-08  Martin Lambers  <marlam@marlam.de>
151 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
152 2007-01-16  Bruno Haible  <bruno@clisp.org>
153
154         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
155         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
156         gl_FUNC_GETTIMEOFDAY.
157         (Include): Add gettimeofday.h.
158         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
159         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
160         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
161         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
162         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
163         * lib/gettimeofday.h: New file.
164         * lib/gettimeofday.c: Include <sys/timeb.h>.
165         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
166         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
167         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
168         fall back on time().
169
170         * tests/test-gettimeofday.c: New file.
171         * modules/gettimeofday-tests: New file.
172
173 2007-01-16  Eric Blake  <ebb9@byu.net>
174
175         * modules/fnmatch (Depends-on): Depend on wchar.
176         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
177         * m4/fnmatch.m4: Likewise.
178         * modules/mbchar (Makefile.am): Assume <wchar.h>.
179         * m4/mbchar.m4: Likewise.
180         * modules/mbswidth (Depends-on): Depend on wchar.
181         * lib/mbswidth.c: Assume <wchar.h>.
182         * m4/mbswidth.m4: Likewise.
183         * modules/quotearg (Depends-on): Depend on wchar.
184         * lib/quotearg.c: Assume <wchar.h>.
185         * m4/quotearg.m4: Likewise.
186         * modules/regex (Depends-on): Depend on wchar.
187         * lib/regex_internal.h: Assume <wchar.h>.
188         * m4/regex.m4: Likewise.
189         * modules/stdint (Depends-on): Depend on wchar.
190         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
191         * m4/stdint.m4: Likewise.
192         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
193         * modules/strftime (Depends-on): Depend on wchar.
194         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
195         * modules/strtol (Depends-on): Depend on wchar.
196         * lib/strtol.c: Assume <wchar.h>.
197         * modules/wcwidth (Depends-on): Depend on wchar.
198         * lib/wcwidth.h: Assume <wchar.h>.
199         * m4/wcwidth.m4: Likewise.
200
201 2007-01-16  Bruno Haible  <bruno@clisp.org>
202
203         * modules/csharpexec-script: New, created from...
204         * modules/csharpexec: ... this.
205
206 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
207
208         * modules/javaexec-script: New, created from...
209         * modules/javaexec: ... this.
210
211 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
212
213         * modules/poll (Dependencies): Add sys_select.
214
215 2007-01-15  Jim Meyering  <jim@meyering.net>
216
217         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
218         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
219         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
220         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
221
222 2007-01-15  Bruno Haible  <bruno@clisp.org>
223
224         * modules/striconveh: New file.
225         * lib/striconveh.h: New file.
226         * lib/striconveh.c: New file.
227         * MODULES.html.sh (Internationalization functions): Add striconveh.
228
229         * modules/striconveh-tests: New file.
230         * tests/test-striconveh.c: New file.
231
232 2007-01-15  Bruno Haible  <bruno@clisp.org>
233
234         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
235         not from GNU libiconv or GNU libc.
236
237 2007-01-15  Bruno Haible  <bruno@clisp.org>
238
239         * doc/gnulib-intro.texi (Copyright): Explain the different license
240         terms for module descriptions, autoconf macros, tests, documentation.
241
242 2007-01-14  Bruno Haible  <bruno@clisp.org>
243
244         * modules/striconv-tests: New file.
245         * tests/test-striconv.c: New file.
246
247 2007-01-14  Bruno Haible  <bruno@clisp.org>
248
249         * modules/iconv-tests: New file.
250         * tests/test-iconv.c: New file.
251
252 2007-01-14  Bruno Haible  <bruno@clisp.org>
253
254         * gnulib-tool (func_get_license): For test modules, use the license of
255         the main module.
256
257 2007-01-14  Bruno Haible  <bruno@clisp.org>
258
259         * modules/iconv (Include): Clarify that <iconv.h> can only be included
260         if iconv is found to exist.
261
262 2007-01-14  Bruno Haible  <bruno@clisp.org>
263
264         * modules/c-ctype-tests: New file.
265         * tests/test-c-ctype.c: New file.
266
267 2007-01-14  Bruno Haible  <bruno@clisp.org>
268
269         * modules/binary-io-tests: New file.
270         * tests/test-binary-io.sh: New file.
271         * tests/test-binary-io.c: New file.
272
273 2007-01-14  Bruno Haible  <bruno@clisp.org>
274
275         * modules/array-oset-tests: New file.
276         * tests/test-array_oset.c: New file.
277
278 2007-01-14  Bruno Haible  <bruno@clisp.org>
279
280         * modules/array-list-tests: New file.
281         * tests/test-array_list.c: New file.
282
283 2007-01-14  Bruno Haible  <bruno@clisp.org>
284
285         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
286         and make.
287         Reported by Simon Josefsson in
288         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
289
290 2007-01-14  Bruno Haible  <bruno@clisp.org>
291
292         * modules/allocsa-tests: New file.
293         * tests/test-allocsa.c: New file.
294
295 2007-01-14  Bruno Haible  <bruno@clisp.org>
296
297         * modules/fchdir (Depends-on): Add absolute-header.
298         * modules/unistd (Depends-on): Likewise.
299
300 2006-12-30  Bruno Haible  <bruno@clisp.org>
301
302         * modules/fchdir: New file.
303         * modules/unistd (Files): Add lib/unistd_.h.
304         (Makefile.am): Generate unistd.h from unistd_.h.
305         * lib/fchdir.c: New file.
306         * lib/dirent_.h: New file.
307         * lib/unistd_.h: New file.
308         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
309         * m4/fchdir.m4: New file.
310         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
311         (gl_HEADER_UNISTD): Invoke it.
312         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
313         function.
314         * lib/backupfile.c (opendir, closedir): Undefine.
315         * lib/chown.c (open, close): Undefine.
316         * lib/clean-temp.c (open, close): Undefine.
317         * lib/copy-file.c (open, close): Undefine.
318         * lib/execute.c (open, close): Undefine.
319         * lib/fsusage.c (open, close): Undefine.
320         * lib/gc-gnulib.c (open, close): Undefine.
321         * lib/getcwd.c (opendir, closedir): Undefine.
322         * lib/glob.c (opendir, closedir): Undefine.
323         * lib/javacomp.c (open, close): Undefine.
324         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
325         * lib/openat-proc.c (open, close): Undefine.
326         * lib/pagealign_alloc.c (open, close): Undefine.
327         * lib/pipe.c (open, close): Undefine.
328         * lib/progreloc.c (open, close): Undefine.
329         * lib/savedir.c (opendir, closedir): Undefine.
330         * lib/utime.c (open, close): Undefine.
331         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
332
333 2007-01-10  Bruno Haible  <bruno@clisp.org>
334
335         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
336
337 2007-01-12  Eric Blake  <ebb9@byu.net>
338
339         Provide a robust <wchar.h>.  Further simplifications are now
340         possible in other modules, but not included here.
341         * modules/wchar: New module.
342         * m4/wchar.m4: New file.
343         * lib/wchar_.h: Likewise.
344         * modules/mbchar (Depends-on): Depend on wchar, as the first use
345         of the new module.
346         * MODULES.html.sh (Extended multibyte and wide character utilities):
347         New section.
348
349 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
350
351         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
352         to a reasonable default for memory allocation.
353         (xreadlink): Don't allocate a huge buffer, to work around a buggy
354         file system that reports garbage st_size values for symlinks.
355         Problem reported by Liyang Hu.
356
357 2007-01-11  Simon Josefsson  <simon@josefsson.org>
358
359         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
360         Emacs .#* auto-save files).
361
362 2007-01-11  Bruno Haible  <bruno@clisp.org>
363
364         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
365         directory.
366
367 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
368
369         Use @...@ consistently in lib/wctype_.h.
370         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
371         on it being set to 1 or 0.
372         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
373         go back to AC_SUBSTing it.
374         * modules/wctype (Makefile.am): Undo previous change.
375
376 2007-01-10  Eric Blake  <ebb9@byu.net>
377
378         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
379         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
380         * modules/wctype (Makefile.am): Likewise.
381         Reported by Chris McGuire.
382
383 2007-01-10  Jim Meyering  <jim@meyering.net>
384
385         fts.c: a small readability/maintainability improvement
386         * lib/fts.c (fts_read): Make this code slightly more readable and
387         maintainable by hoisting the "sp->fts_cur = p" assignments to
388         immediately follow the statements that set P.  Derived from
389         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
390
391 2007-01-10  Eric Blake  <ebb9@byu.net>
392
393         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
394         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
395         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
396         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
397         Reported by Chris McGuire.
398
399 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
400
401         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
402         in sed script.
403
404 2007-01-09  Bruno Haible  <bruno@clisp.org>
405
406         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
407         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
408         variables.
409         (func_module): Use them.
410
411 2007-01-09  Bruno Haible  <bruno@clisp.org>
412
413         * modules/unistr/base: New file.
414         * lib/unistr.h: New file.
415
416         * modules/unistr/u8-to-u16: New file.
417         * lib/unistr/u8-to-u16.c: New file.
418
419         * modules/unistr/u8-to-u32: New file.
420         * lib/unistr/u8-to-u32.c: New file.
421
422         * modules/unistr/u16-to-u8: New file.
423         * lib/unistr/u16-to-u8.c: New file.
424
425         * modules/unistr/u16-to-u32: New file.
426         * lib/unistr/u16-to-u32.c: New file.
427
428         * modules/unistr/u32-to-u8: New file.
429         * lib/unistr/u32-to-u8.c: New file.
430
431         * modules/unistr/u32-to-u16: New file.
432         * lib/unistr/u32-to-u16.c: New file.
433
434         * modules/unistr/u8-check: New file.
435         * modules/unistr/u16-check: New file.
436         * modules/unistr/u32-check: New file.
437         * lib/unistr/u8-check.c: New file.
438         * lib/unistr/u16-check.c: New file.
439         * lib/unistr/u32-check.c: New file.
440
441         * modules/unistr/u8-chr: New file.
442         * modules/unistr/u16-chr: New file.
443         * modules/unistr/u32-chr: New file.
444         * lib/unistr/u8-chr.c: New file.
445         * lib/unistr/u16-chr.c: New file.
446         * lib/unistr/u32-chr.c: New file.
447
448         * modules/unistr/u8-cmp: New file.
449         * modules/unistr/u16-cmp: New file.
450         * modules/unistr/u32-cmp: New file.
451         * lib/unistr/u8-cmp.c: New file.
452         * lib/unistr/u16-cmp.c: New file.
453         * lib/unistr/u32-cmp.c: New file.
454
455         * modules/unistr/u8-cpy: New file.
456         * modules/unistr/u16-cpy: New file.
457         * modules/unistr/u32-cpy: New file.
458         * lib/unistr/u8-cpy.c: New file.
459         * lib/unistr/u16-cpy.c: New file.
460         * lib/unistr/u32-cpy.c: New file.
461         * lib/unistr/u-cpy.h: New file.
462
463         * modules/unistr/u8-cpy-alloc: New file.
464         * modules/unistr/u16-cpy-alloc: New file.
465         * modules/unistr/u32-cpy-alloc: New file.
466         * lib/unistr/u8-cpy-alloc.c: New file.
467         * lib/unistr/u16-cpy-alloc.c: New file.
468         * lib/unistr/u32-cpy-alloc.c: New file.
469         * lib/unistr/u-cpy-alloc.h: New file.
470
471         * modules/unistr/u8-endswith: New file.
472         * modules/unistr/u16-endswith: New file.
473         * modules/unistr/u32-endswith: New file.
474         * lib/unistr/u8-endswith.c: New file.
475         * lib/unistr/u16-endswith.c: New file.
476         * lib/unistr/u32-endswith.c: New file.
477         * lib/unistr/u-endswith.h: New file.
478
479         * modules/unistr/u8-mblen: New file.
480         * modules/unistr/u16-mblen: New file.
481         * modules/unistr/u32-mblen: New file.
482         * lib/unistr/u8-mblen.c: New file.
483         * lib/unistr/u16-mblen.c: New file.
484         * lib/unistr/u32-mblen.c: New file.
485
486         * modules/unistr/u8-mbtouc: New file.
487         * modules/unistr/u16-mbtouc: New file.
488         * modules/unistr/u32-mbtouc: New file.
489         * lib/unistr/u8-mbtouc.c: New file.
490         * lib/unistr/u16-mbtouc.c: New file.
491         * lib/unistr/u32-mbtouc.c: New file.
492
493         * modules/unistr/u8-mbtouc-safe: New file.
494         * modules/unistr/u16-mbtouc-safe: New file.
495         * modules/unistr/u32-mbtouc-safe: New file.
496         * lib/unistr/u8-mbtouc-safe.c: New file.
497         * lib/unistr/u16-mbtouc-safe.c: New file.
498         * lib/unistr/u32-mbtouc-safe.c: New file.
499
500         * modules/unistr/u8-move: New file.
501         * modules/unistr/u16-move: New file.
502         * modules/unistr/u32-move: New file.
503         * lib/unistr/u8-move.c: New file.
504         * lib/unistr/u16-move.c: New file.
505         * lib/unistr/u32-move.c: New file.
506         * lib/unistr/u-move.h: New file.
507
508         * modules/unistr/u8-next: New file.
509         * modules/unistr/u16-next: New file.
510         * modules/unistr/u32-next: New file.
511         * lib/unistr/u8-next.c: New file.
512         * lib/unistr/u16-next.c: New file.
513         * lib/unistr/u32-next.c: New file.
514
515         * modules/unistr/u8-prev: New file.
516         * modules/unistr/u16-prev: New file.
517         * modules/unistr/u32-prev: New file.
518         * lib/unistr/u8-prev.c: New file.
519         * lib/unistr/u16-prev.c: New file.
520         * lib/unistr/u32-prev.c: New file.
521
522         * modules/unistr/u8-set: New file.
523         * modules/unistr/u16-set: New file.
524         * modules/unistr/u32-set: New file.
525         * lib/unistr/u8-set.c: New file.
526         * lib/unistr/u16-set.c: New file.
527         * lib/unistr/u32-set.c: New file.
528         * lib/unistr/u-set.h: New file.
529
530         * modules/unistr/u8-startswith: New file.
531         * modules/unistr/u16-startswith: New file.
532         * modules/unistr/u32-startswith: New file.
533         * lib/unistr/u8-startswith.c: New file.
534         * lib/unistr/u16-startswith.c: New file.
535         * lib/unistr/u32-startswith.c: New file.
536         * lib/unistr/u-startswith.h: New file.
537
538         * modules/unistr/u8-stpcpy: New file.
539         * modules/unistr/u16-stpcpy: New file.
540         * modules/unistr/u32-stpcpy: New file.
541         * lib/unistr/u8-stpcpy.c: New file.
542         * lib/unistr/u16-stpcpy.c: New file.
543         * lib/unistr/u32-stpcpy.c: New file.
544         * lib/unistr/u-stpcpy.h: New file.
545
546         * modules/unistr/u8-stpncpy: New file.
547         * modules/unistr/u16-stpncpy: New file.
548         * modules/unistr/u32-stpncpy: New file.
549         * lib/unistr/u8-stpncpy.c: New file.
550         * lib/unistr/u16-stpncpy.c: New file.
551         * lib/unistr/u32-stpncpy.c: New file.
552         * lib/unistr/u-stpncpy.h: New file.
553
554         * modules/unistr/u8-strcat: New file.
555         * modules/unistr/u16-strcat: New file.
556         * modules/unistr/u32-strcat: New file.
557         * lib/unistr/u8-strcat.c: New file.
558         * lib/unistr/u16-strcat.c: New file.
559         * lib/unistr/u32-strcat.c: New file.
560         * lib/unistr/u-strcat.h: New file.
561
562         * modules/unistr/u8-strchr: New file.
563         * modules/unistr/u16-strchr: New file.
564         * modules/unistr/u32-strchr: New file.
565         * lib/unistr/u8-strchr.c: New file.
566         * lib/unistr/u16-strchr.c: New file.
567         * lib/unistr/u32-strchr.c: New file.
568
569         * modules/unistr/u8-strcmp: New file.
570         * modules/unistr/u16-strcmp: New file.
571         * modules/unistr/u32-strcmp: New file.
572         * lib/unistr/u8-strcmp.c: New file.
573         * lib/unistr/u16-strcmp.c: New file.
574         * lib/unistr/u32-strcmp.c: New file.
575
576         * modules/unistr/u8-strcpy: New file.
577         * modules/unistr/u16-strcpy: New file.
578         * modules/unistr/u32-strcpy: New file.
579         * lib/unistr/u8-strcpy.c: New file.
580         * lib/unistr/u16-strcpy.c: New file.
581         * lib/unistr/u32-strcpy.c: New file.
582         * lib/unistr/u-strcpy.h: New file.
583
584         * modules/unistr/u8-strcspn: New file.
585         * modules/unistr/u16-strcspn: New file.
586         * modules/unistr/u32-strcspn: New file.
587         * lib/unistr/u8-strcspn.c: New file.
588         * lib/unistr/u16-strcspn.c: New file.
589         * lib/unistr/u32-strcspn.c: New file.
590         * lib/unistr/u-strcspn.h: New file.
591
592         * modules/unistr/u8-strdup: New file.
593         * modules/unistr/u16-strdup: New file.
594         * modules/unistr/u32-strdup: New file.
595         * lib/unistr/u8-strdup.c: New file.
596         * lib/unistr/u16-strdup.c: New file.
597         * lib/unistr/u32-strdup.c: New file.
598         * lib/unistr/u-strdup.h: New file.
599
600         * modules/unistr/u8-strlen: New file.
601         * modules/unistr/u16-strlen: New file.
602         * modules/unistr/u32-strlen: New file.
603         * lib/unistr/u8-strlen.c: New file.
604         * lib/unistr/u16-strlen.c: New file.
605         * lib/unistr/u32-strlen.c: New file.
606         * lib/unistr/u-strlen.h: New file.
607
608         * modules/unistr/u8-strmblen: New file.
609         * modules/unistr/u16-strmblen: New file.
610         * modules/unistr/u32-strmblen: New file.
611         * lib/unistr/u8-strmblen.c: New file.
612         * lib/unistr/u16-strmblen.c: New file.
613         * lib/unistr/u32-strmblen.c: New file.
614
615         * modules/unistr/u8-strmbtouc: New file.
616         * modules/unistr/u16-strmbtouc: New file.
617         * modules/unistr/u32-strmbtouc: New file.
618         * lib/unistr/u8-strmbtouc.c: New file.
619         * lib/unistr/u16-strmbtouc.c: New file.
620         * lib/unistr/u32-strmbtouc.c: New file.
621
622         * modules/unistr/u8-strncat: New file.
623         * modules/unistr/u16-strncat: New file.
624         * modules/unistr/u32-strncat: New file.
625         * lib/unistr/u8-strncat.c: New file.
626         * lib/unistr/u16-strncat.c: New file.
627         * lib/unistr/u32-strncat.c: New file.
628         * lib/unistr/u-strncat.h: New file.
629
630         * modules/unistr/u8-strncmp: New file.
631         * modules/unistr/u16-strncmp: New file.
632         * modules/unistr/u32-strncmp: New file.
633         * lib/unistr/u8-strncmp.c: New file.
634         * lib/unistr/u16-strncmp.c: New file.
635         * lib/unistr/u32-strncmp.c: New file.
636
637         * modules/unistr/u8-strncpy: New file.
638         * modules/unistr/u16-strncpy: New file.
639         * modules/unistr/u32-strncpy: New file.
640         * lib/unistr/u8-strncpy.c: New file.
641         * lib/unistr/u16-strncpy.c: New file.
642         * lib/unistr/u32-strncpy.c: New file.
643         * lib/unistr/u-strncpy.h: New file.
644
645         * modules/unistr/u8-strnlen: New file.
646         * modules/unistr/u16-strnlen: New file.
647         * modules/unistr/u32-strnlen: New file.
648         * lib/unistr/u8-strnlen.c: New file.
649         * lib/unistr/u16-strnlen.c: New file.
650         * lib/unistr/u32-strnlen.c: New file.
651         * lib/unistr/u-strnlen.h: New file.
652
653         * modules/unistr/u8-strpbrk: New file.
654         * modules/unistr/u16-strpbrk: New file.
655         * modules/unistr/u32-strpbrk: New file.
656         * lib/unistr/u8-strpbrk.c: New file.
657         * lib/unistr/u16-strpbrk.c: New file.
658         * lib/unistr/u32-strpbrk.c: New file.
659         * lib/unistr/u-strpbrk.h: New file.
660
661         * modules/unistr/u8-strrchr: New file.
662         * modules/unistr/u16-strrchr: New file.
663         * modules/unistr/u32-strrchr: New file.
664         * lib/unistr/u8-strrchr.c: New file.
665         * lib/unistr/u16-strrchr.c: New file.
666         * lib/unistr/u32-strrchr.c: New file.
667
668         * modules/unistr/u8-strspn: New file.
669         * modules/unistr/u16-strspn: New file.
670         * modules/unistr/u32-strspn: New file.
671         * lib/unistr/u8-strspn.c: New file.
672         * lib/unistr/u16-strspn.c: New file.
673         * lib/unistr/u32-strspn.c: New file.
674         * lib/unistr/u-strspn.h: New file.
675
676         * modules/unistr/u8-strstr: New file.
677         * modules/unistr/u16-strstr: New file.
678         * modules/unistr/u32-strstr: New file.
679         * lib/unistr/u8-strstr.c: New file.
680         * lib/unistr/u16-strstr.c: New file.
681         * lib/unistr/u32-strstr.c: New file.
682         * lib/unistr/u-strstr.h: New file.
683
684         * modules/unistr/u8-strtok: New file.
685         * modules/unistr/u16-strtok: New file.
686         * modules/unistr/u32-strtok: New file.
687         * lib/unistr/u8-strtok.c: New file.
688         * lib/unistr/u16-strtok.c: New file.
689         * lib/unistr/u32-strtok.c: New file.
690         * lib/unistr/u-strtok.h: New file.
691
692         * modules/unistr/u8-uctomb: New file.
693         * modules/unistr/u16-uctomb: New file.
694         * modules/unistr/u32-uctomb: New file.
695         * lib/unistr/u8-uctomb.c: New file.
696         * lib/unistr/u16-uctomb.c: New file.
697         * lib/unistr/u32-uctomb.c: New file.
698
699         * MODULES.html.sh (Unicode string functions): Add the new modules.
700
701 2007-01-08  Bruno Haible  <bruno@clisp.org>
702
703         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
704         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
705         subdirectories.
706
707 2007-01-08  Karl Berry  <karl@gnu.org>
708
709         * doc/error.texi: mention that main() fns must set program_name
710         when progname is used.
711
712 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
713
714         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
715         WCTYPE_H is empty, for the benefit of builds from non-distclean
716         directories.  Problem reported by Eric Blake in
717         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
718
719 2007-01-08  Bruno Haible  <bruno@clisp.org>
720
721         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
722         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
723         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
724         PROVIDE_CANONICALIZE_FILENAME_MODE.
725         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
726
727 2007-01-08  Bruno Haible  <bruno@clisp.org>
728
729         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
730         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
731         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
732         * lib/fts.c: Likewise.
733         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
734
735 2006-12-25  Bruno Haible  <bruno@clisp.org>
736
737         * modules/utf8-ucs4-safe: New file.
738         * lib/utf8-ucs4-safe.h: New file.
739         * lib/unistr/utf8-ucs4-safe.c: New file.
740
741         * modules/utf16-ucs4-safe: New file.
742         * lib/utf16-ucs4-safe.h: New file.
743         * lib/unistr/utf16-ucs4-safe.c: New file.
744
745         * MODULES.html.sh (Unicode string functions): Add the new modules.
746
747 2007-01-08  Bruno Haible  <bruno@clisp.org>
748
749         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
750         (Depends-on): Add unitypes.
751         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
752         (u8_mbtouc_aux): Move out to separate file.
753         (u8_mbtouc): Use ucs4_t, uint8_t types.
754         * lib/unistr/utf8-ucs4.c: New file.
755
756         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
757         (Depends-on): Add unitypes.
758         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
759         (u16_mbtouc_aux): Move out to separate file.
760         (u16_mbtouc): Use ucs4_t, uint16_t types.
761         * lib/unistr/utf16-ucs4.c: New file.
762
763         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
764         (Depends-on): Add unitypes.
765         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
766         (u8_uctomb_aux): Move out to separate file.
767         (u8_uctomb): Use ucs4_t, uint8_t types.
768         * lib/unistr/ucs4-utf8.c: New file.
769
770         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
771         (Depends-on): Add unitypes.
772         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
773         (u16_uctomb_aux): Move out to separate file.
774         (u16_uctomb): Use ucs4_t, uint16_t types.
775         * lib/unistr/ucs4-utf16.c: New file.
776
777 2006-12-25  Bruno Haible  <bruno@clisp.org>
778
779         * modules/unitypes: New file.
780         * lib/unitypes.h: New file.
781         * MODULES.html.sh (func_all_modules): New section "Unicode string
782         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
783         this section. Add unitypes.
784
785 2007-01-08  Bruno Haible  <bruno@clisp.org>
786
787         Avoid variable names that conflict with those from libtool.
788         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
789         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
790         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
791         library_names_spec to acl_library_names_spec, hardcode_* to
792         acl_hardcode_*.
793         Reported by Ralf Wildenhues.
794
795 2007-01-08  Bruno Haible  <bruno@clisp.org>
796
797         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
798         definition.
799         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
800         definition.
801         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
802         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
803         definition.
804         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
805         definition.
806         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
807         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
808         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
809         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
810         definition.
811         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
812         definition.
813         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
814         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
815         GC_USE_<algorithm>.
816         * lib/gc-libgcrypt.c: Likewise.
817         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
818         * modules/gc-arctwo (configure.ac): Likewise.
819         * modules/gc-des (configure.ac): Likewise.
820         * modules/gc-hmac-md5 (configure.ac): Likewise.
821         * modules/gc-hmac-sha1 (configure.ac): Likewise.
822         * modules/gc-md2 (configure.ac): Likewise.
823         * modules/gc-md4 (configure.ac): Likewise.
824         * modules/gc-md5 (configure.ac): Likewise.
825         * modules/gc-random (configure.ac): Likewise.
826         * modules/gc-rijndael (configure.ac): Likewise.
827         * modules/gc-sha1 (configure.ac): Likewise.
828
829 2007-01-08  Bruno Haible  <bruno@clisp.org>
830
831         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
832         macro definition.
833         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
834         definition.
835         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
836         definition.
837         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
838         * modules/fcntl-safer (configure.ac): Likewise.
839         * modules/fopen-safer (configure.ac): Likewise.
840         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
841         GNULIB_FWRITEERROR macro definition.
842
843 2007-01-08  Bruno Haible  <bruno@clisp.org>
844
845         * m4/gnulib-common.m4: New file.
846         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
847         (func_get_filelist): Add m4/gnulib-common.m4.
848
849 2007-01-08  Bruno Haible  <bruno@clisp.org>
850
851         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
852         command.
853
854 2007-01-08  Jim Meyering  <jim@meyering.net>
855
856         Use a more robust test for a "can't happen" condition.
857         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
858         narrowed the st_size value.  Presuming the "can't happen" condition
859         is true, that narrowing could conceivably convert an invalid st_size
860         value into a valid one.  Instead, use a change based on Matthew
861         Woehlke's original patch.
862
863         Slight readability improvement: use an assert-like macro
864         in place of literal "abort ()" uses.
865         * lib/fts.c (fts_assert): Define.
866         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
867         Use this macro instead of a bare 'abort'.
868
869 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
870
871         Don't worry about using IRIX 5.3's wctype.h broken definitions;
872         simply work around them.
873         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
874         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
875         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before declaring.
876         Don't bother to define as macros, since the standard doesn't require it.
877         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
878         longer worry about IRIX 5.3.
879         (HAVE_WCTYPE_CTMP_BUG): Remove.
880
881 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
882
883         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
884         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
885         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
886         Problems reported by Georg Schwarz for IRIX 5.3.
887
888         * gnulib-tool (autoconf_minversion): Take the maximum version number
889         found, not the minimum.  Problem reported by James Youngman.
890
891 2007-01-03  Karl Berry  <karl@gnu.org>
892
893         * doc/error.texi: new file, explaining interaction with progname.
894         * doc/gnulib.texi: include it.  Update copyright.
895
896 2007-01-03  Simon Josefsson  <simon@josefsson.org>
897
898         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
899         AC_CANONICAL_HOST, to improve autobuild outputs.
900
901 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
902             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
903
904         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
905         sockets, server sockets, and other file descriptors.  Count errors
906         to compute the return value.  Reorder the code a bit to be easier
907         to follow.  Don't set event bits that were not requested (except
908         POLLERR and POLLHUP).
909
910 2007-01-01  Bruno Haible  <bruno@clisp.org>
911
912         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
913
914 2007-01-03  Jim Meyering  <jim@meyering.net>
915
916         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
917
918 2007-01-02  Bruno Haible  <bruno@clisp.org>
919
920         * modules/settime (Include): Require timespec.h.
921         * modules/nanosleep (Include): Likewise.
922
923 2007-01-01  Bruno Haible  <bruno@clisp.org>
924
925         * gnulib-tool (func_emit_copyright_notice): Bump year.
926         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
927
928 2007-01-01  Bruno Haible  <bruno@clisp.org>
929
930         Improve support for OpenBSD.
931         * build-aux/config.rpath (libname_spec): Export.
932         (library_names_spec): New variable. Export.
933         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
934         library_names_spec from the config.rpath output. Locate shared library
935         through the name pattern in library_names_spec.
936
937 2007-01-01  Eric Blake  <ebb9@byu.net>
938
939         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
940
941 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
942
943         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
944         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
945         assume the C locale, and avoid an "eval" that could cause trouble.
946         Problem with SORT reported by Bob Proulx.
947
948         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
949         Define.  Trivial patch from Henning Nielsen Lund, originally
950         sent to bug-grep@gnu.org today.
951
952 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
953
954         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
955         struct stat.  Problem reported by Henning Nielsen Lund.
956         * lib/acl.c: Include acl.h first, to check interface.  Don't
957         bother to include sys/types.h and sys/stat.h again.
958
959 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
960
961         Import the following change from libc; problem reported by
962         Sven Verdoolaege.
963
964         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
965
966         [BZ #1373]
967         * lib/argp.h: Remove __NTH for __argp_usage inline function.
968
969 2006-12-28  Jim Meyering  <jim@meyering.net>
970
971         * build-aux/announce-gen: Do not assume that the package
972         builds any of tar.gz, tar.bz2, and .xdelta files.
973         Suggestion from Simon Josefsson.
974
975 2006-12-28  Simon Josefsson  <simon@josefsson.org>
976
977         * modules/announce-gen: New file.
978
979 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
980
981         * lib/mbchar.h: Just include <wctype.h>; the wctype module
982         handles its gotchas now.
983         * lib/mbswidth.c: Likewise.
984         * lib/wcwidth.h: Likewise.
985         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
986         and iswcntrl; the wctype module does this stuff now.
987         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
988         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
989         * modules/mbchar (Depends-on): Add wctype.
990         * modules/mbswidth (Depends-on): Likewise.
991         * modules/wcwidth (Depends-on): Likewise.
992
993 2006-12-27  Eric Blake  <ebb9@byu.net>
994
995         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
996         module uses more than what <wctype.h> is required to provide.
997
998 2006-12-26  Eric Blake  <ebb9@byu.net>
999
1000         * gnulib-tool (sed_extract_prog): Avoid space-tab.
1001
1002 2006-12-26  Eric Blake  <ebb9@byu.net>
1003
1004         * modules/absolute-header: New module.
1005         * modules/fcntl (Depends-on): Depend on it.
1006         * modules/inttypes (Depends-on): Likewise.
1007         * modules/stdint (Depends-on): Likewise.
1008         * modules/sys_stat (Depends-on): Likewise.
1009         * modules/wctype (Depends-on): Likewise.
1010         * MODULES.html.sh (Support for building libraries and
1011         executables): Document it.
1012
1013 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
1014
1015         * gnulib-tool (SED): Remove, undoing previous change.
1016         The problem was that it broke coreutils on Solaris, because
1017         "sed --posix" leaked into a makefile.
1018         (sed): New alias, if 'alias' and GNU sed.
1019
1020 2006-12-24  Jim Meyering  <jim@meyering.net>
1021
1022         Work around an fchownat bug in glibc-2.4:
1023         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
1024         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
1025         in spite of the -P option.
1026         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
1027         New macros.
1028         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
1029         * modules/openat (Files): Add lib/fchownat.c.
1030         * lib/openat.c (fchownat): Don't define here.  Move to...
1031         * lib/fchownat.c: ...this new file.
1032
1033 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
1034
1035         Fix bug reported by Bruno Haible in
1036         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
1037         where quotearg.c didn't compile on Mac OS X 10.2 because it
1038         lacks <wchar.h> and wint_t.
1039         * lib/wctype_.h (__wctype_wint_t): New type.
1040         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
1041         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
1042         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
1043         Arg is now of type __wctype_wint_t, not wint_t.
1044         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
1045         substitute HAVE_WINT_T.
1046         * modules/wctype (Files): Add m4/wint_t.m4.
1047         (wctype.h): Substitute HAVE_WINT_T.
1048
1049 2006-12-23  Bruno Haible  <bruno@clisp.org>
1050
1051         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
1052
1053 2006-12-23  Bruno Haible  <bruno@clisp.org>
1054
1055         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
1056         S_ISLNK.
1057         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
1058         mingw.
1059
1060 2006-12-22  Bruno Haible  <bruno@clisp.org>
1061
1062         * lib/copy-file.c: Include acl.h.
1063         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
1064         Close the file descriptors only after being done with copy_acl.
1065         * modules/copy-file (Depends-on): Add acl.
1066
1067 2006-12-22  Bruno Haible  <bruno@clisp.org>
1068
1069         * gnulib-tool (SED): New variable.
1070         Use $SED instead of sed everywhere.
1071
1072 2006-12-22  Bruno Haible  <bruno@clisp.org>
1073
1074         * modules/no-c++: New file.
1075         * m4/no-c++.m4: New file.
1076         * MODULES.html.sh (Support for building libraries and executables):
1077         Add no-c++.
1078
1079 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
1080
1081         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
1082         Include <limits.h>, and use its INT_MAX to rewrite the
1083         j loop so that it does not overflow 'int'.  Problem reported by
1084         Ralf Wildenhues in
1085         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
1086         Play it safe by shifting left by 1 rather than multiplying by 2,
1087         as GCC is less likely to optimize this away when the value
1088         is signed (when it assumes overflow leads to undefined behavior).
1089         Also, don't assume time_t uses two's complement.
1090
1091 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
1092
1093         * MODULES.html.sh: New module wctype.
1094         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
1095         * lib/fnmatch.c: Don't bother to include <wchar.h> before
1096         <wctype.h>, since the new wctype module should fix this.
1097         * lib/quotearg.c: Include <wctype.h> unconditionally, since
1098         the wctype module should arrange for it.
1099         * lib/regex_internal.h: Likewise.
1100         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
1101         since the wctype module should handle this now.
1102         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
1103         * modules/fnmatch (Depends-on): Add wctype.
1104         * modules/quotearg (Depends-on): Likewise.
1105         * modules/regex (Depends-on): Likewise.
1106
1107 2006-12-19  Bruno Haible  <bruno@clisp.org>
1108
1109         * lib/strdup.h [C++]: Wrap definitions in extern "C".
1110         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
1111
1112 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1113
1114         * modules/savewd (Depends-on): Fix dependency on fcntl.
1115
1116 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
1117
1118         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
1119         conforms to C99, rather than relying on the user's environment
1120         setting of STDINT_H.
1121
1122 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
1123         and Eric Blake  <ebb9@byu.net>
1124
1125         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
1126         This is more consistent with the other defines here.
1127         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
1128         Port to z/OS.  Problem reported by Paul Gilmartin.
1129         Change local vars to use gl_ prefix rather than ac_.
1130         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
1131         with other defines.
1132         * modules/double-slash-root: New module.
1133         * modules/dirname (Files): Remove m4/double-slash-root.m4.
1134         (Depends-on): Add double-slash-root.
1135         * MODULES.html.sh (File system functions): Mention new module.
1136
1137 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
1138
1139         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
1140         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
1141         This is for the benefit of gzip, which doesn't do i18n.
1142
1143 2006-12-12  Jim Meyering  <jim@meyering.net>
1144
1145         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
1146         Reported by Andreas Schwab <schwab@suse.de>.
1147
1148 2006-12-12  Bruno Haible  <bruno@clisp.org>
1149
1150         Merge these changes.
1151         2006-09-05  Bruno Haible  <bruno@clisp.org>
1152         * lib/iconvme.c (iconv_string): No need to save and restore errno when
1153         iconv_alloc succeeded.
1154         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
1155         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
1156         test for " && dest " at the end - dest is always != NULL there. Call
1157         iconv with 4xNULL arguments initially, to reset the state. Call iconv
1158         with 2xNULL arguments, also to flush the state storage. Handle the
1159         IRIX iconv behaviour. Realloc the final result, to throw away unused
1160         memory.
1161
1162 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
1163
1164         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
1165         and fchmodat unconditionally, since glibc 2.4 has them.
1166         Problem reported by Arkadiusz Miskiewicz.
1167
1168 2006-12-10  Bruno Haible  <bruno@clisp.org>
1169
1170         * gnulib-tool (func_import): Show the include files only for those
1171         modules that are copied and specified.
1172         Reported by Karl Berry.
1173
1174 2006-12-08  Jim Meyering  <jim@meyering.net>
1175
1176         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
1177         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
1178
1179         * build-aux/announce-gen: Add two new options, both optional:
1180         --bootstrap-tools=TOOL_LIST
1181               a comma-separated list of tools, e.g.,
1182               autoconf,automake,bison,gnulib
1183         --gnulib-snapshot-date=DATE
1184               if gnulib is in the bootstrap tool list,
1185               then report this as the snapshot date.
1186               If not specified, use the current date/time.
1187               If you specify a date here, be sure it's UTC.
1188
1189 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1190
1191         * tests/test-argp-2.sh: Fix test to match actual output.
1192         (func_compare): Fix sed script to be portable.
1193
1194 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
1195
1196         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
1197         workaround for this case.  It is not autoconfigured now; offhand
1198         it's hard to see how to autoconfigure it.
1199
1200 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
1201
1202         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
1203         a directory that is about to be chowned.  Such a directory's
1204         initial file permissions should permit the owner only and this
1205         should not be changed until after the chown, since the group and
1206         other bits would be incorrect if they granted permission before
1207         the chown.
1208
1209         Fix porting problem for iswctype reported by Georg Schwarz in:
1210         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
1211         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
1212         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
1213         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
1214         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1215
1216 2006-12-03  Jim Meyering  <jim@meyering.net>
1217
1218         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
1219         p->fts_statp may not yet be defined.
1220         (fts_read): Instead, set it in the caller, once p->fts_statp is
1221         sure to be defined, and corresponds to a top-level directory.
1222         This bug made du -x fail.  Here's the coreutils test case:
1223         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
1224         Reported by Mike Frysinger.
1225
1226 2006-12-01  Jim Meyering  <jim@meyering.net>
1227
1228         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
1229         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
1230         Reported by Simon Josefsson.
1231
1232 2006-11-30  Jim Meyering  <jim@meyering.net>
1233
1234         * m4/warning.m4: Use the all-permissive copyright notice
1235         recommended by RMS (rather than LGPL).
1236         * m4/vararrays.m4: Likewise.
1237         * m4/flexmember.m4: Likewise.
1238
1239 2006-11-29  Bruno Haible  <bruno@clisp.org>
1240
1241         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1242         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
1243         using +=.
1244         Reported by Simon Josefsson <simon@josefsson.org>.
1245
1246 2006-11-28  James Youngman <jay@gnu.org>
1247
1248         * README: Advise users that they might find the bug-gnulib@gnu.org
1249         and autotools-announce@gnu.org mailing lists useful.
1250
1251 2006-11-28  Bruno Haible  <bruno@clisp.org>
1252
1253         * m4/ptrdiff_max.m4: Remove file.
1254
1255 2006-11-21  Bruno Haible  <bruno@clisp.org>
1256
1257         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
1258         _AC_COMPUTE_INT.
1259         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1260         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
1261         _AC_COMPUTE_INT.
1262         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1263         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
1264         _AC_COMPUTE_INT.
1265         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1266
1267 2006-11-28  Jim Meyering  <jim@meyering.net>
1268
1269         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
1270         warning from "gcc -Wshadow" about shadowing the builtin.
1271
1272 2006-11-27  Bruno Haible  <bruno@clisp.org>
1273
1274         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
1275         _AC_COMPUTE_INT.
1276         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
1277
1278 2006-11-27  Bruno Haible  <bruno@clisp.org>
1279             Paul Eggert  <eggert@cs.ucla.edu>
1280
1281         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
1282
1283 2006-11-26  Bruno Haible  <bruno@clisp.org>
1284
1285         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
1286         noinst_LTLIBRARIES.
1287
1288 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
1289             Bruno Haible  <bruno@clisp.org>
1290
1291         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
1292         if compiling with "gcc -ansi".
1293
1294 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
1295
1296         Fix some incompatibilities with gcc -ansi -pedantic.
1297         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
1298         if compiling pedantically with GCC, unless it's C99 or later.
1299         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
1300         it mishandles gcc -ansi -pedantic as well.
1301         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
1302         if gcc -pedantic.
1303         * lib/regexec.c (check_node_accept_bytes): Don't use auto
1304         initializers for struct if -pedantic, unless it's C99 or later.
1305
1306 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
1307
1308         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
1309         Don't close an fd more than once. Identical atimes indicate
1310         success, not failure.
1311
1312 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
1313
1314         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
1315
1316 2006-11-23  Jim Meyering  <jim@meyering.net>
1317
1318         * build-aux/announce-gen: New file.  From coreutils.
1319
1320 2006-11-22  Jim Meyering  <jim@meyering.net>
1321
1322         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
1323         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
1324         (fts_read): Use a temporary to narrow the overused st_size member
1325         before using it in a switch statement.  Reported by Matthew Woehlke.
1326
1327         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
1328         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
1329
1330 2006-11-20  Bruno Haible  <bruno@clisp.org>
1331
1332         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
1333         changequote instead of pairs of brackets.
1334         Reported by Andreas Schwab <schwab@suse.de>.
1335
1336 2006-11-21  Jim Meyering  <jim@meyering.net>
1337
1338         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
1339         so as to remain compatible with older compilers.
1340         Patch from Michael Deutschmann.
1341
1342 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1343
1344         * MODULES.html.sh (File system functions): Add openat.
1345
1346         * lib/openat.h (rpl_fstatat): New macro, if
1347         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
1348         (fstatat): Define to rpl_fstatat under the same conditions,
1349         unless COMPILING_FSTATAT.
1350         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
1351         seems to have the bug.
1352         * lib/fstatat.c: New file.
1353         * modules/openat (Files): Add it.
1354
1355 2006-11-20  Bruno Haible  <bruno@clisp.org>
1356
1357         * Makefile: New file.
1358
1359 2006-11-20  Jim Meyering  <jim@meyering.net>
1360
1361         The beginnings of syntax-related checks for gnulib.
1362         * lib/Makefile: New file.
1363         * lib/t-idcache: New script.  Ensure that the two halves of
1364         idcache.c stay in sync.
1365
1366         * lib/idcache.c: Adjust comments in user- and group- portions to
1367         be more accurate, and to be consistent with one another.
1368
1369 2006-11-20  Jim Meyering  <jim@meyering.net>
1370
1371         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
1372         continue using the flexible array member (thus, this module performs
1373         half as many malloc calls), with the addition that...
1374         (getgroup, getuser): Consistently record a non-match via an empty
1375         "name" string, and map an empty string match to a NULL return value.
1376         * modules/idcache (Depends-on): Re-add flexmember.
1377
1378         * lib/idcache.c (getuser): Remove all uses of the register keyword.
1379         (getuidbyname, getgroup, getgidbyname): Likewise.
1380
1381         Use cleaner syntax: NULL rather than 0.
1382         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
1383
1384 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
1385
1386         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
1387         It mishandled the case where the group was missing.
1388         Problem reported by Greg Schafer.
1389         * modules/idcache: Likewise.
1390
1391 2006-11-18  Jim Meyering  <jim@meyering.net>
1392
1393         * check-module (%exempt_header): Add exception for some
1394         conditionally-included headers.
1395
1396         * modules/i-ring (Depends-on): Add verify.
1397         (License): Change to LGPL.
1398
1399 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
1400
1401         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
1402         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
1403         and inttostr.h.  Use snprintf rather than uinttostr, so that
1404         LGPLed code doesn't depend on GPLed.
1405
1406 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
1407
1408         * modules/inline (License): Change from GPL to LGPL.
1409
1410 2006-11-17  Jim Meyering  <jim@meyering.net>
1411
1412         * modules/d-type (License): Switch to LGPL.
1413
1414 2006-11-15  Bruno Haible  <bruno@clisp.org>
1415
1416         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
1417
1418 2006-11-15  Eric Blake  <ebb9@byu.net>
1419
1420         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
1421         the module dependency.
1422
1423 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
1424             Bruno Haible  <bruno@clisp.org>
1425
1426         * gnulib-tool (func_create_testdir): Add license consistency check.
1427
1428 2006-11-15  Eric Blake  <ebb9@byu.net>
1429
1430         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
1431         random "(cached)" in configure output.
1432
1433 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1434
1435         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
1436         test for conforming inttypes.h is both announced and cached.
1437
1438         * MODULES.html.sh (seen_modules, seen_files): New variables.
1439         (func_module): Rewrite to use a few less gnulib-tool and sed
1440         invocations.  Avoid a couple of quadratic algorithms for ...
1441         (missed_modules, missed_files): ... these, with ...
1442         (func_append, func_tmpdir): ... these new functions, from
1443         gnulib-tool.  Analogously, install traps for cleanup.
1444
1445         * tests/test-gc.c (main): Remove unused variables.
1446         * tests/test-read-file.c: Include stdlib.h, for 'free'.
1447
1448 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
1449
1450         * modules/inttostr (License): Change to LGPL.
1451
1452 2006-11-14  Eric Blake  <ebb9@byu.net>
1453
1454         * modules/tempname (License): Change to LGPL.
1455
1456 2006-11-14  Eric Blake  <ebb9@byu.net>
1457
1458         * doc/functions.texi (Function Portability): *printf functions on
1459         Cygwin now understand all POSIX size specifiers.
1460
1461 2006-11-14  Bruno Haible  <bruno@clisp.org>
1462
1463         * modules/c-ctype (License): Change to LGPL.
1464
1465 2006-11-12  Bruno Haible  <bruno@clisp.org>
1466
1467         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
1468         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
1469         for GNOME libraries, for which the include files are installed in
1470         subdirectories of $prefix/include.
1471
1472 2006-11-12  Bruno Haible  <bruno@clisp.org>
1473
1474         * m4/lib-link.m4: Require at least autoconf-2.54.
1475         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
1476         name to underscores for the --with option.
1477
1478 2006-11-13  Bruno Haible  <bruno@clisp.org>
1479
1480         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
1481         the tests directory.
1482         Reported by Ralf Wildenhues.
1483
1484 2006-11-13  Bruno Haible  <bruno@clisp.org>
1485
1486         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
1487         (func_emit_initmacro_end): Undo the override here.
1488         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
1489         Works around the famous automake error in coreutils.
1490
1491 2006-11-13  Eric Blake  <ebb9@byu.net>
1492
1493         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
1494         element, not its node.
1495
1496 2006-11-12  Bruno Haible  <bruno@clisp.org>
1497
1498         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
1499         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
1500
1501 2006-11-12  Bruno Haible  <bruno@clisp.org>
1502
1503         * gnulib-tool: New option --local-symlink.
1504         (func_usage): Document it.
1505         (lsymbolic): New variable.
1506         (func_import, func_create_testdir): If --symlink was not specified,
1507         test whether --local-symlink was specified and the file comes from
1508         the local_gnulib_dir.
1509
1510 2006-11-12  Bruno Haible  <bruno@clisp.org>
1511
1512         * gnulib-tool (func_ln): New function.
1513         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
1514
1515 2006-11-12  Bruno Haible  <bruno@clisp.org>
1516
1517         Finish support for source files in subdirectories.
1518         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
1519         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
1520         AUTOMAKE_OPTIONS.
1521         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
1522
1523 2006-11-12  Bruno Haible  <bruno@clisp.org>
1524
1525         * gnulib-tool (func_get_automake_snippet): Synthesize also an
1526         EXTRA_lib_SOURCES augmentation.
1527         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
1528
1529 2006-11-12  Jim Meyering  <jim@meyering.net>
1530
1531         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
1532         file descriptors.  This also averts a failure on systems with
1533         native openat support when a traversed directory lacks "x" access.
1534         * lib/fts_.h: Include "i-ring.h"
1535         (struct FTS) [fts_fd_ring]: New member.
1536         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
1537         (FCHDIR): Add parentheses.
1538         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
1539         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
1540         When descending, rather than simply closing the previous
1541         fts_cwd_fd value, push that file descriptor onto the ring.
1542         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
1543         (fts_open): Initialize the new fd_ring member.
1544         (fts_close): Clear the ring.
1545         (fts_safe_changedir): When possible, use our new fd_ring to skip
1546         the diropen and fstat and dev/ino comparison that would normally
1547         accompany a virtual `chdir ("..")'.
1548
1549         * modules/fts (Depends-on): Add i-ring.
1550         * modules/i-ring: New module.
1551         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
1552         * m4/i-ring.m4: New file.
1553
1554 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1555
1556         * gnulib-tool (func_create_testdir): Fix replacement of
1557         `build-aux' in configure.ac.  Run autotools in gltests
1558         subdirectory.
1559         (func_create_testdir, func_create_megatestdir, test): There is
1560         no need for '--force' in most autotool invocations in a new
1561         tree.  Actually fail the whole test if any of the tools, or the
1562         configure or make stages fail.
1563
1564         Sync from Automake.
1565         * build-aux/gnupload: Revert last change.  Add pointer to upload
1566         instructions of the GNU Maintenance Instructions.
1567         Suggestion by Karl Berry.
1568
1569 2006-11-10  Jim Meyering  <jim@meyering.net>
1570
1571         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
1572
1573 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1574
1575         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
1576         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
1577         (bind_textdomain_codeset) [! ENABLE_NLS]:
1578         Evaluate all the arguments.  That way, callers get compatible behavior
1579         if the arguments have side effects.  Also, it avoids some GCC
1580         diagnostics in some cases; Joel E. Denny reported problems when Bison
1581         was configured with --enable-gcc-warnigs.
1582
1583 2006-11-10  Jim Meyering  <jim@meyering.net>
1584
1585         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
1586         relevant options in CFLAGS (like -O, -fno-inline) are taken into
1587         account.
1588
1589 2006-11-10  Jim Meyering  <jim@meyering.net>
1590
1591         * modules/inline: New file/module.
1592         * modules/xalloc (Files): Remove m4/inline.m4.
1593         (Depends-on): Add inline, instead.
1594         * modules/oset: Likewise.
1595         * modules/list: Likewise.
1596
1597 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
1598
1599         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
1600         Problem reported by Matthew Woehlke.
1601
1602 2006-11-09  Bruno Haible  <bruno@clisp.org>
1603
1604         * lib/tempname.c (gen_tempname): Remove variant that invokes
1605         __gen_tempname.
1606         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
1607         __gen_tempname.
1608
1609 2006-11-08  Bruno Haible  <bruno@clisp.org>
1610
1611         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
1612         to 'yes' instead of 'cross-compiling'.
1613
1614 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
1615
1616         * lib/quotearg.h (quotearg_free): New decl.
1617         * lib/quotearg.c (quotearg_free): New function.
1618         (slot0, nslots, slotvec0, slotvec):
1619         Now file-scope so that quotearg_free can get at them.
1620
1621 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1622
1623         Sync from Automake.
1624         * build-aux/gnupload: Add missing 'gnu' to example URL.
1625         Report by Karl Berry.
1626
1627 2006-11-08  Bruno Haible  <bruno@clisp.org>
1628
1629         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
1630         Suggested by Paul Eggert.
1631
1632 2006-11-08  Jim Meyering  <jim@meyering.net>
1633
1634         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
1635         It's already included if !_LIBC.
1636         (fts_safe_changedir): Add a comment.
1637
1638 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1639
1640         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
1641         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
1642         Matthew Woehlke.
1643
1644         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
1645         definitions up, to avoid colliding with change below.
1646         (static_inline) [HAVE_INLINE]: New macro.
1647         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
1648         Provide extern decls when !HAVE_INLINE.  Do not define unless
1649         static_inline is defined, either by us or by xmalloc.c.  Use
1650         static_inline rather than static inline.
1651         (XCALLOC): Optimize sizeof(T) = 1 case.
1652         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
1653
1654 2006-11-07  Bruno Haible  <bruno@clisp.org>
1655
1656         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
1657         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
1658         AC_C_INLINE.
1659         * modules/xalloc (Files): Add m4/inline.m4.
1660
1661 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1662
1663         * README: Fix typo.
1664         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
1665         (Miscellanous Notes): ...from this.
1666
1667 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
1668
1669         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
1670         Mention that offsetof should be used instead of sizeof.
1671         From Bruno Haible.
1672
1673 2006-11-07  Bruno Haible  <bruno@clisp.org>
1674
1675         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
1676
1677 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1678
1679         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1680         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
1681         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1682         (gl_tree_add_before, gl_tree_add_after):
1683         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
1684         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
1685         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1686         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
1687         (gl_linked_add_after, gl_linked_add_at): Likewise.
1688         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
1689         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
1690         (gl_tree_add_before, gl_tree_add_after): Likewise.
1691         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
1692         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
1693         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
1694
1695 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1696
1697         * lib/gl_oset.h: Use C comment style, not C++ comment style.
1698
1699 2006-11-06  Bruno Haible  <bruno@clisp.org>
1700
1701         * m4/inline.m4: New file.
1702         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
1703         * modules/list (Files): Add m4/inline.m4.
1704         * modules/oset (Files): Likewise.
1705
1706 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
1707
1708         * lib/idcache.c: Include <stddef.h>, for offsetof.
1709         (struct userid.name): Change from char * to a flexible array member.
1710         All uses changed.
1711         * modules/idcache (Depends-on): Add flexmember.
1712
1713         * MODULES.html.sh (Core language properties): New module flexmember.
1714         * modules/flexmember, m4/flexmember.m4: New files.
1715
1716         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
1717         inline functions that are identical with the old xnmalloc_inline,
1718         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
1719         that we can avoid some unnecessary integer multiplications and
1720         divisions in the common case where the element size is known at
1721         compile time.
1722         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
1723         needed.
1724         (xnboundedmalloc): Remove.
1725         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
1726         arguments, for consistency with rest of this header.
1727         (xcharalloc): Rewrite using XNMALLOC.
1728         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
1729         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
1730         versions have been moved to lib/xalloc.h and renamed to be the
1731         non-*_inline versions.
1732         (xmalloc, xrealloc): Implement without reference to the xnmalloc
1733         and xnrealloc functions, since those functions are now inline and
1734         now call us.
1735         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
1736         renaming described above.
1737         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
1738         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
1739         captures the dependency in AC_C_INLINE.
1740
1741         New module canonicalize-lgpl, proposed by Charles Wilson in
1742         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
1743         with a few small changes afterwards.
1744         * MODULES.html.sh (File system functions): New module
1745         canonicalize-lgpl.
1746         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
1747         and canonicalize_file_name.
1748         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
1749         * modules/canonicalize-lgpl: New files.
1750
1751 2006-11-05  Bruno Haible  <bruno@clisp.org>
1752
1753         * gnulib-tool (func_import, func_create_testdir): Create directories
1754         also for files in subdirectories of lib/.
1755
1756 2006-11-05  Bruno Haible  <bruno@clisp.org>
1757
1758         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
1759         ANSI C compliant.
1760
1761 2006-11-03  Bruno Haible  <bruno@clisp.org>
1762
1763         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
1764         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
1765         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
1766         (xnboundedmalloc): New inline function.
1767         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
1768         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
1769         xmalloc.
1770         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
1771         xmalloc.
1772         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
1773         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
1774         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
1775         xmalloc.
1776         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1777         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
1778         xmalloc.
1779         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
1780         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1781         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
1782         xmalloc.
1783         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
1784         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
1785         gl_tree_add_after): Use XMALLOC instead of xmalloc.
1786         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
1787         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
1788         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
1789         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
1790
1791 2006-11-03  Bruno Haible  <bruno@clisp.org>
1792
1793         * lib/c-ctype.h [C++]: Define functions without name mangling.
1794         * lib/fwriteerror.h [C++]: Likewise.
1795         * lib/gcd.h [C++]: Likewise.
1796         * lib/linebreak.h [C++]: Likewise.
1797
1798 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
1799
1800         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
1801         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
1802         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
1803         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
1804         Check for functions and headers just once.
1805         Check for declaration of canonicalize_file_name.
1806         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
1807
1808 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
1809
1810         * gnulib-tool (func_import): Fix typo in actioncmd.
1811
1812 2006-11-02  Bruno Haible  <bruno@clisp.org>
1813
1814         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
1815         newline sequence in the Makefile.am snippet as a space, like "make"
1816         does.
1817         Reported by Roger Persson <perrog@gmail.com>.
1818
1819 2006-11-01  Bruno Haible  <bruno@clisp.org>
1820
1821         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
1822         already declared in <string.h>.
1823         * lib/strcase.h (strncasecmp): Don't declare it if yes.
1824
1825 2006-11-01  Bruno Haible  <bruno@clisp.org>
1826
1827         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
1828         * lib/strcase.h: Include <string.h>.
1829         (strcasecmp): Define to rpl_strcasecmp here.
1830
1831 2006-11-01  Bruno Haible  <bruno@clisp.org>
1832
1833         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
1834
1835 2006-11-01  Eric Blake  <ebb9@byu.net>
1836
1837         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
1838
1839         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
1840
1841 2006-10-29  Bruno Haible  <bruno@clisp.org>
1842
1843         Make it compile in C++ mode.
1844         * lib/full-write.c (full_rw): Add a cast.
1845
1846 2006-11-01  Bruno Haible  <bruno@clisp.org>
1847
1848         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
1849         be POSIX compliant.
1850         Reported by Roger Persson <perrog@gmail.com>.
1851
1852 2006-11-01  Eric Blake  <ebb9@byu.net>
1853
1854         * lib/getopt_.h: Fix comments.
1855
1856 2006-10-31  Eric Blake  <ebb9@byu.net>
1857
1858         * modules/tmpdir (Depends-on): Add sys_stat.
1859         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
1860         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
1861         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
1862         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
1863         tempname.
1864
1865 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
1866
1867         Avoid some C++ diagnostics reported by Bruno Haible.
1868         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
1869         xmalloc.
1870         (quotearg_alloc): Use xcharalloc rather than xmalloc.
1871         (struct slotvec): Move to top level.
1872         (quotearg_n_options): Rewrite to avoid xmalloc.
1873         * lib/xalloc.h (xcharalloc): New function.
1874         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
1875         [defined __cplusplus]: Add function template that provides result
1876         type propagation.  This part of the change is from Bruno Haible.
1877
1878 2006-10-29  Bruno Haible  <bruno@clisp.org>
1879
1880         Make it compile in C++ mode.
1881         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
1882         * lib/strnlen1.c (strnlen1): Cast memchr result.
1883         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
1884         * lib/clean-temp.c (string_equals, string_hash): Add casts.
1885         (create_temp_dir): Rename local variable 'template'.
1886         (compile_csharp_using_sscli): Add cast.
1887         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
1888         * lib/findprog.c (find_in_path): Likewise.
1889         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
1890         * lib/wait-process.c (register_slave_subprocess): Likewise.
1891
1892 2006-10-22  Bruno Haible  <bruno@clisp.org>
1893
1894         * modules/tsearch: New file.
1895         * lib/tsearch.h: New file.
1896         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
1897         * m4/tsearch.m4: New file.
1898         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
1899
1900 2006-10-29  Eric Blake  <ebb9@byu.net>
1901
1902         * lib/arcfour.c: Assume config.h.
1903         * lib/arctwo.c: Likewise.
1904         * lib/base64.c: Likewise.
1905         * lib/check-version.c: Likewise.
1906         * lib/crc.c: Likewise.
1907         * lib/des.c: Likewise.
1908         * lib/gc-gnulib.c: Likewise.
1909         * lib/gc-libgcrypt.c: Likewise.
1910         * lib/gc-pbkdf2-sha1.c: Likewise.
1911         * lib/getaddrinfo.c: Likewise.
1912         * lib/getdelim.c: Likewise.
1913         * lib/getline.c: Likewise.
1914         * lib/hmac-md5.c: Likewise.
1915         * lib/hmac-sha1.c: Likewise.
1916         * lib/iconvme.c: Likewise.
1917         * lib/md2.c: Likewise.
1918         * lib/md4.c: Likewise.
1919         * lib/memxor.c: Likewise.
1920         * lib/read-file.c: Likewise.
1921         * lib/readline.c: Likewise.
1922         * lib/rijndael-alg-fst.c: Likewise.
1923         * lib/rijndael-api-fst.c: Likewise.
1924         * lib/xgetdomainname.c: Likewise.
1925
1926 2006-10-28  Eric Blake  <ebb9@byu.net>
1927
1928         * lib/xstrndup.c: Assume config.h.
1929
1930 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
1931
1932         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
1933         stat-macros.h is now for our own macros, whereas stat_h is for
1934         macros in the <sys/stat.h> name space.
1935         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
1936         (STAT_MACROS_H): Remove.
1937         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
1938         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
1939         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
1940         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
1941         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
1942         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
1943         Move these macros to ...
1944         * lib/stat_.h: here.  Don't include stat-macros.h.
1945         * lib/canonicalize.c: Don't include stat-macros.h.
1946         * lib/chown.c: Likewise.
1947         * lib/euidaccess.c: Likewise.
1948         * lib/file-type.c: Likewise.
1949         * lib/filemode.c: Likewise.
1950         * lib/glob.c: Likewise.
1951         * lib/isapipe.c: Likewise.
1952         * lib/lchown.c: Likewise.
1953         * lib/lstat.c: Likewise.
1954         * lib/mkdir-p.c: Likewise.
1955         * lib/rmdir.c: Likewise.
1956         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
1957         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
1958         unless mkdir isn't declared, to speed up 'configure'.
1959         Always create sys/stat.h, since it's unlikely any real sys/stat.h
1960         would define all the S_* symbols.
1961         * modules/canonicalize (Depends-on):
1962         Depend on sys_stat, not stat-macros.
1963         * modules/chown: Likewise.
1964         * modules/euidaccess: Likewise.
1965         * modules/filemode: Likewise.
1966         * modules/file-type: Likewise.
1967         * modules/glob: Likewise.
1968         * modules/isapipe: Likewise.
1969         * modules/lchown: Likewise.
1970         * modules/lstat: Likewise.
1971         * modules/mkancesdirs: Likewise.
1972         * modules/rmdir: Likewise.
1973         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
1974         * modules/modechange: Likewise.
1975         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
1976         (configure.ac): Remove gl_STAT_MACROS.
1977         * modules/sys_stat (Depends-on): Remove stat-macros.
1978
1979 2006-10-27  Bruno Haible  <bruno@clisp.org>
1980
1981         * m4/signed.m4: Remove file.
1982         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
1983         invocation.
1984         * modules/vasnprintf (Files): Remove m4/signed.m4.
1985
1986 2006-10-27  Bruno Haible  <bruno@clisp.org>
1987
1988         Update to GNU gettext 0.16.
1989         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
1990         m4/inttypes-h.m4, m4/signed.m4.
1991         * m4/gettext.m4: Update to GNU gettext 0.16.
1992         * m4/intl.m4: New file, from GNU gettext.
1993         * m4/intldir.m4: New file, from GNU gettext.
1994         * config/srclist.txt: Update
1995
1996 2006-10-27  Eric Blake  <ebb9@byu.net>
1997
1998         * MODULES.html.sh: Document tempname.
1999         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
2000         dependencies.
2001         (Files): Move lib/tempname.c...
2002         * modules/tempname: ...to this new module.
2003         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
2004         (gl_PREREQ_TEMPNAME): Move...
2005         * m4/tempname.m4: ...to this new file.
2006         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
2007         * modules/sys_stat (Depends-on): Add stat-macros.
2008         * lib/stat_.h (includes): Pick up stat macros.
2009         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
2010         if stat macros are broken.
2011         * lib/tempname.c (includes): No need to include "stat-macros.h".
2012         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
2013         (direxists, __path_search) [!_LIBC]: Don't compile these in
2014         gnulib; the tmpdir module covers that.
2015         * lib/tempname.h: New file.
2016
2017 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
2018
2019         * COPYING: Explain how gnulib-tool converts licence headers.
2020         Almost all wording by Eric Blake.
2021
2022 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
2023
2024         * lib/mbchar.h (is_basic_table): Make read-only.
2025         * lib/mbchar.c (is_basic_table): Likewise.
2026         Reported by John Darrington.
2027
2028 2006-10-25  Bruno Haible  <bruno@clisp.org>
2029
2030         * lib/progname.h (set_program_name): Undefine before defining.
2031
2032 2006-10-25  Bruno Haible  <bruno@clisp.org>
2033
2034         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
2035         false for non-gcc C++ compilers.
2036         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
2037
2038 2006-10-24  Bruno Haible  <bruno@clisp.org>
2039
2040         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
2041         iconv implementations like Irix iconv.
2042
2043 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2044
2045         * modules/vararrays: New file.
2046         * m4/vararrays.m4: New file, taken from diffutils.
2047         * MODULES.html.sh: New module vararrays.
2048
2049 2006-10-24  Karl Berry  <karl@gnu.org>
2050
2051         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
2052         Don't call GNU Unix.
2053
2054 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2055
2056         * users.txt: Add Libtool.
2057
2058         Sync from Libtool:
2059
2060         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2061
2062         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
2063         to gnulib's policy of including config.h unconditionally.
2064
2065 2006-10-24  Bruno Haible  <bruno@clisp.org>
2066
2067         * modules/wcwidth (Files): Add m4/wint_t.m4.
2068         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
2069         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
2070
2071 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
2072
2073         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
2074         to pacify GCC with some -W flags enabled.  Problem reported by
2075         Bruno Haible.
2076
2077 2006-10-24  Jim Meyering  <jim@meyering.net>
2078
2079         * MODULES.html.sh: Remove uinttostr.  It's not a module.
2080         Reported by Karl Berry.
2081
2082 2006-10-23  Bruno Haible  <bruno@clisp.org>
2083
2084         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
2085
2086 2006-10-24  Bruno Haible  <bruno@clisp.org>
2087
2088         * lib/gl_list.h: Use C comment style, not C++ comment style.
2089
2090 2006-10-23  Eric Blake  <ebb9@byu.net>
2091
2092         * lib/getaddrinfo.c (includes): Add missing include.
2093
2094 2006-10-23  Bruno Haible  <bruno@clisp.org>
2095             Paul Eggert  <eggert@cs.ucla.edu>
2096
2097         Ability to rename obstack_free.
2098         * lib/obstack.h (__obstack_free): New macro. Declare instead of
2099         obstack_free.
2100         (obstack_free): Invoke the __obstack_free macro.
2101         * lib/obstack.c (obstack_free): Use __obstack_free macro.
2102
2103 2006-10-23  Bruno Haible  <bruno@clisp.org>
2104             Paul Eggert  <eggert@cs.ucla.edu>
2105
2106         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
2107         __argc, __argv from the declaration. (They are defined as macros on
2108         mingw.)
2109
2110 2006-10-22  Bruno Haible  <bruno@clisp.org>
2111
2112         * doc/gnulib-intro.texi: New file.
2113         * doc/gnulib.texi: Include it.
2114
2115 2006-10-21  Bruno Haible  <bruno@clisp.org>
2116
2117         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
2118         "Introduction", "Miscellanous Notes", "Particular Modules".
2119
2120 2006-10-21  Bruno Haible  <bruno@clisp.org>
2121
2122         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2123         Change mostlyclean-local rule to avoid sh syntax error from bash
2124         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
2125
2126 2006-10-23  Jim Meyering  <jim@meyering.net>
2127
2128         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
2129         in place of snprintf.
2130
2131         * modules/inttostr (Files): Add lib/uinttostr.c.
2132         * lib/uinttostr.c (inttostr): New file/function.
2133         * lib/inttostr.h (uinttostr): Declare.
2134         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
2135         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
2136         Add uinttostr.
2137         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
2138
2139 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
2140
2141         * lib/canonicalize.c (ELOOP): Define if not already defined.
2142         Problem reported by Bruno Haible in
2143         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
2144
2145 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
2146
2147         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
2148         Problem reported by Perry Smith and Ville Laurikari.
2149
2150         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
2151         uses.
2152
2153 2006-10-19  Bruno Haible  <bruno@clisp.org>
2154
2155         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
2156         for mingw.
2157
2158 2006-10-19  Bruno Haible  <bruno@clisp.org>
2159
2160         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
2161         Needed for mingw.
2162
2163 2006-10-19  Bruno Haible  <bruno@clisp.org>
2164
2165         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
2166
2167 2006-10-19  Bruno Haible  <bruno@clisp.org>
2168
2169         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
2170         it.
2171
2172 2006-10-19  Bruno Haible  <bruno@clisp.org>
2173
2174         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
2175         invocation.
2176
2177 2006-10-19  Bruno Haible  <bruno@clisp.org>
2178
2179         * gnulib-tool (func_create_testdir): Don't include ftruncate and
2180         mountlist by default.
2181
2182 2006-10-16  Bruno Haible  <bruno@clisp.org>
2183
2184         * lib/c-strstr.c: Include c-strstr.h.
2185
2186 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
2187
2188         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
2189         in a slash.
2190
2191 2006-10-18  Bruno Haible  <bruno@clisp.org>
2192
2193         * lib/lock.h [C++]: Wrap definitions in extern "C".
2194
2195 2006-10-18  Bruno Haible  <bruno@clisp.org>
2196
2197         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
2198         gl_LIBOBJS list.
2199
2200 2006-10-18  Bruno Haible  <bruno@clisp.org>
2201
2202         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
2203
2204 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
2205
2206         * lib/xstrtol.h: Include gettext.h.
2207         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
2208         Problem reported by Eric Blake.
2209         * modules/xstrtol (Depends-on): Add gettext-h.
2210
2211 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
2212
2213         * lib/strftime.c (advance): New macro.
2214         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
2215         incomplete type, so you can't add 0 to it.  Problem and patch
2216         reported by Eelco Dolstra for dietlibc.
2217
2218 2006-10-18  Jim Meyering  <jim@meyering.net>
2219
2220         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
2221         type for a local, and rename it: s/up/user_proc/.
2222
2223 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
2224
2225         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
2226         READ_UTMP_USER_PROCESS.
2227         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
2228
2229 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
2230
2231         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
2232         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
2233
2234 2006-10-17  Eric Blake  <ebb9@byu.net>
2235
2236         * lib/sigprocmask.c (sigprocmask): Fix typo.
2237
2238         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
2239
2240         * modules/clean-temp (Makefile.am): Don't add to make output...
2241         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
2242         config.h.
2243
2244 2006-10-17  Bruno Haible  <bruno@clisp.org>
2245
2246         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
2247         differently if DEFAULT_TEXT_DOMAIN is set.
2248
2249 2006-10-16  Bruno Haible  <bruno@clisp.org>
2250
2251         * lib/clean-temp.c: Include fwriteerror.h.
2252
2253 2006-10-16  Bruno Haible  <bruno@clisp.org>
2254
2255         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
2256
2257 2006-10-16  Bruno Haible  <bruno@clisp.org>
2258
2259         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
2260         * lib/sigprocmask.h: Include <sys/types.h>.
2261         (sigset_t): Use the system's definition if present.
2262
2263 2006-10-17  Eric Blake  <ebb9@byu.net>
2264
2265         * lib/xvasprintf.c (includes): Assume config.h.
2266         * lib/xasprintf.c (includes): Likewise.
2267
2268 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
2269
2270         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
2271         at least as wide as intmax_t.
2272
2273 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
2274
2275         (Imported from Automake.)
2276         * build-aux/gnupload: Update to version 1.1 of directive file.
2277
2278 2006-10-16  Eric Blake  <ebb9@byu.net>
2279
2280         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
2281         match Automake 1.10a.
2282
2283 2006-10-14  Bruno Haible  <bruno@clisp.org>
2284
2285         * modules/sigprocmask: New file.
2286         * lib/sigprocmask.h: New file.
2287         * lib/sigprocmask.c: New file.
2288         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
2289         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
2290         request sigprocmask.o.
2291         (gl_PREREQ_SIGPROCMASK): New macro.
2292         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
2293         (Depends-on): Add sigprocmask.
2294         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
2295         gt_SIGNALBLOCKING. Test for 'raise' only once.
2296         * lib/fatal-signal.c: Include sigprocmask.h.
2297         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
2298         unblock_fatal_signals): Define always.
2299         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2300         sigprocmask.
2301
2302 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
2303
2304         Sync from Automake.
2305         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
2306         which incorrectly sets the mode of an existing destination
2307         directory.  In some cases the unpatched install-sh could do the
2308         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
2309         system.  We hope this is rare in practice, but it's clearly worth
2310         fixing.  Problem reported by Alex Unleashed in
2311         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
2312         Also, don't bother to check for -m bugs unless we're using -m;
2313         suggested by Stepan Kasal.
2314
2315 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2316
2317         Sync from Automake.
2318         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
2319         `-c' flag, so they appear at the same position as in %FASTDEP%
2320         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
2321         which ignores unknown options only after the first non-option.
2322         Bug report against M4 by Nelson H. F. Beebe.
2323
2324 2006-10-13  Jim Meyering  <jim@meyering.net>
2325
2326         Fix a bug in yesterday's change.
2327         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
2328         p->fts_statp->st_dev would be used uninitialized.
2329         Ensures that we always call fts_stat on the very first entry.
2330         Miklos Szeredi reported that find -xdev stopped working.
2331
2332 2006-10-12  Bruno Haible  <bruno@clisp.org>
2333
2334         * gnulib-tool (func_get_automake_snippet): Append an automatically
2335         computed EXTRA_DIST augmentation.
2336         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
2337         * modules/alloca-opt (Makefile.am): Likewise.
2338         * modules/allocsa (Makefile.am): Likewise.
2339         * modules/arcfour (Makefile.am): Likewise.
2340         * modules/arctwo (Makefile.am): Likewise.
2341         * modules/argmatch (Makefile.am): Likewise.
2342         * modules/argz (Makefile.am): Likewise.
2343         * modules/atexit (Makefile.am): Likewise.
2344         * modules/backupfile (Makefile.am): Likewise.
2345         * modules/byteswap (Makefile.am): Likewise.
2346         * modules/c-strtod (Makefile.am): Likewise.
2347         * modules/c-strtold (Makefile.am): Likewise.
2348         * modules/calloc (Makefile.am): Likewise.
2349         * modules/canon-host (Makefile.am): Likewise.
2350         * modules/canonicalize (Makefile.am): Likewise.
2351         * modules/chdir-long (Makefile.am): Likewise.
2352         * modules/chdir-safer (Makefile.am): Likewise.
2353         * modules/check-version (Makefile.am): Likewise.
2354         * modules/chown (Makefile.am): Likewise.
2355         * modules/cloexec (Makefile.am): Likewise.
2356         * modules/close-stream (Makefile.am): Likewise.
2357         * modules/closeout (Makefile.am): Likewise.
2358         * modules/crc (Makefile.am): Likewise.
2359         * modules/csharpexec (Makefile.am): Likewise.
2360         * modules/cycle-check (Makefile.am): Likewise.
2361         * modules/des (Makefile.am): Likewise.
2362         * modules/dev-ino (Makefile.am): Likewise.
2363         * modules/dirfd (Makefile.am): Likewise.
2364         * modules/dirname (Makefile.am): Likewise.
2365         * modules/dup2 (Makefile.am): Likewise.
2366         * modules/eealloc (Makefile.am): Likewise.
2367         * modules/error (Makefile.am): Likewise.
2368         * modules/euidaccess (Makefile.am): Likewise.
2369         * modules/exclude (Makefile.am): Likewise.
2370         * modules/exitfail (Makefile.am): Likewise.
2371         * modules/fcntl-safer (Makefile.am): Likewise.
2372         * modules/fcntl (Makefile.am): Likewise.
2373         * modules/file-type (Makefile.am): Likewise.
2374         * modules/fileblocks (Makefile.am): Likewise.
2375         * modules/filemode (Makefile.am): Likewise.
2376         * modules/filenamecat (Makefile.am): Likewise.
2377         * modules/fnmatch (Makefile.am): Likewise.
2378         * modules/fopen-safer (Makefile.am): Likewise.
2379         * modules/fpending (Makefile.am): Likewise.
2380         * modules/fprintftime (Makefile.am): Likewise.
2381         * modules/free (Makefile.am): Likewise.
2382         * modules/fsusage (Makefile.am): Likewise.
2383         * modules/ftruncate (Makefile.am): Likewise.
2384         * modules/fts (Makefile.am): Likewise.
2385         * modules/gc-arcfour (Makefile.am): Likewise.
2386         * modules/gc-des (Makefile.am): Likewise.
2387         * modules/gc-hmac-md5 (Makefile.am): Likewise.
2388         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
2389         * modules/gc-md4 (Makefile.am): Likewise.
2390         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2391         * modules/gc-sha1 (Makefile.am): Likewise.
2392         * modules/gc (Makefile.am): Likewise.
2393         * modules/getaddrinfo (Makefile.am): Likewise.
2394         * modules/getcwd (Makefile.am): Likewise.
2395         * modules/getdelim (Makefile.am): Likewise.
2396         * modules/getdomainname (Makefile.am): Likewise.
2397         * modules/getgroups (Makefile.am): Likewise.
2398         * modules/gethostname (Makefile.am): Likewise.
2399         * modules/gethrxtime (Makefile.am): Likewise.
2400         * modules/getline (Makefile.am): Likewise.
2401         * modules/getloadavg (Makefile.am): Likewise.
2402         * modules/getlogin_r (Makefile.am): Likewise.
2403         * modules/getndelim2 (Makefile.am): Likewise.
2404         * modules/getopt (Makefile.am): Likewise.
2405         * modules/getpagesize (Makefile.am): Likewise.
2406         * modules/getpass-gnu (Makefile.am): Likewise.
2407         * modules/getpass (Makefile.am): Likewise.
2408         * modules/getsubopt (Makefile.am): Likewise.
2409         * modules/gettime (Makefile.am): Likewise.
2410         * modules/gettimeofday (Makefile.am): Likewise.
2411         * modules/getugroups (Makefile.am): Likewise.
2412         * modules/getusershell (Makefile.am): Likewise.
2413         * modules/glob (Makefile.am): Likewise.
2414         * modules/group-member (Makefile.am): Likewise.
2415         * modules/hard-locale (Makefile.am): Likewise.
2416         * modules/hash (Makefile.am): Likewise.
2417         * modules/hmac-md5 (Makefile.am): Likewise.
2418         * modules/hmac-sha1 (Makefile.am): Likewise.
2419         * modules/human (Makefile.am): Likewise.
2420         * modules/idcache (Makefile.am): Likewise.
2421         * modules/imaxabs (Makefile.am): Likewise.
2422         * modules/imaxdiv (Makefile.am): Likewise.
2423         * modules/inet_ntop (Makefile.am): Likewise.
2424         * modules/inet_pton (Makefile.am): Likewise.
2425         * modules/intprops (Makefile.am): Likewise.
2426         * modules/inttostr (Makefile.am): Likewise.
2427         * modules/inttypes (Makefile.am): Likewise.
2428         * modules/isapipe (Makefile.am): Likewise.
2429         * modules/javaversion (Makefile.am): Likewise.
2430         * modules/lchmod (Makefile.am): Likewise.
2431         * modules/lchown (Makefile.am): Likewise.
2432         * modules/localcharset (Makefile.am): Likewise.
2433         * modules/long-options (Makefile.am): Likewise.
2434         * modules/lstat (Makefile.am): Likewise.
2435         * modules/malloc (Makefile.am): Likewise.
2436         * modules/mathl (Makefile.am): Likewise.
2437         * modules/mbchar (Makefile.am): Likewise.
2438         * modules/md2 (Makefile.am): Likewise.
2439         * modules/md4 (Makefile.am): Likewise.
2440         * modules/md5 (Makefile.am): Likewise.
2441         * modules/memcasecmp (Makefile.am): Likewise.
2442         * modules/memchr (Makefile.am): Likewise.
2443         * modules/memcmp (Makefile.am): Likewise.
2444         * modules/memcoll (Makefile.am): Likewise.
2445         * modules/memcpy (Makefile.am): Likewise.
2446         * modules/memmem (Makefile.am): Likewise.
2447         * modules/memmove (Makefile.am): Likewise.
2448         * modules/mempcpy (Makefile.am): Likewise.
2449         * modules/memrchr (Makefile.am): Likewise.
2450         * modules/memset (Makefile.am): Likewise.
2451         * modules/memxor (Makefile.am): Likewise.
2452         * modules/mkancesdirs (Makefile.am): Likewise.
2453         * modules/mkdir-p (Makefile.am): Likewise.
2454         * modules/mkdir (Makefile.am): Likewise.
2455         * modules/mkdtemp (Makefile.am): Likewise.
2456         * modules/mkstemp (Makefile.am): Likewise.
2457         * modules/mktime (Makefile.am): Likewise.
2458         * modules/modechange (Makefile.am): Likewise.
2459         * modules/mountlist (Makefile.am): Likewise.
2460         * modules/nanosleep (Makefile.am): Likewise.
2461         * modules/obstack (Makefile.am): Likewise.
2462         * modules/openat (Makefile.am): Likewise.
2463         * modules/pagealign_alloc (Makefile.am): Likewise.
2464         * modules/pathmax (Makefile.am): Likewise.
2465         * modules/physmem (Makefile.am): Likewise.
2466         * modules/poll (Makefile.am): Likewise.
2467         * modules/posixtm (Makefile.am): Likewise.
2468         * modules/posixver (Makefile.am): Likewise.
2469         * modules/putenv (Makefile.am): Likewise.
2470         * modules/quote (Makefile.am): Likewise.
2471         * modules/quotearg (Makefile.am): Likewise.
2472         * modules/raise (Makefile.am): Likewise.
2473         * modules/read-file (Makefile.am): Likewise.
2474         * modules/readline (Makefile.am): Likewise.
2475         * modules/readlink (Makefile.am): Likewise.
2476         * modules/readtokens (Makefile.am): Likewise.
2477         * modules/readutmp (Makefile.am): Likewise.
2478         * modules/realloc (Makefile.am): Likewise.
2479         * modules/regex (Makefile.am): Likewise.
2480         * modules/rename-dest-slash (Makefile.am): Likewise.
2481         * modules/rename (Makefile.am): Likewise.
2482         * modules/rijndael (Makefile.am): Likewise.
2483         * modules/rmdir (Makefile.am): Likewise.
2484         * modules/rpmatch (Makefile.am): Likewise.
2485         * modules/safe-read (Makefile.am): Likewise.
2486         * modules/safe-write (Makefile.am): Likewise.
2487         * modules/same-inode (Makefile.am): Likewise.
2488         * modules/same (Makefile.am): Likewise.
2489         * modules/save-cwd (Makefile.am): Likewise.
2490         * modules/savedir (Makefile.am): Likewise.
2491         * modules/setenv (Makefile.am): Likewise.
2492         * modules/settime (Makefile.am): Likewise.
2493         * modules/sha1 (Makefile.am): Likewise.
2494         * modules/sig2str (Makefile.am): Likewise.
2495         * modules/snprintf (Makefile.am): Likewise.
2496         * modules/stat-macros (Makefile.am): Likewise.
2497         * modules/stat-time (Makefile.am): Likewise.
2498         * modules/stdbool (Makefile.am): Likewise.
2499         * modules/stdint (Makefile.am): Likewise.
2500         * modules/stdlib-safer (Makefile.am): Likewise.
2501         * modules/stpcpy (Makefile.am): Likewise.
2502         * modules/stpncpy (Makefile.am): Likewise.
2503         * modules/strcase (Makefile.am): Likewise.
2504         * modules/strcasestr (Makefile.am): Likewise.
2505         * modules/strchrnul (Makefile.am): Likewise.
2506         * modules/strcspn (Makefile.am): Likewise.
2507         * modules/strdup (Makefile.am): Likewise.
2508         * modules/strerror (Makefile.am): Likewise.
2509         * modules/strftime (Makefile.am): Likewise.
2510         * modules/strndup (Makefile.am): Likewise.
2511         * modules/strnlen (Makefile.am): Likewise.
2512         * modules/strpbrk (Makefile.am): Likewise.
2513         * modules/strsep (Makefile.am): Likewise.
2514         * modules/strstr (Makefile.am): Likewise.
2515         * modules/strtod (Makefile.am): Likewise.
2516         * modules/strtoimax (Makefile.am): Likewise.
2517         * modules/strtok_r (Makefile.am): Likewise.
2518         * modules/strtol (Makefile.am): Likewise.
2519         * modules/strtoll (Makefile.am): Likewise.
2520         * modules/strtoul (Makefile.am): Likewise.
2521         * modules/strtoull (Makefile.am): Likewise.
2522         * modules/strtoumax (Makefile.am): Likewise.
2523         * modules/strverscmp (Makefile.am): Likewise.
2524         * modules/sys_socket (Makefile.am): Likewise.
2525         * modules/sys_stat (Makefile.am): Likewise.
2526         * modules/sysexits (Makefile.am): Likewise.
2527         * modules/time_r (Makefile.am): Likewise.
2528         * modules/timegm (Makefile.am): Likewise.
2529         * modules/timespec (Makefile.am): Likewise.
2530         * modules/tmpfile-safer (Makefile.am): Likewise.
2531         * modules/trim (Makefile.am): Likewise.
2532         * modules/unistd-safer (Makefile.am): Likewise.
2533         * modules/unlinkdir (Makefile.am): Likewise.
2534         * modules/unlocked-io (Makefile.am): Likewise.
2535         * modules/userspec (Makefile.am): Likewise.
2536         * modules/utime (Makefile.am): Likewise.
2537         * modules/utimecmp (Makefile.am): Likewise.
2538         * modules/utimens (Makefile.am): Likewise.
2539         * modules/vasnprintf (Makefile.am): Likewise.
2540         * modules/vasprintf (Makefile.am): Likewise.
2541         * modules/vsnprintf (Makefile.am): Likewise.
2542         * modules/xalloc (Makefile.am): Likewise.
2543         * modules/xgetcwd (Makefile.am): Likewise.
2544         * modules/xnanosleep (Makefile.am): Likewise.
2545         * modules/xreadlink (Makefile.am): Likewise.
2546         * modules/xstrtod (Makefile.am): Likewise.
2547         * modules/xstrtol (Makefile.am): Likewise.
2548         * modules/xstrtold (Makefile.am): Likewise.
2549         * modules/yesno (Makefile.am): Likewise.
2550         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
2551
2552 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2553
2554         * modules/error (Makefile.am): Distribute files through
2555         EXTRA_DIST, not lib_SOURCES.
2556
2557 2006-10-12  Eric Blake  <ebb9@byu.net>
2558
2559         * modules/error (Makefile.am): Distribute files in /lib.
2560         * modules/obstack (Makefile.am): Likewise.
2561
2562 2006-10-12  Bruno Haible  <bruno@clisp.org>
2563
2564         * modules/acl (Makefile.am): Distribute all files in lib/ through
2565         EXTRA_DIST.
2566         * modules/arcfour (Makefile.am): Likewise.
2567         * modules/arctwo (Makefile.am): Likewise.
2568         * modules/argmatch (Makefile.am): Likewise.
2569         * modules/argz (Makefile.am): Likewise.
2570         * modules/atexit (Makefile.am): Likewise.
2571         * modules/backupfile (Makefile.am): Likewise.
2572         * modules/c-strtod (Makefile.am): Likewise.
2573         * modules/c-strtold (Makefile.am): Likewise.
2574         * modules/calloc (Makefile.am): Likewise.
2575         * modules/canon-host (Makefile.am): Likewise.
2576         * modules/canonicalize (Makefile.am): Likewise.
2577         * modules/chdir-long (Makefile.am): Likewise.
2578         * modules/chdir-safer (Makefile.am): Likewise.
2579         * modules/check-version (Makefile.am): Likewise.
2580         * modules/chown (Makefile.am): Likewise.
2581         * modules/cloexec (Makefile.am): Likewise.
2582         * modules/close-stream (Makefile.am): Likewise.
2583         * modules/closeout (Makefile.am): Likewise.
2584         * modules/crc (Makefile.am): Likewise.
2585         * modules/cycle-check (Makefile.am): Likewise.
2586         * modules/des (Makefile.am): Likewise.
2587         * modules/dirfd (Makefile.am): Likewise.
2588         * modules/dirname (Makefile.am): Likewise.
2589         * modules/dup2 (Makefile.am): Likewise.
2590         * modules/euidaccess (Makefile.am): Likewise.
2591         * modules/exclude (Makefile.am): Likewise.
2592         * modules/exitfail (Makefile.am): Likewise.
2593         * modules/fcntl-safer (Makefile.am): Likewise.
2594         * modules/file-type (Makefile.am): Likewise.
2595         * modules/fileblocks (Makefile.am): Likewise.
2596         * modules/filemode (Makefile.am): Likewise.
2597         * modules/filenamecat (Makefile.am): Likewise.
2598         * modules/fnmatch (Makefile.am): Likewise.
2599         * modules/fopen-safer (Makefile.am): Likewise.
2600         * modules/fpending (Makefile.am): Likewise.
2601         * modules/fprintftime (Makefile.am): Likewise.
2602         * modules/free (Makefile.am): Likewise.
2603         * modules/fsusage (Makefile.am): Likewise.
2604         * modules/ftruncate (Makefile.am): Likewise.
2605         * modules/fts (Makefile.am): Likewise.
2606         * modules/gc (Makefile.am): Likewise.
2607         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
2608         * modules/getaddrinfo (Makefile.am): Likewise.
2609         * modules/getcwd (Makefile.am): Likewise.
2610         * modules/getdelim (Makefile.am): Likewise.
2611         * modules/getdomainname (Makefile.am): Likewise.
2612         * modules/getgroups (Makefile.am): Likewise.
2613         * modules/gethostname (Makefile.am): Likewise.
2614         * modules/gethrxtime (Makefile.am): Likewise.
2615         * modules/getline (Makefile.am): Likewise.
2616         * modules/getloadavg (Makefile.am): Likewise.
2617         * modules/getlogin_r (Makefile.am): Likewise.
2618         * modules/getopt (Makefile.am): Likewise.
2619         * modules/getpass (Makefile.am): Likewise.
2620         * modules/getpass-gnu (Makefile.am): Likewise.
2621         * modules/getsubopt (Makefile.am): Likewise.
2622         * modules/gettime (Makefile.am): Likewise.
2623         * modules/gettimeofday (Makefile.am): Likewise.
2624         * modules/getugroups (Makefile.am): Likewise.
2625         * modules/getusershell (Makefile.am): Likewise.
2626         * modules/glob (Makefile.am): Likewise.
2627         * modules/group-member (Makefile.am): Likewise.
2628         * modules/hard-locale (Makefile.am): Likewise.
2629         * modules/hash (Makefile.am): Likewise.
2630         * modules/hmac-md5 (Makefile.am): Likewise.
2631         * modules/hmac-sha1 (Makefile.am): Likewise.
2632         * modules/human (Makefile.am): Likewise.
2633         * modules/idcache (Makefile.am): Likewise.
2634         * modules/imaxabs (Makefile.am): Likewise.
2635         * modules/imaxdiv (Makefile.am): Likewise.
2636         * modules/inet_ntop (Makefile.am): Likewise.
2637         * modules/inet_pton (Makefile.am): Likewise.
2638         * modules/inttostr (Makefile.am): Likewise.
2639         * modules/isapipe (Makefile.am): Likewise.
2640         * modules/lchown (Makefile.am): Likewise.
2641         * modules/long-options (Makefile.am): Likewise.
2642         * modules/lstat (Makefile.am): Likewise.
2643         * modules/malloc (Makefile.am): Likewise.
2644         * modules/mathl (Makefile.am): Likewise.
2645         * modules/mbchar (Makefile.am): Likewise.
2646         * modules/md2 (Makefile.am): Likewise.
2647         * modules/md4 (Makefile.am): Likewise.
2648         * modules/md5 (Makefile.am): Likewise.
2649         * modules/memcasecmp (Makefile.am): Likewise.
2650         * modules/memchr (Makefile.am): Likewise.
2651         * modules/memcmp (Makefile.am): Likewise.
2652         * modules/memcoll (Makefile.am): Likewise.
2653         * modules/memcpy (Makefile.am): Likewise.
2654         * modules/memmem (Makefile.am): Likewise.
2655         * modules/memmove (Makefile.am): Likewise.
2656         * modules/mempcpy (Makefile.am): Likewise.
2657         * modules/memrchr (Makefile.am): Likewise.
2658         * modules/memset (Makefile.am): Likewise.
2659         * modules/memxor (Makefile.am): Likewise.
2660         * modules/mkancesdirs (Makefile.am): Likewise.
2661         * modules/mkdir (Makefile.am): Likewise.
2662         * modules/mkdir-p (Makefile.am): Likewise.
2663         * modules/mkdtemp (Makefile.am): Likewise.
2664         * modules/mkstemp (Makefile.am): Likewise.
2665         * modules/mktime (Makefile.am): Likewise.
2666         * modules/modechange (Makefile.am): Likewise.
2667         * modules/mountlist (Makefile.am): Likewise.
2668         * modules/nanosleep (Makefile.am): Likewise.
2669         * modules/openat (Makefile.am): Likewise.
2670         * modules/pagealign_alloc (Makefile.am): Likewise.
2671         * modules/physmem (Makefile.am): Likewise.
2672         * modules/poll (Makefile.am): Likewise.
2673         * modules/posixtm (Makefile.am): Likewise.
2674         * modules/posixver (Makefile.am): Likewise.
2675         * modules/putenv (Makefile.am): Likewise.
2676         * modules/quote (Makefile.am): Likewise.
2677         * modules/quotearg (Makefile.am): Likewise.
2678         * modules/raise (Makefile.am): Likewise.
2679         * modules/read-file (Makefile.am): Likewise.
2680         * modules/readline (Makefile.am): Likewise.
2681         * modules/readlink (Makefile.am): Likewise.
2682         * modules/readtokens (Makefile.am): Likewise.
2683         * modules/readutmp (Makefile.am): Likewise.
2684         * modules/realloc (Makefile.am): Likewise.
2685         * modules/regex (Makefile.am): Likewise.
2686         * modules/rename (Makefile.am): Likewise.
2687         * modules/rename-dest-slash (Makefile.am): Likewise.
2688         * modules/rijndael (Makefile.am): Likewise.
2689         * modules/rmdir (Makefile.am): Likewise.
2690         * modules/rpmatch (Makefile.am): Likewise.
2691         * modules/safe-read (Makefile.am): Likewise.
2692         * modules/safe-write (Makefile.am): Likewise.
2693         * modules/same (Makefile.am): Likewise.
2694         * modules/save-cwd (Makefile.am): Likewise.
2695         * modules/savedir (Makefile.am): Likewise.
2696         * modules/setenv (Makefile.am): Likewise.
2697         * modules/settime (Makefile.am): Likewise.
2698         * modules/sha1 (Makefile.am): Likewise.
2699         * modules/sig2str (Makefile.am): Likewise.
2700         * modules/snprintf (Makefile.am): Likewise.
2701         * modules/stdlib-safer (Makefile.am): Likewise.
2702         * modules/stpcpy (Makefile.am): Likewise.
2703         * modules/stpncpy (Makefile.am): Likewise.
2704         * modules/strcase (Makefile.am): Likewise.
2705         * modules/strcasestr (Makefile.am): Likewise.
2706         * modules/strchrnul (Makefile.am): Likewise.
2707         * modules/strcspn (Makefile.am): Likewise.
2708         * modules/strdup (Makefile.am): Likewise.
2709         * modules/strerror (Makefile.am): Likewise.
2710         * modules/strftime (Makefile.am): Likewise.
2711         * modules/strndup (Makefile.am): Likewise.
2712         * modules/strnlen (Makefile.am): Likewise.
2713         * modules/strpbrk (Makefile.am): Likewise.
2714         * modules/strsep (Makefile.am): Likewise.
2715         * modules/strstr (Makefile.am): Likewise.
2716         * modules/strtod (Makefile.am): Likewise.
2717         * modules/strtoimax (Makefile.am): Likewise.
2718         * modules/strtok_r (Makefile.am): Likewise.
2719         * modules/strtol (Makefile.am): Likewise.
2720         * modules/strtoll (Makefile.am): Likewise.
2721         * modules/strtoul (Makefile.am): Likewise.
2722         * modules/strtoull (Makefile.am): Likewise.
2723         * modules/strtoumax (Makefile.am): Likewise.
2724         * modules/strverscmp (Makefile.am): Likewise.
2725         * modules/time_r (Makefile.am): Likewise.
2726         * modules/timegm (Makefile.am): Likewise.
2727         * modules/tmpfile-safer (Makefile.am): Likewise.
2728         * modules/unistd-safer (Makefile.am): Likewise.
2729         * modules/unlinkdir (Makefile.am): Likewise.
2730         * modules/userspec (Makefile.am): Likewise.
2731         * modules/utime (Makefile.am): Likewise.
2732         * modules/utimecmp (Makefile.am): Likewise.
2733         * modules/utimens (Makefile.am): Likewise.
2734         * modules/vasnprintf (Makefile.am): Likewise.
2735         * modules/vasprintf (Makefile.am): Likewise.
2736         * modules/vsnprintf (Makefile.am): Likewise.
2737         * modules/xalloc (Makefile.am): Likewise.
2738         * modules/xgetcwd (Makefile.am): Likewise.
2739         * modules/xnanosleep (Makefile.am): Likewise.
2740         * modules/xreadlink (Makefile.am): Likewise.
2741         * modules/xstrtod (Makefile.am): Likewise.
2742         * modules/xstrtol (Makefile.am): Likewise.
2743         * modules/xstrtold (Makefile.am): Likewise.
2744         * modules/yesno (Makefile.am): Likewise.
2745
2746 2006-10-12  Jim Meyering  <jim@meyering.net>
2747
2748         * m4/getloadavg.m4: Revert the change below.
2749
2750         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
2751         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
2752         fail with a symlink, which is what coreutils' ./bootstrap now
2753         creates by default.
2754
2755 2006-10-12  Bruno Haible  <bruno@clisp.org>
2756
2757         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
2758         mingw.
2759         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
2760         MSVC and mingw explicitly.
2761
2762 2006-10-11  Simon Josefsson  <jas@extundo.com>
2763             Bruno Haible  <bruno@clisp.org>
2764
2765         Add support for multiple gnulib-tool invocations in the scope of a
2766         single configure.ac file.
2767         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
2768         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
2769         with the same contents as the _LIBADD variable.
2770         (func_emit_initmacro_start, func_emit_initmacro_end,
2771         func_emit_initmacro_done): New functions.
2772         (func_import, func_create_testdir): Invoke them. Allow the identifiers
2773         gl_LIBOBJS and gl_LTLIBOBJS.
2774
2775 2006-10-11  Bruno Haible  <bruno@clisp.org>
2776
2777         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
2778         (func_create_testdir): Don't create po/Makefile.am, don't invoke
2779         autoreconf. Instead, invoke autopoint explicitly but move back the
2780         *.m4 files from gnulib.
2781
2782 2006-10-11  Bruno Haible  <bruno@clisp.org>
2783
2784         * gnulib-tool (func_usage): Make module names after --create-testdir
2785         optional.
2786         (func_create_testdir): If no module was specified, use nearly all
2787         modules.
2788
2789 2006-10-12  Jim Meyering  <jim@meyering.net>
2790
2791         Big performance improvement for fts-based tools that use FTS_NOSTAT.
2792         Avoid spurious inode-mismatch problems on non-POSIX file systems.
2793         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
2794         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
2795         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
2796         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
2797         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
2798         (fts_set_stat_required): New function.
2799         (fts_open): Defer the calls to fts_stat, if possible or requested.
2800         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
2801         into fts_stat itself.
2802         (fts_read): Perform any required (deferred) fts_stat call.
2803         (fts_build): Likewise, for the directory we're about to open and read.
2804         In the readdir loop, carefully decide whether each entry will require
2805         an eventual call to fts_stat, using dirent.d_type info if available.
2806         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
2807         a command line argument into this function.  Update all callers.
2808         Map a return value of FTS_DOT to FTS_D for a command line argument.
2809         * modules/fts (Depends-on): Add d-type.  Alphabetize.
2810         Thanks to Miklos Szeredi for his tenacity and for the initial
2811         bug report about "find" failing on a FUSE-based file system.
2812
2813         * lib/fts.c (fts_open): Use consistent indentation.
2814
2815 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
2816
2817         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
2818         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
2819         reported by Jim Meyering.  All uses of cache variables renamed
2820         to match Autoconf's.
2821         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
2822         the other one.
2823
2824         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
2825         Fix misspelling in diagnostic.
2826
2827 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2828
2829         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
2830         defined.  Problem reported by Matthew Woehlke.
2831
2832         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
2833         Add support for Tandem NonStop R series.
2834         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
2835         Use new macro.
2836
2837         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
2838         (has_trailing_slash): Omit size arg; all callers changed.
2839         Omit 'inline', since it doesn't help performance and we'd
2840         need to configure it.
2841         Don't count //, ///, etc. as having a trailing slash.
2842         As a side effect, this removes a C99ism reported by Matthew Woehlke.
2843         (rpl_rename_dest_slash): On failure, use rename's errno rather
2844         than (in some cases) an incorrect or junk errno.
2845         Simplify code by removing need to compute length; this does
2846         cause it to make two passes instead of one over the file name,
2847         but it's worth it.
2848
2849         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
2850         change, since Autoconf's version may no longer be appropriate now
2851         that we are using CVS Autoconf's version.  Add support for Tandem.
2852
2853 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
2854             Bruno Haible  <bruno@clisp.org>
2855
2856         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
2857         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
2858         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
2859         gl_AC_TYPE_LONG_LONG.
2860
2861         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
2862         instead of HAVE_LONG_LONG.
2863         * lib/printf-args.c (printf_fetchargs): Likewise.
2864         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
2865         * lib/vasnprintf.c (VASNPRINTF): Likewise.
2866         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
2867         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
2868         gl_AC_TYPE_LONG_LONG.
2869
2870 2006-10-11  Bruno Haible  <bruno@clisp.org>
2871
2872         * m4/longlong.m4: Add comments.
2873         * m4/ulonglong.m4: Likewise.
2874
2875 2006-10-10  Bruno Haible  <bruno@clisp.org>
2876
2877         Make it possible to #define stpcpy, strdup to aliases.
2878         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
2879         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
2880
2881 2006-10-10  Bruno Haible  <bruno@clisp.org>
2882
2883         Make it possible to #define gcd to an alias.
2884         * lib/gcd.c: Include config.h.
2885
2886 2006-10-10  Bruno Haible  <bruno@clisp.org>
2887
2888         Make it possible to #define c_isascii to an alias.
2889         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
2890         defined. Undefine the macros before defining them, to avoid gcc
2891         warnings.
2892         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
2893         define NO_C_CTYPE_MACROS early.
2894
2895 2006-10-10  Bruno Haible  <bruno@clisp.org>
2896
2897         Make it possible to #define set_program_name to an alias.
2898         * lib/progname.c: Don't undefine set_program_name; instead, undefine
2899         ENABLE_RELOCATABLE early.
2900
2901 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
2902
2903         Port to Tandem NSK OSS, which has 64-bit signed int but at most
2904         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
2905         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
2906         More generally, don't assume that 64-bit signed int is available
2907         if unsigned int is, and vice versa.
2908         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
2909         unsigned symbols, not on their signed counterparts.
2910         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
2911         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
2912         (UINT64_C, UINTMAX_C):
2913         Likewise.
2914         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
2915         unsigned counterparts.
2916         (Have_long_long, Unsigned): New macros.
2917         (Int): Renamed from INT.
2918         (strtoimax): Use the new macros.
2919         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
2920         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
2921         * modules/inttypes (inttypes.h): Substitute
2922         HAVE_UNSIGNED_LONG_LONG_INT.
2923         * modules/stdint (stdint.h): Likewise.
2924         (Files): Add m4/ulonglong.m4.
2925
2926 2006-10-10  Bruno Haible  <bruno@clisp.org>
2927
2928         Fix a gcc -Wshadow warning.
2929         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
2930         to 'bucket'.
2931         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
2932         gl_linked_indexof_from_to): Likewise.
2933         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
2934         Likewise.
2935         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
2936         Likewise.
2937         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
2938         Reported by Eric Blake.
2939
2940 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
2941
2942         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
2943         for NetBSD.  Problem reported by Bruno Haible.
2944
2945 2006-10-09  Jim Meyering  <jim@meyering.net>
2946
2947         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
2948         Patch from Bruno Haible.
2949
2950 2006-10-09  Jim Meyering  <jim@meyering.net>
2951
2952         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
2953         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
2954         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
2955
2956 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
2957
2958         Don't include <config.h> twice; this doesn't work in some cases,
2959         e.g., when config.h has "#define intmax_t long long int" and
2960         we include <config.h>, <inttypes.h>, <config.h> in that order.
2961         Problem reported by Matthew Woehlke in:
2962         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
2963         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
2964         * lib/fts-cycle.c: Don't include config.h.
2965         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
2966         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
2967         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
2968         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
2969         inttypes.h.
2970         * lib/xstrtoumax.c: Likewise.
2971         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
2972         __strtol and the like, so that this module is more like its siblings.
2973         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
2974         Remove; no longer needed now that we assume gnulib inttypes.h.
2975
2976 2006-10-08  Bruno Haible  <bruno@clisp.org>
2977
2978         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
2979         option.
2980
2981 2006-10-07  Jim Meyering  <jim@meyering.net>
2982
2983         * modules/inttypes (inttypes.h): Revert what seems to have been
2984         an inadvertent part of today's change: use "|", not "/" in the
2985         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
2986
2987 2006-10-07  Bruno Haible  <bruno@clisp.org>
2988
2989         * modules/sublist: New file.
2990
2991 2006-10-07  Bruno Haible  <bruno@clisp.org>
2992
2993         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
2994         * modules/argz (argz.h): Likewise.
2995         * modules/arpa_inet (arpa/inet.h): Likewise.
2996         * modules/byteswap (byteswap.h): Likewise.
2997         * modules/configmake (configmake.h): Likewise.
2998         * modules/fcntl (fcntl.h): Likewise.
2999         * modules/fnmatch (fnmatch.h): Likewise.
3000         * modules/getopt (getopt.h): Likewise.
3001         * modules/glob (glob.h): Likewise.
3002         * modules/inttypes (inttypes.h): Likewise.
3003         * modules/netinet_in (netinet/in.h): Likewise.
3004         * modules/poll (poll.h): Likewise.
3005         * modules/stdbool (stdbool.h): Likewise.
3006         * modules/stdint (stdint.h): Likewise.
3007         * modules/sys_select (sys/select.h): Likewise.
3008         * modules/sys_socket (sys/socket.h): Likewise.
3009         * modules/sys_stat (sys/stat.h): Likewise.
3010         * modules/sysexits (sysexits.h): Likewise.
3011         * modules/unistd (unistd.h): Likewise.
3012         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
3013         Add a "DO NOT EDIT" comment to the generated file.
3014         (func_import): Likewise for gnulib-comp.m4.
3015
3016 2006-10-07  Bruno Haible  <bruno@clisp.org>
3017
3018         * lib/gl_sublist.h: New file.
3019         * lib/gl_sublist.c: New file.
3020
3021 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
3022
3023         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
3024         name (relative to the original working directory) and the file
3025         name component (relative to the temporary working directory).  All
3026         callers changed.
3027         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
3028         * lib/mkdir-p.c (make_dir_parents): Likewise.
3029         * lib/mkdir-p.h (make_dir_parents): Likewise.
3030
3031 2006-10-06  Eric Blake  <ebb9@byu.net>
3032
3033         Define several macros for use by the clean-temp module.
3034         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
3035         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
3036         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
3037
3038         * lib/clean-temp.h (close_stream_temp): New declaration.
3039         * lib/clean-temp.c (includes): Pull in headers according to what
3040         other modules are in use.
3041         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
3042
3043 2006-10-06  Bruno Haible  <bruno@clisp.org>
3044
3045         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
3046         instead of fopen, fwriteerror.
3047
3048 2006-10-06  Bruno Haible  <bruno@clisp.org>
3049
3050         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
3051         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
3052         int.
3053         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
3054         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
3055         Return an error indicator.
3056         Suggested by Eric Blake.
3057
3058 2006-10-06  Bruno Haible  <bruno@clisp.org>
3059
3060         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
3061         Reported by Eric Blake.
3062
3063 2006-10-06  Bruno Haible  <bruno@clisp.org>
3064
3065         * modules/closeout (Description): Mention stderr too.
3066
3067 2006-10-06  Bruno Haible  <bruno@clisp.org>
3068         and Paul Eggert  <eggert@cs.ucla.edu>
3069
3070         * lib/closeout.c (close_stdout): Also close stderr.
3071         * lib/closeout.h: Update comment.
3072
3073 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
3074
3075         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
3076         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
3077         * lib/dirchownmod.c: Include lchown.h.
3078         * lib/lchown.c: Don't include files that lchown.h now includes.
3079         Don't declare chown, since lchown.h now does that.
3080         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
3081         (lchown): Define to rpl_chown if lchown is declared but
3082         does not exist.  Declare using a prototype if lchown is not
3083         declared.  Add a copyright notice.
3084         * lib/mkstemp.h: Include <unistd.h>.
3085         * lib/openat.c: Include lchown.h.
3086
3087         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
3088         we now test for that separately.
3089         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
3090         rather than O_NOFOLLOW, when testing whether it's possible to
3091         avoid a race condition reliably.
3092         * lib/savewd.c (savewd_chdir): Likewise.
3093
3094         Remove macros that are no longer needed now that stdint.h is
3095         reliable.
3096         * lib/fsusage.c (UINTMAX_MAX): Remove.
3097         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
3098         * lib/utimecmp.c (SIZE_MAX): Remove.
3099
3100         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
3101
3102         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
3103         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
3104         O_NOATIME works.
3105
3106 2006-10-05  Bruno Haible  <bruno@clisp.org>
3107
3108         * lib/gl_list.h (gl_sortedlist_search_from_to,
3109         gl_sortedlist_indexof_from_to): New declarations.
3110         (gl_list_implementation): New fields sortedlist_search_from_to,
3111         sortedlist_indexof_from_to.
3112         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
3113         inline functions.
3114         * lib/gl_list.c (gl_sortedlist_search_from_to,
3115         gl_sortedlist_indexof_from_to): New functions.
3116         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
3117         function.
3118         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
3119         (gl_array_sortedlist_search_from_to): New function.
3120         (gl_array_list_implementation): Update.
3121         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
3122         function.
3123         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
3124         (gl_carray_sortedlist_search_from_to): New function.
3125         (gl_carray_list_implementation): Update.
3126         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
3127         gl_linked_sortedlist_indexof_from_to): New functions.
3128         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
3129         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
3130         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
3131         gl_tree_sortedlist_indexof_from_to): New functions.
3132         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
3133         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
3134         Update.
3135         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
3136         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
3137         Update.
3138
3139 2006-10-05  Bruno Haible  <bruno@clisp.org>
3140
3141         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
3142         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
3143         (struct gl_list_implementation): Add fields search_from_to,
3144         indexof_from_to. Remove fields search, indexof.
3145         (gl_list_search): Use the search_from_to method.
3146         (gl_list_search_from, gl_list_search_from_to): New functions.
3147         (gl_list_indexof): Use the indexof_from_to method.
3148         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
3149         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
3150         (gl_list_search_from, gl_list_search_from_to): New functions.
3151         (gl_list_indexof): Use the indexof_from_to method.
3152         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
3153         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
3154         gl_array_indexof. Add start_index, end_index arguments.
3155         (gl_array_search_from_to): Renamed from gl_array_search. Add
3156         start_index, end_index arguments.
3157         (gl_array_remove, gl_array_list_implementation): Update.
3158         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
3159         gl_carray_indexof. Add start_index, end_index arguments.
3160         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
3161         start_index, end_index arguments.
3162         (gl_carray_remove, gl_carray_list_implementation): Update.
3163         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
3164         gl_linked_search. Add start_index, end_index arguments.
3165         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
3166         start_index, end_index arguments.
3167         (gl_linked_remove): Update.
3168         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
3169         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
3170         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
3171         field to 'size_t'.
3172         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
3173         gl_tree_search. Add start_index, end_index arguments.
3174         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
3175         start_index, end_index arguments.
3176         (gl_tree_remove): Update.
3177         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
3178         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
3179         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
3180         function.
3181         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
3182         gl_tree_search. Add start_index, end_index arguments.
3183         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
3184         start_index, end_index arguments.
3185         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
3186         Update.
3187         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
3188
3189 2006-10-05  Bruno Haible  <bruno@clisp.org>
3190
3191         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
3192
3193         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
3194         fwriteerror_temp): New declarations.
3195         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
3196         (descriptors): New variable.
3197         (cleanup): First, close the descriptors.
3198         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
3199         fclose_temp, fwriteerror_temp): New functions.
3200
3201 2006-10-04  Jim Meyering  <jim@meyering.net>
3202
3203         * lib/fts.c (fts_open): Tiny comment change.
3204
3205 2006-10-04  Bruno Haible  <bruno@clisp.org>
3206
3207         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
3208         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
3209         gl_LOCK_BODY.
3210         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
3211         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
3212         gl_LOCK_EARLY_BODY.
3213         (gl_LOCK): Require gl_LOCK_BODY.
3214
3215 2006-10-04  Bruno Haible  <bruno@clisp.org>
3216
3217         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
3218         (gl_oset_search_atleast): New declaration.
3219         (struct gl_oset_implementation): Add field 'search_atleast'.
3220         (gl_oset_search_atleast): New inline function.
3221         * lib/gl_oset.c (gl_oset_search_atleast): New function.
3222         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
3223         (gl_array_oset_implementation): Update.
3224         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
3225         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
3226         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
3227
3228 2006-10-04  Bruno Haible  <bruno@clisp.org>
3229
3230         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
3231
3232 2006-10-03  Bruno Haible  <bruno@clisp.org>
3233
3234         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
3235         from gl_avltreehash_list_implementation.
3236
3237 2006-10-03  Bruno Haible  <bruno@clisp.org>
3238
3239         * lib/gl_oset.c (gl_oset_add): Fix return type.
3240
3241 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
3242
3243         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
3244
3245 2006-10-02  Eric Blake  <ebb9@byu.net>
3246
3247         * modules/strnlen (Depends-on): Add extensions.
3248
3249 2006-10-02  Eric Blake  <ebb9@byu.net>
3250
3251         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
3252         definition in 2.60+.
3253
3254 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
3255
3256         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
3257         checks.
3258
3259 2006-10-02  Bruno Haible  <bruno@clisp.org>
3260
3261         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
3262         to the AUTOMAKE_OPTIONS.
3263         Reported by Jim Meyering.
3264
3265 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
3266
3267         Work around bug in Solaris 10 /proc file system:
3268         /proc/self/fd/NNN/.. isn't the parent directory of
3269         the directory whose file descriptor is NNN.  This needs to
3270         be worked around at run time, not compile time, since a
3271         program might be built on Solaris 8, where things work, and
3272         run on Solaris 10.
3273         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
3274         to use the following interface instead:
3275         (OPENAT_BUFFER_SIZE): New macro.
3276         (openat_proc_name): New function.
3277         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
3278         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
3279         Likewise.
3280         * lib/openat-proc.c: New file.
3281         * modules/openat (Files): Add lib/openat-proc.c.
3282         (Depends-on): Add same-inode, stdbool.
3283         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
3284
3285 2006-09-29  Bruno Haible  <bruno@clisp.org>
3286
3287         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
3288         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
3289         argument. Set stdout_closed before testing for ferror, not after.
3290         (fwriteerror, fwriteerror_no_ebadf): New functions.
3291
3292 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3293
3294         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
3295
3296 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
3297
3298         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
3299         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
3300
3301 2006-09-28  Jim Meyering  <jim@meyering.net>
3302
3303         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
3304         Include <unistd.h>.
3305
3306 2006-09-28  Bruno Haible  <bruno@clisp.org>
3307
3308         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
3309         * modules/linkedhash-list (Depends-on): Likewise.
3310         * modules/rbtreehash-list (Depends-on): Likewise.
3311
3312 2006-09-28  Bruno Haible  <bruno@clisp.org>
3313
3314         * lib/strndup.h: Simplify the redefinition of strndup.
3315         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
3316         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
3317
3318 2006-09-28  Bruno Haible  <bruno@clisp.org>
3319
3320         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
3321         * lib/gl_linkedhash_list.c: Likewise.
3322         * lib/gl_rbtreehash_list.c: Likewise.
3323
3324 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
3325
3326         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
3327         getaddrinfo.
3328
3329         * lib/__fpending.h: Don't include <stdio_ext.h> unless
3330         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
3331         it causes <stdio_ext.h> to cause a compile-time error.
3332         Problem reported by Nelson H. F. Beebe.
3333         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
3334         of HAVE_DECL___PENDING.
3335
3336         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
3337         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
3338         declaration.
3339
3340 2006-09-27  Jim Meyering  <jim@meyering.net>
3341
3342         This file could end up with a definition for a function
3343         named __strndup, rather than rpl_strndup on a system with
3344         incomplete weak_alias support.
3345         * lib/strndup.c (strndup): Rename from __strndup.
3346         Remove #defines that used to map __strndup to strndup.
3347         Don't use K&R prototypes.
3348         Remove LIBC-related code, since this file is not sync'd with glibc.
3349         * lib/strndup.h: Revamp, accordingly.
3350         * m4/strndup.m4: Modernize.
3351
3352 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
3353
3354         * modules/savewd (Depends-on): Add 'raise'.
3355         * lib/savewd.c: Include <signal.h>, for 'raise'.
3356
3357 2006-09-26  Jim Meyering  <jim@meyering.net>
3358
3359         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
3360         when we detect Darwin 8.7.0's acl_get_file bug.
3361         Rearrange to perform the new (below) run-test while $LIBS
3362         contains any acl-related library.  Set USE_ACL at the end.
3363         (gl_ACL_GET_FILE): New function.
3364
3365 2006-09-26  Eric Blake  <ebb9@byu.net>
3366
3367         * lib/verror.c: Include <config.h> unconditionally.
3368
3369 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
3370
3371         * modules/clock-time (Maintainer): Add self.
3372         * modules/getlogin_r (Depends-on): Add extensions.
3373
3374 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3375
3376         * modules/clock-time: New module.
3377         * modules/nanosleep (Depends-on): Add clock-time.
3378         * modules/gethrxtime (Depends-on): Likewise.
3379         * modules/gettime (Depends-on): Likewise.
3380         * modules/settime (Depends-on): Likewise.
3381
3382         * modules/fts-lgpl: Depend on openat.
3383         * modules/mkancesdirs: Depend on savewd.
3384         * modules/mkdir-p: Likewise.
3385
3386 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3387
3388         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
3389
3390         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
3391         `gl_have_arbitrary_file_name_length_limit' to
3392         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
3393         actually works between configure runs.
3394
3395 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3396             Bruno Haible  <bruno@clisp.org>
3397
3398         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
3399
3400 2006-09-25  Jim Meyering  <jim@meyering.net>
3401
3402         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
3403         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
3404
3405 2006-09-25  Eric Blake  <ebb9@byu.net>
3406
3407         * gnulib-tool (func_import, func_create_testdir): Fix typos in
3408         exec's in 2006-09-18 patch when shuffling fds.
3409
3410 2006-09-25  Bruno Haible  <bruno@clisp.org>
3411
3412         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
3413         Reported by Jim Meyering.
3414
3415 2006-09-24  Jim Meyering  <jim@meyering.net>
3416
3417         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
3418         compare a pointer against a literal "0".  That caused failures with
3419         at least HP-UX's hpcc.
3420
3421 2006-09-22  Simon Josefsson  <jas@extundo.com>
3422
3423         * modules/gc-sha1:
3424         * modules/gc-md4:
3425         * modules/gc-hmac-sha1:
3426         * modules/gc-hmac-md5:
3427         * modules/gc-des:
3428         * modules/gc-arcfour: Distribute more files.
3429
3430 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3431
3432         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
3433         (gl_linked_iterator_from_to): Initialize struct completely.
3434         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
3435         (gl_tree_iterator_from_to): Likewise
3436         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
3437         * lib/gl_array_list.c [lint] (gl_array_iterator)
3438         (gl_array_iterator_from_to): Likewise.
3439         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
3440         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
3441         (gl_carray_iterator_from_to): Likewise.
3442
3443         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
3444         * lib/md4.c (md4_process_block): Remove unused variable.
3445         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
3446         parentheses for clarity.
3447
3448 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3449
3450         * modules/bison-i18n (Depends-on): Add gettext.
3451
3452 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3453
3454         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
3455         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
3456         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
3457         also add missing comma that caused broken test.
3458         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
3459         stdlib.h, for `abort'.
3460         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
3461         variables.
3462         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
3463         include unistd.h if present, for `rmdir'.
3464         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
3465         variables.
3466         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
3467         in the process include standard headers for prototypes.
3468         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
3469         gets declared on GNU/Linux.
3470         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
3471         unistd.h, for `rmdir'.
3472         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
3473
3474         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
3475         always true.
3476         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
3477
3478         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
3479
3480 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3481
3482         * gnulib-tool (func_version): Create output all at once.  This
3483         may help avoid triggering unnecessary SIGPIPEs, and at any
3484         rate it doesn't hurt.
3485
3486 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3487             Bruno Haible  <bruno@clisp.org>
3488
3489         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
3490         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
3491         * m4/signed.m4 (bh_C_SIGNED): Likewise.
3492
3493         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
3494         (gl_FUNC_VASPRINTF): Invoke it.
3495
3496 2006-09-22  Bruno Haible  <bruno@clisp.org>
3497
3498         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
3499         getloadavg.c as first argument.
3500
3501 2006-09-22  Bruno Haible  <bruno@clisp.org>
3502
3503         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
3504         at the beginning of the gl_INIT macro.
3505         * modules/getloadavg (configure.ac): Pass $gl_source_base to
3506         gl_GETLOADAVG.
3507
3508 2006-09-22  Bruno Haible  <bruno@clisp.org>
3509
3510         * gnulib-tool (func_create_megatestdir): Don't include the config-h
3511         module.
3512         Suggested by Ralf Wildenhues.
3513
3514 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
3515
3516         Import this patch from libc:
3517
3518         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
3519
3520         * lib/regex_internal.c (re_string_reconstruct): Handle
3521         offset < pstr->valid_raw_len && pstr->offsets_needed case.
3522         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
3523         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
3524         re_string_context_at.
3525
3526         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
3527         now requires it.
3528         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
3529         gl_REGEX now does it for us.
3530         (gl_REGEX): Add test taken from
3531         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
3532
3533         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
3534         Check that large offsets work.  Modernize Autoconf usages.
3535         Prefer "yes" to mean a good thing rather than a bad.
3536         Don't put "#define mkstemp" in config.h, as this might interfere
3537         with standard system headers that "#define mkstemp mkstemp64".
3538
3539         * modules/mkstemp (Depends-on): Add extensions, so that
3540         mkstemp is visible on some platforms.
3541         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
3542         (Include): Change to "mkstemp.h" from <stdlib.h>.
3543         (Files): Add mkstemp.h.
3544
3545         * lib/mkstemp.h: New file, since some standard headers
3546         #define mkstemp.
3547         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
3548         Include "mkstemp.h".
3549         Make the _LIBC code resemble glibc original more,
3550         e.g., use K&R style.
3551         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
3552         (mkstemp): Remove, since mkstemp.h does this for us.
3553         * lib/stdlib--.h: Include mkstemp.h.
3554
3555         Import this patch from libc:
3556
3557         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3558
3559         * lib/tempname.c (__gen_tempname): Change attempts_min
3560         into a macro.  Use preprocessor to decide how to initialize
3561         attempts [Coverity CID 67].
3562
3563 2006-09-20  Bruno Haible  <bruno@clisp.org>
3564
3565         * lib/mkdtemp.c: Import from libc.
3566         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
3567                 * sysdeps/posix/tempname.c (__gen_tempname): Change
3568                 attempts_min into a macro.  Use preprocessor to decide how to
3569                 initialize attempts [Coverity CID 67].
3570         2001-11-27  Paul Eggert  <eggert@twinsun.com>
3571                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
3572                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
3573
3574 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3575
3576         * gnulib-tool (func_exit): New function, to allow to pass the
3577         exit status portably through the trap.  Use everywhere.
3578         (--help, --version): Signal a write error.
3579         (trap): catch SIGPIPE, for write errors.
3580         Exit at the end of the trap, with the correct exit status.
3581
3582 2006-09-19  Karl Berry  <karl@gnu.org>
3583
3584         * doc/gnulib.texi: note about the license texinfo files.
3585
3586 2006-09-19  Eric Blake  <ebb9@byu.net>
3587
3588         * gnulib-tool: Avoid space-tab.
3589
3590 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3591
3592         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
3593         that prevented coreutils 6.1 from building.  Problem reported
3594         by Petter Reinholdtsen.
3595
3596 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
3597
3598         * gnulib-tool (avoidlist): Fix typo that broke options like
3599         --avoid=lock that are used by coreutils bootstrap.
3600
3601 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
3602
3603         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
3604         more systematically.
3605
3606 2006-09-18  Jim Meyering  <jim@meyering.net>
3607
3608         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
3609
3610 2006-09-18  Bruno Haible  <bruno@clisp.org>
3611
3612         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
3613
3614 2006-09-18  Bruno Haible  <bruno@clisp.org>
3615
3616         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
3617         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
3618         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
3619         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
3620         * m4/gettext.m4: Require autoconf >= 2.52.
3621         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
3622         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
3623         of gl_cv_header_inttypes_h.
3624
3625 2006-09-18  Bruno Haible  <bruno@clisp.org>
3626
3627         * lib/javaversion.c: Include configmake.h.
3628
3629 2006-09-18  Bruno Haible  <bruno@clisp.org>
3630
3631         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
3632         avoid that the while loops be executed in a subshell.
3633
3634 2006-09-18  Bruno Haible  <bruno@clisp.org>
3635
3636         * MODULES.html.sh (func_module): Break long lines.
3637         Suggested by Bruce Korb <bkorb@gnu.org>.
3638
3639 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3640
3641         Speed up by a factor of 1.12.
3642         * gnulib-tool (nl): New variable.
3643         (func_import): Rewrite include directive extraction to only read each
3644         directive once.
3645
3646 2006-09-17  Bruno Haible  <bruno@clisp.org>
3647
3648         * modules/javaversion (Makefile.am): Remove DEFS setting.
3649         (Depends-on): Add configmake, for PKGDATADIR definition.
3650
3651 2006-09-17  Bruno Haible  <bruno@clisp.org>
3652
3653         * gnulib-tool (func_create_testdir): Rewrite all files at once.
3654
3655 2006-09-17  Bruno Haible  <bruno@clisp.org>
3656
3657         * gnulib-tool (func_append): New function, stolen from libtool.m4.
3658         (func_modules_transitive_closure, func_modules_add_dummy,
3659         func_modules_to_filelist, func_import, func_create_testdir,
3660         func_create_megatestdir, ...): Use it wherever possible.
3661         Suggested by Ralf Wildenhues.
3662
3663 2006-09-16  Karl Berry  <karl@gnu.org>
3664
3665         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
3666         to avoid sectioning errors.
3667         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
3668         [ifinfo]: blank line after @center-ed titles.
3669         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
3670         Spell FSF address consistently with others.
3671         (These changes approved by rms.)
3672
3673 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3674
3675         Speed up by a factor of 1.61.
3676         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
3677         already checked module names again.
3678
3679 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3680
3681         Speed up by a factor of 1.13.
3682         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
3683         for new_files, and the input to func_add_or_update.
3684
3685 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3686
3687         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
3688         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
3689
3690 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3691
3692         * modules/mkancesdirs (Depends-on): Add fcntl.
3693         * modules/savewd: New file.
3694         * MODULES.html.sh (File system functions): Add savewd.
3695
3696         * modules/configmake (Makefile.am): Add support for the
3697         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
3698
3699 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3700
3701         * m4/savewd.m4: New file.
3702
3703 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
3704
3705         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
3706         (dirchownmod): New arg FD.  All callers changed.
3707         Use FD rather than opening the directory ourself, as opening is
3708         now the caller's responsibility.
3709         * lib/dirchownmod.h: Likewise.
3710         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
3711         hosts that require <sys/types.h> before <sys/stat.h>.  Include
3712         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
3713         (test_dir): Remove.
3714         (mkancesdirs): Return length of prefix of FILE that has already
3715         been made, or -2 if there is a child doing the work.  Redo
3716         algorithm so that it is O(N) rather than O(N**2).  Optimize away
3717         ".", and treat ".." specially since it might stray back into
3718         already-created areas.  Use a subprocess if necessary.  New arg
3719         WD; all users changed.  MAKE_DIR function should now return 1
3720         if it creates a directory that is not readable.  Return -2 if
3721         a child process is spun off.
3722         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
3723         Adjust signature to match code.
3724         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
3725         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
3726         all users changed.
3727         * lib/savewd.c, lib/savewd.h: New files.
3728
3729 2006-09-15  Jim Meyering  <jim@meyering.net>
3730
3731         * modules/rename-dest-slash: New module.
3732         * MODULES.html.sh (posix_compat): Add it here.
3733
3734         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
3735
3736 2006-09-15  Jim Meyering  <jim@meyering.net>
3737
3738         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
3739         file.
3740
3741         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
3742
3743 2006-09-15  Jim Meyering  <jim@meyering.net>
3744
3745         * lib/rename-dest-slash.c (has_trailing_slash): Use
3746         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
3747         (rpl_rename_dest_slash): Perform the cheaper trailing slash
3748         test before testing whether SRC is a directory.
3749         Suggestions from Bruno Haible.
3750
3751         Avoid a warning about an unused variable.
3752         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
3753         into the #ifdef block where it's used.
3754
3755         * lib/rename-dest-slash.c: New file.
3756
3757 2006-09-14  Bruno Haible  <bruno@clisp.org>
3758
3759         * lib/allocsa.c: Include <config.h> unconditionally.
3760         * lib/asnprintf.c: Likewise.
3761         * lib/asprintf.c: Likewise.
3762         * lib/c-strcasecmp.c: Likewise.
3763         * lib/c-strcasestr.c: Likewise.
3764         * lib/c-strncasecmp.c: Likewise.
3765         * lib/c-strstr.c: Likewise.
3766         * lib/classpath.c: Likewise.
3767         * lib/clean-temp.c: Likewise.
3768         * lib/concatpath.c: Likewise.
3769         * lib/copy-file.c: Likewise.
3770         * lib/csharpcomp.c: Likewise.
3771         * lib/csharpexec.c: Likewise.
3772         * lib/execute.c: Likewise.
3773         * lib/fatal-signal.c: Likewise.
3774         * lib/findprog.c: Likewise.
3775         * lib/fwriteerror.c: Likewise.
3776         * lib/gl_array_list.c: Likewise.
3777         * lib/gl_array_oset.c: Likewise.
3778         * lib/gl_avltree_list.c: Likewise.
3779         * lib/gl_avltree_oset.c: Likewise.
3780         * lib/gl_avltreehash_list.c: Likewise.
3781         * lib/gl_carray_list.c: Likewise.
3782         * lib/gl_linked_list.c: Likewise.
3783         * lib/gl_linkedhash_list.c: Likewise.
3784         * lib/gl_list.c: Likewise.
3785         * lib/gl_oset.c: Likewise.
3786         * lib/gl_rbtree_list.c: Likewise.
3787         * lib/gl_rbtree_oset.c: Likewise.
3788         * lib/gl_rbtreehash_list.c: Likewise.
3789         * lib/imaxabs.c: Likewise.
3790         * lib/imaxdiv.c: Likewise.
3791         * lib/javacomp.c: Likewise.
3792         * lib/javaexec.c: Likewise.
3793         * lib/javaversion.c: Likewise.
3794         * lib/linebreak.c: Likewise.
3795         * lib/localcharset.c: Likewise.
3796         * lib/lock.c: Likewise.
3797         * lib/mbchar.c: Likewise.
3798         * lib/mbswidth.c: Likewise.
3799         * lib/mkdtemp.c: Likewise.
3800         * lib/pipe.c: Likewise.
3801         * lib/printf-args.c: Likewise.
3802         * lib/printf-parse.c: Likewise.
3803         * lib/progname.c: Likewise.
3804         * lib/progreloc.c: Likewise.
3805         * lib/readlink.c: Likewise.
3806         * lib/sh-quote.c: Likewise.
3807         * lib/stpcpy.c: Likewise.
3808         * lib/stpncpy.c: Likewise.
3809         * lib/strcasecmp.c: Likewise.
3810         * lib/strcasestr.c: Likewise.
3811         * lib/strcspn.c: Likewise.
3812         * lib/striconv.c: Likewise.
3813         * lib/strncasecmp.c: Likewise.
3814         * lib/strnlen1.c: Likewise.
3815         * lib/strstr.c: Likewise.
3816         * lib/strtok_r.c: Likewise.
3817         * lib/tls.c: Likewise.
3818         * lib/tmpdir.c: Likewise.
3819         * lib/unicodeio.c: Likewise.
3820         * lib/unsetenv.c: Likewise.
3821         * lib/vasnprintf.c: Likewise.
3822         * lib/vasprintf.c: Likewise.
3823         * lib/wait-process.c: Likewise.
3824         * lib/xallocsa.c: Likewise.
3825         * lib/xsetenv.c: Likewise.
3826         * lib/xstriconv.c: Likewise.
3827
3828 2006-09-13  Simon Josefsson  <jas@extundo.com>
3829
3830         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
3831         that internally, suggested by Ralf Wildenhues
3832         <Ralf.Wildenhues@gmx.de>.
3833
3834 2006-09-13  Simon Josefsson  <jas@extundo.com>
3835
3836         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
3837         @LIBOBJS@.
3838         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3839
3840 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
3841
3842         * lib/_fpending.c: Include <config.h> unconditionally, since we no
3843         longer worry about uses that don't define HAVE_CONFIG_H.
3844         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
3845         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
3846         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
3847         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
3848         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
3849         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
3850         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
3851         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
3852         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
3853         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
3854         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
3855         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
3856         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
3857         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
3858         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
3859         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
3860         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
3861         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
3862         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
3863         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
3864         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
3865         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
3866         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
3867         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
3868         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
3869         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
3870         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
3871         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
3872         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
3873         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
3874         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
3875         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
3876         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
3877         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
3878         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
3879         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
3880         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
3881         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
3882         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
3883         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
3884         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
3885         Likewise.
3886
3887 2006-09-13  Eric Blake  <ebb9@byu.net>
3888
3889         * lib/getopt.c: Fix typo in last commit.
3890
3891 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
3892
3893         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
3894         dgettext.
3895
3896 2006-09-12  Jim Meyering  <jim@meyering.net>
3897
3898         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
3899         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
3900         Reported by Nelson H. F. Beebe.
3901
3902 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
3903
3904         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
3905         program_invocation_name and program_invocation_short_name are
3906         initialized.
3907         * lib/argp-namefrob.h: Move declarations of program_invocation_name
3908         and program_invocation_short_name to argp.h, so they are visible
3909         to user programs.
3910         * lib/argp.h: Likewise
3911
3912 2006-09-10  Bruno Haible  <bruno@clisp.org>
3913
3914         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
3915         m4/inttypes_h.m4, m4/uintmax_t.m4.
3916
3917 2006-09-10  Bruno Haible  <bruno@clisp.org>
3918
3919         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
3920         gl_AC_TYPE_UINTMAX_T.
3921
3922 2006-09-10  Bruno Haible  <bruno@clisp.org>
3923
3924         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
3925
3926 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
3927
3928         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
3929         convention.  Text proposed by Bruno Haible.
3930         (struct argp_option): Document the use of N_() wrappers.
3931
3932         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
3933         '\v', and translate the two parts separately, instead of feeding
3934         the whole string to gettext.  This allows to exclude
3935         '\v' from the strings visible to the translator by writing doc
3936         strings as N_("..") "\v" N_("..").
3937
3938 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
3939
3940         * config/srclist.txt: Undo latest change; the bug was fixed.
3941
3942 2006-09-09  Bruno Haible  <bruno@clisp.org>
3943
3944         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
3945         assignments if building a library without libtool.
3946         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
3947         in func_emit_lib_Makefile_am.
3948         (func_import): When building a static library libfoo.a, arrange to
3949         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
3950         (func_create_testdir): Likewise.
3951         * modules/gc (configure.ac, Makefile.am): If building statically,
3952         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
3953         * modules/iconvme (configure.ac, Makefile.am): Likewise.
3954         * modules/striconv (configure.ac, Makefile.am): Likewise.
3955         Based on a suggestion by Ralf Wildenhues.
3956
3957 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3958
3959         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
3960         Check for unistd.h too, since Autoconf doesn't assume POSIX.
3961         Also:
3962
3963         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3964         Add year_2050_test to catch glibc bug 2821
3965         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3966
3967         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
3968         Prefer #ifdef to #if.
3969
3970         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
3971         Return from 'main' instead of calling 'exit'.
3972
3973 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3974
3975         * lib/mktime.c (guess_time_tm): Fix bug where mktime
3976         returned the maximum time_t value rather than (time_t) -1.
3977         Problem originally reported by William Bardwell
3978         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
3979
3980         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3981         Moved to here ...
3982         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
3983         ... from here.
3984
3985 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
3986
3987         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
3988         2821 is fixed.
3989
3990 2006-09-08  Jim Meyering  <jim@meyering.net>
3991
3992         Don't make generated files read-only.  That would bother too many
3993         people.  However, do retain the ability to work when targets are
3994         read-only: remove the destination and temporary files before writing
3995         them (when generated via sed or echo), or by using the -f option for
3996         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
3997         * modules/alloca-opt, modules/argz, modules/arpa_inet:
3998         * modules/byteswap, modules/configmake, modules/fcntl:
3999         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
4000         * modules/localcharset, modules/netinet_in, modules/poll:
4001         * modules/stdbool, modules/stdint, modules/sys_select:
4002         * modules/sys_socket, modules/sys_stat, modules/sysexits:
4003
4004 2006-09-08  Jim Meyering  <jim@meyering.net>
4005
4006         Avoid new build failure on FreeBSD 6.0.
4007         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
4008         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
4009         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
4010
4011 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4012
4013         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
4014
4015 2006-09-07  Jim Meyering  <jim@meyering.net>
4016
4017         Fix global typo in last change: use chmod u-w, not chmod u-x.
4018         Spotted by Paul Eggert and Bruce Korb.
4019         * modules/alloca-opt, modules/argz, modules/arpa_inet:
4020         * modules/byteswap, modules/configmake, modules/fcntl:
4021         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
4022         * modules/localcharset, modules/netinet_in, modules/poll:
4023         * modules/stdbool, modules/stdint, modules/sys_select:
4024         * modules/sys_socket, modules/sys_stat, modules/sysexits:
4025
4026 2006-09-06  Jim Meyering  <jim@meyering.net>
4027
4028         Make generated files be read-only.
4029         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
4030         Ensure that each generated file is now read-only.
4031         * modules/argz: Likewise.
4032         * modules/arpa_inet: Likewise.
4033         * modules/byteswap: Likewise.
4034         * modules/configmake: Likewise.
4035         * modules/fcntl: Likewise.
4036         * modules/fnmatch: Likewise.
4037         * modules/getopt: Likewise.
4038         * modules/glob: Likewise.
4039         * modules/inttypes: Likewise.
4040         * modules/netinet_in: Likewise.
4041         * modules/poll: Likewise.
4042         * modules/stdbool: Likewise.
4043         * modules/stdint: Likewise.
4044         * modules/sys_select: Likewise.
4045         * modules/sys_socket: Likewise.
4046         * modules/sys_stat: Likewise.
4047         * modules/sysexits: Likewise.
4048         * modules/localcharset: Same as above, but continue using temporary
4049         file named "t-$@" (why different?) rather than the "$@-t" used
4050         everywhere else.
4051
4052         * modules/sysexits (Makefile.am): Replace literal occurrences
4053         of "sysexit.h" more readable, and more consistent, "$@".
4054
4055 2006-09-06  Bruno Haible  <bruno@clisp.org>
4056
4057         * modules/striconv: New file.
4058         * modules/xstriconv: New file.
4059         * MODULES.html.sh (Internationalization functions): Add striconv,
4060         xstriconv.
4061
4062 2006-09-06  Bruno Haible  <bruno@clisp.org>
4063
4064         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
4065         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
4066         not using libtool correctly.
4067
4068 2006-09-06  Bruno Haible  <bruno@clisp.org>
4069
4070         * lib/striconv.h: New file.
4071         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
4072         iconvstring.c.
4073         * lib/xstriconv.h: New file.
4074         * lib/xstriconv.c: New file.
4075
4076 2006-09-06  Bruno Haible  <bruno@clisp.org>
4077
4078         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4079         lib_..._LDFLAGS.
4080
4081 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4082
4083         * lib/argz_.h: Sync from Libtool.
4084
4085         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
4086                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
4087
4088         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
4089
4090 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
4091
4092         * modules/trim: New file.
4093
4094 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
4095
4096         * lib/trim.h: New file.
4097         * lib/trim.c: New file.
4098
4099 2006-09-05  Bruno Haible  <bruno@clisp.org>
4100
4101         * MODULES.html.sh (String handling): Add trim.
4102
4103 2006-09-04  Karl Berry  <karl@gnu.org>
4104
4105         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
4106         until next release.
4107
4108 2006-09-03  Bruno Haible  <bruno@clisp.org>
4109
4110         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
4111         correctly.
4112
4113 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4114
4115         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
4116         not gl_GETLOADAVG.  Omit unneeded semicolons.
4117         Problems reported by Ralf Wildenhues in
4118         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
4119         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
4120         at the end, which is the usual gnulib style.
4121
4122         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
4123         of doing all the work ourselves.
4124         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
4125         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
4126
4127 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4128
4129         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
4130         Problem reported by Ralf Wildenhues in
4131         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
4132
4133         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
4134         HAVE_STRUCT_STATFS_F_FSTYPENAME.
4135
4136 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
4137
4138         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
4139         yesterday's patch by changing test -n to test -z.
4140
4141 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4142
4143         * modules/getloadavg (Files): Add m4/getloadavg.m4.
4144         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
4145         the former is now obsolescent.
4146
4147         * modules/chdir-long (Depends-on): Add fcntl.
4148
4149 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4150
4151         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
4152         obsolescent, and programs should use gnulib instead.
4153         * m4/getloadavg.m4: New file, with contents taken from Autoconf
4154         but with prefixes changed.
4155
4156 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
4157
4158         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
4159         or stdbool.h, because they might not exist while configuring.
4160
4161         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
4162         Don't include unistd.h or limits.h; not needed, since chdir-long.h
4163         does that for us.
4164         (O_DIRECTORY): Remove.
4165
4166 2006-08-31  Eric Blake  <ebb9@byu.net>
4167
4168         * gnulib-tool: Don't let emacs change spaces to TAB.
4169
4170 2006-08-31  Bruno Haible  <bruno@clisp.org>
4171
4172         * gnulib-tool: When calling func_import more than once, do it in a
4173         subshell.
4174         Reported by Eric Blake <ebb9@byu.net>.
4175
4176 2006-08-31  Bruno Haible  <bruno@clisp.org>
4177
4178         * gnulib-tool (nl): Remove variable.
4179         (sed_transform_lib_file): Use more robust test for config-h module.
4180         (func_import): Fix typo in 2006-08-25 patch.
4181
4182 2006-08-31  Bruno Haible  <bruno@clisp.org>
4183
4184         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
4185         specified, augment Makefile.am variables instead of assigning them.
4186
4187 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4188
4189         Work around a bug in both the Linux and SunOS 64-bit kernels:
4190         nanosleep mishandles sleeps for longer than 2**31 seconds.
4191         Problem reported by Frank v Waveren in
4192         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
4193         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
4194         Check for nanosleep bug.
4195         (LIB_NANOSLEEP): Append clock_gettime library if needed.
4196
4197 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4198
4199         Work around a bug in both the Linux and SunOS 64-bit kernels:
4200         nanosleep mishandles sleeps for longer than 2**31 seconds.
4201         Problem reported by Frank v Waveren in
4202         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
4203         * lib/nanosleep.c (BILLION): New constant.
4204         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
4205         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
4206         implementation.
4207
4208 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4209
4210         * modules/nanosleep (Depends-on): Add gettime.
4211
4212 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
4213         and Simon Josefsson  <jas@extundo.com>
4214         and Oskar Liljeblad  <oskar@osk.mine.nu>
4215
4216         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
4217         * gnulib-tool (func_import): New license type 'unmodifiable license
4218         text'.
4219         * modules/fdl: Use it.  Longer description.
4220         * module/gpl, module/lgpl: New files.
4221
4222 2006-08-30  Jim Meyering  <jim@meyering.net>
4223
4224         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
4225         shadowing the parameter.
4226
4227 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4228
4229         Sync from Libtool:
4230
4231         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4232
4233         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
4234         sharing with gnulib.  Report by Eric Blake.
4235
4236 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4237
4238         * modules/isapipe: New file.
4239         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
4240
4241 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4242
4243         * modules/configmake (Makefile.am): Add a comment, and omit
4244         the CONFIGMAKE_ prefix from generated macro names.  Suggested
4245         by Bruno Haible.
4246
4247 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4248
4249         * m4/isapipe.m4: New file.
4250
4251 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
4252
4253         * lib/isapipe.c, lib/isapipe.h: New files.
4254
4255 2006-08-29  Jim Meyering  <jim@meyering.net>
4256
4257         * modules/configmake (Makefile.am): Make configmake.h depend on
4258         Makefile.  Otherwise, a stale configmake.h could hang around.
4259
4260 2006-08-29  Eric Blake  <ebb9@byu.net>
4261
4262         * lib/error.c (error_at_line, print_errno_message): Match libc, after
4263         resolution of upstream bug 3044.
4264
4265 2006-08-29  Bruno Haible  <bruno@clisp.org>
4266
4267         * modules/localcharset (Depends-on): Add configmake.
4268         (Makefile.am): Remove setting of LIBDIR through DEFS.
4269
4270 2006-08-29  Bruno Haible  <bruno@clisp.org>
4271
4272         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
4273         defined.
4274
4275 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4276
4277         * modules/fcntl: New file.
4278         * modules/chdir-safer (Depends-on): Add fcntl.
4279         * modules/fts: Likewise.
4280         * modules/mkdir-p: Likewise.
4281
4282         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
4283         This undoes the most recent change, since we're now addressing the
4284         problem in a different way.
4285
4286         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
4287         into output, since the output might be called Makefile.am even
4288         if $makefile_name is something different.
4289         (func_import): Use $makefile_am rather than
4290         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
4291         empty.
4292
4293         * modules/inttypes (Files): Add m4/inttypes-h.m4.
4294
4295 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4296
4297         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
4298         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
4299         recent change to stdint.m4, since we're now addressing the problem in a
4300         different way.
4301
4302 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4303
4304         * m4/fcntl_h.m4: New file.
4305
4306 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
4307
4308         * lib/fcntl_.h: New file.
4309         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
4310         the fcntl module.
4311         * lib/dirchownmod.c: Likewise.
4312         * lib/fts.c: Likewise.
4313
4314         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
4315         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
4316         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
4317         just before including <inttypes.h>, to avoid circular inclusion.
4318
4319 2006-08-28  Jim Meyering  <jim@meyering.net>
4320
4321         * doc/visibility.texi: Actually read and correct the grammar of the
4322         sentence affected by yesterday's change.
4323
4324 2006-08-28  Eric Blake  <ebb9@byu.net>
4325
4326         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
4327         needs wrapper.
4328
4329 2006-08-28  Eric Blake  <ebb9@byu.net>
4330
4331         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
4332
4333 2006-08-28  Eric Blake  <ebb9@byu.net>
4334
4335         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
4336
4337 2006-08-28  Bruno Haible  <bruno@clisp.org>
4338
4339         * modules/c-strstr: New file, from GNU gettext.
4340         * MODULES.html.sh (String handling): Add c-strstr.
4341
4342 2006-08-28  Bruno Haible  <bruno@clisp.org>
4343
4344         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
4345         macros.
4346         Reported by Eric Blake.
4347
4348 2006-08-28  Bruno Haible  <bruno@clisp.org>
4349
4350         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
4351         (VASNPRINTF): Return a string of length > INT_MAX without failing.
4352         * lib/vasprintf.c: Include errno.h, limits.h.
4353         (EOVERFLOW): New fallback definition.
4354         (vasprintf): Test here whether the string length is > INT_MAX.
4355         * lib/vsnprintf.c: Include errno.h, limits.h.
4356         (EOVERFLOW): New fallback definition.
4357         (vsnprintf): Fix bug when generated string was too long for the buffer.
4358         Test here whether the string length is > INT_MAX.
4359
4360 2006-08-28  Bruno Haible  <bruno@clisp.org>
4361
4362         * lib/inttypes_.h (SCNX*): Remove definitions.
4363         Reported by Eric Blake.
4364
4365 2006-08-28  Bruno Haible  <bruno@clisp.org>
4366
4367         * lib/c-strstr.h: New file, from GNU gettext.
4368         * lib/c-strstr.c: New file, from GNU gettext.
4369
4370 2006-08-28  Bruno Haible  <bruno@clisp.org>
4371
4372         * gnulib-tool: Reorder some statements.
4373
4374 2006-08-28  Bruno Haible  <bruno@clisp.org>
4375
4376         * gnulib-tool: New option --makefile-name.
4377         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
4378         $makefile_name.
4379         (func_import): Write $makefile_name to the cache file, and read it from
4380         there unless explicitly specified. Use $makefile_name as file name
4381         instead of Makefile.am. Adjust the recommendations accordingly.
4382
4383 2006-08-28  Bruno Haible  <bruno@clisp.org>
4384
4385         * gnulib-tool (func_verify_module): Check against misapplying patch.
4386
4387 2006-08-28  Bruno Haible  <bruno@clisp.org>
4388
4389         * gnulib-tool (func_relativize, func_relconcat): New functions.
4390         Give an error if --local-dir is given with --update.
4391         Remove trailing slashes from $local_gnulib_dir.
4392         (func_import): Store the relativized $local_gnulib_dir in
4393         gnulib-cache.m4, and read it from there if not specified explicitly.
4394
4395 2006-08-28  Bruno Haible  <bruno@clisp.org>
4396
4397         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
4398         is the current directory. Respect also $local_gnulib_dir.
4399
4400 2006-08-28  Bruno Haible  <bruno@clisp.org>
4401             Simon Josefsson  <jas@extundo.com>
4402
4403         BeOS portability.
4404         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
4405
4406 2006-08-27  Jim Meyering  <jim@meyering.net>
4407
4408         * doc/visibility.texi: Remove duplicate word: "pointer".
4409
4410 2006-08-26  Bruno Haible  <bruno@clisp.org>
4411
4412         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
4413         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
4414         (Makefile.am): Create inttypes.h from inttypes_.h.
4415         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
4416
4417         * modules/imaxabs: New file.
4418
4419         * modules/imaxdiv: New file.
4420
4421 2006-08-26  Bruno Haible  <bruno@clisp.org>
4422
4423         * m4/inttypes.m4: New file.
4424         * m4/_inttypes_h.m4: Remove file.
4425         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
4426         PRI_MACROS_BROKEN.
4427         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
4428
4429         * m4/imaxabs.m4: New file.
4430
4431         * m4/imaxdiv.m4: New file.
4432
4433 2006-08-26  Bruno Haible  <bruno@clisp.org>
4434
4435         * lib/inttypes_.h: New file.
4436         * lib/inttypes.h: Remove file.
4437         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
4438
4439         * lib/imaxabs.c: New file.
4440
4441         * lib/imaxdiv.c: New file.
4442
4443 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4444
4445         New config-h module, so that "make" output needn't be cluttered
4446         by -DHAVE_CONFIG_H.
4447         * MODULES.html.sh (Support for building libraries and executables):
4448         Add config-h.
4449         * modules/config-h: New file.
4450         * gnulib-tool (nl, sed_transform_lib_file): New vars.
4451         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
4452         the config-h module is used.
4453
4454         New configmake module, so that "make" output needn't be cluttered
4455         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
4456         * MODULES.html.sh (Support for building libraries and executables):
4457         Add configmake.
4458         * modules/configmake: New file.
4459
4460 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
4461
4462         * m4/config-h.m4: New file.
4463
4464 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4465
4466         * config/srclist.txt: Add elisp-comp.
4467
4468 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
4469
4470         * MODULES.html.sh (Support for building libraries and executables):
4471         Add elisp-comp.
4472         * build-aux/elisp-comp: New file.
4473         * modules/elisp-comp: New file.
4474
4475 2006-08-24  Bruno Haible  <bruno@clisp.org>
4476
4477         * gnulib-tool (func_create_testdir): Use non-default values of
4478         sourcebase and m4base.
4479
4480 2006-08-24  Bruno Haible  <bruno@clisp.org>
4481
4482         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
4483         HTML structure.
4484
4485 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
4486
4487         * modules/openat (Depends-on): Add lchown.
4488
4489 2006-08-23  Bruno Haible  <bruno@clisp.org>
4490
4491         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
4492         of gl_LOCK_EARLY instead of gl_LOCK.
4493
4494 2006-08-23  Bruno Haible  <bruno@clisp.org>
4495
4496         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
4497         on OSF/1 to no.
4498         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
4499
4500 2006-08-23  Bruno Haible  <bruno@clisp.org>
4501
4502         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
4503         as unusable.
4504
4505         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
4506         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
4507         (gl_LOCK): New macro.
4508
4509 2006-08-22  Simon Josefsson  <jas@extundo.com>
4510
4511         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
4512         to md5 module.
4513
4514 2006-08-22  Simon Josefsson  <jas@extundo.com>
4515
4516         * MODULES.html.sh: Add "Support for maintaining and release
4517         projects".
4518
4519         * build-aux/gnupload: New file, from coreutils.
4520
4521 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4522
4523         Avoid the need for AC_LIBSOURCES in m4 macros.
4524         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
4525         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
4526         * modules/check-version (EXTRA_DIST): Add check-version.h.
4527         * modules/crc (EXTRA_DIST): Add crc.h.
4528         * modules/des (EXTRA_DIST): Add des.h.
4529         * modules/gc (EXTRA_DIST): Add gc.h.
4530         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
4531         * modules/getline (EXTRA_DIST): Add getline.h.
4532         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
4533         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
4534         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
4535         * modules/md2 (EXTRA_DIST): Add md2.h.
4536         * modules/md4 (EXTRA_DIST): Add md4.h.
4537         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
4538         * modules/read-file (EXTRA_DIST): Add read-file.h.
4539         * modules/readline (EXTRA_DIST): Add readline.h.
4540         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
4541         rijndael-api-fst.h.
4542
4543 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4544
4545         * m4/rijndael.m4 (gl_ARCFOUR):
4546         * m4/arctwo.m4 (gl_ARCTWO):
4547         * m4/check-version.m4 (gl_CHECK_VERSION):
4548         * m4/crc.m4 (gl_CRC):
4549         * m4/des.m4 (gl_DES):
4550         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
4551         * m4/gc.m4 (gl_GC):
4552         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
4553         * m4/getline.m4 (gl_FUNC_GETLINE):
4554         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
4555         * m4/hmac-md5.m4 (gl_HMAC_MD5):
4556         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
4557         * m4/md2.m4 (gl_MD2):
4558         * m4/md4.m4 (gl_MD4):
4559         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
4560         * m4/read-file.m4 (gl_FUNC_READ_FILE):
4561         * m4/readline.m4 (gl_FUNC_READLINE):
4562         * m4/rijndael.m4 (gl_RIJNDAEL):
4563         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4564         to get the necessary .h files and whatnot.
4565
4566 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
4567
4568         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
4569         gnulib rather than the other way around.
4570         * config/srclistvars.sh (COREUTILS): Remove.
4571
4572 2006-08-22  Jim Meyering  <jim@meyering.net>
4573
4574         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
4575
4576         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
4577
4578 2006-08-22  Eric Blake  <ebb9@byu.net>
4579
4580         * modules/regexprops-generic: New file.
4581         * MODULES.html.sh (Support for building documentation): List it.
4582
4583 2006-08-22  Eric Blake  <ebb9@byu.net>
4584
4585         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
4586         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
4587         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
4588         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
4589
4590 2006-08-22  Bruno Haible  <bruno@clisp.org>
4591
4592         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
4593         and lib_LTLIBRARIES like the other lib_* variables.
4594
4595 2006-08-22  Bruno Haible  <bruno@clisp.org>
4596
4597         * build-aux/x-to-1.in: New file, from GNU gettext.
4598
4599 2006-08-22  Bruno Haible  <bruno@clisp.org>
4600
4601         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
4602         <utmpx.h> exists.
4603
4604 2006-08-22  Bruno Haible  <bruno@clisp.org>
4605
4606         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
4607         <utmpx.h> exists.
4608
4609 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4610
4611         BeOS portability.
4612         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
4613         exist.
4614         Problem reported by Bruno Haible.
4615
4616 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4617
4618         Avoid the need for AC_LIBSOURCES in m4 macros.
4619         * modules/acl (EXTRA_DIST): Add acl.h.
4620         * modules/argmatch (Files): Add m4/argmatch.m4.
4621         (configure.ac): Add gl_ARGMATCH.
4622         (EXTRA_DIST): Renamed from lib_SOURCES, for
4623         consistency with the other modules.  Remove argmatch.c.
4624         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
4625         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
4626         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
4627         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
4628         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
4629         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
4630         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
4631         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
4632         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
4633         * modules/closeout (EXTRA_DIST): Add closeout.h.
4634         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
4635         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
4636         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
4637         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
4638         dirname.h; remove basename.c and stripslash.c.
4639         * modules/exclude (EXTRA_DIST): Add exclude.h.
4640         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
4641         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
4642         * modules/file-type (EXTRA_DIST): Add file-type.h.
4643         * modules/filemode (EXTRA_DIST): Add filemode.h.
4644         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
4645         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4646         * modules/fpending (EXTRA_DIST): Add __fpending.h.
4647         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
4648         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
4649         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
4650         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
4651         * modules/getdate (EXTRA_DIST): Add getdate.c.
4652         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
4653         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
4654         * modules/getpass (EXTRA_DIST): Add getpass.h.
4655         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
4656         * modules/group-member (EXTRA_DIST): Add group-member.h.
4657         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
4658         * modules/hash (EXTRA_DIST): Add hash.h.
4659         * modules/human (EXTRA_DIST): Add human.h.
4660         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
4661         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
4662         * modules/lchown (EXTRA_DIST): Add lchown.h.
4663         * modules/long-options (EXTRA_DIST): Add long-options.h.
4664         * modules/lstat (EXTRA_DIST): Add lstat.h.
4665         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
4666         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
4667         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
4668         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
4669         * modules/memxor (EXTRA_DIST): Add memxor.h.
4670         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
4671         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
4672         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
4673         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
4674         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
4675         * modules/physmem (EXTRA_DIST): Add physmem.h.
4676         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
4677         * modules/posixver (EXTRA_DIST): Add posixver.h.
4678         * modules/quote (EXTRA_DIST): Add quote.h.
4679         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
4680         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
4681         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
4682         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
4683         regex_internal.h regexec.c.
4684         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
4685         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
4686         * modules/same (EXTRA_DIST): Add same.h.
4687         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
4688         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
4689         * modules/savedir (EXTRA_DIST): Add savedir.h.
4690         * modules/sha1 (EXTRA_DIST): Add sha1.h.
4691         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
4692         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
4693         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
4694         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
4695         * modules/strdup (EXTRA_DIST): Add strdup.h.
4696         * modules/strftime (EXTRA_DIST): Add strftime.h.
4697         * modules/strndup (EXTRA_DIST): Add strndup.h.
4698         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
4699         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
4700         * modules/time_r (EXTRA_DIST): Add time_r.h.
4701         * modules/timespec (EXTRA_DIST): Add timespec.h.
4702         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
4703         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
4704         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
4705         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
4706         * modules/userspec (EXTRA_DIST): Add userspec.h.
4707         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
4708         * modules/utimens (EXTRA_DIST): Add utimens.h.
4709         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
4710         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
4711         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
4712         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
4713         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
4714         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
4715         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
4716         * modules/yesno (EXTRA_DIST): Add yesno.h.
4717
4718 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
4719
4720         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
4721
4722         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
4723         * m4/dev-ino.m4, same-inode.m4: Remove.
4724
4725         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
4726         * m4/acl.m4 (AC_FUNC_ACL):
4727         * m4/backupfile.m4 (gl_BACKUPFILE):
4728         * m4/c-strtod.m4 (gl_C99_STRTOLD):
4729         * m4/canon-host.m4 (gl_CANON_HOST):
4730         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
4731         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
4732         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
4733         * m4/cloexec.m4 (gl_CLOEXEC):
4734         * m4/close-stream.m4 (gl_CLOSE_STREAM):
4735         * m4/closeout.m4 (gl_CLOSEOUT):
4736         * m4/dirfd.m4 (gl_FUNC_DIRFD):
4737         * m4/dirname.m4 (gl_DIRNAME):
4738         * m4/exclude.m4 (gl_EXCLUDE):
4739         * m4/exitfail.m4 (gl_EXITFAIL):
4740         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
4741         * m4/file-type.m4 (gl_FILE_TYPE):
4742         * m4/filemode.m4 (gl_FILEMODE):
4743         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
4744         * m4/fpending.m4 (gl_FUNC_FPENDING):
4745         * m4/fprintftime.m4 (gl_FPRINTFTIME):
4746         * m4/fts.m4 (gl_FUNC_FTS):
4747         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
4748         * m4/getdate.m4 (gl_GETDATE):
4749         * m4/gethrxtime.m4 (gl_GETHRXTIME):
4750         * m4/getpagesize.m4 (gl_GETPAGESIZE):
4751         * m4/getpass.m4 (gl_FUNC_GETPASS):
4752         * m4/gettime.m4 (gl_GETTIME):
4753         * m4/getugroups.m4 (gl_GETUGROUPS):
4754         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
4755         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
4756         * m4/hard-locale.m4 (gl_HARD_LOCALE):
4757         * m4/hash.m4 (gl_HASH):
4758         * m4/idcache.m4 (gl_IDCACHE):
4759         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
4760         * m4/lchown.m4 (gl_FUNC_LCHOWN):
4761         * m4/long-options.m4 (gl_LONG_OPTIONS):
4762         * m4/lstat.m4 (gl_FUNC_LSTAT):
4763         * m4/md5.m4 (gl_MD5):
4764         * m4/memcasecmp.m4 (gl_MEMCASECMP):
4765         * m4/memcoll.m4 (gl_MEMCOLL):
4766         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
4767         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
4768         * m4/memxor.m4 (gl_MEMXOR):
4769         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
4770         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
4771         * m4/modechange.m4 (gl_MODECHANGE):
4772         * m4/mountlist.m4 (gl_MOUNTLIST):
4773         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4774         * m4/openat.m4 (gl_FUNC_OPENAT):
4775         * m4/pathmax.m4 (gl_PATHMAX):
4776         * m4/physmem.m4 (gl_PHYSMEM):
4777         * m4/posixtm.m4 (gl_POSIXTM):
4778         * m4/posixver.m4 (gl_POSIXVER):
4779         * m4/quote.m4 (gl_QUOTE):
4780         * m4/quotearg.m4 (gl_QUOTEARG):
4781         * m4/readtokens.m4 (gl_READTOKENS):
4782         * m4/readutmp.m4 (gl_READUTMP):
4783         * m4/regex.m4 (gl_REGEX):
4784         * m4/safe-read.m4 (gl_SAFE_READ):
4785         * m4/safe-write.m4 (gl_SAFE_WRITE):
4786         * m4/same.m4 (gl_SAME):
4787         * m4/save-cwd.m4 (gl_SAVE_CWD):
4788         * m4/savedir.m4 (gl_SAVEDIR):
4789         * m4/settime.m4 (gl_SETTIME):
4790         * m4/sha1.m4 (gl_SHA1):
4791         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
4792         * m4/stat-macros.m4 (gl_STAT_MACROS):
4793         * m4/stat-time.m4 (gl_STAT_TIME):
4794         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
4795         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
4796         * m4/strdup.m4 (gl_FUNC_STRDUP):
4797         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
4798         * m4/strndup.m4 (gl_FUNC_STRNDUP):
4799         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
4800         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
4801         * m4/time_r.m4 (gl_TIME_R):
4802         * m4/timespec.m4 (gl_TIMESPEC):
4803         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
4804         * m4/unlinkdir.m4 (gl_UNLINKDIR):
4805         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
4806         * m4/userspec.m4 (gl_USERSPEC):
4807         * m4/utimecmp.m4 (gl_UTIMECMP):
4808         * m4/utimens.m4 (gl_UTIMENS):
4809         * m4/xalloc.m4 (gl_XALLOC):
4810         * m4/xgetcwd.m4 (gl_XGETCWD):
4811         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
4812         * m4/xreadlink.m4 (gl_XREADLINK):
4813         * m4/xstrtod.m4 (gl_XSTRTOD):
4814         * m4/yesno.m4 (gl_YESNO):
4815         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
4816         to get the necessary .h files and whatnot.
4817
4818 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
4819             Bruno Haible  <bruno@clisp.org>
4820
4821         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
4822         /bin/sh understanding of '!' conditional negation.
4823
4824 2006-08-21  Jim Meyering  <jim@meyering.net>
4825
4826         * modules/openat (Depends-on): Really alphabetize.
4827
4828         * modules/acl (Depends-on): Add error and quote.
4829
4830         * check-module (find_included_lib_files): Add at-func.c to the
4831         ok-to-include-more-than-once white list.
4832
4833         * modules/openat (Depends-on): Add lstat.  Alphabetize.
4834
4835 2006-08-21  Bruno Haible  <bruno@clisp.org>
4836
4837         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
4838         Emit a pkgdata_DATA variable only if some snippets add contents to it.
4839         Reported by Martin Lambers <marlam@marlam.de>.
4840
4841 2006-08-21  Bruno Haible  <bruno@clisp.org>
4842
4843         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
4844         specify an installation location, don't emit a noinst_LIBRARIES or
4845         noinst_LTLIBRARIES assignment.
4846
4847 2006-08-21  Bruno Haible  <bruno@clisp.org>
4848
4849         BeOS portability.
4850         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
4851         BeOS has mbrtowc() but no <wctype.h>.
4852
4853 2006-08-21  Bruno Haible  <bruno@clisp.org>
4854
4855         BeOS portability.
4856         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
4857         exist.
4858
4859 2006-08-21  Bruno Haible  <bruno@clisp.org>
4860
4861         BeOS portability.
4862         * lib/mbchar.h: Include <wctype.h> only if it exists.
4863
4864 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4865
4866         Remove files that are no longer needed by their respective modules.
4867         * m4/obstack.m4: Remove.
4868         * m4/strerror_r.m4: Remove.
4869         * m4/uint32_t.m4: Remove.
4870         * m4/uintptr_t.m4: Remove.
4871         * m4/ullong_max.m4: Remove.
4872         * m4/xstrtoimax.m4: Remove.
4873         * m4/xstrtoumax.m4: Remove.
4874
4875         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
4876         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
4877         dependencies now capture this.
4878
4879         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
4880         Do not use AC_LIBSOURCES, since gnulib modules now do this.
4881         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
4882         * m4/human.m4 (gl_HUMAN): Likewise.
4883         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
4884         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
4885
4886         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
4887
4888         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
4889         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
4890         stdint.
4891         * m4/human.m4 (gl_HUMAN): Likewise.
4892         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
4893         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
4894         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4895         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4896         * m4/xstrtol (gl_XSTRTOL): Likewise.
4897
4898         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
4899         AC_TYPE_LONG_LONG_INT.
4900         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
4901         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
4902         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
4903         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
4904
4905         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
4906         on stdbool.
4907
4908         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
4909         (gl_PREREQ_XSTRTOUL): Remove.
4910
4911         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
4912
4913         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
4914         mode.
4915
4916 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4917
4918         Add and change modules to make it easier for coreutils to use
4919         gnulib-tool.
4920         * modules/backupfile (Files): Remove m4/d-ino.m4.
4921         (Depends-on): Add d-ino.
4922         * modules/cycle-check (Depends-on): Add stdint.
4923         (lib_SOURCES): Add cycle-check.h.
4924         * modules/d-ino: New module.
4925         * modules/d-type: New module.
4926         * modules/error (Files): Remove m4/strerror_r.m4.
4927         * modules/filemode (Files): Add m4/st_dm_mode.m4.
4928         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
4929         m4/inttypes_h.m4, m4/uintmax_t.m4.
4930         (Depends-on): Add stdint.
4931         (lib_SOURCES): Add fsusage.h.
4932         * modules/getcwd (Files): Remove d-ino.m4.
4933         (Depends-on): Add d-ino.
4934         * modules/getndelim2 (Depends-on): Add stdint.
4935         * modules/glob (Files): Remove m4/d-type.m4.
4936         (Depends-on): Add d-type.
4937         * modules/host-os: New module.
4938         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
4939         m4/inttypes_h.m4, m4/uintmax_t.m4.
4940         * Depends-on: Add stdint.
4941         (lib_SOURCES): Add human.h.
4942         * modules/inttostr (Files): Remove m4/intmax_t.m4,
4943         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
4944         m4/uintmax_t.m4, m4/ulonglong.m4.
4945         (Depends-on): Add stdint.
4946         (EXTRA_DIST): Add inttostr.h.
4947         * modules/lchmod: New module.
4948         * modules/link-follow: New module.
4949         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
4950         (Depends-on): Add lchmod.
4951         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
4952         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
4953         (Depends-on): Add stdint.
4954         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
4955         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
4956         (Depends-on): Add stdint.
4957         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
4958         * modules/perl: New module.
4959         * modules/regex (Depends-on): Add stdint.
4960         * modules/rmdir-errno: New module.
4961         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4962         m4/intmax_t.m4.
4963         (Depends-on): Add stdint.
4964         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
4965         m4/uintmax_t.m4.
4966         (Depends-on): Add stdint.
4967         * modules/unlink-busy: New module.
4968         * modules/utimecmp (Depends-on): Add stdint.
4969         * modules/uptime: New module.
4970         * modules/winsz-ioctl: New module.
4971         * modules/winsz-termios: New module.
4972         * modules/xnanosleep (Depends-on): Add nanosleep.
4973         * modules/ullong_max: Remove.
4974         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
4975         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
4976         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
4977         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
4978         (Depends-on): Add inttypes.
4979         (lib_SOURCES): Add xstrtol.h.
4980         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
4981         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
4982         * MODULES.html.sh: Move 'assert' into the assert section.
4983         Move 'dummy' into the linking section.
4984         Remove ullong_max.
4985         Add section for compatibility checks for POSIX:2001 functions,
4986         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
4987         winsz-ioctl, and winsz-termios into it.
4988         Add lchmod.
4989         Add top-level Misc section and put host-os, perl, and uptime
4990         into it.
4991
4992 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
4993
4994         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
4995         now assume the stdint module.  Do not include inttypes.h.
4996         * lib/fsusage.h: Likewise.
4997         * lib/getndelim2.c: Likewise.
4998         * lib/human.h: Likewise.
4999         * lib/inttostr.h: Likewise.
5000         * lib/obstack.c: Likewise.
5001         * lib/regex_internal.h: Likewise.
5002         * lib/tempname.c: Likewise.
5003         * lib/utimecmp.c: Likewise.
5004         * lib/xstrtol.h: Likewise.
5005
5006         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
5007
5008         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
5009         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
5010         * lib/xtime.h: Likewise.
5011
5012 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
5013
5014         * modules/openat (Files): Add lib/fchmodat.c.
5015         Fixes problem reported by Jay Youngman.
5016
5017 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
5018
5019         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
5020         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
5021
5022 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
5023             Bruno Haible  <bruno@clisp.org>
5024
5025         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
5026         and is a script that invokes bison. Tighten the code. Add comments.
5027
5028 2006-08-18  Jim Meyering  <jim@meyering.net>
5029
5030         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
5031         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
5032         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
5033         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
5034
5035 2006-08-18  Bruno Haible  <bruno@clisp.org>
5036
5037         * modules/bison-i18n: New file.
5038         * MODULES.html.sh (Internationalization functions): Add it.
5039
5040 2006-08-18  Bruno Haible  <bruno@clisp.org>
5041
5042         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
5043         sys/statvfs.h. When getmntinfo was found, check its declaration and
5044         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
5045
5046 2006-08-18  Bruno Haible  <bruno@clisp.org>
5047
5048         * m4/bison-i18n.m4: New file, from bison.
5049
5050 2006-08-18  Bruno Haible  <bruno@clisp.org>
5051
5052         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
5053         (ME_DUMMY): Treat "kernfs" as a dummy.
5054         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
5055
5056 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
5057
5058         Update from coreutils.
5059
5060         2006-08-15  Jim Meyering  <jim@meyering.net>
5061
5062         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
5063
5064         2006-01-17  Jim Meyering  <jim@meyering.net>
5065
5066         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
5067
5068         2006-01-11  Jim Meyering  <jim@meyering.net>
5069
5070         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
5071         Check for the lchmod function.
5072
5073 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
5074
5075         Update from coreutils.
5076
5077         * lib/__fpending.h: Add copyright notice.
5078         * lib/fprintftime.h: Likewise.
5079         * lib/savedir.c: Use (C) in copyright notice.
5080         * lib/savedir.h: Likewise.
5081
5082         2006-08-15  Jim Meyering  <jim@meyering.net>
5083
5084         * lib/at-func.c: New file, with the logic of all emulated at-functions.
5085         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
5086         in support of the EXPECTED_ERRNO macro.
5087         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
5088         definitions.  Instead, define the appropriate symbols and include
5089         "at-func.c".
5090         * lib/mkdirat.c (mkdirat): Likewise.
5091         * lib/fchmodat.c (fchmodat): Likewise.
5092         (ENOSYS): Remove definition.
5093         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
5094         it.  Don't include "unistd--.h" -- it wasn't ever used.
5095
5096         2006-01-17  Jim Meyering  <jim@meyering.net>
5097
5098         Rewrite fts.c not to change the current working directory,
5099         by using openat, fstatat, fdopendir, etc..
5100
5101         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
5102         (HAVE_OPENAT_SUPPORT): Define.
5103         [_LIBC] (fchdir): Don't undef or define; no longer used.
5104         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
5105         Now, this `function' always succeeds, and consumes its file descriptor
5106         parameter -- so callers must not close such FDs.  Update callers.
5107         (diropen_fd, opendirat, cwd_advance_fd): New functions.
5108         (diropen): Add parameter, SP.  Adjust all callers.
5109         Implement using diropen_fd, rather than open.
5110         (fts_open): Initialize new member, fts_cwd_fd.
5111         Remove fts_rft-setting code.
5112         (fts_close): Close fts_cwd_fd, if necessary.
5113         (__opendir2): Define in terms of opendir or opendirat,
5114         depending on whether the FST_NOCHDIR flag is set.
5115         (fts_build): Since fts_safe_changedir consumes its FD, and since
5116         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
5117         and close the dup'd file descriptor upon failure.
5118         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
5119         (fts_safe_changedir): Tweak semantics to reflect that this function
5120         now calls cwd_advance_fd and hence consumes its FD argument.
5121         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
5122         [struct FTS] (fts_rft): Remove now-unused member.
5123         [struct FTS] (fts_cycle.state): Improve comment.
5124
5125         * lib/openat.c (openat_needs_fchdir): New function.
5126         * lib/openat.h (openat_needs_fchdir): Declare it.
5127
5128 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
5129
5130         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
5131         Problem and fix reported by Pádraig Brady in
5132         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
5133
5134 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5135
5136         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
5137
5138 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5139
5140         * lib/memcoll.c (memcoll): Optimize for the common case where the
5141         arguments are bytewise equal.
5142
5143 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
5144
5145         * doc/regexprops-generic.texi: Add a copyright notice.
5146
5147 2006-08-15  Bruno Haible  <bruno@clisp.org>
5148
5149         * modules/tmpdir (License): Change to LGPL.
5150
5151 2006-08-15  Bruno Haible  <bruno@clisp.org>
5152
5153         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
5154         module.
5155
5156 2006-08-14  Simon Josefsson  <jas@extundo.com>
5157
5158         * config/srclist.txt: Add gnupload.
5159
5160 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5161
5162         Change copyright notice from LGPL 2 to GPL 2, since that's the
5163         standard form used in the gnulib repository.
5164         * tests/test-lock.c: Likewise.
5165         * tests/test-stdint.c: Likewise.
5166         * tests/test-tls.c: Likewise.
5167
5168         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
5169         prelude-manager.  User shorter URLs for GNU projects, without '?'.
5170         Add copyright notice.
5171
5172         * check-module: Add copyright notice.  Output a copyright
5173         notice if "--version" is specified.
5174         * modules/COPYING: New file.
5175         * tests/test-getaddrinfo.c: Add copyright notice.
5176         * tests/test-verify.c: Likewise.
5177
5178 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5179
5180         Change copyright notice from LGPL 2 to GPL 2, since that's the
5181         standard form used in the gnulib repository.
5182         * lib/lock.c: LGPL -> GPL.
5183         * lib/lock.h: Likewise.
5184         * lib/strnlen1.c: Likewise.
5185         * lib/strnlen1.h: Likewise.
5186         * lib/tls.c: Likewise.
5187         * lib/tls.h: Likewise.
5188         * lib/tmpdir.c: Likewise.
5189
5190         * lib/TODO: Remove; this belongs only in coreutils.
5191
5192 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5193
5194         Add copyright notices to long-enough files that lack them, since
5195         otherwise the files aren't clearly free.  Use the same notice that
5196         getdate.texi already uses.
5197         * doc/alloca-opt.texi: Add copyright notice.
5198         * doc/alloca.texi: Likewise.
5199         * doc/ctime.texi: Likewise.
5200         * doc/functions.texi: Likewise.
5201         * doc/gcd.texi: Likewise.
5202         * doc/gnulib-tool.texi: Likewise.
5203         * doc/inet_ntoa.texi: Likewise.
5204         * doc/visibility.texi: Likewise.
5205
5206         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
5207         * doc/quote.texi: Add copyright notice.
5208
5209         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
5210         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
5211         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
5212         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
5213         is now obsolete, and give a pointer to the Sun list.
5214         Add copyright notice.
5215
5216 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
5217
5218         * config/srclistvars.sh: Add copyright notice.
5219
5220 2006-08-14  Eric Blake  <ebb9@byu.net>
5221
5222         Import the following change from libc:
5223
5224         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
5225
5226         Upstream bug 2997.
5227         * lib/misc/error.c: Add space between program name and message if file
5228         name is missing.
5229
5230 2006-08-12  Karl Berry  <karl@gnu.org>
5231
5232         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
5233         remove, these originate in gnulib now.
5234
5235 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5236
5237         * doc/Makefile (standards.info standards.html standards.dvi):
5238         Also depend on make-stds.texi.
5239
5240 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
5241
5242         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
5243         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
5244
5245         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
5246         in wchar_t.  Problem reported by Eric Blake.
5247
5248         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
5249         LEN is smaller than SIZE.  Suggested by Bruno Haible.
5250         Also, help the compiler to keep LEN in a register.
5251
5252 2006-08-11  Eric Blake  <ebb9@byu.net>
5253
5254         * users.txt: Sort.  Add tar.
5255
5256 2006-08-11  Bruno Haible  <bruno@clisp.org>
5257
5258         * users.txt: New file.
5259
5260 2006-08-11  Bruno Haible  <bruno@clisp.org>
5261
5262         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
5263         before <wchar.h>. Needed for OSF/1 and BSD/OS.
5264
5265 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5266
5267         * modules/snprintf (Depends-on): Remove minmax.
5268         (Maintainer): Add self and Bruno.
5269
5270 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
5271
5272         * lib/.cppi-disable: Add snprintf.h, socket_.h.
5273         * lib/snprintf.c: Include <errno.h> and <limits.h>.
5274         (EOVERFLOW): Define if the system does not.
5275         Do not include "minmax.h"; it wasn't used.
5276         (snprintf): Don't assume size_t promotes to an unsigned type.
5277         Fix bug when generated string was too long for the buffer: the
5278         buffer's contents are supposed to be the initial prefix of the
5279         output.  Don't assume vasnprintf returns EOVERFLOW if the size
5280         exceeds INT_MAX; do the check ourselves.
5281
5282         Import the following changes from libc:
5283
5284         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
5285
5286         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
5287         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
5288         set wc to the byte which couldn't be converted.
5289         (re_string_reconstruct): Don't clear valid_raw_len before calling
5290         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
5291         tip_context using re_string_context_at.
5292
5293         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
5294
5295         * lib/posix/regex.h: g++ still cannot handled [restrict].
5296
5297         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
5298
5299         * lib/posix/regex.h: Remove special handling for VMS.
5300
5301 2006-08-10  Jim Meyering  <jim@meyering.net>
5302
5303         * modules/same-inode: New module.
5304         * modules/dev-ino: New module.
5305         * modules/cycle-check: Depend on these modules, rather than simply
5306         including their .h files.
5307         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
5308         required via m4/cycle-check.m4.
5309         * modules/same: Depend on new same-inode module, rather than
5310         including same-inode.h.
5311         * modules/chdir-safer: New file.
5312
5313         * modules/chown (Depends-on): Add stat-macros.
5314
5315 2006-08-10  Jim Meyering  <jim@meyering.net>
5316
5317         * m4/cycle-check.m4: New file.
5318         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
5319         * m4/dev-ino.m4, m4/same-inode.m4: New files.
5320
5321 2006-08-10  Eric Blake  <ebb9@byu.net>
5322
5323         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
5324         in from original proposal.
5325
5326 2006-08-10  Eric Blake  <ebb9@byu.net>
5327         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
5328
5329         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
5330         namespace.
5331
5332 2006-08-10  Bruno Haible  <bruno@clisp.org>
5333
5334         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
5335         as well.
5336
5337 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5338
5339         Sync from coreutils.
5340
5341         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
5342
5343         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
5344         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
5345
5346 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5347
5348         * modules/restrict: Remove; no longer needed now that we assume
5349         Autoconf 2.59 or later.
5350         * MODULES.html.sh: Remove 'restrict'.
5351         * modules/argp (Depends-on): Remove 'restrict'.
5352         * modules/base64 (Depends-on): Likewise.
5353         * modules/gc (Depends-on): Likewise.
5354         * modules/getaddrinfo (Depends-on): Likewise.
5355         * modules/glob (Depends-on): Likewise.
5356         * modules/inet_ntop (Depends-on): Likewise.
5357         * modules/inet_pton (Depends-on): Likewise.
5358         * modules/memxor (Depends-on): Likewise.
5359         * modules/regex (Depends-on): Likewise.
5360         * modules/strtok_r (Depends-on): Likewise.
5361         * modules/time_r (Depends-on): Likewise.
5362
5363 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
5364
5365         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
5366         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
5367         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
5368         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
5369         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
5370         * m4/memxor.m4 (gl_MEMXOR): Likewise.
5371         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
5372         gl_C_RESTRICT replaced by AC_C_RESTRICT.
5373
5374         Merge from coreutils.
5375         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
5376         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
5377         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
5378         * m4/time_r.m4 (gl_TIME_R): Likewise.
5379
5380 2006-08-09  Karl Berry  <karl@gnu.org>
5381
5382         * config/srclist.txt: no more gettext-tools, per Bruno.
5383
5384 2006-08-08  Eric Blake  <ebb9@byu.net>
5385
5386         * modules/verror: New module.
5387         * MODULES.html.sh: Document it.
5388
5389 2006-08-08  Eric Blake  <ebb9@byu.net>
5390
5391         * lib/verror.h, lib/verror.c: New files.
5392
5393 2006-08-08  Eric Blake  <ebb9@byu.net>
5394
5395         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
5396         verror_at_line output complies with GNU Coding Standards even when
5397         file is NULL.
5398
5399 2006-08-07  Bruno Haible  <bruno@clisp.org>
5400
5401         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
5402         versions of AIX.
5403         Reported by Ralf Wildenhues.
5404
5405 2006-08-07  Bruno Haible  <bruno@clisp.org>
5406
5407         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
5408         in an AC_DEFUN. Needed so that the autoconf snippets can use
5409         AC_REQUIRE.
5410
5411 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5412
5413         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5414         Initialize pkgdata_DATA.
5415         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
5416         overriding it.
5417
5418 2006-08-06  Eric Blake  <ebb9@byu.net>
5419
5420         * lib/error.h: Fold in some upstream changes from glibc.
5421         * lib/error.c: Likewise.
5422
5423 2006-08-04  Bruno Haible  <bruno@clisp.org>
5424
5425         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5426         Make the mostlyclean-local rule depend on mostlyclean-generic.
5427         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
5428
5429 2006-07-31  Bruno Haible  <bruno@clisp.org>
5430
5431         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
5432         <stdlib.h>, <string.h>.
5433
5434 2006-07-30  Bruno Haible  <bruno@clisp.org>
5435
5436         * modules/readlink (License): Change to LGPL.
5437
5438 2006-07-30  Bruno Haible  <bruno@clisp.org>
5439
5440         * modules/javaversion (Makefile.am): Distribute javaversion.java and
5441         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
5442         set PKGDATADIR to point to it.
5443
5444 2006-07-30  Bruno Haible  <bruno@clisp.org>
5445
5446         * modules/csharpexec (configure.ac): Comment out macro invocation.
5447         * modules/javaexec (configure.ac): Likewise.
5448         * modules/javacomp-script (configure.ac): Likewise.
5449
5450         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
5451
5452 2006-07-30  Bruno Haible  <bruno@clisp.org>
5453
5454         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
5455         linked-list.
5456
5457 2006-07-30  Bruno Haible  <bruno@clisp.org>
5458
5459         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
5460
5461 2006-07-30  Bruno Haible  <bruno@clisp.org>
5462
5463         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5464         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
5465         get removed.
5466
5467 2006-07-29  Bruno Haible  <bruno@clisp.org>
5468
5469         Make it possible for gnulib-tool to work with locally modified or
5470         augmented gnulib repositories.
5471         * gnulib-tool (func_usage): Document --local-dir option.
5472         (local_gnulib_dir): New variable.
5473         Handle --local-dir option.
5474         (func_lookup_file): New function.
5475         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
5476         (func_get_description, func_get_filelist, func_get_description,
5477         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
5478         func_get_automake_snippet, func_get_include_directive,
5479         func_get_license, func_get_maintainer): Use func_lookup_file.
5480         (func_import, func_create_testdir): Use func_lookup_file.
5481
5482 2006-07-29  Bruno Haible  <bruno@clisp.org>
5483
5484         * modules/setenv (Depends-on): Add unistd.
5485
5486 2006-07-29  Bruno Haible  <bruno@clisp.org>
5487
5488         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
5489
5490 2006-07-29  Bruno Haible  <bruno@clisp.org>
5491
5492         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
5493
5494 2006-07-29  Bruno Haible  <bruno@clisp.org>
5495
5496         * gnulib-tool (import, update): If there is no Makefile.am, look at
5497         aclocal.m4, instead of bailing out.
5498
5499 2006-07-29  Bruno Haible  <bruno@clisp.org>
5500
5501         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
5502         Categorize the options by when they are useful.
5503
5504 2006-07-29  Bruno Haible  <bruno@clisp.org>
5505
5506         * gnulib-tool (func_usage): Document option --no-libtool.
5507         Handle option --no-libtool.
5508         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
5509         for changed semantics of $libtool variable.
5510         (func_import): Likewise. If libtool is not used, show this through
5511         an option --no-libtool.
5512         (func_create_testdir): Update.
5513
5514 2006-07-29  Bruno Haible  <bruno@clisp.org>
5515
5516         * gnulib-tool (func_import): Extend error message about missing
5517         --doc-base.
5518
5519 2006-07-29  Bruno Haible  <bruno@clisp.org>
5520
5521         * gnulib-tool (func_import): Don't create the $docbase directory if
5522         there is no file to store there.
5523
5524 2006-07-29  Bruno Haible  <bruno@clisp.org>
5525
5526         * gnulib-tool (autoconf_minversion): If a --dir option is given and
5527         relevant, look for configure.ac there, not in the current directory.
5528         Also use a simple search for AC_PREREQ, not "autoconf --trace".
5529
5530 2006-07-29  Bruno Haible  <bruno@clisp.org>
5531
5532         * gnulib-tool (SORT): New variable.
5533         (func_usage): Undocument --assume-autoconf option.
5534         Remove --assume-autoconf option handling.
5535         (autoconf_minversion): Determine from the contents of configure.ac.
5536         (func_import): Remove autoconf_minversion handling.
5537         Suggested by Eric Blake.
5538
5539 2006-07-29  Bruno Haible  <bruno@clisp.org>
5540
5541         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
5542
5543 2006-07-29  Bruno Haible  <bruno@clisp.org>
5544
5545         * config/srclist.txt (*setenv.[ch]): Remove rules.
5546
5547 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5548
5549         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
5550
5551 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5552
5553         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
5554         arpa/inet.h.
5555
5556 2006-07-28  Simon Josefsson  <jas@extundo.com>
5557
5558         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
5559         * modules/inet_pton (Depends-on): Likewise.
5560
5561 2006-07-28  Simon Josefsson  <jas@extundo.com>
5562
5563         * m4/netinet_in_h.m4: New file.
5564
5565 2006-07-28  Simon Josefsson  <jas@extundo.com>
5566
5567         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
5568         #include's.
5569
5570 2006-07-28  Simon Josefsson  <jas@extundo.com>
5571
5572         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
5573         #include's.
5574
5575 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
5576
5577         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
5578         setgid on directories only if they set these bits.
5579         * lib/modechange.h: Remove obsolete comment about masks.
5580
5581 2006-07-28  Eric Blake  <ebb9@byu.net>
5582
5583         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
5584         macro expansion.
5585
5586 2006-07-28  Bruno Haible  <bruno@clisp.org>
5587
5588         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
5589
5590 2006-07-28  Bruno Haible  <bruno@clisp.org>
5591
5592         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
5593
5594 2006-07-28  Bruno Haible  <bruno@clisp.org>
5595
5596         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
5597         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
5598         Define fallbacks.
5599         Avoids link error on FreeBSD 4.x.
5600         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
5601
5602         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
5603         encoding.
5604         * lib/mbswidth.c (iswcntrl): Likewise.
5605
5606 2006-07-27  Bruno Haible  <bruno@clisp.org>
5607
5608         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
5609         test.
5610
5611 2006-07-27  Bruno Haible  <bruno@clisp.org>
5612
5613         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
5614         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
5615         defined.
5616
5617 2006-07-26  Eric Blake  <ebb9@byu.net>
5618
5619         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
5620
5621 2006-07-26  Eric Blake  <ebb9@byu.net>
5622
5623         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
5624         like mingw that lack mkstemp.
5625         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
5626         avoid compilation warning on mingw.
5627
5628 2006-07-26  Bruno Haible  <bruno@clisp.org>
5629
5630         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
5631         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
5632         INT_FAST*_MIN, INTPTR_MIN.
5633
5634 2006-07-25  Bruno Haible  <bruno@clisp.org>
5635
5636         * modules/version-etc (Depends-on): Add stdarg.
5637
5638 2006-07-25  Bruno Haible  <bruno@clisp.org>
5639
5640         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
5641         complex commands.
5642
5643 2006-07-25  Bruno Haible  <bruno@clisp.org>
5644
5645         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
5646         defined in <stdarg.h> or config.h.
5647
5648 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5649
5650         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
5651         (gl_STDIO_SAFER): Remove.
5652
5653 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
5654
5655         * MODULES.html.sh (File stream based Input/Output):
5656         Add fopen-safer, tmpfile-safer; remove stdio-safer.
5657         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
5658         * modules/fopen-safer, modules/tmpfile-safer: New files.
5659         * modules/stdio-safer: Remove.
5660
5661 2006-07-24  Bruno Haible  <bruno@clisp.org>
5662
5663         * modules/tmpdir: New file.
5664         * MODULES.html.sh (File system functions): Add it.
5665
5666 2006-07-24  Bruno Haible  <bruno@clisp.org>
5667
5668         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
5669         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
5670
5671 2006-07-24  Bruno Haible  <bruno@clisp.org>
5672
5673         * modules/clean-temp: New file.
5674
5675 2006-07-24  Bruno Haible  <bruno@clisp.org>
5676
5677         * m4/tmpdir.m4: New file, from GNU gettext.
5678
5679 2006-07-24  Bruno Haible  <bruno@clisp.org>
5680
5681         * lib/tmpdir.h: New file, from GNU gettext.
5682         * lib/tmpdir.c: New file, from GNU gettext.
5683
5684 2006-07-24  Bruno Haible  <bruno@clisp.org>
5685
5686         * lib/clean-temp.h: New file, from GNU gettext.
5687         * lib/clean-temp.c: New file, from GNU gettext.
5688
5689 2006-07-23  Eric Blake  <ebb9@byu.net>
5690
5691         * modules/stdio-safer (Files): Add tmpfile-safer.c.
5692         (Depends-on): Add binary-io.
5693
5694 2006-07-23  Eric Blake  <ebb9@byu.net>
5695
5696         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
5697
5698 2006-07-23  Eric Blake  <ebb9@byu.net>
5699
5700         * lib/tmpfile-safer.c: New file.
5701         * lib/stdio-safer.h (fopen_safer): Add prototype.
5702         * lib/stdio--.h (tmpfile): Make safer.
5703
5704 2006-07-23  Bruno Haible  <bruno@clisp.org>
5705
5706         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
5707         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
5708         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
5709         gl_linked_remove_at): Use it.
5710
5711 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5712         and Simon Josefsson <jas@extundo.com>
5713
5714         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
5715
5716         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
5717
5718 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5719
5720         * modules/close-stream: New file.
5721         * modules/closeout (Description): Make it clear that it exits
5722         with a diagnostic on error.
5723         (Depends-on): Add close-stream.  Remove fpending, stdbool.
5724         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
5725
5726 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5727
5728         * m4/close-stream.m4: New file.
5729
5730 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
5731
5732         * lib/close-stream.c, lib/close-stream.h: New files.
5733
5734 2006-07-22  Bruno Haible  <bruno@clisp.org>
5735
5736         Merge from GNU gettext 0.15.
5737
5738         2006-05-01  Bruno Haible  <bruno@clisp.org>
5739
5740                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
5741
5742         2006-07-22  Bruno Haible  <bruno@clisp.org>
5743
5744                 * modules/javaversion: New file.
5745                 * MODULES.html.sh (Java): Add javaversion.
5746
5747         2006-03-12  Bruno Haible  <bruno@clisp.org>
5748
5749                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
5750
5751         2005-12-04  Bruno Haible  <bruno@clisp.org>
5752
5753                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
5754                 (untested).
5755
5756         2006-06-21  Bruno Haible  <bruno@clisp.org>
5757
5758                 Avoid warnings from recent versions of mcs.
5759                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
5760                 -o, -L, -r any more. Use options documented since mcs-1.0
5761                 instead. Similarly for -g.
5762
5763         2005-12-04  Bruno Haible  <bruno@clisp.org>
5764
5765                 * build-aux/csharpcomp.sh.in: Suffix for resources is
5766                 .resources, not .resource.
5767
5768         2005-07-09  Bruno Haible  <bruno@clisp.org>
5769
5770                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
5771                 add a .dll suffix.
5772                 Reported by Mark Junker <mjscod@gmx.de>.
5773
5774         2006-07-22  Bruno Haible  <bruno@clisp.org>
5775
5776                 * modules/gettext: Upgrade to gettext-0.15.
5777                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
5778                 m4/visibility.m4.
5779                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
5780
5781 2006-07-22  Bruno Haible  <bruno@clisp.org>
5782
5783         Merge from GNU gettext 0.15.
5784
5785         2006-03-25  Bruno Haible  <bruno@clisp.org>
5786
5787                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
5788
5789         2006-07-21  Bruno Haible  <bruno@clisp.org>
5790
5791                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
5792                 "1.1".
5793
5794         2006-05-09  Bruno Haible  <bruno@clisp.org>
5795
5796                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
5797                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
5798                 for the conftestver execution.
5799
5800         2006-05-01  Bruno Haible  <bruno@clisp.org>
5801
5802                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
5803                 optional target-version argument. Verify that the compiler
5804                 groks source of the specified source-version, or add -source
5805                 option as necessary. Verify that the compiler produces
5806                 bytecode in the specified target-version, or add -target and
5807                 -source options as necessary. Make the result of the test
5808                 available as variable CONF_JAVAC. Also log error output in
5809                 config.log.
5810
5811         2006-03-11  Bruno Haible  <bruno@clisp.org>
5812
5813                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
5814
5815         2006-05-09  Bruno Haible  <bruno@clisp.org>
5816
5817                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
5818                 CLASSPATH_SEPARATOR to a semicolon.
5819
5820         2006-03-12  Bruno Haible  <bruno@clisp.org>
5821
5822                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
5823                 available as variable CONF_JAVA, for subsequent autoconf
5824                 tests. Also log error output in config.log.
5825
5826         2006-07-19  Bruno Haible  <bruno@clisp.org>
5827
5828                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
5829                 that getline works on glibc2 systems. Needed to avoid trouble
5830                 in relocatable.c.
5831                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
5832
5833         2005-12-04  Bruno Haible  <bruno@clisp.org>
5834
5835                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
5836                 launcher (untested).
5837
5838         2005-12-04  Bruno Haible  <bruno@clisp.org>
5839
5840                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
5841
5842         2006-07-22  Bruno Haible  <bruno@clisp.org>
5843
5844                 * gettext.m4: Update from GNU gettext-0.15.
5845                 * nls.m4: Likewise.
5846                 * po.m4: Likewise.
5847                 * inttypes-pri.m4: Likewise.
5848                 * inttypes-h.m4: Renamed from inttypes.m4.
5849                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
5850
5851 2006-07-22  Bruno Haible  <bruno@clisp.org>
5852
5853         Merge from GNU gettext 0.15.
5854
5855         2005-07-05  Bruno Haible  <bruno@clisp.org>
5856
5857                 * printf-args.c (printf_fetchargs): Work around broken
5858                 definition of wint_t on mingw.
5859
5860         2005-02-12  Bruno Haible  <bruno@clisp.org>
5861
5862                 * xallocsa.h: Add extern "C" for C++.
5863
5864         2006-05-17  Bruno Haible  <bruno@clisp.org>
5865
5866                 Cygwin portability.
5867                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
5868
5869         2006-04-30  Bruno Haible  <bruno@clisp.org>
5870
5871                 * progreloc.c: Include <mach-o/dyld.h> if available.
5872                 (find_executable): Use _NSGetExecutablePath when possible.
5873
5874         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5875
5876                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
5877                 function.
5878
5879         2005-12-29  Bruno Haible  <bruno@clisp.org>
5880
5881                 * progreloc.c (set_program_name_and_installdir): Fix
5882                 compilation error.
5883
5884         2005-12-04  Bruno Haible  <bruno@clisp.org>
5885
5886                 Cygwin portability.
5887                 * progreloc.c: Include <windows.h> also on Cygwin.
5888                 (find_executable): Add support for Cygwin.
5889                 (set_program_name_and_installdir): Handle also platforms with
5890                 nonempty EXEEXT.
5891
5892         2006-07-11  Bruno Haible  <bruno@clisp.org>
5893
5894                 * javacomp.c: Fix a comment.
5895                 Reported by Jim Meyering.
5896
5897         2006-04-30  Bruno Haible  <bruno@clisp.org>
5898
5899                 * javacomp.h (compile_java_class): Add source_version,
5900                 target_version arguments.
5901                 * javacomp.c: Rewritten to choose only a compiler that
5902                 respects the specified source_version and target_version.
5903
5904         2006-06-27  Bruno Haible  <bruno@clisp.org>
5905
5906                 Assume correct S_ISDIR macro.
5907                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
5908
5909         2006-07-22  Bruno Haible  <bruno@clisp.org>
5910
5911                 * javaversion.h: New file, from GNU gettext.
5912                 * javaversion.c: New file, from GNU gettext.
5913                 * javaversion.java: New file, from GNU gettext.
5914                 * javaversion.class: New file, from GNU gettext.
5915
5916         2006-05-17  Bruno Haible  <bruno@clisp.org>
5917
5918                 Cygwin portability.
5919                 * javaexec.c (execute_java_class): Test for jview program
5920                 also on Cygwin.
5921
5922         2006-04-09  Bruno Haible  <bruno@clisp.org>
5923
5924                 * fatal-signal.c: Don't include string.h.
5925                 (at_fatal_signal): Use a copying loop instead of memcpy.
5926
5927         2005-12-04  Bruno Haible  <bruno@clisp.org>
5928
5929                 * csharpexec.c: Add support for 'clix' launcher (untested).
5930                 (execute_csharp_using_sscli): New function.
5931                 (execute_csharp_program): Call it.
5932
5933         2006-06-21  Bruno Haible  <bruno@clisp.org>
5934
5935                 Avoid warnings from recent versions of mcs.
5936                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
5937                 -o, -L, -r any more. Use options documented since mcs-1.0
5938                 instead. Similarly for -g.
5939
5940         2005-07-09  Bruno Haible  <bruno@clisp.org>
5941
5942                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
5943                 add a .dll suffix.
5944                 Reported by Mark Junker <mjscod@gmx.de>.
5945
5946         2006-06-17  Bruno Haible  <bruno@clisp.org>
5947
5948                 * config.charset: Update for NetBSD 3.0.
5949
5950         2006-05-17  Bruno Haible  <bruno@clisp.org>
5951
5952                 Cygwin portability.
5953                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
5954
5955         2006-05-16  Bruno Haible  <bruno@clisp.org>
5956
5957                 * localcharset.c [CYGWIN]: Include <windows.h>.
5958                 (get_charset_aliases): For Cygwin, return the same CPxxx
5959                 aliases list as under WIN32.
5960                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
5961                 the environment variables. Fall back to GetACP().
5962
5963         2006-04-05  Bruno Haible  <bruno@clisp.org>
5964
5965                 * config.charset: Update Juan Manuel Guerrero's address.
5966
5967         2005-02-12  Bruno Haible  <bruno@clisp.org>
5968
5969                 * allocsa.h: Add extern "C" for C++.
5970
5971         2005-02-10  Bruno Haible  <bruno@clisp.org>
5972
5973                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
5974                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
5975
5976         2006-07-22  Bruno Haible  <bruno@clisp.org>
5977
5978                 * gettext.h: Update to GNU gettext-0.15.
5979
5980 2006-07-22  Bruno Haible  <bruno@clisp.org>
5981
5982         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
5983         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
5984         lib-prefix.m4, longdouble.m4, ssize_t.m4.
5985
5986 2006-07-21  Eric Blake  <ebb9@byu.net>
5987
5988         * modules/stdlib-safer: New file.
5989         * MODULES.html.sh (File stream based Input/Output): Add
5990         stdlib-safer.
5991
5992 2006-07-21  Eric Blake  <ebb9@byu.net>
5993
5994         * lib/stdlib-safer.h: New file from coreutils, required by
5995         stdlib--.h.
5996
5997 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
5998
5999         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
6000
6001 2006-07-20  Bruno Haible  <bruno@clisp.org>
6002
6003         * gnulib-tool: Recognize new option --assume-autoconf.
6004         (autoconf_minversion): New variable.
6005         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
6006
6007 2006-07-20  Bruno Haible  <bruno@clisp.org>
6008
6009         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
6010
6011 2006-07-19  Derek R. Price  <derek@ximbiot.com>
6012
6013         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
6014         Reindent and repaginate.
6015
6016 2006-07-19  Derek Price  <derek@ximbiot.com>
6017
6018         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
6019         Correct grammar.
6020
6021 2006-07-17  Bruno Haible  <bruno@clisp.org>
6022
6023         * modules/list: New file.
6024         * modules/array-list: New file.
6025         * modules/carray-list, modules/carray-list-tests: New files.
6026         * modules/linked-list, modules/linked-list-tests: New files.
6027         * modules/avltree-list, modules/avltree-list-tests: New files.
6028         * modules/rbtree-list, modules/rbtree-list-tests: New files.
6029         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
6030         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
6031         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
6032         * modules/oset: New file.
6033         * modules/array-oset: New file.
6034         * modules/avltree-oset, modules/avltree-oset-tests: New files.
6035         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
6036         * tests/test-carray_list.c: New file.
6037         * tests/test-linked_list.c: New file.
6038         * tests/test-avltree_list.c: New file.
6039         * tests/test-rbtree_list.c: New file.
6040         * tests/test-linkedhash_list.c: New file.
6041         * tests/test-avltreehash_list.c: New file.
6042         * tests/test-rbtreehash_list.c: New file.
6043         * tests/test-avltree_oset.c: New file.
6044         * tests/test-rbtree_oset.c: New file.
6045         * MODULES.html.sh (Container data structures): New section.
6046
6047 2006-07-17  Bruno Haible  <bruno@clisp.org>
6048
6049         * m4/gl_list.m4: New file.
6050
6051 2006-07-17  Bruno Haible  <bruno@clisp.org>
6052
6053         * lib/gl_list.h: New file.
6054         * lib/gl_list.c: New file.
6055         * lib/gl_array_list.h: New file.
6056         * lib/gl_array_list.c: New file.
6057         * lib/gl_carray_list.h: New file.
6058         * lib/gl_carray_list.c: New file.
6059         * lib/gl_linked_list.h: New file.
6060         * lib/gl_linked_list.c: New file.
6061         * lib/gl_anylinked_list1.h: New file.
6062         * lib/gl_anylinked_list2.h: New file.
6063         * lib/gl_avltree_list.h: New file.
6064         * lib/gl_avltree_list.c: New file.
6065         * lib/gl_anyavltree_list1.h: New file.
6066         * lib/gl_anyavltree_list2.h: New file.
6067         * lib/gl_rbtree_list.h: New file.
6068         * lib/gl_rbtree_list.c: New file.
6069         * lib/gl_anyrbtree_list1.h: New file.
6070         * lib/gl_anyrbtree_list2.h: New file.
6071         * lib/gl_anytree_list1.h: New file.
6072         * lib/gl_anytree_list2.h: New file.
6073         * lib/gl_linkedhash_list.h: New file.
6074         * lib/gl_linkedhash_list.c: New file.
6075         * lib/gl_anyhash_list1.h: New file.
6076         * lib/gl_anyhash_list2.h: New file.
6077         * lib/gl_avltreehash_list.h: New file.
6078         * lib/gl_avltreehash_list.c: New file.
6079         * lib/gl_rbtreehash_list.h: New file.
6080         * lib/gl_rbtreehash_list.c: New file.
6081         * lib/gl_anytreehash_list1.h: New file.
6082         * lib/gl_anytreehash_list2.h: New file.
6083
6084         * lib/gl_oset.h: New file.
6085         * lib/gl_oset.c: New file.
6086         * lib/gl_array_oset.h: New file.
6087         * lib/gl_array_oset.c: New file.
6088         * lib/gl_avltree_oset.h: New file.
6089         * lib/gl_avltree_oset.c: New file.
6090         * lib/gl_rbtree_oset.h: New file.
6091         * lib/gl_rbtree_oset.c: New file.
6092         * lib/gl_anytree_oset.h: New file.
6093
6094 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6095
6096         * m4/mkancesdirs.m4: New file.
6097         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
6098         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
6099         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
6100         it.
6101
6102 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6103
6104         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
6105         * lib/mkancesdirs.h: New files.
6106         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
6107         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
6108         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
6109         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
6110         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
6111         callers changed.  Revamp internals significantly, by not
6112         attempting to create directories that are temporarily more
6113         permissive than the final results.  Do not attempt to use
6114         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
6115         This removes some race conditions, fixes some bugs, and simplifies
6116         things.  Use new dirchownmod function to do owner and mode changes.
6117         * lib/mkdir-p.h: Likewise.
6118         * lib/modechange.c (octal_to_mode): New function.
6119         (struct mode_change): New member mentioned.
6120         (make_node_op_equals): New arg mentioned.  All callers changed.
6121         (mode_compile): Keep track of which mode bits the user has explicitly
6122         mentioned.
6123         (mode_adjust): New arg DIR, so that we implement the X op correctly.
6124         New arg PMODE_BITS, to keep track of which mode bits the user
6125         mentioned; it treats S_ISUID and S_ISGID speciall.
6126         All callers changed.
6127         * lib/modechange.h: Likewise.
6128
6129 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
6130
6131         * MODULES.html.sh: Add mkancestors.
6132         * modules/mkancesdirs: New module.
6133         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
6134         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
6135         The chdir-safer and afs files are now orphans; I'll remove them
6136         unless someone speaks up.
6137         Add lib/dirchownmod.c, lib/dirchownmod.h.
6138         (Depends-on): Remove alloca, chown, save-cwd, dirname.
6139         Add lchown, mkancesdirs.
6140         (Maintainer): Add self.
6141
6142 2006-07-15  Karl Berry  <karl@gnu.org>
6143
6144         * gnulib-tool: help message wording/arrangement.
6145
6146 2006-07-14  Simon Josefsson  <jas@extundo.com>
6147
6148         * doc/gnulib.texi (Libtool and Windows): New section.
6149
6150 2006-07-12  Simon Josefsson  <jas@extundo.com>
6151
6152         * modules/gendocs (License): Fix license, approved by Karl.
6153
6154 2006-07-12  Eric Blake  <ebb9@byu.net>
6155
6156         * MODULES.html.sh: Add gendocs.
6157
6158 2006-07-11  Eric Blake  <ebb9@byu.net>
6159
6160         * modules/fdl: New module, to install doc/fdl.texi.
6161         * MODULES.html.sh: Add new section for documentation modules.
6162         * gnulib-tool: Avoid space-tab.
6163         (--doc-base): New option, to manage files from doc.
6164
6165 2006-07-11  Eric Blake  <ebb9@byu.net>
6166
6167         * m4/absolute-header.m4: Fix comments to match recent change.
6168
6169 2006-07-11  Eric Blake  <ebb9@byu.net>
6170
6171         * gnulib-tool: List --doc-base before --tests-base.
6172
6173 2006-07-11  Derek R. Price  <derek@ximbiot.com>
6174
6175         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
6176
6177 2006-07-11  Bruno Haible  <bruno@clisp.org>
6178
6179         * README: Mention where to put documentation.
6180
6181 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6182
6183         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
6184
6185 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
6186
6187         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
6188         to stdint.m4.
6189
6190 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
6191
6192         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
6193         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
6194         "no/such/file/stdint.h" when there is no such file, so that
6195         the resulting C code can be parsed by dodgy compilers.
6196         Problems reported by Bob Proulx.
6197
6198 2006-07-10  Derek R. Price  <derek@ximbiot.com>
6199
6200         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
6201         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
6202         macros into the GNU _D_EXACT_NAMLEN.
6203         * lib/savedir.c:  Likewise.
6204         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
6205
6206 2006-07-10  Derek R. Price  <derek@ximbiot.com>
6207         and Paul Eggert  <eggert@cs.ucla.edu>
6208
6209         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
6210         * m4/savedir.m4:
6211         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
6212         macros into the GNU _D_EXACT_NAMLEN.
6213
6214 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6215
6216         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
6217         around the absolute name, to work around a problem with the HP-UX
6218         11.23 native C compiler, reported by Bob Proulx.
6219
6220 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6221
6222         * doc/maintain.texi, make-stds.texi: Sync from
6223         <http://savannah.gnu.org/projects/gnustandards>.
6224
6225 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
6226
6227         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
6228
6229 2006-07-09  Jim Meyering  <jim@meyering.net>
6230
6231         * m4/glob.m4: Remove a doubled word in a comment.
6232
6233 2006-07-09  Jim Meyering  <jim@meyering.net>
6234
6235         * lib/argp-pv.c: Remove a doubled word in a comment.
6236         * lib/check-version.c (check_version): Likewise.
6237         * lib/javacomp.c (compile_java_class): Likewise.
6238
6239 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
6240
6241         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
6242         for the benefit of people using Autoconf 2.60.  If you want to
6243         support older Autoconf versions you can copy m4/onceonly_2_57.m4
6244         (or m4/onceonly.m4, if pre-2.57) manually.
6245
6246 2006-07-08  Jim Meyering  <jim@meyering.net>
6247
6248         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
6249         comment.
6250         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
6251         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
6252         comment.
6253
6254 2006-07-08  Jim Meyering  <jim@meyering.net>
6255
6256         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
6257
6258 2006-07-07  Simon Josefsson  <jas@extundo.com>
6259
6260         * tests/test-crc.c: Change expected crc value, the test vector
6261         were probably computed using the old broken crc.c?
6262
6263 2006-07-06  Simon Josefsson  <jas@extundo.com>
6264
6265         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
6266         now the canonical place for the M4 file).
6267
6268         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
6269         from the sys_socket dependency now.
6270
6271         * modules/inet_pton (Files): Ditto.
6272
6273         * modules/inet_ntop (Files): Ditto.
6274
6275 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
6276
6277         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
6278         not gl_PREREQ_GETUSERSHELL.
6279
6280 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6281
6282         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
6283         with only one argument, for Autoconf 2.60.
6284         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
6285         expand to nothing, so add a shell command to avoid syntax error.
6286         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
6287
6288 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6289
6290         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
6291
6292 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6293
6294         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
6295         no longer needed.  Check for isblank decl.
6296         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
6297         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
6298         of existence.
6299
6300 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6301
6302         * lib/getloadavg.c: Use __VMS, not VMS.
6303         * lib/getopt.c: Likewise.
6304         * lib/getpagesize.h: Likewise.
6305         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
6306         and probably does not work.
6307
6308 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
6309
6310         * lib/.cppi-disable: Add wcwidth.
6311         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
6312         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
6313         (ISGRAPH): Remove.  All uses changed to isgraph.
6314         (FOLD) [!defined _LIBC]: Remove special case.
6315         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
6316         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
6317         HAVE_ISBLANK.
6318         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
6319         case.
6320
6321 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6322
6323         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
6324         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
6325         brackets.  Other minor changes to suppress some compiler
6326         warnings.
6327
6328 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6329         and Paul Eggert  <eggert@cs.ucla.edu>
6330
6331         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
6332         of invoking obsolescent AC_HEADER_DIRENT macro.
6333         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
6334         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
6335         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
6336         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
6337         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
6338         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
6339         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
6340         * m4/readdir.m4: Remove; no longer needed.
6341
6342 2006-07-06  Derek R. Price  <derek@ximbiot.com>
6343         and Paul Eggert  <eggert@cs.ucla.edu>
6344
6345         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
6346         Don't worry about this obsolete case any more.
6347         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
6348         directories.
6349         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
6350         worry about this obsolete case any more.
6351         * lib/fts.c: Likewise.
6352         * lib/getcwd.c: Likewise.
6353         * lib/glob.h: Likewise.
6354         * lib/savedir.c: Likewise.
6355
6356 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6357
6358         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
6359         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
6360         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
6361         needed.
6362         All uses removed.
6363         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6364         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6365         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
6366         needed.
6367         * m4/getdate.m4 (gl_GETDATE): Likewise.
6368         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6369         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6370         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6371         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6372         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
6373         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6374         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
6375         needed.
6376
6377 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
6378
6379         * lib/memcasecmp.c: Include <limits.h>.
6380         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
6381         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
6382         Don't assume isdigit succeeds only on '0' through '9'.
6383
6384 2006-07-05  Eric Blake  <ebb9@byu.net>
6385
6386         * modules/getaddrinfo (Depends-on): Add snprintf.
6387
6388 2006-07-05  Eric Blake  <ebb9@byu.net>
6389
6390         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
6391         to avoid 'header present but could not be compiled' on cygwin.
6392
6393 2006-07-05  Eric Blake  <ebb9@byu.net>
6394
6395         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
6396         missing from netdb.h.
6397         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
6398
6399 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6400
6401         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
6402         no longer needed.
6403         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
6404         * m4/getdate.m4 (gl_GETDATE): Likewise.
6405         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
6406         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
6407         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
6408         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
6409         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
6410
6411 2006-07-05  Derek R. Price  <derek@ximbiot.com>
6412
6413         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
6414         All uses of is_space replaced by isspace.
6415         * lib/exit.h: Don't talk about STDC_HEADERS.
6416         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
6417         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
6418         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
6419         replaced by isprint etc.
6420         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
6421         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6422         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
6423         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
6424         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
6425         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
6426
6427 2006-07-05  Bruno Haible  <bruno@clisp.org>
6428
6429         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
6430         the function exists, before testing against AIX.
6431         Reported by Martin Lambers <marlam@marlam.de>.
6432
6433 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6434
6435         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
6436         From Mark D. Baushke.
6437
6438 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
6439
6440         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
6441         to the absolute name, not just one, to bypass Sun C 5.8's
6442         "warning: #include of /usr/include/... may be non-portable".
6443
6444 2006-07-04  Eric Blake  <ebb9@byu.net>
6445
6446         * modules/dirname-tests: New test module.
6447         * tests/test-dirname.c: New file, replacing dirname.c
6448         TEST_DIRNAME section that was recently deleted.
6449
6450 2006-07-04  Bruno Haible  <bruno@clisp.org>
6451
6452         Assume ANSI C header files and <ctype.h> functions.
6453         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
6454         (mbsnwidth): Use isprint, iscntrl instead.
6455
6456 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6457
6458         Merge from coreutils.
6459         * MODULES.html.sh: Add xstrtold.
6460         * modules/xstrtold: New file.
6461         * modules/cycle-check (Files): Add lib/same-inode.h.
6462         * modules/dirname (Files): Add m4/double-slash-root.m4.
6463         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
6464         * modules/mkdir-p (Files): Add lib/same-inode.h.
6465         * modules/same (Files): Add lib/same-inode.h.
6466
6467 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6468
6469         * m4/absolute-header.m4: Renamed from full-header-path.m4.
6470         This is to keep the terminology clean; POSIX talks about
6471         "absolute pathnames", not "full pathnames", but the GNU
6472         Coding Standards say to use "path" for something else;
6473         so use "absolute" to keep both sides happy.
6474         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
6475         Set gl_absolute_header, not gl_full_header_path.
6476         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
6477         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
6478         All uses changed.
6479
6480         Merge from coreutils.
6481
6482         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6483
6484         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
6485         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
6486         want to require the building of c-strtod.o.
6487         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
6488         needs -lm directly.
6489         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
6490
6491         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
6492
6493         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
6494         --as-needed option if available.  Problem reported by Albert Chin in
6495         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
6496         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
6497         cc merely issues a bunch of annoying warnings for --as-needed
6498         (this problem was reported by Bob Proulx).  Also, try linking with
6499         -lm to detect a bug in binutils 2.16 (this problem was reported
6500         by Ralf Wildenhues).
6501
6502         2006-06-18  Jim Meyering  <jim@meyering.net>
6503
6504         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
6505         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
6506         macro.
6507         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
6508         also check for glibc-2.4's abort-inducing bug.
6509
6510         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
6511         Low-probability clean-up should be to use rmdir to get rid of
6512         the just-created directory, not unlink.
6513
6514         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
6515         configure fail, and request a bug report to inform us about it.
6516         Add a comment that, barring reports to the contrary, in 2007 we'll
6517         assume ftruncate is universally available.
6518
6519         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6520
6521         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
6522
6523         2006-03-12  Jim Meyering  <jim@meyering.net>
6524
6525         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
6526         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
6527         * m4/same.m4 (gl_SAME): Likewise.
6528         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
6529
6530         2006-03-11  Eric Blake  <ebb9@byu.net>
6531
6532         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
6533         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
6534         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
6535         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
6536
6537 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
6538
6539         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
6540         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
6541         reported by Mark D. Baushke, one in
6542         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
6543
6544         Merge from coreutils.
6545
6546         * lib/.cppi-disable: Add stdint_.h.
6547         * lib/.cvsignore: Add stdint.h.
6548
6549         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
6550
6551         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
6552         both double and long double versions.
6553         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
6554         * lib/xstrtold.c: New file.
6555         * lib/xstrtod.h (xstrtold): New decl.
6556
6557         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
6558
6559         * lib/filemode.c (setst): Remove.
6560         (strmode): Rewrite to avoid setst.  This makes the code shorter,
6561         (arguably) clearer, and the generated code is a bit smaller on my
6562         Debian GNU/Linux stable x86 host.
6563
6564         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
6565
6566         * lib/filemode.c: Include "filemode.h" first, to test the interface.
6567         Assume that filemode.h includes sys/types.h and sys/stat.h.
6568         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
6569         (ftypelet): Reorder to put common cases first, for efficiency.
6570         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
6571         to do 'M'.
6572         (strmode): Renamed from mode_string, and now stores 12 bytes instead
6573         of 10, for compatibility with FreeBSD.  All callers changed.
6574         (filemodestring): Now stores 12 bytes instead of 10, and sets file
6575         types that can't be deduced solely from st_mode.  First arg is now a
6576         const pointer.
6577         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
6578         (strmode): Renamed from mode_string.
6579         (filemodestring): New decl.
6580         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
6581         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
6582         needed.
6583         (S_ISPORT, S_ISWHT): New macros, if not already defined.
6584
6585         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
6586
6587         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
6588         fsusage.h now does that.  Include fsusage.h first, to test interface.
6589         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
6590         at most one method (the old code could have generated decls that
6591         didn't conform to C89, not that this was ever exercised).
6592         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
6593
6594         2006-03-19  Jim Meyering  <jim@meyering.net>
6595
6596         Work even in a chroot where d_ino values for entries in "/"
6597         don't match the stat.st_ino values for the same names.
6598         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
6599         number, iterate through all entries again, using lstat instead.
6600         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
6601         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
6602
6603         * lib/getcwd.c (__getcwd): Clarify a comment.
6604         Use memcpy in place of a call to strcpy.
6605
6606         2006-03-12  Jim Meyering  <jim@meyering.net>
6607
6608         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
6609         matches that of the current directory (which we're about to chdir ".."
6610         out of), then save the dev-ino of the parent, instead.
6611
6612         * lib/same-inode.h (SAME_INODE): New file/macro.
6613         * lib/chdir-safer.c (SAME_INODE): Remove definition.
6614         Include "same-inode.h", instead.
6615         * lib/same.c: Likewise.
6616         * lib/cycle-check.h: Include "same-inode.h".
6617         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
6618         * lib/cycle-check.c (SAME_INODE): Remove definition.
6619         * lib/root-dev-ino.h: Include "same-inode.h".
6620
6621         2006-03-11  Eric Blake  <ebb9@byu.net>
6622
6623         * lib/same.c (same_name): s/base_name/last_component/
6624         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
6625         * lib/filenamecat.c (file_name_concat): Likewise.
6626
6627         2006-03-11  Eric Blake  <ebb9@byu.net>,
6628                     Paul Eggert  <eggert@cs.ucla.edu>
6629
6630         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
6631         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
6632         drive prefix.
6633         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
6634         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
6635         (last_component): New method.
6636         * lib/dirname.c (dir_len): Determine when drive letters need a
6637         subsequent slash.  Preserve // when it is special.
6638         (dir_name): Don't append dot when drive letter is absolute.
6639         [TEST_DIRNAME]: Move into a full-blown gnulib test.
6640         * lib/basename.c (base_name): New semantics - malloc the result.
6641         Preserve // when it is special.  Preserve relative files that look
6642         like drive letters.
6643         (base_len): Preserve // when it is special.
6644         (last_component): New method, similar to old base_name semantics.
6645         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
6646         base_name.  Strip redundant slashes from ///.
6647
6648 2006-07-03  Jim Meyering  <jim@meyering.net>
6649
6650         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
6651         macro is used before the first cycle_check call.
6652
6653 2006-07-03  Eric Blake  <ebb9@byu.net>
6654
6655         * modules/dirname (Depends-on): Add xstrndup.
6656
6657 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6658
6659         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
6660         test cases, so that config.log is a bit easier to follow.
6661
6662 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
6663
6664         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
6665         both are 64 bits, since this seems to be the tradition, and this
6666         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
6667         we ever run into a host that prefers long long to long in this
6668         case, we'll need another configure-time test.  Problem reported by
6669         Jim Meyering.
6670
6671 2006-07-02  Eric Blake  <ebb9@byu.net>
6672
6673         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
6674
6675 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6676
6677         * modules/inttypes (Depends-on): No longer depends on stdint.
6678         * modules/stdint (Description): Say more about assumptions.
6679         Say that the fast types might differ.  Say macros are used.
6680         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
6681         (Makefile.am): Revise list of substituted symbols to match
6682         new stdint.m4.
6683         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
6684         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
6685         * tests/test-stdint.c (verify_same_types)
6686         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
6687         the code conforms to C99/C89.
6688         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
6689         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
6690
6691 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6692
6693         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
6694         but fix a bug, by requiring at least 64 bits.
6695         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
6696         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
6697         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
6698         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
6699
6700         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
6701         changes.  Make 2.59 a prerequisite.  Check and substitute for
6702         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
6703         inttypes.h.  Do not use special include files; just use the
6704         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
6705         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
6706         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
6707         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
6708         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
6709         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
6710         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
6711         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
6712         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
6713         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
6714         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
6715         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
6716         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
6717         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
6718         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
6719         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
6720         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
6721         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
6722         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
6723         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
6724         WINT_MAX.  Check for C99 conformance more strictly, by detecting
6725         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
6726         not check for things that C99 does not require, e.g., int8_t.  If
6727         a test isn't needed unless <stdint.h> isn't working, and is
6728         unlikely to be needed for any other reason, then don't do it
6729         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
6730         size_t, since we assume C89 freestanding at least.  Do not check
6731         for sig_atomic_t, wchar_t, or wint_t, since the code now does
6732         the right thing even if the types are not defined.  Instead use:
6733         (gl_STDINT_TYPE_PROPERTIES): New macro.
6734         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
6735         testing whether <sys/types.h> clashes, as Autoconf does this for
6736         us now.  All uses removed.
6737         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
6738         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
6739         (gl_CHECK_TYPE_SAME):
6740         Remove; no longer needed.
6741         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
6742         exists, since we'll return 0 anyway in that case.
6743         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
6744
6745 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
6746
6747         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
6748         possible collision with system files.
6749         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
6750         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
6751         WCHAR_MIN and WCHAR_MAX in this case.
6752         (<stddef.h>): Do not include; no longer needed.
6753         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
6754         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
6755         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
6756         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
6757         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
6758         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
6759         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
6760         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
6761         !defined(__c99))]: Include in this case too, since it's harmless
6762         now.
6763         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
6764         dangerous to do so.
6765         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
6766         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
6767         (_STDINT_MIN, _STDINT_MAX): New macros.
6768         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
6769         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
6770         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
6771         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
6772         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
6773         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
6774         macros, not typedefs; this simplifies things quite a bit.
6775         Use long int for all types narrower than int64_t.
6776         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
6777         Define in terms of long long int or int64_t or long int,
6778         not int64_t or int32_t.  This saves some compile-time testing.
6779         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
6780         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
6781         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
6782         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
6783         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
6784         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
6785         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
6786         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
6787         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
6788         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
6789         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6790         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6791         undef any previous version and define our own version, for
6792         simplicity and consistency with the new macros for types.
6793         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
6794         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
6795         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
6796         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
6797         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
6798         @WINT_T_SUFFIX@ to keep things simple here.
6799         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
6800         Simplify by assuming typical 8/16/32/64 host, since we're
6801         already doing that elsewhere anyway.
6802         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
6803         and assume long long int is 64 bits if available.  This
6804         speeds up 'configure'.
6805
6806 2006-07-01  Eric Blake  <ebb9@byu.net>
6807
6808         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
6809         Reported by Andreas Buening.
6810
6811 2006-07-01  Eric Blake  <ebb9@byu.net>
6812
6813         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
6814
6815 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
6816
6817         * lib/getaddrinfo.c: fixed typo
6818
6819 2006-06-29  Jim Meyering  <jim@meyering.net>
6820
6821         * modules/strftime (Maintainer): Add my name, since with the
6822         FPRINTFTIME changes strftime.c has forked from glibc.
6823
6824 2006-06-29  Eric Blake  <ebb9@byu.net>
6825
6826         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
6827
6828 2006-06-29  Eric Blake  <ebb9@byu.net>
6829
6830         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
6831
6832 2006-06-29  Eric Blake  <ebb9@byu.net>
6833
6834         * lib/stat_.h: New file.
6835
6836 2006-06-29  Eric Blake  <ebb9@byu.net>
6837
6838         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
6839         unused static function.
6840
6841 2006-06-29  Eric Blake  <ebb9@byu.net>
6842
6843         * doc/functions.texi (Function Portability): Document missing lstat
6844         on mingw.
6845
6846 2006-06-29  Eric Blake  <ebb9@byu.net>
6847
6848         * MODULES.html.sh: Add sys_stat.
6849         * modules/sys_stat: New module.
6850         * modules/mkstemp (Depends-on): Add sys_stat.
6851
6852 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6853
6854         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
6855
6856 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6857
6858         * m4/c-bs-a.m4: Removed.
6859
6860 2006-06-29  Derek R. Price  <derek@ximbiot.com>
6861
6862         * lib/strftime.c: Assume strftime() exists.
6863
6864 2006-06-29  Derek Price  <derek@ximbiot.com>
6865
6866         * modules/c-bs-a: Removed - \a is C89.
6867         * MODULES.html.sh: Remove c-bs-a.
6868
6869 2006-06-29  Bruno Haible  <bruno@clisp.org>
6870
6871         * modules/wcwidth (License): Change to LGPL.
6872
6873 2006-06-28  Simon Josefsson  <jas@extundo.com>
6874
6875         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
6876         on _WIN32.
6877
6878         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
6879         getnameinfo.
6880
6881 2006-06-28  Simon Josefsson  <jas@extundo.com>
6882
6883         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
6884
6885 2006-06-28  Simon Josefsson  <jas@extundo.com>
6886
6887         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
6888         functions there.  It will succeed on Windows XP, but on Windows
6889         2000 and (presumably) earlier, it will fail, and use the internal
6890         re-implementation.
6891         (use_win32_p): New function.
6892         (getaddrinfo): Use strtoul on servname, to support numeric ports.
6893         Support AI_NUMERICSERV to disable getservbyname.
6894         (getnameinfo): New function, only supports
6895         NI_NUMERICHOST|NI_NUMERICSERV for now.
6896
6897         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
6898         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
6899         getnameinfo.
6900
6901 2006-06-28  Eric Blake  <ebb9@byu.net>
6902
6903         * modules/wcwidth: New file.
6904         * modules/mbchar (Depends-on): Add wcwidth.
6905         * modules/mbswidth (Depends-on): Add wcwidth.
6906         * MODULES.html.sh: Add wcwidth.
6907
6908 2006-06-28  Eric Blake  <ebb9@byu.net>
6909
6910         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
6911         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
6912
6913 2006-06-28  Eric Blake  <ebb9@byu.net>
6914
6915         * lib/xvasprintf.h: Fix comments.
6916
6917 2006-06-28  Eric Blake  <ebb9@byu.net>
6918
6919         * lib/mbchar.h (wcwidth): Include wcwidth.h.
6920         * lib/mbswidth.c (wcwidth): Move from here...
6921         * lib/wcwidth.h: ...to this new file.
6922
6923 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6924
6925         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
6926
6927         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
6928         it's obsolete.
6929         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
6930
6931 2006-06-28  Derek R. Price  <derek@ximbiot.com>
6932
6933         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
6934         Autoconf 2.60 says this stuff was obsolete.
6935
6936 2006-06-28  Bruno Haible  <bruno@clisp.org>
6937
6938         * modules/wcwidth (Files): Add m4/wchar_t.m4.
6939
6940 2006-06-28  Bruno Haible  <bruno@clisp.org>
6941
6942         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
6943         gt_TYPE_WCHAR_T.
6944
6945 2006-06-28  Bruno Haible  <bruno@clisp.org>
6946
6947         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
6948         declaration for wcwidth.
6949         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
6950
6951 2006-06-28  Bruno Haible  <bruno@clisp.org>
6952
6953         * lib/mkdtemp.c [MINGW]: Include <io.h>.
6954         (mkdir): Define using _mkdir.
6955
6956 2006-06-28  Bruno Haible  <bruno@clisp.org>
6957
6958         * lib/getaddrinfo.h: Fix POSIX URL.
6959         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
6960         _WIN32.
6961         (use_win32_p): Make static.
6962         (getaddrinfo): Reject service name if it is empty or does not consist
6963         solely of decimal digits, or if its value is > 65535.
6964         (getnameinfo): Remove useless casts.
6965
6966 2006-06-27  Simon Josefsson  <jas@extundo.com>
6967
6968         * modules/sys_select: New file, suggested by Bruno Haible, Paul
6969         Eggert and Martin Lambers.
6970
6971 2006-06-27  Simon Josefsson  <jas@extundo.com>
6972
6973         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
6974         Eggert and Martin Lambers.
6975
6976 2006-06-27  Bruno Haible  <bruno@clisp.org>
6977
6978         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
6979         result to 0, not to empty.
6980         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
6981
6982 2006-06-27  Bruno Haible  <bruno@clisp.org>
6983
6984         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
6985
6986 2006-06-26  Simon Josefsson  <jas@extundo.com>
6987
6988         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
6989         present.
6990
6991 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
6992
6993         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
6994         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
6995         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
6996
6997 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
6998
6999         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
7000
7001 2006-06-26  Bruno Haible  <bruno@clisp.org>
7002
7003         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
7004
7005 2006-06-26  Bruno Haible  <bruno@clisp.org>
7006
7007         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
7008
7009 2006-06-26  Bruno Haible  <bruno@clisp.org>
7010
7011         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
7012         SGI C compiler in pre-C99 mode.
7013         Suggested by Mark D. Baushke and Larry Jones.
7014
7015 2006-06-26  Bruno Haible  <bruno@clisp.org>
7016
7017         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
7018         WCHAR_MAX.
7019         Reported by Mark D. Baushke and Larry Jones.
7020
7021 2006-06-26  Bruno Haible  <bruno@clisp.org>
7022
7023         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
7024         in pre-C99 mode.
7025         Suggested by Mark D. Baushke and Larry Jones.
7026
7027 2006-06-23  Simon Josefsson  <jas@extundo.com>
7028             Bruno Haible  <bruno@clisp.org>
7029
7030         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
7031         Emit mostlyclean-local rule.
7032         (func_emit_tests_Makefile_am): Likewise.
7033         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
7034
7035 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
7036
7037         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
7038
7039 2006-06-23  Bruno Haible  <bruno@clisp.org>
7040
7041         * tests/test-stdint.c: Update to match ISO C 99 Technical
7042         Corrigendum 1.
7043
7044 2006-06-23  Bruno Haible  <bruno@clisp.org>
7045
7046         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
7047
7048 2006-06-23  Bruno Haible  <bruno@clisp.org>
7049
7050         * lib/stdint_.h: Treat IRIX like OpenBSD.
7051
7052 2006-06-23  Bruno Haible  <bruno@clisp.org>
7053
7054         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
7055         ISO C 99 Technical Corrigendum 1.
7056
7057 2006-06-22  Simon Josefsson  <jas@extundo.com>
7058
7059         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
7060         MinGW.
7061
7062 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
7063
7064         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
7065         needed.  Some compiler complained about some of them.  Problem reported
7066         by Larry Jones in
7067         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
7068
7069 2006-06-21  Simon Josefsson  <jas@extundo.com>
7070
7071         * tests/test-getaddrinfo.c: New file.
7072
7073         * modules/getaddrinfo-tests: New file.
7074
7075         * MODULES.html.sh: Add inet_pton.
7076
7077         * modules/inet_pton: New file.
7078
7079 2006-06-21  Simon Josefsson  <jas@extundo.com>
7080
7081         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
7082         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
7083         of using the (limited) gnulib implementation on Windows XP.
7084
7085         * m4/inet_pton.m4: New file.
7086
7087 2006-06-21  Simon Josefsson  <jas@extundo.com>
7088
7089         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
7090         variable.
7091
7092         * lib/socket_.h: Don't define WINVER.
7093
7094         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
7095         slightly modified to work in gnulib.
7096
7097 2006-06-21  Simon Josefsson  <jas@extundo.com>
7098
7099         * doc/gnulib.texi (Windows sockets): Add.
7100
7101 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
7102
7103         * lib/read-file.c (fread_file): Start with buffer allocation of
7104         0 bytes rather than 1 byte; this simplifies the code.
7105         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
7106         code to free buffer and save/restore errno.
7107         (internal_read_file): Remove unused local.
7108
7109 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
7110
7111         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
7112         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
7113         Problem reported by Denis Excoffier in
7114         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
7115
7116 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7117
7118         * modules/sys_socket, modules/socklen: Include sys/types since
7119         FreeBSD 4.x's sys/socket.h needs it.
7120
7121 2006-06-19  Simon Josefsson  <jas@extundo.com>
7122
7123         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
7124
7125 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
7126
7127         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
7128
7129 2006-06-19  Bruno Haible  <bruno@clisp.org>
7130
7131         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
7132         and FULL_PATH_INTTYPES_H in angle brackets.
7133         Reported by Mark D. Baushke <mdb@gnu.org>.
7134
7135 2006-06-17  Eric Blake  <ebb9@byu.net>
7136
7137         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
7138         errno.
7139
7140 2006-06-17  Bruno Haible  <bruno@clisp.org>
7141
7142         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
7143         <sys/inttypes.h>.
7144
7145 2006-06-17  Bruno Haible  <bruno@clisp.org>
7146
7147         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
7148         whether errno is declared. Assume <errno.h> declares errno.
7149
7150 2006-06-17  Bruno Haible  <bruno@clisp.org>
7151
7152         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
7153
7154 2006-06-17  Bruno Haible  <bruno@clisp.org>
7155
7156         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
7157         problem on Solaris 2.5.1.
7158
7159 2006-06-16  Eric Blake  <ebb9@byu.net>
7160
7161         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
7162         * lib/unicodeio.c [!defined errno]: Likewise.
7163         * lib/strtol.c [!defined errno]: Likewise.
7164         * lib/strtod.c [!defined errno]: Likewise.
7165
7166 2006-06-15  Eric Blake  <ebb9@byu.net>
7167
7168         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
7169
7170 2006-06-15  Eric Blake  <ebb9@byu.net>
7171
7172         * config/srclist.txt (ssize_t.m4): Lose sync.
7173
7174 2006-06-15  Bruno Haible  <bruno@clisp.org>
7175
7176         * modules/stdint (Files): Include m4/full-header-path.m4,
7177         m4/size_max.m4, m4/wchar_t.m4.
7178         (Makefile.am): Many more substitutions.
7179         * modules/stdint-tests: New file.
7180         * tests/test-stdint.c: New file.
7181
7182 2006-06-15  Bruno Haible  <bruno@clisp.org>
7183
7184         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
7185         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
7186         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
7187         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
7188         gl_CHECK_TYPE_SAME): New macros.
7189
7190 2006-06-15  Bruno Haible  <bruno@clisp.org>
7191
7192         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
7193
7194 2006-06-15  Bruno Haible  <bruno@clisp.org>
7195
7196         * lib/stdint_.h: Rewritten to be fully auto-configured.
7197         Fixes bug on HP-UX/IA64.
7198
7199 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
7200
7201         * lib/getdate.y (__attribute__): Don't define if already defined.
7202         Problem reported by Larry Jones.
7203         * lib/utimens.c (__attribute__): Likewise.
7204
7205 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
7206
7207         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
7208         reported by Andreas Schwab.
7209
7210 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7211             Bruno Haible  <bruno@clisp.org>
7212
7213         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
7214         check for the declaration of strnlen and a run test that exposes the
7215         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
7216         rpl_strndup.
7217
7218 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7219             Bruno Haible  <bruno@clisp.org>
7220
7221         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
7222
7223 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7224
7225         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
7226         compile test, for Tru64 4.0D.
7227
7228 2006-05-28  Karl Berry  <karl@gnu.org>
7229
7230         * config/srclist.txt (printf-args.c): lose sync.
7231
7232 2006-05-26  Martin Lambers  <marlam@marlam.de>
7233
7234         * lib/getpass.c: Updates the test for the native W32 API, and adds
7235         missing includes, thus fixing compilation warnings.
7236
7237 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
7238
7239         * lib/exclude.c (exclude_fnmatch): New function.
7240         (excluded_file_name): Call exclude_fnmatch.
7241         * lib/exclude.h (excluded_file_name): New prototype
7242
7243 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
7244
7245         * lib/tempname.c (small_open, large_open): New macros.
7246         (__open, __open64) [!_LIBC]: Remove.
7247         (__gen_tempname): Use small_open and large_open instead of __open
7248         and __open64.  This fixes a portability bug on HP-UX 11.11i
7249         reported by Simon Wing-Tang in
7250         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
7251
7252 2006-05-24  Bruno Haible  <bruno@clisp.org>
7253
7254         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
7255         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
7256         Reported by Thorsten Maerz <torte@netztorte.de> via
7257         Aaron Stone <aaron@serendipity.cx>.
7258
7259 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7260
7261         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
7262         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
7263         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
7264         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
7265         not really conditional on the cache.
7266         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
7267
7268 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
7269
7270         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
7271         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
7272         (my_usleep): Don't mishandle maximum value.
7273
7274 2006-05-19  Jim Meyering  <jim@meyering.net>
7275
7276         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
7277
7278 2006-05-17  Bruno Haible  <bruno@clisp.org>
7279
7280         Cygwin portability.
7281         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
7282
7283 2006-05-17  Bruno Haible  <bruno@clisp.org>
7284
7285         * lib/stdint_.h: Fix recognition of Cygwin.
7286
7287 2006-05-15  Bruno Haible  <bruno@clisp.org>
7288
7289         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
7290         on libtool patch by Ralf Wildenhues.
7291
7292 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
7293
7294         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
7295         test for C99 conformance; (bool) 0.5 is an integer constant
7296         expression, but (bool) -0.5 is not.  Problem reported by Fedor
7297         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
7298
7299 2006-05-11  Simon Josefsson  <jas@extundo.com>
7300
7301         * m4/xvasprintf.m4: Fix obvious typo.
7302
7303 2006-05-11  Jim Meyering  <jim@meyering.net>
7304
7305         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
7306         James Lemley.
7307
7308 2006-05-10  Simon Josefsson  <jas@extundo.com>
7309
7310         * lib/md4.c: Typo fix, update copyright years.
7311         (K1, K2): Don't use L because it turn computations into 64-bit on
7312         64-bit platforms.
7313
7314 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
7315
7316         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
7317         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
7318         unwanted sign propagation, e.g., on hosts with 64-bit int.
7319         There still are some problems with reeelly weird theoretical hosts
7320         (e.g., 33-bit int) but it's not worth worrying about now.
7321         * lib/sha1.c (rol): Likewise.
7322         (K1, K2, K3, K4): Remove unnecessary L suffix.
7323
7324 2006-05-10  Bruno Haible  <bruno@clisp.org>
7325
7326         * lib/des.c: Cast to avoid warnings.
7327
7328 2006-05-09  Bruno Haible  <bruno@clisp.org>
7329
7330         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
7331         (Depends-on): Depend also on xsize, stdarg.
7332         (configure.ac): Add gl_XVASPRINTF.
7333
7334 2006-05-09  Bruno Haible  <bruno@clisp.org>
7335
7336         * m4/xvasprintf.m4: New file.
7337
7338 2006-05-09  Bruno Haible  <bruno@clisp.org>
7339
7340         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
7341         (EOVERFLOW): Define fallback value.
7342         (xstrcat): New function.
7343         (xvasprintf): Recognize the special case of a string concatenation.
7344
7345 2006-05-08  Eric Blake  <ebb9@byu.net>
7346
7347         * gnulib-tool (func_version): Base copyright year on CVS date.
7348         (func_emit_copyright_notice): New function.
7349         (func_emit_lib_Makefile_am): Use it.
7350         (func_emit_tests_Makefile_am): Likewise.
7351         (func_import): Likewise.
7352
7353 2006-05-08  Bruno Haible  <bruno@clisp.org>
7354
7355         * modules/stdarg: New file.
7356         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
7357
7358 2006-05-08  Bruno Haible  <bruno@clisp.org>
7359
7360         * m4/stdarg.m4: New file, from GNU gettext.
7361
7362 2006-05-08  Bruno Haible  <bruno@clisp.org>
7363
7364         * config/srclist.txt (build-aux/config.rpath): different from latest
7365         release.
7366
7367 2006-05-08  Bruno Haible  <bruno@clisp.org>
7368
7369         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
7370
7371 2006-05-05  Jim Meyering  <jim@meyering.net>
7372
7373         * m4/warning.m4: New file, derived from bison's file by the same name.
7374
7375 2006-05-03  Bruno Haible  <bruno@clisp.org>
7376
7377         * lib/stdint_.h: Shorter URL.
7378         * lib/inttypes.h: Likewise.
7379
7380 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7381
7382         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
7383
7384 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7385
7386         * lib/verify.h: Document the internals better.  Most of this change
7387         was written by Bruno Haible.
7388
7389 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
7390
7391         * doc/verify.texi: New file, partly based on a proposal by
7392         Bruno Haible.
7393
7394 2006-05-02  Bruno Haible  <bruno@clisp.org>
7395
7396         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
7397         test from here...
7398         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
7399
7400 2006-04-29  Bruno Haible  <bruno@clisp.org>
7401
7402         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
7403         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
7404
7405 2006-04-29  Bruno Haible  <bruno@clisp.org>
7406
7407         * gnulib-tool: Make --update option actually work.
7408
7409 2006-04-29  Bruno Haible  <bruno@clisp.org>
7410
7411         * doc/gcd.texi: New file.
7412         * doc/gnulib.texi: Include it.
7413
7414 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
7415
7416         * lib/getdate.y (get_date): When adding relative date, start with the
7417         initial time, not with the result of the first mktime call.
7418
7419 2006-04-25  Bruno Haible  <bruno@clisp.org>
7420
7421         * gnulib-tool (func_import): Output the include directives in three
7422         blocks, sorted separately.
7423         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7424
7425 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7426
7427         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
7428         to define main with arguments, for C++.  Reported by Eric Blake.
7429         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
7430         Prefer 'int main ()' to 'int main (void)', for C++.
7431         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
7432         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
7433         for 'main', for C99 and C++.
7434
7435 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
7436
7437         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
7438         Don't assume that exit status -1 is valid.
7439         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7440         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
7441         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7442         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
7443         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
7444         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
7445         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
7446         functions can be used without declaring them, or that you can
7447         exit with status -1.
7448         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7449
7450 2006-04-24  Karl Berry  <karl@gnu.org>
7451
7452         * config/srclist.txt (longdouble.m4): sync lost.
7453
7454 2006-04-24  Eric Blake  <ebb9@byu.net>
7455
7456         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
7457
7458 2006-04-24  Bruno Haible  <bruno@clisp.org>
7459
7460         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
7461         poll() implementation in AIX.
7462         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7463
7464 2006-04-24  Bruno Haible  <bruno@clisp.org>
7465
7466         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
7467         assigned exactly once.
7468
7469 2006-04-23  Claudio Fontana  <claudio@gnu.org>
7470             Bruno Haible  <bruno@clisp.org>
7471
7472         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
7473         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
7474         for AM_CPPFLAGS.
7475
7476 2006-04-23  Bruno Haible  <bruno@clisp.org>
7477
7478         * modules/copy-file: Depend on unistd.
7479         * modules/execute: Likewise.
7480         * modules/fatal-signal: Likewise.
7481         * modules/findprog: Likewise.
7482         * modules/mkdtemp : Likewise.
7483         * modules/pipe: Likewise.
7484         * modules/wait-process: Likewise.
7485
7486 2006-04-23  Bruno Haible  <bruno@clisp.org>
7487
7488         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
7489         condition was already detected.
7490         Reported by Ben Pfaff <blp@cs.stanford.edu>.
7491
7492 2006-04-23  Bruno Haible  <bruno@clisp.org>
7493
7494         * lib/copy-file.c: Include <unistd.h> unconditionally.
7495         * lib/execute.c: Likewise.
7496         * lib/fatal-signal.c: Likewise.
7497         * lib/findprog.c: Likewise.
7498         * lib/mkdtemp.c: Likewise.
7499         * lib/pipe.h: Likewise.
7500         * lib/pipe.c: Likewise.
7501         * lib/wait-process.h: Likewise.
7502
7503 2006-04-23  Bruno Haible  <bruno@clisp.org>
7504
7505         * gnulib-tool (func_usage): Fix --import description. Document
7506         --update.
7507         (func_import): Create temporary file in a temporary directory, if
7508         --dry-run is specified. Silence errors from 'grep' when there are no
7509         m4 files in $m4dir.
7510         (func_create_testdir): Silence errors from 'grep' when there are no
7511         m4 files in $m4dir.
7512         Reported by Karl Berry <karl@freefriends.org>.
7513
7514 2006-04-20  Bruno Haible  <bruno@clisp.org>
7515
7516         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
7517         one argument, so that the code will be portable to Autoconf 2.60.
7518         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
7519         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
7520         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
7521
7522 2006-04-19  Derek Price  <derek@ximbiot.com>
7523             Eric Blake  <ebb9@byu.net>
7524
7525         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
7526         rather than "/full/path.h".  Update comment to match.  Shorten &
7527         generalize m4_translit call via AS_TR_CPP.
7528
7529 2006-04-19  Derek Price  <derek@ximbiot.com>
7530             Eric Blake  <ebb9@byu.net>
7531
7532         * lib/inttypes.h: Correct grammar in comment.
7533
7534 2006-04-18  Derek Price  <derek@ximbiot.com>
7535             Paul Eggert  <eggert@cs.ucla.edu>
7536
7537         * modules/inttypes: New file.
7538         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
7539
7540 2006-04-18  Derek Price  <derek@ximbiot.com>
7541             Paul Eggert  <eggert@cs.ucla.edu>
7542
7543         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
7544         New files.
7545
7546 2006-04-18  Derek Price  <derek@ximbiot.com>
7547             Paul Eggert  <eggert@cs.ucla.edu>
7548
7549         * lib/inttypes.h: New file.
7550         * lib/strtoimax.c: Assume <inttypes.h>.
7551
7552 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
7553
7554         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
7555         isn't mounted.  Problem reported by Kir Kolyshkin.
7556
7557 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
7558
7559         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
7560         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
7561         Derek R. Price.
7562         * lib/regex.h (RE_DUP_MAX): Update comment to match current
7563         implementation.
7564
7565 2006-04-12  Eric Blake  <ebb9@byu.net>
7566
7567         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
7568         is now done automatically by the corresponding Autoconf macro.
7569
7570 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
7571
7572         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
7573         time_r.h.
7574
7575 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7576
7577         Merge regex changes from libc, removing some of our
7578         POSIX-conformance changes that were rejected and redoing them in a
7579         less-intrusive way.
7580
7581         * lib/regcomp.c (re_compile_internal, init_dfa):
7582         Length arg is now size_t, not Idx.  All uses changed.
7583         (peek_token): Forward decl now says internal_function.
7584         (__re_error_msgid, __re_error_msgid_idx):
7585         Now static rather than extern with attribute_hidden.
7586         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
7587         For some reason libc prefers K&R style defns for external functions.
7588         (regerror) [!defined _LIBC]: Likewise.
7589         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
7590         (seek_collating_symbol_entry, lookup_collation_sequence_value):
7591         (build_range_exp, build_collating_symbol):
7592         Use K&R-style defn.
7593         (re_compile_fastmap): Use '\0' to memset, not 0.
7594         (utf8_sb_map): Make the calculations more obvious.
7595         (init_dfa, parse_bracket_exp, build_charclass_op):
7596         Call calloc and cast result, as glibc does.
7597         (init_word_char, fetch_token, peek_token, peek_token_bracket):
7598         (build_range_exp, build_collating_symbol):
7599         Now internal functions.
7600
7601         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
7602
7603         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
7604         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
7605         Don't depend on VMS; depend on __VMS instead, for POSIX
7606         namespace cleanness.
7607         (regoff_t): Define to ssize_t, not long int.
7608
7609         Remove the REG_ macros named below.  Instead, make the old names
7610         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
7611         __USE_GNU_REGEX.
7612         (REG_BACKSLASH_ESCAPE_IN_LISTS):
7613         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
7614         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
7615         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
7616         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
7617         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
7618         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
7619         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
7620         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
7621         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
7622         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
7623         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
7624         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
7625         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
7626         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
7627         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
7628         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
7629         (REG_NREGS):
7630         Remove.  All uses replaced by the old RE_* names.
7631         (RE_BACKSLASH_ESCAPE_IN_LISTS):
7632         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
7633         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
7634         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
7635         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
7636         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
7637         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
7638         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
7639         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
7640         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
7641         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
7642         Don't bother having these macros be independent of each others'
7643         values, since they no longer exist in the POSIX name space.
7644
7645         Rename the following member names back to their old names,
7646         unless !__USE_GNU_REGEX.  All uses changed back.
7647         (buffer): Renamed from re_buffer.
7648         (allocated): Renamed from re_allocated.
7649         (used): Renamed from re_used.
7650         (syntax): Renamed from re_syntax.
7651         (fastmap): Renamed from re_fastmap.
7652         (translate): Renamed from re_translate.
7653         (can_be_null): Renamed from re_can_be_null.
7654         (regs_allocated): Renamed from re_regs_allocated.
7655         (fastmap_accurate): Renamed from re_fastmap_accurate.
7656         (no_sub): Renamed from re_no_sub.
7657         (not_bol): Renamed from re_not_bol.
7658         (not_eol): Renamed from re_not_eol.
7659         (newline_anchor): Renamed from re_newline_anchor.
7660         (num_regs): Renamed from rm_num_regs.
7661         (start): Renamed from rm_start.
7662         (end): Renamed from rm_end.
7663
7664         (free_state): Move up a bit.
7665
7666         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
7667         #define to be empty.
7668         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
7669         when that is what is intended.
7670         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
7671         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
7672         (MAX): New macro.
7673         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
7674         All uses changed back to re_malloc, etc.  It's now the caller's
7675         responsibility to check for overflow; all callers changed.
7676         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
7677         (re_x2nrealloc): Remove.
7678         (free_state): Remove decl.
7679
7680         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
7681         (re_set_registers, re_exec):
7682         Use K&R-style defn.
7683
7684         2006-01-31  Roland McGrath  <roland@redhat.com>
7685
7686         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
7687         Reported by Mike Frysinger <vapier@gentoo.org>.
7688
7689         2006-01-15  Andreas Jaeger  <aj@suse.de>
7690
7691         [BZ #1950]
7692         * lib/regex_internal.c (re_string_reconstruct): Adjust for
7693         build_wcs_upper_buffer change.
7694         (build_wcs_upper_buffer): Change return type.
7695
7696         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
7697
7698         * lib/regex_internal.h: Include <stdint.h> if available.
7699
7700         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
7701
7702         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
7703
7704         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7705
7706         * lib/regcomp.c: Adjust for changed secondary hash function.
7707
7708         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
7709
7710         * lib/regex.h: Pretty printing.
7711         Clean up namespace a bit.
7712
7713         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
7714
7715         * lib/regexec.c (update_cur_sifted_state, check_arrival,
7716         check_arrival_add_next_nodes): Avoid using uninitialized variable.
7717
7718         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
7719                     Ulrich Drepper  <drepper@redhat.com>
7720
7721         [BZ #1302]
7722         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
7723         changed.
7724         (bitset_word_t): Renamed from bitset_word.  All uses changed.
7725
7726         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
7727
7728         [BZ #281]
7729         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
7730         * lib/regcomp.c: Remove unnecessary uses of
7731         unsigned RE_TRANSLATE_TYPE.
7732         * lib/regex_internal.h: Likewise.
7733         * lib/regex_internal.c: Likewise.
7734         * lib/regexec.c: Likewise.
7735         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
7736
7737         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
7738
7739         * lib/regexec.c (find_recover_state): Remove unnecessary
7740         initialization.
7741         (transit_state_bkref): Make DFA a const pointer.
7742         (get_subexp): Likewise.
7743         (check_arrival): Likewise.
7744         (update_cur_sifted_state): Likewise.
7745         (re_search_internal): Likewise.
7746         (prune_impossible_nodes): Likewise.
7747         (acquire_init_state_context): Likewise.
7748         (proceed_next_node): Likewise.
7749         (set_regs): Likewise.
7750         (free_fail_stack_return): Likewise.
7751         (check_arrival_expand_ecl): Mark DFA parameter as const.
7752         (check_arrival_expand_ecl_sub): Likewise.
7753         (check_subexp_limits): Likewise.
7754         (sub_epsilon_src_nodes):  Likewise.
7755         (add_epsilon_src_nodes):  Likewise.
7756         (merge_state_array): Likewise.
7757         (update_regs): Likewise.
7758         (build_trtable): Likewise.
7759         (sift_states_backward): Mark MCTX parameter as const.
7760         (build_sifted_states): Likewise.
7761         (update_cur_sifted_state): Likewise.
7762         (sift_states_mkref): Likewise.
7763         (check_arrival_expand_ecl): Mark eclosure as const.
7764         (check_dst_limits_calc_pos_1): Likewise.
7765         * lib/regex_internal.h (re_match_context_t): Make dfa a const
7766         pointer.
7767
7768         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
7769
7770         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
7771         (transit_state_sb): Likewise.
7772         (transit_state_mb): Likewise.
7773         (sift_states_iter_mb): Likewise.
7774         (check_arrival_add_next_nodes): Likewise.
7775         (check_node_accept_bytes): Change first parameter to pointer-to-const.
7776         [_LIBC] (re_search_2_stub): Use mempcpy.
7777
7778         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
7779         mbrtowc for very simple UTF-8 case.
7780
7781         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
7782         a pointer-to-const.
7783         (re_acquire_state_context): Likewise.
7784         * lib/regex_internal.h: Adjust prototypes.
7785
7786         * lib/regex.c: Prevent using C++ compilers.
7787
7788         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
7789         (re_acquire_state_context): Likewise.
7790
7791 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7792
7793         * modules/regex (Depends-on): Add ssize_t.
7794
7795 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7796
7797         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
7798         translation table.
7799
7800 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
7801
7802         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
7803
7804 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
7805             Bruno Haible  <bruno@clisp.org>
7806
7807         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
7808         <sys/types.h> and <inttypes.h>.
7809
7810 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7811
7812         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
7813         `__error_t_defined', so argp.h will not typedef the former.
7814
7815 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
7816
7817         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
7818         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
7819         glibc names.  Even if glibc is changed to conform to POSIX, the
7820         traditional names will be available anyway, since regex depends on
7821         the extensions module.  Also, fix a longstanding typo in the
7822         implementation of Spencer ERE test #75 from grep 2.3.  Problems
7823         reported by Emanuele Giaquinta.  Also, change sense of cached
7824         variable, so that the message makes sense.
7825
7826 2006-03-24  Simon Josefsson  <jas@extundo.com>
7827
7828         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
7829         including some doc fixes.
7830         (base64_encode_alloc): Fix +1 bug on allocation failures.
7831
7832 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7833
7834         * lib/base64.c (base64_encode): Do not read past end of array with
7835         unsanitized input on systems with CHAR_BIT > 8.
7836
7837 2006-03-24  Eric Blake  <ebb9@byu.net>
7838
7839         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
7840
7841 2006-03-22  Karl Berry  <karl@gnu.org>
7842
7843         * config/srclist.txt (*setenv.[ch]): get from coreutils.
7844         * config/srclistvars.sh (COREUTILS): new var.
7845
7846 2006-03-17  Jim Meyering  <jim@meyering.net>
7847
7848         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
7849         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
7850
7851 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7852
7853         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
7854         no longer needs it.  Instead, check that regoff_t is as least
7855         as wide as ptrdiff_t.
7856
7857         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
7858         so that our regex.h stays compatible with the installed regex.
7859         This is helpful for installers who configure --without-included-regex.
7860         Problem reported by Emanuele Giaquinta.
7861
7862 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
7863
7864         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
7865         Typedef to long int, not to off_, as POSIX will likely change
7866         in that direction.
7867
7868 2006-03-15  Eric Blake  <ebb9@byu.net>
7869
7870         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
7871
7872 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
7873
7874         * lib/argp-help.c (validate_uparams): Fix typo
7875         * lib/argp-parse.c (argp_default_options): Consistently begin help
7876         messages with a lowercase letter.
7877
7878 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
7879
7880         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
7881         overrun buffers and shouldn't be used (much as gets shouldn't be
7882         used).
7883         * lib/time_r.c (asctime_r, ctime_r): Likewise.
7884
7885 2006-03-08  Simon Josefsson  <jas@extundo.com>
7886
7887         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
7888         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7889
7890 2006-03-08  Simon Josefsson  <jas@extundo.com>
7891
7892         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
7893         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7894
7895 2006-03-08  Simon Josefsson  <jas@extundo.com>
7896
7897         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
7898         signal that configure disabled the device.
7899
7900 2006-03-08  Simon Josefsson  <jas@extundo.com>
7901
7902         * build-aux/maint.mk: Fix refresh-po, to handle no translated
7903         languages.
7904
7905 2006-03-07  Simon Josefsson  <jas@extundo.com>
7906
7907         * modules/getopt (Depends-on): Add unistd.
7908
7909         * modules/unistd: New file.
7910
7911 2006-03-07  Simon Josefsson  <jas@extundo.com>
7912
7913         * modules/gc-random: New file.
7914
7915 2006-03-07  Simon Josefsson  <jas@extundo.com>
7916
7917         * m4/unistd_h.m4: New file.
7918
7919 2006-03-07  Simon Josefsson  <jas@extundo.com>
7920
7921         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
7922         test to be side-effect free by storing the result in the cache
7923         variable gl_cv_lib_readline, and moving the assignment of
7924         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
7925         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7926
7927 2006-03-07  Simon Josefsson  <jas@extundo.com>
7928
7929         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
7930         error on missing devices (the functions will return an error).
7931
7932         * m4/gc.m4: Move random stuff to gc-random.m4
7933
7934 2006-03-07  Simon Josefsson  <jas@extundo.com>
7935
7936         * lib/unistd_.h: New file.
7937
7938 2006-03-07  Simon Josefsson  <jas@extundo.com>
7939
7940         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
7941
7942 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7943
7944         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
7945         Problem reported by Juan Manuel Guerrero.
7946
7947 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7948
7949         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
7950         the unistd module.
7951         * lib/getlogin_r.c: Likewise.
7952         * lib/getlogin_r.h: Likewise.
7953         * lib/glob.c: Likewise.
7954         * lib/pagealign_alloc.c: Likewise.
7955         * lib/unistd_.h: Remove; no longer needed.
7956
7957 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
7958
7959         * MODULES.html.sh (Support for systems lacking POSIX:2001):
7960         Add unistd.
7961         * modules/c-stack (Depends-on): Add unistd.
7962         * modules/getlogin_r: Likewise.
7963         * modules/glob: Likewise.
7964         * modules/pagealign_alloc: Likewise.
7965         * modules/unistd (Files): Remove lib/unistd_.h.
7966         (EXTRA_DIST): Remove.
7967         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
7968         need unistd_.h.
7969         (MOSTLYCLEANFILES): Remove unistd.h-t.
7970
7971 2006-03-03  Simon Josefsson  <jas@extundo.com>
7972
7973         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
7974
7975 2006-03-03  Simon Josefsson  <jas@extundo.com>
7976
7977         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
7978         libidn and bison.
7979
7980 2006-03-03  Simon Josefsson  <jas@extundo.com>
7981
7982         * build-aux/maint.mk: Add indent target.
7983
7984 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
7985
7986         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
7987         our replacement poll.h in any case, to avoid a differing
7988         declaration from a system header.  Seen on AIX.
7989
7990 2006-03-01  Simon Josefsson  <jas@extundo.com>
7991
7992         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
7993         <kasal@ucw.cz>.
7994
7995 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
7996
7997         * modules/gettime (Depends-on): Add extensions module.
7998         * modules/nanosleep (Depends-on): Likewise.
7999         * modules/settime (Depends-on): Likewise.
8000
8001 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
8002
8003         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
8004         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
8005         pedantically.
8006         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
8007         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
8008
8009         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
8010         not "==".  Reported by Ralf Wildenhues.
8011
8012 2006-03-01  Karl Berry  <karl@gnu.org>
8013
8014         * doc/Copyright/request-*: new files, synced from gnuorg.
8015
8016 2006-03-01  Karl Berry  <karl@gnu.org>
8017
8018         * config/srclist.txt (Copyright/*): new entries.
8019
8020 2006-02-28  Simon Josefsson  <jas@extundo.com>
8021
8022         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
8023
8024 2006-02-27  Simon Josefsson  <jas@extundo.com>
8025
8026         * lib/base64.h: Indent #define's.  From Jim Meyering
8027         <jim@meyering.net>.
8028
8029 2006-02-27  Jim Meyering  <jim@meyering.net>
8030
8031         Revert the change of 2006-02-24, so these files can continue
8032         to be sync'd from gettext.
8033         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
8034         of `config.h'.
8035
8036 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
8037
8038         * modules/intprops: New file.
8039         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
8040         Add intprops.
8041         * modules/getloadavg (Files): Remove lib/intprops.h.
8042         (Depends-on): Add intprops.
8043         * modules/human: Likewise.
8044         * modules/inttostr: Likewise.
8045         * modules/openat: Likewise.
8046         * modules/sig2str: Likewise.
8047         * modules/userspec: Likewise.
8048         * modules/utimecmp: Likewise.
8049         * modules/xnanosleep: Likewise.
8050         * modules/xstrtol: Likewise.
8051
8052 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
8053
8054         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
8055         * modules/lock-tests (TESTS): Use $(EXEEXT).
8056         * modules/tls-tests: Likewise.
8057         * modules/argp-tests: Likewise.
8058         (check_PROGRAMS): New var, replacing...
8059         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
8060
8061 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8062
8063         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
8064         `config.h'.
8065
8066 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
8067
8068         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
8069
8070 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8071
8072         Sync from coreutils.
8073         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
8074         gl_CHDIR_SAFER.
8075
8076 2006-02-22  Jim Meyering  <jim@meyering.net>
8077
8078         Sync from coreutils.
8079         * m4/chdir-safer.m4: New file.
8080
8081 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
8082
8083         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
8084         AT_FDCWD exceeds INT_MAX.
8085         * lib/openat.h (AT_FDCWD): Likewise.
8086
8087 2006-02-17  Eric Blake  <address@hidden>
8088
8089         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
8090
8091 2006-02-16  Simon Josefsson  <jas@extundo.com>
8092
8093         * modules/getaddrinfo (Depends-on): Add sys_socket.
8094
8095 2006-02-15  Simon Josefsson  <jas@extundo.com>
8096
8097         * build-aux/maint.mk: Add dsyntax-check rule.
8098
8099 2006-02-15  Eric Blake  <ebb9@byu.net>
8100
8101         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
8102         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
8103         'present but cannot compile' warnings on cygwin.
8104         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
8105         use ws2tcpip.h if sys/socket.h works.
8106         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
8107         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
8108
8109 2006-02-14  Simon Josefsson  <jas@extundo.com>
8110
8111         * modules/maintainer-makefile (Files): Rename.
8112
8113         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
8114         and (the local) Makefile.cfg to maint-cfg.mk.
8115
8116         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
8117         to the latter.
8118
8119         * modules/maintainer-makefile: New module.
8120
8121         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
8122         severaly stripped to make it possible to build it up from scratch
8123         with reliable tests.
8124
8125         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
8126         fixes to permit overriding the default actions when configure and
8127         makefile are not available.
8128
8129 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
8130
8131         Sync from coreutils.
8132         * modules/lstat (Depends-on): Don't depend on xalloc.
8133         (License): Change from GPL to LGPL, since this is now simply a
8134         replacement for a libc function.
8135
8136 2006-02-14  Jim Meyering  <jim@meyering.net>
8137
8138         Sync from coreutils.
8139
8140         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
8141         failure on deficient systems, and simplify gnulib lgpl dependencies.
8142         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
8143         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
8144
8145         * lib/xalloc-die.c: Remove unused definition of N_.
8146
8147 2006-02-14  Jim Meyering  <jim@meyering.net>
8148
8149         Sync from coreutils.
8150         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
8151         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
8152         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
8153         double-quote uses of that variable, to accommodate the rare case in
8154         which getmntent is available in none of the libraries checked.  This
8155         happens at least on FreeBSD 5.0.
8156
8157 2006-02-13  Simon Josefsson  <jas@extundo.com>
8158
8159         * gnulib-tool (Usage): Fix --import, from
8160         karl@freefriends.org (Karl Berry).
8161
8162 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
8163
8164         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
8165
8166 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
8167
8168         * lib/argp-namefrob.h: Restore changes accidentally lost during the
8169         "autoupdate" on 2005-12-12.
8170
8171 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
8172
8173         * modules/closeout (Depends-on): Remove atexit.
8174
8175 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
8176
8177         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
8178         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
8179
8180 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
8181
8182         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
8183         __EXTENSIONS__ if this causes compilation to fail.  Problem
8184         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
8185         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
8186
8187 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
8188
8189         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
8190         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
8191         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
8192         All uses changed.
8193
8194 2006-01-26  Simon Josefsson  <jas@extundo.com>
8195
8196         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
8197         prototype is visible on mingw32.
8198
8199         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
8200         for mingw32.
8201
8202         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
8203         mingw32).
8204
8205 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
8206
8207         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
8208         attempt to open for write; this always fails, at least on POSIX
8209         hosts.  This reinstates the 2006-01-09 change, which was
8210         inadvertently removed.
8211
8212 2006-01-26  Bruno Haible  <bruno@clisp.org>
8213
8214         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
8215         Reported by Paul Eggert.
8216
8217 2006-01-26  Bruno Haible  <bruno@clisp.org>
8218             Paul Eggert  <eggert@cs.ucla.edu>
8219
8220         * lib/stdbool_.h (_Bool)
8221         [(! (defined __cplusplus || defined __BEOS__)
8222           && !defined __GNUC__
8223           && !(defined __HP_cc || defined __xlc__
8224                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
8225                || defined __sgi))]:
8226         #define to signed char in these cases too; this simplifies
8227         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
8228         etc., separately) and makes it more conservative.
8229
8230 2006-01-25  Simon Josefsson  <jas@extundo.com>
8231
8232         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
8233         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
8234         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
8235
8236 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
8237
8238         * lib/argp-namefrob.h: Bugfix. Remove stray #
8239
8240 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
8241
8242         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
8243         so that we test the test.
8244         Check for yet another HP-UX cc bug involving *bool |= bool.
8245
8246 2006-01-25  Karl Berry  <karl@gnu.org>
8247
8248         * config/srclist.txt (vasnprintf.c): sync lost.
8249
8250 2006-01-25  Jim Meyering  <jim@meyering.net>
8251
8252         Sync from the stable (b5) branch of coreutils:
8253
8254         * lib/fts.c (fts_children): Don't let close() clobber errno from
8255         failed fchdir().
8256
8257         * lib/fts.c (fts_stat): When following a symlink-to-directory,
8258         don't necessarily interpret stat-fails+lstat-succeeds as indicating
8259         a dangling symlink.  That can also happen at least for ELOOP.
8260         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
8261         FYI, this bug predates the inclusion of fts.c in coreutils.
8262
8263         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
8264         in their own block, so pre-c99 compilers don't object.
8265
8266         Avoid the double-free (first in fts_read, second in fts_close) that
8267         would occur when an `active' directory is made inaccessible (e.g.,
8268         via chmod a-x) during a traversal.
8269         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8270         before returning.  Reproduce this failure by
8271         mkdir -p a/b; cd a; chmod a-x . b
8272         Reported by Stavros Passas.
8273
8274 2006-01-25  Jim Meyering  <jim@meyering.net>
8275
8276         * lib/fileblocks.c: Remove more useless parentheses.
8277         * lib/readutmp.h: Likewise.
8278
8279 2006-01-25  Bruno Haible  <bruno@clisp.org>
8280
8281         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
8282         warnings.
8283         Reported by Paul Eggert.
8284
8285 2006-01-25  Bruno Haible  <bruno@clisp.org>
8286
8287         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
8288         rid of a trap command. For Solaris sh.
8289         Reported by Mark D. Baushke <mdb@gnu.org>.
8290
8291 2006-01-24  Simon Josefsson  <jas@extundo.com>
8292
8293         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
8294         Bruno.
8295
8296 2006-01-24  Karl Berry  <karl@gnu.org>
8297
8298         * config/srclist.txt (argp-namefrob.h): sync lost.
8299
8300 2006-01-24  Jim Meyering  <jim@meyering.net>
8301
8302         * modules/openat (Files): Add lib/intprops.h.
8303         From Mark D. Baushke.
8304
8305 2006-01-24  Jim Meyering  <jim@meyering.net>
8306
8307         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
8308         Reported by Mark D. Baushke.
8309
8310 2006-01-24  Jim Meyering  <jim@meyering.net>
8311
8312         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
8313
8314 2006-01-24  Bruno Haible  <bruno@clisp.org>
8315
8316         * modules/strnlen (Maintainer): Change from glibc to all.
8317
8318 2006-01-24  Bruno Haible  <bruno@clisp.org>
8319
8320         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
8321         Patch by Paul Eggert.
8322
8323 2006-01-24  Bruno Haible  <bruno@clisp.org>
8324
8325         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
8326         already has it.
8327         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
8328         2005-11-26.
8329
8330         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
8331         'signed char' to avoid problems with the built-in _Bool type.
8332         Reported by Paul Eggert on 2005-11-26.
8333
8334 2006-01-24  Bruno Haible  <bruno@clisp.org>
8335
8336         * gnulib-tool (func_import): Avoid constructing complicated sed
8337         expressions inside backquote.
8338         Report and solution by Mark D. Baushke <mdb@gnu.org>.
8339
8340 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
8341
8342         These changes imported from libc.
8343         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
8344         test and two separate function calls.
8345         * lib/strndup.c (__strndup): Add libc_hidden_def.
8346
8347 2006-01-23  Simon Josefsson  <jas@extundo.com>
8348
8349         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
8350         Remove the test_*_SOURCES variable: automake infers it by default.
8351         * modules/tls-tests: Likewise.
8352
8353 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8354
8355         Work around porting bugs reported by Dieter in
8356         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
8357         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
8358         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
8359         Include "getopt.h" first, to check interface.
8360         (getenv): Declare only if defined HAVE_DECL_GETENV &&
8361         !HAVE_DECL_GETENV.
8362         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
8363         (__strndup): Revert to K&R-style function dfns, the glibc style.
8364         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
8365         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
8366         Include strnlen.h first, to get prototype properly.
8367         (strnlen): Renamed from __strnlen.
8368         Remove weak alias.
8369
8370 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8371
8372         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
8373
8374 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
8375
8376         * config/srclist.txt: Adjust to reflect glibc reorganization.
8377         This affects only comments.
8378
8379 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
8380
8381          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
8382          Reported by Bruce Korb <bkorb@gnu.org>.
8383
8384 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
8385
8386         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
8387         to pacify gcc -Wswitch-default.
8388
8389 2006-01-22  Bruno Haible  <bruno@clisp.org>
8390
8391         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
8392         temporary buffer for sprintf, take into account the precision also
8393         for 'd', 'i', 'u', 'o', 'x', 'X'.
8394
8395 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8396
8397         * modules/argp-tests: New module
8398         * tests/test-argp.c: New file
8399         * tests/test-argp-2.sh: New file
8400
8401 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
8402
8403         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
8404         (__argp_base_name): Removed
8405         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
8406         typo.
8407         (__argp_base_name): Provide macro definition or extern declaration
8408         depending on the configuration
8409
8410 2006-01-20  Simon Josefsson  <jas@extundo.com>
8411
8412         * modules/inet_ntop (Depends-on): Depend on sys_socket.
8413
8414 2006-01-20  Simon Josefsson  <jas@extundo.com>
8415
8416         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
8417
8418 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
8419
8420         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
8421         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
8422         Suggested by Bruno Haible.
8423
8424 2006-01-20  Karl Berry  <karl@gnu.org>
8425
8426         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
8427         until changes propagate, I guess.
8428
8429 2006-01-19  Simon Josefsson  <jas@extundo.com>
8430
8431         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
8432
8433 2006-01-19  Simon Josefsson  <jas@extundo.com>
8434
8435         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
8436
8437 2006-01-19  Simon Josefsson  <jas@extundo.com>
8438
8439         * gnulib-tool: Set check_PROGRAMS.
8440
8441         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8442         modules/des-tests, modules/gc-arcfour-tests,
8443         modules/gc-arctwo-tests, modules/gc-des-tests,
8444         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8445         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8446         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8447         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8448         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8449         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
8450         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
8451         test_*_SOURCES.
8452
8453 2006-01-18  Simon Josefsson  <jas@extundo.com>
8454
8455         * modules/socklen (Depends-on): Depend on sys_socket.
8456
8457 2006-01-18  Simon Josefsson  <jas@extundo.com>
8458
8459         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
8460         modules/des-tests, modules/gc-arcfour-tests,
8461         modules/gc-arctwo-tests, modules/gc-des-tests,
8462         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
8463         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
8464         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
8465         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
8466         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
8467         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
8468         $(EXEEXT) to automake TESTS variable, for mingw32.
8469
8470 2006-01-17  Simon Josefsson  <jas@extundo.com>
8471
8472         * modules/socklen (Include): Need sys/socket.h.
8473
8474 2006-01-17  Bruno Haible  <bruno@clisp.org>
8475
8476         * modules/ssize_t (Include): Add <sys/types.h>.
8477
8478 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
8479
8480         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
8481         it's not portable and it doesn't work with cross-compiles.
8482         Problem reported by Bruno Haible.  Fix missing-$ typo in
8483         'test "gl_cv_ignore_unused_libraries" ...' that prevented
8484         -zignore from being used with Sun's C compiler.
8485
8486 2006-01-12  Simon Josefsson  <jas@extundo.com>
8487
8488         * lib/base64.c: Fix warning, reported by Bruno Haible
8489         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
8490
8491 2006-01-12  Bruno Haible  <bruno@clisp.org>
8492
8493         * modules/ldd: New file.
8494         * build-aux/ldd.sh.in: New file.
8495         * MODULES.html.sh (Support for building libraries and executables): Add
8496         ldd.
8497
8498 2006-01-12  Bruno Haible  <bruno@clisp.org>
8499
8500         * m4/ldd.m4: New file.
8501
8502 2006-01-12  Bruno Haible  <bruno@clisp.org>
8503
8504         * gnulib-tool (func_import, func_create_testdir): Don't go into an
8505         endless loop while replacing $auxdir with build-aux.
8506
8507 2006-01-11  Simon Josefsson  <jas@extundo.com>
8508
8509         * lib/stdint_.h (SIZE_MAX): Add missing (.
8510
8511 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
8512
8513         Sync from coreutils.
8514         * lib/md5.c: Fix commentary typos.
8515         (alignof, UNALIGNED_P): No need for a GCC-specific version.
8516         * lib/md5.h (__attribute__): Remove; unused.
8517         * lib/sha1.c: Fix commentary to match md5 better.
8518         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
8519         so that we don't need to worry about alignment.  All uses changed.
8520         This merges the 2005-10-28 md5 change into sha1.
8521
8522 2006-01-11  Jim Meyering  <jim@meyering.net>
8523
8524         Sync from coreutils.
8525         * lib/md5.c (OP): Fix spacing.
8526
8527 2006-01-11  Bruno Haible  <bruno@clisp.org>
8528
8529         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8530         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
8531         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
8532
8533 2006-01-11  Bruno Haible  <bruno@clisp.org>
8534
8535         Ensure automatic ordering between gl_LOCK and gl_ARGP.
8536         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
8537         the "early" section as well.
8538
8539 2006-01-11  Bruno Haible  <bruno@clisp.org>
8540
8541         Avoid "ar: no archive members specified" error on MacOS X.
8542         * gnulib-tool (func_modules_add_dummy): New function.
8543         (func_import, func_create_testdir): Invoke it.
8544
8545 2006-01-11  Bruno Haible  <bruno@clisp.org>
8546
8547         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
8548         with $auxdir in AC_CONFIG_FILES statements.
8549
8550 2006-01-11  Bruno Haible  <bruno@clisp.org>
8551
8552         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8553         Initialize also noinst_HEADERS to empty.
8554
8555 2006-01-11  Bruno Haible  <bruno@clisp.org>
8556
8557         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
8558         variables.
8559         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
8560         autoreconf.
8561
8562 2006-01-11  Bruno Haible  <bruno@clisp.org>
8563
8564         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
8565         overridable by the user.
8566         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8567
8568 2006-01-10  Simon Josefsson  <jas@extundo.com>
8569
8570         * modules/sys_socket: New file.
8571
8572 2006-01-10  Simon Josefsson  <jas@extundo.com>
8573
8574         * m4/sys_socket_h.m4: New file.
8575
8576 2006-01-10  Simon Josefsson  <jas@extundo.com>
8577
8578         * lib/socket_.h: New file.
8579
8580 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8581
8582         * modules/readutmp (Maintainer): Add myself.
8583
8584 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8585
8586         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
8587         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
8588         People who are still concerned with buggy memcmp implementations
8589         can invoke gl_FUNC_MEMCMP themselves.
8590
8591 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
8592
8593         * lib/regex_internal.h (BITSET_WORD_BITS):
8594         Work around a bug in 64-bit PGC (before version 6.1-2), where the
8595         preprocessor mishandles large unsigned values as if they were signed.
8596         Problem reported by Claudio Fontana in
8597         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
8598
8599 2006-01-10  Jim Meyering  <jim@meyering.net>
8600
8601         Avoid the double-free (first in fts_read, second in fts_close) that
8602         would occur when an `active' directory is made inaccessible (e.g.,
8603         via chmod a-x) during a traversal.
8604         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
8605         before returning.  Reproduce this failure by
8606         mkdir -p a/b; cd a; chmod a-x . b
8607         Reported by Stavros Passas.
8608
8609         Sync from coreutils.
8610         * lib/sha1.c: Tweak grammar in a comment.
8611
8612 2006-01-10  Jim Meyering  <jim@meyering.net>
8613
8614         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
8615         Patch by Joerg Sonnenberger.
8616
8617 2006-01-10  Bruno Haible  <bruno@clisp.org>
8618
8619         * modules/readutmp: Depend on module free.
8620         * modules/strtok_r: Depend on module restrict.
8621
8622 2006-01-10  Bruno Haible  <bruno@clisp.org>
8623
8624         * modules/gettext (configure.ac): Add an invocation of
8625         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
8626
8627 2006-01-10  Bruno Haible  <bruno@clisp.org>
8628
8629         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
8630         Reported by Werner Lemberg <wl@gnu.org>.
8631
8632 2006-01-10  Bruno Haible  <bruno@clisp.org>
8633
8634         * lib/localcharset.c: Update from GNU gettext.
8635
8636 2006-01-10  Bruno Haible  <bruno@clisp.org>
8637
8638         * lib/argp.h (__const): Remove macro. Use const instead.
8639         * lib/argp-fmtstream.h (__const): Likewise.
8640         * lib/glob_.h (__const): Remove macro.
8641         * lib/glob-libc.h: Use const instead of __const.
8642
8643 2006-01-10  Bruno Haible  <bruno@clisp.org>
8644
8645         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
8646         variable.
8647         Needed to avoid an automake error regarding the 'gettext' module.
8648
8649 2006-01-09  Simon Josefsson  <jas@extundo.com>
8650
8651         * modules/inet_ntop (Depends-on): Add restrict.
8652
8653 2006-01-09  Simon Josefsson  <jas@extundo.com>
8654
8655         * modules/gc-rijndael-tests (License): Put under LGPL.
8656
8657         * modules/gc-des-tests (License): Likewise.
8658
8659         * modules/gc-arcfour-tests (License): Likewise.
8660
8661         * modules/gc-arctwo-tests (License): Likewise.
8662
8663         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
8664
8665         * modules/gc-hmac-sha1-tests (Files): Likewise.
8666
8667         * modules/gc-hmac-md5-tests (License): Likewise.
8668
8669         * modules/gc-sha1-tests (License): Likewise.
8670
8671         * modules/gc-md5-tests (License): Likewise.
8672
8673         * modules/gc-md4-tests (License): Likewise.
8674
8675         * modules/gc-md2-tests (License): Likewise.
8676
8677         * modules/gc-tests (License): Likewise.
8678
8679         * modules/des-tests (License): Likewise.
8680
8681         * modules/md4-tests (License): Likewise.
8682
8683         * modules/md2-tests (License): Likewise.
8684
8685 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8686
8687         Sync from coreutils:
8688
8689         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
8690         * modules/lib-ignore: New file.
8691         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
8692         chdir-safer.m4, lchmod.m4.
8693         * modules/openat: Add mkdirat.c, openat-priv.h.
8694
8695 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8696
8697         Sync from coreutils.
8698         * m4/lib-ignore.m4: New file.
8699         * m4/lchmod.m4: New file.
8700
8701 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8702
8703         Sync from coreutils.
8704         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
8705         for write access: POSIX says that must fail.
8706         * lib/fts.c (diropen): Likewise.
8707         * lib/save-cwd.c (save_cwd): Likewise.
8708         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
8709         well, for minor improvements on hosts that lack O_DIRECTORY.
8710         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
8711         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
8712         Fall back on chown if open failed with EACCES.
8713
8714         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
8715         Report an error at compile-time if only a 1-second nominal clock
8716         resolution is found.
8717
8718         * lib/lchmod.h: New file.
8719         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
8720         (make_dir_parents): Use lchown rather than chown, and
8721         lchmod rather than chmod.
8722
8723         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
8724         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
8725         "proc" reported by n0dalus.
8726
8727         * lib/mountlist.c: Include <limits.h>.
8728         (dev_from_mount_options)
8729         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
8730         New function.  It no longer assumes "dev=" has the System V meaning
8731         on Linux (since it doesn't).  It also parses "dev=" more carefully.
8732         (read_file_system_list)
8733         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
8734         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
8735         dev= in that case.
8736
8737         * lib/posixtm.h (PDS_PRE_2000): New macro.
8738         * lib/posixtm.c (year): Arg is now syntax_bits rather than
8739         allow_century.  All usages changed.  Reject dates outside the range
8740         1969-1999 if PDS_PRE_2000 is used.
8741
8742 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
8743
8744         Sync from coreutils.
8745         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
8746         (Time of day items): Mention the possibility of leap seconds.
8747         Problem reported by Dr. David Alan Gilbert.
8748
8749 2006-01-09  Jim Meyering  <jim@meyering.net>
8750
8751         Sync from coreutils.
8752
8753         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
8754
8755         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
8756
8757         * lib/modechange.c (mode_compile): Reject an invalid mode string
8758         that starts with an octal digit.  From Andreas Gruenbacher.
8759
8760         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
8761         and dup to open_safer and dup_safer, respectively.
8762         (openat_permissive): Fix typo in comment.
8763
8764         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
8765         "gettext.h"; either no longer needed or are guaranteed by openat.h.
8766         (_): Remove; no longer needed.
8767         (openat): Renamed from rpl_openat; no need for rpl_openat
8768         since openat.h renames openat for us.
8769         Replace most of the body with a call to openat_permissive,
8770         to avoid duplicate code.
8771         Port to (probably hypothetical) environments were mode_t is
8772         wider than int.
8773         (openat_permissive): Require mode arg, so that we can check
8774         types better.  Put it just after flags.  Change cwd failure
8775         indicator from pointer-to-bool to pointer-to-errno-value.
8776         All callers changed.
8777         Invoke openat_save_fail and/or openat_restore_fail if
8778         cwd_errno is null, so that openat can call us.
8779         (openat_permissive, fdopendir, fstatat, unlinkat):
8780         Simplify errno handling to avoid some duplicate code,
8781         as it's OK to set errno on success.
8782         * lib/openat.h: Revamp code so that function macros depend on
8783         __OPENAT_PREFIX only, not also on AT_FDCWD.
8784         (openat_ro): Remove.  Caller changed to use openat_permissive.
8785         (openat_permissive): Now a macro, if not a function.
8786         (openat_restore_fail, openat_save_fail): Now always functions,
8787         since mkdirat needs them even if __OPENAT_PREFIX is defined.
8788
8789         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
8790         and openat.c.
8791         * lib/mkdirat.c: Include openat-priv.h.
8792         Remove definitions of macros defined therein.
8793         * lib/openat.c: Likewise.
8794
8795         * lib/mkdirat.c (mkdirat): New file and function.
8796         * lib/openat.h (mkdirat): Declare.
8797
8798         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
8799
8800         * lib/openat.h (openat_permissive): Declare.
8801         (openat_ro): Define.
8802
8803         * lib/openat.c (EXPECTED_ERRNO): New macro.
8804         (openat_permissive): New function -- used in remove.c rewrite.
8805         (all functions): Set errno just before returning, only if there
8806         was an actual failure.
8807         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
8808
8809         Emulate openat-family functions using Linux's procfs, if possible.
8810         Idea and some code based on Ulrich Drepper's glibc changes.
8811
8812         * lib/openat.c: (BUILD_PROC_NAME): New macro.
8813         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
8814         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
8815         before falling back on save_cwd and restore_cwd.
8816         (fdopendir, fstatat, unlinkat): Likewise.
8817
8818         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
8819         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
8820
8821         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
8822         as second argument to va_arg.  Otherwise, some versions of gcc
8823         warn that `if this code is reached, the program will abort'.
8824
8825 2006-01-09  Jim Meyering  <jim@meyering.net>
8826
8827         Sync from coreutils.
8828         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
8829         Require openat-priv.h.
8830
8831 2006-01-09  Bruno Haible  <bruno@clisp.org>
8832
8833         * modules/strnlen (Include): Use strnlen.h.
8834
8835 2006-01-09  Bruno Haible  <bruno@clisp.org>
8836
8837         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
8838
8839 2006-01-09  Bruno Haible  <bruno@clisp.org>
8840
8841         * lib/sysexit_.h (EX_OK): New macro.
8842         Suggested by Martin Lambers <marlam@marlam.de>.
8843
8844 2006-01-09  Bruno Haible  <bruno@clisp.org>
8845
8846         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
8847         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
8848
8849 2006-01-09  Bruno Haible  <bruno@clisp.org>
8850
8851         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
8852         numbers.
8853
8854 2006-01-09  Bruno Haible  <bruno@clisp.org>
8855
8856         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
8857         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
8858         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
8859         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
8860
8861 2006-01-09  Bruno Haible  <bruno@clisp.org>
8862
8863         * build-aux/javacomp.sh.in: New file, moved from lib/.
8864         * modules/javacomp-script (Files): Update.
8865         (configure.ac): Add AC_CONFIG_FILES invocation.
8866         (EXTRA_DIST): Remove variable.
8867
8868         * build-aux/javaexec.sh.in: New file, moved from lib/.
8869         * modules/javaexec (Files): Update.
8870         (configure.ac): Add AC_CONFIG_FILES invocation.
8871         (EXTRA_DIST): Remove javaexec.sh.in.
8872
8873         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
8874         * modules/csharpcomp-script (Files): Update.
8875         (configure.ac): Add AC_CONFIG_FILES invocation.
8876         (EXTRA_DIST): Remove variable.
8877
8878         * build-aux/csharpexec.sh.in: New file, moved from lib/.
8879         * modules/csharpexec (Files): Update.
8880         (configure.ac): Add AC_CONFIG_FILES invocation.
8881         (EXTRA_DIST): Remove csharpexec.sh.in.
8882
8883 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8884
8885         Sync from coreutils.
8886
8887         Add POSIX ACL support
8888         * lib/acl.h (copy_acl, set_acl): Add declarations.
8889         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
8890         systems other than Linux.
8891         (chmod_or_fchmod): New function: use fchmod when possible,
8892         and chmod otherwise.
8893         (file_has_acl): Add a POSIX ACL implementation, with a
8894         Linux-specific subcase.
8895         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
8896         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
8897         acls are unsupported.
8898         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
8899         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
8900         are unsupported.
8901
8902 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
8903
8904         Sync from coreutils.
8905         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
8906
8907 2006-01-07  Bruno Haible  <bruno@clisp.org>
8908
8909         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
8910         gl_EARLY.
8911
8912 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8913
8914         * lib/strftime.c (tzname): Don't declare if it is already #defined.
8915         Problem reported for Mingw by Mark Junker.
8916
8917 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8918
8919         * README: Gnulib normally doesn't generate a tarball.
8920
8921 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
8922
8923         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
8924         long int, not int, for nanosecond counts, so that people who are
8925         used to POSIX struct timespec won't be surprised.  Reported by Jim
8926         Meyering.
8927
8928 2005-12-28  Bruno Haible  <bruno@clisp.org>
8929
8930         * build-aux/config.rpath: Update from GNU gettext.
8931
8932 2005-12-16  Jim Meyering  <jim@meyering.net>
8933
8934         * modules/fprintftime: New module.
8935         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
8936
8937 2005-12-16  Jim Meyering  <jim@meyering.net>
8938
8939         * m4/fprintftime.m4: New file.
8940
8941 2005-12-16  Jim Meyering  <jim@meyering.net>
8942
8943         * lib/fprintftime.c, lib/fprintftime.h: New files.
8944
8945 2005-12-15  Simon Josefsson  <jas@extundo.com>
8946
8947         * modules/socklen (configure.ac): Fix M4 macro name, to align with
8948         new m4/socklen.m4.
8949
8950 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8951
8952         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
8953         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
8954
8955 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8956
8957         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
8958         * lib/argp-help.c (fill_in_uparams): Check if the constructed
8959         struct uparams is valid. Fall back to the default values if it is
8960         not.
8961
8962 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8963
8964         * modules/argp (Files): Add argp-pin.c
8965         (Depends-on): dirname
8966         (lib_SOURCES): Add argp-pin.c
8967
8968 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8969
8970         * m4/argp.m4:  Check if program_invocation_name and
8971         program_invocation_short_name are declared and define appropriate
8972         macros if they are not.
8973
8974 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8975
8976         * lib/argp-help.c (__argp_base_name): New function
8977         (__argp_short_program_name): Rewrite using __argp_base_name
8978         * lib/argp-namefrob.h: Define program_invocation_name and
8979         program_invocation_short_name if requested
8980         (__argp_base_name): Add prototype
8981         * lib/argp-parse.c (argp_def): Use gettext wrappers
8982         (argp_default_parser): Use __argp_base_name
8983         * lib/argp-pin.c: New file. Defines program_invocation_name and
8984         program_invocation_short_name on systems that lack them.
8985
8986 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8987
8988         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
8989         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8990         porting problem reported by Georg Schwarz in
8991         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8992
8993 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
8994
8995         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
8996         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
8997         porting problem reported by Georg Schwarz in
8998         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
8999
9000 2005-12-05  Bruno Haible  <bruno@clisp.org>
9001
9002         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
9003         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
9004         Reported by Mark Junker <mjscod@gmx.de>.
9005
9006 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
9007
9008         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
9009         Use implementation from Albert Chin, with some
9010         comments/corrections by Stepan Kasal and myself.
9011
9012 2005-12-02  Bruno Haible  <bruno@clisp.org>
9013
9014         * gnulib-tool (func_import): Accept GPLed build tool modules when
9015         --lgpl is given.
9016         * modules/csharpcomp-script: New file.
9017         * modules/csharpcomp: Depend on it.
9018         * modules/javacomp-script: New file.
9019         * modules/javacomp: Depend on it.
9020         Suggested by Simon Josefsson.
9021
9022 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
9023
9024         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
9025         statement, to work around an HP-UX 10.20 compiler bug reported by
9026         Peter O'Gorman.
9027
9028 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
9029
9030         * modules/savedir (Depends-on): Add openat.
9031
9032 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
9033
9034         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
9035         (uintmax_t) [defined uintmax_t]: Do not declare.
9036         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
9037         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
9038         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
9039         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
9040         sake of portability to weird hosts that C allows (though we don't
9041         know of any practical examples).
9042
9043         * lib/savedir.h (fdsavedir): New decl.
9044         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
9045         contains most of the former guts of savedir.
9046         (savedir): Use savedirstream.
9047         Include "openat.h".
9048
9049 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
9050
9051         * modules/obstack (Files): Add m4/ulonglong.m4.
9052         Problem reported by Davide Angelocola.
9053
9054 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
9055
9056         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
9057         coreutils no longer futzes with rounding modes.
9058
9059 2005-11-14  Jim Meyering  <jim@meyering.net>
9060
9061         * lib/mkstemp-safer.c: Include <config.h>, required for possible
9062         replacement of mkstemp.
9063
9064 2005-11-10  Simon Josefsson  <jas@extundo.com>
9065
9066         * lib/readline.c: Remove EOL.
9067
9068 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9069
9070         * modules/gethrxtime (Depends-on): Add gettime.
9071
9072 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9073
9074         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
9075         or gettimeofday; no longer needed.
9076
9077 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
9078
9079         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
9080         time business.
9081         (gethrxtime) [! (HAVE_NANOUPTIME
9082         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
9083         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
9084         our own approximation.
9085
9086 2005-11-08  Eric Blake  <ebb9@byu.net>
9087
9088         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
9089
9090 2005-11-08  Eric Blake  <ebb9@byu.net>
9091
9092         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
9093
9094 2005-11-04  Bruno Haible  <bruno@clisp.org>
9095
9096         * gnulib-tool: Implement --update mode.
9097
9098 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
9099
9100         Fix porting problem reported by Theodoros V. Kalamatianos.
9101         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
9102         Don't assume that futimes failing means we must fail.
9103
9104 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
9105
9106         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
9107         variables to suggest the intended function of the PATH_MAX check.
9108
9109 2005-10-30  Kean Johnston  <jkj@sco.com>
9110
9111         Trivial changes to support SCO systems.
9112         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
9113         as PATH_MAX.
9114         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
9115         where __ptr is null when no I/O is pending.
9116
9117 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
9118
9119         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
9120         leave errno alone.  Problem reported by Dmitry V. Levin.
9121
9122 2005-10-28  Simon Josefsson  <jas@extundo.com>
9123
9124         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
9125         Test more.
9126
9127         * tests/test-gc-md2.c, tests/test-md2.c: New files.
9128
9129         * modules/md2, modules/md2-tests: New files.
9130
9131 2005-10-28  Simon Josefsson  <jas@extundo.com>
9132
9133         * m4/inet_ntop.m4: More tests.
9134
9135         * m4/gc-md2.m4, md2.m4: New file.
9136
9137 2005-10-28  Simon Josefsson  <jas@extundo.com>
9138
9139         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
9140         "restrict" keywords, as per POSIX.  Protect the function
9141         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
9142         Don't use K&R prototypes.  Check the sprintf return values.
9143         Re-define EAFNOSUPPORT if not present.  Indent.
9144
9145         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
9146         suggested by Bruno Haible <bruno@clisp.org>.
9147
9148         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
9149
9150         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
9151
9152         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
9153         libgcrypt).
9154
9155         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
9156
9157         * lib/md2.h, lib/md2.c: New files.
9158
9159 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
9160
9161         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
9162         errno alone.  Problem reported by Frederic Jolliton.
9163
9164 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
9165
9166         * modules/verify (License): Change from GPL to LGPL.  This is a
9167         tiny module and there are apparently near-equivalents that are
9168         under the BSD license.
9169
9170 2005-10-24  Simon Josefsson  <jas@extundo.com>
9171
9172         * modules/sha1: Relicense to LGPL.
9173
9174 2005-10-24  Simon Josefsson  <jas@extundo.com>
9175
9176         * lib/md4.h: Shrink buffer size, now that we changed the type.
9177
9178 2005-10-23  Simon Josefsson  <jas@extundo.com>
9179
9180         * gnulib-tool (func_import): Fix --tests-base.
9181
9182 2005-10-22  Simon Josefsson  <jas@extundo.com>
9183
9184         * modules/arcfour (Depends-on): Need stdint.
9185
9186 2005-10-22  Simon Josefsson  <jas@extundo.com>
9187
9188         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
9189         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
9190
9191 2005-10-22  Simon Josefsson  <jas@extundo.com>
9192
9193         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
9194         suggested by Bruno Haible <bruno@clisp.org>.
9195
9196 2005-10-22  Simon Josefsson  <jas@extundo.com>
9197
9198         * lib/crc.h: Include stddef.h, for size_t.
9199
9200 2005-10-22  Simon Josefsson  <jas@extundo.com>
9201
9202         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
9203         arcfour_context struct (simplify test vector testing in GNU
9204         Shishi).
9205
9206 2005-10-21  Simon Josefsson  <jas@extundo.com>
9207
9208         * modules/des, modules/des-tests: New files.
9209
9210         * modules/gc-des, modules/gc-des-tests: New files.
9211
9212         * tests/test-des.c, tests/test-gc-des.c: New file.
9213
9214 2005-10-21  Simon Josefsson  <jas@extundo.com>
9215
9216         * modules/arctwo, modules/arctwo-tests: New files.
9217
9218         * tests/test-arctwo.c: New file.
9219
9220         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
9221
9222         * tests/test-gc-arctwo.c: New file.
9223
9224 2005-10-21  Simon Josefsson  <jas@extundo.com>
9225
9226         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
9227         Bruno Haible <bruno@clisp.org>.
9228
9229         * m4/gc-des.m4: New file.
9230
9231 2005-10-21  Simon Josefsson  <jas@extundo.com>
9232
9233         * m4/arctwo.m4: New file.
9234
9235         * m4/gc-arctwo.m4: New file.
9236
9237 2005-10-21  Simon Josefsson  <jas@extundo.com>
9238
9239         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
9240         block.
9241
9242 2005-10-21  Simon Josefsson  <jas@extundo.com>
9243
9244         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
9245         <bruno@clisp.org>.
9246
9247         * lib/hmac-sha1.c (hmac_sha1): Likewise.
9248
9249         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
9250         Bruno Haible <bruno@clisp.org>.
9251
9252         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
9253         <bruno@clisp.org>.
9254
9255 2005-10-21  Simon Josefsson  <jas@extundo.com>
9256
9257         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
9258
9259 2005-10-21  Simon Josefsson  <jas@extundo.com>
9260
9261         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
9262
9263 2005-10-21  Simon Josefsson  <jas@extundo.com>
9264
9265         * lib/des.h, lib/des.c: New files.
9266
9267         * lib/gc-gnulib.c: Support DES.c
9268
9269 2005-10-21  Simon Josefsson  <jas@extundo.com>
9270
9271         * lib/arctwo.h, lib/arctwo.c: New files.
9272
9273         * lib/gc-gnulib.c: Support ARCTWO.
9274
9275 2005-10-21  Simon Josefsson  <jas@extundo.com>
9276
9277         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
9278         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9279
9280 2005-10-21  Simon Josefsson  <jas@extundo.com>
9281
9282         * gnulib-tool (func_import, func_create_testdir): Define automake
9283         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
9284         Makefile.am snippet),
9285         suggested by Bruno Haible <bruno@clisp.org>.
9286
9287         * modules/gc (Makefile.am): Use it.
9288
9289 2005-10-21  Bruno Haible  <bruno@clisp.org>
9290
9291         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
9292         patch.
9293
9294 2005-10-19  Simon Josefsson  <jas@extundo.com>
9295
9296         * tests/test-gc-rijndael.c: New file.
9297
9298         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
9299
9300 2005-10-19  Simon Josefsson  <jas@extundo.com>
9301
9302         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
9303         interface too.
9304
9305 2005-10-19  Simon Josefsson  <jas@extundo.com>
9306
9307         * tests/test-gc-arcfour.c: New file.
9308
9309         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
9310
9311 2005-10-19  Simon Josefsson  <jas@extundo.com>
9312
9313         * modules/gc-md4, modules/gc-md4-tests: New file.
9314
9315         * tests/test-gc-md4.c: New file.
9316
9317 2005-10-19  Simon Josefsson  <jas@extundo.com>
9318
9319         * m4/gc-md4.m4: New file.
9320
9321 2005-10-19  Simon Josefsson  <jas@extundo.com>
9322
9323         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
9324         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
9325         <kasal@ucw.cz>.
9326
9327 2005-10-19  Simon Josefsson  <jas@extundo.com>
9328
9329         * m4/gc-arcfour.m4: New file.
9330
9331         * m4/gc-rijndael.m4: New file.
9332
9333 2005-10-19  Simon Josefsson  <jas@extundo.com>
9334
9335         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
9336
9337 2005-10-19  Simon Josefsson  <jas@extundo.com>
9338
9339         * lib/gc-gnulib.c: Support ARCFOUR.
9340
9341 2005-10-19  Simon Josefsson  <jas@extundo.com>
9342
9343         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
9344         support.
9345
9346         * lib/gc.h: Add ECB enum type.
9347
9348         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
9349
9350 2005-10-18  Simon Josefsson  <jas@extundo.com>
9351
9352         * tests/test-md5.c: New file.
9353
9354         * modules/md5-tests: New file.
9355
9356 2005-10-18  Simon Josefsson  <jas@extundo.com>
9357
9358         * tests/test-md4.c: New file.
9359
9360         * modules/md4, modules/md4-tests: New files.
9361
9362 2005-10-18  Simon Josefsson  <jas@extundo.com>
9363
9364         * m4/md4.m4: New file.
9365
9366 2005-10-18  Simon Josefsson  <jas@extundo.com>
9367
9368         * lib/md4.h, lib/md4.c: New files, based on md5.?.
9369
9370 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
9371
9372         * gnulib-tool (func_create_testdir): Omit the second check whether
9373         BUILT_SOURCES in nonempty.
9374
9375 2005-10-17  Simon Josefsson  <jas@extundo.com>
9376
9377         * tests/test-rijndael.c: New file.
9378
9379 2005-10-17  Simon Josefsson  <jas@extundo.com>
9380
9381         * modules/sha1: Depend on stdint instead of md5.
9382
9383         * modules/md5: Depend on stdint, remove uint32_t.
9384
9385 2005-10-17  Simon Josefsson  <jas@extundo.com>
9386
9387         * modules/gc-sha1-tests: New file.
9388
9389         * tests/test-gc-sha1.c: New file.
9390
9391 2005-10-17  Simon Josefsson  <jas@extundo.com>
9392
9393         * m4/md5.m4: Remove call to uint32_t.m4.
9394
9395 2005-10-17  Simon Josefsson  <jas@extundo.com>
9396
9397         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
9398
9399         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
9400         md5.h.
9401
9402         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
9403
9404         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
9405
9406 2005-10-17  Simon Josefsson  <jas@extundo.com>
9407
9408         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
9409
9410 2005-10-17  Simon Josefsson  <jas@extundo.com>
9411
9412         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
9413
9414 2005-10-17  Simon Josefsson  <jas@extundo.com>
9415
9416         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
9417
9418         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
9419
9420 2005-10-17  Bruno Haible  <bruno@clisp.org>
9421
9422         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
9423         that it can also be used in a test.
9424
9425 2005-10-16  Bruno Haible  <bruno@clisp.org>
9426
9427         * gnulib-tool (func_emit_tests_Makefile_am): Also define
9428         TESTS_ENVIRONMENT, so that individual tests can augment it.
9429
9430         * gnulib-tool (func_create_testdir): Use an intermediate target for
9431         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
9432         macros, like $(ALLOCA_H), which cannot be passed through the command
9433         line.
9434
9435 2005-10-15  Simon Josefsson  <jas@extundo.com>
9436
9437         * modules/rijndael-tests: New file.
9438
9439         * modules/rijndael: New file.
9440
9441 2005-10-15  Simon Josefsson  <jas@extundo.com>
9442
9443         * m4/rijndael.m4: New file.
9444
9445 2005-10-15  Simon Josefsson  <jas@extundo.com>
9446
9447         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
9448
9449         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
9450
9451 2005-10-14  Simon Josefsson  <jas@extundo.com>
9452
9453         * tests/test-arcfour.c: New file.
9454
9455         * modules/arcfour, modules/arcfour-tests: New files.
9456
9457 2005-10-14  Simon Josefsson  <jas@extundo.com>
9458
9459         * m4/arcfour.m4: New file.
9460
9461 2005-10-14  Simon Josefsson  <jas@extundo.com>
9462
9463         * lib/arcfour.h, lib/arcfour.c: New files.
9464
9465 2005-10-14  Roland McGrath  <roland@redhat.com>
9466
9467         Import from libc.  [BZ #1331]
9468         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
9469         macro argument.
9470         Reported by Matej Vela <vela@debian.org>.
9471
9472 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9473
9474         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
9475         include <wchar.h>; no longer needed.
9476
9477 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9478
9479         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
9480
9481 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
9482         and  Ulrich Drepper  <drepper@redhat.com>
9483
9484         Import from libc.
9485         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
9486         instead of inline stream orientation test and two separate
9487         function calls.  Pay no attention to USE_IN_LIBIO.
9488
9489 2005-10-13  Simon Josefsson  <jas@extundo.com>
9490
9491         * modules/gc-hmac-md5-tests: New file.
9492
9493         * tests/test-gc-hmac-sha1.c: New file.
9494
9495         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
9496
9497         * modules/gc-hmac-md5-tests: New file.
9498
9499         * tests/test-gc-md5.c: New file.
9500
9501         * modules/gc-md5-tests: New file.
9502
9503 2005-10-13  Simon Josefsson  <jas@extundo.com>
9504
9505         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
9506         Move memory allocation outside of loop.
9507
9508 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
9509
9510         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
9511         intermediate directory is in a read-only file system.  Problem
9512         reported by Eric Blake.
9513
9514 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
9515
9516         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
9517
9518 2005-10-12  Simon Josefsson  <jas@extundo.com>
9519
9520         * tests/test-hmac-sha1.c: New file.
9521
9522         * modules/hmac-sha1-tests: New file.
9523
9524         * modules/hmac-sha1: New file.
9525
9526 2005-10-12  Simon Josefsson  <jas@extundo.com>
9527
9528         * modules/gc-sha1: New file.
9529
9530 2005-10-12  Simon Josefsson  <jas@extundo.com>
9531
9532         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
9533
9534         * tests/test-gc-pbkdf2-sha1.c: New file.
9535
9536 2005-10-12  Simon Josefsson  <jas@extundo.com>
9537
9538         * modules/gc-md5, modules/gc-hmac-md5: New files.
9539
9540         * modules/gc (Files): Remove md5, memxor and hmac files.
9541
9542 2005-10-12  Simon Josefsson  <jas@extundo.com>
9543
9544         * m4/gc-pbkdf2-sha1.m4: New file.
9545
9546         * m4/gc-hmac-sha1.m4: New file.
9547
9548         * m4/gc-sha1: New file.
9549
9550         * m4/hmac-sha1.m4: New file.
9551
9552 2005-10-12  Simon Josefsson  <jas@extundo.com>
9553
9554         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
9555
9556         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
9557
9558 2005-10-12  Simon Josefsson  <jas@extundo.com>
9559
9560         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
9561         suggested by Bruno Haible <bruno@clisp.org>.
9562
9563 2005-10-12  Simon Josefsson  <jas@extundo.com>
9564
9565         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
9566
9567 2005-10-12  Simon Josefsson  <jas@extundo.com>
9568
9569         * lib/gc-pbkdf2-sha1.c: New file.
9570
9571         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
9572
9573 2005-10-12  Simon Josefsson  <jas@extundo.com>
9574
9575         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
9576
9577         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
9578
9579 2005-10-12  Simon Josefsson  <jas@extundo.com>
9580
9581         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
9582         GC_USE_HMAC_MD5, respectively.
9583
9584         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
9585         (gc_md5): Fix typo.
9586
9587         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
9588
9589         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
9590
9591         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
9592
9593 2005-10-12  Bruno Haible  <bruno@clisp.org>
9594
9595         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
9596         Reported by Stepan Kasal <kasal@ucw.cz>.
9597
9598 2005-10-11  Simon Josefsson  <jas@extundo.com>
9599
9600         * tests/test-crc.c: New file.
9601
9602         * modules/crc, modules/crc-tests: New files.
9603
9604 2005-10-11  Simon Josefsson  <jas@extundo.com>
9605
9606         * m4/crc.m4: New file.
9607
9608 2005-10-11  Simon Josefsson  <jas@extundo.com>
9609
9610         * lib/gc.h: Add gc_hash and gc_hash_buffer.
9611
9612         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
9613
9614         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
9615
9616 2005-10-11  Simon Josefsson  <jas@extundo.com>
9617
9618         * lib/crc.h, lib/crc.c: New files.
9619
9620         * lib/gc.h (gc_hash_buffer): Add doc.
9621
9622 2005-10-11  Bruno Haible  <bruno@clisp.org>
9623
9624         * modules/c-strcasestr: New file.
9625         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
9626
9627 2005-10-11  Bruno Haible  <bruno@clisp.org>
9628
9629         * modules/c-strcase: New file.
9630         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
9631
9632 2005-10-11  Bruno Haible  <bruno@clisp.org>
9633
9634         * lib/strcasecmp.c: Include limits.h.
9635         (strcasecmp): Avoid integer overflow on exotic platforms.
9636         * lib/strncasecmp.c: Include limits.h.
9637         (strncasecmp): Avoid integer overflow on exotic platforms.
9638         Reported by Paul Eggert.
9639
9640 2005-10-11  Bruno Haible  <bruno@clisp.org>
9641
9642         * lib/c-strcasestr.h: New file, from GNU gettext.
9643         * lib/c-strcasestr.c: New file, from GNU gettext.
9644
9645 2005-10-11  Bruno Haible  <bruno@clisp.org>
9646
9647         * lib/c-strcase.h: New file, from GNU gettext.
9648         * lib/c-strcasecmp.c: New file, from GNU gettext.
9649         * lib/c-strncasecmp.c: New file, from GNU gettext.
9650
9651 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9652
9653         * modules/mempcpy (License): GPL -> LGPL.
9654         * modules/strchrnul (License): Likewise.
9655         * modules/sysexits (License): Likewise.
9656
9657 2005-10-08  Simon Josefsson  <jas@extundo.com>
9658
9659         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
9660
9661 2005-10-07  Simon Josefsson  <jas@extundo.com>
9662
9663         * m4/memxor.m4: Remove gl_C_RESTRICT call.
9664
9665 2005-10-06  Simon Josefsson  <jas@extundo.com>
9666
9667         * tests/test-hmac-md5.c: New file.
9668
9669         * modules/hmac-md5-tests: New file.
9670
9671         * modules/hmac-md5: New file.
9672
9673 2005-10-06  Simon Josefsson  <jas@extundo.com>
9674
9675         * m4/hmac-md5.m4: New file.
9676
9677         * m4/memxor.m4: Require gl_C_RESTRICT.
9678
9679 2005-10-06  Simon Josefsson  <jas@extundo.com>
9680
9681         * lib/memxor.c (memxor): Avoid casts and warnings.
9682
9683 2005-10-06  Simon Josefsson  <jas@extundo.com>
9684
9685         * lib/hmac-md5.c: New file.
9686
9687         * lib/hmac.h: New file.
9688
9689 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9690
9691         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
9692         promotes to int, not unsigned int, to catch the AIX 5.3
9693         compiler bug.
9694
9695 2005-10-05  Simon Josefsson  <jas@extundo.com>
9696
9697         * modules/memxor: New file.
9698
9699         * modules/iconv (Files): Move config.rpath to havelib, it is used
9700         there.
9701
9702         * modules/havelib (Files): Add config.rpath.
9703
9704 2005-10-05  Simon Josefsson  <jas@extundo.com>
9705
9706         * m4/memxor.m4: New file.
9707
9708 2005-10-05  Simon Josefsson  <jas@extundo.com>
9709
9710         * lib/memxor.c (memxor): Fix compiler error.
9711
9712         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
9713         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
9714
9715         * lib/memxor.h, lib/memxor.c: New files.
9716
9717         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
9718         we assume all systems have it, suggested by Jim Meyering
9719         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
9720         any systems lack sys/socket.h; mingw32 is known to lack it, but we
9721         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
9722         same reasons.
9723
9724 2005-10-05  Simon Josefsson  <jas@extundo.com>
9725
9726         * config/srclist.txt: Add glibc bug 1423 for md5.h.
9727
9728 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9729
9730         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
9731         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
9732         needed, since the source code now assumes these .h files.
9733
9734 2005-10-05  Derek Price  <derek@ximbiot.com>
9735
9736         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
9737
9738 2005-10-05  Bruno Haible  <bruno@clisp.org>
9739
9740         * modules/stdint (License): Change to LGPL.
9741
9742 2005-10-04  Simon Josefsson  <jas@extundo.com>
9743
9744         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
9745         D. Baushke" <mdb@gnu.org>.
9746
9747 2005-10-04  Bruno Haible  <bruno@clisp.org>
9748
9749         * lib/verify.h (verify_true): Provide alternative definition for C++.
9750
9751 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
9752
9753         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
9754         (SSIZE_MAX): New macro, if not already defined.
9755         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
9756         than 2 GiB.
9757
9758 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9759
9760         Sync from coreutils.
9761         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
9762         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
9763         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
9764         ULLONG_MAX doesn't work with 2.7.2.1.
9765
9766 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9767
9768         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
9769         From Ben Pfaff.
9770
9771         * modules/exclude (Depends-on): Depend on verify.
9772         * modules/strtoimax (Depends-on): Likewise.
9773         * modules/utimecmp (Depends-on): Likewise.
9774
9775 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
9776
9777         * lib/exclude.c: Include verify.h.
9778         (verify): Remove.  All callers changed to use verify.h's version.
9779         * lib/strtoimax.c: Likewise.
9780         * lib/utimecmp.c: Likewis.e
9781
9782         Sync from coreutils.
9783         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
9784         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
9785         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
9786         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
9787         bother returning ENOSYS if settimeofday or stime fails; just let
9788         them return whatever errno they want to return.
9789         * lib/utimens.c: Include unistd.h, for dup2.
9790         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
9791         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
9792
9793 2005-10-02  Jim Meyering  <jim@meyering.net>
9794
9795         Sync from coreutils.
9796         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
9797         from glibc-2.2.5 that fails for read-only files.
9798
9799 2005-10-02  Jim Meyering  <jim@meyering.net>
9800
9801         Sync from coreutils.
9802         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
9803         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
9804         `#if HAVE_CONFIG_H'.
9805         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
9806         Remove AT_FDCWD test.
9807         Do not consume the fd unless successful.
9808         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
9809         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
9810         block, so that we don't even try to compile it if settimeofday is
9811         available.  This works around a compilation failure on OSF1 V5.1,
9812         due to stime requiring a `long int*' while tv_sec is `int'.
9813
9814 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
9815
9816         Sync from coreutils.
9817         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
9818         against `yes', rather than just testing for nonempty.
9819
9820 2005-10-01  Simon Josefsson  <jas@extundo.com>
9821
9822         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
9823         and Darwin.
9824
9825         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
9826         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
9827         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
9828         freeaddrinfo and gai_strerror are declared by the POSIX headers.
9829         Check if struct addrinfo is declared.
9830
9831 2005-10-01  Simon Josefsson  <jas@extundo.com>
9832
9833         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
9834         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
9835         AI_* and EAI_* definitions.  Protect function declarations.
9836
9837 2005-10-01  Jim Meyering  <jim@meyering.net>
9838
9839         Sync from coreutils.
9840
9841         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
9842         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
9843         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
9844         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9845         in the inet and nsl libraries.  Required on Solaris 5.7.
9846
9847 2005-10-01  Jim Meyering  <jim@meyering.net>
9848
9849         Sync from coreutils.
9850         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
9851         in the inet and nsl libraries.  Required on Solaris 5.7.
9852
9853 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
9854
9855         * lib/getdelim.c (getdelim): Remove unused variables.
9856
9857 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9858
9859         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
9860         so that the code works even with ancient cpp.  Portability problem
9861         with GCC 2.7.2.1 reported by Thomas M.Ott.
9862
9863 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9864
9865         * modules/regex (Depends-on): Add strcase.
9866
9867         * modules/gethostname (Licence): Change from GPL to LGPL, since
9868         gethostname.c is a trivial implementation of a standard library
9869         function.
9870         * modules/poll (License): Change from GPL to LGPL, since it's
9871         derived from LGPL code.
9872
9873 2005-09-27  Jim Meyering  <jim@meyering.net>
9874
9875         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
9876         HAVE_CONFIG_H.
9877
9878         * lib/intprops.h (signed_type_or_expr__): Define.
9879         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
9880         for unsigned types.
9881
9882 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9883
9884         * lib/verify.h (verify_expr): Remove, replacing with:
9885         (verify_true): New macro that returns true instead of void.
9886         (verify_type__): Remove.
9887         (verify): Use verify_true rather than verify_type__.
9888
9889 2005-09-26  Bruno Haible  <bruno@clisp.org>
9890
9891         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
9892         is necessary.
9893         (lib_SOURCES): Remove mbchar.c.
9894         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
9895         (Files): Add m4/mbrtowc.m4.
9896         * modules/mbiter: Likewise.
9897         * modules/mbuiter: Likewise.
9898
9899 2005-09-26  Bruno Haible  <bruno@clisp.org>
9900
9901         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
9902         compile mbchar.c if they are not both present.
9903         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
9904         * m4/mbiter.m4 (gl_MBITER): Likewise.
9905         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
9906         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
9907         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
9908
9909 2005-09-25  Jim Meyering  <jim@meyering.net>
9910
9911         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
9912         also uses socklen_t.
9913
9914 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
9915
9916         * lib/utimens.c (ENOSYS): Define if not already defined.
9917         (futimens): Support having a null PATH if the file descriptor
9918         is nonnegative.
9919
9920         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
9921         Remove.
9922         (__attribute): Define to empty unless GCC 3.1 or later.
9923         This works around a core dump on OpenBSD 3.4, which has GCC
9924         2.95.3, which dumps core when given __attribute__(()).  It also
9925         simplifies other tests, since we really don't want to bother with
9926         worrying about which ancient version of GCC supported what.
9927         Original problem reported by Yoann Vandoorselaere, with part of
9928         the fix suggested by Derek Price.
9929
9930 2005-09-24  Jim Meyering  <jim@meyering.net>
9931
9932         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
9933         so we can once again use a positive bitfield width of 1 -- now we
9934         don't have to explain why we were using a bitfield width of 2.
9935
9936 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9937
9938         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
9939         and similarly for the other external symbols.  Problem reported
9940         by James Gallager.
9941
9942         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
9943         bug reported by Jim Meyering.
9944
9945         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
9946         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
9947         not needed, since socklen is a prerequisite module.
9948
9949 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
9950
9951         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
9952         Problem reported by Eric Blake.
9953         (getaddrinfo): Initialize se so that it's not garbage.
9954         Redo internal storage allocation so that it doesn't make unportable
9955         assumptions about alignment.
9956         Fix a memory leak.
9957
9958         * lib/utimens.c (futimens): Use futimesat if available.
9959         Prefer it to futimes since it doesn't have the futimes bug.
9960
9961         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
9962         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
9963         Instead, declare a function that returns a pointer to an array,
9964         and use verify_type__ to declare the size of the array.
9965         Problem and germ of a solution reported by Bruno Haible.
9966         (verify_type__): Use 2, not 1, for bitfield size, to avoid
9967         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
9968
9969 2005-09-23  Jim Meyering  <jim@meyering.net>
9970
9971         Sync from coreutils.
9972         Correct build failure (socklen_t not defined) on at least
9973         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
9974         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
9975
9976 2005-09-23  Jim Meyering  <jim@meyering.net>
9977
9978         * modules/getaddrinfo (Depends-on): Add socklen.
9979
9980 2005-09-23  Bruno Haible  <bruno@clisp.org>
9981
9982         * tests/test-verify.c: New file.
9983
9984 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
9985
9986         Sync from coreutils.
9987
9988         * modules/argmatch (Depends-on): Add verify.
9989         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
9990         unistd-safer.
9991         * modules/save-cwd (Depends-on): Likewise.
9992
9993         * modules/openat (Files): Add lib/openat-die.c.
9994         (Depends-on): Remove error, exitfail.
9995         Add dirname.
9996
9997         * modules/verify: New file.
9998         * MODULES.html.sh (Diagnostics <assert.h>): New section,
9999         with "verify" module.
10000
10001 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10002
10003         Sync from coreutils.
10004
10005         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
10006         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
10007         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
10008         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
10009         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
10010         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
10011         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
10012         Don't bother checking for string.h, stdlib.h, unistd.h.
10013         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
10014         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
10015         module's job.
10016         * m4/jm-macros.m4 (gl_MACROS): Likewise.
10017         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
10018
10019         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
10020         (gl_GETDATE): Use it.
10021
10022         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
10023
10024 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10025
10026         Sync from coreutils.
10027
10028         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
10029         stat-time.h.
10030         * lib/argmatch.h: Include verify.h
10031         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
10032         (ARGMATCH_ASSERT): Remove; unused.
10033         * lib/canonicalize.c: Assume STDC_HEADERS.
10034         * lib/exclude.c: Include "strcase.h".
10035         * lib/regex_internal.h [!defined _LIBC]: Likewise.
10036         * lib/getusershell.c: Include stdio--.h rather than stdio.h
10037         and stdio-safer.h.
10038         (getusershell): Call fopen, not fopen_safer.
10039         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
10040         Do not include unistd-safer.h.
10041         (save_cwd): Don't call fd_safer; no longer needed
10042         now that we include fcntl--.h.
10043
10044         * lib/getdate.y (relative_time): New type.
10045         (RELATIVE_TIME_0): New constant.
10046         (parser_control): Use relative_time instead of doing it ourselves.
10047         (%union): Add new relative_time rel member.
10048         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
10049         Now typeless.
10050         (relunit, relunit_snumber): Now of type rel.
10051         (zone, rel, relunit, get_date): Adjust to above changes.
10052
10053         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
10054         Do not include unistd-safer.h.
10055         (getloadavg): Don't call fd_safer; no longer needed
10056         now that we include fcntl--.h.
10057
10058         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
10059         (make_dir_parents): Treat ENOSYS like EEXIST.
10060
10061         Improve quality of diagnostics on restore_cwd failure.
10062         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
10063         (make_dir_parents): Last arg is now int * (for errno), not bool *.
10064         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
10065         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
10066         each time through the loop.  Do not diagnose restore_cwd failure;
10067         that is the caller's job (and perhaps the caller does not care).
10068
10069         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
10070         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
10071         If the file already exists but is not a directory, don't bother
10072         to try to make its parents.
10073         Close potential file descriptor leak if we can't chdir("/") (!).
10074         Don't always return true if chdir($PWD) fails; return true only
10075         if the requested action was done successfully (except for the
10076         chdir($PWD)).
10077         Don't log final directory unless we actually made it.
10078         Refactor to avoid duplicate code to fix up permissions.
10079         Don't attempt to fix up parent permissions if chdir($PWD) fails.
10080
10081         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
10082         to make it a bit faster and (I hope) clearer.
10083         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
10084         Fix bug in formats like %2N.
10085
10086         * lib/verify.h: New file.
10087
10088 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
10089
10090         Sync from coreutils.
10091         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
10092
10093 2005-09-22  Jim Meyering  <jim@meyering.net>
10094
10095         Sync from coreutils.
10096
10097         * m4/lstat.m4 (gl_FUNC_LSTAT):
10098         Use AC_LIBSOURCES to require lstat.c and lstat.h.
10099         Remove obsolete comment.
10100         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
10101         * m4/xstrtod.m4: Likewise.
10102
10103         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
10104
10105 2005-09-22  Jim Meyering  <jim@meyering.net>
10106
10107         Sync from coreutils.
10108
10109         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
10110
10111         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
10112         the .tm_year member, since otherwise gcc-4.0 would now warn about
10113         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
10114
10115         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
10116         order to avoid an unsuppressible warning from gcc on 64-bit systems.
10117
10118         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
10119         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
10120         when run in a time zone for which daylight savings time is in effect
10121         for the starting date.
10122
10123         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
10124         stop us from restricting permissions of just-created absolute-named
10125         directories.
10126         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
10127         to restore initial working directory.
10128         * lib/mkdir-p.c (make_dir_parents): New parameter:
10129         different_working_dir, to tell caller if/when we change the working
10130         directory and are unable to return to the initial one.
10131         * lib/mkdir-p.h (make_dir_parents): Update prototype.
10132         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
10133         `return false'.  This fixes a bug introduced on 2004-07-30.
10134
10135         * lib/openat.c (fdopendir): Be sure to close the supplied
10136         file descriptor before returning.  This makes our replacement
10137         implementation a little closer to Solaris's, where fdopendir
10138         ties the file descriptor to the returned DIR* pointer.
10139         * lib/openat.c (unlinkat): New function.
10140         * lib/openat.h (unlinkat): Add prototype.
10141         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
10142         (openat_restore_fail): Rename from openat_restore_die.
10143         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
10144
10145         Provide an alternative to exiting immediately upon save_cwd or
10146         restore_cwd failure.  Now, an application can arrange e.g.,
10147         to perform a longjump in that case.
10148         * lib/openat.c: Include dirname.h.
10149         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
10150         (rpl_openat, fdopendir, fstatat): Call openat_save_die
10151         and openat_restore_die rather than calling error directly.
10152         Don't include "error.h" or "exitfail.h"; they're no longer needed.
10153
10154         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
10155         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
10156         define.
10157
10158         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
10159         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
10160                             int utc, int nanoseconds);
10161         Background:
10162         date should not have to allocate a megabyte of virtual memory to
10163         handle a format argument like +%1048575T.  When implemented with
10164         strftime, it must allocate such a buffer, use strftime to fill it
10165         in, print it, then free it.
10166         With fprintftime, it simply prints everything and exits.
10167         With no need for memory allocation, that's one fewer way to fail.
10168         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
10169         optional field width, not before, so we accept %9:z, not %:9z.
10170         (my_strftime): Be sure to use L_('x') for literals.
10171
10172         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
10173         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
10174         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
10175         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
10176         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
10177         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
10178         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
10179         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
10180         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
10181         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
10182         * lib/xgethostname.c, lib/xreadlink.c:
10183         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
10184
10185         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
10186         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
10187         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
10188         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
10189         and don't include <sys/file.h>).
10190
10191 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
10192
10193         Sync from coreutils.
10194
10195         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
10196         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
10197         [!LDAV_DONE]: Avoid unused variable warning.
10198
10199 2005-09-21  Bruno Haible  <bruno@clisp.org>
10200
10201         * lib/unicodeio.h (unicode_to_mb): New declaration.
10202
10203 2005-09-20  Derek Price  <derek@ximbiot.com>
10204
10205         * lib/getaddrinfo.c: Don't include <netdb.h> included from
10206         getaddrinfo.h.
10207
10208 2005-09-20  Bruno Haible  <bruno@clisp.org>
10209
10210         * gnulib-tool: Remove trailing slashes from the values specified for
10211         --source-base, --m4-base, --tests-base, --aux-dir.
10212         Suggested by Simon Josefsson <jas@extundo.com>.
10213
10214 2005-09-20  Bruno Haible  <bruno@clisp.org>
10215
10216         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
10217         func_modules_to_filelist, func_import, func_create_testdir): Make all
10218         sorting results locale-independent, so that gnulib-cache.m4 doesn't
10219         change when gnulib-tool is invoked in a different locale.
10220
10221 2005-09-19  Simon Josefsson  <jas@extundo.com>
10222
10223         * m4/socklen.m4: Fix typo.
10224
10225 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10226
10227         Use a consistent style for including <config.h>.
10228         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
10229         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
10230         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
10231         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
10232         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
10233         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
10234         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
10235         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
10236         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
10237         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
10238         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
10239         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
10240         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
10241         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
10242         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
10243         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
10244         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
10245         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
10246         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
10247         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
10248         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
10249         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
10250         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
10251         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
10252         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
10253         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
10254         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
10255         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
10256         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
10257         lib/xstrtoumax.c, lib/yesno.c:
10258         Standardize inclusion of config.h.
10259         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
10260         lib/inttostr.h:  Removed inclusion of config.h from header files.
10261         * lib/inttostr.c:  Adjusted in-tree users.
10262         * lib/timespec.h: Remove superfluous warning to include config.h.
10263         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
10264         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
10265         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
10266         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
10267         config.h with HAVE_CONFIG_H.
10268
10269 2005-09-19  Jim Meyering  <jim@meyering.net>
10270
10271         * modules/pathmax (License): Change to LGPL.
10272
10273 2005-09-19  Derek Price  <derek@ximbiot.com>
10274
10275         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
10276
10277 2005-09-19  Bruno Haible  <bruno@clisp.org>
10278
10279         * gnulib-tool (import): Provide default for --tests-base.
10280
10281 2005-09-19  Bruno Haible  <bruno@clisp.org>
10282
10283         * doc/quote.texi: New file, extracted from gnulib.texi.
10284         * doc/ctime.texi: New file, extracted from gnulib.texi.
10285         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
10286         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
10287         * doc/gnulib.texi: Include them.
10288
10289 2005-09-18  Bruno Haible  <bruno@clisp.org>
10290
10291         Portability fix.
10292         * gnulib-tool (func_readlink): New function.
10293         (func_ln_if_changed): Use it.
10294
10295 2005-09-18  Bruno Haible  <bruno@clisp.org>
10296
10297         * gnulib-tool: Support --with-tests also with --import.
10298         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
10299         (func_import): Use variables $testsbase and $inctests. Emit a
10300         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
10301         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
10302         SUBDIRS += $testsdir.
10303         (func_create_testdir): Update.
10304
10305 2005-09-18  Bruno Haible  <bruno@clisp.org>
10306
10307         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
10308         instead of $dry_run.
10309         (func_cp_if_changed, func_mv_if_changed): Remove functions.
10310         (func_ln_if_changed): Don't handle dry-run here.
10311         (func_import): In dry-run mode, detect more precisely which actions
10312         would be performed, and don't use "...ing" verbs.
10313
10314 2005-09-18  Bruno Haible  <bruno@clisp.org>
10315
10316         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
10317         (func_import): Use join on two temporary files instead of three nested
10318         loops, in order to determine which files are new or old.
10319
10320 2005-09-18  Bruno Haible  <bruno@clisp.org>
10321
10322         * gnulib-tool (func_import): Comment out code that spits out the
10323         new files with --dry-run.
10324
10325 2005-09-18  Bruno Haible  <bruno@clisp.org>
10326
10327         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
10328
10329 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10330
10331         * lib/stat-time.h: New file.
10332         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
10333         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
10334         in a different way.
10335         (timespec_cmp): New function.
10336         * lib/utimecmp.c: Include stat-time.h.
10337         (SYSCALL_RESOLUTION): Depend on whether various struct stat
10338         members exist, not on the obsolescent ST_MTIM_NSEC.
10339         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
10340
10341 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10342
10343         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
10344
10345 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
10346
10347         * MODULES.html.sh (File system functions): Add stat-time.
10348         * modules/stat-time: New file.
10349         * modules/timespec (Files): Remove m4/st_mtim.m4; this
10350         is now done in a different way, by the stat-time module.
10351         * modules/utimecmp (Depends-on): Add stat-time.
10352
10353 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10354
10355         * m4/st_mtim.m4: Remove.  Superseded by...
10356         * m4/stat-time.m4: New file.
10357         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
10358         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
10359
10360 2005-09-15  Derek Price  <derek@ximbiot.com>
10361
10362         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
10363
10364 2005-09-15  Derek Price  <derek@ximbiot.com>
10365
10366         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
10367         * lib/regex_internal.c: Ditto, using this...
10368         (__GNUC_PREREQ): ...new macro.
10369         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
10370         using...
10371         (__GNUC_PREREQ): ...this new macro.
10372
10373         * lib/strstr.h: Include string.h. Define strstr as a macro here.
10374
10375 2005-09-15  Derek Price  <derek@ximbiot.com>
10376             Paul Eggert  <eggert@cs.ucla.edu>
10377
10378         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
10379         changes, consolidating in...
10380         * lib/regex_internal.h: ...this file.
10381
10382 2005-09-13  Jim Meyering  <jim@meyering.net>
10383
10384         * lib/canon-host.c: Filter through gnu indent and reword comments
10385         slightly.
10386         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
10387
10388 2005-09-13  Derek Price  <derek@ximbiot.com>
10389
10390         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
10391         failure.
10392         Reported by Jim Meyering  <jim@meyering.net>.
10393
10394 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10395
10396         * lib/base64.c: Typo.
10397         (base64_encode): Put b64str in initialized data section.
10398
10399 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
10400
10401         Merge glibc and coreutils changes into gnulib, plus a few
10402         extra fixes.
10403         * lib/md5.c: Use #error rather than a string.
10404         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
10405         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
10406         (__attribute__): Define to empty for non recent-GCC.
10407         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
10408         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
10409         Renamed from their non-__ counterparts, with new macros replacing
10410         them if not _LIBC.  Add __THROW attribute.
10411         (rol): Remove.
10412         (struct md5_ctx): Align buffer if using GCC.
10413         * lib/sha1.h (struct sha1_ctx): Likewise.
10414         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
10415         The old name was backwards.
10416         (NOTSWAP): Remove; not used.
10417         (rol): New macro, moved here from md5.h.
10418         (sha1_process_block): Remove a FIXME that doesn't make sense.
10419
10420 2005-09-12  Derek Price  <derek@ximbiot.com>
10421
10422         Return usable errors from canon-host.
10423         * lib/canon-host.h: New file.
10424         * lib/canon-host.c (canon_host): Wrap...
10425         (canon_host_r): ...this new function, which now relies exclusively on
10426         getaddrinfo.
10427         (ch_strerror): New function.
10428         (last_cherror): New global.
10429         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
10430         interface.
10431         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
10432         void *.
10433         (freeaddrinfo): Free ai->ai_canonname when set.
10434
10435 2005-09-12  Derek Price  <derek@ximbiot.com>
10436
10437         Make canon-host require getaddrinfo.
10438         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
10439         AC_LIBSOURCE canon-host.h.  Call...
10440         (gl_PREREQ_CANON_HOST): ...this new function, which requires
10441         gl_GETADDRINFO.
10442         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
10443
10444 2005-09-12  Derek Price  <derek@ximbiot.com>
10445
10446         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
10447         LGPL.
10448         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
10449
10450 2005-09-12  Derek Price  <derek@ximbiot.com>
10451
10452         * lib/gai_strerror.c: Include config.h when available.  Include
10453         getaddrinfo.h before other headers to test interface.
10454         Reported by Larry Jones <lawrence.jones@ugs.com>.
10455
10456 2005-09-12  Derek Price  <derek@ximbiot.com>
10457             Paul Eggert  <eggert@cs.ucla.edu>
10458
10459         * modules/glob (Files): Add glob-libc.h.
10460
10461 2005-09-12  Derek Price  <derek@ximbiot.com>
10462             Paul Eggert  <eggert@cs.ucla.edu>
10463
10464         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
10465         glob_.h, glob-libc.h.
10466         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
10467
10468 2005-09-12  Derek Price  <derek@ximbiot.com>
10469             Paul Eggert  <eggert@cs.ucla.edu>
10470
10471         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
10472         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
10473         protecting things that should be done only in gnulib contexts.
10474         * lib/glob_.h: New file, containing only the glob things needed for
10475         gnulib.
10476         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
10477         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
10478         (glob, globfree, glob_pattern_p): Now defined simply in terms of
10479         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
10480         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
10481         and to respect the namespace rules better.
10482
10483 2005-09-08  Simon Josefsson  <jas@extundo.com>
10484
10485         * modules/socklen: New file.
10486
10487 2005-09-08  Simon Josefsson  <jas@extundo.com>
10488
10489         * m4/socklen.m4: New file.
10490
10491 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10492
10493         * modules/utimens (Files): Add m4/utimbuf.m4, since
10494         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
10495         Reported by Sergey Poznyakoff.
10496
10497 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10498
10499         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
10500         definitions, since that's the preferred style in glibc.
10501         Fix a minor spacing issue, and update copyright notice to match
10502         glibc's.
10503
10504 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10505
10506         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
10507
10508 2005-09-06  Simon Josefsson  <jas@extundo.com>
10509
10510         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
10511         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
10512
10513 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10514
10515         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
10516         warning.
10517
10518 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10519
10520         * config/srclist.txt: Add glibc bug 1302.
10521
10522 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
10523
10524         Change bitset word type from unsigned int to unsigned long int,
10525         as this has better performance on typical 64-bit hosts.
10526         Port bitset code to hosts with unusual word sizes.
10527         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
10528         (build_collating_symbol):
10529         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
10530         argument is a bitset.  This is merely a style issue, but it makes
10531         it clearer that an entire array is expected.
10532         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
10533         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
10534         Port to the case where bitset_word is not the same as unsigned int.
10535         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10536         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
10537         Likewise.
10538         * lib/regexec.c (check_dst_limits_calc_pos_1,
10539         check_subexp_matching_top):
10540         (build_trtable, group_nodes_into_DFAstates):
10541         Likewise.
10542         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
10543         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
10544         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
10545         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
10546         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
10547         * lib/regcomp.c (optimize_subexps, lower_subexp):
10548         Work even if bitset_word has holes in its bitwise representation.
10549         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
10550         * lib/regexec.c (check_dst_limits_calc_pos_1,
10551         check_subexp_matching_top):
10552         Likewise.
10553         * lib/regex_internal.c (re_string_reconstruct):
10554         Don't assume UCHAR_MAX == 255.
10555         * lib/regex_internal.h (bitset_set_all): Likewise.
10556         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
10557         All uses changed.
10558         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
10559         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
10560         All uses changed.
10561         (BITSET_WORD_MAX): New macro.
10562         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
10563         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
10564         (bitset_empty, bitset_copy):
10565         Prefer sizeof (bitset) to multiplying it out ourselves.
10566         (bitset_not_merge): Remove; unused.
10567         (bitset_contain): Return bool, not unsigned int with one bit on.
10568         All callers changed.
10569         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
10570         alignment than re_node_set; do this by defining a new internal
10571         type struct dests_alloc and using it to allocate memory.
10572
10573 2005-09-05  Bruno Haible  <bruno@clisp.org>
10574
10575         * gnulib-tool (func_import): Fix comparison in handling of symbolic
10576         links.
10577
10578 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
10579
10580         * modules/size_max (Makefile.am): Add size_max.h
10581
10582 2005-09-04  Derek Price  <derek@ximbiot.com>
10583
10584         * gnulib-tool (func_import): Fix reversed $symbolic logic.
10585
10586 2005-09-03  Simon Josefsson  <jas@extundo.com>
10587
10588         * gnulib-tool: Fix typo.
10589
10590 2005-09-03  Simon Josefsson  <jas@extundo.com>
10591
10592         * config/srclist.txt: Add glibc bug 1293.
10593
10594 2005-09-03  Derek Price  <derek@ximbiot.com>
10595
10596         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
10597         From Larry Jones <lawrence.jones@ugs.com>.
10598
10599 2005-09-02  Simon Josefsson  <jas@extundo.com>
10600
10601         * modules/socklen: New file.
10602
10603 2005-09-02  Simon Josefsson  <jas@extundo.com>
10604
10605         * modules/havelib: New module.
10606
10607         * modules/gettext, modules/iconv, modules/lock, modules/readline:
10608         Use havelib.
10609
10610 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10611
10612         Check for arithmetic overflow when calculating sizes, to prevent
10613         some buffer-overflow issues.  These patches are conservative, in the
10614         sense that when I couldn't determine whether an overflow was possible,
10615         I inserted a run-time check.
10616         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
10617         macros.
10618         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
10619         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
10620         (re_xnrealloc, re_x2nrealloc): New inline functions.
10621         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
10622         parse_bracket_exp):
10623         (build_equiv_class, build_charclass): Check for arithmetic overflow
10624         in size expression calculations.
10625         * lib/regex_internal.c (re_string_realloc_buffers):
10626         (build_wcs_upper_buffer, re_node_set_add_intersect):
10627         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
10628         (re_dfa_add_node, register_state): Likewise.
10629         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
10630         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
10631         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
10632         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
10633
10634 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
10635
10636         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
10637         m4/ulonglong.m4.  Problem reported by Martin Lambers.
10638
10639 2005-09-02  Bruno Haible  <bruno@clisp.org>
10640
10641         Support for lib vs. lib64 distinction on biarch platforms.
10642         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
10643         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
10644         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
10645
10646 2005-09-02  Bruno Haible  <bruno@clisp.org>
10647
10648         * gnulib-tool (import): In the other first-use case, provide defaults
10649         as well.
10650
10651 2005-09-02  Bruno Haible  <bruno@clisp.org>
10652
10653         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
10654         patches not yet found in the latest gettext release.
10655
10656 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10657
10658         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
10659         to avoid a collision with bits/local_lim.h in glibc.
10660         All uses changed.  Problem reported by Dmitry V. Levin in
10661         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
10662
10663         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
10664         bugs in int versus size_t comparisons.
10665         (re_string_context_at): Fix bug where the code assumed that
10666         Idx is signed.
10667
10668         Use bool where appropriate.
10669         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
10670         All callers changed.
10671         (calc_eclosure_iter): Likewise, for ROOT arg.
10672         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
10673         (build_charclass_op): Likewise, for NON_MATCH arg.
10674         * lib/regex_internal.c (re_string_allocate, re_string_construct):
10675         (re_string_construct_common): Likewise, for ICASE arg.
10676         * lib/regexec.c (re_search_2_stub, re_search_stub):
10677         Likewise, for RET_LEN arg.
10678         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
10679         (set_regs): Likewise, for FL_BACKTRACK arg.
10680         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
10681         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
10682         (calc_eclosure_iter, parse_bracket_exp):
10683         Use bool for internal variables that are booleans.
10684         * lib/regexec.c (re_search_internal, check_matching,
10685         proceed_next_node):
10686         (set_regs, build_sifted_states, sift_states_bkref):
10687         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
10688         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
10689         (find_collation_sequence_value):
10690         Likewise.
10691         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
10692         (re_node_set_compare):
10693         Return bool, not int. All callers changed.
10694         * lib/regexec.c (check_halt_node_context, check_dst_limits):
10695         (build_trtable, check_node_accept): Likewise.
10696         * lib/regex_internal.h: Include stdbool.h.
10697
10698         Fix bugs uncovered when converting to bool.
10699         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
10700         failure instead of charging ahead blindly.
10701         * lib/regex_internal.c (register_state): Likewise.
10702         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
10703         for freeing internal storage.
10704         (group_nodes_into_DFA_states): Use unsigned int, not int, for
10705         bitset pieces used as boolean, to avoid undefined behavior
10706         on hosts that do int overflow checking.
10707
10708 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10709
10710         * config/srclist.txt: Add glibc bugs 1285-1287.
10711
10712 2005-09-01  Jim Meyering  <jim@meyering.net>
10713
10714         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
10715         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
10716         Require gl_STAT_MACROS, too.
10717
10718 2005-09-01  Bruno Haible  <bruno@clisp.org>
10719
10720         * gnulib-tool (import): In the first-use case, provide defaults.
10721
10722 2005-09-01  Bruno Haible  <bruno@clisp.org>
10723
10724         * gnulib-tool (func_import): Remove the .tmp files.
10725
10726 2005-09-01  Bruno Haible  <bruno@clisp.org>
10727
10728         * gnulib-tool (func_import): Fix handling of symbolic links.
10729
10730 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10731
10732         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
10733         old glibc regex code mishandles strings longer than 2**31 bytes.
10734         This patch fixes this when the regex code is used in gnulib
10735         (i.e., outside glibc).
10736
10737         This patch should not affect the use of the regex code inside
10738         glibc.  No doubt this problem also needs to be handled for glibc
10739         as well, but the result will be an incompatible change to the
10740         glibc ABI, and the old ABI will have to be supported too.  That
10741         can be the the subject for another patch.
10742
10743         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
10744         governing whether the rest of this patch is active.  By default,
10745         the macro is disabled and the patch has no effect.
10746         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
10747         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
10748         (struct re_pattern_buffer, re_search, re_search_2, re_match):
10749         (re_match_2, re_set_registers): Use the new types.
10750         * lib/regex_internal.h (Idx, re_hashval_t): New types.
10751         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
10752         New macros.
10753         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
10754         (re_string_context_at, bin_tree_t, re_dfastate_t):
10755         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
10756         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
10757         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
10758         (re_string_char_size_at, re_string_wchar_at):
10759         (re_string_elem_size_at):
10760         Use the new types and macros to port to 64-bit hosts.
10761         Use unsigned types for internal values, so that the code
10762         mostly works even for arrays larger than SSIZE_MAX.
10763         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
10764         (search_duplicated_node, calc_eclosure_iter, fetch_number):
10765         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
10766         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
10767         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
10768         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
10769         (calc_inveclosure, parse_dup_op, build_range_exp):
10770         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
10771         (fetch_number, create_token_tree, mark_opt_subexp):
10772         Likewise.
10773         * lib/regex_internal.c (re_string_construct_common,
10774         create_ci_newstate):
10775         (create_cd_newstate, re_string_allocate, re_string_construct):
10776         (re_string_realloc_buffers, build_wcs_upper_buffer):
10777         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
10778         (re_string_reconstruct, re_string_peek_byte_case):
10779         (re_string_fetch_byte_case, re_string_context_at):
10780         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
10781         (re_node_set_init_copy, re_node_set_add_intersect):
10782         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
10783         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
10784         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
10785         (re_acquire_state, re_acquire_state_context, register_state):
10786         Likewise.
10787         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
10788         search_cur_bkref_entry):
10789         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
10790         (re_search_internal, re_search_2_stub, re_search_stub)
10791         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
10792         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
10793         (update_cur_sifted_state, check_dst_limits):
10794         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10795         (check_subexp_limits, sift_states_bkref, merge_state_array):
10796         (check_subexp_matching_top, get_subexp, get_subexp_sub):
10797         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
10798         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
10799         (expand_bkref_cache, check_node_accept_bytes):
10800         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
10801         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
10802         (acquire_init_state_context, check_halt_node_context):
10803         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
10804         (sift_states_backward, clean_state_log_if_needed):
10805         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
10806         (find_recover_state, transit_state_sb, transit_state_mb):
10807         (transit_state_bkref, build_trtable, match_ctx_clean):
10808         Likewise.
10809         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
10810         to work around an assumption that REG_MISSING is negative.
10811
10812         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
10813         (seek_collating_symbol_entry) [defined _LIBC]:
10814         (lookup_collation_sequence_value) [defined _LIBC]:
10815         (build_range_exp, build_collating_symbol) [defined _LIBC]:
10816         Use prototypes rather than old-style function definitions.
10817         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
10818         (transit_state_sb) [0]:
10819         (find_collation_sequence_value) [defined _LIBC]: Likewise.
10820
10821         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
10822         rm_eo.
10823
10824         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
10825         (optimize_subexps, lower_subexp):
10826         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
10827         since the signed shift might overflow.  Use 1u<<31 instead.
10828         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
10829         Likewise.
10830         * lib/regexec.c (check_dst_limits_calc_pos_1,
10831         check_subexp_matching_top): Likewise.
10832
10833         * lib/regcomp.c (optimize_subexps, lower_subexp):
10834         Use CHAR_BIT rather than 8, for clarity.
10835         * lib/regexec.c (check_dst_limits_calc_pos_1):
10836         (check_subexp_matching_top): Likewise.
10837         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
10838         have to worry about portability issues when shifting it left.
10839         Remove no-longer-needed test for table_size > 0.
10840         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
10841         in a word, as the resulting behavior is undefined.
10842         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
10843         in one case, a <= should have been an <, and in another case the
10844         whole test was missing.
10845         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
10846         the standard name CHAR_BIT.
10847         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
10848         this is not true on one's complement and signed-magnitude hosts.
10849
10850         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
10851         next_last_offset.
10852         (struct re_dfa_t): Remove unused member states_alloc.
10853         * lib/regcomp.c (init_dfa): Don't initialize unused members.
10854
10855 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10856
10857         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
10858         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
10859         and large-file glibc and in 32-bit large-file Solaris.
10860
10861 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10862
10863         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
10864         lengths fit in regoff_t; this isn't true if regoff_t is the same
10865         width as size_t.
10866         * lib/regex.c (re_search_internal): 5th arg is LAST_START
10867         (= START + RANGE) instead of RANGE.  This avoids overflow
10868         problems when regoff_t is the same width as size_t.
10869         All callers changed.
10870         (re_search_2_stub): Check for overflow when adding the
10871         sizes of the two strings.
10872         (re_search_stub): Check for overflow when adding START
10873         to RANGE; if it occurs, substitute the extreme value.
10874
10875 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10876
10877         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
10878
10879 2005-08-31  Jim Meyering  <jim@meyering.net>
10880
10881         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
10882         a pointer-to-const.
10883         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
10884         (register_state): Likewise.
10885         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
10886         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
10887         (group_nodes_into_DFAstates): Likewise.
10888
10889 2005-08-31  Jim Meyering  <jim@meyering.net>
10890
10891         * check-module: Add a FIXME comment.
10892
10893 2005-08-31  Eric Blake  <ebb9@byu.net>
10894
10895         * modules/unistd-safer (Files): Add unistd--.h.
10896         * modules/stdio-safer (Files): Add stdio--.h.
10897
10898 2005-08-31  Derek Price  <derek@ximbiot.com>
10899
10900         * lib/getdelim.c (getdelim): Return EOF on EOF.
10901         Reported by Larry Jones <lawrence.jones@ugs.com>.
10902
10903 2005-08-31  Bruno Haible  <bruno@clisp.org>
10904
10905         Avoid unnecessary diffs in the generated lib/Makefile.am.
10906         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
10907         the generated files.
10908         (func_import): Don't set cmd.
10909
10910 2005-08-31  Bruno Haible  <bruno@clisp.org>
10911
10912         * lib/strstr.c: Include <stddef.h>, for NULL.
10913         * lib/strcasestr.c: Likewise.
10914         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10915
10916 2005-08-31  Bruno Haible  <bruno@clisp.org>
10917
10918         * gnulib-tool: New option --macro-prefix.
10919         (func_import): Use macro_prefix.
10920         (import): Handle option --macro-prefix.
10921
10922 2005-08-31  Bruno Haible  <bruno@clisp.org>
10923
10924         * gnulib-tool (import): Rename most ac_* variables to cached_*.
10925         Also use new variables cached_lgpl, cached_libtool.
10926
10927 2005-08-31  Bruno Haible  <bruno@clisp.org>
10928
10929         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
10930         always instantiating them.
10931
10932 2005-08-31  Bruno Haible  <bruno@clisp.org>
10933
10934         * gnulib-tool (func_import): Read the previous cached settings
10935         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
10936         earlier added by gnulib but are now dropped. Warn when a gnulib file
10937         overwrites a non-gnulib file.
10938
10939 2005-08-31  Bruno Haible  <bruno@clisp.org>
10940
10941         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
10942         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
10943         projects that don't keep autogenerated files in CVS. Put into
10944         actioncmd only the specified modules, not the transitive closure.
10945
10946 2005-08-31  Bruno Haible  <bruno@clisp.org>
10947
10948         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
10949         Create directories that shall be filled.
10950         (import): Don't look for gl_* macros in configure.ac. Recurse across
10951         all directories containing a gnulib-cache.m4 files, if meaningful.
10952
10953 2005-08-31  Bruno Haible  <bruno@clisp.org>
10954
10955         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
10956         (import): Set seen_libtool when we see gl_LIBTOOL.
10957
10958 2005-08-31  Bruno Haible  <bruno@clisp.org>
10959
10960         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
10961         declaration macro definitions from generated gnulib.m4.
10962
10963 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
10964
10965         * lib/iconvme.h: Add prototype for iconv_alloc.
10966
10967 2005-08-29  Simon Josefsson  <jas@extundo.com>
10968
10969         * lib/iconvme.c: Fix errno.
10970
10971 2005-08-29  Bruno Haible  <bruno@clisp.org>
10972
10973         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
10974         that it works when the directory contains spaces.
10975
10976 2005-08-29  Bruno Haible  <bruno@clisp.org>
10977
10978         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
10979
10980 2005-08-29  Bruno Haible  <bruno@clisp.org>
10981
10982         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
10983         Emit more advice.
10984
10985 2005-08-29  Bruno Haible  <bruno@clisp.org>
10986         and Stepan Kasal  <kasal@ucw.cz>
10987
10988         * check-module: If more parameters are given, check each of them
10989         separately; add more exceptions, as noted by Jim Meyering.
10990         (check_module): New procedure.
10991         (%exempt_header): Now contains all exceptions.
10992
10993 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
10994
10995         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
10996
10997 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
10998
10999         * lib/iconvme.c: Split iconv_string into iconv_alloc.
11000
11001 2005-08-28  Bruno Haible  <bruno@clisp.org>
11002
11003         * m4/gnulib-tool.m4: New file.
11004
11005 2005-08-27  Jim Meyering  <jim@meyering.net>
11006
11007         * modules/unistd-safer (Files): Add pipe-safer.c.
11008         * modules/fcntl-safer (Files): Add creat-safer.c.
11009
11010 2005-08-27  Jim Meyering  <jim@meyering.net>
11011
11012         * m4/stdlib-safer.m4: New file.  From coreutils.
11013         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
11014         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
11015         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
11016         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
11017         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
11018
11019 2005-08-27  Jim Meyering  <jim@meyering.net>
11020
11021         * lib/fopen-safer.c: Merge minor changes from coreutils.
11022         * lib/dup-safer.c: Likewise.
11023         * lib/fd-safer.c: Likewise.
11024
11025         Merge from coreutils.
11026         * lib/stdio--.h: New file.
11027         * lib/stdlib--.h: New file.
11028         * lib/mkstemp-safer.c: New file.
11029
11030         GNU tar needs these.
11031         * lib/pipe-safer.c: New file.
11032         * lib/creat-safer.c: New file.
11033         * lib/fcntl--.h (creat): Define to creat_safer.
11034         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
11035         * lib/unistd--.h (pipe): Define to pipe_safer.
11036         * lib/unistd-safer.h: Declare pipe_safer.
11037
11038 2005-08-26  Simon Josefsson  <jas@extundo.com>
11039
11040         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
11041         Haible <bruno@clisp.org>.
11042
11043 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
11044
11045         * lib/regex_internal.h: Remove all references to
11046         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
11047         or better.
11048         (bitset_not, bitset_merge, bitset_not_merge):
11049         (bitset_mask, re_string_allocate, re_string_construct):
11050         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
11051         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
11052         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
11053         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
11054         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11055         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11056         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
11057         (re_acquire_state_context):
11058         Remove unnecessary forward decls.
11059         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
11060         Put __attribute at function definition,
11061         now that the function decl has been removed.
11062         * lib/regex_internal.c (re_string_peek_byte_case):
11063         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
11064         Likewise.
11065
11066 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
11067
11068         * m4/regex.m4: Add AC_PREREQ(2.50).
11069         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
11070
11071 2005-08-25  Simon Josefsson  <jas@extundo.com>
11072
11073         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
11074         __fsetlocking.
11075
11076 2005-08-25  Simon Josefsson  <jas@extundo.com>
11077
11078         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
11079         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
11080         GLIBC specific code.
11081
11082 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11083
11084         Make regex safe for g++.  This fixes one real bug (an "err"
11085         that should have been "*err").  g++ problem reported by
11086         Sam Steingold.
11087         * lib/regex_internal.h (re_calloc): New macro, consistent with
11088         re_malloc etc.  All callers of calloc changed to use re_calloc.
11089         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
11090         not int.  All callers changed.
11091         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
11092         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
11093         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
11094         (find_recover_state): Change "err" to "*err"; this fixes what
11095         appears to be a real bug.
11096         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
11097         versus int.
11098
11099 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11100
11101         * modules/regex (Depends-on): Add malloc, since the code
11102         assumes that !malloc(0) means failure.
11103
11104 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11105
11106         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
11107
11108         alloca modernization/simplification for regex.
11109         * lib/regex.c: Remove portability cruft for alloca.  This no longer
11110         needs to be at the start of the file, and can be moved into
11111         regex_internal.h and simplified.
11112         * lib/regex_internal.h: Include <alloca.h>.
11113         (__libc_use_alloca) [!defined _LIBC]: New macro.
11114         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
11115         now works outside glibc.
11116
11117 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11118
11119         * config/srclist.txt: Add glibc bugs 1241, 1245.
11120
11121 2005-08-25  Jim Meyering  <jim@meyering.net>
11122
11123         * lib/open-safer.c: Include <config.h>.
11124         Otherwise, we'd lose LARGEFILE support in any file using
11125         e.g. "fcntl--.h"
11126
11127 2005-08-25  Bruno Haible  <bruno@clisp.org>
11128
11129         * m4/minmax.m4: Require autoconf 2.52.
11130         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
11131         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
11132         alternatives of translit over the alphabet.
11133         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
11134
11135 2005-08-24  Simon Josefsson  <jas@extundo.com>
11136
11137         * tests/test-getpass.c: New file.
11138
11139 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11140
11141         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
11142         for GNU regex features.
11143
11144 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11145
11146         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
11147         * lib/regex.h (regerror): Likewise.
11148
11149         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
11150         requires this.  (The code never needed it.)
11151
11152         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
11153         All uses of recently-renamed identifiers changed to use the new,
11154         POSIX-compliant names.  The code will build and run just fine
11155         without these changes, but it's better to eat our own dog food
11156         and use the standard-conforming names.
11157
11158         * lib/regex.h: Fix a multitude of POSIX name space violations.
11159         These changes have an effect only for programs that define
11160         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
11161         do not change anything for programs compiled in the normal way.
11162         Also, there is no effect on the ABI.
11163
11164         (_REGEX_SOURCE): New macro.
11165         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
11166         defined and _GNU_SOURCE is not; this fixes a name space violation.
11167
11168         Rename the following macros to obey POSIX requirements.
11169         The old names are still visible as macros if _REGEX_SOURCE is defined.
11170         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
11171         RE_BACKSLASH_ESCAPE_IN_LISTS.
11172         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
11173         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
11174         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
11175         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
11176         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
11177         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
11178         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
11179         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
11180         (REG_INTERVALS): renamed from RE_INTERVALS.
11181         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
11182         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
11183         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
11184         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
11185         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
11186         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
11187         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
11188         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
11189         RE_UNMATCHED_RIGHT_PAREN_ORD.
11190         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
11191         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
11192         (REG_DEBUG): renamed from RE_DEBUG.
11193         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
11194         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
11195         unusual, since we can't clash with the POSIX REG_ICASE.
11196         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
11197         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
11198         (REG_NO_SUB): renamed from RE_NO_SUB.
11199         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
11200         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
11201         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
11202         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
11203         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
11204         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
11205         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
11206         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
11207         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
11208         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
11209         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
11210         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
11211         RE_SYNTAX_POSIX_MINIMAL_BASIC.
11212         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
11213         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
11214         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
11215         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
11216         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
11217         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
11218         (REG_FIXED): Renamed from REGS_FIXED.
11219         (REG_NREGS): Renamed from RE_NREGS.
11220
11221         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
11222         of other REG_* macros, since POSIX says the user is allowed to
11223         #undef these macros selectively.
11224
11225         (reg_errcode_t): Update comment stating what other tables need
11226         to be consistent.
11227
11228         Rename the following enum values to obey POSIX requirements.
11229         The old names are still visible as macros.
11230         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
11231         is not defined, since GNU is supposed to be a superset of POSIX as
11232         much as possible, and since we want reg_errcode_t to be a signed
11233         type for implementation consistency.
11234         (_REG_NOERROR): Renamed from REG_NOERROR.
11235         (_REG_NOMATCH): Renamed from REG_NOMATCH.
11236         (_REG_BADPAT): Renamed from REG_BADPAT.
11237         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
11238         (_REG_ECTYPE): Renamed from REG_ECTYPE.
11239         (_REG_EESCAPE): Renamed from REG_EESCAPE.
11240         (_REG_ESUBREG): Renamed from REG_ESUBREG.
11241         (_REG_EBRACK): Renamed from REG_EBRACK.
11242         (_REG_EPAREN): Renamed from REG_EPAREN.
11243         (_REG_EBRACE): Renamed from REG_EBRACE.
11244         (_REG_BADBR): Renamed from REG_BADBR.
11245         (_REG_ERANGE): Renamed from REG_ERANGE.
11246         (_REG_ESPACE): Renamed from REG_ESPACE.
11247         (_REG_BADRPT): Renamed from REG_BADRPT.
11248         (_REG_EEND): Renamed from REG_EEND.
11249         (_REG_ESIZE): Renamed from REG_ESIZE.
11250         (_REG_ERPAREN): Renamed from REG_ERPAREN.
11251         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
11252         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
11253         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
11254         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
11255
11256         (_REG_RE_NAME, _REG_RM_NAME): New macros.
11257         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
11258         changed.  But support the old name if the new one is not defined
11259         and if _REGEX_SOURCE.
11260
11261         Change the following member names in struct re_pattern_buffer.
11262         The old names are still supported if !_REGEX_SOURCE.
11263         The new names are always supported, regardless of _REGEX_SOURCE.
11264         (re_buffer): Renamed from buffer.
11265         (re_allocated): Renamed from allocated.
11266         (re_used): Renamed from used.
11267         (re_syntax): Renamed from syntax.
11268         (re_fastmap): Renamed from fastmap.
11269         (re_translate): Renamed from translate.
11270         (re_can_be_null): Renamed from can_be_null.
11271         (re_regs_allocated): Renamed from regs_allocated.
11272         (re_fastmap_accurate): Renamed from fastmap_accurate.
11273         (re_no_sub): Renamed from no_sub.
11274         (re_not_bol): Renamed from not_bol.
11275         (re_not_eol): Renamed from not_eol.
11276         (re_newline_anchor): Renamed from newline_anchor.
11277
11278         Change the following member names in struct re_registers.
11279         The old names are still supported if !_REGEX_SOURCE.
11280         The new names are always supported, regardless of _REGEX_SOURCE.
11281         (rm_num_regs): Renamed from num_regs.
11282         (rm_start): Renamed from start.
11283         (rm_end): Renamed from end.
11284
11285         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
11286         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
11287         Prepend __ to parameter names.
11288
11289         Undo yesterday's changes.
11290
11291 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11292
11293         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
11294         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
11295         lib/regex.c.
11296
11297 2005-08-24  Jim Meyering  <jim@meyering.net>
11298
11299         Sync from coreutils.
11300         * m4/fcntl-safer.m4: New file.
11301
11302         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
11303         and object files for this module.
11304
11305 2005-08-24  Jim Meyering  <jim@meyering.net>
11306
11307         Sync from coreutils.
11308         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
11309
11310 2005-08-24  Jim Meyering  <jim@meyering.net>
11311
11312         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
11313         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
11314
11315 2005-08-24  Jim Meyering  <jim@meyering.net>
11316
11317         * modules/fcntl-safer: New module.
11318         * modules/fts (Depends-on): Add fcntl-safer.
11319         * MODULES.html.sh (File descriptor based Input/Output):
11320         Add fcntl-safer.
11321
11322 2005-08-24  Bruno Haible  <bruno@clisp.org>
11323
11324         Support for unit test modules.
11325         * modules/README: Mention tests modules.
11326         * modules/TEMPLATE-TESTS: New file.
11327         * gnulib-tool: New options --extract-tests-module, --with-tests and
11328         --tests-base (unused for the moment).
11329         (testsbase, inctests): New variables.
11330         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
11331         (func_verify_module): Exclude TEMPLATE-TESTS.
11332         (func_verify_nontests_module, func_verify_tests_module): New functions.
11333         (func_get_dependencies): Add implicit dependency for tests modules.
11334         (func_get_tests_module): New function.
11335         (func_modules_transitive_closure): When --with-tests was specified,
11336         include the unit tests as well, unless explicitly avoided.
11337         (func_emit_lib_Makefile_am): Ignore the tests modules here.
11338         (func_emit_tests_Makefile_am): New function.
11339         (func_create_testdir): When --with-tests was specified, emit a
11340         tests/ directory.
11341         * MODULES.html.sh (Future developments): Update.
11342
11343 2005-08-24  Bruno Haible  <bruno@clisp.org>
11344
11345         * modules/tls-tests: New file.
11346         * tests/test-tls.c: New file, from GNU gettext.
11347
11348 2005-08-24  Bruno Haible  <bruno@clisp.org>
11349
11350         * modules/lock-tests: New file.
11351         * tests/test-lock.c: New file, from GNU gettext.
11352
11353 2005-08-24  Bruno Haible  <bruno@clisp.org>
11354
11355         * lib/lock.h: Add multiple inclusion guard.
11356         * lib/tls.h: Add multiple inclusion guard.
11357
11358 2005-08-24  Bruno Haible  <bruno@clisp.org>
11359
11360         * gnulib-tool: Add support for the --aux-dir option to
11361         --create-testdir, --create-megatestdir, --test, --megatest.
11362         (func_create_testdir, func_create_megatestdir): Optionally emit a
11363         AC_CONFIG_AUX_DIR directive.
11364         (create-testdir, create-megatestdir, test, megatest): Provide a
11365         default value for $auxdir.
11366
11367 2005-08-24  Bruno Haible  <bruno@clisp.org>
11368
11369         * gnulib-tool (import): Use compound statement instead of subshell
11370         where possible.
11371
11372 2005-08-24  Bruno Haible  <bruno@clisp.org>
11373
11374         * gnulib-tool (import): Change --aux-dir default to "build-aux".
11375
11376 2005-08-24  Bruno Haible  <bruno@clisp.org>
11377
11378         * gnulib-tool (func_version): Update.
11379
11380 2005-08-24  Bruno Haible  <bruno@clisp.org>
11381
11382         * gnulib-tool (func_import, func_create_testdir,
11383         func_create_megatestdir): Quote all autoconf macro arguments.
11384
11385 2005-08-24  Bruno Haible  <bruno@clisp.org>
11386
11387         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
11388         option --force, because --force causes the aclocal.m4 of each
11389         subdirectory to be newer than the corresponding config.h.in.
11390
11391 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11392
11393         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
11394         All contents moved to gl_REGEX.
11395         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
11396         assume that it does.
11397
11398 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11399
11400         * lib/regex.h (REG_NOSYS)
11401         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
11402         Define, since POSIX requires it as of 2001.
11403         (_REG_ENOSYS)
11404         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
11405         New private symbol, used to keep the enum signed in all cases.
11406         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
11407         Youngman in
11408         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
11409
11410         * lib/regex_internal.c (re_string_skip_chars, register_state):
11411         (calc_state_hash):
11412         Remove forward decls; no longer needed now that we use prototypes.
11413         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
11414         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
11415         (clean_state_log_if_needed): Likewise.
11416
11417 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11418
11419         * config/srclist.txt: Add glibc bugs 1231-1233.
11420
11421 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11422
11423         Fix problems reported by Sam Steingold in
11424         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
11425         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
11426         assumed that reg_errcode_t is a signed type, which is not
11427         necessarily true if _XOPEN_SOURCE is not defined.
11428         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
11429         since some compilers warn about it otherwise.
11430
11431 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11432
11433         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
11434         (init_word_char, create_initial_state, duplicate_node_closure):
11435         (fetch_token, peek_token_bracket, build_range_exp):
11436         (build_collating_symbol): Remove forward decls; no longer needed
11437         now that we use prototypes.
11438
11439         * lib/regcomp.c:
11440         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
11441         (re_compile_fastmap_iter, regcomp, regerror, regfree):
11442         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
11443         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
11444         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
11445         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
11446         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
11447         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
11448         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
11449         (build_range_exp, build_collating_symbol, parse_bracket_exp):
11450         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
11451         (build_charclass, build_charclass_op, fetch_number, create_tree):
11452         (create_token_tree, mark_opt_subexp, duplicate_tree):
11453         Use prototypes rather than old-style definitions.
11454
11455         * lib/regex_internal.c:
11456         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
11457         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
11458         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
11459         (re_string_reconstruct, re_string_peek_byte_case):
11460         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
11461         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
11462         (re_node_set_init_copy, re_node_set_add_intersect):
11463         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
11464         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
11465         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
11466         (re_acquire_state, re_acquire_state_context, register_state):
11467         (create_ci_newstate, create_cd_newstate, free_state):
11468         Likewise.
11469         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
11470         re_search_2):
11471         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
11472         (re_search_internal, prune_impossible_nodes):
11473         (acquire_init_state_context, check_matching, static):
11474         (check_halt_node_context, check_halt_state_context, proceed_next_node):
11475         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
11476         (update_regs, sift_states_backward, build_sifted_states):
11477         (clean_state_log_if_needed, merge_state_array):
11478         (update_cur_sifted_state, add_epsilon_src_nodes):
11479         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
11480         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
11481         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
11482         (find_recover_state, check_subexp_matching_top, transit_state_mb):
11483         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
11484         (check_arrival, check_arrival_add_next_nodes):
11485         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
11486         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
11487         (check_node_accept_bytes, check_node_accept, extend_buffers):
11488         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
11489         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
11490         (sift_ctx_init):
11491         Likewise.
11492
11493         * lib/regex_internal.h:
11494         (re_string_allocate, re_string_construct, re_string_reconstruct):
11495         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
11496         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
11497         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
11498         (re_string_context_at, re_string_peek_byte_case):
11499         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
11500         is defined, since we now use prototypes always.
11501
11502         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
11503         C89 or better.  All uses removed.
11504
11505 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11506
11507         * config/srclist.txt: Add glibc bugs 1220-1227.
11508
11509 2005-08-20  Jim Meyering  <jim@meyering.net>
11510
11511         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
11512         of unused local, dfa.
11513
11514 2005-08-20  Bruno Haible  <bruno@clisp.org>
11515
11516         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
11517
11518 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11519
11520         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
11521         (re_node_set_insert_last, re_dfa_add_node):
11522         Rename local variables to avoid GCC shadowing warnings.
11523
11524 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11525
11526         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
11527         [defined lint]: Suppress bogus uninitialized-variable warnings.
11528
11529         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
11530         and let the caller return REG_ESPACE if out of space.  This
11531         removes an uninitialied-variable warning with GCC 4.0.1, and also
11532         avoids taking the address of a local variable.  All callers
11533         changed.
11534
11535 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11536
11537         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
11538         $LIBCSRC/posix/regexec.c.
11539         Add glibc bug 1217 for regcomp.c.
11540
11541 2005-08-19  Jim Meyering  <jim@meyering.net>
11542
11543         * lib/regexec.c (proceed_next_node): Redo local variables to
11544         avoid GCC shadowing warnings.
11545
11546 2005-08-18  Bruno Haible  <bruno@clisp.org>
11547
11548         * lib/strstr.c (strstr): Fix return value in multibyte case.
11549         * lib/strcasestr.c (strcasestr): Likewise.
11550
11551 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11552
11553         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
11554
11555 2005-08-17  Jim Meyering  <jim@meyering.net>
11556
11557         Make the %s format (seconds since the epoch) work for a negative
11558         number and when used with a zero-padded field width, e.g. %015s.
11559
11560         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
11561         label so that it precedes the code to set `digits'.  Otherwise,
11562         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
11563         print `00-22'.  Now, it prints `-0022', as it should.
11564
11565 2005-08-17  Bruno Haible  <bruno@clisp.org>
11566
11567         * modules/strstr (Files): Add m4/mbrtowc.m4.
11568         (Depends-on): Add mbuiter.
11569
11570 2005-08-17  Bruno Haible  <bruno@clisp.org>
11571
11572         * modules/strcasestr: New file.
11573         * MODULES.html.sh (String handling, based on ANSI C 89): Add
11574         strcasestr.
11575
11576 2005-08-17  Bruno Haible  <bruno@clisp.org>
11577
11578         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
11579
11580 2005-08-17  Bruno Haible  <bruno@clisp.org>
11581
11582         * modules/mbuiter: New file.
11583         * MODULES.html.sh (Extended multibyte and wide character utilities):
11584         Add mbuiter.
11585
11586 2005-08-17  Bruno Haible  <bruno@clisp.org>
11587
11588         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
11589         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
11590
11591 2005-08-17  Bruno Haible  <bruno@clisp.org>
11592
11593         * m4/strcasestr.m4: New file.
11594
11595 2005-08-17  Bruno Haible  <bruno@clisp.org>
11596
11597         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
11598         * lib/strstr.c: Completely rewritten, with multibyte locale support.
11599
11600 2005-08-17  Bruno Haible  <bruno@clisp.org>
11601
11602         * lib/strcasestr.h: New file.
11603         * lib/strcasestr.c: New file.
11604
11605 2005-08-17  Bruno Haible  <bruno@clisp.org>
11606
11607         * lib/strcasecmp.c: Use mbuiter.h.
11608
11609 2005-08-17  Bruno Haible  <bruno@clisp.org>
11610
11611         * lib/mbuiter.h: New file.
11612
11613 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11614
11615         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
11616         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
11617         and gl_GETOPT are both invoked via different paths (as happens
11618         with GNU tar CVS because it uses both argp and getopt), the former
11619         wins.
11620
11621 2005-08-16  Bruno Haible  <bruno@clisp.org>
11622
11623         * modules/tls: New file.
11624         * MODULES.html.sh (Multithreading): Add tls.
11625
11626 2005-08-16  Bruno Haible  <bruno@clisp.org>
11627
11628         * modules/strnlen1: New file.
11629         * MODULES.html.sh (String handling): Add strnlen1.
11630
11631 2005-08-16  Bruno Haible  <bruno@clisp.org>
11632
11633         * modules/strcase (Files): Add m4/mbrtowc.m4.
11634         (Depends-on): Add strnlen1, mbchar.
11635
11636 2005-08-16  Bruno Haible  <bruno@clisp.org>
11637
11638         * modules/mbiter: New file.
11639         * MODULES.html.sh (Extended multibyte and wide character utilities):
11640         Add mbiter.
11641
11642 2005-08-16  Bruno Haible  <bruno@clisp.org>
11643
11644         * modules/mbfile: New file.
11645         * MODULES.html.sh (Extended multibyte and wide character utilities):
11646         Add mbfile.
11647
11648 2005-08-16  Bruno Haible  <bruno@clisp.org>
11649
11650         * modules/mbchar: New file.
11651         * MODULES.html.sh (Extended multibyte and wide character utilities):
11652         New section.
11653
11654 2005-08-16  Bruno Haible  <bruno@clisp.org>
11655
11656         * m4/tls.m4: New file, from GNU gettext.
11657
11658 2005-08-16  Bruno Haible  <bruno@clisp.org>
11659
11660         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
11661         always.
11662         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
11663
11664 2005-08-16  Bruno Haible  <bruno@clisp.org>
11665
11666         * m4/mbiter.m4: New file.
11667
11668 2005-08-16  Bruno Haible  <bruno@clisp.org>
11669
11670         * m4/mbfile.m4: New file.
11671
11672 2005-08-16  Bruno Haible  <bruno@clisp.org>
11673
11674         * m4/mbchar.m4: New file.
11675
11676 2005-08-16  Bruno Haible  <bruno@clisp.org>
11677
11678         * lib/tls.h: New file, from GNU gettext.
11679         * lib/tls.c: New file, from GNU gettext.
11680
11681 2005-08-16  Bruno Haible  <bruno@clisp.org>
11682
11683         * lib/strnlen1.h: New file.
11684         * lib/strnlen1.c: New file.
11685
11686 2005-08-16  Bruno Haible  <bruno@clisp.org>
11687
11688         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
11689         (mbi_init): Update.
11690         (mbi_avail, mbi_advance): Let the iteration end before the terminating
11691         NUL byte, not after it.
11692
11693 2005-08-16  Bruno Haible  <bruno@clisp.org>
11694
11695         * lib/strcase.h (strcasecmp): Add note in comments.
11696         * lib/strncasecmp.c: Use code from strcasecmp.c.
11697         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
11698         (strcasecmp): Work correctly in multibyte locales.
11699
11700 2005-08-16  Bruno Haible  <bruno@clisp.org>
11701
11702         * lib/mbiter.h: New file.
11703
11704 2005-08-16  Bruno Haible  <bruno@clisp.org>
11705
11706         * lib/mbfile.h: New file.
11707
11708 2005-08-16  Bruno Haible  <bruno@clisp.org>
11709
11710         * lib/mbchar.h: New file.
11711         * lib/mbchar.c: New file.
11712
11713 2005-08-16  Bruno Haible  <bruno@clisp.org>
11714
11715         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
11716         the valid ones. Makes the comparison operations transitive:
11717         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
11718         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
11719
11720 2005-08-15  Simon Josefsson  <jas@extundo.com>
11721
11722         * modules/ssize_t (License): Change to 'unlimited'.
11723
11724         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
11725
11726 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11727
11728         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
11729         Add comments for each pending glibc patch.
11730
11731 2005-08-15  Bruno Haible  <bruno@clisp.org>
11732
11733         * lib/regex.h (__restrict_arr): Don't define to __restrict if
11734         __cplusplus is defined.
11735
11736 2005-08-14  Jim Meyering  <jim@meyering.net>
11737
11738         Sync from coreutils.
11739
11740         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
11741         Use the hash-table-based cycle-detection code not just when
11742         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
11743         Reported by James Youngman in
11744         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
11745         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
11746         FTS_TIGHT_CYCLE_CHECK.
11747         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
11748         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
11749         once again.
11750         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
11751         * lib/fts.c (fd_safer): Remove decl.
11752         Include fcntl--.h rather than unistd-safer.h
11753         (fts_safe_changedir): Don't call fd_safer; no longer needed
11754         now that we include fcntl--.h.
11755
11756 2005-08-12  Simon Josefsson  <jas@extundo.com>
11757
11758         * modules/getndelim2: Use ssize_t module.
11759         * modules/getnline: Likewise.
11760         * modules/safe-read: Likewise.
11761         * modules/xreadlink: Likewise.
11762
11763         * modules/ssize_t: New file.
11764
11765 2005-08-12  Simon Josefsson  <jas@extundo.com>
11766
11767         * m4/readline.m4: Look for termcap, curses or ncurses if required.
11768
11769 2005-08-12  Simon Josefsson  <jas@extundo.com>
11770
11771         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
11772         ssize_t.
11773
11774 2005-08-12  Simon Josefsson  <jas@extundo.com>
11775
11776         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
11777         readline, getdelim and check_version.
11778         (Support for systems lacking ISO C 99: Sizes of integer types):
11779         Add size_max.
11780
11781 2005-08-12  Bruno Haible  <bruno@clisp.org>
11782
11783         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
11784
11785 2005-08-11  Simon Josefsson  <jas@extundo.com>
11786
11787         * modules/readline: New file.
11788
11789         * modules/strnlen (Files): Add strnlen.h.
11790
11791 2005-08-11  Simon Josefsson  <jas@extundo.com>
11792
11793         * m4/readline.m4: New file.
11794
11795 2005-08-11  Simon Josefsson  <jas@extundo.com>
11796
11797         * lib/readline.h, readline.c: New file.
11798
11799 2005-08-11  Simon Josefsson  <jas@extundo.com>
11800
11801         * doc/gnulib.texi (Initial import, Finishing touches): Mention
11802         gl_AVOID.
11803
11804 2005-08-11  Bruno Haible  <bruno@clisp.org>
11805
11806         * lib/strnlen.h (strnlen): Change parameter name to match comment.
11807
11808 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
11809
11810         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
11811
11812 2005-08-10  Simon Josefsson  <jas@extundo.com>
11813
11814         * tests/test-iconvme.c: New file.
11815
11816 2005-08-10  Simon Josefsson  <jas@extundo.com>
11817
11818         * m4/strnlen.m4: New file.
11819
11820         * m4/strndup.m4: Don't check for strnlen declaration, done in
11821         strnlen.m4.
11822
11823 2005-08-10  Simon Josefsson  <jas@extundo.com>
11824
11825         * lib/strndup.c: Use strnlen.h.
11826
11827         * lib/strnlen.h: New file.
11828
11829 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11830
11831         * README: Typos.
11832
11833 2005-08-02  Simon Josefsson  <jas@extundo.com>
11834
11835         * modules/readline: New file.
11836
11837 2005-08-02  Simon Josefsson  <jas@extundo.com>
11838
11839         * modules/getdelim: New file.
11840
11841         * modules/getline: Rewrite, don't use getndelim2.
11842
11843 2005-08-02  Simon Josefsson  <jas@extundo.com>
11844
11845         * m4/getline.m4: Separate out getdelim stuff into separate module.
11846
11847         * m4/getdelim.m4: New file.
11848
11849 2005-08-02  Simon Josefsson  <jas@extundo.com>
11850
11851         * lib/getline.h, getline.c: Rewrite.
11852
11853         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
11854
11855 2005-07-31  Bruno Haible  <bruno@clisp.org>
11856
11857         * lib/lock.h (gl_lock_initializer): New macro.
11858         (gl_lock_define_initialized): Use it.
11859         (gl_rwlock_initializer): New macro.
11860         (gl_rwlock_define_initialized): Use it.
11861         (gl_recursive_lock_initializer): New macro.
11862         (gl_recursive_lock_define_initialized): Use it.
11863
11864 2005-07-30  Karl Berry  <karl@gnu.org>
11865
11866         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
11867         Report from Ben Pfaff, regarding getopt.
11868
11869 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
11870
11871         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
11872         normal way.
11873         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
11874         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
11875         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
11876         (gl_GETOPT): Use the new macros.  Most of the implementation
11877         is moved to the new macros.  This is for programs like Emacs
11878         that don't want all the functionality of gl_GETOPT.
11879
11880 2005-07-26  Bruno Haible  <bruno@clisp.org>
11881
11882         * m4/lock.m4: Update from GNU gettext.
11883
11884 2005-07-26  Bruno Haible  <bruno@clisp.org>
11885
11886         * lib/lock.h: Update from GNU gettext.
11887         * lib/lock.c: Update from GNU gettext.
11888
11889 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
11890
11891         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
11892         obsolescent AC_TRY_RUN.  Include the default includes files, for
11893         'exit'.
11894
11895 2005-07-24  Bruno Haible  <bruno@clisp.org>
11896
11897         * modules/visibility: New file.
11898         * MODULES.html.sh (Misc): Add visibility.
11899
11900 2005-07-24  Bruno Haible  <bruno@clisp.org>
11901
11902         * m4/visibility.m4: New file.
11903
11904 2005-07-24  Bruno Haible  <bruno@clisp.org>
11905
11906         * doc/visibility.texi: New file.
11907
11908 2005-07-22  Bruno Haible  <bruno@clisp.org>
11909
11910         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
11911         $(ALLOCA_H), redundant through BUILT_SOURCES.
11912         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
11913         redundant through BUILT_SOURCES.
11914         * modules/byteswap (Makefile.am): Remove explicit dependency on
11915         $(BYTESWAP_H), redundant through BUILT_SOURCES.
11916         * modules/fnmatch (Makefile.am): Remove explicit dependency on
11917         $(FNMATCH_H), redundant through BUILT_SOURCES.
11918         * modules/getopt (Makefile.am): Remove explicit dependency on
11919         $(GETOPT_H), redundant through BUILT_SOURCES.
11920         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
11921         redundant through BUILT_SOURCES.
11922         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
11923         redundant through BUILT_SOURCES.
11924         * modules/stdbool (Makefile.am): Remove explicit dependency on
11925         $(STDBOOL_H), redundant through BUILT_SOURCES.
11926         * modules/stdint (Makefile.am): Remove explicit dependency on
11927         $(STDINT_H), redundant through BUILT_SOURCES.
11928         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
11929         Remove explicit dependency on $(SYSEXITS_H).
11930         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
11931
11932 2005-07-18  Simon Josefsson  <jas@extundo.com>
11933
11934         * lib/check-version.c (check_version): Accept identical versions too.
11935
11936 2005-07-18  Bruno Haible  <bruno@clisp.org>
11937
11938         * modules/lock: New file.
11939         * MODULES.html.sh (Multithreading): New section.
11940
11941 2005-07-18  Bruno Haible  <bruno@clisp.org>
11942
11943         * m4/lock.m4: New file, from GNU gettext.
11944
11945 2005-07-18  Bruno Haible  <bruno@clisp.org>
11946
11947         * lib/lock.h: New file, from GNU gettext.
11948         * lib/lock.c: New file, from GNU gettext.
11949
11950 2005-07-18  Bruno Haible  <bruno@clisp.org>
11951
11952         * lib/lock.h (gl_once_t): New type.
11953         (gl_once_define, gl_once): New macros.
11954         * lib/lock.c (fresh_once): New variable.
11955         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
11956         functions.
11957
11958 2005-07-16  Simon Josefsson  <jas@extundo.com>
11959
11960         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
11961         workaround, suggested by Bruno.
11962
11963 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11964
11965         * modules/xalloc (Depends-on): Add xalloc-die.
11966         * modules/xvasprintf (Depends-on): Add xalloc-die.
11967
11968 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
11969
11970         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
11971         with a minor change.
11972
11973 2005-07-15  Bruno Haible  <bruno@clisp.org>
11974
11975         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
11976         When using lib/poll.c, define poll as rpl_poll.
11977
11978 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
11979
11980         * modules/argp (Depends-on): Remove unlocked-io.
11981
11982 2005-07-14  Derek Price  <derek@ximbiot.com>
11983
11984         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
11985         for glob symlink bug.
11986
11987 2005-07-14  Bruno Haible  <bruno@clisp.org>
11988
11989         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
11990         Instead, test for *_unlocked function declarations directly.
11991
11992 2005-07-11  Simon Josefsson  <jas@extundo.com>
11993
11994         * modules/size_max: New file.
11995
11996         * modules/xsize: Depend on size_max module for size_max.m4.
11997
11998 2005-07-11  Simon Josefsson  <jas@extundo.com>
11999
12000         * lib/size_max.h: New file.
12001
12002 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
12003
12004         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
12005         copyright symbol and the year.
12006         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
12007         (version_etc_va): Use parameterized copyright notice.
12008         Reword to conform to the current GNU coding standards.
12009
12010 2005-07-11  Karl Berry  <karl@gnu.org>
12011
12012         * doc/gnulib.texi (Quoting): new node.
12013         (Initial import): more info, from Patrice.
12014
12015 2005-07-11  Bruno Haible  <bruno@clisp.org>
12016
12017         * gnulib-tool (func_usage): Document option --avoid.
12018         (Command line options): Handle --avoid.
12019         (func_acceptable): New function.
12020         (func_modules_transitive_closure): Use it.
12021
12022 2005-07-11  Bruno Haible  <bruno@clisp.org>
12023
12024         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
12025         Reported by Jim Meyering.
12026
12027 2005-07-10  Bruno Haible  <bruno@clisp.org>
12028
12029         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
12030         Needed when size_t is smaller than 'unsigned int'.
12031         Reported by Paul Eggert.
12032
12033 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12034
12035         * modules/argp (Depends-on): Add unlocked-io
12036
12037 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12038
12039         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
12040         block of defines.
12041
12042 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
12043
12044         * config/srclist.txt: Comment out regcomp.c, since we have a porting
12045         fix now.
12046
12047 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
12048         and Paul Eggert  <eggert@cs.ucla.edu>
12049
12050         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
12051         in wint_t, not wchar_t.  Remove now-unnecessary cast.
12052
12053 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12054
12055         * modules/regex (Files): Add lib/regex_internal.c,
12056         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
12057         (Depends-on): Add extensions.
12058         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
12059
12060 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12061
12062         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
12063         pathconf.
12064         * m4/same.m4 (gl_SAME): Likewise.
12065         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
12066
12067         * m4/regex.m4: Adjust to new libc regex implementation.
12068         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
12069         all the .c and .h parts of (the new) regex.
12070         Quote the m4 stuff better.
12071         Check for RE_ICASE bug of old gnulib.
12072         Check for REG_STARTEND of recent libc.
12073         Rename local variables from jm_* to gl_*.
12074         Quote operand of "test -f".
12075         Say "recent enough" version of libc, not "version 2".
12076         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
12077         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
12078         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
12079         Remove check for btowc, isascii.
12080         Require AM_LANGINFO_CODESET.
12081
12082 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12083
12084         * lib/regex.c, regex.h: Sync from libc.
12085         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
12086         * lib/regexec.c:
12087         New files, synced from libc, except that regex_internal.h
12088         currently has a small porting fix.
12089
12090 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
12091
12092         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
12093         regex_internal.c, regexec.c.
12094         Add regex_internal.h too, but as a comment, since the libc version
12095         is currently broken in gnulib mode.
12096
12097 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12098
12099         Support programs like Emacs that use gnulib but not gettext.
12100         * MODULES.html.sh (Internationalization functions): Add gettext-h.
12101         * modules/gettext-h: New file.
12102         * modules/gettext (Files): Remove lib/gettext.h.
12103         (Depends-on): Add gettext-h.
12104         (Makefile.am): Remove lib_SOURCES.
12105         * modules/argmatch, modules/c-stack, modules/closeout:
12106         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
12107         * modules/execute, modules/file-type, modules/getaddrinfo:
12108         * modules/getopt, modules/human, modules/javacomp:
12109         * modules/javaexec, modules/mkdir-p, modules/obstack:
12110         * modules/openat, modules/pagealign_alloc, modules/pipe:
12111         * modules/quotearg, modules/regex, modules/rpmatch:
12112         * modules/unicodeio, modules/userspec, modules/version-etc:
12113         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
12114         * modules/xsetenv:
12115         Depend on gettext-h, not gettext.
12116
12117 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
12118
12119         * gnulib-tool (func_import): Add support for 'public domain' license.
12120         * modules/alloca, modules/atexit, modules/memmove:
12121         Now public domain, not GPL.
12122         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
12123         * modules/realloc, modules/strerror, modules/strtod:
12124         Now LGPL, not GPL.
12125
12126 2005-07-05  Bruno Haible  <bruno@clisp.org>
12127
12128         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
12129         autoconf CVS. Needed for mingw.
12130
12131 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12132
12133         Remove the dependency of the strftime module on the tzset module.
12134         * modules/strftime (Depends-on): Remove dependency on tzset.
12135
12136 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12137
12138         Remove the dependency of the strftime module on the tzset module.
12139         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
12140         gl_FUNC_TZSET_CLOBBER.
12141
12142 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
12143
12144         Remove the dependency of the strftime module on the tzset module.
12145         * lib/strftime.c (my_strftime)
12146         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
12147         Copy the input structure, to work around some of the bug with
12148         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
12149         Solaris releases, you should also use the tzset module, but we won't
12150         require it as a dependency any more since we don't want LGPLed code
12151         to depend on GPLed code.
12152
12153 2005-07-02  Jim Meyering  <jim@meyering.net>
12154
12155         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
12156         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
12157         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
12158         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
12159
12160 2005-07-02  Jim Meyering  <jim@meyering.net>
12161
12162         * lib/backupfile.c (backup_args): Change a `0' to NULL.
12163
12164 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
12165
12166         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
12167         declares only 'struct timespec;' (!).
12168
12169 2005-07-01  Jim Meyering  <jim@meyering.net>
12170
12171         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
12172         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
12173         * lib/save-cwd.c, tempname.c:
12174         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
12175         and don't include <sys/file.h>).
12176
12177 2005-06-29  Jim Meyering  <jim@meyering.net>
12178
12179         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
12180         type name.  Use the variable name instead.
12181         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
12182         Likewise.
12183
12184 2005-06-28  Simon Josefsson  <jas@extundo.com>
12185
12186         * modules/check-version (Files): Add check-version.m4.
12187
12188 2005-06-28  Simon Josefsson  <jas@extundo.com>
12189
12190         * m4/check-version.m4: New file, suggested by Jim Meyering
12191         <jim@meyering.net>.
12192
12193 2005-06-28  Simon Josefsson  <jas@extundo.com>
12194
12195         * lib/check-version.h, lib/check-version.c: New files.
12196
12197 2005-06-28  Simon Josefsson  <jas@extundo.com>
12198
12199         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
12200         collision with global variable.  Better indentation.  Don't
12201         increment buffer pointer beyond buffer end.  Based on comments
12202         from Paul Eggert <eggert@cs.ucla.edu>.
12203
12204         * lib/base64.h: Indent.
12205
12206 2005-06-28  Simon Josefsson  <jas@extundo.com>
12207
12208         * doc/gnulib.texi (Library version handling): New section.
12209
12210 2005-06-28  Jim Meyering  <jim@meyering.net>
12211
12212         * check-module (find_included_lib_files): Hard-code another
12213         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
12214         but modules/fts-lgpl (correctly) does not list those files.
12215
12216         * modules/canonicalize (Files): Add lib/pathmax.h.
12217
12218 2005-06-25  Simon Josefsson  <jas@extundo.com>
12219
12220         * modules/check-version: New file.
12221
12222 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
12223
12224         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
12225         initializer of struct addrinfo, as an indication that we don't
12226         care how many members the structure has.
12227
12228 2005-06-24  Derek Price  <derek@ximbiot.com>
12229         and Bruno Haible  <bruno@clisp.org>
12230
12231         Remove stat module & update lstat.
12232         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
12233         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
12234         * m4/stat.m4: Remove this file.
12235
12236 2005-06-24  Derek Price  <derek@ximbiot.com>
12237         and Bruno Haible  <bruno@clisp.org>
12238
12239         Remove stat module & update lstat.
12240         * lib/stat.c: Remove this file...
12241         (slash_aware_lstat): ...moving this content and its support...
12242         * lib/lstat.c (rpl_lstat): ...into here.
12243         * lib/lstat.h: New file.
12244
12245 2005-06-24  Derek Price  <derek@ximbiot.com>
12246         and Bruno Haible  <bruno@clisp.org>
12247
12248         Remove stat module & update lstat.
12249         * config/srclist.txt (libc sources): Remove stat.
12250
12251 2005-06-24  Derek Price  <derek@ximbiot.com>
12252         and Bruno Haible  <bruno@clisp.org>
12253
12254         Remove stat module & update lstat.
12255         * MODULES.html.sh (stat): Remove.
12256         * MODULES.html: Regenerated.
12257         * modules/lstat (Description): Correct function name.
12258         (Files): Add "lstat.h".
12259         (Depends-on): Remove stat, add xalloc, stat-macros.
12260         * modules/stat: Remove this file.
12261         (Include): Add "lstat.h", remove <sys/stat.h>.
12262
12263 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
12264
12265         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
12266         (ranged_convert): Don't save conversion in a temporary struct.
12267         This causes a warning with GCC 4.0.0, and anyway in the typical
12268         case it's not worth the extra 100 bytes or so of code.
12269         (ranged_convert, __mktime_internal): When calling a function via a
12270         pointer P, use P () rather than (*P) (), as we now assume C89 or
12271         better.
12272
12273 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12274
12275         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
12276         "who -r" failed to give output.  Problem reported by Tim Waugh.
12277
12278         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
12279         (xcalloc): Use it to avoid needless tests.
12280         Problem reported by Jim Meyering.
12281
12282 2005-06-20  Derek Price  <derek@ximbiot.com>
12283
12284         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
12285         unnecessary for Autoconfs > 2.59c.
12286
12287 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12288
12289         * lib/argp.h (__option_is_short): Check upper limit of
12290         __key. Isprint() requires its argument to have the value
12291         of an unsigned char or EOF.
12292
12293 2005-06-16  Jim Meyering  <jim@meyering.net>
12294
12295         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
12296         when either N or S is zero.
12297
12298 2005-06-16  Derek Price  <derek@ximbiot.com>
12299
12300         * m4/bison.m4: Declare YACC & YFLAGS precious.
12301
12302 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
12303
12304         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
12305         multibyte string or pattern, fall back on unibyte matching.
12306         Problem reported by James Youngman.
12307
12308 2005-06-08  Bruno Haible  <bruno@clisp.org>
12309
12310         * modules/csharpcomp: New file.
12311         * MODULES.html.sh (C#): Add csharpcomp.
12312
12313 2005-06-08  Bruno Haible  <bruno@clisp.org>
12314
12315         * m4/csharpcomp.m4: New file, from GNU gettext.
12316
12317 2005-06-08  Bruno Haible  <bruno@clisp.org>
12318
12319         * lib/csharpcomp.h: New file, from GNU gettext.
12320         * lib/csharpcomp.c: New file, from GNU gettext.
12321         * lib/csharpcomp.sh.in: New file, from GNU gettext.
12322
12323 2005-06-08  Bruno Haible  <bruno@clisp.org>
12324
12325         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
12326         warning on mingw.
12327
12328 2005-06-07  Derek Price  <derek@ximbiot.com>
12329
12330         Sync from CVS.
12331         * lib/glob_.h: Indent nested #ifdef.
12332
12333 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12334
12335         Sync from coreutils.
12336         Use "file name" when talking about file names, instead of "filename"
12337         or "path", as per the GNU coding standards.
12338         * lib/mkdir-p.c: Renamed from makepath.c.
12339         (make_dir_parents): Renamed from make_path.  All callers changed.
12340         * lib/mkdir-p.h: Likewise.  All includers changed.
12341         * lib/filenamecat.c: Renamed from path-concat.c.
12342         (file_name_concat): Renamed from path_concat.  All callers changed.
12343         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
12344         * lib/filenamecat.h: Likewise.  All includers changed.
12345         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
12346         in comments or local variable names.
12347         * lib/basename.c: Likewise.
12348         * lib/canonicalize.c, canonicalize.h: Likewise.
12349         * lib/dirname.c, dirname.h: Likewise.
12350         * lib/euidaccess.c: Likewise.
12351         * lib/exclude.c: Likewise
12352         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
12353         * lib/fsusage.c, fsuage.h: Likewise.
12354         * lib/fts.c, fts_.h: Likewise.
12355         * lib/getcwd.c: Likewise.
12356         * lib/getloadavg.c: Likewise.
12357         * lib/mkstemp.c: Likewise.
12358         * lib/mountlist.c, mountlist.h: Likewise.
12359         * lib/openat.c, openat.h: Likewise.
12360         * lib/readlink-stub.c: Likewise.
12361         * lib/readutmp.c, readutmp.h: Likewise.
12362         * lib/rename.c: Likewise.
12363         * lib/rmdir.c: Likewise.
12364         * lib/same.c: Likewise.
12365         * lib/savedir.c: Likewise.
12366         * lib/stripslash.c: Likewise.
12367         * lib/tempname.c: Likewise.
12368         * lib/xreadlink.c: Likewise.
12369         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
12370         All uses changed.
12371         * lib/exclude.h: Likewise.
12372
12373         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
12374         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12375         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
12376         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12377         * lib/pathmax.h: Include <limits.h> unconditionally, since other
12378         files have been getting away with it for years (MORE/BSD 4.3
12379         is extinct now).
12380         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
12381         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
12382
12383         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
12384         Define to 256, not 255, as per modern POSIX.
12385
12386 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12387
12388         Sync from coreutils.
12389         Use "file name" when talking about file names, instead of "filename"
12390         or "path", as per the GNU coding standards.
12391         * MODULES.html.sh: mkdir-p renamed from makepath.
12392         filenamecat renamed from path-concat.
12393         * modules/filenamecat: Renamed from modules/path-concat.
12394         (Files): filenamecat.h and filenamecat.c renamed from
12395         path-concat.h and path-concat.c.
12396         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
12397         (Include): filenamecat.h, not path-concat.h.
12398         * modules/mkdir-p: Renamed from modules/makepath.
12399         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
12400         makepath.c.
12401         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
12402         (Include): mkdir-p.h, not makepath.h.
12403
12404 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
12405
12406         Sync from coreutils.
12407         * m4/mkdir-p.m4: Renamed from makepath.m4.
12408         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
12409         Rename files from makepath.c to mkdir-p.c, and from
12410         makepath.h to mkdir-p.h.
12411         * m4/filenamecat.m4: Renamed from path-concat.m4.
12412         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
12413         Rename files from path-concat.c to filenamecat.c,
12414         and from path-concat.h to filenamecat.h.
12415         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
12416         "file name" in local variables or comments.
12417         * m4/rename.m4: Likewise.
12418
12419 2005-06-01  Bruno Haible  <bruno@clisp.org>
12420
12421         * modules/csharpexec: New file.
12422         * MODULES.html.sh (C#): New section.
12423
12424 2005-06-01  Bruno Haible  <bruno@clisp.org>
12425
12426         * m4/csharp.m4: New file, from GNU gettext.
12427         * m4/csharpexec.m4: New file, from GNU gettext.
12428
12429 2005-06-01  Bruno Haible  <bruno@clisp.org>
12430
12431         * lib/csharpexec.h: New file, from GNU gettext.
12432         * lib/csharpexec.c: New file, from GNU gettext.
12433         * lib/csharpexec.sh.in: New file, from GNU gettext.
12434
12435 2005-05-31  Derek Price  <derek@ximbiot.com>
12436             Paul Eggert  <eggert@cs.ucla.edu>
12437
12438         Sync from cvs.
12439         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12440
12441 2005-05-31  Derek Price  <derek@ximbiot.com>
12442             Paul Eggert  <eggert@cs.ucla.edu>
12443
12444         Sync from cvs.
12445         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
12446
12447 2005-05-29  Derek Price  <derek@ximbiot.com>
12448
12449         * config/srclist.txt (glob_.h, glob.c): Add these files.
12450
12451 2005-05-29  Derek Price  <derek@ximbiot.com>
12452
12453         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
12454         * modules/glob: New file.
12455         * modules/getlogin_r: Add link to POSIX spec in description.
12456
12457 2005-05-29  Derek Price  <derek@ximbiot.com>
12458             Paul Eggert  <eggert@cs.ucla.edu>
12459
12460         * m4/glob.m4: New file.
12461
12462 2005-05-29  Derek Price  <derek@ximbiot.com>
12463             Paul Eggert  <eggert@cs.ucla.edu>
12464
12465         * lib/glob_.h, lib/glob.c: New files.
12466
12467 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12468
12469         * modules/fts (Files): Remove m4/inttypes-pri.m4.
12470         * modules/fts-lgpl (Depends-on): Remove gettext.
12471
12472 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12473
12474         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
12475         and don't require gt_INTTYPES_PRI.
12476
12477 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
12478
12479         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
12480
12481         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
12482         the configuration hassle isn't worth it.
12483         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
12484         (LONGEST_MODIFIER, PRIuMAX): Remove.
12485
12486 2005-05-27  Bruno Haible  <bruno@clisp.org>
12487
12488         * lib/getlogin_r.h: Remove second include of <stddef.h>.
12489
12490 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
12491
12492         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
12493         _POSIX_PTHREAD_SEMANTICS for Solaris.
12494
12495 2005-05-25  Derek Price  <derek@ximbiot.com>
12496
12497         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
12498
12499 2005-05-25  Derek Price  <derek@ximbiot.com>
12500             Paul Eggert  <eggert@cs.ucla.edu>
12501
12502         * modules/getlogin_r, m4/getlogin_r.m4: New files.
12503         * lib/getlogin_r.c, getlogin_r.h: New files.
12504
12505 2005-05-25  Bruno Haible  <bruno@clisp.org>
12506             Derek Price  <derek@ximbiot.com>
12507
12508         * lib/getlogin_r.h: Simplify API documentation.
12509
12510 2005-05-23  Derek Price  <derek@ximbiot.com>
12511
12512         * modules/minmax (Files): Add m4/minmax.m4.
12513         (configure.ac): Add gl_MINMAX.
12514
12515 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
12516
12517         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
12518         so that unistd-safer.h (GPL'ed code) need not be included.
12519
12520 2005-05-22  Bruno Haible  <bruno@clisp.org>
12521
12522         * m4/minmax.m4: New file.
12523         Based on a patch by Derek Price <derek@ximbiot.com>.
12524
12525 2005-05-22  Bruno Haible  <bruno@clisp.org>
12526
12527         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
12528         (INT64_MIN): Fix definition.
12529         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
12530
12531         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
12532         NEED_SIGNED_INT_TYPES.
12533
12534         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
12535         HAVE_SYSTEM_INTTYPES.
12536
12537 2005-05-22  Bruno Haible  <bruno@clisp.org>
12538
12539         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
12540         Also include <sys/param.h> if it defines MIN, MAX.
12541         Based on a patch by Derek Price <derek@ximbiot.com>.
12542
12543 2005-05-21  Jim Meyering  <jim@meyering.net>
12544
12545         * modules/fts (Files): Add m4/inttypes-pri.m4.
12546         (Depends-on): Add lstat and remove gettext.  Alphabetize.
12547
12548 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12549
12550         New fts module.
12551         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
12552         (setup_dir, free_dir): New functions.
12553         (enter_dir, leave_dir): Define trivial
12554         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
12555         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
12556         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
12557         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
12558         Move to fts-cycle.c.
12559         (fts_open): Use setup_dir.
12560         (fts_close): Use free_dir.
12561         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
12562         This adds a label and some gotos, but the alternatives were messier.
12563         Check for memory allocation failure when entering a dir.
12564         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
12565         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
12566         (FTS): New member fts_cycle, that is a union that contains the
12567         old active_dir_ht and cycle_state.  All uses changed to mention
12568         fts_cycle.ht and fts_cycle.state.
12569         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
12570         fts.c, with the following changes:
12571         (setup_dir, free_dir): New functions.
12572         (enter_dir): Now returns bool.  Return true if successful, false
12573         if memory exhausted.  All callers changed.
12574         Do not bother partly cleaning up on
12575         memory allocation failure; that is free_dir's job.
12576         However, free ad if hash_insert fails, to avoid memory leak.
12577         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
12578         fts->fts_options to see which union member to use.
12579
12580 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12581
12582         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
12583         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
12584
12585 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
12586
12587         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
12588
12589 2005-05-20  Jim Meyering  <jim@meyering.net>
12590
12591         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
12592         Now a macro, to pacify GCC.
12593
12594 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12595
12596         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
12597         of -1.
12598
12599 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
12600
12601         * lib/chown.c (rpl_chown): Return -1 on failure.
12602
12603 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12604
12605         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
12606         Don't check for stddef.h.
12607         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
12608         don't use its results.
12609         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
12610         since we include them unconditionally.  Don't require
12611         AM_STDBOOL_H, since stdbool is a prerequisite.
12612         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
12613         since we assume C89 or better.
12614         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
12615         as we don't use their results.
12616         Don't check for fchdir, memmove, memset, strrchr, as we use
12617         them unconditionally.
12618         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
12619         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
12620
12621 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
12622
12623         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
12624         Include <stddef.h> unconditionally, since we assume C89 now.
12625         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
12626         * lib/fts.c: Include fts_.h first, to check interface.
12627         Do not include intprops.h; no longer needed.
12628         Include cycle-check.h and hash.h, since fts_.h no longer does.
12629         Remove unnecessary casts of closedir to void.
12630         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
12631         decide whether to decrement nlinks.
12632         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
12633         (FTS): Use struct hash_table * instead of Hash_table, so that
12634         we no longer need to include hash.h here.
12635
12636 2005-05-18  Jim Meyering  <jim@meyering.net>
12637
12638         * modules/dirfd (License): Change to LGPL.  Most of the code
12639         is already in the public domain.
12640
12641 2005-05-18  Jim Meyering  <jim@meyering.net>
12642
12643         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
12644         Reported by Yoann Vandoorselaere.
12645
12646 2005-05-17  Jim Meyering  <jim@meyering.net>
12647
12648         * m4/fts.m4: New file, from coreutils.
12649
12650 2005-05-17  Jim Meyering  <jim@meyering.net>
12651
12652         * lib/fts.c, lib/fts_.h: New files, from coreutils.
12653
12654 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12655
12656         Sync from coreutils.
12657         * m4/unlinkdir.m4: New file.
12658
12659 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12660
12661         Sync from coreutils.
12662         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
12663         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
12664         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
12665         White space changes only.
12666         * lib/makepath.c (make_path): Port to hosts where leading "//" is
12667         special.
12668         * lib/yesno.c: Include getline.h, not ctype.h.
12669         (yesno): Don't remove leading white space; POSIX doesn't allow it.
12670         Use getline to remove arbitrary restriction on response length.
12671
12672 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12673
12674         * config/srclist-update: Spell out "Street" in FSF postal
12675         mail address; this is the style the FSF seems to prefer.
12676
12677         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
12678         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
12679         this updates FSF postal mail address.
12680
12681         Sync from coreutils.
12682         * modules/unlinkdir: New file.
12683         * modules/yesno (Depends-on): Add getline.
12684         * MODULES.html.sh (File system functions): Add unlinkdir.
12685
12686 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12687
12688         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
12689         lib/strsep.h:
12690         Change the initial comment to refer to GPL, not LGPL.
12691         gnulib-tool will change it to LGPL as needed.
12692
12693         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
12694         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
12695         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
12696         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
12697         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
12698         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
12699         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
12700         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
12701         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
12702         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
12703         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
12704         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
12705         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
12706         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
12707         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
12708         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
12709         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
12710         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
12711         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
12712         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
12713         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
12714         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
12715         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
12716         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
12717         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
12718         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
12719         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
12720         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
12721         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
12722         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
12723         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
12724         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
12725         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
12726         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
12727         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
12728         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
12729         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
12730         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
12731         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
12732         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
12733         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
12734         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
12735         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
12736         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
12737         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
12738         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
12739         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
12740         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
12741         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
12742         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
12743         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
12744         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
12745         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
12746         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
12747         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
12748         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
12749         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
12750         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
12751         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
12752         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
12753         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
12754         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
12755         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
12756         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
12757         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
12758         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
12759         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
12760         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
12761         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
12762         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
12763         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
12764         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
12765         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
12766         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
12767         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
12768         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
12769         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
12770         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
12771         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
12772         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
12773         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
12774         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
12775         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
12776         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
12777         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
12778         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
12779         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
12780         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
12781         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
12782         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
12783         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
12784         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
12785         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
12786         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
12787         lib/yesno.c, lib/yesno.h:
12788         Update FSF postal mail address.
12789
12790 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
12791
12792         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
12793         tests/test-memmem.c, tests/test-stpncpy.c:
12794         Update FSF postal mail address.
12795
12796 2005-05-13  Bruno Haible  <bruno@clisp.org>
12797
12798         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
12799         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
12800         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
12801         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
12802         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
12803         Add support for 64-bit integers in the MSVC compiler.
12804
12805 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
12806
12807         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
12808
12809 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
12810
12811         * gnulib-tool (func_import): Sort and uniquify recommended includes.
12812
12813 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
12814
12815         * doc/getdate.texi (General date syntax): Don't say that date
12816         date --iso-8601=ns generates acceptable dates; it doesn't yet.
12817         Problem reported by Nic Ferrier.
12818
12819 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12820
12821         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
12822         specified in ai_socktype. Fix invalid ai_protocol
12823         check. ai_protocol is usually set to 0 or depending on
12824         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
12825         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
12826         ai_socktype / ai_protocol in the returned addrinfo structure.
12827
12828 2005-05-10  Simon Josefsson  <jas@extundo.com>
12829
12830         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
12831         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12832
12833 2005-05-10  Karl Berry  <karl@gnu.org>
12834
12835         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
12836         (from http://www.gnu.org/licenses).
12837         * doc/COPYING.LIB: also rename to COPYING.LESSER.
12838         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
12839         fdl.texi suffices.
12840
12841 2005-05-10  Karl Berry  <karl@gnu.org>
12842
12843         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
12844         (COPYING.DOC): remove.
12845
12846         * config/srclist-update: new FSF address.
12847
12848 2005-05-10  Derek Price  <derek@ximbiot.com>
12849
12850         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
12851         possible.
12852
12853 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12854             Bruno Haible  <bruno@clisp.org>
12855
12856         * modules/inet_ntop: New file.
12857         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
12858         inet_ntop.
12859
12860 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12861             Bruno Haible  <bruno@clisp.org>
12862
12863         * m4/inet_ntop.m4: New file.
12864
12865 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12866             Bruno Haible  <bruno@clisp.org>
12867
12868         * lib/inet_ntop.h: New file.
12869         * lib/inet_ntop.c: New file, from glibc with modifications.
12870
12871 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
12872
12873         * modules/time_r (License): Change to LGPL.
12874         * modules/extensions (License): Change to LGPL.  Actually,
12875         the license is more permissive than that, but currently gnulib-tool
12876         doesn't know how to handle more-permissive licenses.
12877
12878         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
12879         Problem reported by Dave Love.
12880
12881 2005-05-08  Jim Meyering  <jim@meyering.net>
12882
12883         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
12884         blank.
12885
12886 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
12887
12888         * modules/argmatch (Depends-on): Add stdbool.
12889         * modules/backupfile (Depends-on): Likewise.
12890         * modules/chdir-long (Depends-on): Likewise.
12891         * modules/closeout (Depends-on): Likewise.
12892         * modules/cycle-check (Depends-on): Likewise.
12893         * modules/dirname (Depends-on): Likewise.
12894         * modules/fnmatch (Depends-on): Likewise.
12895         * modules/fsusage (Depends-on): Likewise.
12896         * modules/fwriteerror (Depends-on): Likewise.
12897         * modules/getcwd (Depends-on): Likewise.
12898         * modules/getloadavg (Depends-on): Likewise.
12899         * modules/hard-locale (Depends-on): Likewise.
12900         * modules/makepath (Depends-on): Likewise.
12901         * modules/mountlist (Depends-on): Likewise.
12902         * modules/nanosleep (Depends-on): Likewise.
12903         * modules/posixtm (Depends-on): Likewise.
12904         * modules/quotearg (Depends-on): Likewise.
12905         * modules/readtokens (Depends-on): Likewise.
12906         * modules/readtokens0 (Depends-on): Likewise.
12907         * modules/readutmp (Depends-on): Likewise.
12908         * modules/save-cwd (Depends-on): Likewise.
12909         * modules/strftime (Depends-on): Likewise.
12910         * modules/userspec (Depends-on): Likewise.
12911         * modules/utimecmp (Depends-on): Likewise.
12912         * modules/xgetcwd (Depends-on): Likewise.
12913         * modules/xnanosleep (Depends-on): Likewise.
12914         * modules/xstrtod (Depends-on): Likewise.
12915         * modules/yesno (Depends-on): Likewise.
12916
12917 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
12918
12919         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
12920         needless checks.
12921
12922 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12923
12924         Merge from coreutils.  Among other things,
12925         add bulletproofing for cases where stdin, stdout, or stderr are closed.
12926         * lib/fd-safer.c: New file.
12927         * lib/fcntl-safer.h, open-safer.c: Remove.
12928         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
12929         * lib/dup-safer.c: Include unistd-safer.h first.
12930         Don't include errno.h.
12931         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
12932         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
12933         * lib/file-type.c: Rely on file-type.h change.
12934         * lib/getloadavg.c: Include unistd-safer.h.
12935         (getloadavg): Use safer open.
12936         * lib/getusershell.c: Include "stdio-safer.h".
12937         (getusershell): Use safer fopen.
12938         * lib/long-options.c (long_options): Use NULL rather than 0.
12939         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
12940         'free'.
12941         * lib/modechange.c: Likewise.
12942         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
12943         (MODE_DONE): New constant.
12944         (struct mode_change): Remove 'next' member.
12945         (make_node_op_equals): New function; like the old one of the
12946         same name, except it allocates an array.
12947         (mode_compile, mode_create_from_ref): Use it.
12948         (mode_compile): Allocate result as an array, not a linked list.
12949         Parse octal string ourself, so that we catch mistakes like "+0".
12950         (mode_adjust): Arg is an array, not a linked list.
12951         * lib/modechange.c: Include stat-macros.h, xalloc.h.
12952         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
12953         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
12954         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
12955         Remove.  This is now stat-macros.h's job.
12956         (talloc): Remove.  All callers replaced by xalloc, so that
12957         our invokers don't have to worry about reporting memory failures.
12958         (make_node_op_equals): Remove.
12959         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12960         New constants.
12961         (struct mode_change): Moved here from modechange.h.
12962         (mode_append_entry): Remove.
12963         (mode_compile): Remove MASKED_OPS arg, since it encouraged
12964         apps to have incorrect behavior.  Use simpler algorithm for head
12965         and tail.  Don't futz with umask; that's now the job of mode_adjust.
12966         Detect more invalid usages rather than having somewhat-random behavior.
12967         Don't insert an "a=" action, as that leads to incorrect behavior.
12968         (mode_compile, mode_create_from_ref): Return NULL on error instead
12969         of an enum, since now there's only one way to have an error.  All
12970         callers changed.
12971         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
12972         at the correct time.  Simplify calculation of "+u" and its ilk.
12973         Don't mishandle "+X".
12974         (mode_free): Remove "register" and localize decls.
12975         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
12976         (struct mode_change): Move to modechange.c; callers don't
12977         need to see this stuff.
12978         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
12979         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
12980         (mode_change, mode_adjust): Reflect the new signatures noted above.
12981         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
12982         that might redefine system include files.
12983         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
12984         (my_usleep): Use NULL rather than (void *) 0.
12985         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
12986         Use siginterrupt to specify that system calls should be interrupted.
12987         (rpl_nanosleep): Move initialization of suspended closer to call of
12988         my_usleep.
12989         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
12990         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
12991         (desirable_utmp_entry): New function.
12992         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
12993         using x2nrealloc, to simplify logic.
12994         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
12995         size calculation.  Do not assume utmp file is a regular file.
12996         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
12997         (READ_UTMP_CHECK_PIDS): New constant.
12998         * lib/save-cwd.c: Include unistd-safer.h.
12999         (save_cwd): Use fd_safer.
13000         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
13001         [!_LIBC] Include "stat-macros.h" instead.
13002         * lib/unistd-safer.h (fd_safer): New decl.
13003
13004 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13005
13006         * modules/getloadavg (Depends-on): Add unistd-safer.
13007         * modules/getusershell (Depends-on): Add stdio-safer.
13008         * modules/lstat (Depends-on): Remove xalloc.
13009         * modules/mkstemp (Depends-on): Add stat-macros.
13010         * modules/modechange (Depends-on): Remove xstrtol.
13011         Add stat-macros, xalloc.
13012         * modules/save-cwd (Depends-on): Add unistd-safer.
13013         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
13014         * modules/unistd-safer (Files): Add lib/fd-safer.c
13015         (Makefile.am): Remove lib_SOURCES.
13016
13017         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
13018         Remove fcntl-safer; unistd-safer supersedes it.
13019
13020 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13021
13022         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
13023         AC_HEADER_STAT.
13024         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
13025         (gl_PREREQ_CHOWN): Remove.
13026         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
13027         it.  Don't require AC_HEADER_STAT.
13028         (gl_PREREQ_LSTAT): Remove.
13029         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
13030         Don't require AC_HEADER_STAT.
13031         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
13032         (gl_PREREQ_RMDIR): Remove.
13033         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
13034         mention stat-macros.h or AC_HEADER_STAT, since we'll make
13035         the stat-macros module a prerequisite.
13036         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
13037         * m4/filemode.m4 (gl_FILEMODE): Likewise.
13038         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
13039         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
13040         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
13041         variable names.
13042         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
13043         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
13044         variable prefixes.
13045         * m4/fcntl-safer.m4: Remove.
13046         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
13047         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
13048         Invoke gl_PREREQ_FD_SAFER.
13049         (gl_PREREQ_FD_SAFER): New macro.
13050         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
13051         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
13052         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
13053         Remove duplicate call to AC_LIBOBJ(readutmp).
13054         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
13055
13056         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
13057         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
13058
13059 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
13060
13061         * MODULES.html.sh (Misc): Add byteswap.
13062
13063 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13064
13065         * modules/getcwd (Depends-on): Add extensions.
13066         * modules/openat (Depends-on): Likewise.
13067
13068 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13069
13070         * modules/byteswap: New file.
13071
13072 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13073
13074         * m4/byteswap.m4: New file.
13075
13076 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
13077
13078         * lib/byteswap_.h: New file.
13079
13080 2005-04-25  Karl Berry  <karl@gnu.org>
13081
13082         * m4/gettext.m4: Update from GNU gettext 0.14.4.
13083
13084 2005-04-25  Albert Chin  <china@thewrittenword.com>
13085
13086         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
13087         Toolkit C bug.
13088
13089 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
13090
13091         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
13092         (func_ln_if_changed) Remove forcibly for no error message
13093         in case file does not exist.
13094
13095 2005-04-19  Simon Josefsson  <jas@extundo.com>
13096
13097         * gnulib-tool (Options): Make --symlink mean --symbolic.
13098
13099 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
13100
13101         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
13102
13103 2005-04-16  Simon Josefsson  <jas@extundo.com>
13104
13105         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
13106
13107 2005-04-15  Simon Josefsson  <jas@extundo.com>
13108
13109         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
13110
13111 2005-04-15  Simon Josefsson  <jas@extundo.com>
13112
13113         * gnulib-tool: Rename --symlink to --symbolic.
13114
13115 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
13116
13117         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
13118         symbolic links to files instead of copying/moving.  Add --aux-dir,
13119         specifying directory relative --dir where auxiliary build tools
13120         are placed.
13121
13122 2005-04-14  Bruno Haible  <bruno@clisp.org>
13123
13124         * modules/allocsa (License): Change to LGPL.
13125         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
13126
13127 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
13128
13129         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
13130         that "UTC +1 second" continues to work.  Problem reported
13131         by Dmitry V. Levin.
13132         (relunit_snumber): New rule.
13133         (relunit): Use it.
13134
13135 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13136
13137         * lib/getdate.y (universal_time_zone_table): New constant.
13138         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
13139         universal_time_zone_table.
13140         (lookup_zone): Prefer universal_time_zone_table to
13141         local_time_zone_table, so that "GMT" time stamps are allowed in
13142         London during the summer.  Problem reported by Ian Abbott.
13143
13144 2005-04-12  Jim Meyering  <jim@meyering.net>
13145
13146         * lib/human.c (humblock): Set *options even when returning due to
13147         xstrtoumax conversion failure.  Thanks to a used-uninitialized
13148         warning from gcc-4.
13149
13150 2005-04-09  Jim Meyering  <jim@meyering.net>
13151
13152         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
13153         -Wuninitialized: initialize tm0.tm_year.
13154
13155 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
13156
13157         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
13158         count, since there's no maximum.  All uses changed.
13159         Add member dsts_seen.
13160         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
13161         not being INT_MAX.
13162         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
13163         Use pc_rels_seen to decide whther a date is absolute.
13164
13165         * lib/getdate.y (number): Don't overwrite year.
13166         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
13167         check.
13168
13169 2005-04-02  Simon Josefsson  <jas@extundo.com>
13170
13171         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
13172         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
13173
13174 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
13175
13176         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
13177         where no absolute path name can be longer than PATH_MAX.
13178
13179 2005-03-27  Jim Meyering  <jim@meyering.net>
13180
13181         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
13182
13183 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
13184
13185         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
13186         "one's complement" -> "ones' complement" in comment, as per Knuth.
13187         "value of type" -> "type or expression" in comment.
13188         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
13189
13190 2005-03-26  Jim Meyering  <jim@meyering.net>
13191
13192         Comment nits.
13193         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
13194         Correct typos: s/or/of/.
13195
13196 2005-03-26  Jim Meyering  <jim@meyering.net>
13197
13198         * modules/check-include-files: Move to ../ and rename to...
13199         * check-module: ...this.
13200
13201 2005-03-25  Jim Meyering  <jim@meyering.net>
13202
13203         * modules/xvasprintf (Files): Add xalloc.h.
13204
13205 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
13206
13207         * modules/gettext (Files): config/config.rpath ->
13208         build-aux/config.rpath
13209         * modules/iconv (Files): Likewise.
13210         Problem reported by Oskar Liljeblad.
13211
13212 2005-03-23  Jim Meyering  <jim@meyering.net>
13213
13214         * modules/check-include-files: New script to check for
13215         missing dependencies, multiple includes, etc.
13216
13217         * modules/c-strtold (Depends-on): Add xalloc.
13218         * modules/c-strtod (Depends-on): Add xalloc.
13219         * modules/hash (Depends-on): Add xalloc.
13220         (Files): Remove lib/xalloc.h.
13221
13222         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
13223         * modules/userspec (Files): Add lib/inttostr.h.
13224
13225 2005-03-23  Jim Meyering  <jim@meyering.net>
13226
13227         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
13228
13229 2005-03-22  Jim Meyering  <jim@meyering.net>
13230
13231         * modules/stat-macros: New module.
13232         * modules/canonicalize, modules/euidaccess, modules/file-type,
13233         * modules/filemode, modules/lchown, modules/makepath,
13234         * modules/rmdir, modules/stat: Depend on new stat-macros module
13235         rather than listing lib/stat-macros.h manually.
13236         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
13237
13238 2005-03-22  Jim Meyering  <jim@meyering.net>
13239
13240         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
13241
13242 2005-03-22  Bruno Haible  <bruno@clisp.org>
13243
13244         * config/srclist.txt: Replace target directory 'config' with
13245         'build-aux'.
13246         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
13247         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
13248         ../build-aux/.
13249
13250 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
13251
13252         * modules/chdir-long (Depends-on): Add mempcpy.
13253
13254         * modules/acl, modules/backupfile, modules/c-strtod,
13255         modules/c-strtold, modules/canon-host, modules/canonicalize,
13256         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
13257         modules/exclude, modules/exitfail, modules/file-type,
13258         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
13259         modules/getdate, modules/getline, modules/getpagesize,
13260         modules/getpass, modules/getugroups, modules/group-member,
13261         modules/hard-locale, modules/hash, modules/human, modules/idcache,
13262         modules/inttostr, modules/long-options, modules/makepath,
13263         modules/md5, modules/memcasecmp, modules/memcoll,
13264         modules/modechange, modules/mountlist, modules/path-concat,
13265         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
13266         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
13267         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
13268         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
13269         modules/strftime, modules/strndup, modules/strverscmp,
13270         modules/timespec, modules/unlocked-io, modules/userspec,
13271         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
13272         modules/yesno:
13273         Remove lib_SOURCES line from Makefile.am section, as this is now
13274         done automatically by the corresponding Autoconf macro.
13275
13276 2005-03-21  Jim Meyering  <jim@meyering.net>
13277
13278         Changes imported from coreutils.
13279
13280         * lib/cycle-check.c: Don't include xalloc.h.
13281
13282         * lib/path-concat.c: Don't include assert.h.
13283         (path_concat): Remove assertion that would have triggered
13284         for ABASE starting with more than one slash.
13285         Reported by Andreas Schwab.
13286
13287         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
13288         properly when ABASE is an absolute file name.
13289         Correct the description of this function.
13290         Include <assert.h>.
13291         Add an assertion and a test driver.
13292         This fixes a bug introduced on 2004-07-02.
13293         Andreas Schwab reported the resulting failure of cp --parents:
13294         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
13295
13296 2005-03-21  Jim Meyering  <jim@meyering.net>
13297
13298         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
13299         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
13300
13301 2005-03-21  Jim Meyering  <jim@meyering.net>
13302         and  Paul Eggert  <eggert@cs.ucla.edu>
13303
13304         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
13305         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
13306         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
13307         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
13308         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
13309         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
13310         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
13311         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
13312         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
13313         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
13314         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
13315         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
13316         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
13317         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
13318         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
13319         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
13320         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
13321         for these modules.
13322
13323 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
13324
13325         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
13326         (which shouldn't happen), generate nothing instead of returning 0
13327         immediately, so that nstrftime (NULL, ...) doesn't return 0.
13328
13329 2005-03-16  Bruno Haible  <bruno@clisp.org>
13330
13331         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
13332         HAVE_LONGLONG_64BIT.
13333
13334 2005-03-16  Bruno Haible  <bruno@clisp.org>
13335
13336         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
13337         HAVE_LONGLONG_64BIT.
13338
13339 2005-03-16  Bruno Haible  <bruno@clisp.org>
13340
13341         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
13342         HAVE_LONGLONG_64BIT.
13343
13344 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13345
13346         * lib/strftime.c (my_strftime): Prepend space to format so that we can
13347         reliably distinguish strftime failure from empty output on POSIX
13348         hosts.
13349
13350 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
13351
13352         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
13353         (iconv_string): Don't guess a size-zero buffer, as that might cause
13354         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
13355         result would be 'too large', where 'too large' is (heuristically)
13356         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
13357         overflow concerns.  This will prevent some unwanted malloc failures
13358         when the inputs are very large.
13359
13360 2005-03-15  Karl Berry  <karl@gnu.org>
13361
13362         * config/srclist.txt (config.rpath): from gettext.
13363         * config/config.rpath: update.
13364
13365 2005-03-15  Bruno Haible  <bruno@clisp.org>
13366
13367         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
13368         to 'negate'.
13369
13370         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
13371         variable.
13372
13373         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
13374         results.
13375
13376 2005-03-14  Simon Josefsson  <jas@extundo.com>
13377
13378         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
13379         <fx@gnu.org>.
13380
13381 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
13382
13383         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
13384         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
13385         intprops.h.
13386         * lib/strtol.c: Likewise.
13387
13388 2005-03-14  Jim Meyering  <jim@meyering.net>
13389
13390         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
13391         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
13392         to be nonzero so that we (and caller) can detect the difference
13393         between a valid zero-length expansion and an error return, even
13394         when the underlying strftime fails before writing anything into
13395         that location.
13396
13397 2005-03-14  Bruno Haible  <bruno@clisp.org>
13398
13399         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
13400         Update from GNU gettext 0.14.3.
13401
13402 2005-03-10  Jim Meyering  <jim@meyering.net>
13403
13404         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
13405
13406 2005-03-10  Jim Meyering  <jim@meyering.net>
13407
13408         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
13409         so that this module works on systems without fchdir.
13410
13411 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
13412
13413         Factor int-properties macros into a single file, except for
13414         glibc-related files.
13415         * lib/intprops.h: New file.
13416         * lib/getloadavg.c: Include it instead of limits.h.
13417         (INT_STRLEN_BOUND): Remove.
13418         * lib/human.c: Include intprops.h.
13419         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
13420         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
13421         302/1000.
13422         * lib/inttostr.h: Include intprops.h instead of limits.h.
13423         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
13424         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
13425         for consistency with intprops.h.
13426         (time_t_is_integer, twos_complement_arithmetic): Use them.
13427         * lib/sig2str.h: Include <signal.h>, intprops.h.
13428         (INT_STRLEN_BOUND): Remove.
13429         * lib/strftime.c (TYPE_SIGNED): Remove.
13430         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
13431         * lib/strtol.c: Adjust comments to match intprops.h.
13432         * lib/userspec.c: Include intprops.h.
13433         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
13434         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
13435         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
13436         instead of rolling our own expressions.
13437         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
13438
13439         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
13440         instead of int.
13441         (my_strftime): Do not mishandle years close to INT_MAX, by doing
13442         the right thing even if adding 1900 would overflow.  Similarly
13443         for tm_mon + 1 and tm_yday + 1.
13444         Make %Y always equivalent to %C%y, and similarly for %G and %g.
13445         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
13446         (DO_SIGNED_NUMBER): New macro.
13447         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
13448
13449 2005-03-07  Bruno Haible  <bruno@clisp.org>
13450
13451         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
13452
13453 2005-03-07  Bruno Haible  <bruno@clisp.org>
13454
13455         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
13456
13457 2005-03-04  Derek R. Price  <derek@ximbiot.com>
13458
13459         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
13460         (func_import): Only replace files via --import when they have actually
13461         changed.
13462
13463 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13464
13465         * m4/mmap-anon.m4: New file.
13466         * m4/pagealign_alloc.m4: New file.
13467
13468 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13469             Bruno Haible  <bruno@clisp.org>
13470
13471         * modules/pagealign_alloc: New file.
13472         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
13473
13474 2005-03-03  Derek R. Price  <derek@ximbiot.com>
13475             Bruno Haible  <bruno@clisp.org>
13476
13477         * lib/pagealign_alloc.h: New file.
13478         * lib/pagealign_alloc.c: New file.
13479
13480 2005-03-03  Bruno Haible  <bruno@clisp.org>
13481
13482         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
13483         Use an all-permissive copyright notice, recommended by RMS.
13484
13485 2005-03-02  Bruno Haible  <bruno@clisp.org>
13486
13487         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
13488         of AIX, the replacement has to be done only after <string.h> is
13489         included, therefore not in config.h. stpncpy.h does the replacement,
13490         and stpncpy.c uses it.
13491
13492 2005-03-02  Bruno Haible  <bruno@clisp.org>
13493
13494         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
13495         stpncpy.c uses it.
13496
13497 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13498
13499         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
13500         The workaround isn't strictly needed for POSIX conformance, and
13501         it's too much of a pain to configure and maintain.  We'll ask
13502         people to fix their kernels instead.
13503         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
13504         (NANOSLEEP_BUG_WORKAROUND): Remove.
13505         (xnanosleep): Remove the workaround.
13506
13507 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13508
13509         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
13510         Reported by Derek Price.
13511         (Include): Add "timespec.h".
13512
13513         * modules/xnanosleep (Depends-on): Remove gethrxtime.
13514
13515 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13516
13517         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
13518         to detect nanosleep bug.
13519
13520 2005-03-01  Bruno Haible  <bruno@clisp.org>
13521
13522         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
13523
13524 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13525
13526         * modules/gethrxtime: New file.
13527         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
13528         (Depends-on): Add gethrxtime.
13529         (configure.ac): Add gl_XNANOSLEEP.
13530         (Makefile.am): Remove lib_SOURCES line.
13531
13532 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13533
13534         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
13535         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
13536
13537 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
13538
13539         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
13540         * lib/timespec.h (gettime): Return void, since it always
13541         succeeds now.  All uses changed.
13542         * lib/gettime.c (gettime) Likewise.
13543         [HAVE_NANOTIME]: Prefer nanotime.
13544         Assume gettimeofday succeeds, as POSIX requires.
13545         Assime time () succeeds, since other code already does.
13546         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
13547         (timespec_subtract): Remove.
13548         (NANOSLEEP_BUG_WORKAROUND): New constant.
13549         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
13550         things considerably.  Use it only on GNU/Linux hosts, since the
13551         workaround shouldn't be needed elsewhere.
13552
13553 2005-02-24  Bruno Haible  <bruno@clisp.org>
13554
13555         * modules/gettext (Files): Add m4/glibc2.m4.
13556
13557 2005-02-24  Bruno Haible  <bruno@clisp.org>
13558
13559         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
13560         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
13561         * m4/progtest.m4:
13562         Update from GNU gettext 0.14.2.
13563         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
13564
13565 2005-02-24  Bruno Haible  <bruno@clisp.org>
13566
13567         * lib/localcharset.c: Update from GNU gettext 0.14.2.
13568         * lib/config.charset: Update from GNU gettext 0.14.2.
13569
13570 2005-02-24  Bruno Haible  <bruno@clisp.org>
13571
13572         * lib/gettext.h: Update from GNU gettext 0.14.2.
13573
13574 2005-02-23  Simon Josefsson  <jas@extundo.com>
13575
13576         * m4/iconvme.m4: New file.
13577
13578 2005-02-23  Jim Meyering  <jim@meyering.net>
13579
13580         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
13581         change.
13582         Thanks to Bruno Haible for catching it.
13583
13584 2005-02-22  Simon Josefsson  <jas@extundo.com>
13585
13586         * modules/iconvme: New file.
13587
13588         * MODULES.html.sh: Add iconvme.
13589
13590 2005-02-22  Simon Josefsson  <jas@extundo.com>
13591
13592         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
13593
13594 2005-02-22  Simon Josefsson  <jas@extundo.com>
13595
13596         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
13597
13598 2005-02-22  Jim Meyering  <jim@meyering.net>
13599
13600         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
13601         s/ifndef/ifdef/.
13602
13603 2005-02-20  Neil Conway  <neilc@samurai.com>
13604
13605         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
13606         returned by OSX/Darwin if the specified buffer is not large
13607         enough for the hostname.
13608
13609 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13610
13611         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
13612         pass it to _help, otherwise the latter coredumps trying to
13613         dereference state.root_argp.
13614
13615 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13616
13617         * modules/chdir-long (Depends-on): Add memrchr.
13618         * modules/memrchr (Files): Add lib/memrchr.h.
13619         (Include): "memrchr.h".
13620
13621 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13622
13623         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
13624
13625 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
13626
13627         * lib/memrchr.h: New file.
13628         * lib/chdir-long.c: Include it.
13629         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
13630         Don't bother including stddef.h.
13631
13632 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
13633
13634         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
13635         inclusion.
13636         Include <sys/types.h>, for dev_t.
13637         (ME_DUMMY, ME_REMOTE): Move from here....
13638         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
13639         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
13640         Dmitry V. Levin.
13641         Include mountlist.h first, to test the interface.
13642
13643 2005-01-29  Bruno Haible  <bruno@clisp.org>
13644
13645         * lib/progname.c (program_name): Initialize.
13646         Needed when linking statically on MacOS X.
13647
13648 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13649
13650         Sync from coreutils.
13651         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
13652         (Depends-on): Add c-strtod.
13653         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
13654
13655 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
13656
13657         Sync from coreutils.
13658         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
13659
13660         Remove files that are specific to coreutils.
13661         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
13662
13663 2005-01-28  Bruno Haible  <bruno@clisp.org>
13664
13665         * modules/javacomp: New file.
13666         * MODULES.html.sh (Java): Add javacomp.
13667
13668 2005-01-28  Bruno Haible  <bruno@clisp.org>
13669
13670         * m4/javacomp.m4: New file, from GNU gettext.
13671
13672 2005-01-28  Bruno Haible  <bruno@clisp.org>
13673
13674         * lib/javacomp.sh.in: New file, from GNU gettext.
13675         * lib/javacomp.h: New file, from GNU gettext.
13676         * lib/javacomp.c: New file, from GNU gettext.
13677
13678 2005-01-26  Simon Josefsson  <jas@extundo.com>
13679
13680         * lib/gai_strerror.c: Use GPL in header.
13681
13682 2005-01-26  Bruno Haible  <bruno@clisp.org>
13683
13684         * modules/javaexec: New file.
13685         * MODULES.html.sh (Java): Add javaexec.
13686
13687 2005-01-26  Bruno Haible  <bruno@clisp.org>
13688
13689         * m4/javaexec.m4: New file, from GNU gettext.
13690
13691 2005-01-26  Bruno Haible  <bruno@clisp.org>
13692
13693         * lib/javaexec.sh.in: New file, from GNU gettext.
13694         * lib/javaexec.h: New file, from GNU gettext.
13695         * lib/javaexec.c: New file, from GNU gettext.
13696
13697 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13698
13699         * modules/lchown (Depends-on): Remove lchown.h
13700
13701 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13702
13703         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
13704         must be defined if the header file was not found, in order
13705         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
13706
13707 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13708
13709         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
13710         initializers for struct pentry_state.
13711         (__argp_error): Check return value of __asprintf
13712         (__argp_failure): Translate error message
13713
13714         * lib/argp-parse.c: Removed braces around the expansion of N_()
13715
13716 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13717
13718         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
13719         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
13720         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
13721         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
13722         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
13723         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
13724         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
13725         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
13726         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
13727         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
13728         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
13729         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
13730         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
13731         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
13732         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
13733         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
13734         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
13735         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
13736         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
13737         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
13738         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
13739         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
13740         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
13741         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
13742         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
13743         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
13744         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
13745         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
13746         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
13747         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
13748         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
13749         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
13750         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
13751         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
13752         xstrtol.m4, xstrtoumax.m4, yesno.m4:
13753         Use an all-permissive copyright notice, recommended by RMS.
13754
13755 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
13756
13757         * modules/chdir-long (Depends-on): Remove mempcpy.
13758
13759 2005-01-21  Jim Meyering  <jim@meyering.net>
13760
13761         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
13762         same value as for Solaris 9.
13763
13764         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
13765         component length.  This included changing the parameter to be
13766         of type `char *' rather than `char const *'.
13767         * lib/chdir-long.h (chdir_long): Update prototype.
13768
13769         * lib/openat.c (fdopendir, fstatat): New functions.
13770         * lib/openat.h: Include headers required for use of DIR and struct
13771         stat.
13772         [AT_SYMLINK_NOFOLLOW]: Define.
13773         (fdopendir, fstatat): Add prototypes.
13774
13775 2005-01-21  Bruno Haible  <bruno@clisp.org>
13776
13777         * modules/classpath: New file.
13778         * MODULES.html.sh (Java): Add classpath.
13779
13780 2005-01-21  Bruno Haible  <bruno@clisp.org>
13781
13782         * lib/classpath.h: New file, from GNU gettext.
13783         * lib/classpath.c: New file, from GNU gettext.
13784
13785 2005-01-20  Simon Josefsson  <jas@extundo.com>
13786
13787         * modules/version-etc-fsf: New file.
13788
13789 2005-01-20  Simon Josefsson  <jas@extundo.com>
13790
13791         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
13792         * lib/version-etc.c: Remove version_etc_copyright.
13793         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
13794         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
13795
13796 2005-01-20  Simon Josefsson  <jas@extundo.com>
13797
13798         * lib/base64.h (isbase64): Add.
13799
13800         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
13801         using a unsigned prototype, don't inline.
13802         (base64_decode): Use it.
13803
13804 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13805
13806         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
13807         it.
13808
13809 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13810
13811         * lib/save-cwd.c (save_cwd): Remove code to support the case
13812         where fchdir is missing or flaky.
13813
13814 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13815
13816         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
13817
13818 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
13819
13820         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
13821         AC_LIBSOURCES now does this.
13822         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
13823         with new ullong_max module.
13824
13825 2005-01-19  Bruno Haible  <bruno@clisp.org>
13826
13827         * modules/sh-quote: New file.
13828         * MODULES.html.sh (Executing programs): Add sh-quote.
13829
13830 2005-01-19  Bruno Haible  <bruno@clisp.org>
13831
13832         * lib/sh-quote.h: New file, from GNU gettext.
13833         * lib/sh-quote.c: New file, from GNU gettext.
13834
13835 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13836
13837         Merge from coreutils.
13838         * m4/ullong_max.m4: New file.
13839         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
13840         (gl_MACROS): Assume localeconv exists.
13841
13842 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13843
13844         Merge changes from coreutils, as described below in several
13845         changelogs dated today.
13846
13847         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
13848         (O_DIRECTORY): Remove; not needed here, since "." must be
13849         a directory.  All uses removed.
13850         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
13851         universal on Suns, and we also need to test for IRIX.
13852         Revamp code to use 'if' rather than '#if'.
13853         Avoid unnecessary comparison of cwd->desc to 0.
13854
13855         * lib/utimens.c (futimens): Robustify the previous patch, by checking
13856         for known valid error numbers rather than observed invalid ones.
13857
13858 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
13859
13860         * modules/ullong_max: New file.
13861
13862         * modules/chdir-long, modules/openat: New files.
13863         * modules/save-cwd (Depends-on): Depend on chdir-long.
13864         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
13865
13866 2005-01-18  Jim Meyering  <jim@meyering.net>
13867
13868         Merge from coreutils.
13869         * m4/chdir-long.m4, m4/openat.m4: New files.
13870         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
13871         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
13872         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
13873         is sane and DOES follow symlinks.  Besides, testing 20 different
13874         systems found no broken chown implementations.
13875         Prompted by a change in rsync's copy of this macro.
13876         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
13877
13878         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
13879
13880         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
13881         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
13882         NULL-means-set-to-current-time semantics.
13883         Remove temporary file immediately, rather than waiting
13884         for configure's at-exit trap code to do it.
13885
13886 2005-01-18  Jim Meyering  <jim@meyering.net>
13887
13888         * lib/version-etc.c (version_etc_copyright): Update copyright date.
13889
13890         * lib/utimens.c (futimens): Account for the fact that futimes
13891         can also fail with errno == ENOSYS or errno == ENOENT.
13892         Patch from Dmitry V. Levin.
13893
13894         Change the name of the robust chdir function from chdir to chdir_long.
13895         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
13896         (restore_cwd): Use chdir_long, not chdir.
13897         * lib/chdir-long.c: Renamed from chdir.c.
13898         * lib/chdir-long.h: Renamed from chdir.h.
13899         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
13900         Hurd.
13901
13902 2005-01-18  Bruno Haible  <bruno@clisp.org>
13903
13904         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
13905         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
13906         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
13907         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
13908         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
13909         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
13910         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
13911         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
13912         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
13913         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
13914         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
13915         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
13916         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
13917         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
13918         Use an all-permissive copyright notice, recommended by RMS.
13919
13920 2005-01-18  Bob Proulx  <bob@proulx.com>
13921
13922         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
13923         simplify offsetof() macro construct to avoid compile failure with
13924         native HP-UX 11.0 ANSI C compiler.
13925
13926 2005-01-17  Bruno Haible  <bruno@clisp.org>
13927
13928         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
13929         redundant because stpncpy.m4 takes care of it.
13930
13931 2005-01-17  Bruno Haible  <bruno@clisp.org>
13932
13933         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
13934
13935 2005-01-17  Bruno Haible  <bruno@clisp.org>
13936
13937         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
13938         used.
13939
13940 2005-01-17  Bruno Haible  <bruno@clisp.org>
13941
13942         * lib/fwriteerror.h (fwriteerror): Change specification to include
13943         fclose.
13944         * lib/fwriteerror.c: Include <stdbool.h>.
13945         (fwriteerror): At the end, close the file stream. Record whether
13946         stdout was already closed.
13947
13948 2005-01-17  Bruno Haible  <bruno@clisp.org>
13949
13950         * lib/execute.c (environ): Declare if needed.
13951         * lib/pipe.c (environ): Likewise.
13952         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
13953
13954 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
13955
13956         * modules/argp: Depend on vsnprintf
13957
13958 2005-01-10  Jim Meyering  <jim@meyering.net>
13959
13960         * modules/closeout (Depends-on): Add atexit.
13961
13962 2005-01-06  Bruno Haible  <bruno@clisp.org>
13963
13964         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
13965
13966 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13967
13968         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
13969         definitions to be after all include files, to avoid collisions.
13970         Problem reported by Bob Proulx.
13971
13972 2005-01-04  Jim Meyering  <jim@meyering.net>
13973
13974         Changes imported from coreutils.
13975         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
13976         as the mkstemp template, use a temporary directory and an
13977         8.3-friendly template to avoid trouble on systems like DJGPP.
13978         Reported by Juan M. Guerrero via Stepan Kasal.
13979         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
13980         close. Remove the temporary directory right away, rather than waiting
13981         for configure's at-exit trap code to do it.
13982         Suggestion from Stepan Kasal.
13983
13984 2005-01-01  Simon Josefsson  <jas@extundo.com>
13985
13986         * gnulib-tool: Print #include directives when --import'ing.
13987
13988 2004-12-28  Simon Josefsson  <jas@extundo.com>
13989
13990         * tests/test-base64.c: Include required header files.  Remove
13991         unused variables.
13992
13993 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13994
13995         * modules/error (Depends-on): Remove gettext.
13996
13997 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
13998
13999         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
14000         not needed.  This removes a dependency on the gettext module.
14001         [defined _LIBC]: Do not include <libintl.h>; not needed.
14002
14003 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
14004
14005         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
14006         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
14007
14008 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
14009
14010         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
14011         HAVE_DECL_STRTOLD.
14012
14013 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14014
14015         * modules/getdate (Depends-on): Remove alloca-opt.
14016
14017 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14018
14019         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
14020
14021 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
14022
14023         * lib/argp-parse.c: Include <stddef.h>.
14024         (alignof, alignto): New macros.
14025         (parser_init): Don't assume that void * is aligned sufficiently
14026         for struct option.
14027
14028         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
14029         need to extend the stack.
14030         (YYINITDEPTH): New macro, so that the initial stack isn't overly
14031         large.
14032
14033 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14034
14035         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
14036
14037 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
14038
14039         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
14040         (2004-10-24) change.  Apparently this was a false alarm.
14041
14042         * modules/getdate: Depend on alloca-opt, not alloca.
14043
14044 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
14045
14046         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
14047         Remove now-obsolete comment about AIX.
14048         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
14049         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
14050         (YYMAXDEPTH): New macro.
14051
14052 2004-12-18  Simon Josefsson  <jas@extundo.com>
14053
14054         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
14055
14056 2004-12-18  Bruno Haible  <bruno@clisp.org>
14057
14058         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
14059
14060 2004-12-18  Bruno Haible  <bruno@clisp.org>
14061
14062         * lib/fatal-signal.c (fatal_signals): Make non-const.
14063         (init_fatal_signals): New function.
14064         (uninstall_handlers, install_handlers): Ignore signals that were set to
14065         SIG_IGN.
14066         (at_fatal_signal): Call init_fatal_signals.
14067         (init_fatal_signal_set): Likewise. Ignore signals that were set to
14068         SIG_IGN.
14069         Reported by Paul Eggert.
14070
14071 2004-12-18  Bruno Haible  <bruno@clisp.org>
14072
14073         * doc/alloca.texi: New file.
14074         * doc/alloca-opt.texi: New file.
14075
14076 2004-12-17  Jim Meyering  <jim@meyering.net>
14077
14078         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
14079         Otherwise, install-sh could exit with improper exit status when
14080         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
14081
14082 2004-12-16  Simon Josefsson  <jas@extundo.com>
14083
14084         * tests/test-base64.c: Add license.
14085
14086 2004-12-15  Stepan Kasal  <address@hidden>
14087
14088         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
14089
14090 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
14091
14092         * modules/getcwd (Files): Add m4/d-ino.m4.
14093         Suggested by Mark D. Baushke.
14094
14095 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
14096
14097         * lib/getdate.y (textint): New member "negative".
14098         (time_zone_hhmm): New function.
14099         Expect 14 shift-reduce conflicts, not 13.
14100         (o_colon_minutes): New rule.
14101         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
14102         (yylex): Set the "negative" member of signed numbers.
14103
14104 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
14105
14106         * doc/getdate.texi (Time of day items, Time zone items):
14107         Describe new formats +00:00, UTC+00:00.
14108
14109 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
14110
14111         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
14112         spurious "-l"s.  Problem reported by Stepan Kasal.
14113
14114 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
14115
14116         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
14117         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
14118
14119 2004-12-04  Simon Josefsson  <jas@extundo.com>
14120
14121         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
14122         Vandoorselaere <yoann@prelude-ids.org>.
14123
14124 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14125
14126         Changes imported from coreutils.
14127         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
14128         exist.
14129         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
14130
14131 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14132
14133         Changes imported from coreutils.
14134         * lib/hard-locale.c: Assume <locale.h> exists.
14135         Include "strdup.h".
14136         (GLIBC_VERSION): New macro.
14137         (hard_locale): Assume setlocale exists.
14138         Rewrite to avoid #ifdef.
14139         Use strdup rather than malloc + strcpy.
14140         * lib/human.c: Assume <locale.h> exists.
14141         (human_readable): Assume localeconv exists.
14142
14143 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
14144
14145         * modules/hard-locale (Depends-on): Add strdup.
14146
14147 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
14148
14149         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
14150         convert T2, not T.  (Imported from libc.)
14151
14152 2004-11-30  Simon Josefsson  <jas@extundo.com>
14153
14154         * modules/restrict (License): Change to LGPL.
14155
14156 2004-11-30  Simon Josefsson  <jas@extundo.com>
14157
14158         * m4/restrict.m4: Add copyright and copying conditions.
14159
14160 2004-11-30  Simon Josefsson  <jas@extundo.com>
14161
14162         * m4/base64.m4: New file.
14163
14164 2004-11-30  Simon Josefsson  <jas@extundo.com>
14165
14166         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
14167         base64.
14168
14169         * tests/test-base64.c: New file.
14170
14171         * modules/base64: New file.
14172
14173 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
14174
14175         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
14176         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
14177
14178         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
14179
14180 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
14181
14182         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
14183         (__getcwd.c): Don't restore errno; glibc doesn't.
14184         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
14185         first, falling back to our code only if its results look suspicious.
14186         Ensure that the resulting buffer is only as large as necessary.
14187
14188         * lib/readutmp.c: Include readutmp.h first.
14189         Include <errno.h>, since readutmp.h no longer does that.
14190         * lib/readutmp.h: Don't include <errno.h>,
14191         <sys/param.h>, <time.h>; not needed to establish interface.
14192         (errno): Remove decl.
14193         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
14194         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
14195         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
14196
14197 2004-11-28  Simon Josefsson  <jas@extundo.com>
14198
14199         * lib/base64.h, base64.c: New file.
14200
14201 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
14202
14203         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
14204
14205 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
14206
14207         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
14208         (Depends-on): Remove pathmax, same.  Add mempcpy.
14209         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
14210         (Makefile.am): Append getcwd.h to lib_SOURCES.
14211         (Include): Add getcwd.h.
14212         (Maintainer): Change from Jim Meyering to "all, glibc",
14213         since getdate now uses intended-for-glibc code.
14214         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
14215         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
14216
14217 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14218
14219         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
14220         HP's ANSI C compiler.
14221         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
14222         Declaring int functions causes warnings on some modern systems and
14223         shouldn't be needed to compile on ancient ones.
14224         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
14225         defined.
14226
14227         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
14228         with the following changes.
14229         (__set_errno): Parenthesize properly.
14230         Include <stdbool.h>.
14231         (MIN, MAX, MATCHING_INO): New macros.
14232         (__getcwd): Define with prototype, not K&R form.
14233         Use heuristics to allocate default buffer on stack if possible.
14234         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
14235         behavior, and to avoid the PATH_MAX limit when computing
14236         ../../../../...
14237         Use MATCHING_INO to compare inode number to file.
14238         Check for arithmetic overflow in size calculations.
14239         Fix bug in reallocation of dot array that caused getcwd to fail
14240         on directories nested deeper than 75.
14241         Be more careful about saving errno on error.
14242         Do not use realloc; use only free+malloc, as this is a bit
14243         more flexible and avoids a needless copy operation.
14244         Do not inspect st_dev and st_ino for symbolic links; POSIX
14245         doesn't specify the latter.
14246         Check for closedir errors.
14247         Avoid needless casts.
14248         Use "#ifdef weak_alias" around weak_alias, to be like other
14249         glibc code.
14250         The following changes to getcwd.c have effect only when used in
14251         gnulib; they have no effect inside glibc proper.
14252         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
14253         as alloca isn't used.
14254         (alloca, __alloca): Likewise.
14255         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
14256         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
14257         unconditionally, as gnulib assumes C89 or better.
14258         Do not include <sys/param.h>.
14259         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
14260         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
14261         better.
14262         (NULL) [!defined NULL]: Remove; we assume C89 or better.
14263         Include <dirent.h> in a way that is compatible with modern Autoconf.
14264         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
14265         New macros, if not already defined.
14266         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
14267         Use "_LIBC", not "defined _LIBC", for consistency.
14268         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
14269         a mempcpy module.
14270         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
14271         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
14272         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
14273         credit only to Jim Meyering and adjust the copyright dates.
14274         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
14275         <stdlib.h>, <unistd.h>, "pathmax.h".
14276         Instead, include "xgetcwd.h" (first) and "getcwd.h".
14277         (INITIAL_BUFFER_SIZE): Remove.
14278         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
14279
14280 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14281
14282         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
14283         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
14284         Use the _ONCE methods, for efficiency.
14285         Check for fcntl.h.  In test program, include <errno.h>
14286         and <fcntl.h> if available.  Remove old K&R cruft from
14287         test program.  Check for common errors in GNU/Linux,
14288         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
14289         don't do AC_LIBOBJ, as that's getcwd.m4's job.
14290         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
14291         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
14292         name accordingly.
14293         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
14294         accommodate new getcwd.c.
14295         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
14296         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
14297         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
14298         that's all we need now.
14299
14300 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14301
14302         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
14303         argp-parse.c depends on getopt internals, that means we should
14304         always use our getopt, to be on the safe side.
14305         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
14306         order not to spoil the result of an eventual previous invocation
14307         of gl_GETOPT_SUBSTITUTE.
14308
14309 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14310
14311         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
14312         redefinition warnings. To avoid them, include the defines
14313         in `#if !defined __need_getopt ... #endif'. The only place
14314         where __getopt_argv_const is used is in definitions
14315         of getopt_long and getopt_long_only below, which are as well
14316         protected by `#ifndef __need_getopt'.
14317         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
14318         __need_getopt after including <stdio.h> and <unistd.h> These
14319         headers might have defined it.
14320
14321 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14322
14323         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
14324
14325 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
14326
14327         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
14328         (futimens): New function, which uses futimes if available.
14329         (futimens, utimens): Support timespec==NULL, with same semantics
14330         as utime and utimens.
14331         * lib/utimens.h (futimens): New decl.
14332
14333 2004-11-23  Jim Meyering  <jim@meyering.net>
14334
14335         * lib/getopt_.h: Remove trailing blanks.
14336
14337 2004-11-23  Jim Meyering  <jim@meyering.net>
14338
14339         * lib/__fpending.c: Add comment.
14340
14341 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
14342
14343         * modules/canonicalize (Depends-on): Add xreadlink.
14344         Problem reported by James Youngman.
14345
14346 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
14347
14348         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
14349         New macros.
14350         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
14351         optopt): Use them instead of invoking ## directly; otherwise, the
14352         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
14353
14354 2004-11-19  Bruno Haible  <bruno@clisp.org>
14355
14356         * lib/strtok_r.c: Move comments from here...
14357         * lib/strtok_r.h: ... to here.
14358
14359 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14360
14361         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
14362         implementations that mishandle size_t overflow.
14363
14364 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
14365
14366         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
14367         might fail.  Problem reported by Yoann Vandoorselaere.
14368         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
14369         implementations that mishandle size_t overflow.
14370
14371 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14372
14373         * modules/canon-host (Depends-on): Add strdup.
14374
14375 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14376
14377         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
14378
14379 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14380
14381         * lib/canon-host.c: Include "strdup.h".
14382         (canon_host): Use getaddrinfo if available, so that IPv6 works.
14383         Use strdup instead of malloc/strcpy to duplicate strings.
14384
14385         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
14386         (human_space_before_unit): New constant.
14387         * lib/human.c (human_readable): Support it.
14388
14389         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
14390         (xgetcwd): Set errno correctly when failing.
14391         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
14392         the failure is actually due to a PATH_MAX problem.
14393
14394         Further getopt changes to make it more likely that glibc will
14395         buy the changes back.
14396         * lib/getopt.c (POSIXLY_CORRECT): New constant.
14397         (getopt): Use it, so to preserve glibc semantic
14398         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
14399         when compiling for libc.
14400         * lib/getopt_.h (__getopt_argv_const): Bring it back.
14401         (getopt_long, getopt_long_only): Use it.
14402
14403         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14404         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
14405         (getopt): Argv is now char * const *, as per standard.
14406         (_getopt_internal_r, _getopt_internal): Argv is now char **,
14407         not char *__getopt_argv_const *.
14408         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14409         _getopt_long_only_r): Likewise.
14410         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
14411         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14412         _getopt_long_r, _getopt_long_only_r): Likewise.
14413         * lib/getopt_.h (__getopt_argv_const): Remove.
14414         (getopt): Argv is now char * const *, as per standard.
14415
14416         * lib/getdate.y (tORDINAL): New token.
14417         (day, relunit): Allow it for relative times.
14418         (relative_time_table): Use tORDINAL for ordinals.
14419
14420 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
14421
14422         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
14423         Document that "second" isn't allowed as an ordinal number.
14424
14425 2004-11-16  Jim Meyering  <jim@meyering.net>
14426
14427         * modules/closeout (Depends-on): Add fpending.
14428
14429 2004-11-15  Jim Meyering  <jim@meyering.net>
14430
14431         * lib/closeout.c: Include "__fpending.h" once again.
14432         Include <stdbool.h>.
14433         (close_stdout): Don't fail just because stdout was closed initially,
14434         since some programs don't write to stdout in the normal course of
14435         operation (other than --version and --help), and we don't want this
14436         function to make e.g. `touch file >&-' fail.
14437         But do fail if it was closed and someone has tried to write to it.
14438         E.g., `printf foo >&-' must fail.
14439
14440 2004-11-13  Jim Meyering  <jim@meyering.net>
14441
14442         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
14443
14444 2004-11-12  Simon Josefsson  <jas@extundo.com>
14445
14446         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
14447         small doc fix is still pending.
14448
14449 2004-11-11  Simon Josefsson  <jas@extundo.com>
14450
14451         * modules/strtok_r: New file.
14452
14453         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14454         strtok_r.
14455
14456 2004-11-11  Simon Josefsson  <jas@extundo.com>
14457
14458         * m4/strtok_r.m4: New file.
14459
14460         * m4/getopt.m4: Replace opterr.
14461
14462 2004-11-11  Simon Josefsson  <jas@extundo.com>
14463
14464         * lib/strtok_r.h, strtok_r.c: New file.
14465
14466 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14467
14468         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
14469         of replacing opterr, getopt, etc.  This should handle the
14470         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
14471
14472 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
14473
14474         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
14475         we can stop lying to compilers about the constness of argv when we
14476         are compiled outside glibc.
14477         (getopt, getopt_long, getopt_long_only): Use it.
14478         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
14479         _getopt_internal, getopt): Likewise.
14480         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
14481         _getopt_long_only_r): Likewise.
14482         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
14483         _getopt_long_r, _getopt_long_only_r): Likewise.
14484
14485         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
14486         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
14487         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
14488         the other external symbols.
14489         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
14490         declaration, since the above renaming now works around collisions.
14491
14492 2004-11-11  Jim Meyering  <jim@meyering.net>
14493
14494         * lib/linebreak.c: Remove trailing blanks.
14495         * lib/alloca_.h: Likewise.
14496         * lib/acosl.c: Likewise.
14497         * lib/euidaccess.c: Likewise.
14498         * lib/allocsa.h: Likewise.
14499
14500 2004-11-10  Simon Josefsson  <jas@extundo.com>
14501
14502         * m4/getaddrinfo.m4: New file.
14503
14504 2004-11-10  Simon Josefsson  <jas@extundo.com>
14505
14506         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
14507
14508 2004-11-10  Simon Josefsson  <jas@extundo.com>
14509
14510         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
14511         getaddrinfo.
14512
14513         * modules/getaddrinfo: New file.
14514
14515 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14516
14517         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
14518
14519 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14520
14521         * lib/mktime.c (SHR): New macro, which is a portable
14522         substitute for >> that should work even on Crays.
14523         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
14524         Problem reported by Mark D. Baushke in
14525         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
14526         * lib/getdate.y (SHR): Likewise.
14527         (tm_diff): Use it.
14528         * lib/strftime.c (SHR): Likewise.
14529         (tm_diff): Use it.
14530         * lib/quotearg.c (struct quoting_options): Use unsigned int for
14531         quote_these_too, so that right shifts are well defined.  All uses
14532         changed.
14533
14534 2004-11-10  Jim Meyering  <jim@meyering.net>
14535
14536         Ensure that no close failure goes unreported.
14537         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
14538         return early when it seems there's nothing to flush.
14539         Don't include __fpending.h.
14540
14541 2004-11-10  Jim Meyering  <jim@meyering.net>
14542
14543         * modules/closeout (Depends-on): Remove fpending.
14544
14545 2004-11-10  Jim Meyering  <jim@meyering.net>
14546
14547         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
14548
14549 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14550
14551         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
14552         gl_FUNC_STRFTIME.
14553         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
14554         and AC_REQUIRE when possible, to avoid duplicate checks.
14555         Check for <wchar.h>.
14556
14557 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
14558
14559         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
14560
14561 2004-11-09  Bruno Haible  <bruno@clisp.org>
14562
14563         * m4/sockpfaf.m4: New file.
14564
14565 2004-11-05  Bruno Haible  <bruno@clisp.org>
14566
14567         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
14568         Reported by Mark D. Baushke <mdb@cvshome.org>.
14569
14570 2004-11-04  Bruno Haible  <bruno@clisp.org>
14571
14572         2004-09-11  Bruno Haible  <bruno@clisp.org>
14573                 * allocsa.valgrind: New file.
14574         2004-02-06  Bruno Haible  <bruno@clisp.org>
14575                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
14576                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
14577                 Reported by Christopher Seip <chris.seip@hp.com>.
14578
14579 2004-11-04  Bruno Haible  <bruno@clisp.org>
14580
14581         * modules/allocsa (Files): Add lib/allocsa.valgrind.
14582         (Makefile.am): Distribute it.
14583
14584 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
14585
14586         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
14587         with errno == ERANGE if the buffer is too small.
14588         Problem reported by Mark D. Baushke.
14589
14590 2004-11-03  Albert Chin  <china@thewrittenword.com>
14591             Paul Eggert  <eggert@cs.ucla.edu>
14592
14593         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
14594         equivalent, substitute $ac_type for equivalent type rather than
14595         blindly using uint32_t *always* which won't work if uint32_t is not
14596         available.  Define _UINT32_T to work around typedef of uint32_t if
14597         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
14598         2.5.1.
14599
14600 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14601
14602         * m4/jm-macros.m4: Sync from coreutils.
14603         (gl_MACROS): Check for mbrlen, for pathchk.
14604         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
14605
14606 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14607
14608         * lib/xreadlink.c (MAXSIZE): New macro.
14609         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
14610         size does not exceed MAXSIZE.  Avoid cast.
14611         As suggested by Mark D. Baushke in
14612         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
14613         if readlink fails with buffer size just under MAXSIZE, try again
14614         with MAXSIZE.
14615
14616 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
14617
14618         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
14619
14620 2004-11-02  Derek R. Price  <derek@ximbiot.com>
14621         and  Paul Eggert  <eggert@cs.ucla.edu>
14622
14623         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
14624         (get_date): Overparenthesize to avoid GCC warning.
14625
14626 2004-11-02  Bruno Haible  <bruno@clisp.org>
14627
14628         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
14629         returns void.
14630
14631 2004-11-02  Bruno Haible  <bruno@clisp.org>
14632
14633         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
14634         function returns void.
14635
14636 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14637
14638         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
14639         fflush_unlocked, flockfile, funlockfile, funlockfile,
14640         fputs_unlocked, putc_unlocked.
14641
14642 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
14643
14644         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14645         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
14646         already declared.
14647
14648 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14649
14650         * modules/getdate (Files): Add doc/getdate.texi.
14651         (Depends-on): Add setenv, xalloc.
14652
14653 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14654
14655         * lib/getdate.y: Add support for TZ="foo" within a date string.
14656         Fix some bugs near time_t boundaries.  Reject dates with
14657         out-of-range components, e.g., "Sept 31".
14658         Include <stdlib.h>, "setenv.h", "xalloc.h".
14659         (ISDIGIT_LOCALE): Remove; unused.
14660         Note that the TZ and time functions used here are not reentrant.
14661         (mktime_ok, get_tz): New functions.
14662         (TZBUFSIZE): New constant.
14663         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
14664         This requires that we sometimes generate our own TZ="XXX..." setting.
14665
14666 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14667
14668         * doc/getdate.texi: New file, from coreutils with modifications for
14669         the new TZ parsing.
14670
14671 2004-10-27  Derek R. Price  <derek@ximbiot.com>
14672
14673         * lib/mktime.c (not_equal_tm): Remove redundant check.
14674
14675 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14676
14677         * modules/regex (lib_SOURCES): Add regex.c.
14678         Reported by James Youngman in
14679         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
14680
14681 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
14682
14683         * lib/getdate.y: Use Bison 1.875 features, and some minor
14684         code cleanups.  This change does not affect semantics.
14685         Don't include <stdlib.h>; no longer needed.
14686         Don't include unlocked-io.h; only the "#if TEST" code uses
14687         stdio, and performance isn't crucial there.
14688         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
14689         Bison 1.875 features as described below.
14690         All uses of "PC." replaced by "pc->".
14691         (YYSTYPE): Add a forward declaration.
14692         (yylex, yyerror): Use full prototypes in forward decls.
14693         Use "%pure-parser" rather than obsolescent "%pure_parser".
14694         Use %parse-param and %lex-param instead of obsolescent
14695         YYPARSE_PARAM and YYLEX_PARAM.
14696         (meridian_table, month_and_day_table, time_units_table,
14697         relative_time_table, time_zone_table, military_table,
14698         lookup_zone, lookup_word, get_date):
14699         Use NULL instead of 0 where appropriate.
14700         (to_hour): Avoid abort (), to avoid a dependency on
14701         stdlib.h.
14702         (yyerror, yylex): Now accepts parser_control * arg.
14703         (main) [TEST]: Use '\0' rather than 0 for char.
14704
14705 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14706
14707         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
14708
14709 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
14710
14711         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
14712         It's now the caller's responsibility to handle the case where
14713         !HAVE_GETPAGESIZE && !defined getpagesize.
14714
14715         * lib/mktime.c (leapyear): Arg is long int, not int.
14716
14717 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
14718
14719         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
14720
14721 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
14722
14723         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
14724         missing.  Problem reported by James Youngman.
14725
14726 2004-10-16  Simon Josefsson  <jas@extundo.com>
14727
14728         * gnulib-tool: Fix comments.  Fix parse problem.
14729         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
14730
14731 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
14732
14733         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
14734         implementation of getopt_long.  Problem reported by Alexander Taler in:
14735         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
14736
14737 2004-10-15  Bruno Haible  <bruno@clisp.org>
14738
14739         * gnulib-tool: Untabify. Initialize supplied_libname.
14740         (func_usage): More homogenous output.
14741         (func_modules_transitive_closure, func_modules_to_filelist,
14742         func_emit_lib_Makefile_am): New functions.
14743         (func_import): New function, extracted from big case statement. Use
14744         func_get_license, func_modules_transitive_closure,
14745         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
14746         opt_lgpl. Don't use test -a, as it's not portable.
14747         (func_create_testdir): Use func_modules_transitive_closure,
14748         func_modules_to_filelist, func_emit_lib_Makefile_am.
14749
14750 2004-10-15  Bruno Haible  <bruno@clisp.org>
14751
14752         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
14753
14754 2004-10-15  Bruno Haible  <bruno@clisp.org>
14755
14756         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
14757         the portions belonging to each module.
14758         Suggested by Derek Robert Price <derek@ximbiot.com>.
14759
14760 2004-10-12  Simon Josefsson  <jas@extundo.com>
14761
14762         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
14763         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
14764         to real functions.
14765
14766 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14767
14768         * modules/vsnprintf: New file.
14769
14770 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14771
14772         * m4/vsnprintf.m4: New file.
14773
14774 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14775
14776         * lib/vsnprintf.h: New file.
14777         * lib/vsnprintf.c: New file.
14778
14779 2004-10-11  Bruno Haible  <bruno@clisp.org>
14780
14781         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
14782         vsnprintf.
14783
14784 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14785
14786         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
14787
14788 2004-10-07  Bruno Haible  <bruno@clisp.org>
14789
14790         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
14791         fits into the provided buffer.
14792
14793 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14794
14795         * lib/diacrit.c, diacrit.h: Add GPL notice.
14796
14797         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
14798         notice.
14799         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
14800         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
14801         This avoids a potential constant-folding bug.
14802
14803 2004-10-05  Bruno Haible  <bruno@clisp.org>
14804
14805         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
14806         for the declaration of strsep.
14807
14808 2004-10-05  Bruno Haible  <bruno@clisp.org>
14809
14810         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
14811
14812 2004-10-04  Simon Josefsson  <jas@extundo.com>
14813
14814         * modules/memmem: New file.
14815         * tests/test-memmem.c: New file.
14816         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
14817
14818 2004-10-04  Simon Josefsson  <jas@extundo.com>
14819
14820         * m4/memmem.m4: New file.
14821
14822 2004-10-04  Simon Josefsson  <jas@extundo.com>
14823
14824         * lib/memmem.h: New file.
14825         * lib/memmem.c: New file, taken from glibc.
14826
14827 2004-10-04  Simon Josefsson  <jas@extundo.com>
14828
14829         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
14830         '#ifdef USE_UNLOCKED_IO'.
14831
14832 2004-10-04  Simon Josefsson  <jas@extundo.com>
14833
14834         * config/srclist.txt: Add memmem from glibc.
14835
14836 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14837
14838         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
14839
14840         * modules/argmatch, modules/argp, modules/closeout, modules/error,
14841         modules/exclude, modules/getdate, modules/getline,
14842         modules/getndelim2, modules/getpass, modules/getpass-gnu,
14843         modules/getusershell, modules/linebuffer, modules/md5,
14844         modules/mountlist, modules/posixtm, modules/readtokens,
14845         modules/readutmp, modules/regex, modules/sha1,
14846         modules/version-etc, modules/yesno:
14847         Remove dependency on unlocked-io.
14848
14849 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14850
14851         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
14852
14853         * m4/unlocked-io.m4: Add copyright notice.
14854         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
14855
14856 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14857
14858         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
14859         * lib/xmalloc.c (xmemdup): Likewise.
14860         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
14861         XFREE): Remove these long-obsolescent macros.
14862         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
14863         * lib/xstrdup.c: Remove.
14864
14865         * lib/regex.c (re_comp): Cast gettext return value to char *,
14866         Problem reported by Martin Neitzel via Mark D. Baushke.
14867
14868 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
14869
14870         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
14871         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
14872         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
14873         regex.c, sha1.c, version-etc.c, yesno.c:
14874         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
14875         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
14876         the includer's responsibility.
14877
14878         Sync from coreutils.
14879
14880         * lib/modechange.c (mode_compile): Don't decrement a pointer that
14881         points to the start of a string, as the C Standard says the
14882         resulting behavior is undefined.
14883
14884         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
14885         simple -> simple_backups, numbered_existing ->
14886         numbered_existing_backups, numbered -> numbered_backups
14887         to avoid shadowing problems.  All uses changed.
14888         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
14889         * lib/backupfile.c (check_extension, numbered_backup):
14890         Rename locals to avoid shadowing 'basename'.
14891         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
14892         once.
14893
14894         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
14895         * lib/.cvsignore: Add getopt.h.
14896
14897 2004-10-04  Bruno Haible  <bruno@clisp.org>
14898
14899         * modules/README: New file.
14900         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
14901         not a module.
14902
14903 2004-10-02  Jim Meyering  <jim@meyering.net>
14904
14905         * lib/dirfd.h, getpagesize.h: Add copyright notice.
14906
14907 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14908
14909         * modules/strsep: New file.
14910
14911 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14912
14913         * m4/strsep.m4: New file.
14914
14915 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
14916
14917         * lib/strsep.h: New file.
14918         * lib/strsep.c: New file.
14919
14920 2004-10-01  Simon Josefsson  <jas@extundo.com>
14921
14922         * lib/snprintf.c (snprintf): Handle size==0.
14923
14924 2004-10-01  Simon Josefsson  <jas@extundo.com>
14925             Bruno Haible  <bruno@clisp.org>
14926
14927         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
14928         (snprintf): Declare 'args'.
14929
14930 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
14931
14932         * lib/snprintf.c: Remove comments as to why each header is needed.
14933
14934 2004-10-01  Bruno Haible  <bruno@clisp.org>
14935
14936         * MODULES.html.sh: Add strsep.
14937
14938 2004-09-30  Simon Josefsson  <jas@extundo.com>
14939
14940         * modules/snprintf: New file.
14941
14942 2004-09-30  Simon Josefsson  <jas@extundo.com>
14943
14944         * m4/snprintf.m4: New file.
14945
14946 2004-09-30  Simon Josefsson  <jas@extundo.com>
14947
14948         * lib/snprintf.h, lib/snprintf.c: New files.
14949
14950 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
14951
14952         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
14953         (hol_entry_help): Never translate an empty string.
14954         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
14955         * lib/argp.h (OPTION_NO_TRANS): New option.
14956
14957 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14958
14959         * modules/argp (Maintainer): Replace Simon Josefsson
14960         by Sergey Poznyakoff.
14961
14962 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14963
14964         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
14965         changes merged back into glibc.
14966
14967 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
14968
14969         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
14970
14971 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14972
14973         * lib/xvasprintf.c: Include xalloc.h.
14974         (xvasprintf): Use xalloc_die, not xmalloc_die.
14975
14976 2004-09-29  Bruno Haible  <bruno@clisp.org>
14977
14978         * modules/alloca-opt: New file, derived from modules/alloca.
14979         * modules/allocsa: Depend on alloca-opt instead of alloca.
14980         * modules/setenv: Likewise.
14981         * modules/vasnprintf: Likewise.
14982         * MODULES.html.sh: Add alloca-opt.
14983
14984 2004-09-28  Simon Josefsson  <jas@extundo.com>
14985
14986         * gnulib-tool: New parameter --lgpl, to asseert that modules are
14987         LGPL, and to replace license template from GPL to LGPL.
14988
14989 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14990
14991         * modules/dummy: Change license to LGPL.
14992
14993 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
14994
14995         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
14996
14997 2004-09-24  Simon Josefsson  <jas@extundo.com>
14998
14999         * modules/minmax (License): Change from GPL to LGPL.
15000
15001 2004-09-23  Simon Josefsson  <jas@extundo.com>
15002
15003         * gnulib-tool (--import): Typo.
15004
15005 2004-09-23  Simon Josefsson  <jas@extundo.com>
15006
15007         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
15008
15009 2004-09-22  Bruno Haible  <bruno@clisp.org>
15010
15011         * modules/*: Add 'License' field.
15012         * gnulib-tool: Accept --extract-license option.
15013         (func_get_license): New function.
15014
15015 2004-09-21  Bruno Haible  <bruno@clisp.org>
15016
15017         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
15018         Reported by Simon Josefsson.
15019
15020 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
15021
15022         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
15023         gl_AC_TYPE_LONG_LONG.
15024
15025 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
15026
15027         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
15028
15029 2004-09-18  Simon Josefsson  <jas@extundo.com>
15030         and  Paul Eggert  <eggert@cs.ucla.edu>
15031
15032         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
15033         calls with autoreconf.  Define GL_LIB.
15034
15035 2004-09-14  Karl Berry  <karl@gnu.org>
15036
15037         * config/srclist.txt: unsync setenv.c, sigh.
15038
15039 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
15040
15041         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
15042         Problem reported by Bruno Haible in:
15043         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
15044
15045 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
15046
15047         * config/srclist.txt: Comment out argp-pvh.c.
15048
15049 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
15050
15051         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
15052         in case some system header has #define'd it.  Problem reported by
15053         Soeren D. Schulze in
15054         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
15055
15056 2004-09-09  Karl Berry  <karl@gnu.org>
15057
15058         * regex.[ch]: delete from the root.  These were supposed to be
15059                 synced with emacs cvs, but this has not happened for about
15060                 a year, and anyway nothing else uses emacs regex.[ch].
15061                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
15062                 lib/regex[.ch] is untouched.
15063
15064 2004-09-09  Bruno Haible  <bruno@clisp.org>
15065
15066         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
15067
15068 2004-09-09  Bruno Haible  <bruno@clisp.org>
15069
15070         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
15071         modifications.
15072         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
15073
15074 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
15075
15076         * modules/xvasprintf: New file.
15077         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
15078
15079 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
15080
15081         * lib/xvasprintf.h: New file.
15082         * lib/xvasprintf.c: New file.
15083         * lib/xasprintf.c: New file.
15084
15085 2004-09-08  Bruno Haible  <bruno@clisp.org>
15086
15087         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
15088
15089 2004-09-08  Bruno Haible  <bruno@clisp.org>
15090
15091         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
15092         length is > INT_MAX.
15093         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
15094         more.
15095
15096 2004-09-08  Bruno Haible  <bruno@clisp.org>
15097
15098         * lib/stdint_.h: New file, taken from GNU clisp.
15099
15100 2004-09-08  Bruno Haible  <bruno@clisp.org>
15101             Oskar Liljeblad  <oskar@osk.mine.nu>
15102
15103         * modules/stdint: New file.
15104         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
15105
15106 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15107
15108         Import from coreutils.
15109         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
15110         strings on unbounded length.  alloca's performance benefits aren't
15111         that important here.
15112         (V_STRDUP): Remove.
15113         (parse_with_separator): New function, with most of the internals
15114         of the old parse_user_spec.  Allow user to omit both user and group,
15115         for compatibility with FreeBSD.
15116         Clone only the user name, not the entire spec.
15117         Do not set *uid, *gid unless entirely successful.
15118         Avoid memory leak in some failing cases.
15119         Fix regression for USER.GROUP reported by Dmitry V. Levin in
15120         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
15121         (parse_user_spec): Rewrite to use parse_with_separator.
15122
15123 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15124
15125         * modules/userspec: Don't depend on alloca.
15126
15127 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15128
15129         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
15130
15131 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15132
15133         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
15134         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
15135         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
15136
15137 2004-08-16  Simon Josefsson  <jas@extundo.com>
15138
15139         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
15140         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
15141         Add --dry-run for --import.
15142         Let user provided command line parameters override configure.ac
15143         settings.
15144
15145 2004-08-12  Simon Josefsson  <jas@extundo.com>
15146
15147         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
15148         as discussed with Paul Eggert in threads rooted at
15149         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
15150         and
15151         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
15152         Before, the test was empty, and relied on ELIDE_CODE in source
15153         code.)
15154         (gl_PREREQ_GETOPT): New macro.
15155         (gl_GETOPT): Use them.
15156
15157 2004-08-12  Simon Josefsson  <jas@extundo.com>
15158
15159         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
15160         * lib/getopt_.h: Renamed from getopt.h.
15161
15162 2004-08-12  Simon Josefsson  <jas@extundo.com>
15163
15164         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
15165         Change default library name from libfoo to libgnu.
15166         Now, if you have a configure.ac that says:
15167                 gl_SOURCE_BASE(gl)
15168                 gl_M4_BASE(gl/m4)
15169                 gl_MODULES(error getopt etcetera)
15170                 gl_INIT
15171         you can import all you need by running:
15172                 ../gnulib/gnulib-tool --import
15173
15174         * modules/getopt (Files): Rename getopt.h to getopt_.h.
15175         (Makefile.am): Rewrite, use logic from argz.
15176         (Include): Use <getopt.h> instead of "getopt.h".
15177
15178 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15179
15180         * modules/argp (Files): Add m4/unlocked-io.m4.
15181         (Depends-on): Add extensions.
15182
15183 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15184
15185         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
15186         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
15187         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
15188         Check for program_invocation_name, program_invocation_short_name,
15189         flockfile, funlockfile, features.h, _getopt_long_only_r.
15190
15191 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15192
15193         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
15194         its complicated substitute.
15195         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
15196         and program_invocation_name.
15197         (__argp_basename) [!_LIBC]: Remove; the only use was
15198         replaced by its body.
15199         (__argp_short_program_name): Change condition from
15200         !defined __argp_short_program_name to
15201         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
15202         to match argp-namefrob.h.
15203         (__argp_failure): Don't assume strerror_r returns char *.
15204         * lib/argp-parse.c (N_): Define unconditionally.
15205         (argp_default_options): Fill out initializers with 0 to avoid
15206         gcc warnings.
15207
15208 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
15209
15210         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
15211         getopt1.c.
15212
15213 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15214
15215         Merge from coreutils.
15216
15217         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
15218
15219         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
15220         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
15221
15222 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15223
15224         Merge from coreutils.
15225
15226         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
15227         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
15228         for Reliant Unix 5.43.
15229
15230         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
15231         (union fooround): Use uintmax_t, not long int.
15232         The rest is a merge from libc:
15233         [defined _LIBC]: Include <shlib-compat.h>.
15234         (_obstack) [defined _LIBC]: Remove after 2.3.4.
15235
15236         * lib/settime.c (settime): Recode to avoid warning with
15237         Sun Forte C 6U2.
15238
15239         * lib/strverscmp.c: Convert to UTF-8.
15240
15241 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
15242
15243         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
15244         m4/uintmax_t.m4.
15245
15246 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15247
15248         * modules/xalloc-die: New file.
15249         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
15250
15251         * modules/md5 (Files): Add m4/uint32_t.m4.
15252         * modules/sha1: Renamed from modules/sha.
15253         (Files):
15254         Rename lib/sha.h to lib/sha1.h.
15255         Rename lib/sha.c to lib/sha1.c.
15256         Rename m4/sha.m4 to m4/sha1.m4.
15257         (lib_SOURCES): Likewise.
15258         (configure.ac): Rename gl_SHA to gl_SHA1.
15259         (Include): sha.h -> sha1.h.
15260
15261 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15262
15263         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
15264         * m4/sha1.m4: Renamed from sha.m4.
15265         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
15266
15267 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
15268
15269         * lib/obstack.h (obstack_empty_p):
15270         Don't assume that chunk->contents is suitably aligned.
15271         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
15272         Likewise. Problem reported by Benno in
15273         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
15274
15275         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
15276         readable.  This could be improved further but it'd take some work.
15277
15278 2004-08-08  Simon Josefsson  <jas@extundo.com>
15279
15280         * modules/xgethostname (Depends-on): Remove exit and error (not
15281         used).
15282
15283         * modules/getpass-gnu: Add getpass.h.
15284         (Depends-on): Add stdbool.
15285         * modules/getpass: Add getpass.h.
15286
15287 2004-08-08  Simon Josefsson  <jas@extundo.com>
15288
15289         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
15290         Check getpass declaration.
15291
15292 2004-08-08  Simon Josefsson  <jas@extundo.com>
15293
15294         * lib/xgethostname.c: Don't include error.h (not used).
15295
15296         * lib/getpass.h: Add.
15297         * lib/getpass.c: Include getpass.h first.
15298
15299 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
15300
15301         * lib/xalloc-die.c: New file.
15302         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
15303         All uses removed.
15304         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
15305         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
15306         xalloc-die.c.
15307         (_, N_, xalloc_die): Move to xalloc-die.c.
15308         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
15309         so that we needn't mess with xalloc_msg_memory_exhausted.
15310
15311         * lib/sha1.h: Renamed from sha.h.
15312         (SHA1_H): Renamed from _SHA_H.
15313         (sha1_ctx): Renamed from sha_ctx.
15314         (sha1_init_ctx): Renamed from sha_init_ctx.
15315         (sha1_process_block): Renamed from sha_process_block.
15316         (sha1_process_bytes): Renamed from sha_process_bytes.
15317         (sha1_finish_ctx): Renamed from sha_finish_ctx.
15318         (sha1_read_ctx): Renamed from sha_read_ctx.
15319         (sha1_stream): Renamed from sha_stream.
15320         (sha1_buffer): Renamed from sha_buffer.
15321         * lib/sha1.c: Likewise; renamed from sha.c.
15322         Do not include <sys/types.h>.
15323         Include <stddef.h> rather than <stdlib.h>.
15324
15325 2004-08-08  Bruno Haible  <bruno@clisp.org>
15326
15327         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
15328         FILESYSTEM_PREFIX_LEN.
15329         * lib/progreloc.c: Likewise.
15330         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
15331
15332 2004-08-06  Simon Josefsson  <jas@extundo.com>
15333
15334         * modules/progname (Depends-on): Don't depend on stdbool.
15335
15336 2004-08-06  Simon Josefsson  <jas@extundo.com>
15337
15338         * modules/getsubopt: New file.
15339         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15340         getsubopt.
15341
15342 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15343
15344         More merge from coreutils.
15345
15346         * m4/utimens.m4, m4/utimecmp.m4: New files.
15347         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
15348         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
15349         prereq.m4, sha.m4: Import changes from coreutils.
15350
15351 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15352
15353         More merge from coreutils.
15354         * modules/raise, modules/readtokens0, modules/utimens:
15355         * modules/utimecmp, module/xnanosleep: New files.
15356         * modules/strftime: Add lib/strftime.h.
15357         Change include from <time.h> to "strftime.h".
15358         * modules/yesno: Add lib/yesno.h.
15359         * modules/backupfile: Remove lib/addext.c.
15360         * modules/euidaccess: Add stat-macros.h.
15361         * modules/canonicalize, modules/euidaccess,
15362         modules/filemode, modules/lchown, modules/makepath,
15363         modules/rmdir, modules/stat: Likewise.
15364
15365 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
15366
15367         Merge from tar.
15368         * lib/argp-help.c (make_hol, hol_append): Don't assume that
15369         SIZE_MAX is a valid preprocessor constant.
15370         (__argp_basename): Change from "#ifndef _LIBC"
15371         to "#ifndef __argp_short_program_name", so that
15372         we don't compile these functions for tar.
15373
15374         More merges from coreutils.
15375         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
15376         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
15377         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
15378         * lib/addext.c: Remove; no longer needed.
15379         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
15380         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
15381         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
15382         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
15383         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
15384         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
15385         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
15386         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
15387         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
15388         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
15389         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
15390         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
15391         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
15392         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
15393         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
15394         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
15395         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
15396         Import changes from coreutils.
15397
15398 2004-08-05  Simon Josefsson  <jas@extundo.com>
15399
15400         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
15401
15402 2004-08-05  Simon Josefsson  <jas@extundo.com>
15403
15404         * m4/getsubopt.m4: New file.
15405
15406 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15407
15408         Merge from coreutils.
15409
15410         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
15411         * m4/getcwd-path-max.m4: New files.
15412
15413         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
15414         FILESYSTEM_PREFIX_LEN ->
15415         FILE_SYSTEM_PREFIX_LEN.
15416         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
15417         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
15418         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
15419         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
15420
15421         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
15422         prerequisite modules now handle the DOS stuff.
15423         Don't check for unistd.h.
15424
15425 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15426
15427         Merge from coreutils.
15428
15429         * lib/.gdb-history: Remove; this doesn't belong here.
15430
15431         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
15432         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
15433         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
15434         * lib/getcwd.c: New files.
15435
15436         * lib/dirname.h: Include <stdbool.h>.
15437         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
15438         for consistency with POSIX terminology.  All uses changed.
15439         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
15440         (strip_trailing_slashes): Use bool for booleans.
15441         * lib/stripslash.c (strip_trailing_slashes): Likewise.
15442
15443         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
15444         sometimes returns a positive errno value even when it succeeds.
15445         (print_errno_message) [!LIBC]: Fall back on strerror if
15446         __strerror_r fails.
15447
15448         * lib/path-concat.c (mempcpy): Don't define if a system header defines
15449         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
15450         (longest_relative_suffix): New function.
15451         (path_concat): Use it.  Assume first argument is not NULL.
15452         Port to DOS.  Omit redundant separators.
15453         Report an error instead of returning NULL.
15454         Use mempcpy instead of memcpy.
15455         (xpath_concat): Remove: not declared or used.
15456
15457         * lib/same.h: Include <stdbool.h>
15458         (same_name): Return bool, not int.
15459         * lib/same.c (same_name): Likewise.
15460         (errno): Don't declare; we assume C89 or better now.
15461
15462         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
15463         if not already defined.
15464
15465         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
15466         * lib/dup-safer.c (errno): Likewise.
15467
15468 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
15469
15470         Merge from coreutils.
15471         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
15472         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
15473         * modules/path-concat: Don't depend on strdup.
15474
15475 2004-08-03  Simon Josefsson  <jas@extundo.com>
15476
15477         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
15478         * lib/progname.h: Don't include stdbool.h.
15479
15480 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15481
15482         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
15483         * MODULES.html.sh (func_all_modules): Remove fatal.
15484
15485 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15486
15487         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
15488
15489 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
15490
15491         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
15492         working.
15493
15494 2004-08-02  Simon Josefsson  <jas@extundo.com>
15495
15496         * lib/getsubopt.h: New file, with comments from Bruno Haible.
15497         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
15498         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
15499
15500 2004-08-01  Simon Josefsson  <jas@extundo.com>
15501
15502         * lib/xgetdomainname.c: Include stdlib.h, for free().
15503
15504 2004-07-19  Bruno Haible  <bruno@clisp.org>
15505
15506         * MODULES.html.sh (func_all_modules): Add dummy.
15507
15508 2004-07-16  Simon Josefsson  <jas@extundo.com>
15509
15510         * modules/dummy: New file.
15511
15512 2004-07-16  Simon Josefsson  <jas@extundo.com>
15513
15514         * lib/dummy.c: New file.
15515
15516 2004-07-16  Bruno Haible  <bruno@clisp.org>
15517
15518         * lib/backupfile.h: Add extern "C" for C++.
15519         * lib/closeout.h: Likewise.
15520         * lib/copy-file.h: Likewise.
15521         * lib/findprog.h: Likewise.
15522         * lib/full-write.h: Likewise.
15523         * lib/pathname.h: Likewise.
15524         * lib/progname.h: Likewise.
15525         * lib/stpcpy.h: Likewise.
15526         * lib/stpncpy.h: Likewise.
15527         * lib/strcase.h: Likewise.
15528         * lib/strstr.h: Likewise.
15529         * lib/xalloc.h: Likewise.
15530
15531         * lib/mbswidth.h: Add extern "C" for C++.
15532         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
15533
15534 2004-07-13  Robert Millan  <robertmh@gnu.org>
15535
15536         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
15537
15538 2004-07-09  Simon Josefsson  <jas@extundo.com>
15539
15540         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
15541         failed without this.)
15542
15543 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15544
15545         * modules/chown (Files): Add lib/fchown-stub.c, since
15546         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
15547
15548 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
15549
15550         * lib/fchown-stub.c: New file.
15551
15552 2004-06-24  Jim Meyering  <jim@meyering.net>
15553
15554         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
15555
15556 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15557
15558         * modules/argz: Omit "#include".
15559
15560         * MODULES.html.sh (func_all_modules): Add calloc, to match
15561         2004-06-01 addition of calloc module.
15562
15563 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15564
15565         * m4/argz.m4: New file, which is autoupdated from libtool.
15566
15567 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15568
15569         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
15570         libtool.
15571
15572 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15573
15574         * config/srclist-update: Don't insist on "USA." before the
15575         close-comment, as libtool omits the period and puts the */ on a
15576         separate line.
15577         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
15578         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
15579
15580 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
15581
15582         * modules/argz: New file.
15583         * MODULES.html.sh (func_all_modules): Add argz.
15584
15585 2004-06-12  Jim Meyering  <jim@meyering.net>
15586         and  Paul Eggert  <eggert@cs.ucla.edu>
15587
15588         * modules/hash (Files): Add lib/xalloc.h.
15589         * modules/pipe (Depends-on): Add wait-process.
15590         * modules/stat (Depends-on): Add xalloc.
15591         * modules/userspec (Files): Add lib/userspec.h.
15592         * modules/xstrto
15593
15594         Upgrade from gettext-0.13.
15595         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
15596         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
15597         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
15598
15599 2004-06-10  Jim Meyering  <jim@meyering.net>
15600
15601         * lib/calloc.c: New file.
15602
15603 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
15604
15605         * lib/getdate.y (yylex): Allow space between sign and number.
15606         Problem reported by Dan Jacobson.
15607
15608 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15609
15610         Merge from coreutils CVS.
15611
15612         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
15613         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
15614         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
15615         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
15616         xstrtol.m4: Fix copyright date and/or serial number.
15617
15618         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
15619         See if we need an fchown replacement.
15620         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
15621         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
15622         and use the replacement function if we detect either defect.
15623
15624         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
15625         gl_UTIMECMP.
15626
15627 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
15628         and  Jim Meyering  <jim@meyering.net>
15629
15630         Merge from coreutils CVS.
15631
15632         * lib/stat-macros.h: New file, with contents from file-type.h
15633         and coreutils' system.h.
15634         * lib/file-type.c: Include "stat-macros.h".
15635         * lib/file-type.h (file_type): Move all macro definitions to new file,
15636         stat-macros.h.
15637
15638         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
15639         Wrap old code with this conditional.
15640         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
15641         function that does not dereference symlinks.
15642         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
15643
15644         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
15645         dependency problems.
15646         (xreadlink): Accept new arg SIZE, for efficiency.
15647         All decls and uses changed.
15648         * lib/xreadlink.h: Include <stddef.h>, for size_t.
15649
15650         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
15651         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
15652
15653         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
15654         sysexits.h.
15655
15656 2004-06-01  Jim Meyering  <jim@meyering.net>
15657
15658         * m4/calloc.m4: New file.
15659
15660 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
15661
15662         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
15663         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
15664         Also, fix a typo in a diagnostic.
15665
15666 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15667
15668         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
15669         or AC_FUNC_REALLOC.
15670
15671 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
15672
15673         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
15674         macros to be defined.
15675         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
15676         the allocator returns NULL because the requested size is zero.
15677
15678 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
15679
15680         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
15681         var.  Add comment explaining why libc still defines it.  This
15682         merges the following patch from glibc:
15683         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
15684
15685 2004-05-20  Andreas Schwab  <schwab@suse.de>
15686
15687         * m4/free.m4: Replace free if it not known to work, not the other
15688         way round.
15689
15690 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
15691
15692         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
15693         present in glibc since revision 1.1 of this file.
15694         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
15695         obstack_alignment_mask, obstack_alloc, obstack_base,
15696         obstack_blank, obstack_blank_fast, obstack_chunk_size,
15697         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
15698         obstack_grow0, obstack_init, obstack_int_grow,
15699         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
15700         obstack_next_free, obstack_object_size, obstack_ptr_grow,
15701         obstack_ptr_grow_fast, obstack_room): Remove declarations of
15702         nonexistent functions.
15703
15704 2004-05-18  Karl Berry  <karl@gnu.org>
15705
15706         * config/srclist.txt: break link for vasnprintf.c.
15707
15708 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15709
15710         Port obstack to the AS/400, where pointers are 16 bytes wide and
15711         you cannot cast an integer to a valid pointer.  This patch is
15712         currently waiting to be integrated into glibc; see
15713         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
15714
15715         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
15716         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
15717         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
15718         (struct obstack): temp member is now a union of a pointer and
15719         an integer, instead of an integer.  All integer uses changed.
15720         This does not affect the physical layout of struct obstack,
15721         except on hosts (like the AS/400) where the size or alignment of
15722         void * is greater than that of ptrdiff_t.
15723         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
15724         __STDC__)]: Store temporary in pointer member of union, not
15725         integer member.
15726         * lib/obstack.c: Include <stddef.h>, for offsetof.
15727         (struct fooalign): Remove; it doesn't need a name.
15728         (union fooround): Change double to long double, and add void *.
15729         (DEFAULT_ALIGNMENT): Use offsetof to compute.
15730         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
15731         not a macro.  Hence the values are always int; so remove all
15732         casts-to-int in uses.
15733
15734 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
15735
15736         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
15737         we can get this patch merged into glibc.
15738
15739 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15740             Paul Eggert  <eggert@cs.ucla.edu>
15741
15742         * m4/argp: Depend on alloca.
15743
15744 2004-05-17  Derek R. Price  <derek@ximbiot.com>
15745             Paul Eggert  <eggert@cs.ucla.edu>
15746
15747         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
15748         freecoding.
15749
15750 2004-05-17  Bruno Haible  <bruno@clisp.org>
15751
15752         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
15753         precision that consists of a '.' followed by an empty digit string.
15754         Patch by Tor Lillqvist <tml@iki.fi>.
15755
15756 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15757
15758         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
15759         for backward compatibility with older code.  We need our own
15760         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
15761         it under some other name, and our alloca.h will define it.
15762
15763 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
15764             Derek Price  <derek@ximbiot.com>
15765
15766         * lib/alloca.c: Include <alloca.h>, to get our interface.
15767         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
15768         include <alloca.h> first.  Use C89 prototype for alloca; this
15769         requires including <stddef.h> for size_t.  Use extern "C" if C++.
15770         Use #elif for simplicity, since we can assume C89 now.
15771         Don't try to source the system alloca.h since it will not be found
15772         and to prevent recursively including its replacement.
15773         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
15774         * lib/regex.c: Likewise.
15775
15776 2004-05-16  Derek Price  <derek@ximbiot.com>
15777             Paul Eggert  <eggert@cs.ucla.edu>
15778
15779         getline cleanup.  This changes the getndelim2 API: both order of
15780         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
15781         no delimiter).
15782
15783         * lib/getline.c: Don't include stddef.h or stdio.h, since our
15784         interface does that.
15785         (getline): Always use getdelim, so that we don't have two
15786         copies of this code.
15787         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
15788         if available.
15789         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
15790         (GETNDELIM2_MAXIMUM): New macro.
15791         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
15792         instead of the old practice of delim2==0.  All callers changed.
15793         Return -1 on overflow, instead of returning junk.
15794         Do not set *linesize unless allocation succeeds.
15795         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
15796         that we include sys/types.h.
15797         * lib/getnline.h: Likewise.
15798         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
15799         (getndelim2): Reorder arguments.
15800         * lib/getnline.c (getnline, getndelim):
15801         Don't discard the NMAX argument.
15802         (getnline): Invoke getndelim, to avoid code duplication.
15803         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
15804         of (size_t) -1 by callers of the getnline family.
15805
15806 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15807
15808         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
15809         Check for gettimeofday.
15810         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
15811         Check for settimeofday, stime.
15812
15813 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
15814
15815         * lib/nanosleep.c (suspended): Change its type from int to
15816         sig_atomic_t volatile.
15817         (first_call): Make it private to rpl_nanosleep, and have it
15818         be zero initially as that's a bit faster.
15819         (my_usleep): Round up fractional times instead of truncating them,
15820         as this is the usual meaning for 'sleep'.
15821
15822         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
15823         doesn't work.
15824         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
15825         (ENOSYS): Define if not defined.
15826         (settime): Fall back on stime if it exists and settimeofday fails.
15827         But don't bother with fallbacks if a method fails with errno == EPERM.
15828
15829 2004-05-11  Jim Meyering  <jim@meyering.net>
15830
15831         Prior to this change, the save_cwd caller required read access to the
15832         current directory on most systems (ones with the fchdir function).
15833
15834         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
15835         fails, try write-only, and finally, resort to using xgetcwd.
15836
15837 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
15838
15839         * lib/obstack.c, obstack.h: Import changes from libc.
15840
15841 2004-04-28  Bruno Haible  <bruno@clisp.org>
15842
15843         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
15844         also implicitly appends .exe to executables.
15845         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
15846         accepts Windows pathnames.
15847         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15848         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15849         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
15850         Treat Cygwin like Windows, since it now accepts Windows pathnames.
15851         Reported by Derek Robert Price <derek@ximbiot.com>.
15852
15853 2004-04-21  Karl Berry  <karl@gnu.org>
15854
15855         * config/srclist.txt (localcharset.c): break sync.
15856
15857 2004-04-20  Paul Eggert  <eggert@twinsun.com>
15858
15859         * m4/host-os.m4: Add a copyright notice.
15860
15861 2004-04-20  Jim Meyering  <jim@meyering.net>
15862
15863         Change UTILS_ to gl_ in AC_DEFINE'd names.
15864         Change utils_- and jm_-prefixed variables, too.
15865         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
15866         UTILS_FUNC_MKDIR_TRAILING_SLASH.
15867         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
15868
15869         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
15870         Don't emit trailing blanks.
15871         Also rename jm_-prefixed variables to have gl_ prefix.
15872
15873         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
15874         Also rename jm_-prefixed variables to have gl_ prefix.
15875
15876         * m4/jm-macros.m4: Reflect the renamings.
15877         * m4/prereq.m4: Likewise.
15878
15879 2004-04-20  Jim Meyering  <jim@meyering.net>
15880
15881         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
15882         memory.
15883
15884 2004-04-20  Jim Meyering  <jim@meyering.net>
15885             Bruno Haible  <bruno@clisp.org>
15886
15887         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
15888         memory when realloc fails.
15889
15890 2004-04-19  Jim Meyering  <jim@meyering.net>
15891
15892         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
15893         now that readutmp.c may call `free (0)'.
15894
15895 2004-04-19  Bruno Haible  <bruno@clisp.org>
15896
15897         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
15898         * m4/inttypes_h.m4: Likewise.
15899         * m4/stdint_h.m4: Likewise.
15900         * m4/intmax_t.m4: Likewise.
15901         * m4/uintmax_t.m4: Likewise.
15902
15903 2004-04-18  Jim Meyering  <jim@meyering.net>
15904
15905         * m4/prereq.m4: Don't forbid jm_ prefix.
15906
15907         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
15908         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
15909         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
15910         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
15911         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
15912         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
15913         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
15914         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
15915         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
15916         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
15917         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
15918         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
15919         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
15920         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
15921         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
15922         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
15923         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
15924         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
15925         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
15926
15927 2004-04-18  Jim Meyering  <jim@meyering.net>
15928
15929         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
15930         failure, don't leak memory and do call END_UTMP_ENT.
15931
15932 2004-04-16  Jim Meyering  <jim@meyering.net>
15933
15934         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
15935         coreutils' stat program.
15936         (gl_PREREQ): Don't require jm_PREREQ_STAT.
15937
15938 2004-04-11  Paul Eggert  <eggert@twinsun.com>
15939
15940         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
15941         C89.
15942         (CHAR_BIT): Remove, since we assume C89.
15943         Include <stdint.h> if available, as per current Autoconf CVS advice.
15944
15945 2004-03-31  Jim Meyering  <jim@meyering.net>
15946
15947         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
15948         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
15949         * m4/xalloc.m4: Likewise.
15950
15951 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15952
15953         Merge from coreutils.
15954
15955         * m4/inttostr.m4: New file.
15956         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
15957         Require AM_STDBOOL_H and gl_TIMESPEC instead.
15958         Require gl_CLOCK_TIME.
15959         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
15960
15961 2004-03-30  Paul Eggert  <eggert@twinsun.com>
15962
15963         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
15964         not bool, to be more consistent with Unix conventions.
15965         Suggested by Bruno Haible.
15966
15967         Merge from coreutils.
15968
15969         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
15970         * lib/umaxtostr.c: New files.
15971
15972         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
15973         the usual <time.h> dance.
15974         (get_date): Change signature to support fractional time stamps.
15975         All callers changed.
15976         * lib/getdate.y: Include "getdate.h" first, as we can now
15977         assume C89 and don't need to worry about 'const'.
15978         Similarly, include "unlocked-io.h" near start, not in middle.
15979         Include <limits.h>.
15980         (textint.value): Use long int rather than int.
15981         (textint.digits): Use size_t rather than int.
15982         (BILLION, LOG10_BILLION): New constants.
15983         (parser_control): New member rel_ns.  Members day_ordinal,
15984         time_zone, month, day, hour, minutes, rel_year, rel_month,
15985         rel_day, rel_hour, rel_minutes, rel_seconds
15986         are now long int, not int.  Member seconds is now struct timespec,
15987         not int.  New member timespec_seen.  Members dates_seen, days_seen,
15988         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
15989         not int.
15990         (%union.intval): Now long int, not int.
15991         New member timespec.
15992         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
15993         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
15994         (spec): Now is a timespec or an item list.
15995         (timespec, items): New nonterminals.
15996         (time, rel, relunit, number, get_date):
15997         Add support for fractional seconds.
15998         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
15999         (gmtime, localtime, mktime): Remove decls; not needed with C89.
16000         (to_hour): First arg is now long int, not int.
16001         (to_year): Returns long int, not int.
16002         Don't treat year -70 like 70.
16003         (tm_diff): Returns long int, not int.
16004         (lookup_word): Use bool instead of int when appropriate.
16005         (yylex): Use size_t for count, not int.
16006         Detect overflow when parsing large integer constants.
16007         Add support for fractions.
16008         (get_date): Make pointers 'const' if possible.
16009         Use more-portable code to detect integer overflow.
16010         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
16011         Don't use ctime; it's not reliable if the year has >4 digits.
16012
16013         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
16014         This is for compatibility with BSD.
16015
16016         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
16017         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
16018         From coreutils' system.h.
16019
16020         * lib/userspec.c: Don't include "posixver.h".
16021         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
16022         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
16023         compatible extension.  Simplify code by removing a boolean int
16024         that was always nonzero if a string was nonnull.
16025
16026 2004-03-30  Jim Meyering  <jim@meyering.net>
16027
16028         Merge from coreutils.
16029
16030         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
16031         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
16032         on some systems one must include <grp.h> before it.
16033         Reported by Christian Krackowizer.
16034
16035 2004-03-30  Jim Meyering  <jim@meyering.net>
16036
16037         Merge from coreutils.
16038
16039         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
16040
16041         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
16042         an empty input stream.
16043
16044         * lib/readtokens.c: Include <stdbool.h>.
16045         (readtoken): Use `size_t' rather than int/long.
16046         All callers adjusted.
16047         Use `bool' rather than `int' where appropriate.
16048         Use memset rather than an explicit loop.
16049         Use x2nrealloc rather than xrealloc.
16050         Allow the use of `\0' as a delimiter.
16051         (readtokens): Likewise.
16052         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
16053
16054 2004-03-30  Jim Meyering  <jim@meyering.net>
16055
16056         * m4/realloc.m4: Remove file, since now it does no more than
16057         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
16058         the `configure.ac' section of module/realloc.
16059         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
16060
16061 2004-03-30  Bruno Haible  <bruno@clisp.org>
16062
16063         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
16064         nonnull.
16065
16066 2004-03-29  Paul Eggert  <eggert@twinsun.com>
16067
16068         Merge changes to getloadavg.c from coreutils and Emacs.
16069
16070         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
16071         Define to an expression, not to the empty string.
16072         Include cloexec.h and xalloc.h.
16073         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
16074         Use set_cloexec_flag rather than rolling our own.
16075         * lib/cloexec.c, lib/cloexec.h: New files.
16076
16077 2004-03-29  Paul Eggert  <eggert@twinsun.com>
16078
16079         * m4/cloexec.m4: New file.
16080
16081 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16082
16083         * lib/getopt.h: Sync with libc CVS.
16084
16085 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16086             Bruno Haible  <bruno@clisp.org>
16087
16088         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
16089         mbswidth.
16090
16091 2004-03-18  Paul Eggert  <eggert@twinsun.com>
16092             Bruno Haible  <bruno@clisp.org>
16093
16094         * lib/mbswidth.h: Include <wchar.h> only if
16095         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
16096         <wchar.h>.
16097         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
16098
16099 2004-03-09  Paul Eggert  <eggert@twinsun.com>
16100
16101         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
16102         Sync with libc CVS.
16103         * lib/getopt_int.h: New file, also synced from libc.
16104
16105 2004-03-09  Paul Eggert  <eggert@twinsun.com>
16106
16107         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
16108         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
16109         Bring back getopt.c, getopt.h, getopt1.c.
16110
16111 2004-03-07  Paul Eggert  <eggert@twinsun.com>
16112
16113         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
16114         All uses changed.  Check for sa_sigaction member; this fixes
16115         a bug first reported by Jason Andrade in
16116         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
16117
16118 2004-03-07  Paul Eggert  <eggert@twinsun.com>
16119
16120         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
16121         '#if' expressions.  Unlike the code it replaces, it does not
16122         depend on (defined _SC_PAGESIZE).  However, it does depend on
16123         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
16124         first reported by Jason Andrade in
16125         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
16126
16127 2004-02-25  Simon Josefsson  <jas@extundo.com>
16128
16129         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
16130
16131 2004-02-25  Simon Josefsson  <jas@extundo.com>
16132
16133         * lib/strdup.h: New file.
16134         * lib/strdup.c: Include it.
16135         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
16136         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
16137
16138 2004-02-23  Karl Berry  <karl@gnu.org>
16139
16140         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
16141         (from fencepost.gnu.org:/gd/gnuorg).
16142
16143 2004-02-23  Karl Berry  <karl@gnu.org>
16144
16145         * config/srclistvars.sh (GNUORG) [karl]: redefine.
16146         * config/srclist.txt: add maintain/standards documents.
16147
16148 2004-02-18  Bruno Haible  <bruno@clisp.org>
16149
16150         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
16151         Reported by Derek Robert Price <derek@ximbiot.com>.
16152
16153 2004-02-16  Karl Berry  <karl@gnu.org>
16154
16155         * config/mkinstalldirs, install-sh: update from automake.
16156
16157 2004-02-06  Karl Berry  <karl@gnu.org>
16158
16159         * m4/po.m4: update from gettext 0.14.1.
16160
16161 2004-02-06  Karl Berry  <karl@gnu.org>
16162
16163         * lib/config.charset: update from gettext 0.14.1.
16164
16165 2004-02-05  Paul Eggert  <eggert@twinsun.com>
16166
16167         Add comments and code, prompted by suggestions from Bruno Haible
16168         for sh-quote.
16169         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
16170         describing the enum quoting_style values.
16171         * lib/quotearg.c (quotearg_alloc): New function.
16172         (quotearg_buffer_restyled): Treat lone { and } as special.
16173         Treat = as special.  Work around bug with older shells
16174         that "see" a '\' that is really the 2nd byte of a multibyte char.
16175         Quote empty string with shell_quoting_style.
16176
16177 2004-02-03  Bruno Haible  <bruno@clisp.org>
16178
16179         * m4/pipe.m4: New file, from GNU gettext.
16180
16181 2004-02-03  Bruno Haible  <bruno@clisp.org>
16182
16183         * lib/pipe.h: New file, from GNU gettext.
16184         * lib/pipe.c: New file, from GNU gettext.
16185
16186 2004-01-27  Bruno Haible  <bruno@clisp.org>
16187
16188         * m4/execute.m4: New file, from GNU gettext.
16189
16190 2004-01-27  Bruno Haible  <bruno@clisp.org>
16191
16192         * lib/execute.h: New file, from GNU gettext.
16193         * lib/execute.c: New file, from GNU gettext.
16194         * lib/w32spawn.h: New file, from GNU gettext.
16195
16196 2004-01-24  Paul Eggert  <eggert@twinsun.com>
16197
16198         Merge from diffutils.
16199
16200         * lib/file-type.c (file_type): Add typed memory objects.
16201         * lib/file-type.h (S_TYPEISTMO): New macro.
16202
16203         * lib/c-stack.h (c_stack_action): Remove argv argument.
16204         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
16205         (die): Don't calculate message unless segv_action returns.
16206         (get_stack_location, min_address_from_argv, max_address_from_argv,
16207         volatile stack_base, volatile_stack_size): Remove.
16208         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
16209         that every segmentation violation is a stack overflow.  (Ouch!)
16210         See Debian bug 136249 (still outstanding) for more info about why
16211         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
16212
16213 2004-01-24  Paul Eggert  <eggert@twinsun.com>
16214
16215         Exit-status fix from coreutils.
16216
16217         Use exit_failure consistently in place of EXIT_FAILURE,
16218         so that program exit statuses are consistent on failure.
16219
16220         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
16221         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
16222         * lib/argmatch.h: Comment fix to match the above.
16223         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
16224         Now a macro referring to exit_failure, instead of a separate
16225         variable.  Include "exitfail.h" to get it.
16226         * lib/xstrtol.h: Include "exitfail.h".
16227         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
16228
16229         * lib/long-options.c (parse_long_options): Use prototype
16230         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
16231         for clarity.
16232
16233 2004-01-21  Jim Meyering  <jim@meyering.net>
16234
16235         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
16236         so as not to conflict with a different-sized __mktime_internal
16237         function in GNU libc.
16238         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
16239         Problem building statically-linked `ls' reported by Michael Brunnbauer.
16240
16241 2004-01-20  Karl Berry  <karl@gnu.org>
16242
16243         * config/config.guess: update from config.
16244
16245         * config/srclistvars.sh: GNUWWWLICENSES for karl.
16246
16247 2004-01-20  Bruno Haible  <bruno@clisp.org>
16248
16249         Safer stack allocation.
16250         * lib/setenv.c: Include allocsa.h.
16251         (alloca): Remove fallback definition.
16252         (freea): Remove macro.
16253         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
16254         instead of freea.
16255
16256 2004-01-20  Bruno Haible  <bruno@clisp.org>
16257
16258         * m4/eealloc.m4: New file, from GNU gettext.
16259
16260 2004-01-20  Bruno Haible  <bruno@clisp.org>
16261
16262         * m4/allocsa.m4: New file, from GNU gettext.
16263
16264 2004-01-20  Bruno Haible  <bruno@clisp.org>
16265
16266         * lib/xallocsa.h: New file, from GNU gettext.
16267         * lib/xallocsa.c: New file, from GNU gettext.
16268
16269 2004-01-20  Bruno Haible  <bruno@clisp.org>
16270
16271         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
16272
16273 2004-01-20  Bruno Haible  <bruno@clisp.org>
16274
16275         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
16276         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
16277         specially.
16278
16279 2004-01-20  Bruno Haible  <bruno@clisp.org>
16280
16281         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
16282         patch.
16283
16284 2004-01-20  Bruno Haible  <bruno@clisp.org>
16285
16286         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
16287
16288 2004-01-20  Bruno Haible  <bruno@clisp.org>
16289
16290         * lib/eealloc.h: New file.
16291
16292 2004-01-20  Bruno Haible  <bruno@clisp.org>
16293
16294         * lib/binary-io.h: Avoid warnings on Cygwin.
16295
16296 2004-01-20  Bruno Haible  <bruno@clisp.org>
16297
16298         * lib/allocsa.h: New file, from GNU gettext.
16299         * lib/allocsa.c: New file, from GNU gettext.
16300
16301 2004-01-18  Karl Berry  <karl@gnu.org>
16302
16303         * doc/gpl.texi, doc/lgpl.texi: new files.
16304
16305 2004-01-18  Karl Berry  <karl@gnu.org>
16306
16307         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
16308         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
16309
16310 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16311
16312         Merge from coreutils.
16313
16314         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
16315         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
16316         (gl_DEFAULT_POSIX2_VERSION): Move
16317         the documentation from 'configure' into 'config.hin',
16318         so that 'configure --help' isn't burdened by it and
16319         we don't have to worry about its formatting there.
16320         Reword the documentation so that it's more succinct
16321         and can be run together into a single paragraph.
16322         * m4/same.m4 (gl_SAME): Check for pathconf.
16323
16324 2004-01-15  Paul Eggert  <eggert@twinsun.com>
16325
16326         Merge from coreutils.
16327
16328         * lib/posixver.c: Include posixver.h.
16329
16330         * lib/same.c: Include <stdbool.h>, <limits.h>.
16331         (_POSIX_NAME_MAX): Define if not defined.
16332         (MIN): New macro.
16333         (same_name): If file names are silently truncated, report
16334         that the file names are the same if they are the same after
16335         the silent truncation.
16336
16337         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
16338         conversion function.
16339         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
16340         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
16341         longer needed.
16342
16343 2004-01-15  Jim Meyering  <jim@meyering.net>
16344
16345         Merge from coreutils.
16346
16347         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
16348         if no library is required.
16349         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
16350         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
16351         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
16352         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
16353         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
16354         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
16355         value, $ac_cv_search_crypt, if it's "none required".
16356         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
16357         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
16358         not gl_FUNC_GETLOADAVG.
16359         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
16360         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
16361
16362 2004-01-15  Jim Meyering  <jim@meyering.net>
16363
16364         Merge from coreutils.
16365
16366         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
16367         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
16368         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
16369
16370         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
16371         optional configure-time default.
16372
16373         * lib/version-etc.c (version_etc_copyright): Update copyright date.
16374
16375         * lib/xreadlink.c (xreadlink): Correct outdated comment.
16376
16377 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
16378
16379         Merge from coreutils.
16380
16381         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
16382         value, $ac_cv_search_nanosleep, if it's "none required".
16383
16384 2004-01-14  Paul Eggert  <eggert@twinsun.com>
16385
16386         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
16387         with like-named macro in fnmatch.c.
16388         (EXT): Use an internal constant instead.
16389
16390         Merge fnmatch patches from glibc.
16391         * lib/fnmatch.c (mbsinit): Remove define.
16392         Add libc_hidden_ver (__fnmatch, fnmatch).
16393         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
16394         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
16395
16396 2004-01-14  Karl Berry  <karl@gnu.org>
16397
16398         * config/install-sh: update from automake.
16399
16400 2004-01-13  Karl Berry  <karl@gnu.org>
16401
16402         * config/install-sh: update from automake.
16403
16404 2004-01-09  Karl Berry  <karl@gnu.org>
16405
16406         * config/install-sh: update from automake.
16407
16408 2004-01-05  Karl Berry  <karl@gnu.org>
16409
16410         * config/config.{sub,guess}: update from config.
16411
16412 2003-12-31  Karl Berry  <karl@gnu.org>
16413
16414         * config/depcomp: update from automake.
16415
16416 2003-12-14  Karl Berry  <karl@gnu.org>
16417
16418         * lib/config.charset: update from gettext-runtime.
16419
16420 2003-12-03  Paul Eggert  <eggert@twinsun.com>
16421
16422         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
16423         Bug reported by Alfred M. Szmidt.
16424
16425 2003-12-03  Bruno Haible  <bruno@clisp.org>
16426
16427         * m4/gettext.m4: Upgrade from gettext-0.13.
16428         * m4/po.m4: Upgrade from gettext-0.13.
16429         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
16430         * m4/intmax.m4: New file, from gettext-0.13.
16431         * m4/printf-posix.m4: New file, from gettext-0.13.
16432
16433 2003-11-29  Karl Berry  <karl@gnu.org>
16434
16435         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
16436
16437 2003-11-25  Paul Eggert  <eggert@twinsun.com>
16438             Bruno Haible  <bruno@clisp.org>
16439
16440         * lib/printf-parse.h: Don't include sys/types.h.
16441         (ARG_NONE): New macro.
16442         (char_directive): Change type of *arg_index fields to size_t.
16443         * lib/printf-parse.c: Don't include sys/types.h.
16444         (SSIZE_MAX): Remove macro.
16445         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
16446         Remove unnecessary overflow check.
16447         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
16448         fields.
16449
16450 2003-11-25  Bruno Haible  <bruno@clisp.org>
16451
16452         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
16453
16454 2003-11-25  Bruno Haible  <bruno@clisp.org>
16455
16456         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
16457         gt_TYPE_SSIZE_T.
16458
16459 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16460
16461         * modules/alloca: Remove dependency on xalloc.
16462
16463 2003-11-24  Paul Eggert  <eggert@twinsun.com>
16464
16465         * lib/alloca.c: Remove dependency on xalloc module.
16466         (xalloc_die): Remove.
16467         (memory_full) [!defined emacs]: New macro.
16468         [!defined emacs]: Don't include xalloc.h.
16469         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
16470         address arithmetic overflows.  Change datatypes a bit to avoid
16471         unnecessary casts.
16472
16473 2003-11-22  Jim Meyering  <jim@meyering.net>
16474
16475         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
16476         s/size/size_t/.
16477
16478 2003-11-21  Karl Berry  <karl@gnu.org>
16479
16480         * config/config.{sub,guess}: update from config.
16481
16482 2003-11-18  Karl Berry  <karl@gnu.org>
16483
16484         * config/config.{sub,guess}: update from config.
16485
16486         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
16487
16488 2003-11-17  Paul Eggert  <eggert@twinsun.com>
16489
16490         * README: Mention that S+T cannot overflow if S is the size of
16491         an existing object and T is sufficiently small.
16492
16493 2003-11-17  Jim Meyering  <jim@meyering.net>
16494
16495         On systems without utime and without a utimes function capable of
16496         dealing with a NULL struct utimbuf* argument, this utime replacement
16497         could -- in unusual circumstances -- leak a file descriptor.
16498         * lib/utime.c: Include <unistd.h> and <errno.h>.
16499         (utime_null): Be sure to close `fd' and to preserve errno.
16500         Reported by Geoff Collyer via Arnold Robbins.
16501
16502 2003-11-17  Bruno Haible  <bruno@clisp.org>
16503
16504         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
16505         (Depends-on): Add xsize.
16506
16507 2003-11-17  Bruno Haible  <bruno@clisp.org>
16508
16509         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
16510
16511 2003-11-17  Bruno Haible  <bruno@clisp.org>
16512
16513         * lib/vasnprintf.c (alloca): Remove fallback definition.
16514         (freea): Remove definition.
16515         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
16516         Reported by Paul Eggert.
16517
16518 2003-11-16  Paul Eggert  <eggert@twinsun.com>
16519             Bruno Haible  <bruno@clisp.org>
16520
16521         Protect against address arithmetic overflow.
16522         * lib/printf-args.h: Include stddef.h.
16523         (arguments): Change type of field 'count' to size_t.
16524         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
16525         'unsigned int' where appropriate.
16526         * lib/printf-parse.h: Include sys/types.h.
16527         (char_directive): Change type of *arg_index fields to ssize_t.
16528         (char_directives): Change type of fields 'count', max_*_length to
16529         size_t.
16530         * lib/printf-parse.c: Include sys/types.h and xsize.h.
16531         (SSIZE_MAX): Define fallback value.
16532         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
16533         instead of 'int' where appropriate. Check a_allocated, d_allocated
16534         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
16535         * lib/vasnprintf.c: Include xsize.h.
16536         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
16537         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
16538         overflow. Avoid wraparound when converting a width or precision from
16539         decimal to binary.
16540
16541 2003-11-16  Bruno Haible  <bruno@clisp.org>
16542
16543         Update from GNU gettext.
16544         * lib/printf-parse.c: Generalize to it can be compiled for wide
16545         strings.
16546         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
16547         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
16548         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
16549         SNPRINTF): New macros.
16550         Don't include <alloca.h> if the file is used inside libintl.
16551         (local_wcslen): New function, for Solaris 2.5.1.
16552         (VASNPRINTF): Use it instead of wcslen.
16553
16554 2003-11-16  Bruno Haible  <bruno@clisp.org>
16555
16556         * lib/xsize.h (xmax): New function.
16557         (xsum, xsum3, xsum4): Declare as "pure" functions.
16558
16559 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16560
16561         * modules/xalloc (Files): Undo latest change, since xalloc.h
16562         no longer needs SIZE_MAX or PTRDIFF_MAX.
16563
16564 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16565
16566         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
16567         gl_PTRDIFF_MAX.
16568
16569 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16570
16571         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
16572         "return", to pacify some unknown compiler.  Problem reported
16573         by Joerg Schilling.
16574
16575 2003-11-12  Paul Eggert  <eggert@twinsun.com>
16576
16577         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
16578         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
16579         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
16580         heuristic is just as accurate as far as we know, and it removes a
16581         dependency on size_max.m4 and ptrdiff_max.m4.
16582
16583 2003-11-11  Bruno Haible  <bruno@clisp.org>
16584
16585         * modules/xsize (Files): Add m4/size_max.m4.
16586         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
16587
16588 2003-11-11  Bruno Haible  <bruno@clisp.org>
16589
16590         * m4/size_max.m4: New file.
16591         * m4/ptrdiff_max.m4: New file.
16592         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
16593         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
16594         (gl_XALLOC): Invoke it.
16595
16596 2003-11-11  Bruno Haible  <bruno@clisp.org>
16597
16598         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
16599         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
16600         defined.
16601
16602 2003-11-10  Paul Eggert  <eggert@twinsun.com>
16603
16604         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
16605         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
16606         rejected some allocations of exactly SIZE_MAX - 2 bytes.
16607         From Bruno Haible.
16608         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
16609         not (size_t) -1, since it's defined here.
16610
16611 2003-11-09  Karl Berry  <karl@gnu.org>
16612
16613         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
16614
16615 2003-11-06  Paul Eggert  <eggert@twinsun.com>
16616
16617         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
16618         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
16619         Reject sizes of exactly SIZE_MAX bytes.
16620         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
16621         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
16622
16623 2003-11-05  Bruno Haible  <bruno@clisp.org>
16624
16625         * lib/xsize.h: Include limits.h, to avoid a possible collision with
16626         SIZE_MAX defined in <limits.h> on Solaris.
16627
16628 2003-11-04  Jim Meyering  <jim@meyering.net>
16629
16630         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
16631         variable names, rather than @VAR@.
16632         * modules/poll: Likewise.
16633
16634 2003-11-04  Bruno Haible  <bruno@clisp.org>
16635
16636         * modules/xsize: New file.
16637         * modules/linebreak: Depend on xsize.
16638         * MODULES.html.sh (func_all_modules): Add xsize.
16639
16640 2003-11-04  Bruno Haible  <bruno@clisp.org>
16641
16642         * m4/xsize.m4: New file.
16643
16644 2003-11-04  Bruno Haible  <bruno@clisp.org>
16645
16646         * lib/xsize.h: New file.
16647         * lib/linebreak.c: Include xsize.h.
16648         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
16649         argument for overflow.
16650         Suggested by Paul Eggert.
16651
16652 2003-11-03  Karl Berry  <karl@gnu.org>
16653
16654         * config/config.{guess,sub}: update from config.
16655
16656 2003-11-03  Jim Meyering  <jim@meyering.net>
16657
16658         * modules/userspec (lib_SOURCES): Add userspec.h.
16659         (Include): Add "userspec.h".
16660         Improve description.
16661
16662 2003-11-03  Jim Meyering  <jim@meyering.net>
16663
16664         * lib/userspec.c: Include "userspec.h".
16665         * lib/userspec.h: New file.
16666
16667 2003-11-03  Bruno Haible  <bruno@clisp.org>
16668
16669         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
16670
16671 2003-11-03  Bruno Haible  <bruno@clisp.org>
16672
16673         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
16674         available, to avoid (extremely rare) race condition.
16675         Suggested by Paul Eggert.
16676
16677 2003-11-02  Karl Berry  <karl@gnu.org>
16678
16679         * config/srclist.txt (vasprintf.c): sync broken, sigh.
16680
16681 2003-10-31  Paul Eggert  <eggert@twinsun.com>
16682
16683         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
16684         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
16685         (read_filesystem_list): Set and use me_type_malloced.
16686         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
16687         whatever the type happens to be), for brevity and consistency.
16688         Check for size calculation overflow on Alphas running OSF/1.
16689
16690 2003-10-31  Jim Meyering  <jim@meyering.net>
16691
16692         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
16693
16694         * lib/linebuffer.c: Include <string.h> for declaration of memset.
16695
16696 2003-10-30  Paul Eggert  <eggert@twinsun.com>
16697             Bruno Haible  <bruno@clisp.org>
16698
16699         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
16700         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
16701
16702 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16703
16704         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
16705         netbsd*-gnu*.  Suggested by Robert Millan.
16706
16707 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16708
16709         * modules/group-member: Depend on stdbool.
16710
16711 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16712
16713         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
16714
16715 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16716
16717         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
16718         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
16719         after the 'gnu' in these cases.  This fixes some bugs in the
16720         previous change, and is based on suggestions by Robert Millan.
16721
16722 2003-10-29  Paul Eggert  <eggert@twinsun.com>
16723
16724         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
16725         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
16726         no longer needed.
16727         * lib/quotearg.c (quotearg_n_options): Use it.
16728         * lib/group-member.c: Include <stdbool.h>.
16729         (free_group_info): Arg is now const *; don't free arg.
16730         (get_group_info): Now returns bool and accepts struct group_info *,
16731         rather than returning a malloc'ed struct group_info *.
16732         All uses changed.  Check for overflow in internal size calculation.
16733
16734         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
16735         rather than xmalloc/xrealloc.
16736         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
16737         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
16738         conformance bug: the old code used a pointer after freeing the
16739         storage that it addressed.
16740         * lib/hash.c (hash_initialize): Simplify the code by using
16741         xalloc_oversized rather than doing it by hand.
16742         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
16743         the buffer preserved.  Use free and xmalloc instead.
16744         * lib/quotearg.c (quotearg_n_options): Likewise.
16745         Use a simpler test for size overflow.  Don't use xalloc_oversized
16746         because unsigned int might be wider than size_t (!); this suggests
16747         that we should switch from unsigned int to size_t for slot numbers.
16748
16749 2003-10-28  Paul Eggert  <eggert@twinsun.com>
16750
16751         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
16752         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
16753         NetBSD kernels.  Requested by Richard Stallman.
16754
16755 2003-10-27  Paul Eggert  <eggert@twinsun.com>
16756
16757         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
16758         to allocate the returned structure.  Do not allocate a subarray,
16759         as x2nrealloc will do that.
16760         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
16761         instead of xnrealloc.
16762         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
16763
16764 2003-10-27  Bruno Haible  <bruno@clisp.org>
16765
16766         * lib/stdbool_.h: Better support for BeOS.
16767
16768 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16769
16770         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
16771         now uses inline.
16772
16773 2003-10-26  Paul Eggert  <eggert@twinsun.com>
16774
16775         * lib/xalloc.h (xalloc_oversized): New static inline function, for
16776         callers that want to do their own size-overflow checking.  Include
16777         <stdbool.h>, since xalloc_oversized returns bool.
16778         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
16779         to use xalloc_oversized.
16780
16781         Add two functions x2realloc, x2nrealloc, for programs that grow
16782         arrays dynamically by doubling their sizes.
16783         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
16784         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
16785         New functions.
16786
16787         Port to C99 semantics for 'inline' of external functions.
16788         Bug reported by Bruno Haible.
16789         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
16790         with the old contents of xnmalloc.
16791         (xnmalloc, xmalloc): Use it.
16792         (xnrealloc_inline): New static inline function,
16793         with the old contents of xnrealloc.
16794         (xnrealloc, xrealloc): Use it.
16795
16796         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
16797         that.
16798
16799 2003-10-26  Karl Berry  <karl@gnu.org>
16800
16801         * config/srclist.txt (COPYING.DOC): no longer available from
16802         /gd/gnuorg; don't know where the ultimate source is.
16803
16804 2003-10-25  Paul Eggert  <eggert@twinsun.com>
16805
16806         Fix several address-calculation bugs in the hash modules,
16807         plus some minor code cleanup.
16808
16809         * lib/hash.h: Include <stdbool.h>, for bool.
16810         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
16811         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
16812         hash_get_n_entries, hash_get_max_bucket_length,
16813         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
16814         hash_rehash): Use size_t rather than unsigned.
16815         * lib/hash.c (struct hash_table, hash_get_n_buckets,
16816         hash_get_n_buckets_used, hash_get_n_entries,
16817         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
16818         hash_get_entries, hash_do_for_each, hash_string, is_prime,
16819         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
16820         Likewise.
16821         (SIZE_MAX): Define if not defined.
16822         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
16823         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
16824         hash_print):
16825         Use const * when possible.
16826         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
16827         (check_tuning): Fix bug: if tuning parameters were very close to
16828         0 or 1, rounding errors could have caused subscript violations.
16829         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
16830         (hash_initialize): Add 'fail:' label
16831         to free table and return NULL, and use it to simplify code.
16832         Use calloc rather than clearing the storage ourself.
16833         (hash_initialize, hash_rehash): Check for arithmetic overflow in
16834         buffer size calculations.
16835         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
16836         Include <stddef.h>, for size_t.
16837         * lib/hash-pjw.c (hash_pjw): Likewise.
16838         Switch to method described by Bruno Haible.
16839         Include <limits.h>, for CHAR_BIT.
16840         (SIZE_BITS): New macro.
16841
16842 2003-10-23  Paul Eggert  <eggert@twinsun.com>
16843
16844         * m4/getline.m4 (AM_FUNC_GETLINE):
16845         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
16846         hosts.  Problem reported by Derek Robert Price in
16847         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
16848         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
16849         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
16850
16851 2003-10-21  Paul Eggert  <eggert@twinsun.com>
16852
16853         * lib/getndelim2.c (getndelim2): When size calculation overflows,
16854         ceiling the allocation at NMAX bytes rather than silently
16855         discarding input bytes before NMAX is reached.  This makes
16856         a difference only if NMAX exceeds SIZE_MAX / 2.
16857
16858         * lib/obstack.c: Merge from glibc.
16859         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
16860         Add libc_hidden_def (_obstack_newchunk).
16861         (_obstack_free) [! defined _LIBC]: Remove.
16862         [defined _LIBC]: Make a strong alias from obstack_free, rather than
16863         a clone of the function body.
16864         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
16865         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
16866
16867         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
16868         glibc.
16869         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
16870         arg to memcpy.
16871
16872         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
16873         (obstack_ptr_grow_fast, obstack_int_grow_fast):
16874         Don't use lvalue casts, as GCC plans to remove support for them
16875         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
16876         was also present in the non-GCC version, indicating that this
16877         code had always been buggy and had never been widely used.
16878         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
16879         Use the fast variant of each macro, rather than copying the
16880         definiens of the fast variant; that way, we'll be more likely to
16881         catch future bugs in the fast variants.
16882
16883 2003-10-20  Bruno Haible  <bruno@clisp.org>
16884
16885         * modules/wait-process: New file.
16886         * MODULES.html.sh (func_all_modules): Add wait-process.
16887
16888 2003-10-20  Bruno Haible  <bruno@clisp.org>
16889
16890         * m4/wait-process.m4: New file.
16891
16892 2003-10-20  Bruno Haible  <bruno@clisp.org>
16893
16894         * lib/wait-process.h: New file, from GNU gettext.
16895         * lib/wait-process.c: New file, from GNU gettext.
16896
16897 2003-10-19  Jim Meyering  <jim@meyering.net>
16898
16899         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
16900         HPUX 10.20.
16901
16902 2003-10-18  Karl Berry  <karl@gnu.org>
16903
16904         * config/config.guess: update from config.
16905
16906 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16907
16908         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
16909         (getgroups): First arg is int, not size_t.
16910         Don't let 'free' mangle errno.
16911
16912 2003-10-16  Paul Eggert  <eggert@twinsun.com>
16913
16914         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
16915
16916 2003-10-16  Karl Berry  <karl@gnu.org>
16917
16918         * config/config.{guess,sub}: update from config.
16919
16920 2003-10-16  Jim Meyering  <jim@meyering.net>
16921
16922         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
16923         memcpy.
16924
16925 2003-10-15  Paul Eggert  <eggert@twinsun.com>
16926
16927         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
16928         (SIZE_MAX): Remove.
16929         (new_exclude, add_exclude_file): Initial size no longer needs to
16930         be a power of 2.
16931         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
16932         our own address arithmetic overflow checking.
16933
16934         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
16935         (fnmatch): Do not alloca more than 2000 wide characters;
16936         instead, use malloc for large buffers.
16937         Check for address arithmetic overflow, and return -1
16938         with errno set to ENOMEM in that case.
16939         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
16940         (NEW_PATTERN): Do not alloca more than 8000 bytes;
16941         instead, return -1.  Check for address arithmetic overflow.
16942
16943 2003-10-14  Paul Eggert  <eggert@twinsun.com>
16944
16945         Handle invalid suffixes and overflow independently, so that
16946         callers can treat them independently as needed.  Fix some bugs in
16947         suffix handling, e.g., "100k@" was not diagnosed as an invalid
16948         suffix for a human-readable blocksize.  The major caller-visible
16949         change is the addition of a new
16950         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
16951         that both overflow and suffix chars were found.
16952
16953         * lib/human.c (humblock): Don't check separately for invalid suffix
16954         char; that is xstrtoumax's job (now that its bug is fixed).
16955         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
16956         INTMAX_MAX]: New macros.
16957         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
16958         TYPE_MAXIMUM): New macros.
16959         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
16960         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
16961         if overflow occurs, as it's what __strtol does and it's more useful
16962         in practice.
16963         (__xstrtol): If __strtol reports some error other than ERANGE,
16964         reflect it to the caller as LONGINT_INVALID.  If it reports
16965         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
16966         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
16967         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
16968         value.
16969         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
16970         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
16971         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
16972         [defined UINTMAX_MAX]: New macros.
16973
16974 2003-10-14  Bruno Haible  <bruno@clisp.org>
16975
16976         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
16977
16978 2003-10-14  Bruno Haible  <bruno@clisp.org>
16979
16980         * m4/sig_atomic_t: New file, from GNU gettext.
16981         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
16982
16983 2003-10-14  Bruno Haible  <bruno@clisp.org>
16984
16985         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
16986         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
16987         Also use volatile where needed.
16988
16989 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16990
16991         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
16992         Change maintainer from Bruno Haible to 'all'.
16993
16994 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16995
16996         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
16997
16998 2003-10-12  Paul Eggert  <eggert@twinsun.com>
16999
17000         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
17001         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
17002         and define in terms of the other primitives.
17003         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
17004         (SIZE_MAX): Define if not already defined.
17005         (array_size_overflow): New function.
17006         (xalloc_die): Abort instead of exiting if 'error' returns.
17007         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
17008         (xmalloc, xrealloc): Use them.
17009         (xcalloc): Check for address arithmetic overflow.
17010         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
17011         a bit faster than strcpy.
17012
17013 2003-10-10  Simon Josefsson  <jas@extundo.com>
17014
17015         * modules/argp (Depends-on): Add restrict and strcase.
17016
17017 2003-10-10  Simon Josefsson  <jas@extundo.com>
17018
17019         * m4/argp.m4: Add AC_C_INLINE.
17020
17021 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17022
17023         Merge getpass from libc, plus a few fixes.
17024
17025         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
17026         Include <stdbool.h>.
17027         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
17028         __fsetlocking to empty.
17029         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
17030         do include <bits/libc-lock.h>.
17031         Do not include <fcntl.h>; not needed.
17032         [_LIBC]: Include <wchar.h>.
17033         (NOTCANCEL_MODE): New macro.
17034         (flockfile, funlockfile) [_LIBC]: New macros.
17035         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
17036         [!_LIBC]: New macros.
17037         (call_fclose): New function.
17038         (getpass): Use it.  Save tty stream separately; this simplifies the
17039         code and makes it more reliable if stdin happens to equal stdout.
17040         Invoke __fsetlocking on tty.
17041         Handle thread cancellation if needed.
17042         Namespace cleanup (use __tcgetattr, __getline).
17043         Use bool for Booleans.
17044         [USE_IN_LIBIO]: Handle wide streams.
17045         [!_LIBC]: Unconditionally do the fseek, since we don't know what
17046         stream might go where.
17047
17048         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
17049         doesn't have to include <stdio.h> before us.
17050         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
17051         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
17052         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
17053         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
17054         if not declared, so that we can use getpass.c code from libc without
17055         rewriting it.
17056         (flockfile, ftrylockfile, funlockfile): New macros.
17057
17058 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17059
17060         * modules/getpass: Depend on stdbool.
17061
17062 2003-10-08  Paul Eggert  <eggert@twinsun.com>
17063
17064         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
17065
17066 2003-10-07  Karl Berry  <karl@gnu.org>
17067
17068         * config/config.{guess,sub}: update from config.
17069
17070 2003-10-06  Jim Meyering  <jim@meyering.net>
17071             Bruno Haible  <bruno@clisp.org>
17072
17073         This lets translators provide better translations for the
17074         "Written by ..." part of --version output.
17075         * lib/version-etc.h: Include stdarg.h.
17076         (version_etc_copyright): Declare as readonly.
17077         (version_etc): Make this function variadic with a NULL-terminated list
17078         of author name strings.
17079         (version_etc_va): New declaration.
17080         * lib/version-etc.c: Include stdarg.h, stdlib.h.
17081         (version_etc_copyright): Declare as readonly.
17082         (version_etc_va): New function. Provide a different translatable string
17083         for each possible number of authors < 10. Abbreviate when there are 10
17084         authors or more.
17085         (version_etc): Make this function variadic. Call version_etc_va.
17086         Suggestion from Gary V. Vaughan.
17087
17088         * lib/long-options.h (parse_long_options): Change prototype: the
17089         authors string is moved to the end and becomes variadic.
17090         * lib/long-options.c: Include stdarg.h.
17091         (parse_long_options): Make this function variadic, too.
17092         Call version_etc_va, not version_etc.
17093
17094 2003-10-06  Bruno Haible  <bruno@clisp.org>
17095
17096         * modules/version-etc-2: Remove file.
17097         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
17098
17099 2003-10-06  Bruno Haible  <bruno@clisp.org>
17100
17101         * modules/fatal-signal: New file.
17102         * MODULES.html.sh (func_all_modules): Add fatal-signal.
17103
17104 2003-10-06  Bruno Haible  <bruno@clisp.org>
17105
17106         * m4/fatal-signal.m4: New file.
17107         * m4/signalblocking.m4: New file, from GNU gettext.
17108
17109 2003-10-06  Bruno Haible  <bruno@clisp.org>
17110
17111         * lib/version-etc-2.h: Remove file.
17112         * lib/version-etc-2.c: Remove file.
17113
17114 2003-10-06  Bruno Haible  <bruno@clisp.org>
17115
17116         * lib/fatal-signal.h: New file, from GNU gettext.
17117         * lib/fatal-signal.c: New file, from GNU gettext.
17118
17119 2003-10-05  Paul Eggert  <eggert@twinsun.com>
17120
17121         * README: Rework advice for preventing empty .o files.
17122         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
17123         not <sys/types.h>.
17124
17125 2003-10-04  Karl Berry  <karl@gnu.org>
17126
17127         * lib/argp*: update from libc.
17128
17129 2003-10-04  Karl Berry  <karl@gnu.org>
17130
17131         * config/config.{guess,sub}: update from config.
17132
17133 2003-10-02  Bruno Haible  <bruno@clisp.org>
17134
17135         * modules/lchown (Include): Add lchown.h.
17136         * modules/time_r (Include): Use "..." syntax.
17137         * modules/xgetdomainname (Include): Add xgetdomainname.h.
17138
17139 2003-10-01  Simon Josefsson  <jas@extundo.com>
17140
17141         * MODULES.html.sh (func_all_modules): Move gethostname from section
17142         'based on' to section 'lacking' POSIX:2001.
17143
17144 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
17145
17146         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
17147         to output mode on the same stream.
17148
17149 2003-09-29  Paul Eggert  <eggert@twinsun.com>
17150
17151         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
17152         Fix arg typo in previous patch.
17153
17154 2003-09-28  Jim Meyering  <jim@meyering.net>
17155
17156         * lib/error.c: Correct cpp indentation.
17157
17158 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17159
17160         * modules/free: New file.
17161
17162 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17163
17164         * m4/free.m4: New file.
17165
17166 2003-09-27  Paul Eggert  <eggert@twinsun.com>
17167
17168         * lib/minmax.h (MIN, MAX)
17169         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
17170         Omit the special code that used __typeof__, since we worry that
17171         it could be more trouble than it's worth.  See:
17172         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
17173         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
17174
17175         * lib/free.c: New file.
17176
17177 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
17178
17179         Trivial fixes to Makefile.am parts of module listings.
17180         * modules/strstr: Append strstr.h to lib_SOURCES.
17181         * modules/strcase: Likewise, for strcase.h.
17182
17183 2003-09-27  Karl Berry  <karl@gnu.org>
17184
17185         * config/mkinstalldirs: update from automake.
17186
17187 2003-09-26  Paul Eggert  <eggert@twinsun.com>
17188
17189         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
17190         (error_tail): Do not loop, reallocating temporary buffer, since
17191         the output cannot contain more wide characters than the input
17192         contains bytes, the size must be big enough already.  This avoids
17193         one potential size overflow calculation.  Check for size overflow
17194         when calculating temporary buffer size.  Free temporary buffer
17195         when done, if it was allocated with malloc; this plugs a memory
17196         leak.  Remove casts from void * to pointers, that are no longer
17197         needed now that we're assuming C89 or better.
17198
17199         Merge error changes from glibc.
17200
17201         * lib/error.c, error.h: Update copyright notice header to match glibc.
17202         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
17203         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
17204         Disable cancellation while printing error.
17205         * lib/error.h: Prepend __ to parameter names.
17206
17207 2003-09-26  Jim Meyering  <jim@meyering.net>
17208
17209         * lib/error.c (error_tail): Move some declarations
17210         into inner scope where the local variables are used.
17211
17212 2003-09-26  Bruno Haible  <bruno@clisp.org>
17213
17214         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
17215         stpncpy().
17216         Don't define stpncpy through config.h; it's now done through stpncpy.h.
17217
17218 2003-09-26  Bruno Haible  <bruno@clisp.org>
17219
17220         * lib/stpncpy.h (gnu_stpncpy): New declaration.
17221         (stpncpy): Define as alias for gnu_stpncpy.
17222         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
17223
17224 2003-09-25  Simon Josefsson  <jas@extundo.com>
17225
17226         * lib/xgetdomainname.h: New file.
17227         * lib/xgetdomainname.c: New file.
17228
17229 2003-09-25  Simon Josefsson  <jas@extundo.com>
17230             Bruno Haible  <bruno@clisp.org>
17231
17232         * modules/getdomainname: New file.
17233         * modules/xgetdomainname: New file.
17234         * MODULES.html.sh (func_all_modules): Add getdomainname,
17235         xgetdomainname.
17236
17237 2003-09-25  Simon Josefsson  <jas@extundo.com>
17238             Bruno Haible  <bruno@clisp.org>
17239
17240         * m4/getdomainname.m4: New file.
17241
17242 2003-09-25  Simon Josefsson  <jas@extundo.com>
17243             Bruno Haible  <bruno@clisp.org>
17244
17245         * lib/getdomainname.h: New file.
17246         * lib/getdomainname.c: New file.
17247
17248 2003-09-25  Karl Berry  <karl@gnu.org>
17249
17250         * lib/argp-fmtstream.c, argp-help.c: update from libc.
17251
17252 2003-09-25  Karl Berry  <karl@gnu.org>
17253
17254         * config/install-sh: update from automake.
17255
17256 2003-09-25  Bruno Haible  <bruno@clisp.org>
17257
17258         * modules/version-etc-2: New file, from modules/version-etc with
17259         modifications.
17260         * MODULES.html.sh (func_all_modules): Add version-etc-2.
17261
17262 2003-09-25  Bruno Haible  <bruno@clisp.org>
17263
17264         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
17265         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
17266
17267 2003-09-24  Simon Josefsson  <jas@extundo.com>
17268
17269         * modules/xgethostname: Add xgethostname.h.
17270
17271 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17272
17273         * lib/linebuffer.c (freebuffer): Don't free the argument, just
17274         the buffer associated with the argument.  Bug reported by
17275         Simon Josefsson.
17276
17277 2003-09-24  Paul Eggert  <eggert@twinsun.com>
17278
17279         * README: Document assumptions that 'int' is at least 32 bits
17280         wide, that integer arithmetic is 2's complement without overflow,
17281         that there are no holes in integer values, that adding sizes of
17282         two nonoverlapping objects can't overflow, and that all-bits-zero
17283         yields scalar zero.  Fix spelling and capitalization typos.
17284
17285 2003-09-19  Karl Berry  <karl@gnu.org>
17286
17287         * lib/argp.h: update from libc.
17288
17289 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17290
17291         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
17292         to avoid spurious warnings like "AC_RUN_IFELSE was called before
17293         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
17294
17295 2003-09-17  Paul Eggert  <eggert@twinsun.com>
17296
17297         * gnulib-tool: Use "test -h", not "test -L", for portability
17298         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
17299         (tags_regexp): Remove, since \| doesn't conform to POSIX.
17300         (sed_extract_prog): Issue s commands one-by-one, rather than
17301         using \| in one s command.
17302
17303 2003-09-16  Paul Eggert  <eggert@twinsun.com>
17304
17305         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
17306         input error, instead of returning NULL the next time we are called
17307         (and therefore losing track of errno).
17308
17309 2003-09-16  Bruno Haible  <bruno@clisp.org>
17310
17311         * gnulib-tool (func_create_testdir): Warn about duplicated
17312         dependencies.
17313
17314 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17315
17316         * modules/argmatch, modules/fatal, modules/obstack,
17317         modules/xalloc, modules/xgethostname: Sort dependencies by
17318         importance, not alphabetically.
17319
17320 2003-09-15  Paul Eggert  <eggert@twinsun.com>
17321
17322         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
17323         fails, so that the caller gets the proper errno.
17324
17325         * lib/readutmp.c (read_utmp): Likewise.
17326         Check for fstat error.  Close stream and free storage
17327         when failing.
17328
17329 2003-09-14  Karl Berry  <karl@gnu.org>
17330
17331         * config/srclist.txt (strdup.c): disable for c89 changes.
17332
17333 2003-09-14  Jim Meyering  <jim@meyering.net>
17334
17335         * lib/getloadavg.c: Correct cpp indentation.
17336         * lib/strdup.c: Likewise.
17337         * lib/vasnprintf.c: Likewise.
17338
17339 2003-09-14  Bruno Haible  <bruno@clisp.org>
17340
17341         * modules/fwriteerror: New file.
17342         * MODULES.html.sh (func_all_modules): Add fwriteerror.
17343
17344 2003-09-14  Bruno Haible  <bruno@clisp.org>
17345
17346         * lib/fwriteerror.h: New file.
17347         * lib/fwriteerror.c: New file.
17348
17349 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17350
17351         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
17352         modules/xgethostname, modules/xalloc: Depend on exit.
17353
17354 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17355
17356         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
17357
17358         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
17359         and AC_MINIX, too, so that their extensions are available.
17360
17361         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
17362         This macro has been superseded by gl_BACKUPFILE.
17363
17364         More patches to assume C89 or better.
17365
17366         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
17367
17368         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
17369         unconditionally.
17370         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
17371         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
17372         Include <string.h>, <stdlib.h> unconditionally.
17373         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
17374         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
17375         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
17376         headers or for string.h.
17377         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
17378         or strtoul.
17379
17380         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
17381         headers.
17382         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
17383         * m4/userspec.m4 (gl_USERSPEC): Likewise.
17384         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
17385         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
17386         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
17387         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
17388         memcpy, memset.
17389         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
17390         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
17391         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
17392         strtol.
17393         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
17394         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
17395         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
17396         strtoul.
17397
17398 2003-09-12  Paul Eggert  <eggert@twinsun.com>
17399
17400         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
17401         * lib/obstack.c [!defined _LIBC]: Likewise.
17402         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
17403         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
17404         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
17405
17406         More changes to assume C89 or better.
17407
17408         * lib/error.c (error_tail): Assume vprintf.
17409
17410         * lib/argmatch.c (getenv): Remove decl.
17411         * lib/progreloc.c (get_full_program_name): Define via prototype.
17412         * lib/setenv.c (clearenv): Likewise.
17413         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
17414         needed.
17415         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
17416         (malloc, memcpy): Remove decls.
17417         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
17418         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
17419         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17420         (memcpy): Remove macro.
17421         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
17422         (__P): Remove.  All uses removed.
17423         (PTR): Remove.  All uses changed to void *.
17424         (CHAR_BIT, NULL): Remove.
17425         (spaces, zeros, memset_space, memset_zero)
17426         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
17427         Remove.
17428         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
17429         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
17430         Define with prototype.
17431         Remove now-unnecessary prototype decl.
17432         (extra_args_spec): Assume ANSI C.  All uses changed.
17433         (extra_args_spec_iso): Remove.
17434         (my_strftime, emacs_strftimeu): Define via prototype.
17435         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
17436         unconditionally.
17437         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
17438         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
17439         (strtoul, strtol): Remove decls.
17440         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
17441         LONG_MAX): Remove.
17442         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
17443         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
17444         (LOCALE_PARAM_PROTO): New macro.
17445         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
17446         (INTERNAL (strtol), strtol): Define with a prototype.
17447         (PARAMS): Remove.  All uses removed.
17448         * lib/tempname.c: Include <string.h> unconditionally.
17449         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
17450         * lib/xgethostname.c (main): Define with a prototype.
17451         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
17452         Include <stdlib.h> unconditionally.
17453         (calloc, malloc, realloc, free): Remove decls.
17454         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
17455         Include <stdlib.h> unconditionally.  Sort include file names.
17456         (strtod): Remove.
17457         (xstrtod): Define with a prototype.
17458         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
17459         (strtol, strtoul): Remove decls.
17460
17461 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17462
17463         More patches to assume C89 or better.
17464         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
17465         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
17466         string.h, memchr, STDC_HEADERS.
17467
17468 2003-09-11  Paul Eggert  <eggert@twinsun.com>
17469
17470         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
17471         Include <stdlib.h>, <string.h> unconditionally.
17472         Remove now-unnecessary cast to char *.
17473         * lib/strnlen.c: Include <string.h> unconditionally.
17474         * lib/yesno.c (yesno): Define with a prototype.
17475
17476 2003-09-11  Bruno Haible  <bruno@clisp.org>
17477
17478         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
17479
17480 2003-09-10  Jim Meyering  <jim@meyering.net>
17481
17482         * lib/error.c: Correct indentation of cpp directives.
17483
17484 2003-09-10  Bruno Haible  <bruno@clisp.org>
17485
17486         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
17487         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
17488         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
17489         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
17490         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
17491         <stdlib.h> and <string.h> checks.
17492         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
17493         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
17494
17495 2003-09-10  Bruno Haible  <bruno@clisp.org>
17496
17497         * lib/strcspn.c: Include <string.h> unconditionally.
17498         * lib/strpbrk.c: Include <string.h> unconditionally.
17499         * lib/strstr.c: Include <string.h> unconditionally.
17500         * lib/unicodeio.c: Include <string.h> unconditionally.
17501         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
17502         * lib/unsetenv.c: Likewise.
17503         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
17504         * lib/yesno.c: Include <stdlib.h> unconditionally.
17505         (rpmatch): Add prototype.
17506
17507 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17508
17509         More patches to assume C89 or better.
17510         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
17511         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
17512         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
17513         or for string.h.
17514         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
17515         stdlib.h.
17516         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
17517         C headers.
17518         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
17519         string.h.
17520         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
17521         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
17522         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
17523         or for string.h.
17524         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
17525         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
17526         C headers.
17527         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
17528         memcpy.
17529         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
17530         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
17531         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
17532         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
17533         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
17534         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
17535         string.h, free.
17536         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
17537         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
17538         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
17539         C headers, or for string.h.
17540         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
17541         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
17542         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
17543         headers, memory.h, stdlib.h, string.h, strings.h.
17544         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
17545         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
17546         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
17547         strchr.
17548         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
17549         headers, memory.h, string.h.
17550         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
17551         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
17552         free.
17553         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
17554         headers.
17555         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
17556         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
17557         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
17558         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
17559         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
17560
17561 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17562
17563         More K&R removal.
17564
17565         * lib/acosl.c (main): Use a prototype.
17566         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
17567         tanl.c: Likewise.
17568
17569         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
17570
17571         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
17572         (getopt, etopt_long, getopt_long_only, _getopt_internal)
17573         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
17574         with a prototype.
17575         * lib/getopt.c (const): Remove macro.
17576         Include <string.h> unconditionally.
17577         (my_index): Remove; all uses changed to strchr.
17578         (strlen): Remove decl.
17579         (exchange): Remove forward decl; no longer needed.
17580         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
17581         Define with prototype.
17582         * lib/getopt1.c (const): Remove macro.
17583         (getopt_long, getopt_long_only, main): Define with prototype.
17584
17585         * lib/getugroups.c: Include <string.h> unconditionally.
17586
17587         * lib/getusershell.c: Include <stdlib.h> unconditionally.
17588         (getusershell, setusershell, endusershell, readname, main):
17589         Define with prototypes.
17590
17591         * lib/group-member.c: Include group-member.h first.
17592         Include <stdlib.h> unconditionally.
17593
17594         * lib/hard-locale.c: Include hard-locale.h first.
17595         Include <stdlib.h>, <string.h> unconditionally.
17596
17597         * lib/hash.c (free, malloc): Remove decls.
17598         Include <stdlib.h> unconditionally.
17599
17600         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
17601         (getenv): Do not declare.
17602
17603         * lib/idcache.c: Include <string.h> unconditionally.
17604
17605         * lib/long-options.c: Include long-options.h first, to test interface.
17606         Include <stdlib.h> unconditionally.
17607
17608         * lib/makepath.c: Include makepath.h first, to test interface.
17609         Include <stdlib.h> and <string.h> unconditionally.
17610
17611         * lib/linebuffer.c: Include <stdlib.h>.
17612         (free): Remove decl.
17613
17614         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
17615         stddef.h. rpl_malloc returns void *, not char *.
17616         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
17617         prototype.
17618
17619         * lib/md5.h: Include <limits.h> unconditionally.
17620         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
17621         (__P): Remove; all uses removed.
17622         * lib/md5.c: Include "md5.h" first.
17623         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
17624         md5_buffer, md5_process_bytes, md5_process_block):
17625         Define with prototypes.
17626         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
17627         * lib/sha.c: Include "sha.h" first.
17628         Include <stdlib.h>, <string.h> unconditionally.
17629
17630         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
17631         * lib/memcmp.c (__ptr_t): Likewise.
17632         * lib/memrchr.c (__ptr_t): Likewise.
17633         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
17634         Include <string.h> unconditionally.
17635         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
17636         * lib/memchr.c: Include <stdlib.h> unconditionally.
17637         * lib/memchr.c (LONG_MAX): Remove.
17638         * lib/memrchr.c (LONG_MAX): Likewise.
17639         * lib/memchr.c (__memchr): Define via a prototype.
17640         * lib/memrchr.c (__memrchr): Likewise.
17641         * lib/memcmp.c (__P): Remove, and remove all uses.
17642         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
17643         Remove forward decls; no longer needed.
17644         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
17645         Use types required by C89 in prototype.
17646
17647         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
17648         * lib/savedir.c: Likewise.
17649         * lib/mkdir.c (free): Remove decl.
17650         * lib/rmdir.c (rmdir): Define with a prototype.
17651         * lib/savedir.c: Include savedir.h first, to test interface.
17652
17653         * lib/mktime.c (STDC_HEADERS): Remove.
17654         Include <stdlib.h>, <string.h> unconditionally.
17655
17656         * lib/modechange.c: Include <stdlib.h> unconditionally.
17657         (malloc): Remove decl.
17658
17659         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
17660         (free): Remove decl.
17661
17662         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
17663         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
17664         (This type really should be intptr_t, but that's a C99ism.)
17665         (_obstack_memcpy): Remove: all uses changed to memcpy.
17666         Include <string.h> unconditionally.
17667         (struct obstack): Assume __STDC__ for types of members
17668         chunkfun, freefun, extra_arg.
17669         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
17670         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
17671         obstack_begin, obstack_specify_allocation,
17672         obstack_specify_allocation_with_arg, obstack_chunkfun,
17673         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
17674         Remove unprototyped decls and the macros that use them.
17675         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
17676         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
17677         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
17678         (defined __STDC__ && __STDC__)]:
17679         Remove nonprototyped code.
17680         Include <stdlib.h> unconditionally.
17681         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
17682         _obstack_allocated_p, _obstack_free, obstack_free,
17683         _obstack_memory_used, print_and_abort):
17684         Define using prototypes.
17685         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
17686         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
17687         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
17688         obstack_next_free, obstack_object_size, obstack_room) [0]:
17689         Remove unused, unprototyped code.
17690
17691         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
17692
17693         * lib/physmem.c (physmem_total, physmem_available, main): Define
17694         with prototypes.
17695
17696         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
17697         (main): Define with a prototype.
17698
17699         * lib/posixver.c (getenv): Remove decl.
17700
17701         * lib/putenv.c (malloc): Returns void *, not char *.
17702         Include <string.h> unconditionally.
17703         (strchr, memcpy, NULL): Do not define.
17704
17705         * lib/readtokens.c: Include readtokens.h first, to test interface.
17706         Include <stdlib.h>, <string.h> unconditionally.
17707         (init_tokenbuffer): Define with a prototype.
17708
17709         * lib/regex.c (PARAMS): Remove.  All uses removed.
17710         All uses of _RE_ARGS removed, too.
17711         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17712         unconditionally.
17713         (bzero): Assume memset exists.
17714         (memcmp, memcpy, NULL): Remove.
17715         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
17716         char, or assignments to local vars of type signed char.
17717         (init_syntax_once, PREFIX(extract_number_and_incr),
17718         PREFIX(print_partial_compiled_pattern),
17719         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
17720         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
17721         PREFIX(regex_grow_registers), PREFIX(regex_compile),
17722         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
17723         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
17724         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
17725         wcs_compile_range, byte_compile_range, truncate_wchar,
17726         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
17727         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
17728         count_mbs_length, wcs_re_match_2_internal,
17729         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
17730         PREFIX(alt_match_null_string_p),
17731         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
17732         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
17733         regfree, PREFIX(extract_number)): Define with prototype.  Remove
17734         now-unnecessary declaration, if any.
17735         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
17736         regcomp, regexec):
17737         Remove now-unnecessary casts among pointer types.
17738         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
17739
17740         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
17741         (free): Remove decl.
17742
17743         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
17744
17745         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
17746         (free): Remove decl.
17747
17748         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
17749         * lib/xgetcwd.c: Likewise.
17750
17751         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
17752         (free): Remove decl.
17753
17754         * lib/strchrnul.c (strchrnul): Define with a prototype.
17755         Fix bug: c_in was not converted to char before searching.
17756
17757         The following changes are not K&R related:
17758
17759         * lib/group-member.h: Include <sys/types.h>, so that this file is
17760         self-contained.
17761         * lib/makepath.h: Likewise.
17762
17763         * lib/getusershell.c (readname, default_index, line_size, readname):
17764         Use size_t, not int, for sizes.
17765         (readname): If the size overflows, report an error instead of
17766         looping forever.
17767
17768 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17769
17770         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
17771         libc.
17772
17773 2003-09-09  Paul Eggert  <eggert@twinsun.com>
17774
17775         * README: New section: portability guidelines.
17776
17777 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17778
17779         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
17780         C89 spec.
17781
17782 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
17783
17784         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
17785
17786 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17787
17788         Assume C89 or better; remove K&R cruft.
17789         A few of these changes were first proposed by Derek Robert Price
17790         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
17791
17792         * lib/addext.c: Include <string.h> unconditionally.
17793         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
17794         Don't declare getenv or malloc.
17795
17796         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
17797         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
17798         (NULL): Remove.
17799         (find_stack_direction, alloca): Use prototypes.
17800
17801         * lib/atexit.c (atexit): Define using a prototype.
17802
17803         * lib/basename.c, dirname.c, stripslash.c:
17804         Include <string.h> unconditionally.
17805
17806         * lib/bcopy.c: Include <stddef.h>.
17807         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
17808
17809         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
17810
17811         * lib/error.h (error, error_at_line, error_print_progname)
17812         [! (defined (__STDC__) && __STDC__)]: Remove decls.
17813         * lib/error.c: Include error.h first, to check interface.
17814         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17815         (VA_START): Remove; all uses changeed to va_start.
17816         (exit, strerror): Remove decls.
17817         (error_print_progname): Prototype uncondionally.
17818         Don't include <errno.h>; no longer needed.
17819         (private_strerror): Remove.
17820         (error_tail): Always define.
17821         (error, error_at_line): Assume C89 or better; always use prototypes.
17822         * lib/fatal.c: Include "fatal.h" first, to test interface.
17823         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
17824         (VA_START): Remove; all uses changed to va_start.
17825         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
17826         this case.
17827         (exit): Remove decl.
17828         (fatal): Prototype unconditionally.  Assume va_start works.
17829         Abort at end, to pacify gcc.
17830
17831         * lib/euidaccess.c (main): Define with a prototype.
17832
17833         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
17834
17835         * lib/exitfail.c: Include <stdlib.h> unconditionally.
17836
17837         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
17838         prototypes.
17839         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
17840         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
17841         (getenv): Remove decl.
17842         (fnmatch): Define using a prototype.
17843         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
17844         (FCT): Define using a prototype.
17845
17846         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
17847
17848         * lib/gethostname.c: Include <stddef.h>.
17849         (gethostname): Define with prototype.  Length is size_t, not int.
17850
17851 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17852
17853         Assume C89 or better; remove K&R cruft.
17854         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
17855         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
17856         string.h, getenv, malloc.
17857         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
17858         headers.
17859         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
17860         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
17861         do not check for strerror.
17862         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
17863         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
17864         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
17865         do not check for doprnt or vprintf.
17866         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
17867         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
17868
17869 2003-09-08  Paul Eggert  <eggert@twinsun.com>
17870
17871         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
17872         getversion.c should have been removed then, but was accidentally
17873         preserved.
17874
17875         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
17876         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
17877
17878 2003-09-08  Karl Berry  <karl@gnu.org>
17879
17880         * config/config.sub, config.guess, srclistvars.sh: update from savannah
17881                 config, forget about prep.
17882
17883         * config/depcomp, missing: update from automake.
17884
17885 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17886
17887         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
17888         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17889
17890 2003-09-07  Paul Eggert  <eggert@twinsun.com>
17891
17892         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
17893         copy_tm_result.  Bug reported by Simon Josefsson in
17894         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
17895
17896 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17897
17898         * m4/time_r.m4: New file.
17899         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
17900         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
17901         is. Check for timegm declaration.
17902         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
17903         Do not check for gmtime_r.
17904         Replace mktime if __mktime_internal does not exist and if mktime
17905         hasn't been replaced already.
17906
17907 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17908
17909         * lib/time_r.c, lib/time_r.h: New files.
17910
17911         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
17912         __localtime_r.
17913         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
17914         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
17915
17916         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
17917         __gmtime_r.
17918         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
17919         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
17920         Include <time_r.h>.
17921
17922         * lib/timegm.c: Switch to glibc implementation, with the following
17923         changes:
17924         [defined HAVE_CONFIG_H]: Include <config.h>.
17925         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
17926         (__mktime_internal) [!defined _LIBC]: New decl.
17927         (__gmtime_r) [!defined _LIBC]: New macro and function.
17928         (timegm): Use a prototype, since gnulib assumes C89.
17929         Do not bother declaring tmp to be const, as it's not really usefu.
17930         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
17931         (timegm): Declare only if HAVE_DECL_TIMEGM.
17932
17933 2003-09-06  Paul Eggert  <eggert@twinsun.com>
17934
17935         * MODULES.html.sh (func_all_modules): Add time_r.
17936         * modules/time_r: New file.
17937         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
17938         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
17939
17940 2003-09-03  Paul Eggert  <eggert@twinsun.com>
17941
17942         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
17943         Bug reported by Lute Kamstra in
17944         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
17945
17946         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
17947         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
17948         course with correspondingly smaller numbers for tomorrow and
17949         yesterday.  From Tadayoshi Funaba.  Originally installed into
17950         sh-utils on 1999-08-07, but the patch got lost (I guess during the
17951         coreutils merge?).
17952
17953 2003-08-31  Simon Josefsson  <jas@extundo.com>
17954
17955         * modules/timegm: New file.
17956         * MODULES.html.sh (func_all_modules): Add timegm.
17957
17958 2003-08-31  Simon Josefsson  <jas@extundo.com>
17959
17960         * m4/timegm.m4: New file.
17961
17962 2003-08-31  Simon Josefsson  <jas@extundo.com>
17963
17964         * lib/timegm.h: New file.
17965         * lib/timegm.c: New file.  Based on
17966         wget-1.8.2/src/http.c:mktime_from_utc.
17967
17968 2003-08-31  Karl Berry  <karl@gnu.org>
17969
17970         * lib/argp.h: update from libc.
17971
17972 2003-08-28  Bruno Haible  <bruno@clisp.org>
17973
17974         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
17975         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
17976         followed by '#define fnmatch fnmatch_posix' gives an error.
17977
17978 2003-08-28  Bruno Haible  <bruno@clisp.org>
17979
17980         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
17981         warning on QNX, which defines O_BINARY to 000000.
17982
17983 2003-08-27  Jim Meyering  <jim@meyering.net>
17984
17985         * m4/mkstemp.m4: Require that the system mkstemp be able to create
17986         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
17987         would fail after 32.  Reported by Danny Levinson.  Details here:
17988         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
17989
17990 2003-08-24  Bruno Haible  <bruno@clisp.org>
17991
17992         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
17993         MSVC7 <stdio.h> is included later.
17994
17995 2003-08-22  Simon Josefsson  <jas@extundo.com>
17996
17997         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
17998
17999 2003-08-20  Karl Berry  <karl@gnu.org>
18000
18001         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
18002
18003 2003-08-20  Bruno Haible  <bruno@clisp.org>
18004
18005         * modules/progname: New file.
18006         * MODULES.html.sh (func_all_modules): Add progname.
18007
18008 2003-08-20  Bruno Haible  <bruno@clisp.org>
18009
18010         * lib/progname.h: New file, from GNU gettext.
18011         * lib/progname.c: New file, from GNU gettext.
18012         * lib/progreloc.c: New file, from GNU gettext.
18013
18014 2003-08-19  Jim Meyering  <jim@meyering.net>
18015
18016         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
18017         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
18018
18019 2003-08-19  Bruno Haible  <bruno@clisp.org>
18020
18021         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
18022         more.
18023
18024 2003-08-19  Bruno Haible  <bruno@clisp.org>
18025
18026         * lib/xstrdup.c: Assume <string.h> exists.
18027
18028 2003-08-18  Paul Eggert  <eggert@twinsun.com>
18029
18030         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
18031         in makefile rules.
18032
18033 2003-08-18  Jim Meyering  <jim@meyering.net>
18034
18035         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
18036         * m4/lib-ld.m4: Likewise.
18037
18038 2003-08-18  Jim Meyering  <jim@meyering.net>
18039
18040         * lib/setenv.h: Indent nested cpp directive.
18041         * lib/vasnprintf.c: Remove trailing blanks.
18042
18043 2003-08-17  Simon Josefsson  <jas@extundo.com>
18044
18045         * modules/xstrndup: New file.
18046         * MODULES.html.sh (func_all_modules): Add xstrndup.
18047
18048 2003-08-17  Simon Josefsson  <jas@extundo.com>
18049
18050         * modules/argp: Fix autoconf macro name. Add more dependencies.
18051
18052 2003-08-17  Simon Josefsson  <jas@extundo.com>
18053
18054         * m4/xstrndup.m4: New file.
18055
18056 2003-08-17  Simon Josefsson  <jas@extundo.com>
18057
18058         * m4/argp.m4: New file.
18059
18060 2003-08-17  Simon Josefsson  <jas@extundo.com>
18061             Bruno Haible  <bruno@clisp.org>
18062
18063         * lib/xstrndup.h: New file.
18064         * lib/xstrndup.c: New file.
18065
18066 2003-08-17  Bruno Haible  <bruno@clisp.org>
18067
18068         * modules/strndup (Files, Include): Add lib/strndup.h.
18069
18070 2003-08-17  Bruno Haible  <bruno@clisp.org>
18071
18072         * modules/euidaccess (Files): Add lib/euidaccess.h.
18073
18074 2003-08-17  Bruno Haible  <bruno@clisp.org>
18075
18076         * lib/strndup.h: New file.
18077
18078 2003-08-17  Bruno Haible  <bruno@clisp.org>
18079
18080         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
18081         like AC_GNU_SOURCE.
18082         * modules/extensions (configure.ac): Comment out the invocation of
18083         gl_USE_SYSTEM_EXTENSIONS.
18084
18085 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18086
18087         Merges from coreutils, etc.
18088         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
18089         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
18090         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
18091         fixing a typo.
18092         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
18093         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
18094
18095 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18096
18097         Document merge from coreutils.
18098         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
18099         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
18100         * modules/utime: Add m4/utimes-null.m4.
18101
18102 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18103
18104         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
18105         space, undoing this 2003-08-12 change:
18106         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
18107
18108 2003-08-16  Paul Eggert  <eggert@twinsun.com>
18109
18110         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
18111         strtoul.c from libc, undoing this 2003-08-12 change:
18112         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
18113
18114 2003-08-16  Jim Meyering  <jim@meyering.net>
18115
18116         Merges from coreutils.
18117         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
18118         prefix.  Adjust cache variables similarly.  Create 500 rather than
18119         just 300 files, to exercise bug on Darwin6.5, too.
18120         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
18121         $missing_dir.
18122         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
18123         AM_SYS_POSIX_TERMIOS.
18124         Reported by mkc@mathdogs.com.
18125         Also change use of $am_cv_sys_posix_termios
18126         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
18127         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
18128         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
18129         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
18130         in /proc/mounts until it finds one with matching device number.  This
18131         is unnecessary when the FILE argument *is* a mount point.  No stat call
18132         is necessary in that case.  So, disable the statvfs-testing code on
18133         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
18134         as RedHat bug# 84846.
18135         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
18136         to 1MB, so as not to render systems with no stack size limit (e.g.,
18137         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
18138         Include <unistd.h>.  On some systems,
18139         it is required for the definition of _SC_PAGESIZE.
18140
18141 2003-08-16  Jim Meyering  <jim@meyering.net>
18142
18143         Merge from coreutils.
18144         * lib/xstrtoimax.c: #else #if -> #elif.
18145         * lib/xstrtoumax.c: Likewise.
18146
18147 2003-08-16  Jim Meyering  <jim@meyering.net>
18148
18149         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
18150         * m4/utimes.m4: Removed.
18151         * m4/utimes-null.m4: Renamed from utimes.m4.
18152
18153         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
18154         to 1MB, so as not to render systems with no stack size limit (e.g.,
18155         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
18156         Include <unistd.h>.  On some systems,
18157         it is required for the definition of _SC_PAGESIZE.
18158
18159 2003-08-16  Jim Meyering  <jim@meyering.net>
18160         and Paul Eggert  <eggert@cs.ucla.edu>
18161
18162         Merges from coreutils, etc.
18163
18164         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
18165         using the latest version from cvs.  This avoids problems with #line
18166         directives using a vendor (Sun) compiler.
18167         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
18168         Don't set GETGROUPS_LIB here; now it's
18169         done via getgroups.m4's wrapper function.
18170         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
18171         rather than just in sh-util/configure.in, so that the
18172         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
18173         same.
18174         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
18175         AC_FUNC_GETLOADAVG where to find getloadavg.c.
18176         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
18177         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
18178         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
18179         Remove code that is now done by the newly-required macros.
18180         Append $(EXEEXT) to DF_PROG.
18181         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
18182         Do not invoke or require the following here,
18183         since prereq.m4 or some gnulib .m4 now does this for us:
18184         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
18185         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
18186         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
18187         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
18188         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
18189         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
18190         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
18191         AC_FUNC_OBSTACK.
18192         Do not replace the following functions, as this is now the job
18193         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
18194         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
18195         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
18196         atexit getpass, strdup, getpagesize.
18197         Replace 'raise'.
18198         Do not check for the following functions, as this is now the job
18199         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
18200         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
18201         setregid.
18202         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
18203         Check for sys/sysctl.h.
18204         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
18205         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
18206         of checking for ssize_t ourselves.
18207
18208         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
18209         Require every macro that gnulib/modules/* suggests for us.
18210         (jm_PREREQ_ADDEXT): New macro.
18211         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
18212         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
18213
18214         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
18215         (gl_PHYSMEM): Use it.
18216         Also check for `table' function.
18217         Check for new headers and functions.
18218         Add check for sys/sysmp.h.
18219         With suggestions from Kaveh Ghazi.
18220         Ignore headers that are present but cannot be compiled.  This
18221         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
18222         C 5.4.
18223
18224 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18225
18226         Document merge from coreutils.
18227         * modules/userspec: Depend on posixver.
18228         * modules/strftime: Depend on tzset.
18229
18230 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18231
18232         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
18233         rather than tab, after '#' in shell-script copyright notices.
18234         Suggested by Bruno Haible.
18235
18236 2003-08-15  Paul Eggert  <eggert@twinsun.com>
18237
18238         * config/srclist-update: Use three spaces, rather than tab, after '#'
18239         in shell-script copyright notices.  Suggested by Bruno Haible.
18240         Remove unnecessary parenthesization in regular expression.
18241
18242 2003-08-15  Jim Meyering  <jim@meyering.net>
18243
18244         Merge from coreutils.
18245         * lib/xgethostname.c: Include <stdlib.h>.
18246         (xghostname): Don't exit for anything other than memory-related
18247         failure; just return NULL.
18248         * lib/userspec.c: Include "posixver.h".
18249         (parse_user_spec): Accept `.' as a separator only
18250         in pre-POSIX-200112 mode.
18251         * lib/strtoimax.c: Use #elif rather than #else #if.
18252         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
18253         Remove function, now that we can rely on a working tzset function.
18254         [!_LIBC]: Ensure that the required autoconf test has been run.
18255         [!defined _NL_CURRENT && HAVE_STRFTIME]:
18256         Use underlying_strftime for %r.
18257         * lib/sha.c: Merge in some clean-up and optimization changes from
18258         glibc.
18259         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
18260         Ensure that it is a multiple of 64.
18261         Rearrange loop exit tests so as to avoid performing an
18262         additional fread after encountering an error or EOF.
18263         * lib/realloc.c: Update copyright date.
18264
18265 2003-08-15  Jim Meyering  <jim@meyering.net>
18266         and Paul Eggert  <eggert@twinsun.com>
18267
18268         Merge from coreutils.
18269         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
18270         member but strut utmpx does not.  Needed for AIX 4.3.3.
18271         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
18272
18273 2003-08-15  Jim Meyering  <jim@meyering.net>
18274         and Paul Eggert  <eggert@cs.ucla.edu>
18275
18276         Merges from coreutils, etc.
18277         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
18278         Require gl_FUNC_TZSET_CLOBBER.
18279         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
18280         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
18281         members.
18282
18283 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18284
18285         Help the merge from coreutils.
18286         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
18287         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
18288         * m4/tzset.m4: Use it too.
18289
18290 2003-08-14  Paul Eggert  <eggert@twinsun.com>
18291
18292         * modules/tzset: New file.
18293
18294 2003-08-14  Jim Meyering  <jim@meyering.net>
18295
18296         Merges from coreutils.
18297         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
18298         variable names, rather than @FNMATCH_H@.
18299         * modules/alloca: Likewise for $(ALLOCA_H).
18300
18301         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
18302         the three copies of the literal target, `fnmatch.h'.
18303         * modules/alloca (alloca.h): Likewise.
18304
18305 2003-08-14  Jim Meyering  <jim@meyering.net>
18306
18307         Merge from coreutils.
18308         * m4/tzset.m4: New file.
18309         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
18310         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
18311         otherwise, AIX 5.1 systems would end up using the latter.
18312         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
18313         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
18314         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
18315         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
18316
18317 2003-08-14  Jim Meyering  <jim@meyering.net>
18318
18319         Merge from coreutils.
18320         * lib/obstack.h: Whitespace changes.
18321         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
18322         and xcalloc return values.
18323         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
18324         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
18325         hang on OSF/1 5.1 for DIR on both local and remote file systems.
18326         Reported by (and fix confirmed by) Nelson H. F. Beebe.
18327         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
18328         error from mntctl.
18329         Use mntctl's return value to drive the entry-processing loop, since
18330         we can't rely on the value of the vmt_length member in the last
18331         entry.  On some systems doing so could result in exhausting
18332         virtual memory.  Based in part on a patch from Mike Jetzer.
18333
18334 2003-08-14  Jim Meyering  <jim@meyering.net>
18335         and Paul Eggert  <eggert@twinsun.com>
18336
18337         Merges from coreutils, plus other fixes.
18338         * lib/physmem.c: Merge in portability changes from gcc/libiberty
18339         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
18340         for credits and details.  Thanks to Kaveh Ghazi for helping
18341         to keep these files in sync.
18342         (ARRAY_SIZE): Define it.
18343         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
18344         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
18345         (memcasecmp): Don't assume size_t fits in unsigned int.
18346         Remove casts and duplicate code.
18347         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
18348         (memcpy): Remove definition.
18349         Merge in some clean-up and optimization changes from glibc.
18350         [BLOCKSIZE]: Move definition to top of file.
18351         Ensure that it is a multiple of 64.
18352         Rearrange loop exit tests so as to avoid performing an
18353         additional fread after encountering an error or EOF.
18354         * lib/md5.h (md5_uintptr): Define.
18355         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
18356         return to the initial working directory.  Preserve errno
18357         for caller.
18358         * lib/idcache.c: Include "xalloc.h".
18359         (xmalloc, xrealloc): Remove decls.
18360         (getuser): Remove casts no longer required in C89.
18361         * lib/human.c: Include stdio.h, for sprintf.
18362         * lib/group-member.c: Include "xalloc.h".
18363         (xmalloc, xrealloc): Remove decls.
18364         (get_group_info): Remove casts no longer required in C89.
18365         * lib/getusershell.c (readname): Remove casts no longer required in
18366         C89.
18367         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
18368         * lib/getline.c: Whitespace fix, from coreutils.
18369
18370 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18371
18372         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
18373         Check for isascii.
18374
18375         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18376         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18377         Undo previous (whitespace-only) change.
18378
18379 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18380
18381         * lib/exclude.c: Include <ctype.h>
18382         (IN_CTYPE_DOMAIN): New macro.
18383         (is_space): New fn.
18384         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
18385         and empty lines.
18386
18387         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18388         Undo previous (whitespace-only) change.
18389
18390 2003-08-13  Paul Eggert  <eggert@twinsun.com>
18391
18392         * config/srclist-update: Change update back to the old behavior,
18393         leaving whitespace alone.  Use one 'sed' command rather than a
18394         pipeline.
18395         (fixlicense): Now a variable, not a function.
18396         (remove_trailing_blanks): Remove.
18397         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
18398         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18399         Undo previous (whitespace-only) change.
18400
18401 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18402
18403         Merge from coreutils.
18404         * modules/euidaccess: Add lib_SOURCES, include for new
18405         file euidaccess.h
18406
18407 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18408
18409         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
18410         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
18411         Normalize leading white space and remove trailing white space.
18412
18413         Merge from coreutils
18414         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
18415
18416         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
18417         0.12.1.  These files are now being upgraded automatically by
18418         ../config/srclist-update.
18419
18420 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18421
18422         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
18423         Normalize leading white space and remove trailing white space.
18424         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
18425         notice, as per ../config/srclist-update.
18426
18427         Merge from coreutils.
18428         * lib/euidaccess.h: New file.
18429         * lib/euidaccess.c: Include it.
18430         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
18431         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
18432         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
18433
18434 2003-08-12  Paul Eggert  <eggert@twinsun.com>
18435
18436         * config/srclist-update: Add copyright notice.
18437         (remove_id_lines, remove_trailing_blanks): New constants.
18438         (fixfile): Use them to normalize spacing a bit in copied files.
18439         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
18440         Normalize leading white space and remove trailing white space.
18441
18442         * config/texinfo.tex: Sync with texinfo.
18443
18444         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
18445         strtoul.c from libc, to merge coreutils whitespace changes.
18446
18447         * config/srclist.txt: Get the following m4 files from gettext:
18448         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
18449         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
18450         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
18451         wint_t.m4.
18452
18453 2003-08-12  Karl Berry  <karl@gnu.org>
18454
18455         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
18456         been made.
18457
18458 2003-08-11  Paul Eggert  <eggert@twinsun.com>
18459
18460         * modules/gnu-source, m4/gnu-source.m4:
18461         Remove; we're assuming Autoconf 2.54 or later now.
18462         Suggested by Bruno Haible.
18463         * MODULES.html.sh (func_all_modules): Remove gnu-source.
18464
18465 2003-08-11  Bruno Haible  <bruno@clisp.org>
18466
18467         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
18468
18469 2003-08-11  Bruno Haible  <bruno@clisp.org>
18470
18471         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
18472         (vasnprintf): Use it instead of wcslen.
18473
18474 2003-08-11  Bruno Haible  <bruno@clisp.org>
18475
18476         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
18477         value to ensure that _Bool promotes to int. Use #define for _Bool when
18478         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
18479
18480 2003-08-10  Karl Berry  <karl@gnu.org>
18481
18482         * lib/regex.h: update from libc (whitespace fix).
18483
18484 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18485
18486         Merge some files from coreutils.  These changes were
18487         originally made by Jim Meyering.
18488         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
18489         many older Unixes require this.
18490         * lib/alloca.c (alloca): Remove cast to argument of free;
18491         no longer needed in C89.
18492         * lib/alloca_.h, regex.h: Fix white space to match
18493         what GNU indent does.
18494
18495 2003-08-09  Paul Eggert  <eggert@twinsun.com>
18496
18497         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
18498         apparently Emacs's Unicode mode got confused before my 2003-08-05
18499         checkin.
18500
18501 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18502
18503         * m4/extensions.m4: New file.
18504         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
18505         Require gl_USE_SYSTEM_EXTENSIONS.
18506         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
18507         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
18508
18509 2003-08-08  Paul Eggert  <eggert@twinsun.com>
18510
18511         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
18512         * modules/extensions, modules/gnu-source: New files.
18513         * modules/timespec, modules/unlocked-io: Depend on extensions.
18514
18515 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18516
18517         * modules/restrict: New file.
18518         * MODULES.html.sh (func_all_modules): Add restrict.
18519         * modules/regex: Depend on restrict.
18520
18521 2003-08-07  Paul Eggert  <eggert@twinsun.com>
18522
18523         * m4/restrict.m4: New file.
18524         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
18525
18526 2003-08-07  Bruno Haible  <bruno@clisp.org>
18527
18528         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
18529         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
18530
18531 2003-08-07  Bruno Haible  <bruno@clisp.org>
18532
18533         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
18534         makes the module 'getndelim2' compatible with the module 'getline'.
18535
18536 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18537
18538         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
18539         byte with "\201" to avoid glitches when editing that source file
18540         with multi-gnome-terminal.
18541
18542 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18543
18544         * lib/bumpalloc.h: Remove.
18545
18546 2003-08-05  Paul Eggert  <eggert@twinsun.com>
18547
18548         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
18549         * modules/bumpalloc: Remove.
18550
18551 2003-08-04  Paul Eggert  <eggert@twinsun.com>
18552
18553         * lib/getloadavg.c: Change copyright notice and spacing to conform to
18554         GNU coding style.
18555
18556         Merge from coreutils.
18557         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
18558         1. From glibc.
18559         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
18560         from Karl Berry, implemented by Jim Meyering.
18561         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
18562         from Dmitry V. Levin.
18563         Remove anachronistic cast of xrealloc.
18564         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
18565         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
18566         type. Otherwise, it wouldn't compile with at least /bin/cc on
18567         ymp-cray-unicos9.0.2.X.
18568         Combine two mostly-identical uses of alloca into one.
18569         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
18570
18571 2003-08-04  Dave Love  <d.love@dl.ac.uk>
18572
18573         [From Emacs.]
18574
18575         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
18576         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
18577         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
18578         obsolete NLIST_NAME_UNION.
18579         [__GNU__]: Undef BSD and FSCALE.
18580         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
18581
18582 2003-08-03  Paul Eggert  <eggert@twinsun.com>
18583
18584         * lib/stdbool_.h (_Bool): Make it signed char, instead of
18585         an enum type, so that it's guaranteed to promote to int.  See:
18586         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
18587
18588 2003-08-03  Karl Berry  <karl@gnu.org>
18589
18590         * config/depcomp: update from automake.
18591
18592 2003-07-31  Paul Eggert  <eggert@twinsun.com>
18593
18594         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
18595         (strerror): Don't assume that a printable int fits in 14 bytes.
18596
18597 2003-07-31  Bruno Haible  <bruno@clisp.org>
18598
18599         * modules/getpass-gnu: New file.
18600         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
18601
18602 2003-07-31  Bruno Haible  <bruno@clisp.org>
18603
18604         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
18605
18606 2003-07-24  Karl Berry  <karl@gnu.org>
18607
18608         * config/missing: update from automake.
18609
18610 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
18611             Bruno Haible  <bruno@clisp.org>
18612
18613         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
18614         * lib/getline.c (getline, getdelim): Likewise.
18615         Remove _GNU_SOURCE define; now it's defined in config.h through
18616         m4/getline.m4.
18617
18618 2003-07-23  Karl Berry  <karl@gnu.org>
18619
18620         * config/config.sub: update from prep.
18621
18622 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18623
18624         * modules/xalloc (Depends-on): Add exitfail.
18625         * modules/xmemcoll: Likewise.
18626
18627 2003-07-22  Paul Eggert  <eggert@twinsun.com>
18628
18629         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
18630         over-parenthesization in macros.
18631
18632         Sync with coreutils.
18633
18634         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
18635         required by C99.
18636
18637         Use `exit_failure' for xalloc and xmemcoll instead of their own
18638         private exit-failure variables.
18639         * lib/xalloc.h (xalloc_exit_failure): Remove.
18640         * lib/xmalloc.c: Likewise.  Include exitfail.h.
18641         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
18642         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
18643         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
18644         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
18645
18646 2003-07-20  Jim Meyering  <jim@meyering.net>
18647
18648         * modules/closeout (Depends-on): Add exitfail.
18649         Suggestion from Bruno Haible.
18650
18651 2003-07-19  Karl Berry  <karl@gnu.org>
18652
18653         * config/config.sub: update from prep.
18654
18655 2003-07-18  Paul Eggert  <eggert@twinsun.com>
18656
18657         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
18658         Remove.
18659         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
18660         to test that it can stand by itself.  Include "exitfail.h".
18661         Clients should set exit_failure instead.
18662         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
18663
18664 2003-07-18  Bruno Haible  <bruno@clisp.org>
18665
18666         * modules/getndelim2: New file.
18667         * modules/getline: Share files with module getndelim2.
18668         * modules/getnline: Depend on getndelim2 instead of sharing files with
18669         it. Add getnline.c to lib_SOURCES.
18670         * MODULES.html.sh (func_all_modules): Add getndelim2.
18671
18672 2003-07-18  Bruno Haible  <bruno@clisp.org>
18673
18674         * m4/getndelim2.m4: New file.
18675         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
18676         invoke gl_PREREQ_GETNDELIM2.
18677         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
18678         gl_PREREQ_GETNDELIM2.
18679         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
18680         gl_GETNDELIM2.
18681
18682 2003-07-18  Bruno Haible  <bruno@clisp.org>
18683
18684         * lib/getndelim2.h: New file.
18685         * lib/getndelim2.c: Make into a module of its own. Include config.h,
18686         getndelim2.h.
18687         (getndelim2): Make non-static. Change return type to ssize_t.
18688         * lib/getline.h: Change argument names.
18689         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
18690         * lib/getnline.c: Include getndelim2.h.
18691
18692 2003-07-18  Andreas Schwab  <schwab@suse.de>
18693
18694         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
18695
18696 2003-07-17  Karl Berry  <karl@gnu.org>
18697
18698         * config/config.sub: update from prep.
18699
18700 2003-07-17  Bruno Haible  <bruno@clisp.org>
18701
18702         * modules/getnline: New file.
18703         * modules/getline: Add lib/getndelim2.c to source file list.
18704         * MODULES.html.sh (func_all_modules): Add getnline.
18705
18706 2003-07-17  Bruno Haible  <bruno@clisp.org>
18707
18708         * m4/getnline.m4: New file.
18709
18710 2003-07-17  Bruno Haible  <bruno@clisp.org>
18711
18712         * m4/Makefile.am.in: Remove file.
18713         * m4/Makefile.am: Remove file.
18714         * m4/Makefile.in: Remove file.
18715
18716 2003-07-17  Bruno Haible  <bruno@clisp.org>
18717
18718         * lib/getnline.h: New file.
18719         * lib/getnline.c: New file.
18720         * lib/getndelim2.c: New file, extracted from getline.c.
18721         (getndelim2): Renamed from getdelim2, with added nmax argument.
18722         * lib/getline.c: Include getndelim2.c.
18723         (getdelim2): Moved out to getndelim2.c.
18724         (getline, getdelim): Update.
18725
18726 2003-07-17  Bruno Haible  <bruno@clisp.org>
18727
18728         * lib/Makefile.am: Remove file.
18729         * lib/Makefile.in: Remove file.
18730
18731 2003-07-17  Bruno Haible  <bruno@clisp.org>
18732
18733         * configure.in: Remove file.
18734         * Makefile.in: Remove file.
18735
18736 2003-07-17  Bruno Haible  <bruno@clisp.org>
18737
18738         * MODULES.html.sh: Put the </BODY> right before </HTML>.
18739
18740 2003-07-16  Karl Berry  <karl@gnu.org>
18741
18742         * config/srclist-update: was running fixlicense twice, which caused
18743                 texinfo.tex to be nullified for some reason.  Simplify,
18744                 $gplsrc is no longer needed as far as I can see?
18745
18746 2003-07-16  Jim Meyering  <jim@meyering.net>
18747
18748         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
18749
18750 2003-07-15  Paul Eggert  <eggert@twinsun.com>
18751
18752         * config/srclist.txt: Get the following files from gettext-runtime/intl
18753         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
18754         ref-del.sin.  From Bruno Haible.
18755         * config/srclist-update (fixfile): Change grep pattern again, since the
18756         previous fix didn't work (there was another trailing $).  Use
18757         '[$]' to escape the $s.
18758
18759 2003-07-15  Karl Berry  <karl@gnu.org>
18760
18761         * lib/vasnprintf.c: update from gettext.
18762
18763 2003-07-15  Karl Berry  <karl@gnu.org>
18764
18765         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
18766         gets expanded when surrounded by '$'.
18767
18768 2003-07-15  Jim Meyering  <jim@meyering.net>
18769
18770         * modules/save-cwd: Don't depend on error.  From Derek Price.
18771
18772 2003-07-15  Jim Meyering  <jim@meyering.net>
18773
18774         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
18775
18776 2003-07-14  Simon Josefsson  <jas@extundo.com>
18777
18778         * modules/mempcpy: New file.
18779         * MODULES.html.sh (func_all_modules): Add mempcpy.
18780
18781 2003-07-14  Simon Josefsson  <jas@extundo.com>
18782
18783         * m4/mempcpy.m4: New file.
18784
18785 2003-07-14  Simon Josefsson  <jas@extundo.com>
18786
18787         * lib/mempcpy.h: New file.
18788         * lib/mempcpy.c: New file.
18789
18790 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18791
18792         * modules/getdate, modules/posixtm: Depend on mktime.
18793
18794 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18795
18796         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
18797         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
18798         unicodeio.c, unicodeio.h, unlocked-io.h:
18799         Switch from LGPL to GPL.
18800
18801 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18802
18803         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
18804         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
18805         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
18806         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
18807         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
18808         updated automatically by ../config/srclist-update.  This changes
18809         their license from LPGL to GPL.
18810
18811 2003-07-14  Paul Eggert  <eggert@twinsun.com>
18812
18813         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
18814         assumed to refer to the root of the most recent stable gettext version.
18815         * config/srclistvars.sh: Add defaults for eggert.
18816         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
18817         Match "This program" as well as "The program".  This is needed
18818         for gettext.
18819
18820 2003-07-14  Jim Meyering  <jim@meyering.net>
18821
18822         Don't emit diagnostics.  Let callers do that.
18823         * lib/save-cwd.c: Don't include "error.h".
18824         (save_cwd): Don't call error.  Ensure that errno is valid
18825         when returning nonzero.
18826
18827         * lib/save-cwd.h (restore_cwd): Update prototype.
18828         * lib/save-cwd.c (restore_cwd): Remove two parameters.
18829         Simplify.  Don't call error upon failure.  Let callers do that.
18830         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
18831         when auditing is enabled.  But don't bother updating the #if.
18832
18833 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
18834
18835         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
18836         it breaks C++ compilation.
18837         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
18838
18839 2003-07-10  Simon Josefsson  <jas@extundo.com>
18840
18841         * modules/strchrnul (Makefile.am): Add strchrnul.h.
18842
18843 2003-07-10  Jim Meyering  <jim@meyering.net>
18844
18845         * m4/clock_time.m4: Remove trailing blank.
18846         * m4/intmax_t.m4: Likewise.
18847
18848 2003-07-10  Jim Meyering  <jim@meyering.net>
18849
18850         * lib/vasnprintf.c: Remove trailing blanks.
18851         Make cpp indentation consistent.
18852
18853 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18854
18855         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
18856         posixver.c, strftime.c, strnlen.c, strverscmp.c:
18857         Switch from LGPL to GPL.
18858
18859 2003-07-09  Paul Eggert  <eggert@twinsun.com>
18860
18861         * config/srclist.txt: Sort sublists.  Add
18862         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
18863         that differ from gnulib for one reason or another; we'd like this list
18864         to be smaller but for now let's document what we have.
18865
18866 2003-07-08  Paul Eggert  <eggert@twinsun.com>
18867
18868         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
18869         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
18870         and sweeter "eval x=$x".
18871         * config/srclist.txt: Get lib/argp* from glibc.
18872
18873 2003-07-07  Paul Eggert  <eggert@twinsun.com>
18874
18875         * lib/mktime.c: Fix some boundary cases and remove need for floating
18876         point.
18877
18878         Issue a compile-time diagnostic if time_t is floating point, or if
18879         two's complement arithmetic is not in effect, or if arithmetic
18880         right shift does not propagate the sign.  These assumptions were
18881         all in the original code but they weren't checked.
18882
18883         (TIME_T_MIDPOINT, verify): New macros.
18884         (__isleap): Remove; it has integer overflow problems.
18885         (leapyear): New function, without those problems.
18886         (ydhms_tm_diff): Remove; splitting into two parts.
18887         (ydhms_diff): New function, containing the arithmetic part of
18888         the old ydhms_tm_diff function.  Issue a compile-time
18889         diagnostic if we are not using C99 integer division.
18890         Avoid casts when possible.
18891         (guess_time_tm): New function, containing the checking part of
18892         the old ydhms_tm_diff function.  Return the new value, rather than
18893         the difference between it and the old.  Accept a new argument T
18894         so that *T specifies the old value.  Check for overflow in the result.
18895
18896         (__mktime_internal): Use a time_t offset, not a long int offset.
18897         This undoes the 2003-06-04 change, which is no longer needed now
18898         that we have better overflow checking.
18899         (localtime_offset): Likewise.
18900
18901         (__mktime_internal): Avoid harmful overflow on hosts where time_t
18902         and long are 64-bit but int is only 32-bit.
18903         (ydhms_diff): Use long int to store year1 and yday1.
18904         Issue a compile-time diagnostic if long int is not wide enough.
18905
18906         (__mktime_internal): Use long int to store adjusted year and yday.
18907         Use plain C rather than preprocessor commands, if that doesn't
18908         affect efficiency.
18909         Check for overflow (and try to repair) after each probe
18910         rather than checking only at the very end.  This avoids some bugs
18911         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
18912         does not equal GMT offset at maximum time).
18913         Use integer to check for overflow rather than floating point; this
18914         is more portable to non-IEEE hosts, and is a tad faster.
18915         When we detect that we are oscillating between two values,
18916         don't check whether tm_isdst has the requested value, since
18917         we already know the answer.  When tm_isdst has the wrong value,
18918         use a different heuristic to find the right one, based on the
18919         extreme values actually observed in practice in tz2003a,
18920         rather than the (overly optimistic) "previous 3 calendar quarters".
18921
18922         (not_equal_tm, print_tm, check_result): Use "const T" rather than
18923         "T const" to accommodate glibc style.
18924         (check_result): Use less-confusing report format.  "long" -> "long int.
18925         (main): Likewise.
18926         Don't loop if the iteration overflows time_t.
18927         Allow a negative step in the iteration.
18928
18929 2003-07-06  Karl Berry  <karl@gnu.org>
18930
18931         * config/depcomp: update from automake.
18932         * config/config.sub: update from prep.
18933
18934 2003-07-03  Karl Berry  <karl@gnu.org>
18935
18936         * config/config.guess: update from prep.
18937
18938 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18939
18940         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
18941         xreadlink.c now includes it unconditionally.
18942
18943 2003-07-01  Paul Eggert  <eggert@twinsun.com>
18944
18945         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
18946         having it depend on HAVE_SYS_TYPES_H.
18947
18948 2003-07-01  Bruno Haible  <bruno@clisp.org>
18949
18950         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
18951         <sys/types.h> should be sufficient.
18952         Reported by Paul Eggert.
18953
18954 2003-06-26  Karl Berry  <karl@gnu.org>
18955
18956         * config/depcomp: update from automake.
18957
18958 2003-06-26  Bruno Haible  <bruno@clisp.org>
18959
18960         * modules/human: Depend on module stdbool.
18961
18962 2003-06-25  Bruno Haible  <bruno@clisp.org>
18963
18964         * modules/readlink: New file.
18965         * modules/xreadlink: Depend on it.
18966         * MODULES.html.sh (func_all_modules): Add readlink.
18967
18968 2003-06-25  Bruno Haible  <bruno@clisp.org>
18969
18970         * m4/readlink.m4: New file.
18971
18972 2003-06-25  Bruno Haible  <bruno@clisp.org>
18973
18974         * lib/readlink.c: New file.
18975
18976 2003-06-22  Karl Berry  <karl@gnu.org>
18977
18978         * config/srclist.txt: update mkinstalldirs from automake.
18979         * config/mkinstalldirs: update.
18980
18981 2003-06-22  Bruno Haible  <bruno@clisp.org>
18982
18983         Portability to mingw32.
18984         * m4/ssize_t.m4: New file, from GNU gettext.
18985         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
18986         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
18987
18988 2003-06-22  Bruno Haible  <bruno@clisp.org>
18989
18990         * modules/safe-read: Add m4/ssize_t.m4.
18991         * modules/xreadlink: Add m4/ssize_t.m4.
18992
18993 2003-06-20  Bruno Haible  <bruno@clisp.org>
18994
18995         Assume C89, so PARAMS isn't needed.
18996         * lib/unicodeio.h (PARAMS): Remove.
18997         * lib/unicodeio.c: Don't use PARAMS.
18998
18999 2003-06-18  Karl Berry  <karl@gnu.org>
19000
19001         * config/config.{guess,sub}: update from prep.
19002
19003 2003-06-18  Jim Meyering  <jim@meyering.net>
19004
19005         Merge changes from coreutils.
19006         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
19007         Remove explicit declarations of xmalloc and realloc.
19008         Include xalloc.h.
19009         (read_utmp): Remove anachronistic cast of xmalloc.
19010
19011 2003-06-17  Paul Eggert  <eggert@twinsun.com>
19012
19013         Assume C89, so PARAMS isn't needed.
19014         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
19015         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
19016         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
19017         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
19018         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
19019         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
19020         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
19021         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
19022         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
19023         lib/xstrtod.h, lib/xstrtol.h: Likewise.
19024         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
19025         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
19026         no longer needed. Anyway, config.h should always be included before any
19027         other file.
19028
19029 2003-06-11  Simon Josefsson  <jas@extundo.com>
19030
19031         * modules/sysexits: New file.
19032         * MODULES.html.sh (func_all_modules): Add sysexits.
19033
19034 2003-06-11  Simon Josefsson  <jas@extundo.com>
19035
19036         * lib/sysexit_.h: New file.
19037
19038 2003-06-11  Derek Price  <derek@ximbiot.com>
19039
19040         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
19041         necessary.
19042
19043 2003-06-11  Bruno Haible  <bruno@clisp.org>
19044
19045         * m4/sysexits.m4: New file.
19046
19047 2003-06-10  Simon Josefsson  <jas@extundo.com>
19048
19049         * lib/argp.h: New file, from glibc.
19050         * lib/argp-ba.c: New file, from glibc.
19051         * lib/argp-eexst.c: New file, from glibc.
19052         * lib/argp-fmtstream.c: New file, from glibc.
19053         * lib/argp-fmtstream.h: New file, from glibc.
19054         * lib/argp-fs-xinl.c: New file, from glibc.
19055         * lib/argp-help.c: New file, from glibc.
19056         * lib/argp-namefrob.h: New file, from glibc.
19057         * lib/argp-parse.c: New file, from glibc.
19058         * lib/argp-pv.c: New file, from glibc.
19059         * lib/argp-pvh.c: New file, from glibc.
19060         * lib/argp-xinl.c: New file, from glibc.
19061
19062 2003-06-10  Simon Josefsson  <jas@extundo.com>
19063
19064         * modules/strchrnul: New file.
19065
19066 2003-06-10  Simon Josefsson  <jas@extundo.com>
19067
19068         * modules/argp: New file.
19069
19070 2003-06-10  Simon Josefsson  <jas@extundo.com>
19071
19072         * m4/strchrnul.m4: New file.
19073
19074 2003-06-10  Simon Josefsson  <jas@extundo.com>
19075
19076         * lib/strchrnul.h: New file.
19077         * lib/strchrnul.c: New file.
19078
19079 2003-06-10  Bruno Haible  <bruno@clisp.org>
19080
19081         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
19082
19083 2003-06-07  Karl Berry  <karl@gnu.org>
19084
19085         * config/config.{guess,sub}: update from prep.
19086
19087 2003-06-07  Jim Meyering  <jim@meyering.net>
19088
19089         * modules/strtod: Use $(...) notation, not @...@ for
19090         AC_REPLACE'd variables.
19091         * modules/localcharset: Likewise.
19092
19093 2003-06-07  Jim Meyering  <jim@meyering.net>
19094
19095         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
19096         in place of my name in the copyright comment.
19097         Remove definition and uses of __P.
19098
19099         From coreutils.
19100         * lib/stat.c: Don't declare xmalloc explicitly.
19101         Instead, include "xalloc.h".
19102         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
19103         xrealloc, and xcalloc return values.
19104         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
19105         Improve comment.
19106         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
19107
19108 2003-06-07  Bruno Haible  <bruno@clisp.org>
19109
19110         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
19111         avoid AC_CONFIG_LINKS.
19112         * modules/fnmatch (Makefile.am): Use explicit creation rule for
19113         fnmatch.h, to avoid AC_CONFIG_LINKS.
19114         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
19115
19116 2003-06-07  Bruno Haible  <bruno@clisp.org>
19117
19118         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
19119         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
19120         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
19121         directory.
19122         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
19123         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
19124         directory.
19125
19126 2003-06-06  Jim Meyering  <jim@meyering.net>
19127
19128         Merge from coreutils.
19129         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
19130         Consolidate declarations and initializations of *_base* locals.
19131
19132         Merge from coreutils.
19133         This avoids a core dump on systems without GNU putenv,
19134         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
19135         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
19136         (unsetenv): New static function, from GNU libc.
19137         (rpl_putenv): Use it.
19138
19139         * lib/modechange.c: Remove trailing blanks.
19140
19141         Merge from coreutils.
19142         * lib/fsusage.c: Remove declaration of statfs.
19143         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
19144
19145         * lib/posixtm.c: Include <stdbool.h> unconditionally.
19146
19147 2003-06-06  Jim Meyering  <jim@meyering.net>
19148
19149         * lib/stdbool_.h: Renamed from stdbool.h.in.
19150
19151 2003-06-06  Jim Meyering  <jim@meyering.net>
19152             Bruno Haible  <bruno@clisp.org>
19153
19154         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
19155         Adjust Makefile.am snippet not to redirect directly to target.
19156         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
19157
19158 2003-06-05  Paul Eggert  <eggert@twinsun.com>
19159
19160         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
19161         mismatch, look in future quarters as well as past.  This fixes a
19162         bug when processing fall-backwards gaps immediately after a long
19163         period of daylight-saving time.
19164
19165         * lib/mktime.c: Assume freestanding C89 or better.
19166         (HAVE_LIMITS_H): Remove.  Assume it's 1.
19167         (__P): Remove; not used.
19168         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
19169         (mktime, not_equal_tm, print_tm, check_result,
19170         main): Use prototypes.  Use const * where appropriate.
19171         (main): Fix typo in testing code that uncovered by above changes.
19172         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
19173
19174 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19175
19176         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
19177         locale.h, localeconv.  This merges changes from coreutils.
19178
19179         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
19180         It can be removed after the next Autoconf is released.
19181         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
19182         needed.
19183
19184 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19185
19186         * lib/mktime.c: Fix Debian bug 177940
19187         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
19188         (localtime_offset): Now long int, not time_t, because we want it
19189         to be guaranteed to be signed.  All uses changed.
19190         (__mktime_internal): If overflow would occur when adding offset,
19191         don't add it.
19192
19193         Merge 'human' changes from coreutils.  Rewrite to support
19194         locale-specific notations like thousands separators.
19195         * lib/human.c: Simplify authorship notice.
19196         Include human.h immediately after config.h.
19197         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
19198         <limits.h>: Do not include, since human.h does.
19199         (SIZE_MAX, UINTMAX_MAX): New macros.
19200         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
19201         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
19202         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
19203         (power_letter): Renamed from suffixes.
19204         (generate_suffix_backwards): Remove.
19205         (adjust_value): Now takes int style (because of human.h changes)
19206         and long double value (for greater precision on some platforms).
19207         (group_number): New function.
19208         (human_readable): Use it.  Use integer options, not enum.
19209         Put the options before the sizes in the arg list.
19210         Support all the new options.
19211         The old human_readable function has been removed;
19212         use inttostr.h instead.
19213         (human_readable, default_block_size, humblock):
19214         Use uintmax_t, not int, for block sizes.
19215         (human_readable_inexact, block_size_types): Remove.
19216         (block_size_opts): New constant.
19217         (human_options): Renamed from human_block_size, with new signature
19218         that allows block sizes up to UINTMAX_MAX.  All callers changed.
19219         * lib/human.h: Add copyright and authorship notice.
19220         Include <limits.h> and <stdbool.h> unconditionally.
19221         (PARAMS): Remove.  All uses removed.
19222         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
19223         (enum human_inexact_style): Remove tag; now a nameless enum.
19224         (human_floor, human_ceiling, human_round_to_even): Now have
19225         values 2, 0, 1 rather than -1, 1, 0.
19226         (human_group_digits, human_suppress_point_zero, human_autoscale,
19227         human_base_1024, human_SI, human_B): New constants.
19228         (human_readable_inexact, human_block_size): Remove.
19229         (human_readable): Size args are now uintmax_t, not int.
19230         (human_options): New decl.
19231
19232         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
19233         unnecessary now that we assume C89 or better.  This change
19234         imported from coreutils.
19235
19236         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19237         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
19238         in the 2003-05-30 sync from glibc.
19239
19240         .h files should stand alone, but we shouldn't include <sys/types.h>
19241         if we can get away with just <stddef.h>.
19242
19243         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
19244         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
19245         rather than <sys/types.h>, as we merely need size_t.
19246         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
19247         to get size_t.
19248         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
19249         Include <stdio.h>, to get FILE.
19250         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
19251         memcasecmp.h has included <stddef.h> and all we need is size_t.
19252         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
19253         our interface, instead of including <sys/types.h>
19254
19255 2003-06-04  Paul Eggert  <eggert@twinsun.com>
19256
19257         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
19258         now, as glibc mktime is buggy on non-glibc systems.
19259
19260 2003-06-03  Karl Berry  <karl@gnu.org>
19261
19262         * config/config.sub: update from prep.
19263
19264 2003-06-02  Paul Eggert  <eggert@twinsun.com>
19265
19266         [from coreutils]
19267         Fix some minor time-related bugs with POSIX time arguments.
19268         Some valid time stamps were being rejected (notably -1, and
19269         time stamps before 1900 on 64-bit hosts).  And some invalid
19270         time stamps were being accepted, e.g. September 31.
19271
19272         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
19273         that we can return (time_t) -1 successfully.
19274         * lib/posixtm.c: Likewise.
19275         [HAVE_STDBOOL_H]: Include <stdbool.h>.
19276         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
19277         (t): Remove static var.
19278         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
19279         of static var.  All uses changed.
19280         (year): Do not reject years before 1900; they can occur with
19281         64-bit time_t.
19282         (posix_time_parse): Do not check for out-of-range components;
19283         that is now the caller's responsibility, since our checks were
19284         only approximations.
19285         (posixtime): Use mktime to check for out-of-range components,
19286         since it knows them exactly.
19287         If mktime returns (time_t) -1, check whether an error actually occurred
19288         by invoking localtime on -1.
19289         (main) [TEST_POSIXTIME]: Check for input data errors, and report
19290         posixtime failures better.
19291         Improve the test data (in comments only).
19292
19293 2003-06-02  Karl Berry  <karl@gnu.org>
19294
19295         * config/mkinstalldirs (version): new variable.
19296         (--version): new option.
19297         (usage): improve message.
19298
19299 2003-05-30  Karl Berry  <karl@gnu.org>
19300
19301         * lib/mktime.c: update from libc.
19302
19303 2003-05-30  Bruno Haible  <bruno@clisp.org>
19304
19305         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
19306         * config/config.rpath: Upgrade to gettext-0.12.1.
19307
19308 2003-05-30  Bruno Haible  <bruno@clisp.org>
19309
19310         * m4/gettext.m4: Upgrade to gettext-0.12.1.
19311         * m4/nls.m4: New file, from gettext-0.12.1.
19312         * m4/po.m4: New file, from gettext-0.12.1.
19313         * m4/progtest.m4: Upgrade to gettext-0.12.1.
19314
19315 2003-05-30  Bruno Haible  <bruno@clisp.org>
19316
19317         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
19318         * lib/localcharset.h: Likewise.
19319         * lib/localcharset.c: Likewise.
19320
19321 2003-05-29  Karl Berry  <karl@gnu.org>
19322
19323         * config/config.rpath: update from gettext.
19324
19325 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19326
19327         Assume the headers required for C89 freestanding compilers.
19328         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
19329         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
19330         * m4/human.m4 (gl_HUMAN): Likewise.
19331         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
19332         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
19333         * m4/userspec.m4 (gl_USERSPEC): Likewise.
19334         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
19335         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
19336         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
19337
19338 2003-05-28  Paul Eggert  <eggert@twinsun.com>
19339
19340         Assume the headers required for C89 freestanding compilers.
19341         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
19342         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
19343         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
19344         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
19345         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
19346         define, since <limits.h> is guaranteed to do that.
19347         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
19348         * lib/exclude.c: Include <stdbool.h> unconditionally.
19349         * lib/tempname.c: Include <stddef.h> unconditionally.
19350         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
19351         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
19352         <stddef.h> does that.
19353         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
19354         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
19355         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
19356         needed.
19357         * lib/xstrtol.c: Likewise.
19358         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
19359         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
19360
19361         * lib/addext.c (addext): Use assignment rather than cast, to avoid
19362         warnings on some platforms.
19363
19364         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
19365         arbitrarily.
19366
19367 2003-05-26  Jim Meyering  <jim@meyering.net>
19368
19369         Merge in a change from coreutils:
19370         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
19371         that is guaranteed to be `no'.  Use `no_such_member' to indicate
19372         that condition, rather than `-1' which is slightly misleading.
19373         Change the name of the cache variable to have the gl_ prefix.
19374         Prompted by a patch from Richard Dawe for DJGPP.
19375
19376 2003-05-24  Karl Berry  <karl@gnu.org>
19377
19378         * config/config.guess: update from prep.
19379
19380 2003-05-22  Karl Berry  <karl@gnu.org>
19381
19382         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
19383
19384 2003-05-20  Karl Berry  <karl@gnu.org>
19385
19386         * config/config.guess: update from prep.
19387
19388 2003-05-18  Karl Berry  <karl@gnu.org>
19389
19390         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
19391         might actually be set by the user.
19392
19393         * config/depcomp, install-sh, mdate-sh: update from automake.
19394
19395 2003-05-17  Bruno Haible  <bruno@clisp.org>
19396
19397         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
19398         invalid expansion for AC_EGREP_CPP.
19399         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
19400         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
19401         Suggested by Akim Demaille <akim@epita.fr> in
19402         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
19403
19404 2003-05-12  Jim Meyering  <jim@meyering.net>
19405
19406         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
19407         the space-padded-by-default conversion specifiers, %e, %k, %l.
19408
19409 2003-05-12  Bruno Haible  <bruno@clisp.org>
19410
19411         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
19412         the string is longer than 4 KB.
19413
19414 2003-05-11  Karl Berry  <karl@gnu.org>
19415
19416         * config/config.{guess,sub}: update from prep.
19417
19418 2003-05-09  Bruno Haible  <bruno@clisp.org>
19419
19420         * modules/error: Add m4/strerror_r.m4 to file list.
19421
19422 2003-05-03  Bruno Haible  <bruno@clisp.org>
19423
19424         Upgrade to Unicode-4.0.
19425         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
19426         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
19427         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
19428         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
19429         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
19430         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
19431         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
19432         Change width of U+E0100..U+E01EF from 1 to 0.
19433
19434 2003-04-25  Jim Meyering  <jim@meyering.net>
19435
19436         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
19437         of type size_t, not int.
19438
19439 2003-04-25  Bruno Haible  <bruno@clisp.org>
19440
19441         * lib/copy-file.c: Include <stddef.h>, for size_t.
19442
19443 2003-04-21  Paul Eggert  <eggert@twinsun.com>
19444
19445         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
19446         code which expansion is under static control.  Patch imported from
19447         Akim Demaille's patch to Bison; see
19448         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
19449
19450 2003-04-14  Bruno Haible  <bruno@clisp.org>
19451
19452         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
19453
19454 2003-04-11  Jim Meyering  <jim@meyering.net>
19455
19456         Merge changes from Coreutils.
19457
19458         2003-03-22  Jim Meyering  <jim@meyering.net>
19459
19460         * lib/strftime.c (widen): Cast alloca return value to proper type.
19461
19462         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
19463
19464         From GNU libc.
19465         * lib/strftime.c (my_strftime): Handle very large width
19466         specifications for numeric values correctly.  Improve checks for
19467         overflow.
19468
19469         2003-01-19  Jim Meyering  <jim@meyering.net>
19470
19471         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
19472         definitions.
19473         (nl_get_alt_digit) [! defined my_strftime]: Define.
19474         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
19475         _nl_get_alt_digit and _nl_get_walt_digit.
19476
19477         * lib/strftime.c (my_strftime): Merge in locale-related changes from
19478         libc. These changes have no effect outside of _LIBC.
19479
19480 2003-04-10  Bruno Haible  <bruno@clisp.org>
19481
19482         * modules/findprog: New file.
19483         * MODULES.html.sh (func_all_modules): Add it.
19484
19485 2003-04-10  Bruno Haible  <bruno@clisp.org>
19486
19487         * m4/findprog.m4: New file.
19488         * m4/eaccess.m4: New file.
19489
19490 2003-04-10  Bruno Haible  <bruno@clisp.org>
19491
19492         * lib/findprog.h: New file, from GNU gettext.
19493         * lib/findprog.c: New file, from GNU gettext.
19494
19495 2003-04-05  Jim Meyering  <jim@meyering.net>
19496
19497         Merge changes from Coreutils.
19498
19499         * lib/exclude.h (PARAMS): Remove definition and uses.
19500         * lib/exclude.c: Remove uses of `PARAMS'.
19501
19502         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
19503         Add test-cases for DOS filenames. Declare program_name.
19504         (main): Set up program_name.  Patch by Rich Dawe.
19505
19506         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
19507         error from mntctl.
19508         Use mntctl's return value to drive the entry-processing loop, since
19509         we can't rely on the value of the vmt_length member in the last
19510         entry.  On some systems doing so could result in exhausting
19511         virtual memory.  Based in part on a patch from Mike Jetzer.
19512
19513 2003-04-04  Bruno Haible  <bruno@clisp.org>
19514
19515         * modules/linebreak: New file.
19516         * MODULES.html.sh (func_all_modules): Add it.
19517
19518 2003-04-04  Bruno Haible  <bruno@clisp.org>
19519
19520         * m4/linebreak.m4: New file.
19521
19522 2003-04-04  Bruno Haible  <bruno@clisp.org>
19523
19524         * lib/linebreak.h: New file, from GNU gettext.
19525         * lib/linebreak.c: New file, from GNU gettext with slight
19526         modifications.
19527         * lib/lbrkprop.h: New file, from GNU gettext.
19528
19529 2003-04-03  Bruno Haible  <bruno@clisp.org>
19530
19531         * modules/utf8-ucs4: New file.
19532         * modules/utf16-ucs4: New file.
19533         * modules/ucs4-utf8: New file.
19534         * modules/ucs4-utf16: New file.
19535         * MODULES.html.sh (func_all_modules): Add them.
19536
19537 2003-04-03  Bruno Haible  <bruno@clisp.org>
19538
19539         * m4/utf-ucs4.m4: New file.
19540         * m4/ucs4-utf.m4: New file.
19541
19542 2003-04-03  Bruno Haible  <bruno@clisp.org>
19543
19544         * lib/utf8-ucs4.h: New file, from GNU gettext.
19545         * lib/utf16-ucs4.h: New file, from GNU gettext.
19546         * lib/ucs4-utf8.h: New file, from GNU gettext.
19547         * lib/ucs4-utf16.h: New file, from GNU gettext.
19548
19549 2003-04-02  Bruno Haible  <bruno@clisp.org>
19550
19551         * modules/binary-io: New file.
19552         * MODULES.html.sh (func_all_modules): Add it.
19553
19554 2003-04-02  Bruno Haible  <bruno@clisp.org>
19555
19556         * lib/binary-io.h: New file, from GNU gettext.
19557
19558 2003-04-01  Bruno Haible  <bruno@clisp.org>
19559
19560         * modules/pathname: New file.
19561         * MODULES.html.sh (func_all_modules): Add it.
19562
19563 2003-04-01  Bruno Haible  <bruno@clisp.org>
19564
19565         * lib/pathname.h: New file, from GNU gettext.
19566         * lib/concatpath.c: New file, from GNU gettext.
19567
19568 2003-03-30  Bruno Haible  <bruno@clisp.org>
19569
19570         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
19571
19572 2003-03-30  Bruno Haible  <bruno@clisp.org>
19573
19574         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
19575         function chown() doesn't exist.
19576
19577 2003-03-28  Bruno Haible  <bruno@clisp.org>
19578
19579         * modules/copy-file: New file.
19580         * MODULES.html.sh (func_all_modules): Add it.
19581
19582 2003-03-28  Bruno Haible  <bruno@clisp.org>
19583
19584         * m4/copy-file.m4: New file.
19585
19586 2003-03-28  Bruno Haible  <bruno@clisp.org>
19587
19588         * lib/copy-file.h: New file, from GNU gettext.
19589         * lib/copy-file.c: New file, from GNU gettext.
19590
19591 2003-03-18  Jim Meyering  <jim@meyering.net>
19592
19593         * lib/quote.c (quote_n): Fix typo in comment.
19594
19595 2003-03-18  Bruno Haible  <bruno@clisp.org>
19596
19597         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
19598         checking.
19599         * m4/onceonly_2_57.m4: Likewise.
19600
19601 2003-03-17  Bruno Haible  <bruno@clisp.org>
19602
19603         * m4/onceonly.m4: Require autoconf 2.54 or newer.
19604         (m4_quote): Remove macro.
19605         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
19606
19607 2003-03-14  Jim Meyering  <jim@meyering.net>
19608
19609         Merge changes from Coreutils.
19610         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
19611         to be const, in order to avoid warnings.
19612         (obstack_room): Likewise.
19613         (obstack_empty_p): Likewise.
19614
19615 2003-03-14  Bruno Haible  <bruno@clisp.org>
19616
19617         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
19618         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
19619
19620 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19621
19622         Merge changes from Bison.
19623         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
19624         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
19625         when compiling Bison 1.875's `bitset bset = obstack_alloc
19626         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
19627         * lib/hash.c: Include <stdbool.h> unconditionally.
19628
19629 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19630
19631         * m4/onceonly.m4 (m4_quote): New macro.
19632         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
19633         Quote AC_FOREACH variable-expansions properly.
19634
19635 2003-03-13  Paul Eggert  <eggert@twinsun.com>
19636
19637         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
19638
19639 2003-03-09  Paul Eggert  <eggert@twinsun.com>
19640
19641         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
19642         Reported by Bruce Becker; see:
19643         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
19644
19645 2003-03-03  Paul Eggert  <eggert@twinsun.com>
19646             Bruno Haible  <bruno@clisp.org>
19647
19648         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
19649         Reported by John Hughes, see
19650         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
19651
19652 2003-02-20  Bruno Haible  <bruno@clisp.org>
19653
19654         * MODULES.html.sh (func_all_modules): Add poll.
19655
19656 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19657
19658         * modules/poll: New file.
19659
19660 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19661
19662         * lib/poll_.h: New file.
19663         * lib/poll.c: New file.
19664
19665 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
19666
19667         * m4/poll.m4: New file.
19668
19669 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19670
19671         * modules/mathl: New file.
19672
19673 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19674
19675         * lib/mathl.h: New file.
19676         * lib/acosl.c: New file.
19677         * lib/asinl.c: New file.
19678         * lib/atanl.c: New file.
19679         * lib/ceill.c: New file.
19680         * lib/cosl.c: New file.
19681         * lib/expl.c: New file.
19682         * lib/floorl.c: New file.
19683         * lib/frexpl.c: New file.
19684         * lib/ldexpl.c: New file.
19685         * lib/logl.c: New file.
19686         * lib/sincosl.c: New file.
19687         * lib/sinl.c: New file.
19688         * lib/sqrtl.c: New file.
19689         * lib/tanl.c: New file.
19690         * lib/trigl.c: New file.
19691         * lib/trigl.h: New file.
19692
19693 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
19694
19695         * m4/mathl.m4: New file.
19696
19697 2003-02-18  Bruno Haible  <bruno@clisp.org>
19698
19699         * MODULES.html.sh (func_all_modules): Add mathl.
19700
19701 2003-02-17  Bruno Haible  <bruno@clisp.org>
19702
19703         * modules/mkdtemp: New module.
19704         * MODULES.html.sh (func_all_modules): Add it.
19705
19706 2003-02-17  Bruno Haible  <bruno@clisp.org>
19707
19708         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
19709
19710 2003-02-17  Bruno Haible  <bruno@clisp.org>
19711
19712         * lib/mkdtemp.h: New file, from GNU gettext.
19713         * lib/mkdtemp.c: New file, from GNU gettext.
19714
19715 2003-02-02  Jim Meyering  <jim@meyering.net>
19716
19717         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
19718         e.g. glibc-2.2.93.
19719
19720 2003-01-31  Bruno Haible  <bruno@clisp.org>
19721
19722         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
19723         'rpl_rename'.
19724         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
19725         'rpl_strnlen'.
19726         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
19727         'rpl_strtod'.
19728         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
19729         'rpl_utime'.
19730
19731 2003-01-31  Bruno Haible  <bruno@clisp.org>
19732
19733         * lib/rename.c: #undef rename before defining rpl_rename.
19734         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
19735
19736 2003-01-30  Bruno Haible  <bruno@clisp.org>
19737
19738         * modules/vasnprintf, modules/vasprintf: New modules.
19739         * MODULES.html.sh (func_all_modules): Add them.
19740
19741 2003-01-30  Bruno Haible  <bruno@clisp.org>
19742
19743         * m4/signed.m4: New file, from GNU gettext.
19744         * m4/longdouble.m4: New file, from GNU gettext.
19745         * m4/wchar_t.m4: New file, from GNU gettext.
19746         * m4/wint_t.m4: New file, from GNU gettext.
19747         * m4/vasnprintf.m4: New file.
19748         * m4/vasprintf.m4: New file.
19749
19750 2003-01-30  Bruno Haible  <bruno@clisp.org>
19751
19752         * lib/printf-args.h: New file, from GNU gettext.
19753         * lib/printf-args.c: New file, from GNU gettext.
19754         * lib/printf-parse.h: New file, from GNU gettext.
19755         * lib/printf-parse.c: New file, from GNU gettext.
19756         * lib/vasnprintf.h: New file, from GNU gettext.
19757         * lib/vasnprintf.c: New file, from GNU gettext.
19758         * lib/asnprintf.c: New file, from GNU gettext.
19759         * lib/vasprintf.h: New file, from GNU gettext with modifications.
19760         * lib/vasprintf.c: New file, from GNU gettext.
19761         * lib/asprintf.c: New file, from GNU gettext.
19762
19763 2003-01-29  Bruno Haible  <bruno@clisp.org>
19764
19765         * modules/stpncpy: New module.
19766         * MODULES.html.sh (func_all_modules): Add it.
19767
19768 2003-01-29  Bruno Haible  <bruno@clisp.org>
19769
19770         * m4/stpncpy.m4: New file.
19771
19772 2003-01-29  Bruno Haible  <bruno@clisp.org>
19773
19774         * lib/stpncpy.h: New file, from GNU gettext with modifications.
19775         * lib/stpncpy.c: New file, from GNU gettext with modifications.
19776
19777 2003-01-28  Bruno Haible  <bruno@clisp.org>
19778
19779         * modules/c-ctype: New module.
19780         * MODULES.html.sh (func_all_modules): Add it.
19781
19782 2003-01-28  Bruno Haible  <bruno@clisp.org>
19783
19784         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
19785         Paul Eggert.
19786         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
19787         Paul Eggert.
19788
19789 2003-01-27  Bruno Haible  <bruno@clisp.org>
19790
19791         * modules/xsetenv: New module.
19792         * MODULES.html.sh (func_all_modules): Add it.
19793
19794 2003-01-27  Bruno Haible  <bruno@clisp.org>
19795
19796         * lib/xsetenv.h: New file, from GNU gettext.
19797         * lib/xsetenv.c: New file, from GNU gettext.
19798
19799 2003-01-23  Jim Meyering  <jim@meyering.net>
19800
19801         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
19802         from working on systems without dirfd (at least Irix and OSF1/Tru64).
19803
19804 2003-01-23  Bruno Haible  <bruno@clisp.org>
19805
19806         * modules/minmax: New module.
19807         * MODULES.html.sh (func_all_modules): Add it.
19808
19809 2003-01-23  Bruno Haible  <bruno@clisp.org>
19810
19811         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
19812         Eggert.
19813
19814 2003-01-22  Bruno Haible  <bruno@clisp.org>
19815
19816         * modules/exit: New module.
19817         * MODULES.html.sh (func_all_modules): Add it.
19818
19819 2003-01-22  Bruno Haible  <bruno@clisp.org>
19820
19821         * lib/exit.h: New file, from GNU gettext.
19822
19823 2003-01-19  Bruno Haible  <bruno@clisp.org>
19824
19825         * gnulib-tool: Recognize option --extract-maintainer.
19826         (func_get_maintainer): New function.
19827         * modules/*: Add Maintainer entry.
19828
19829 2003-01-16  Jim Meyering  <jim@meyering.net>
19830
19831         * m4/regex.m4: The `regex' struct is both input and output.
19832         Initialize it before each use.  Patch by Tim Waugh.
19833
19834 2003-01-16  Bruno Haible  <bruno@clisp.org>
19835
19836         * MODULES.html.sh: Add a table of contents. Add the module name as
19837         leftmost column. Add hyperlinks.
19838
19839 2003-01-15  Bruno Haible  <bruno@clisp.org>
19840
19841         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
19842
19843 2003-01-15  Bruno Haible  <bruno@clisp.org>
19844
19845         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
19846         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
19847         suffix.
19848
19849 2003-01-15  Bruno Haible  <bruno@clisp.org>
19850
19851         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
19852
19853 2003-01-15  Bruno Haible  <bruno@clisp.org>
19854
19855         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
19856         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
19857
19858 2003-01-14  Jim Meyering  <jim@meyering.net>
19859
19860         * lib/same.c (same_name): Tweak a comment.
19861
19862 2003-01-14  Bruno Haible  <bruno@clisp.org>
19863
19864         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
19865         when a string comparison is sufficient.
19866
19867 2003-01-14  Bruno Haible  <bruno@clisp.org>
19868
19869         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
19870         'unsigned int'.
19871
19872 2003-01-14  Bruno Haible  <bruno@clisp.org>
19873
19874         * lib/hash-pjw.c: Add comment about low quality of this function.
19875
19876 2003-01-13  Bruno Haible  <bruno@clisp.org>
19877
19878         * modules/stpcpy: Distribute lib/stpcpy.h.
19879         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
19880
19881 2003-01-13  Bruno Haible  <bruno@clisp.org>
19882
19883         * modules/*: Add a description.
19884         * modules/strpbrk: Fix Makefile.am snippet.
19885         * modules/strtoimax: Fix dependencies.
19886         * modules/strtoumax: Likewise.
19887
19888 2003-01-13  Bruno Haible  <bruno@clisp.org>
19889
19890         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
19891         * modules/alloca (Makefile.am): All object files depend on alloca.h.
19892         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
19893
19894 2003-01-13  Bruno Haible  <bruno@clisp.org>
19895
19896         * gnulib-tool (func_create_testdir): Store config/* files in the main
19897         directory.
19898         * config.rpath: Move to ...
19899         * config/config.rpath: ... here.
19900         * modules/gettext: Contains config/config.rpath, not config.rpath.
19901         * modules/iconv: Likewise.
19902
19903 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19904
19905         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19906         to avoid collisions with libcurses and libreadline.
19907
19908         * m4/getstr.m4: Remove.
19909         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
19910
19911 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19912
19913         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19914         to avoid collisions with libcurses and libreadline.
19915
19916         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
19917         * lib/getstr.h, getstr.c: Remove.
19918         * lib/getline.c: Include "getline.h", to check interface.
19919         Move body of old getstr.c here: this defines MIN_CHUNK and
19920         declares getdelim2, which is renamed from getstr.
19921         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
19922
19923         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
19924         All uses changed.
19925         * lib/linebuffer.h: Likewise.
19926         (readline): Remove backward-compatibility macro.
19927
19928 2003-01-12  Paul Eggert  <eggert@twinsun.com>
19929
19930         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
19931         to avoid collisions with libcurses and libreadline.
19932         * getstr: Remove.
19933         * MODULES.html.sh: Remove getstr.
19934         * modules/getline: Depend on unlocked-io, not getstr.
19935
19936 2003-01-12  Jim Meyering  <jim@meyering.net>
19937
19938         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
19939
19940 2003-01-10  Bruno Haible  <bruno@clisp.org>
19941
19942         * modules/alloca: Change Makefile.am requirements. Simplify Include
19943         requirements. Add lib/alloca_.h to file list.
19944
19945 2003-01-10  Bruno Haible  <bruno@clisp.org>
19946
19947         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
19948
19949 2003-01-10  Bruno Haible  <bruno@clisp.org>
19950
19951         * lib/alloca_.h: New file.
19952         * lib/getdate.y: Unconditionally include alloca.h.
19953         * lib/makepath.c: Likewise.
19954         * lib/setenv.c: Likewise.
19955         * lib/userspec.c: Likewise.
19956
19957 2003-01-09  Karl Berry  <karl@gnu.org>
19958
19959         * MODULES.html.sh: include `dirname $0` in PATH, to find
19960         gnulib-tool.
19961
19962 2003-01-09  Bruno Haible  <bruno@clisp.org>
19963
19964         * modules/stdbool: Change configure.ac, Makefile.am requirements.
19965         Simplify Include requirements. Add lib/stdbool.h.in to file list.
19966
19967 2003-01-09  Bruno Haible  <bruno@clisp.org>
19968
19969         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
19970
19971 2003-01-09  Bruno Haible  <bruno@clisp.org>
19972
19973         * lib/stdbool.h.in: New file.
19974
19975 2003-01-09  Bruno Haible  <bruno@clisp.org>
19976
19977         * gnulib-tool (func_all_modules): Ignore files ending in ~.
19978         * MODULES.html.sh: Likewise.
19979
19980 2003-01-08  Jim Meyering  <jim@meyering.net>
19981
19982         * lib/full-write.c: Undefine and define-away `const' after inclusion
19983         of errno.h, not before.  Suggestion from Bruno Haible.
19984
19985 2003-01-08  Bruno Haible  <bruno@clisp.org>
19986
19987         * modules/full-read: Depend on full-write.
19988
19989 2003-01-08  Bruno Haible  <bruno@clisp.org>
19990
19991         * lib/safe-read.c: Include specification header first, to ensure its
19992         selfcontainedness.
19993         * lib/full-write.c: Likewise.
19994
19995 2003-01-07  Jim Meyering  <jim@meyering.net>
19996
19997         * lib/full-write.c: Rework so that it may serve to define full_read,
19998         too.
19999         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
20000
20001 2003-01-07  Bruno Haible  <bruno@clisp.org>
20002
20003         * lib/strtoimax.c: Include <stdint.h> as an alternative to
20004         <inttypes.h>.
20005         * lib/xstrtol.h: Likewise.
20006         * lib/xstrtoimax.c: Likewise.
20007         * lib/xstrtoumax.c: Likewise.
20008         * lib/human.h: Likewise.
20009
20010         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
20011         on systems that have <inttypes.h> but not <stdint.h>.
20012
20013 2003-01-07  Bruno Haible  <bruno@clisp.org>
20014
20015         * MODULES.html.sh: Add copyright notice.
20016         (missed_files): Omit CVS directory entries.
20017         (func_module): Make it work with sed-3.02.
20018         * MODULES.txt: Remove file.
20019
20020 2003-01-06  Jim Meyering  <jim@meyering.net>
20021
20022         * lib/version-etc.c: Update year in translatable copyright string.
20023
20024 2003-01-03  Karl Berry  <karl@gnu.org>
20025
20026         * config/config.{guess,sub}: update from prep.
20027
20028 2003-01-02  Karl Berry  <karl@gnu.org>
20029
20030         * doc/COPYING.DOC: belatedly updated to 1.2.
20031
20032 2003-01-01  Karl Berry  <karl@gnu.org>
20033
20034         * gnulib-tool (func_verify_module): report module name $module in
20035         error message, not $1.
20036         * gnulib-tool (create-testdir): don't complain if destdir couldn't
20037         be created, only if it doesn't exist.
20038         * gnulib-tool (last_checkin_date): don't expand the $Date here.
20039
20040 2002-12-31  Paul Eggert  <eggert@twinsun.com>
20041
20042         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
20043
20044 2002-12-31  Paul Eggert  <eggert@twinsun.com>
20045
20046         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
20047         memcmp if strcoll doesn't work.
20048
20049 2002-12-31  Bruno Haible  <bruno@clisp.org>
20050
20051         * lib/utime.c (utime_null): No need to call ftruncate if the file was
20052         nonempty.
20053
20054 2002-12-31  Bruno Haible  <bruno@clisp.org>
20055
20056         * lib/memcoll.c (STRCOLL): New macro.
20057         (memcoll): Use it.
20058
20059 2002-12-31  Bruno Haible  <bruno@clisp.org>
20060
20061         * lib/localcharset.h: New file.
20062         * lib/localcharset.c: Include it.
20063         * lib/unicodeio.c: Likewise.
20064
20065 2002-12-31  Bruno Haible  <bruno@clisp.org>
20066
20067         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
20068         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
20069
20070 2002-12-31  Bruno Haible  <bruno@clisp.org>
20071
20072         * lib/getline.h: Include <stddef.h>, for size_t.
20073
20074         * lib/unicodeio.h: Include <stddef.h>, for size_t.
20075         * lib/unicodeio.c: Don't include <stddef.h>.
20076
20077 2002-12-31  Bruno Haible  <bruno@clisp.org>
20078
20079         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
20080         HAVE_TM_ZONE.
20081
20082 2002-12-24  Karl Berry  <karl@gnu.org>
20083
20084         * config/config.guess: update from prep.
20085
20086 2002-12-24  Bruno Haible  <bruno@clisp.org>
20087
20088         General infrasructure.
20089         * m4/README: Rewritten.
20090         * m4/onceonly.m4: New file.
20091         * m4/onceonly_2_57.m4: New file.
20092
20093         Module atexit.
20094         * m4/atexit.m4: New file.
20095
20096         Module strtod.
20097         * m4/strtod.m4: New file.
20098
20099         Module strtol.
20100         * m4/strtol.m4: New file.
20101
20102         Module strtoul.
20103         * m4/strtoul.m4: New file.
20104
20105         Module memchr.
20106         * m4/memchr.m4: New file.
20107
20108         Module memcmp.
20109         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
20110         (jm_FUNC_MEMCMP): Invoke it.
20111
20112         Module memcpy.
20113         * m4/memcpy.m4: New file.
20114
20115         Module memmove.
20116         * m4/memmove.m4: New file.
20117
20118         Module memset.
20119         * m4/memset.m4: New file.
20120
20121         Module strcspn.
20122         * m4/strcspn.m4: New file.
20123
20124         Module strpbrk.
20125         * m4/strpbrk.m4: New file.
20126
20127         Module strstr.
20128         * m4/strstr.m4: New file.
20129
20130         Module strerror.
20131         * m4/strerror.m4: New file.
20132
20133         Module mktime.
20134         * m4/mktime.m4: Renamed from jm-mktime.m4.
20135         (gl_PREREQ_MKTIME): New macro.
20136         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
20137
20138         Module malloc.
20139         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
20140         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
20141         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
20142
20143         Module realloc.
20144         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
20145         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
20146         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
20147
20148         Module strftime.
20149         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
20150         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
20151         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
20152         gl_TM_GMTOFF.
20153         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
20154
20155         Module xalloc.
20156         * m4/xalloc.m4: New file.
20157
20158         Module alloca.
20159         * m4/alloca.m4: New file.
20160
20161         Module putenv.
20162         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
20163         (jm_FUNC_PUTENV): Invoke it.
20164
20165         Module setenv.
20166         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
20167         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
20168         when invoked twice.
20169         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
20170         gt_FUNC_SETENV.
20171
20172         Module memrchr.
20173         * m4/memrchr.m4: New file.
20174
20175         Module stpcpy.
20176         * m4/stpcpy.m4: New file.
20177
20178         Module strcase.
20179         * m4/strcase.m4: New file.
20180
20181         Module strdup.
20182         * m4/strdup.m4: New file.
20183
20184         Module strnlen.
20185         * m4/strnlen.m4: New file.
20186
20187         Module strndup.
20188         * m4/strndup.m4: New file.
20189
20190         Module xstrtod.
20191         * m4/xstrtod.m4: New file.
20192
20193         Module xstrtol.
20194         * m4/xstrtol.m4: New file.
20195
20196         Module getdate.
20197         * m4/getdate.m4: New file.
20198
20199         Module unlocked-io.
20200         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
20201         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
20202         * m4/jm-glibc-io.m4n: Remove file.
20203
20204         Module long-options.
20205         * m4/long-options.m4: New file.
20206
20207         Module md5.
20208         * m4/md5.m4: New file.
20209
20210         Module sha.
20211         * m4/sha.m4: New file.
20212
20213         Module getstr.
20214         * m4/getstr.m4: New file.
20215
20216         Module getline.
20217         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
20218         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
20219         <sys/types.h>, for size_t. Use the function name gnu_getline, not
20220         simply getline. Infoke gl_PREREQ_GETLINE.
20221
20222         Module obstack.
20223         * m4/obstack.m4: New file.
20224
20225         Module hash.
20226         * m4/hash.m4: New file.
20227
20228         Module readtokens.
20229         * m4/readtokens.m4: New file.
20230
20231         Module strverscmp.
20232         * m4/strverscmp.m4: New file.
20233
20234         Module stdbool.
20235         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
20236         OSF/1.
20237
20238         Module strtoll.
20239         * m4/strtoll.m4: New file.
20240
20241         Module strtoull.
20242         * m4/strtoull.m4: New file.
20243
20244         Module strtoimax.
20245         * m4/strtoimax.m4: New file.
20246
20247         Module strtoumax.
20248         * m4/strtoumax.m4: New file.
20249
20250         Module xstrtoimax.
20251         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
20252         jm_AC_PREREQ_XSTRTOIMAX.
20253         Moved the strtol prerequisites to strtol.m4.
20254         Moved the strtoll prerequisites to strtoll.m4.
20255         Moved the strtoimax prerequisites to strtoimax.m4.
20256
20257         Module xstrtoumax.
20258         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
20259         jm_AC_PREREQ_XSTRTOUMAX.
20260         Moved the strtoul prerequisites to strtoul.m4.
20261         Moved the strtoull prerequisites to strtoull.m4.
20262         Moved the strtoumax prerequisites to strtoumax.m4.
20263
20264         Module chown.
20265         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
20266         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
20267
20268         Module dup2.
20269         * m4/dup2.m4: New file.
20270
20271         Module ftruncate.
20272         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
20273         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
20274
20275         Module getgroups.
20276         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
20277         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
20278
20279         Module gettimeofday.
20280         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
20281         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
20282         gl_PREREQ_GETTIMEOFDAY.
20283
20284         Module mkdir.
20285         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
20286         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
20287
20288         Module mkstemp.
20289         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
20290         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
20291         jm_AC_TYPE_UINTMAX_T.
20292         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
20293
20294         Module stat.
20295         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
20296         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
20297
20298         Module lstat.
20299         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
20300         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
20301
20302         Module timespec.
20303         * m4/timespec.m4 (gl_TIMESPEC): New macro.
20304         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
20305         * m4/st_mtim.m4: Indentation.
20306
20307         Module nanosleep.
20308         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
20309         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
20310         gl_PREREQ_NANOSLEEP.
20311
20312         Module regex.
20313         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
20314         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
20315         (gl_REGEX): New macro.
20316
20317         Module rename.
20318         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
20319         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
20320
20321         Module rmdir.
20322         * m4/rmdir.m4: New file.
20323
20324         Module utime.
20325         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
20326         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
20327         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
20328
20329         Module dirname.
20330         * m4/dirname.m4: New file.
20331
20332         Module getopt.
20333         * m4/getopt.m4: New file.
20334
20335         Module unistd-safer.
20336         * m4/unistd-safer.m4: New file.
20337
20338         Module fnmatch.
20339         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
20340         declaration.
20341         (gl_PREREQ_FNMATCH_EXTRA): New macro.
20342         (gl_FUNC_FNMATCH_POSIX): New macro.
20343         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
20344         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
20345         simply fnmatch.
20346
20347         Module exclude.
20348         * m4/exclude.m4: New file.
20349
20350         Module human.
20351         * m4/human.m4: New file.
20352
20353         Module acl.
20354         * m4/acl.m4: Nop.
20355
20356         Module backupfile.
20357         * m4/backupfile.m4: New file.
20358         * m4/d-ino.m4: Indentation.
20359
20360         Module fsusage.
20361         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
20362         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
20363         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
20364
20365         Module dirfd.
20366         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
20367         requirements.
20368
20369         Module euidaccess.
20370         * m4/euidaccess.m4: New file.
20371
20372         Module file-type.
20373         * m4/file-type.m4: New file.
20374
20375         Module fileblocks.
20376         * m4/fileblocks.m4: New file.
20377
20378         Module filemode.
20379         * m4/filemode.m4: New file.
20380
20381         Module isdir.
20382         * m4/isdir.m4: New file.
20383
20384         Module lchown.
20385         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
20386         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
20387
20388         Module makepath.
20389         * m4/makepath.m4: New file.
20390
20391         Module modechange.
20392         * m4/modechange.m4: New file.
20393
20394         Module mountlist.
20395         * m4/mountlist.m4: New file.
20396         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
20397         Indentation.
20398
20399         Module path-concat.
20400         * m4/path-concat.m4: New file.
20401
20402         Module pathmax.
20403         * m4/pathmax.m4: New file.
20404
20405         Module same.
20406         * m4/same.m4: New file.
20407
20408         Module save-cwd.
20409         * m4/save-cwd.m4: New file.
20410
20411         Module savedir.
20412         * m4/savedir.m4: New file.
20413
20414         Module xgetcwd.
20415         * m4/xgetcwd.m4: New file.
20416         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
20417
20418         Module xreadlink.
20419         * m4/xreadlink.m4: New file.
20420
20421         Module safe-read.
20422         * m4/safe-read.m4: New file.
20423
20424         Module safe-write.
20425         * m4/safe-write.m4: New file.
20426
20427         Module closeout.
20428         * m4/closeout.m4: New file.
20429
20430         Module stdio-safer.
20431         * m4/stdio-safer.m4: New file.
20432
20433         Module getpass.
20434         * m4/getpass.m4: New file.
20435
20436         Module getugroups.
20437         * m4/getugroups.m4: New file.
20438
20439         Module group-member.
20440         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
20441         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
20442
20443         Module idcache.
20444         * m4/idcache.m4: New file.
20445
20446         Module userspec.
20447         * m4/userspec.m4: New file.
20448
20449         Module gettime.
20450         * m4/clock_time.m4: New file.
20451         * m4/gettime.m4: New file.
20452
20453         Module settime.
20454         * m4/settime.m4: New file.
20455
20456         Module posixtm.
20457         * m4/posixtm.m4: New file.
20458
20459         Module gethostname.
20460         * m4/gethostname.m4: New file.
20461
20462         Module canon-host.
20463         * m4/canon-host.m4: New file.
20464
20465         Module gettext.
20466         * m4/codeset.m4: New file, from gettext-0.11.5.
20467         * m4/gettext.m4: New file, from gettext-0.11.5.
20468         * m4/glibc21.m4: New file, from gettext-0.11.5.
20469         * m4/iconv.m4: New file, from gettext-0.11.5.
20470         * m4/intdiv0.m4: New file, from gettext-0.11.5.
20471         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
20472         * m4/inttypes.m4: New file, from gettext-0.11.5.
20473         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
20474         * m4/isc-posix.m4: New file, from gettext-0.11.5.
20475         * m4/lcmessage.m4: New file, from gettext-0.11.5.
20476         * m4/lib-ld.m4: New file, from gettext-0.11.5.
20477         * m4/lib-link.m4: New file, from gettext-0.11.5.
20478         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
20479         * m4/progtest.m4: New file, from gettext-0.11.5.
20480         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
20481         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
20482         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
20483
20484         Module localcharset.
20485         * m4/localcharset.m4: New file.
20486
20487         Module hard-locale.
20488         * m4/hard-locale.m4: New file.
20489
20490         Module mbswidth.
20491         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
20492         onceonly macros.
20493         * m4/mbrtowc.m4: Add comment.
20494
20495         Module memcasecmp.
20496         * m4/memcasecmp.m4: New file.
20497
20498         Module memcoll.
20499         * m4/memcoll.m4: New file.
20500
20501         Module unicodeio.
20502         * m4/unicodeio.m4: New file.
20503
20504         Module rpmatch.
20505         * m4/rpmatch.m4: New file.
20506
20507         Module yesno.
20508         * m4/yesno.m4: New file.
20509
20510         Module exitfail.
20511         * m4/exitfail.m4: New file.
20512
20513         Module c-stack.
20514         * m4/c-stack.m4 (gl_C_STACK): New macro.
20515         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
20516
20517         Module error.
20518         * m4/error.m4 (gl_ERROR): New macro.
20519         (jm_PREREQ_ERROR): Use onceonly macros.
20520
20521         Module fatal.
20522         * m4/fatal.m4: New file.
20523
20524         Module getloadavg.
20525         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
20526         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
20527
20528         Module getpagesize.
20529         * m4/getpagesize.m4: New file.
20530
20531         Module getusershell.
20532         * m4/getusershell.m4: New file.
20533
20534         Module physmem.
20535         * m4/physmem.m4: New file.
20536
20537         Module posixver.
20538         * m4/posixver.m4: New file.
20539
20540         Module quotearg.
20541         * m4/quotearg.m4: New file.
20542
20543         Module quote.
20544         * m4/quote.m4: New file.
20545
20546         Module readutmp.
20547         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
20548
20549         Module sig2str.
20550         * m4/sig2str.m4: New file.
20551
20552         Other.
20553         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
20554         ulonglong.m4.
20555         * m4/intmax_t.m4: New file.
20556         * m4/d-type.m4: Indentation.
20557         * m4/jm-macros.m4: Update.
20558         * m4/prereq.m4 (jm_PREREQ): Update.
20559         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
20560         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
20561         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
20562         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
20563         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
20564         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
20565         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
20566         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
20567         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
20568         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
20569         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
20570         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
20571         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
20572         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
20573         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
20574         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
20575         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
20576         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
20577         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
20578
20579 2002-12-24  Bruno Haible  <bruno@clisp.org>
20580
20581         * MODULES.txt: Update according to m4/ changes.
20582
20583         Module gettext.
20584         * config.rpath: New file, from gettext-0.11.5.
20585
20586         * modules/*: New module descriptions.
20587         * gnulib-tool: New file.
20588         * MODULES.html.sh: New file.
20589
20590 2002-12-21  Karl Berry  <karl@gnu.org>
20591
20592         * doc/fdl.texi: update to version 1.2.
20593
20594 2002-12-19  Karl Berry  <karl@gnu.org>
20595
20596         * config/config.guess: update from prep.
20597
20598 2002-12-18  Bruno Haible  <bruno@clisp.org>
20599
20600         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
20601         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
20602
20603 2002-12-17  Bruno Haible  <bruno@clisp.org>
20604
20605         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
20606         stdlib.h, string.h.
20607
20608 2002-12-17  Bruno Haible  <bruno@clisp.org>
20609
20610         * lib/canon-host.c (strdup): Remove unused declaration.
20611
20612         * lib/fsusage.c: Include full_read.h.
20613         (get_fs_usage): Use full_read instead of safe_read.
20614
20615         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
20616
20617 2002-12-12  Karl Berry  <karl@gnu.org>
20618
20619         * config/config.guess: update from prep.
20620
20621 2002-12-11  Bruno Haible  <bruno@clisp.org>
20622
20623         * m4/setenv.m4: New file, from gettext-0.11.5.
20624
20625 2002-12-11  Bruno Haible  <bruno@clisp.org>
20626
20627         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
20628         not unsetenv().
20629         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
20630         modifications:
20631
20632         2002-12-11  Bruno Haible  <bruno@clisp.org>
20633
20634                 * setenv.c (alloca): Fall back to malloc.
20635                 (freea): New macro.
20636                 (setenv): Use freea() to free memory allocated with alloca().
20637
20638         2002-11-13  Bruno Haible  <bruno@clisp.org>
20639
20640                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
20641                 function declarations.
20642                 * unsetenv.c (unsetenv): Likewise.
20643
20644         2002-03-04  Bruno Haible  <bruno@clisp.org>
20645
20646                 Portability to AIX 4.3.3.
20647                 * unsetenv.c: New file, extracted from setenv.c.
20648                 * setenv.c: Move the unsetenv() function to unsetenv.c.
20649
20650         2001-12-20  Bruno Haible  <bruno@clisp.org>
20651
20652                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
20653                 use malloc instead. For SunOS 4.
20654
20655         2001-12-11  Bruno Haible  <bruno@clisp.org>
20656
20657                 * setenv.c: Declare alloca.
20658                 (compar_fn_t): New typedef.
20659                 (KNOWN_VALUE, STORE_VALUE): Use it.
20660
20661         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
20662         setenv.h.
20663
20664 2002-12-10  Paul Eggert  <eggert@twinsun.com>
20665
20666         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
20667         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
20668         Choose values that are less likely to collide with system fnmatch
20669         options.
20670         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
20671         defined (e.g., a pure POSIX system).
20672         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
20673         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
20674
20675 2002-12-06  Paul Eggert  <eggert@twinsun.com>
20676
20677         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
20678         a pain in practice to deal with generated m4 files.  This change
20679         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
20680
20681         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
20682         and jm-glibc-io.m4, as they are no longer a special case.
20683         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
20684         kludge and the auto-generation stuff.  Check only whether the
20685         functions are declared, not whether they exist, since older hosts
20686         that don't declare the functions can't use the optimization anyway.
20687
20688 2002-12-06  Jim Meyering  <jim@meyering.net>
20689
20690         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
20691
20692         Merge in changes from libc's misc/error.c, in preparation
20693         for the merge of gnulib's changes back into libc.
20694
20695         * lib/error.c (_): Define only if not already defined.
20696         Move definition to follow all #include directives.
20697         Include unlocked-io.h only if !_LIBC.
20698         [_LIBC]: Include <libio/libioP.h>.
20699         [USE_IN_LIBIO]: Include <libio/iolibio.h>
20700         (fflush): Tweak definition to use INTUSE.
20701         (putc): Define.
20702
20703 2002-12-05  Paul Eggert  <eggert@twinsun.com>
20704
20705         * lib/alloca.c [defined emacs]: Include "lisp.h".
20706         (xalloc_die) [defined emacs]: New macro.
20707         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
20708         [! defined emacs]: Include <xalloc.h>.
20709         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
20710         (pointer): Typedef to POINTER_TYPE *.
20711         (malloc): Remove decl; we now always use xmalloc.
20712         (alloca): Use old-style definition, since Emacs needs this.
20713         Check for arithmetic overflow when computing combined size.
20714
20715 2002-12-04  Paul Eggert  <eggert@twinsun.com>
20716
20717         Do not generate unlocked-io.h automatically, since it's easier to
20718         maintain it by hand.
20719
20720         * lib/unlocked-io.h: New file, from GNU diffutils,
20721         but with proper copyright notice and attribution.
20722         * lib/gen-uio: Remove.
20723         * lib/Makefile.am: Add copyright notice.
20724         (libfetish_a_SOURCES): Add unlocked-io.h.
20725         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
20726         (DISTCLEANFILES, io_functions): Remove macros.
20727         (EXTRA_DIST): Remove gen_uio.
20728         (unlocked-io.h): Remove rule.
20729
20730 2002-12-04  Jim Meyering  <jim@meyering.net>
20731
20732         Reflect the fact that stat.c and lstat.c are no longer generated.
20733         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
20734         (DISTCLEANFILES): Likewise.
20735         (EXTRA_DIST): Likewise.
20736         (all_local): Don't depend on stat.c or lstat.c.
20737         (stat.c, lstat.c): Remove rules.
20738         (EXTRA_DIST): Remove xstat.in.
20739
20740         * lib/xstat.in: Remove file.  Contents moved into stat.c.
20741         * lib/stat.c: New file.  Contents mostly from xstat.in.
20742         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
20743         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
20744
20745         * lib/safe-read.c: Rework so that it may serve to define safe_write,
20746         too.
20747         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
20748
20749 2002-12-03  Jim Meyering  <jim@meyering.net>
20750
20751         * lib/safe-read.c, safe-write.c: Change variable names and comments,
20752         but not semantics, to minimize the differences between these two files.
20753         (safe_read): Change comment to mention SAFE_READ_ERROR.
20754
20755         * lib/safe-read.c (IS_EINTR): Define.
20756         (safe_read): Use IS_EINTR in place of in-function cpp directives.
20757
20758 2002-12-02  Jim Meyering  <jim@meyering.net>
20759
20760         * lib/safe-read.c (EINTR): Define.
20761         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
20762         (INT_MAX): Provide fallback.
20763         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
20764
20765         * lib/safe-read.h (SAFE_READ_ERROR): Define.
20766
20767 2002-12-02  Bruno Haible  <bruno@clisp.org>
20768
20769         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
20770         Define, taken from safe-read.c.
20771         (INT_MAX): Provide fallback.
20772         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
20773         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
20774
20775         * lib/safe-read.c (EINTR): Remove definition.
20776         (safe_read): Don't use EINTR if it is absent.
20777
20778 2002-12-01  Jim Meyering  <jim@meyering.net>
20779
20780         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
20781         zero.
20782         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
20783
20784 2002-11-27  Paul Eggert  <eggert@twinsun.com>
20785
20786         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
20787         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
20788         with `if (! (value < limit)) abort ();', for readability.
20789
20790 2002-11-26  Karl Berry  <karl@gnu.org>
20791
20792         * lib/strdup.c: copy from libc again, with jim's ok.
20793         * lib/.cppi-disable: re-add strdup.c
20794
20795 2002-11-25  Karl Berry  <karl@gnu.org>
20796
20797         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
20798         instead of "strtol.c".
20799
20800 2002-11-25  Karl Berry  <karl@gnu.org>
20801
20802         * config/install-sh: update from automake for variable quoting, $0 in
20803         error msgs, etc.
20804
20805         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
20806         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
20807         entry.
20808
20809 2002-11-25  Jim Meyering  <jim@meyering.net>
20810
20811         * lib/mktime.c: Sync from libc, now that it has the latest fix.
20812
20813 2002-11-24  Karl Berry  <karl@gnu.org>
20814
20815         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
20816         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
20817
20818 2002-11-24  Jim Meyering  <jim@meyering.net>
20819
20820         Update from coreutils:
20821
20822         * lib/mktime.c: Merge in changes from libc.
20823
20824         Avoid a link-time failure on some Linux systems.
20825         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
20826         (otherwise).
20827         (__mon_yday): Declare with the STATIC attribute.
20828         (__mktime_internal): Likewise.
20829         Based on a report from Greg Schafer.
20830
20831 2002-11-23  Jim Meyering  <jim@meyering.net>
20832
20833         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
20834         Use `unsigned', not `int', as type of index.
20835
20836         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
20837
20838         * lib/fsusage.c: Remove unneeded parentheses around operands of
20839         `defined'.
20840
20841 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20842
20843         * lib/quotearg.h: Allow multiple inclusion by surrounding with
20844         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
20845         so that we can be included first.
20846         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
20847         * lib/quotearg.c: Include quotearg.h immediately after config.h.
20848         No need to include stddef.h or sys/types.h any more.
20849         Surround local include files with "", not "<>".
20850         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
20851         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
20852         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
20853         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
20854         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
20855         (ISPRINT): Remove; no longer needed now that we assume C89.
20856
20857         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
20858         Preserve errno.
20859
20860         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
20861         quotearg_char): Use SIZE_MAX rather than
20862         (size_t) -1 when we are talking about "infinity".
20863
20864         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
20865
20866 2002-11-22  Paul Eggert  <eggert@twinsun.com>
20867
20868         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
20869         hint that one should use `if (! x) abort ();' rather than `assert
20870         (x);', and anyway it's one less thing to worry about configuring.
20871         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
20872         hash_rehash, hash_insert): Use abort rather than assert.
20873
20874 2002-11-22  Bruno Haible  <bruno@clisp.org>
20875
20876         * lib/safe-read.h: Assume C89. Add comments.
20877         (safe_read): Change return type to size_t.
20878         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
20879         byte counts > SSIZE_MAX correctly.
20880         * lib/safe-write.h: New file.
20881         * lib/safe-write.c: New file.
20882         * lib/full-read.h: New file.
20883         * lib/full-read.c: New file.
20884         * lib/full-write.h: Assume C89. Add comments.
20885         * lib/full-write.c: Include safe-write.h.
20886         (full_write): Rewritten to use safe_write.
20887         Suggested by Jim Meyering and Paul Eggert.
20888
20889 2002-11-21  Jim Meyering  <jim@meyering.net>
20890
20891         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
20892
20893         Merge in changes from the coreutils.
20894
20895         2002-09-25  Paul Eggert  <eggert@twinsun.com>
20896         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
20897         <stdint.h>.
20898         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
20899         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
20900         int.  Work more efficiently if X is the same width as uintmax_t.
20901         Do not compare X to -1, to avoid bogus compiler warning.
20902         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
20903         Don't assume that f_frsize and f_bsize are the same type.
20904
20905         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
20906         warning on FreeBSD.
20907
20908         * lib/makepath.c (make_path): Restore umask *before* creating the final
20909         component.
20910         (make_path): Minor reformatting.
20911
20912         * lib/xmalloc.c: Adjust to work with new autoconf macros,
20913         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
20914         HAVE_MALLOC/HAVE_REALLOC.
20915
20916         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
20917         dummy ones.  At least on GNU/Linux systems, `auto' means something
20918         else.
20919         From Michael Stone.
20920
20921 2002-11-21  Bruno Haible  <bruno@clisp.org>
20922
20923         Remove case insensitive option matching.
20924         * lib/argmatch.h (argcasematch): Remove declaration.
20925         (ARGCASEMATCH): Remove macro.
20926         (__xargmatch_internal): Remove case_sensitive argument.
20927         (XARGMATCH): Update.
20928         (XARGCASEMATCH): Remove macro.
20929         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
20930         case_sensitive argument.
20931         (argcasematch): Remove function.
20932         (__xargmatch_internal): Remove case_sensitive argument.
20933         (main): Use XARGMATCH instead of XARGCASEMATCH.
20934
20935         * lib/xmalloc.c: Change compile-time error message. Add comment about
20936         required autoconf version.
20937
20938 2002-11-20  Paul Eggert  <eggert@twinsun.com>
20939
20940         Merge argmatch cleanups from Bison.  Assume C89.
20941
20942         * lib/argmatch.c: Include config.h here, not in argmatch.h.
20943         Include stdlib.h, for EXIT_FAILURE.
20944         Always include <string.h>, since we assume C89.
20945         (EXIT_FAILURE): Remove pre-C89 bug workaround.
20946         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
20947         Include <stddef.h> instead, since it's all we need for size_t.
20948         (PARAMS): Remove.  All uses removed.
20949         (ARRAY_CARDINALITY): Do not bother to #undef.
20950         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
20951         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20952         Remove unnecessary parentheses.
20953         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
20954         Insert necessary parentheses.
20955         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
20956         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
20957
20958 2002-11-19  Bruno Haible  <bruno@clisp.org>
20959
20960         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
20961         * lib/mbswidth.h: Include <stddef.h>, for size_t.
20962
20963         * lib/mbswidth.h (PARAMS): Remove macro.
20964         (mbswidth, mbsnwidth): Use ANSI C function declarations.
20965         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
20966
20967         * lib/gcd.h (PARAMS): Remove macro.
20968         (gcd): Use ANSI C function declarations.
20969         * lib/gcd.c (gcd): Likewise.
20970
20971 2002-11-15  Bruno Haible  <bruno@clisp.org>
20972
20973         * lib/strcspn.c: Include <stddef.h>.
20974         (strcspn): Use ANSI C function declaration. Change return type to
20975         size_t. Use NULL.
20976         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
20977         (strpbrk): Use NULL.
20978         * lib/strpbrk.h (PARAMS): Remove macro.
20979         (strpbrk): Use ANSI C function declaration.
20980         * lib/strstr.c: Don't include <sys/types.h>.
20981         * lib/strstr.h (PARAMS): Remove macro.
20982         (strstr): Use ANSI C function declarations.
20983
20984 2002-11-14  Karl Berry  <karl@gnu.org>
20985
20986         * config/mkinstalldirs: `do' on separate line, instead of
20987         `for var; do'.
20988
20989 2002-11-06  Bruno Haible  <bruno@clisp.org>
20990
20991         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
20992         * lib/gcd.c (gcd): Likewise.
20993
20994 2002-11-05  Bruno Haible  <bruno@clisp.org>
20995
20996         * lib/gcd.h: New file, from gettext-0.11.5.
20997         * lib/gcd.c: New file, from gettext-0.11.5.
20998
20999 2002-11-05  Bruno Haible  <bruno@clisp.org>
21000
21001         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21002         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21003         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21004         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
21005
21006         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
21007         <libintl.h>.
21008         * lib/makepath.c: Include gettext.h instead of <locale.h> and
21009         <libintl.h>.
21010
21011         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
21012         * lib/human.c: Include gettext.h instead of <libintl.h>.
21013         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
21014         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
21015         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
21016         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
21017         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
21018         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
21019         (textdomain): Remove definition.
21020         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
21021
21022         * lib/long-options.c: Remove include of <libintl.h> and definition of
21023         _.
21024         * lib/same.c: Remove include of <libintl.h> and definition of _.
21025
21026 2002-11-04  Owen Taylor  <otaylor@redhat.com>
21027
21028         * lib/config.charset: A few additions for Solaris.
21029
21030 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
21031
21032         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
21033         * lib/localcharset.c (locale_charset): Declare as extern "C".
21034
21035 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
21036
21037         * lib/config.charset: msdos in uk_UA uses CP1125.
21038
21039 2002-11-04  Bruno Haible  <bruno@clisp.org>
21040
21041         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
21042         * lib/strcase.h: New file, from GNU gettext-0.11.5.
21043         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
21044         * lib/strstr.h: New file, from GNU gettext-0.11.5.
21045         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
21046
21047 2002-11-04  Bruno Haible  <bruno@clisp.org>
21048
21049         * lib/localcharset.c (locale_charset): Don't return an empty string.
21050
21051 2002-11-04  Bruno Haible  <bruno@clisp.org>
21052
21053         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
21054         aliases.
21055
21056 2002-11-04  Bruno Haible  <bruno@clisp.org>
21057
21058         * lib/config.charset: Update for newest glibc. Add canonical names
21059         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
21060
21061 2002-11-04  Bruno Haible  <bruno@clisp.org>
21062
21063         * lib/config.charset: Add support for NetBSD.
21064
21065 2002-11-04  Bruno Haible  <bruno@clisp.org>
21066
21067         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
21068
21069 2002-11-01  Bruno Haible  <bruno@clisp.org>
21070
21071         * configure.in: Add AC_CONFIG_AUX_DIR call.
21072         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
21073         test/Makefile.
21074         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
21075
21076 2002-09-28  Karl Berry  <karl@gnu.org>
21077
21078         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
21079         installed automake until the next release, since changes have been
21080         made.
21081
21082 2002-09-25  Karl Berry  <karl@gnu.org>
21083
21084         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
21085         * lib/getopt*: copy from libc/posix.
21086         * lib/gettext.h: copy from gettext.
21087         * lib/.cppi-disable: add strdup.c, gettext.h.
21088
21089 2002-09-25  Karl Berry  <karl@gnu.org>
21090
21091         * config/srclist.txt: enable gettext.h check.
21092         * config/config.{guess,sub}: update from prep.
21093         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
21094                 from automake 1.6.3.
21095         See srclist*.
21096
21097 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
21098
21099         * regex.c (PATFETCH): Remove the translating fetch.
21100         (PATFETCH_RAW): Rename to PATFETCH.
21101         (set_image_of_range): New fun.
21102         (SET_RANGE_TABLE_WORK_AREA): Use it.
21103         (regex_compile): Don't translate the pattern chars so eagerly.
21104         Only do it when inserting an `exactn' bytecode or when handling
21105         a char-range.
21106         (mutually_exclusive_p): Avoid empty statement.
21107
21108 2002-07-06  Jim Meyering  <meyering@lucent.com>
21109
21110         * m4/README: Don't mention Makefile.am.in.
21111         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
21112
21113 2002-07-01  Jim Meyering  <meyering@lucent.com>
21114
21115         * lib/c-stack.c: Include sys/time.h.
21116         From Volker Borchert.
21117
21118 2002-06-26  Paul Eggert  <eggert@twinsun.com>
21119
21120         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
21121
21122 2002-06-26  Paul Eggert  <eggert@twinsun.com>
21123
21124         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
21125         New macro.  Use it uniformly instead of
21126         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
21127         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
21128         reported by Vin Shelton.
21129
21130 2002-06-22  Paul Eggert  <eggert@twinsun.com>
21131
21132         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
21133         Do not assume SA_SIGINFO behavior.
21134         Bug reported by Jim Meyering on NetBSD 1.5.2.
21135
21136 2002-06-22  Jim Meyering  <meyering@lucent.com>
21137
21138         * m4/c-stack.m4: New file, from diffutils-2.8.2.
21139         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
21140
21141         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
21142         now that configure.ac uses AC_GNU_SOURCE.
21143         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
21144         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
21145
21146         Update to latest tools.  Suggestions from Paul Eggert.
21147         * m4/stdbool.m4: New file, from diffutils-2.8.2.
21148         * m4/gnu-source.m4: Update from diffutils-2.8.2.
21149         * m4/fnmatch.m4: Likewise.
21150         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
21151         to AC_HEADER_STDBOOL
21152
21153 2002-06-22  Jim Meyering  <meyering@lucent.com>
21154
21155         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
21156         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
21157
21158 2002-06-22  Jim Meyering  <meyering@lucent.com>
21159
21160         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
21161
21162         * lib/exitfail.c, exitfail.h: Likewise.
21163         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
21164
21165         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
21166         of fnmatch.h.
21167         (EXTRA_DIST): Add fnmatch_loop.c.
21168         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
21169
21170         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
21171         * lib/fnmatch.c: Update from diffutils-2.8.2.
21172         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
21173         * lib/fnmatch.h: Remove file.
21174
21175 2002-06-21  Jim Meyering  <meyering@lucent.com>
21176
21177         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
21178         * m4/mbrtowc.m4: Likewise.
21179
21180         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
21181         * m4/mbswidth.m4: Reflect name change:
21182         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
21183         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
21184
21185         * m4/lib-link.m4: Update from gettext-0.11.2.
21186         * m4/gettext.m4: Likewise.
21187
21188         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
21189         From Alfred M. Szmidt.
21190
21191 2002-06-18  Paul Eggert  <eggert@twinsun.com>
21192
21193         * lib/file-type.h: Report an error if neither S_ISREG nor
21194         S_IFREG is defined, instead of using a test specific to glibc
21195         2.2.  This should be safe, since POSIX requires S_ISREG and
21196         Unix Version 7 had S_IFREG.  We don't need to check for
21197         <sys/types.h> since we don't use any symbols that it defines.
21198
21199 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
21200
21201         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
21202         $@-t, so that each temporary file name is unique and valid in the first
21203         8 characters, for operation under DOS.
21204
21205 2002-06-15  Paul Eggert  <eggert@twinsun.com>
21206
21207         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
21208
21209 2002-06-15  Jim Meyering  <meyering@lucent.com>
21210
21211         Work even with DJGPP 2.03, which lacks support for symlinks.
21212         From Richard Dawe.
21213         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
21214         is defined.
21215         * lib/lchown.c (S_ISLNK): Likewise.
21216
21217 2002-06-15  Jim Meyering  <meyering@lucent.com>
21218
21219         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
21220         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
21221         have been included before this file.
21222
21223 2002-06-14  Jim Meyering  <meyering@lucent.com>
21224
21225         * lib/file-type.h: Use the version from diffutils-2.8.2.
21226         * lib/file-type.c: Likewise.
21227
21228 2002-06-07  Jim Meyering  <meyering@lucent.com>
21229
21230         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
21231         They're needed at least for NetBSD 1.5.2.
21232         ($statxfs_includes): Include those same headers.
21233         ($statxfs_includes): Include sys/vfs.h if available.
21234         ($statxfs_includes): Likewise for sys/statvfs.h.
21235         Check for the following members in both structs statfs and statvfs:
21236         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
21237
21238 2002-06-01  Jim Meyering  <meyering@lucent.com>
21239
21240         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
21241         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
21242
21243 2002-05-28  Jim Meyering  <meyering@lucent.com>
21244
21245         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
21246         Reported by Volker Borchert.
21247
21248 2002-05-27  Jim Meyering  <meyering@lucent.com>
21249
21250         Fix a problem seen only on nonconforming systems whereby ls.c's
21251         use of localtime, and then of gettimeofday would cause trouble:
21252         the localtime call used to initialize rpl_gettimeofday's save
21253         mechanism would clobber ls's current local time information so
21254         that in any long listing the first file would always be listed
21255         with date 1970-01-01.  Analysis by Volker Borchert.
21256
21257         * lib/gettimeofday.c (localtime): Undefine.
21258         (rpl_localtime): New function.
21259
21260 2002-05-27  Jim Meyering  <meyering@lucent.com>
21261
21262         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
21263         localtime.
21264
21265         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
21266         use the replacement function; it wouldn't resolve at link time.
21267         Reported by Volker Borchert.
21268
21269 2002-05-22  Jim Meyering  <meyering@lucent.com>
21270
21271         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
21272         file-type.h.
21273         * lib/file-type.h: New file.
21274         * lib/file-type.c (file_type): New file/function.  Extracted from
21275         diffutils.
21276
21277 2002-04-30  Jim Meyering  <meyering@lucent.com>
21278
21279         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
21280
21281 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21282
21283         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
21284
21285 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21286
21287         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
21288         Do not check for alloca.h (no longer used) or stdbool.h (was never
21289         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
21290
21291 2002-04-29  Paul Eggert  <eggert@twinsun.com>
21292
21293         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
21294
21295 2002-04-29  Jim Meyering  <meyering@lucent.com>
21296
21297         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
21298         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
21299         Use AC_FUNC_STRNLEN here instead.
21300
21301         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
21302         With autoconf-2.53a, it's part of AC_PROG_CC.
21303
21304 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21305
21306         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
21307         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
21308
21309 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21310
21311         * lib/sig2str.h, lib/sig2str.c: New files.
21312         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
21313
21314 2002-04-28  Paul Eggert  <eggert@twinsun.com>
21315
21316         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
21317         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
21318         of 127, since 64 is the largest conceivable number for ancient
21319         nonstandard hosts.
21320         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
21321
21322 2002-04-28  Jim Meyering  <meyering@lucent.com>
21323
21324         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
21325
21326 2002-04-24  Jim Meyering  <meyering@lucent.com>
21327
21328         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
21329         (jm_PREREQ): Use it.
21330
21331         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
21332         mach/mach.h fcntl.h.
21333         Check for this function: setlocale.
21334
21335 2002-04-24  Jim Meyering  <meyering@lucent.com>
21336
21337         * lib/gettext.h: New file, from Gettext.
21338         * lib/Makefile.am (INCLUDES): Remove -I../intl.
21339         (libfetish_a_SOURCES): Add gettext.h.
21340
21341 2002-04-16  Jim Meyering  <meyering@lucent.com>
21342
21343         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
21344         ut_pid, ut_id, ut_exit.
21345
21346 2002-04-16  Jim Meyering  <meyering@lucent.com>
21347
21348         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
21349         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
21350         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
21351
21352 2002-04-12  Jim Meyering  <meyering@lucent.com>
21353
21354         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
21355         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
21356         existence of the getmntinfo function.  Needed for Darwin 5.3.
21357
21358         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
21359         This is necessary at least on Darwin 5.3.
21360
21361         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
21362         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
21363         strnlen.o in the library, and that makes some versions of ranlib
21364         object.
21365
21366 2002-04-12  Jim Meyering  <meyering@lucent.com>
21367
21368         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
21369
21370 2002-04-09  Jim Meyering  <meyering@lucent.com>
21371
21372         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
21373         to be more precise.  Rather than saying we're checking whether the
21374         function `works', say what we're testing.
21375         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
21376         Reported by Bruno Haible.
21377
21378 2002-03-10  Jim Meyering  <meyering@lucent.com>
21379
21380         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
21381         Suggestion from Santiago Vila.
21382
21383 2002-03-08  Jim Meyering  <meyering@lucent.com>
21384
21385         * lib/rename.c: Mention that this wrapper is needed also on
21386         mips-dec-ultrix4.4 systems.
21387
21388 2002-03-02  Jim Meyering  <meyering@lucent.com>
21389
21390         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
21391         not HAVE_CLOCK_SETTIME.
21392
21393 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21394
21395         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
21396         Check for clock_settime.
21397
21398 2002-02-27  Paul Eggert  <eggert@twinsun.com>
21399
21400         * lib/nanosleep.h: Rename to....
21401         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
21402
21403         * lib/gettime.c: New file.
21404         * lib/settime.c: New file.
21405         * lib/stime.c: Remove.
21406
21407         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
21408         timespec.h.  Remove nanosleep.h.
21409
21410 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21411
21412         * m4/acl.m4: New file.
21413         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
21414         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
21415
21416 2002-02-25  Paul Eggert  <eggert@twinsun.com>
21417
21418         * lib/acl.c, lib/acl.h: New files.
21419         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
21420
21421 2002-02-24  Jim Meyering  <meyering@lucent.com>
21422
21423         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
21424         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
21425         cause trouble.  Reported by Nelson Beebe.
21426
21427 2002-02-23  Paul Eggert  <eggert@twinsun.com>
21428
21429         * lib/path-concat.c (xpath_concat): Reorder code to pacify
21430         compilers that don't know that xalloc_die never returns.
21431
21432 2002-02-20  Jim Meyering  <meyering@lucent.com>
21433
21434         * lib/getdate.c: Regenerate using bison-1.33.
21435
21436 2002-02-17  Jim Meyering  <meyering@lucent.com>
21437
21438         * config/config.guess (main): Don't use `head -1'; it's no longer
21439         portable. Use `sed 1q' instead.
21440
21441 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
21442
21443         * m4/codeset.m4: Upgrade to gettext-0.11.
21444         * m4/gettext.m4: Upgrade to gettext-0.11.
21445         * m4/glibc21.m4: Upgrade to gettext-0.11.
21446         * m4/iconv.m4: Upgrade to gettext-0.11.
21447         * m4/isc-posix.m4: Upgrade to gettext-0.11.
21448         * m4/lcmessage.m4: Upgrade to gettext-0.11.
21449         * m4/lib-ld.m4: New file, from gettext-0.11.
21450         * m4/lib-link.m4: New file, from gettext-0.11.
21451         * m4/lib-prefix.m4: New file, from gettext-0.11.
21452         * m4/progtest.m4: Upgrade to gettext-0.11.
21453
21454 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21455
21456         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
21457         (jm_PREREQ): Use it.
21458
21459 2002-02-15  Paul Eggert  <eggert@twinsun.com>
21460
21461         * lib/posixver.c, lib/posixver.h: New files.
21462         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21463
21464 2002-02-02  Paul Eggert  <eggert@twinsun.com>
21465             Bruno Haible  <bruno@clisp.org>
21466
21467         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
21468         (fwrite_success_callback): New declaration.
21469         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
21470         print_unicode_char. Call failure callback instead of error.
21471         (fwrite_success_callback): New function.
21472         (exit_failure_callback): New function.
21473         (fallback_failure_callback): New function.
21474         (print_unicode_char): Call unicode_to_mb.
21475
21476 2002-01-26  Jim Meyering  <meyering@lucent.com>
21477
21478         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
21479         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
21480
21481 2002-01-26  Jim Meyering  <meyering@lucent.com>
21482
21483         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
21484
21485 2002-01-22  Paul Eggert  <eggert@twinsun.com>
21486
21487         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
21488
21489 2002-01-22  Jim Meyering  <meyering@lucent.com>
21490
21491         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
21492         Otherwise, some versions of automake would omit the rule that makes
21493         Makefile from Makefile.in.
21494
21495 2002-01-21  Paul Eggert  <eggert@twinsun.com>
21496
21497         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
21498         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
21499         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
21500         (memcoll): Set errno to zero if there is no error.
21501
21502         * lib/quotearg.c (quotearg_buffer_restyled):
21503         Fix bug with quoting buffers containing NUL when backslashing escapes.
21504         This bug was exposed by the other changes in this patch.
21505         (quotearg_n_options): New arg ARGSIZE.
21506         All callers changed.
21507         (quoting_options_from_style): New function.
21508         (quotearg_n_style): Use it.
21509         (quotearg_n_style_mem): New function.
21510
21511         * lib/quotearg.h (quotearg_n_style_mem): New function.
21512
21513 2002-01-19  Jim Meyering  <meyering@lucent.com>
21514
21515         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
21516         Remove useless quotes: DF_PROG="df".
21517         * m4/strnlen.m4: New file.
21518
21519 2002-01-16  Paul Eggert  <eggert@twinsun.com>
21520
21521         * lib/backupfile.c (ISDIGIT): Comment fix.
21522         * lib/getdate.y (ISDIGIT): Likewise.
21523         * lib/posixtm.c (ISDIGIT, year): Likewise.
21524         * lib/strverscmp.c (ISDIGIT): Likewise.
21525         * lib/userspec.c (ISDIGIT): Likewise.
21526
21527 2002-01-16  Jim Meyering  <meyering@lucent.com>
21528
21529         * lib/getdate.y: Add three semicolons, each just before a closing
21530         brace. Bison (as of version 1.31) no longer papers over that mistake.
21531
21532 2002-01-05  Jim Meyering  <meyering@lucent.com>
21533
21534         * lib/version-etc.c (version_etc_copyright): Update copyright year.
21535
21536 2001-12-19  Paul Eggert  <eggert@twinsun.com>
21537
21538         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
21539         not silently exit merely because the output buffer happens to
21540         have nothing pending.
21541
21542 2001-12-18  Paul Eggert  <eggert@twinsun.com>
21543
21544         See the big note in ../ChangeLog.
21545         * lib/human.c (suffixes): Prefer K to k for 1024.
21546         (generate_suffix_backwards): New function.
21547         (human_readable_inexact): Use it.
21548         * lib/xstrtol.c (__xstrtol): If there is no number but there
21549         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
21550         Accept 'K' as well as 'k'.
21551
21552 2001-12-15  Jim Meyering  <meyering@lucent.com>
21553
21554         * lib/regex.h (__restrict_arr): Update from libc.
21555
21556         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
21557         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
21558         (STREQ): Define.
21559
21560 2001-12-14  Jim Meyering  <meyering@lucent.com>
21561
21562         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
21563         Suggestion from Bruno Haible.
21564
21565 2001-12-10  Jim Meyering  <meyering@lucent.com>
21566
21567         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
21568         xrealloc, Instead, include "xalloc.h".
21569         (initbuffer): Don't cast xmalloc return value to char*.
21570         (readline): Reword comment.
21571         Don't cast xrealloc return value to char*
21572         Return NULL, not 0.
21573
21574 2001-12-09  Jim Meyering  <meyering@lucent.com>
21575
21576         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
21577         about `signed and unsigned type in conditional expression'.
21578         * lib/posixtm.c (posix_time_parse): Likewise.
21579
21580         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
21581
21582         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
21583         to avoid a pedantic warning.
21584
21585         * lib/getstr.c: Don't include assert.h.
21586         (getstr): Remove warning-evoking assertions.
21587         Return -1 if offset parameter is out of bounds.
21588         Change the type of a local from int to size_t.
21589
21590         * lib/strftime.c (my_strftime_localtime_r): Include this function
21591         definition in the `#if ! HAVE_TM_GMTOFF' block.
21592
21593         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
21594         Include xalloc.h instead.
21595
21596 2001-12-02  Jim Meyering  <meyering@lucent.com>
21597
21598         * lib/tempname.c: Don't declare getenv, thus reverting the change of
21599         2001-11-18.  It's no longer necessary, now that stdlib.h is always
21600         included.
21601
21602         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
21603         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
21604
21605 2001-11-30  Akim Demaille  <akim@epita.fr>
21606
21607         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
21608         before being defined.
21609
21610 2001-11-27  Paul Eggert  <eggert@twinsun.com>
21611
21612         * lib/quotearg.h (quotearg_n, quotearg_n_style):
21613         First arg is int, not unsigned.
21614         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
21615         (SIZE_MAX, UINT_MAX): New macros.
21616         (quotearg_n_options): Abort if N is negative.
21617         Avoid overflow check on hosts where size_t is 64 bits and int
21618         is 32 bits, as overflow is impossible there.
21619         Fix off-by-one typo that caused unnecessary reallocation.
21620
21621 2001-11-27  Jim Meyering  <meyering@lucent.com>
21622
21623         * lib/tempname.c: Merge with version from libc.
21624         * lib/regex.c: Likewise.
21625
21626         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
21627         systems for which STDC_HEADERS is 0, it was not included, resulting in
21628         a warning about an integer-to-pointer conversion problem with getenv.
21629         Reported by Volker Borchert.
21630
21631 2001-11-26  Jim Meyering  <meyering@lucent.com>
21632
21633         * lib/gtod.h: Remove file.
21634         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
21635         * lib/gettimeofday.c: Don't include gtod.h.
21636         (GTOD_init): Remove function.
21637         (rpl_gettimeofday): Do its job here instead, rather than aborting.
21638         Suggestion from Volker Borchert.
21639
21640 2001-11-23  Jim Meyering  <meyering@lucent.com>
21641
21642         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
21643         it.
21644         * lib/hash.c (struct hash_table): Define it here instead.
21645
21646 2001-11-22  Jim Meyering  <meyering@lucent.com>
21647
21648         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
21649
21650 2001-11-20  Jim Meyering  <meyering@lucent.com>
21651
21652         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
21653         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
21654
21655 2001-11-19  Jim Meyering  <meyering@lucent.com>
21656
21657         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
21658         directory.  Use "conftestXXXXXX" as the template.
21659         Suggestion from Paul Eggert.
21660
21661         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
21662         immediately, so the test doesn't mistakenly hit the max-open-files
21663         limit.
21664
21665 2001-11-18  Paul Eggert  <eggert@twinsun.com>
21666
21667         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
21668         (TEMPORARIES): New macro.
21669         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
21670         removes an artificial limitation (e.g. HP-UX 10.20, where
21671         TMP_MAX is 17576).
21672
21673 2001-11-18  Jim Meyering  <meyering@lucent.com>
21674
21675         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
21676
21677 2001-11-18  Jim Meyering  <meyering@lucent.com>
21678
21679         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
21680         on SunOS 4.
21681
21682         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
21683         files will be created before anything else.
21684
21685 2001-11-17  Paul Eggert  <eggert@twinsun.com>
21686
21687         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
21688         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
21689
21690 2001-11-17  Jim Meyering  <meyering@lucent.com>
21691
21692         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
21693         Prompted by a report from Bob Proulx.
21694
21695         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
21696         Instead, require UTILS_FUNC_MKSTEMP.
21697
21698 2001-11-17  Jim Meyering  <meyering@lucent.com>
21699
21700         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
21701         Now, that's done as part of AC_FUNC_STRTOD.
21702
21703 2001-11-17  Jim Meyering  <meyering@lucent.com>
21704
21705         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
21706         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
21707         rather than group writable.  Patch by Juan F. Codagnone.
21708
21709         * lib/readtokens.c: Remove explicit declarations of xmalloc and
21710         xrealloc, Instead, include "xalloc.h".
21711
21712         * lib/mountlist.c: Include unlocked-io.h after all system headers.
21713         Remove explicit declarations of xmalloc, xrealloc,
21714         and xstrdup.  Instead, include "xalloc.h".
21715
21716         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
21717         unlocked-io.h.
21718         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
21719         Likewise.
21720         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
21721
21722         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
21723         Reported by Padraig Brady.
21724
21725         * lib/mkstemp.c: #undef mkstemp.
21726         Include config.h.
21727         (rpl_mkstemp): Rename from mkstemp.
21728         Protoize.
21729
21730 2001-11-16  Jim Meyering  <meyering@lucent.com>
21731
21732         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
21733         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
21734         determine the amount of total physical memory, use pstat_getstatic.
21735         HPUX-11 doesn't define _SC_PHYS_PAGES.
21736         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
21737         If sysconf couldn't be used to determine the amount of available
21738         physical memory, use both pstat_getstatic and pstat_getdynamic.
21739         Based on a patch from Bob Proulx.
21740
21741 2001-11-10  Jim Meyering  <meyering@lucent.com>
21742
21743         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
21744         (jm_PREREQ): Use it.
21745
21746 2001-11-09  Jim Meyering  <meyering@lucent.com>
21747
21748         * m4/jm-macros.m4: Require autoconf-2.52f.
21749         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
21750         Use these AC_-prefixed names, not the AM_-prefixed ones.
21751
21752         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
21753
21754 2001-11-05  Jim Meyering  <meyering@lucent.com>
21755
21756         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
21757
21758 2001-11-04  Jim Meyering  <meyering@lucent.com>
21759
21760         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
21761         $DEFS.
21762
21763 2001-11-03  Jim Meyering  <meyering@lucent.com>
21764
21765         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
21766         of AC_DEFUN.
21767
21768         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
21769         know the name of the variable in the macro definition.
21770
21771 2001-11-03  Jim Meyering  <meyering@lucent.com>
21772
21773         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
21774         in argmatch_to_argument call.
21775
21776         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
21777         argument.
21778
21779         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
21780         e.g., a fault due to an attempt to free a NULL pointer.
21781
21782 2001-11-01  Jim Meyering  <meyering@lucent.com>
21783
21784         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
21785         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
21786
21787 2001-11-01  Jim Meyering  <meyering@lucent.com>
21788
21789         * lib/dirfd.c, lib/dirfd.h: New files.
21790         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
21791
21792         * lib/hash.c (hash_print) [TESTING]: Clean up.
21793
21794 2001-10-22  Paul Eggert  <eggert@twinsun.com>
21795
21796         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
21797         to avoid a warning if -Wall.
21798
21799 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
21800
21801         * README: New file
21802         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
21803         (per RMS's instructions, this is now the canonical source)
21804         * lgpl/, gpl/: New directories.
21805
21806 2001-10-21  Paul Eggert  <eggert@twinsun.com>
21807
21808         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
21809
21810 2001-10-21  Jim Meyering  <meyering@lucent.com>
21811
21812         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
21813         this code would end up calling gettext even in packages built
21814         with --disable-nls.
21815         * lib/getopt.c (_): Likewise.
21816         * lib/regex.c (_): Likewise.
21817
21818 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21819
21820         * m4/error.m4 (jm_PREREQ_ERROR):
21821         Do not invoke AC_CHECK_FUNCS with strerror_r, as
21822         AC_FUNC_STRERROR_R does that.
21823         Check for strerror declaration.
21824
21825         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
21826         are supposed to have them these days.
21827         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
21828         Merge changes from latest Autoconf CVS.
21829         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
21830         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
21831         POSIX decided to standardize on the int flavor of strerror_r.
21832
21833 2001-10-20  Paul Eggert  <eggert@twinsun.com>
21834
21835         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
21836         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
21837         Use strerror_r that is only a macro, even if it is not a function.
21838         (strerror): Check for HAVE_DECL_STRERROR before declaring.
21839         (private_strerror): Use prototypes, not old-style function definition.
21840         (print_errno_message): New function.
21841         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
21842         char*-flavored one.
21843         (error_tail, error, error_at_line): Use it.
21844
21845 2001-10-11  Jim Meyering  <meyering@lucent.com>
21846
21847         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
21848         and quote_n (1, ... to avoid clobbering a buffer.
21849
21850 2001-10-05  Jim Meyering  <meyering@lucent.com>
21851
21852         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
21853         hash-pjw.h.
21854         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
21855         * lib/hash-pjw.h: New file.
21856
21857 2001-09-30  Jim Meyering  <meyering@lucent.com>
21858
21859         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
21860         `struct fsstat' has the `f_fstypename' member.
21861         Use that to define FS_TYPE, which is now used to make
21862         the getfsstat link test tighter.
21863
21864 2001-09-30  Jim Meyering  <meyering@lucent.com>
21865
21866         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
21867         Include <sys/ucred.h>, for Apple Darwin.
21868         Include sys/mount.h and sys/fs_types.h only if available.
21869         (FS_TYPE): Define.
21870         (read_filesystem_list): Use FS_TYPE.
21871
21872 2001-09-29  Paul Eggert  <eggert@twinsun.com>
21873
21874         * lib/exclude.c (excluded_filename): 0 -> false, since it's
21875         a boolean context.
21876
21877 2001-09-29  Jim Meyering  <meyering@lucent.com>
21878
21879         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21880         [one-argument getmntent function]): Include stdio.h before mntent.h.
21881         SunOS 4.1.x needs it for the declaration of `FILE'.
21882         Patch by Volker Borchert.
21883
21884         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
21885         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
21886         sys/fs_types.h, and make the link-test for getfsstat guard #include
21887         directives with appropriate #if HAVE_*_H tests so that we can
21888         detect getfsstat on Apple Darwin1.3.7 systems.
21889         Reported by Nelson Beebe.
21890         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
21891
21892 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21893
21894         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21895         #defines strtoimax.  Also treat the other strto* functions
21896         like strtoimax.
21897
21898         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
21899         Check for strtoul and strtoumax,
21900         as those declarations are made even in the signed case.
21901         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
21902         Likewise, for strtol and strtoimax.
21903
21904 2001-09-28  Paul Eggert  <eggert@twinsun.com>
21905
21906         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
21907         #defines strtoimax.  Also treat the other strto* functions
21908         like strtoimax.
21909
21910         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
21911         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
21912         (strtoimax, strtoumax): Do not declare if already defined as a macro.
21913
21914 2001-09-26  Jim Meyering  <meyering@lucent.com>
21915
21916         Most macros in unlocked-io.h had the wrong number of arguments.
21917         * lib/gen-uio: New script.
21918         (USE_UNLOCKED_IO): Define to 1 if not already defined.
21919         * lib/unlocked-io.hin: Remove file.
21920         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
21921         rather than trying to embed it here.
21922         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
21923         Reported by Padraig Brady.
21924
21925 2001-09-25  Volker Borchert  <bt@teknon.de>
21926
21927         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
21928         `result'.
21929
21930 2001-09-24  Jim Meyering  <meyering@lucent.com>
21931
21932         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
21933
21934 2001-09-23  Jim Meyering  <meyering@lucent.com>
21935
21936         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
21937         instead of the mere test for existence of mntent.h.  The latter
21938         would get a false-positive on AIX 3.4 systems.
21939         In the outer getmntent if-block, don't die if neither of the getmntent
21940         tests succeeds.  Instead, just fall through and continue with the
21941         remaining tests.
21942
21943 2001-09-23  Jim Meyering  <meyering@lucent.com>
21944
21945         * lib/mountlist.c: Remove useless parentheses in #if directives.
21946         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
21947         the deprecated MOUNTED symbol is no longer defined in mntent.h.
21948
21949 2001-09-22  Jim Meyering  <meyering@lucent.com>
21950
21951         * m4/gettext.m4: New file.  From gettext.
21952         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
21953         * m4/progtest.m4: Likewise
21954         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
21955         * m4/glibc21.m4: Likewise.
21956
21957         * m4/libintl.m4: Remove.  No longer used.
21958
21959 2001-09-22  Jim Meyering  <meyering@lucent.com>
21960
21961         * lib/localcharset.c: Update from latest gettext.
21962         * lib/config.charset: Likewise.
21963
21964 2001-09-20  Jim Meyering  <meyering@lucent.com>
21965
21966         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
21967         strtoimax.
21968         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
21969         strtoumax.
21970
21971 2001-09-20  Jim Meyering  <meyering@lucent.com>
21972
21973         * lib/xstrtol.c (strtoimax): Guard declaration with
21974         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
21975         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
21976         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
21977         (strtoumax): Likewise, for completeness (it wasn't necessary).
21978
21979 2001-09-17  Paul Eggert  <eggert@twinsun.com>
21980
21981         * lib/strtoimax.c (HAVE_LONG_LONG):
21982         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
21983         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
21984         to work around bug in IBM C compiler.
21985
21986 2001-09-17  Jim Meyering  <meyering@lucent.com>
21987
21988         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
21989         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
21990         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
21991         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
21992         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
21993         whenever the right hand side need not be expanded by the shell.
21994
21995 2001-09-16  Paul Eggert  <eggert@twinsun.com>
21996
21997         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
21998         library.  It's not correct, as some older glibcs are buggy.
21999         fnmatch wasn't fixed until glibc 2.2.
22000
22001         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
22002         special shell magic here.
22003
22004 2001-09-16  Jim Meyering  <meyering@lucent.com>
22005
22006         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
22007         * m4/jm-macros.m4: Require it.
22008
22009 2001-09-16  Jim Meyering  <meyering@lucent.com>
22010
22011         * lib/mkdir.c: New file.
22012
22013 2001-09-15  Jim Meyering  <meyering@lucent.com>
22014
22015         * m4/jm-macros.m4: Check for help2man.
22016
22017 2001-09-11  Jim Meyering  <meyering@lucent.com>
22018
22019         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
22020         The body, by Paul Eggert, was moved here from configure.in.
22021         * m4/jm-macros.m4: Require UTILS_HOST_OS.
22022
22023 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22024
22025         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
22026         (jm_PREREQ): Use it.
22027
22028 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22029
22030         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
22031         Use ssize_t, not int, to store result of readlink.
22032         Check for ssize_t overflow as well as size_t overflow,
22033         as POSIX says the result of readlink is implementation-defined
22034         when ssize_t overflows.
22035         Remove unnecessary cast to char*.
22036         Use free+malloc instead of realloc, as the storage doesn't need
22037         to be preserved and it's clearer and can be more efficient that way.
22038         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
22039         * lib/xreadlink.h (xreadlink): Update prototype.
22040
22041 2001-09-04  Paul Eggert  <eggert@twinsun.com>
22042
22043         * lib/xgetcwd.c: Revert some of the previous change; intead,
22044         fix the HAVE_GETCWD_NULL code to behave more like the
22045         !HAVE_GETCWD_NULL code used to.
22046
22047         Include "xalloc.h".
22048         (xgetcwd): Do not return NULL when memory is exhausted; instead,
22049         invoke xalloc_die.
22050
22051 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22052
22053         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
22054         sys/param.h, as pathmax.h includes them.
22055
22056 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22057
22058         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
22059         (jm_PREREQ_XGETCWD): New macro.
22060
22061         * m4/getcwd.m4: New file.
22062
22063 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22064
22065         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
22066         like the HAVE_GETCWD_NULL code.
22067         Include pathmax.h if not HAVE_GETCWD.
22068         Do not include xalloc.h.
22069         (INITIAL_BUFFER_SIZE): New symbol.
22070         Do not use xmalloc / xrealloc, since the caller is responsible for
22071         handling errors.  Preserve errno around `free' during failure.
22072         Do not overrun buffer when using getwd.
22073
22074 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22075
22076         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
22077         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
22078         getcwd (NULL, 0).
22079
22080 2001-09-03  Paul Eggert  <eggert@twinsun.com>
22081
22082         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
22083         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
22084         spotted by Jim Meyering.
22085
22086 2001-09-03  Jim Meyering  <meyering@lucent.com>
22087
22088         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
22089         failure.
22090
22091 2001-09-02  Jim Meyering  <meyering@lucent.com>
22092
22093         * lib/error.c: Update from GNU libc.
22094
22095 2001-09-01  Jim Meyering  <meyering@lucent.com>
22096
22097         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
22098         Used by df.
22099
22100 2001-09-01  Jim Meyering  <meyering@lucent.com>
22101
22102         * lib/xreadlink.c: New file.
22103         * lib/xreadlink.h: New file.
22104         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
22105         xreadlink.h.
22106
22107         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
22108         doesn't conflict with sparc Solaris 7's definition in
22109         /usr/include/sys/int_types.h.
22110
22111         * lib/exclude.c: Use `""', not `<>' to #include non-system header
22112         files.
22113         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
22114         and strncasecmp as r-values.  Unixware didn't have declarations.
22115
22116 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22117
22118         * lib/xstrtol.h: Add copyright notice.
22119         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
22120         LONGINT_INVALID_SUFFIX_CHAR.
22121
22122 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22123
22124         * lib/xstrtol.c (strtoimax): New decl.
22125
22126 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22127
22128         * lib/xgetcwd.c: Don't include pathmax.h.
22129         Include stdlib.h and unistd.h if available.
22130         Include xalloc.h.
22131         (xmalloc, xstrdup, free): Remove decls.
22132         (xgetcwd): Don't assume sizes fit in unsigned.
22133         Check for overflow when computing sizes.
22134         Simplify reallocation code.
22135
22136 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22137
22138         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
22139         a directory's st_size can have an arbitrary value, so the old
22140         usage could waste an arbitrary amount of memory.  All uses
22141         changed.
22142         * lib/savedir.h: Update prototype.
22143
22144 2001-08-31  Paul Eggert  <eggert@twinsun.com>
22145
22146         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
22147
22148         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
22149         old strtoimax.c.
22150
22151         Also, make the following further changes to make this file's
22152         configuration more similar to that of strtol.c:
22153         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
22154         (strtoumax, uintmax_t, strtoull, strtol): Remove.
22155         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
22156         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
22157         changed to signed values.
22158
22159         And make the following changes as well:
22160         Fix copyright notice, as 1999 was missing.
22161         (verify): New macro.
22162         (strtoimax): Check sizes at compile-time, not run-time.
22163         Prefer strtol to strtoll if both work.
22164         (main): Remove; it was not that useful and was a pain to maintain.
22165
22166         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
22167
22168 2001-08-31  Jim Meyering  <meyering@lucent.com>
22169
22170         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
22171         Use an initial, malloc'd, buffer of length 128 rather than
22172         a statically allocated one of length 1024.
22173
22174 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22175
22176         Simplify code, partly by assuming autoconf 2.52 semantics.
22177
22178         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
22179
22180         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
22181         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
22182         All uses removed.
22183         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
22184         Move AC_REQUIRE to next-to-top level, to avoid confusion.
22185         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
22186         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
22187         jm_AC_HEADER_INTTYPES_H.
22188         * m4/jm-macros.m4 (jm_MACROS): Likewise.
22189
22190         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
22191
22192         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
22193         Quote first arg of AC_DEFUN.
22194         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
22195         since they are needed to parse the include file even if we need
22196         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
22197         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
22198         but with opposite signedness.
22199
22200 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22201
22202         Merge 'exclude' changes from tar 1.13.22.
22203         This fixes one or two unlikely storage allocation overflow bugs,
22204         but doesn't change user-visible behavior otherwise.
22205
22206 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22207
22208         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
22209         (jm_PREREQ_EXCLUDE): New macro.
22210
22211 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22212
22213         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
22214         tm to be declared.
22215
22216 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22217
22218         * lib/hash.c: Remove '2001' from copyright notice.
22219
22220 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22221
22222         * lib/full-write.h: New file.
22223         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
22224         * lib/full-write.c: Correct credits, as cccp.c no longer
22225         exists and anyway it was so heavily changed from the old cccp
22226         code as to be unrecognizable.  Include full-write.h.
22227         (full_write) Return size_t, with short writes meaning failure.
22228         All callers changed.  This fixes a bug with large buffers
22229         on 64-bit hosts.
22230         * lib/utime.c: Include full-write.h.
22231
22232 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22233
22234         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
22235         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
22236         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
22237         Include if available.
22238         (<xalloc.h>): Include
22239         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
22240         (verify): New macro.  Use it to verify that EXCLUDE macros do not
22241         collide with FNM macros.
22242         (struct patopts): New struct.
22243         (struct exclude): Use it, as exclude patterns now come with options.
22244         (new_exclude): Support above changes.
22245         (new_exclude, add_exclude_file):
22246         Initial size must now be a power of two to simplify overflow checking.
22247         (free_exclude, fnmatch_no_wildcards): New function.
22248         (excluded_filename): No longer requires options arg, as the options
22249         are determined by add_exclude.  Now returns bool, not int.
22250         (excluded_filename, add_exclude):
22251         Add support for the fancy new exclusion options.
22252         (add_exclude, add_exclude_file): Now takes int options arg.
22253         Check for arithmetic overflow when computing sizes.
22254         (add_exclude_file): xrealloc might modify errno, so don't
22255         realloc until after errno might be used.
22256
22257         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
22258         New macros.
22259         (free_exclude): New decl.
22260         (add_exclude, add_exclude_file): Now takes int options arg.
22261         (excluded_filename): No longer requires options arg, as the options
22262         are determined by add_exclude.  Now returns bool, not int.
22263
22264 2001-08-30  Paul Eggert  <eggert@twinsun.com>
22265
22266         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
22267
22268 2001-08-27  Jim Meyering  <meyering@lucent.com>
22269
22270         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
22271
22272         * lib/version-etc.c (N_): Remove definition.
22273         Revert most of last change.
22274         Instead, simply don't mark the `Copyright...' string for translation.
22275         Based on advice from Paul Eggert.
22276
22277         * lib/strtoxmax.c: Tweak comment.
22278
22279 2001-08-26  Jim Meyering  <meyering@lucent.com>
22280
22281         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
22282
22283         * m4/xstrtoimax.m4: New file.
22284         * m4/xstrtoumax.m4: Add comments explaining why we
22285         AC_REPLACE_FUNCS(strtol).
22286
22287 2001-08-26  Jim Meyering  <meyering@lucent.com>
22288
22289         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
22290         of copyright with `%s' so translators don't get an untranslated
22291         message in 2002.
22292         (COPYRIGHT_YEAR): Define.
22293         (version_etc): Use fprintf rather than fputs.
22294         Suggestion from Ulrich Drepper.
22295
22296         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
22297
22298         * lib/strtoll.c: New file, from GNU libc.
22299         * lib/xstrtoimax.c: New file.
22300
22301         * lib/xstrtol.h: Add xstrtoimax.
22302         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
22303         * lib/strtoimax.c: New file.  Likewise, but first define
22304         STRTOUXMAX_SIGNED.
22305
22306         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
22307         ...
22308         * lib/strtoxmax.c: ... then renamed to this.
22309
22310 2001-08-18  Paul Eggert  <eggert@twinsun.com>
22311
22312         * m4/inttypes.m4: Add AC_PREREQ(2.13).
22313         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
22314         (jm_AC_TYPE_INTMAX_T): New macro.
22315         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
22316
22317         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
22318
22319         * m4/longlong.m4: Renamed from ulonglong.m4.
22320         * m4/inttypes.m4: Renamed from inttypes_h.m4.
22321         * m4/uintmax_t.m4: Removed.
22322
22323 2001-08-13  Paul Eggert  <eggert@twinsun.com>
22324
22325         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
22326         Port to Solaris 8, where 'sed' requires a space after the 'r'
22327         command, and where sh dislikes "$/".  Clean up the spacing a bit.
22328         Redirect output to $tmp just once.
22329
22330 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
22331
22332         * lib/addext.c (<errno.h>): Include.
22333         (errno): Declare if not defined.
22334         (addext): Work correctly when pathconf returns -1 and leaves
22335         errno alone because there is no limit.  Also, work even if
22336         pathconf returns a value greater than SIZE_MAX.
22337
22338 2001-08-12  Jim Meyering  <meyering@lucent.com>
22339
22340         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
22341         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
22342         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
22343         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
22344         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
22345         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
22346         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
22347         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
22348         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
22349         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
22350         utime.m4, utimes.m4, xstrtoumax.m4:
22351         Quote the first argument in each use of AC_DEFUN.
22352
22353 2001-08-12  Jim Meyering  <meyering@lucent.com>
22354
22355         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
22356         Simply `return getcwd (NULL, 0);'.
22357         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
22358         Use 1300 as initial value for length, not PATH_MAX.
22359
22360         * lib/pathmax.h: Clean up cpp syntax.
22361
22362 2001-08-12  Jim Meyering  <meyering@lucent.com>
22363
22364         * lib/gettimeofday.c: New file.
22365         * lib/gtod.h: New file.
22366         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
22367
22368 2001-08-05  Jim Meyering  <meyering@lucent.com>
22369
22370         * m4/jm-macros.m4: Require autoconf-2.52.
22371
22372 2001-08-04  Jim Meyering  <meyering@lucent.com>
22373
22374         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
22375         stmt, to get in sync with glibc.
22376
22377 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22378
22379         The following changes are from gettext 0.10.39 as maintained by
22380         Bruno Haible.
22381
22382         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
22383         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
22384         with inverted sense.  All uses changed.
22385
22386         * lib/mbswidth.c: Don't include <limits.h>.
22387         Include <stdlib.h> and <string.h> unconditionally.
22388         (iswcntrl, mbsinit, ISCNTRL): New macros.
22389         (mbsnwidth): Use K&R style function declarations.
22390         Don't bother checking for MB_LEN_MAX == 1, since the compiler
22391         can optimize it when MB_CUR_MAX == 1.
22392         The width of control characters is zero, not 1.
22393
22394 2001-08-03  Paul Eggert  <eggert@twinsun.com>
22395
22396         The following changes are from gettext 0.10.39 as maintained by
22397         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
22398
22399         * m4/codeset.m4: Upgrade to serial AM1.
22400         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
22401         all uses changed.  Quote first arg of AC_DEFUN.
22402         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
22403
22404         * m4/iconv.m4: Upgrade to serial AM2.
22405         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
22406         Add --with-libconv-prefix.
22407         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
22408         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
22409         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
22410         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
22411         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
22412
22413         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
22414         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
22415         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
22416         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
22417         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
22418         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
22419         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
22420         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
22421         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
22422
22423         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
22424         string.h any more.
22425
22426         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
22427         not the default value.
22428
22429         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
22430         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
22431         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
22432         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
22433         Also check for iswcntrl, used for wcwidth fallback.
22434         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
22435         to Autoconf 2.13.
22436
22437 2001-08-03  Jim Meyering  <meyering@lucent.com>
22438
22439         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
22440         as it was in the original.  Reported by Paul Eggert.
22441
22442 2001-07-16  Jim Meyering  <meyering@lucent.com>
22443
22444         * m4/gettimeofday.m4: New file.
22445         Prompted by a report from Bernhard Baehr.
22446
22447 2001-07-15  Jim Meyering  <meyering@lucent.com>
22448
22449         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
22450         stuff. Now it's in ../Makefile.cfg.
22451
22452 2001-07-15  Jim Meyering  <meyering@lucent.com>
22453
22454         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
22455         (BUILT_SOURCES): Add unlocked-io.h.
22456         (io_functions): Define.
22457         (unlocked-io.h): New rule.
22458         (DISTCLEANFILES): Add unlocked-io.h.
22459         (all-local): Depend on unlocked-io.h, to ensure it is created.
22460
22461         * lib/unlocked-io.hin: New file
22462
22463         * lib/regex.c: Update from glibc.
22464
22465 2001-07-05  Jim Meyering  <meyering@lucent.com>
22466
22467         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
22468         recommendation.
22469         (libfetish_a_SOURCES): Put all .h files here instead.
22470         Remove a thus-exposed (better checks in automake) duplicate and
22471         two unnecessary .h files.
22472
22473 2001-07-04  Jim Meyering  <meyering@lucent.com>
22474
22475         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
22476         that generates jm-glibc-io.m4 so that it doesn't trigger any make
22477         distcheck failure.
22478
22479 2001-07-02  Jim Meyering  <meyering@lucent.com>
22480
22481         The following changes were prompted by suggestions from Bruno Haible.
22482
22483         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
22484         is now generated.
22485         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
22486         definition of EXTRA_DIST.
22487         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
22488         ensure that the generated file is created/updated whenever the list
22489         of $(unlocked_functions) is changed.
22490         (jm-glibc-io.m4): New rule.
22491         (unlocked-io.h): New rule -- currently unused.
22492
22493 2001-06-24  Jim Meyering  <meyering@lucent.com>
22494
22495         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
22496         unmatched right bracket, rather than kludging it with an extra,
22497         falsely-matching quote in a comment.  Patch by Akim Demaille.
22498
22499 2001-06-11  Jim Meyering  <meyering@lucent.com>
22500
22501         * lib/regex.c: Update from GNU libc.
22502
22503 2001-05-27  Jim Meyering  <meyering@lucent.com>
22504
22505         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
22506         Check for ut_type in struct utmp.
22507
22508 2001-05-27  Jim Meyering  <meyering@lucent.com>
22509
22510         * lib/readutmp.h (UT_TYPE): Define.
22511
22512 2001-05-24  Jim Meyering  <meyering@lucent.com>
22513
22514         * lib/argmatch.c: Include "quote.h".
22515         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
22516         quote function.  Reported by Göran Uddeborg.
22517
22518 2001-05-22  Jim Meyering  <meyering@lucent.com>
22519
22520         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
22521         now that we use the package-supplied version unconditionally.
22522         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
22523
22524 2001-05-21  Jim Meyering  <meyering@lucent.com>
22525
22526         * m4/regex.m4: Change a couple backticks to single quotes to avoid
22527         shell syntax errors.
22528
22529 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22530
22531         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
22532
22533 2001-05-20  Paul Eggert  <eggert@twinsun.com>
22534
22535         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
22536         Don't bother to check library strftime, since
22537         we'll be using our own my_strftime function anyway.
22538         Define my_strftime instead of strftime.
22539
22540 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
22541
22542         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
22543         which is not yet declared.
22544
22545 2001-05-15  Jim Meyering  <meyering@lucent.com>
22546
22547         * m4/regex.m4: Use proper quoting so brackets appear in the test
22548         program.
22549         Reported by, and with help from, Bruno Haible.
22550
22551 2001-05-13  Jim Meyering  <meyering@lucent.com>
22552
22553         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
22554         undefined.
22555
22556 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22557
22558         dirname code cleanup.  base_name now behaves more compatibly
22559         with POSIX basename when given file names that have trailing
22560         slashes, and similarly for dir_name.  Add new primitives
22561         base_len and dir_len.  Put the directory-name-related decls
22562         into dirname.h.
22563
22564         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
22565         * lib/backupfile.c (base_name): Likewise.
22566         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
22567         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
22568         * lib/makepath.c (strip_trailing_slashes): Likewise.
22569         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
22570         ISSLASH): Likewise.
22571         * lib/rename.c (strip_trailing_slashes): Likewise.
22572         * lib/same.c (base_name): Likewise.
22573         * lib/stripslash.c (ISSLASH): Likewise.
22574
22575         * lib/addext.c: Include <dirname.h> after size_t is defined.
22576         * lib/backupfile.c: Likewise.
22577
22578         * lib/addext.c (addext): Use base_len to trim redundant
22579         trailing slashes instead of doing it ourselves.
22580         But do not trim the last slash if it is not redundant.
22581
22582         * lib/backupfile.c (find_backup_file_name,
22583         max_backup_version): Use base_len instead of rolling it ourselves.
22584         Handle the case of "" and (on DOS) "C:" correctly.
22585
22586         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
22587         needed. Include <string.h>, <dirname.h>.
22588         (base_name): Allow file names ending in slashes, other than names
22589         that are all slashes.  In this case, return the basename followed
22590         by the slashes.  This is more general, and can be used in places
22591         where the original base_name purposely had an assertion failure.
22592         (base_len): New function.
22593
22594         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
22595         Do not include <assert.h>; no longer needed.
22596         Include xalloc.h.
22597         (memrchr): Remove decl.
22598         (dir_name_r): Remove.
22599         (dir_len): Renamed from dirlen.  All callers changed.
22600         Rewrite in terms of base_name, for simplicity and consistency.
22601         (dir_name): Never return NULL.  All callers changed.
22602         Do not include <stdlib.h> in test program; no longer needed.
22603         return 0; is fine for test program.
22604
22605         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
22606         New macros.
22607         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
22608
22609         * lib/path-concat.c (path_concat): Use base_len to compute
22610         base length, not strlen; this means we cannot rely on memcpy
22611         to null-terminate.
22612
22613         * lib/same.c (STREQ): Remove.
22614         (same_name): Handle the case where the basename ends in trailing '/'.
22615
22616         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
22617         a slash was stripped.  Do not strip the last slash after a
22618         file system prefix.
22619
22620 2001-05-11  Paul Eggert  <eggert@twinsun.com>
22621
22622         * lib/Makefile.am (libfetish_a_SOURCES):
22623         Add strftime.c, since we now compile it on all hosts.
22624
22625         * lib/strftime.c (my_strftime):
22626         Define to nstrftime if emacs, but only if my_strftime is not defined.
22627         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
22628         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
22629         Add one more extra argument: a nanoseconds value.
22630         All uses changed.
22631         (ns): New macro.
22632         (my_strftime function): Add %N format.
22633         (emacs_strftimeu): Renamed from emacs_strftime,
22634         with extra ut argument.
22635
22636 2001-05-09  Paul Eggert  <eggert@twinsun.com>
22637
22638         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
22639
22640 2001-04-21  Jim Meyering  <meyering@lucent.com>
22641
22642         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
22643         doesn't interfere.
22644
22645 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
22646
22647         * m4/ftruncate.m4: Check for chsize.
22648         Link with ftruncate.o unconditionally if ftruncate is missing.
22649         This was required when cross-compiling to i586-mingw32msvc.
22650
22651 2001-04-08  Jim Meyering  <meyering@lucent.com>
22652
22653         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
22654         recomputed; that's necessary when the offset spans a DST transition.
22655         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
22656
22657 2001-04-02  Jim Meyering  <meyering@lucent.com>
22658
22659         * lib/regex.h, regex.c: Update from GNU libc.
22660
22661 2001-03-24  Jim Meyering  <meyering@lucent.com>
22662
22663         * m4/jm-macros.m4: Require autoconf-2.49d.
22664
22665 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
22666
22667         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
22668
22669 2001-03-19  Paul Eggert  <eggert@twinsun.com>
22670
22671         * lib/version-etc.c (version_etc_copyright): Update to 2001.
22672
22673 2001-03-17  Jim Meyering  <meyering@lucent.com>
22674
22675         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
22676         now that the version in autoconf is equivalent.
22677         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
22678
22679         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
22680         Suggestion from Akim Demaille.
22681
22682         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
22683         (jm_PREREQ_TEMPNAME): New function.
22684
22685 2001-03-16  Paul Eggert  <eggert@twinsun.com>
22686
22687         * lib/tempname.c (uint64_t): Define to uintmax_t if
22688         not defined, and if UINT64_MAX is not defined.
22689         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
22690         Reported by John David Anglin.
22691
22692 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
22693
22694         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
22695         resolve alias if codeset is empty.
22696         * lib/config.charset (BeOS): Use wildcard syntax.
22697
22698 2001-03-13  Jim Meyering  <meyering@lucent.com>
22699
22700         * lib/path-concat.c (path_concat)
22701         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
22702         concatenating e.g., `C:' and `foo'.
22703         From Bruno Haible.
22704
22705 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22706
22707         * lib/localcharset.c (locale_charset): Don't use
22708         setlocale(LC_CTYPE,NULL). Don't return NULL.
22709         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
22710
22711 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
22712
22713         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
22714         support for DOS/DJGPP.
22715
22716 2001-03-01  Paul Eggert  <eggert@twinsun.com>
22717
22718         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
22719         lacks mkstemp.  Compile our own tempname.c if we compile our own
22720         mkstemp.c, as mkstemp relies on tempname.
22721
22722 2001-03-01  Jim Meyering  <meyering@lucent.com>
22723
22724         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
22725         AH_VERBATIM really does output its argument verbatim.
22726
22727 2001-02-28  Paul Eggert  <eggert@twinsun.com>
22728
22729         * lib/Makefile.am (libfetish_a_SOURCES):
22730         Add dup-safer.c, fopen-safer.c.
22731         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
22732
22733         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
22734         * lib/unistd-safer.h: New files.
22735
22736 2001-02-25  Paul Eggert  <eggert@twinsun.com>
22737
22738         The mkstemp replacement is taken from glibc 2.2.2, with some
22739         portability fixes for use outside glibc, as follows:
22740
22741         * lib/tempname.c (struct_stat64): New macro.
22742         (direxists, __gen_tempname): Use it.
22743         This avoids a portability problem with Solaris 8.
22744
22745         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
22746         (<stddef.h>, <stdint.h>, <string.h>):
22747         Include only if STDC_HEADERS || _LIBC.
22748         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
22749         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
22750         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
22751         (__set_errno): Define this macro if <errno.h> doesn't.
22752         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
22753         Define these macros if <stdio.h> doesn't.
22754         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
22755         Define these macros if <sys/stat.h>
22756         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
22757         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
22758         __xstat64): Define if not _LIBC.
22759         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
22760         (__gen_tempname): Invoke gettimeofday only if
22761         HAVE_GETTIMEOFDAY || _LIBC;
22762         otherwise, fall back on plain "time".
22763         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
22764
22765         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
22766
22767         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
22768
22769 2001-02-18  Paul Eggert  <eggert@twinsun.com>
22770
22771         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
22772
22773 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22774
22775         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
22776         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
22777         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
22778         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
22779
22780 2001-02-17  Paul Eggert  <eggert@twinsun.com>
22781
22782         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
22783         Remove workaround macros for hosts that have mbrtowc but not
22784         mbstate_t, as we now insist on proper declarations for both
22785         before using mbrtowc.
22786
22787 2001-02-17  Jim Meyering  <meyering@lucent.com>
22788
22789         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
22790         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
22791         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
22792         UnixWare 7.1.1.
22793
22794         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
22795         rather than AC_CACHE_VAL.
22796
22797 2001-02-17  Jim Meyering  <meyering@lucent.com>
22798
22799         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
22800         around included file name.
22801
22802         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
22803
22804         * lib/strftime.c: Update from GNU libc (the only changes were to
22805         comments).
22806
22807 2001-02-17  Jim Meyering  <meyering@lucent.com>
22808
22809         * lib/regex.c: Update from libc.
22810
22811 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
22812
22813         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
22814         clash.
22815
22816 2001-02-16  Paul Eggert  <eggert@twinsun.com>
22817
22818         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
22819         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
22820         Reported by Mark Hounschell via Paul Eggert.
22821
22822 2001-02-07  Jim Meyering  <meyering@lucent.com>
22823
22824         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
22825
22826 2001-02-05  Jim Meyering  <meyering@lucent.com>
22827
22828         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
22829         it includes the patch required for `large file' support with at least
22830         HP-UX's 10.20 /bin/cc.
22831
22832 2001-02-03  Jim Meyering  <meyering@lucent.com>
22833
22834         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
22835         AS_IF, now that it works once again (mysteriously).
22836         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22837
22838 2001-01-30  Jim Meyering  <meyering@lucent.com>
22839
22840         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
22841         * m4/chown.m4: Rename conftestchown to conftest.chown.
22842         * m4/rename.m4: s/conftestdir/conftest.d1/ and
22843         s/conftestdir2/conftest.d2/.
22844         * m4/utimes.m4: s/conftestdata/conftest.data/
22845         Inspired by Pavel Roskin's change in autoconf.
22846
22847 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
22848
22849         * lib/config.charset: Update for FreeBSD 4.2.
22850
22851 2001-01-27  Jim Meyering  <meyering@lucent.com>
22852
22853         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
22854         a use of AS_IF.
22855         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
22856
22857 2001-01-26  Jim Meyering  <meyering@lucent.com>
22858
22859         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
22860         quotearg.c includes it.
22861
22862 2001-01-26  Jim Meyering  <meyering@lucent.com>
22863
22864         * lib/quotearg.c: Include stddef.h.
22865         * lib/quote.c: Include stddef.h.
22866         Reported by Axel Kittenberger.
22867
22868         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
22869         line in double quotes so that it evokes a better diagnostic.
22870         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
22871         Reported by Axel Kittenberger.
22872
22873 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
22874
22875         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
22876         as if it was a `charset'.
22877
22878 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22879
22880         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
22881         has const.
22882
22883 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
22884
22885         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
22886         to avoid a warning.  Add back 'const' to inptr.
22887
22888 2001-01-20  Jim Meyering  <meyering@lucent.com>
22889
22890         Be sure that headers are checked before used in code compiled
22891         for the type checks.
22892         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
22893         In place of that, invoke jm_CHECK_ALL_TYPES.
22894         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
22895         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
22896         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
22897         The check for ssize_t was mistakenly run before the test for unistd.h.
22898
22899         The configure-time check for stdbool.h was missing.
22900         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
22901         (jm_PREREQ_HASH): New function.
22902
22903 2001-01-17  Jim Meyering  <meyering@lucent.com>
22904
22905         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
22906         for autoconf-2.49c.
22907         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
22908
22909 2001-01-16  Jim Meyering  <meyering@lucent.com>
22910
22911         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
22912         From Bruno Haible.
22913
22914 2001-01-14  Jim Meyering  <meyering@lucent.com>
22915
22916         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
22917         foo and bar.  Create conftestdir/ in the script, not in the C code.
22918         Remove directories in the script, not in the C code.
22919         Remove conftestdir{,2} before trying to create the directory.
22920         Make the entire configure script fail if the mkdir fails.
22921
22922 2001-01-14  Jim Meyering  <meyering@lucent.com>
22923
22924         * lib/rename.c: New file.  From Volker Borchert.
22925         Include stdlib.h, string.h or strings.h, and xalloc.h.
22926         Use strip_trailing_slashes rather than open-coding it.
22927
22928 2001-01-03  Paul Eggert  <eggert@twinsun.com>
22929
22930         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
22931
22932 2001-01-03  Jim Meyering  <meyering@lucent.com>
22933
22934         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
22935         of local `inptr' to avoid warning with some system declarations of
22936         iconv.
22937
22938 2001-01-02  Volker Borchert  <bt@teknon.de>
22939
22940         * m4/rename.m4: New file.
22941         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
22942
22943 2001-01-01  Jim Meyering  <meyering@lucent.com>
22944
22945         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
22946         even on systems with utmpx.h.  It's necessary for the declaration of
22947         utmp's ut_user member.  Reported by Andreas Jaeger.
22948
22949         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
22950         available. They are required for the declarations of getgrgid and
22951         getpwuid resp.
22952         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
22953         Reported by Andreas Jaeger.
22954
22955 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
22956
22957         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
22958         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
22959         so `make install' also works in VPATH builds.
22960
22961 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
22962
22963         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
22964         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
22965         can be used in subdirectories.
22966
22967 2000-12-29  Paul Eggert  <eggert@twinsun.com>
22968
22969         * lib/modechange.c: Do not assume that mode_t uses the
22970         traditional octal encoding.  E.g. "chmod 1 FOO" should set
22971         the other-execute bit of FOO even if S_IXOTH != 1.
22972
22973         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
22974         WOTH, XOTH, ALLM): New macros.
22975         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
22976          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
22977         Use them.
22978         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
22979         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
22980         (mode_compile):
22981         No need to use uintmax_t; unsigned long is long enough.
22982         Don't bother to get suffix since we don't use it.
22983
22984 2000-12-26  Jim Meyering  <meyering@lucent.com>
22985
22986         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
22987         better with autoheader.
22988
22989 2000-12-24  Jim Meyering  <meyering@lucent.com>
22990
22991         * lib/hash.c (is_prime): Return explicit boolean values.
22992         (hash_get_first): Return NULL to appease Irix5.6's 89.
22993         Reported by Nelson Beebe.
22994
22995 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
22996
22997         * lib/localcharset.c (locale_charset): Add support for Win32.
22998
22999 2000-12-18  Paul Eggert  <eggert@twinsun.com>
23000
23001         * lib/physmem.h, lib/physmem.c: New files.
23002
23003         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
23004         (noinst_HEADERS): Add physmem.h.
23005
23006         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
23007         't' for compatibility with Solaris 8 sort.
23008
23009 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
23010
23011         * lib/config.charset: Add support for BeOS.
23012
23013 2000-12-17  Jim Meyering  <meyering@lucent.com>
23014
23015         * m4/dos.m4 (jm_AC_DOS): New file and macro.
23016         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
23017
23018 2000-12-16  Jim Meyering  <meyering@lucent.com>
23019
23020         This bug had a serious impact on chown: `chown N:M FILE' (for integer
23021         N and M) would have treated it like `chown N:N FILE'.
23022
23023         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
23024
23025 2000-12-16  Jim Meyering  <meyering@lucent.com>
23026
23027         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
23028         SHELLS_FILE to a file name that's useful on djgpp systems.
23029         Include stdlib.h.
23030         (ADDITIONAL_DEFAULT_SHELLS): Define.
23031         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
23032         Based mostly on a patch from Prashant TR.
23033
23034 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
23035
23036         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
23037         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
23038         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
23039
23040 2000-12-08  Andreas Schwab  <schwab@suse.de>
23041
23042         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
23043         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
23044
23045 2000-12-07  Jim Meyering  <meyering@lucent.com>
23046
23047         * lib/stripslash.c (ISSLASH): Define.
23048         (strip_trailing_slashes): Use ISSLASH rather than comparing against
23049         `/'.
23050         From Prashant TR.
23051
23052         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
23053         (dir_name_r): Declare this function as static.
23054         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
23055         manifest itself on a name containing a mix of slashes and
23056         backslashes.
23057         Make this function work with names starting with a DOS-style
23058         drive letter and colon prefix.
23059         (dir_name): Append `.' if necessary.
23060         Based mostly on patches from Prashant TR and Eli Zaretskii.
23061
23062         * lib/dirname.h (dir_name_r): Remove prototype.
23063
23064 2000-12-06  Paul Eggert  <eggert@twinsun.com>
23065
23066         * m4/off_t-format.m4: Remove this file.
23067         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
23068
23069 2000-12-06  Jim Meyering  <meyering@lucent.com>
23070
23071         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
23072         replacement strtoull, we may well need the replacement strtoul, too.
23073         Check for declarations of strtoul and strtoull.
23074         Check for strtol.  Mainly as a cue to cause automake to include
23075         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
23076         Check for limits.h -- strtol.c needs it.
23077
23078 2000-12-05  Jim Meyering  <meyering@lucent.com>
23079
23080         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
23081
23082 2000-12-04  Jim Meyering  <meyering@lucent.com>
23083
23084         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
23085         Also include memory.h, stdlib.h, unistd.h if appropriate.
23086         Reported by Andreas Jaeger (conflicting declaration of malloc).
23087
23088 2000-12-02  Jim Meyering  <meyering@lucent.com>
23089
23090         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
23091         * m4/jm-macros.m4 (jm_MACROS): require it.
23092
23093 2000-12-02  Jim Meyering  <meyering@lucent.com>
23094
23095         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
23096
23097 2000-12-01  Paul Eggert  <eggert@twinsun.com>
23098
23099         * lib/memrchr.c: Include <config.h> before any system include file.
23100
23101 2000-11-30  Jim Meyering  <meyering@lucent.com>
23102
23103         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
23104
23105 2000-11-30  Jim Meyering  <meyering@lucent.com>
23106
23107         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
23108
23109 2000-11-29  Paul Eggert  <eggert@twinsun.com>
23110
23111         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
23112
23113 2000-11-26  Jim Meyering  <meyering@lucent.com>
23114
23115         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
23116
23117 2000-11-22  Paul Eggert  <eggert@twinsun.com>
23118
23119         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
23120         size of (size_t) -1; it's not portable.
23121
23122 2000-11-17  Jim Meyering  <meyering@lucent.com>
23123
23124         * lib/strstr.c: Update from GNU libc.
23125
23126 2000-11-17  Akim Demaille  <akim@epita.fr>
23127
23128         * lib/obstack.h: Formatting changes.
23129         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
23130         prevent type checking.
23131         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
23132         cast the value to (void *): assigning a `foo *' to a `void *'
23133         variable is valid.
23134         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
23135
23136 2000-11-16  Jim Meyering  <meyering@lucent.com>
23137
23138         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
23139
23140 2000-11-11  Jim Meyering  <meyering@lucent.com>
23141
23142         * lib/error.c: Add a couple #includes, merging from GNU libc version.
23143
23144 2000-11-10  Jim Meyering  <meyering@lucent.com>
23145
23146         * lib/obstack.h: Update from GNU libc.
23147         * lib/obstack.c: Likewise.
23148
23149 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
23150
23151         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
23152
23153 2000-11-06  Paul Eggert  <eggert@twinsun.com>
23154
23155         * lib/getusershell.c (setusershell): Use rewind rather than
23156         fseek/fseeko, to avoid configuration hassles with fseeko.
23157         Don't bother opening SHELLS_FILE if shellstream is NULL;
23158         it's not necessary.
23159
23160 2000-11-05  Jim Meyering  <meyering@lucent.com>
23161
23162         * lib/makepath.h (make_dir): Declare.
23163         * lib/makepath.c (make_dir): Remove `static' attribute.
23164         Tweak a comment.
23165
23166 2000-11-04  Jim Meyering  <meyering@lucent.com>
23167
23168         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
23169
23170 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
23171
23172         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
23173         last one in a bucket, advance to the next bucket.
23174
23175 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
23176
23177         * lib/fnmatch.c: Do not comment out all the code if we are using
23178         the GNU C library, because in some cases we are replacing buggy
23179         code in the GNU C library itself.
23180
23181 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
23182
23183         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
23184         (regex_compile): Catch bogus \(\1\).
23185
23186 2000-10-30  Paul Eggert  <eggert@twinsun.com>
23187
23188         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
23189         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
23190         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
23191
23192 2000-10-30  Paul Eggert  <eggert@twinsun.com>
23193
23194         * lib/error.h, getline.h, modechange.h:
23195         Remove "2000" from Copyright line, as the file hasn't been
23196         changed this year other than in the copyright notice.
23197
23198         * lib/xalloc.h: Add "2000" to Copyright line, as this file
23199         was changed this year.
23200
23201 2000-10-29  Jim Meyering  <meyering@lucent.com>
23202
23203         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
23204         renaming.
23205         * m4/ls-mntd-fs.m4: Likewise
23206
23207 2000-10-29  Jim Meyering  <meyering@lucent.com>
23208
23209         * lib/xstat.in: Fix grammar in comment.
23210
23211 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
23212
23213         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
23214         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
23215         doesn't define __restrict_arr.
23216
23217 2000-10-28  Jim Meyering  <meyering@lucent.com>
23218
23219         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
23220         (jm_PREREQ_MEMCHR): New function.
23221
23222 2000-10-28  Jim Meyering  <meyering@lucent.com>
23223
23224         * lib/memchr.c: Update from libc.
23225         Adjust for portability:
23226         [HAVE_STDLIB_H]: Include stdlib.h.
23227         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
23228         Undef __memchr, too.
23229         [!weak_alias]: Define __memchr to memchr.
23230
23231         * lib/regex.c: Update from libc.
23232         * lib/regex.h: Likewise.
23233         * lib/getopt1.c: Likewise.
23234         * lib/memcmp.c: Likewise.
23235
23236         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
23237         Avoid using fseek, when possible -- it's broken by design.
23238         Patch by Ulrich Drepper.
23239
23240 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
23241
23242         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
23243         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
23244         Giving in to popular pressure to shut up the compiler with casts.
23245
23246 2000-10-26  Jim Meyering  <meyering@lucent.com>
23247
23248         * lib/strftime.c: Update from libc.
23249
23250 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
23251
23252         * regex.c: More `unsigned char' -> `re_char' changes.
23253         Also change several `int' into `re_wchar_t'.
23254         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
23255         (PUSH_FAILURE_POINTER): Don't cast any more.
23256         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
23257         We want GCC to complain, since this piece of code makes
23258         re_match non-reentrant, which *should* be fixed.
23259         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
23260         (EXTEND_BUFFER): Use RETALLOC.
23261         (SET_LIST_BIT): Don't cast.
23262         (re_wchar_t): New type.
23263         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
23264         that those two functions will always properly return.
23265         (IMMEDIATE_QUIT_CHECK): Cast to void.
23266         (analyse_first): Use recursion rather than an explicit stack.
23267         (re_compile_fastmap): Can't fail anymore.
23268         (re_search_2): Don't check re_compile_fastmap for failure.
23269         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
23270         Now also sets the new value (passed in a new argument).
23271         (re_match_2_internal): Use it.
23272         Also, use a new var `reg' of type size_t when looping through regs
23273         rather than reuse the inappropriate `mcnt'.
23274
23275 2000-10-25  Jim Meyering  <meyering@lucent.com>
23276
23277         * lib/obstack.c: Update from libc.
23278
23279 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
23280
23281         * regex.c (regex_compile): Change the way of handling a range from
23282         a char less than 256 to a char not less than 256.
23283
23284 2000-10-24  Andrew Innes  <andrewi@gnu.org>
23285
23286         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
23287         NT-Emacs only.
23288         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
23289         so that re_search functions only quit when callers expect them to.
23290
23291 2000-10-23  Jim Meyering  <meyering@lucent.com>
23292
23293         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
23294         wrong.  That set_locale call must not have any side effects.
23295         From Paul Eggert.
23296
23297 2000-10-22  Jim Meyering  <meyering@lucent.com>
23298
23299         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
23300         [CYCLIC]: Remove now-unused definition.
23301
23302         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
23303         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
23304         Suggestion from Ulrich Drepper.
23305
23306 2000-10-21  Jim Meyering  <meyering@lucent.com>
23307
23308         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
23309         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
23310         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
23311
23312 2000-10-21  Jim Meyering  <meyering@lucent.com>
23313
23314         * lib/dirname.c (memrchr): Declare if necessary.
23315         (dir_name): Remove the restriction that there be no
23316         trailing slashes.  Now, this code skips past them, effectively
23317         ignoring them.
23318         [TEST_DIRNAME] (main): New unit tests.
23319
23320         * lib/memrchr.c: New file from GNU libc.
23321         Undef __memrchr, too.
23322         [!weak_alias]: Define __memrchr to memrchr.
23323         Guard weak_alias use with `#ifdef weak_alias'.
23324
23325 2000-10-21  Jim Meyering  <meyering@lucent.com>
23326
23327         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
23328         (dir_name): Use dir_name_r.
23329         * lib/dirname.h (dir_name_r): Declare it.
23330
23331 2000-10-17  Jim Meyering  <meyering@lucent.com>
23332
23333         * lib/quote.h (PARAMS): Define and use.
23334         Reported by Akim Demaille.
23335
23336         * lib/getopt.c: Update from libc.
23337
23338 2000-10-16  Jim Meyering  <meyering@lucent.com>
23339
23340         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
23341         setlocale.
23342         From Jan Fedak.
23343
23344 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
23345
23346         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
23347
23348 2000-09-25  Jim Meyering  <meyering@lucent.com>
23349
23350         * lib/md5.h (rol): Define (from GnuPG).
23351
23352         * lib/sha.c: Give credit (GnuPG) where due.
23353         (M): Use rol rather than open-coding it.
23354         Add a FIXME comment.
23355
23356 2000-09-21  Jim Meyering  <meyering@lucent.com>
23357
23358         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
23359         Reported by Michael Stone.
23360
23361 2000-09-20  Jim Meyering  <meyering@lucent.com>
23362
23363         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
23364         (noinst_HEADERS): Add sha.h.
23365         Based on code from Scott G. Miller and from GnuPG.
23366
23367 2000-09-18  Jim Meyering  <meyering@lucent.com>
23368
23369         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
23370         LIBS. Otherwise, everyone ends up linking with -lelf for some
23371         configurations.
23372         Reported by Mike Stone.
23373
23374 2000-09-15  Jim Meyering  <meyering@lucent.com>
23375
23376         * lib/regex.c: Update from libc.
23377
23378 2000-09-10  Jim Meyering  <meyering@lucent.com>
23379
23380         * lib/getopt.c (_getopt_internal): Update from glibc.
23381
23382 2000-09-09  Jim Meyering  <meyering@lucent.com>
23383
23384         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
23385         think it should be used as a general replacement for isascii.
23386         * lib/fnmatch.c: Likewise.
23387         * lib/mbswidth.c: Likewise
23388         * lib/regex.c: Likewise.
23389
23390         Don't use atoi.
23391         * lib/userspec.c: Include sys/param.h and limits.h.
23392         Include xstrtol.h.
23393         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
23394         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
23395         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
23396         UID, GID.  Check range.
23397
23398 2000-09-06  Jim Meyering  <meyering@lucent.com>
23399
23400         * lib/getopt.c (_getopt_internal): Update from glibc.
23401
23402 2000-08-30  Jim Meyering  <meyering@lucent.com>
23403
23404         * lib/strftime.c: Merge in changes from GNU libc.
23405
23406 2000-08-26  Jim Meyering  <meyering@lucent.com>
23407
23408         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
23409         * m4/fpending.m4: New file.
23410
23411 2000-08-26  Jim Meyering  <meyering@lucent.com>
23412
23413         * lib/closeout.c: Include "__fpending.h".
23414         (close_stdout_status): Return right away if there's nothing to flush.
23415
23416         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
23417         * lib/__fpending.c: New file.
23418         * lib/__fpending.h: New file.
23419
23420 2000-08-20  Jim Meyering  <meyering@lucent.com>
23421
23422         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
23423         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
23424         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
23425
23426 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
23427
23428         Improve fileutils installation on systems where running
23429         programs (like install) can't be unlinked.
23430         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
23431         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
23432
23433 2000-08-07  Paul Eggert  <eggert@twinsun.com>
23434
23435         Standardize on "memory exhausted" instead of "Memory exhausted"
23436         or "virtual memory exhausted".
23437         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
23438         "virtual memory exhausted".
23439         * lib/same.c (same_name): Invoke xalloc_die instead of printing
23440         our own message.
23441         * lib/userspec.c (parse_user_spec): Likewise.
23442         * lib/bumpalloc.h: comment fix
23443         * lib/same.c, userspec.c: Include xalloc.h.
23444
23445         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
23446         not char *const and pointing to a constant array.
23447         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
23448         (xrealloc): Comment fix.
23449
23450         * lib/userspec.c (parse_user_spec):
23451         Don't translate a message until just before returning,
23452         to avoid unnecessary translation.
23453
23454 2000-08-07  Jim Meyering  <meyering@lucent.com>
23455
23456         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
23457         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
23458         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
23459         getgroups.c, gethostname.c, getopt.h, group-member.c,
23460         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
23461         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
23462         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
23463         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
23464         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
23465         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
23466         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
23467         yesno.c: Back out Copyright date changes for each file with no change
23468         this year.  This eases coordination with other programs using the same
23469         source code modules.  From Paul Eggert.
23470
23471 2000-08-06  Paul Eggert  <eggert@twinsun.com>
23472
23473         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
23474         not char, for compatibility with glibc 2.1.3 strftime.c.
23475
23476 2000-08-03  Greg McGary  <greg@mcgary.org>
23477
23478         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
23479         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
23480         (EXTEND_BUFFER): Use them.
23481
23482 2000-08-01  Jim Meyering  <meyering@lucent.com>
23483
23484         * lib/dirname.c (ISSLASH): Define.
23485         (BACKSLASH_IS_PATH_SEPARATOR): Define.
23486         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
23487         both `\' and `/' may be use as path separators.
23488         Based on a patch from Prashant TR.
23489
23490 2000-07-31  Paul Eggert  <eggert@twinsun.com>
23491
23492         * lib/quotearg.c (quotearg_n_options): Don't make the initial
23493         slot vector a constant, since it might get modified.
23494
23495 2000-07-31  Jim Meyering  <meyering@lucent.com>
23496
23497         * lib/xmalloc.c: Use `virtual memory exhausted', not
23498         `Memory exhausted'.
23499         * lib/obstack.c (print_and_abort): Likewise.
23500
23501 2000-07-30  Paul Eggert  <eggert@twinsun.com>
23502
23503         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
23504         buffer, so that the caller can always quote one small
23505         component of a "memory exhausted" message in slot 0.
23506         From a suggestion by Jim Meyering.
23507
23508 2000-07-30  Jim Meyering  <meyering@lucent.com>
23509
23510         * lib/makepath.c (make_path): Quote the other instance, too.
23511
23512         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
23513         (STATIC_BUF_SIZE): Define.
23514         (quotearg_n_options): Use only statically allocated storage when
23515         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
23516         than STATIC_BUF_SIZE.
23517
23518 2000-07-29  Jim Meyering  <meyering@lucent.com>
23519
23520         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
23521         * lib/dirname.c (dir_name): Likewise.
23522
23523         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
23524         `/'.
23525
23526         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
23527         (dir_name): Assert that there are no trailing slashes.
23528
23529 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
23530
23531         * lib/mbswidth.h (mbswidth): Add a flags argument.
23532         (mbswidth): New declaration.
23533         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
23534         * lib/mbswidth.c (mbswidth): Add a flags argument.
23535         (mbsnwidth): New function.
23536
23537 2000-07-24  Jim Meyering  <meyering@lucent.com>
23538
23539         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
23540
23541 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23542
23543         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
23544
23545 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23546
23547         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
23548         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
23549         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
23550         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
23551         invoke multibyte primitives.
23552
23553 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23554
23555         * lib/quotearg.c:
23556         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
23557         so that mbstate_t is always defined.
23558
23559         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
23560         be 1 in at least one GCC installation, and this configuration
23561         error is likely to be common.  Ignoring MB_LEN_MAX hurts
23562         performance on hosts that have mbrtowc but have only unibyte
23563         locales, but I assume these hosts are rare.
23564
23565 2000-07-23  Paul Eggert  <eggert@twinsun.com>
23566
23567         * lib/mbswidth.c (_XOPEN_SOURCE):
23568         Don't define; this causes problems on Solaris 7.
23569         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
23570
23571 2000-07-23  Jim Meyering  <meyering@lucent.com>
23572
23573         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
23574         too: getgrgid, getpwuid, getuid.
23575
23576 2000-07-23  Jim Meyering  <meyering@lucent.com>
23577
23578         * lib/basename.c (base_name): Add an assertion.
23579
23580 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
23581
23582         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
23583         shadow its mbsinit function.
23584
23585 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23586
23587         * lib/mbswidth.h: New file.
23588         * lib/mbswidth.c: New file.
23589         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
23590         (noinst_HEADERS): Add mbswidth.h.
23591
23592 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
23593
23594         * lib/config.charset: Add support for FreeBSD. Improve support for
23595         HP-UX and IRIX 6.
23596
23597 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
23598
23599         * m4/mbswidth.m4: New file.
23600         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
23601
23602 2000-07-15  Jim Meyering  <meyering@lucent.com>
23603
23604         * lib/makepath.c: Include quote.h.
23605         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
23606         corresponding argument in a `quote (...)' call.
23607         Give better diagnostics.
23608
23609         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
23610         (noinst_HEADERS): Add quote.h.
23611
23612         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
23613         from tar's src/misc.c.
23614         * lib/quote.h: New file.  Prototypes for same.
23615
23616 2000-07-14  Paul Eggert  <eggert@twinsun.com>
23617
23618         From a suggestion by Bruno Haible.
23619         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
23620         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
23621         to decide whether to define the BeOS workaround macro;
23622         this adjusts to the change to AC_MBSTATE_T.
23623
23624 2000-07-14  Jim Meyering  <meyering@lucent.com>
23625
23626         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
23627         jm_AC_TYPE_UINTMAX_T.
23628
23629 2000-07-13  Paul Eggert  <eggert@twinsun.com>
23630
23631         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
23632
23633         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
23634         quotearg_buffer_restyled): Add support for
23635         clocale_quoting_style.  Undo previous change to
23636         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
23637         and "{RIGHT QUOTATION MARK}" msgids.
23638
23639 2000-07-10  Paul Eggert  <eggert@twinsun.com>
23640
23641         From a suggestion by Bruno Haible.
23642         * m4/mbstate_t.m4 (AC_MBSTATE_T):
23643         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
23644         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
23645         and mbstate_t, to a single-part test that simply defines mbstate_t.
23646         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
23647         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
23648
23649 2000-07-10  Jim Meyering  <meyering@lucent.com>
23650
23651         * m4/strerror_r.m4: Mirror the correction made in autoconf.
23652
23653         * m4/gnu-source.m4: Output to confdefs.h directly.
23654         Suggestion from Akim Demaille.
23655
23656 2000-07-09  Paul Eggert  <eggert@twinsun.com>
23657
23658         The old behavior of quoting `like this' doesn't look good with
23659         newer, ISO-style fonts.  See:
23660         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
23661
23662         Instead, quote "like this" by default.  Let the translator
23663         tailor the locale-specific quoting behavior by providing
23664         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
23665
23666         * lib/quotearg.c (N_): New macro.
23667         (gettext_default): New function.
23668         (quotearg_buffer_restyled): Use
23669         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
23670         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
23671
23672 2000-07-09  Jim Meyering  <meyering@lucent.com>
23673
23674         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
23675         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
23676
23677         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
23678         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
23679
23680 2000-07-09  Jim Meyering  <meyering@lucent.com>
23681
23682         * lib/Most files: Update copyright dates to include 2000.
23683
23684 2000-07-08  Jim Meyering  <meyering@lucent.com>
23685
23686         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
23687         if not defined.
23688         (xgethostname): Remove now-unnecessary #ifdef.
23689         Move declaration of `err' into loop where it's used.
23690
23691 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23692         and Bruno Haible  <haible@clisp.cons.org>
23693
23694         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
23695         only if the test for an object-type mbstate_t fails.  This
23696         prevents us from mistakenly reporting that mbstate_t is a
23697         system object type after we "#define mbstate_t int" to work
23698         around its lack.
23699
23700 2000-07-05  Paul Eggert  <eggert@twinsun.com>
23701         and Bruno Haible  <haible@clisp.cons.org>
23702
23703         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
23704
23705 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23706
23707         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
23708         to strerror_r.
23709         Include <ctype.h> for use of isalpha.
23710
23711 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23712
23713         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
23714         by allocating a larger buffer. Test the gethostname return value for
23715         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
23716         returns an error and ENAMETOOLONG isn't defined.
23717
23718 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
23719
23720         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
23721         dimension.
23722
23723 2000-07-04  Jim Meyering  <meyering@lucent.com>
23724
23725         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
23726         of the deprecated AC_CHECKING.
23727
23728 2000-07-04  Jim Meyering  <meyering@lucent.com>
23729
23730         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
23731         Reported by Bruno Haible.
23732
23733 2000-07-04  Jim Meyering  <meyering@lucent.com>
23734
23735         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
23736         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
23737         lacks mbrtowc.
23738
23739 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23740
23741         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
23742         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
23743
23744 2000-07-03  Paul Eggert  <eggert@twinsun.com>
23745         and Bruno Haible  <haible@clisp.cons.org>
23746
23747         * lib/quotearg.c (mbrtowc):
23748         Assign to *pwc, and return 1 only if result is nonzero.
23749         (iswprint): Use ISPRINT when substituting our own mbrtowc.
23750
23751 2000-07-03  Jim Meyering  <meyering@lucent.com>
23752
23753         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
23754
23755 2000-07-03  Jim Meyering  <meyering@lucent.com>
23756
23757         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
23758         This is necessary to get a definition of e.g., UTMP_FILE on
23759         HP-UX 10.20.
23760         From Bob Proulx.
23761
23762 2000-07-02  Jim Meyering  <meyering@lucent.com>
23763
23764         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
23765
23766         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
23767         AC_LIBOBJ(function_name).
23768         * m4/chown.m4: Likewise.
23769         * m4/fnmatch.m4: Likewise.
23770         * m4/ftruncate.m4: Likewise.
23771         * m4/getgroups.m4: Likewise.
23772         * m4/getline.m4: Likewise.
23773         * m4/group-member.m4: Likewise.
23774         * m4/jm-macros.m4: Likewise.
23775         * m4/lstat.m4: Likewise.
23776         * m4/malloc.m4: Likewise.
23777         * m4/memcmp.m4: Likewise.
23778         * m4/nanosleep.m4: Likewise.
23779         * m4/putenv.m4: Likewise.
23780         * m4/realloc.m4: Likewise.
23781         * m4/regex.m4: Likewise.
23782         * m4/stat.m4: Likewise.
23783         * m4/strftime.m4: Likewise.
23784
23785 2000-07-02  Jim Meyering  <meyering@lucent.com>
23786
23787         * lib/quotearg.c (mbstate_t): Don't define here.
23788
23789 2000-07-02  Jim Meyering  <meyering@lucent.com>
23790
23791         * lib/nanosleep.c (SIGCONT): Define if not already defined.
23792
23793 2000-07-01  Jim Meyering  <meyering@lucent.com>
23794
23795         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
23796
23797 2000-07-01  Jim Meyering  <meyering@lucent.com>
23798
23799         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
23800         problem.
23801
23802 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23803
23804         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
23805         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
23806
23807 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
23808
23809         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
23810         per change in ../m4/ls-mntd-fs.m4.
23811         (read_filesystem_list): Ignore symbolic links.
23812
23813 2000-06-29  Jim Meyering  <meyering@lucent.com>
23814
23815         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
23816         for declaration of strcmp.
23817
23818         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
23819
23820         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
23821         Avoid warning by casting result to `char *' to remove `const'.
23822
23823 2000-06-28  Jim Meyering  <meyering@lucent.com>
23824
23825         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
23826         included by quotearg.c, for which we perform this test.  From
23827         Bruno Haible.
23828
23829 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23830
23831         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
23832         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
23833         <utmpx.h> exists, put readutmp.o into LIBOBJS.
23834
23835 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
23836
23837         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
23838
23839 2000-06-26  Paul Eggert  <eggert@twinsun.com>
23840
23841         savedir now sets errno on failure and invokes xmalloc to get memory.
23842         Fix a couple of other minor bugs while we're at it.
23843
23844         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
23845         (NAMLEN): Remove macro.
23846         (malloc, realloc): Remove decls.
23847         (stpcpy): Likewise.
23848         ("xalloc.h"): Include.
23849         (NAME_SIZE_DEFAULT): New macro.
23850         (savedir): Use xmalloc / xrealloc to allocate memory.
23851         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
23852         Skip "" directory entries.
23853         Use strlen to calculate directory entry length, since the old method
23854         is rarely used these days and isn't worth supporting.
23855         Don't use a pointer after freeing it.
23856         Check for integer overflow when calculating allocation size.
23857         Use memcpy to copy entries, instead of stpcpy.
23858         Set errno properly when returning NULL.
23859         Check for readdir error.
23860
23861 2000-06-26  Jim Meyering  <meyering@lucent.com>
23862
23863         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
23864
23865 2000-06-25  Jim Meyering  <meyering@lucent.com>
23866
23867         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
23868         Linux header bug when _XOPEN_SOURCE is defined to 500.
23869
23870 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23871
23872         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
23873         deficiency.
23874
23875 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
23876
23877         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
23878         Include xalloc.h.
23879         Don't include <stdlib.h>.  Don't declare malloc, realloc.
23880
23881 2000-06-24  Jim Meyering  <meyering@lucent.com>
23882
23883         * m4/strerror_r.m4: Revive this file -- to try out an experimental
23884         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
23885         for which strerror does return char*, but which lacks a conveniently
23886         accessible declaration of the function.  If the compile-test says
23887         strerror_r doesn't work, then resort to a `run'-test that works on
23888         BeOS and segfaults on DEC Unix.
23889
23890 2000-06-24  Jim Meyering  <meyering@lucent.com>
23891
23892         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
23893
23894 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23895
23896         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
23897         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
23898
23899 2000-06-23  Paul Eggert  <eggert@twinsun.com>
23900
23901         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
23902         (mbrtowc, mbstate_t): Define substitutes if
23903         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
23904         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
23905         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
23906
23907 2000-06-23  Jim Meyering  <meyering@lucent.com>
23908
23909         * m4/afs.m4: Add missing AC_MSG_RESULT.
23910         Reported by Bruno Haible.
23911
23912         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
23913         Suggestion from Bruno Haible.
23914
23915 2000-06-23  Jim Meyering  <meyering@lucent.com>
23916
23917         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
23918
23919 2000-06-21  Jim Meyering  <meyering@lucent.com>
23920
23921         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
23922
23923 2000-06-21  Jim Meyering  <meyering@lucent.com>
23924
23925         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
23926         (noinst_HEADERS): Add getstr.h.
23927
23928         * lib/getline.c (getstr): Move into a separate file.
23929         * lib/getstr.c (getstr): New file, extracted from getline.c, with
23930         the following changes: new parameter, delim2; both delim[12]
23931         parameters have type `int', not `char'.  The latter would lose
23932         with 8-bit delimiters.
23933         * lib/getstr.h: New file.
23934
23935 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23936
23937         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
23938         than 1024, return a memory chunk of least possible size, instead
23939         of size PATH_MAX + 2. In the loop, increment the size proportionally.
23940         Use free/xmalloc instead of xrealloc to avoid copying for very long
23941         paths.
23942
23943 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23944
23945         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
23946         the empty string.
23947
23948 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
23949
23950         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
23951         address, not strdup.  Include <stdlib.h> and don't declare free().
23952
23953 2000-06-19  Jim Meyering  <meyering@lucent.com>
23954
23955         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
23956
23957 2000-06-18  Jim Meyering  <meyering@lucent.com>
23958
23959         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
23960
23961         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
23962         `checking whether...' message to be consistent with that of the
23963         lstat test.
23964
23965 2000-06-18  Jim Meyering  <meyering@lucent.com>
23966
23967         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
23968         Besides, these days every porting target provides a mkdir function.
23969
23970         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
23971         needed. (this snippet comes from src/system.h).
23972
23973 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
23974
23975         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
23976
23977 2000-06-15  Paul Eggert  <eggert@twinsun.com>
23978
23979         * lib/human.c (adjust_value): New function.
23980         (human_readable_inexact): Apply rounding style even when
23981         printing approximate values.
23982
23983 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23984
23985         * lib/human.c (human_readable_inexact): Allow an input block
23986         size that is not a multiple of the output block size, and vice versa.
23987         Reported by Piergiorgio Sartor.
23988
23989 2000-06-14  Paul Eggert  <eggert@twinsun.com>
23990
23991         * lib/getdate.y (get_date): Apply relative times after time
23992         zone indicator, not before.  Reported by Todd A. Jacobs.
23993
23994 2000-06-13  Jim Meyering  <meyering@lucent.com>
23995
23996         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
23997
23998         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
23999
24000 2000-06-12  Paul Eggert  <eggert@twinsun.com>
24001
24002         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
24003
24004 2000-06-12  Jim Meyering  <meyering@lucent.com>
24005
24006         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
24007         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
24008         optional argument.
24009         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
24010         the optional argument, `lib'.
24011
24012 2000-06-08  Jim Meyering  <meyering@lucent.com>
24013
24014         * m4/largefile.m4: Remove file (now that it's part of autoconf).
24015
24016 2000-06-04  Paul Eggert  <eggert@twinsun.com>
24017
24018         Rewrite largefile configuration so that we don't need to run
24019         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
24020         AC_CANONICAL_HOST in configure.in -- jmm]
24021
24022         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
24023         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
24024         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
24025         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
24026         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
24027         All uses changed.
24028         Instead of inspecting the output of getconf, try to compile the
24029         test program without and with the macro definition.
24030         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
24031         for getconf.  Instead, check for the needed flags by compiling
24032         test programs.
24033
24034 2000-06-04  Paul Eggert  <eggert@twinsun.com>
24035
24036         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
24037
24038 2000-06-04  Jim Meyering  <meyering@lucent.com>
24039
24040         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
24041         SunOS 4.1.4 for which gid_t is an unsigned type.
24042
24043 2000-06-03  Jim Meyering  <meyering@lucent.com>
24044
24045         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
24046         now that autoconf requires that.
24047
24048         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
24049         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
24050         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
24051
24052 2000-06-03  Jim Meyering  <meyering@lucent.com>
24053
24054         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
24055
24056 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
24057
24058         * m4/glibc21.m4: New file.
24059         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
24060
24061 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
24062
24063         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
24064         newer, don't install charset.alias.
24065         * lib/config.charset: Change the Linux/glibc rules so they become empty
24066         on glibc-2.1 or newer.
24067
24068 2000-06-02  Jim Meyering  <meyering@lucent.com>
24069
24070         * lib/mountlist.c: Back out last change.  Instead, do this...
24071         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
24072         me_dummy member using the same `ignore'-testing code.
24073         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
24074         fs_type strings.
24075         From Mark D. Roth.
24076
24077 2000-05-29  Jim Meyering  <meyering@lucent.com>
24078
24079         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
24080         mounts with the `ignore' attribute.  Based on a patch from
24081         Mark D. Roth.
24082
24083 2000-05-28  Jim Meyering  <meyering@lucent.com>
24084
24085         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
24086         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24087         * m4/stat.m4: Likewise.
24088         * m4/lstat.m4: Likewise.
24089         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
24090
24091         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
24092         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
24093
24094 2000-05-26  Jim Meyering  <meyering@lucent.com>
24095
24096         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
24097
24098 2000-05-24  Jim Meyering  <meyering@lucent.com>
24099
24100         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
24101         autoconf requires that.
24102         * m4/lib-check.m4: Likewise.
24103         * m4/jm-macros.m4: Likewise.
24104         * m4/strftime.m4: Likewise.
24105
24106         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
24107         AC_CHECK_DECLS, now that autoconf requires that.
24108
24109 2000-05-22  Jim Meyering  <meyering@lucent.com>
24110
24111         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24112         * m4/lstat.m4: Likewise.
24113
24114 2000-05-22  Jim Meyering  <meyering@lucent.com>
24115
24116         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
24117
24118 2000-05-20  Jim Meyering  <meyering@lucent.com>
24119
24120         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
24121         (jm_PREREQ): Use it.
24122
24123 2000-05-18  Jim Meyering  <meyering@lucent.com>
24124
24125         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
24126         back, too, since it may have been modified by allocate_entry.
24127         (hash_delete): Rewrite to use neither the assignment operator
24128         nor the comma operator in an if-expression.
24129
24130 2000-05-15  Paul Eggert  <eggert@twinsun.com>
24131
24132         * lib/closeout.c:
24133         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
24134         Remove; no longer needed.
24135         "quotearg.h": Add include.
24136         (file_name): Do not bother to explicitly initialize to NULL; it's less
24137         efficient on some hosts.
24138         (close_stdout_status): Remove test as to whether stdout was already
24139         closed; it breaks for the case "echo x | sort >&-".
24140         Quote file name colons.
24141         Do not assume that _("write error") lacks format strings.
24142
24143 2000-05-15  Jim Meyering  <meyering@lucent.com>
24144
24145         * lib/version-etc.c (version_etc_copyright): Update the copyright
24146         string used in all --version output.
24147
24148 2000-05-14  Jim Meyering  <meyering@lucent.com>
24149
24150         * lib/closeout.c (close_stdout_set_file_name): New function.
24151         (close_stdout_status): Use new file-scoped global.
24152         Return right away if fstat says the stdout file descriptor is invalid.
24153         * lib/closeout.h (close_stdout_set_file_name): Declare.
24154
24155 2000-05-10  Jim Meyering  <meyering@lucent.com>
24156
24157         * lib/closeout.c [default_exit_status]: New file-scoped variable.
24158         (close_stdout_set_status): New function.
24159         * lib/closeout.h (close_stdout_set_status): Declare.
24160
24161 2000-05-09  Jim Meyering  <meyering@lucent.com>
24162
24163         * m4/gettext.m4: Rename this...
24164         * m4/libintl.m4: ...to this.
24165
24166 2000-05-08  Jim Meyering  <meyering@lucent.com>
24167
24168         * lib/long-options.c: Don't include closeout.h.
24169         (parse_long_options): Don't call close_stdout for --version.
24170
24171 2000-05-06  Paul Eggert  <eggert@twinsun.com>
24172
24173         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
24174         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
24175         2.1.3 bug.  This avoids a clash when files like regex.c define
24176         _GNU_SOURCE.
24177
24178 2000-05-06  Jim Meyering  <meyering@lucent.com>
24179
24180         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
24181         (AC_REPLACE_FUNCS): Add strnlen.
24182
24183         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
24184         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
24185
24186         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
24187         AC_SEARCH_LIBS call for nanosleep.
24188         (LIB_NANOSLEEP): Set and AC_SUBST.
24189
24190 2000-05-06  Jim Meyering  <meyering@lucent.com>
24191
24192         * lib/strnlen.c: Undefine __strnlen and strnlen.
24193         [!weak_alias]: Define __strnlen to strnlen.
24194
24195         * lib/atexit.c: New file, from libiberty.
24196
24197 2000-05-06  Jim Meyering  <meyering@lucent.com>
24198
24199         * lib/closeout.c (close_stdout_status): Also check for errors on the
24200         stderr stream.
24201
24202 2000-05-05  Jim Meyering  <meyering@lucent.com>
24203
24204         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
24205         AC_SEARCH_LIBS call for clock_gettime.
24206         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
24207
24208         * m4/search-libs.m4: Update from autoconf.
24209
24210         su doesn't work on Solaris 2.6.
24211         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
24212         <shadow.h>.  Reported by Dragos Harabor.
24213
24214 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
24215
24216         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
24217         memcpy instead of xmalloc, xrealloc, path_concat.
24218         (locale_charset): Treat empty environment variables as absent.
24219         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
24220
24221 2000-05-04  Jim Meyering  <meyering@lucent.com>
24222
24223         * lib/getopt.c: Update from glibc.
24224         * lib/obstack.c: Likewise.
24225         * lib/obstack.h: Likewise.
24226         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
24227         file
24228
24229         * lib/regex.h: Likewise.
24230         * lib/strndup.c: Likewise.
24231         * lib/strnlen.c: New file, from glibc.
24232
24233 2000-05-03  Jim Meyering  <meyering@lucent.com>
24234
24235         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
24236
24237 2000-05-02  Paul Eggert  <eggert@twinsun.com>
24238
24239         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
24240         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
24241         compile-time test, rather than inspecting host and OS, to
24242         decide whether to define _LARGEFILE_SOURCE.
24243
24244 2000-05-01  Jim Meyering  <meyering@lucent.com>
24245
24246         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
24247
24248         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
24249         Based on a patch from Bruno Haible.
24250
24251 2000-05-01  Jim Meyering  <meyering@lucent.com>
24252
24253         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
24254
24255 2000-04-29  Jim Meyering  <meyering@lucent.com>
24256
24257         * lib/path-concat.c: Declare strdup only if it's not defined.
24258         * lib/canon-host.c: Likewise.
24259
24260 2000-04-28  Jim Meyering  <meyering@lucent.com>
24261
24262         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
24263         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
24264         is included first, then limits.h is included by locale.h by libintl.h.
24265         From John David Anglin.
24266
24267 2000-04-25  Jim Meyering  <meyering@lucent.com>
24268
24269         * lib/makepath.c (S_IRWXUGO): Define.
24270         (make_path): Always perform explicit chmod if MODE specifies any
24271         of the `special' permission bits.  Prompted by a bug report against
24272         install from Mate Wierdl and Joost van Baal.
24273
24274 2000-04-18  Jim Meyering  <meyering@lucent.com>
24275
24276         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
24277         (jm_PREREQ): Use it.
24278
24279 2000-04-18  Jim Meyering  <meyering@lucent.com>
24280
24281         * lib/README: New file.
24282
24283         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
24284         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
24285
24286 2000-04-17  Jim Meyering  <meyering@lucent.com>
24287
24288         Get it right :-)
24289         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
24290         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
24291         Suggestion from Akim Demaille.
24292
24293 2000-04-17  Jim Meyering  <meyering@lucent.com>
24294
24295         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
24296         the definition of it to rpl_strftime also defined-away the system's
24297         declaration.
24298
24299 2000-04-15  Jim Meyering  <meyering@lucent.com>
24300
24301         Use `C' to denote so-called `contiguous' files, the same way
24302         that tar does.
24303         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
24304         (ftypelet): Use S_ISCTG.
24305         From Michael Deutschmann.
24306
24307 2000-04-14  Jim Meyering  <meyering@lucent.com>
24308
24309         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
24310         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
24311         clobbered.
24312
24313 2000-04-14  Jim Meyering  <meyering@lucent.com>
24314
24315         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
24316
24317 2000-04-13  Jim Meyering  <meyering@lucent.com>
24318
24319         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
24320         AH_VERBATIM to insert required #ifndef into config.h.in.
24321         Suggestion from Akim Demaille.
24322
24323 2000-04-12  Jim Meyering  <meyering@lucent.com>
24324
24325         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
24326         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
24327         Christian Krackowizer.
24328
24329         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
24330         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
24331         (AC_SYS_LARGEFILE): Require.
24332         (AM_C_PROTOTYPES): Require.
24333
24334 2000-04-08  Jim Meyering  <meyering@lucent.com>
24335
24336         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
24337         names don't conflict.  Reported by Eli Zaretskii.
24338
24339 2000-04-07  Jim Meyering  <meyering@lucent.com>
24340
24341         * lib/putenv.c: Move inclusion of errno.h so it follows that of
24342         sys/types.h, to work around system header problems on AIX 3.2.5.
24343         From Bruno Haible.
24344
24345 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
24346
24347         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
24348         bug.  Deal with the different error behavior of Irix iconv.
24349
24350 2000-04-05  Paul Eggert  <eggert@twinsun.com>
24351
24352         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
24353         IRIX if the installer said otherwise.
24354
24355 2000-04-05  Jim Meyering  <meyering@lucent.com>
24356
24357         Portability tweaks required for ultrix4.3.
24358         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
24359         (jm_CHECK_DECLS): Add getutent to the list of functions.
24360         (_jm_DECL_HEADERS): Add utmpx.h.
24361         From John David Anglin.
24362
24363         * m4/strftime.m4: Back out the 2000-04-02 change.
24364         Instead of that change, simply undefine putenv in the test program.
24365
24366 2000-04-05  Jim Meyering  <meyering@lucent.com>
24367
24368         Portability tweaks required for ultrix4.3.
24369         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
24370         getutent.
24371         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
24372         * lib/canon-host.c: Declare strdup.
24373         * lib/path-concat.c: Likewise.
24374         From John David Anglin.
24375
24376 2000-04-04  Jim Meyering  <meyering@lucent.com>
24377
24378         Be more DOS 8.3-friendly.
24379         * lib/ref-add.sin: Renamed from ref-add.sed.in.
24380         * lib/ref-del.sin: Renamed from ref-del.sed.in.
24381         * lib/Makefile.am: Reflect renaming.
24382         Reported by Eli Zaretskii.
24383
24384         Use a temporary file name that won't clash with `charset.alias'
24385         in the DOS 8.3 name space.
24386         * lib/Makefile.am (charset_tmp): Define.
24387         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
24388         (uninstall-local): Likewise.
24389         Reported by Eli Zaretskii.
24390
24391 2000-04-03  Jim Meyering  <meyering@lucent.com>
24392
24393         * m4/gettext.m4: Fix typo in comment.
24394
24395         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
24396         textutils/configure.in).  Suggestion from Paul Eggert.
24397         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
24398
24399 2000-04-02  Paul Eggert  <eggert@twinsun.com>
24400
24401         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
24402         variable in the shell rather than using putenv, which isn't
24403         portable.  This avoids the configure-time inter-test dependency
24404         on the potentially-renamed putenv function.
24405
24406 2000-03-30  Paul Eggert  <eggert@twinsun.com>
24407
24408         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
24409         before checking struct stat.st_blksize, so that
24410         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
24411
24412 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24413
24414         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
24415         since strftime.c uses HAVE_STRFTIME to decide whether to use
24416         the underlying strftime.
24417
24418 2000-03-29  Paul Eggert  <eggert@twinsun.com>
24419
24420         * lib/time/strftime.c (my_strftime): Make sure we call the system
24421         strftime, not ourselves, when invoking the underlying strftime.
24422
24423 2000-03-24  Jim Meyering  <meyering@lucent.com>
24424
24425         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
24426         (charset_alias): Define.
24427         (install-exec-local): Factor out common code.
24428         (uninstall-local): Split lines longer than 80.
24429         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
24430         (SUFFIXES): Define.
24431         (.sed.in.sed): New rule.  Don't redirect directly to $@.
24432         (CLEANFILES): Add ref-add.sed and ref-del.sed.
24433
24434 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
24435
24436         * lib/config.charset: Output a line containing "Packages using this
24437         file".
24438         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
24439         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
24440         ref-del.sed): New rules.
24441
24442 2000-03-17  Jim Meyering  <meyering@lucent.com>
24443
24444         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
24445         Otherwise, include <strings.h>
24446
24447 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
24448
24449         * lib/unicodeio.c (utf8_wctomb): New function.
24450         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
24451         format instead of in UCS-4 with platform dependent endianness.
24452
24453 2000-03-10  Jim Meyering  <meyering@lucent.com>
24454
24455         * m4/lib-check.m4: Look for getspnam in -lgen, too.
24456         From Marco Franzen.
24457
24458 2000-03-07  Paul Eggert  <eggert@twinsun.com>
24459
24460         * lib/savedir.c (savedir): Work even if directory size is
24461         negative; this can happen with some screwy NFS configurations.
24462
24463 2000-03-06  Jim Meyering  <meyering@lucent.com>
24464
24465         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
24466         if it's NULL (because we ran out of memory).  From Bruno Haible.
24467
24468 2000-03-05  Jim Meyering  <meyering@lucent.com>
24469
24470         * lib/localcharset.c ("path-concat.h"): Include.
24471         (get_charset_aliases): Use path_concat instead of ANSI string
24472         concatenation.
24473
24474         * lib/unicodeio.h (PARAMS): Define.
24475         Use it to guard prototype.
24476
24477 2000-03-04  Jim Meyering  <meyering@lucent.com>
24478
24479         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
24480         for lib/localcharset.c.
24481
24482 2000-03-04  Jim Meyering  <meyering@lucent.com>
24483
24484         * lib/Makefile.am (install-exec-local): Create $(libdir) before
24485         installing into it.
24486         (uninstall-local): Uncomment this rule so `make distcheck' works
24487         once again.
24488
24489         * lib/unicodeio.c (<errno.h>): Include it.
24490         (errno): Declare if not defined.
24491
24492         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
24493
24494         * lib/config.charset: New version, incorporating remarks from a linux
24495         i18n mailing list.  From Bruno Haible.
24496
24497 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
24498
24499         * m4/codeset.m4: New file.
24500         * m4/iconv.m4: New file.
24501         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
24502
24503 2000-03-03  Jim Meyering  <meyering@lucent.com>
24504
24505         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
24506
24507 2000-03-02  Jim Meyering  <meyering@lucent.com>
24508
24509         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
24510         the messages come out on separate lines.
24511
24512         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
24513         rather than jm_CHECK_DECLARATIONS.
24514         * m4/decl.m4: Remove now-unused file.
24515
24516         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
24517         geteuid.
24518
24519 2000-03-02  Jim Meyering  <meyering@lucent.com>
24520
24521         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
24522
24523 2000-03-01  Jim Meyering  <meyering@lucent.com>
24524
24525         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
24526         * lib/unicodeio.c: Likewise.
24527
24528 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
24529
24530         * lib/config.charset: New file.
24531         * lib/localcharset.c: New file.
24532         * lib/unicodeio.h, lib/unicodeio.c: New files.
24533         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
24534         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
24535         (noinst_HEADERS): Add unicodeio.h.
24536         (all-local, install-exec-local, charset.alias): New targets.
24537
24538 2000-02-28  Paul Eggert  <eggert@twinsun.com>
24539
24540         * lib/quotearg.c (ALERT_CHAR): New macro.
24541         (quotearg_buffer_restyled): Use it.
24542
24543 2000-02-27  Jim Meyering  <meyering@lucent.com>
24544
24545         * m4/check-decl.m4: Add getenv to the list.
24546
24547 2000-02-27  Jim Meyering  <meyering@lucent.com>
24548
24549         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
24550         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
24551
24552         * lib/backupfile.c: Guard inclusion of stdlib.h with
24553         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
24554         Declare malloc if needed.
24555
24556         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
24557         `#ifndef HAVE_DECL..'
24558         now that autoconf always defines the HAVE_DECL_ symbols.
24559         * lib/human.c: Likewise.
24560         * lib/same.c: Likewise.
24561         * lib/strtoumax.c: Likewise.
24562
24563         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
24564         declaration check was not run.
24565         * lib/hash.c: Likewise.
24566         * lib/human.c: Likewise.
24567         * lib/same.c: Likewise.
24568         * lib/strtoumax.c: Likewise.
24569
24570         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
24571         `.', then first look up the entire `.'-containing string as a login
24572         name.
24573
24574 2000-02-23  Jim Meyering  <meyering@lucent.com>
24575
24576         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
24577         in place of my hack.
24578
24579 2000-02-18  Paul Eggert  <eggert@twinsun.com>
24580
24581         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
24582         (textint): New typedef.
24583         (parser_control): Member year changed from int to textint.
24584         All uses changed.
24585         (YYSTYPE): Removed; replaced by %union with int and textint members.
24586         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
24587         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
24588         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
24589         (tSNUMBER, tUNUMBER): Now of type <textintval>.
24590         (date, number, to_year): Use width of number in digits, not its value,
24591         to determine whether it's a 2-digit year, or a 2-digit time.
24592         (yylex): Store number of digits of numeric tokens.
24593         Reported by John Kendall.
24594
24595         (parser_control): Changed from struct parser_control to typedef (for
24596         consistency).  All uses changed.
24597
24598         (tID): Removed; not used.
24599         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
24600
24601 2000-02-14  Paul Eggert  <eggert@twinsun.com>
24602
24603         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
24604         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
24605
24606 2000-02-12  Jim Meyering  <meyering@lucent.com>
24607
24608         * lib/userspec.c (ISDIGIT): Define it.
24609         (isdigit): Remove definition.
24610         (is_number): Use ISDIGIT, not isdigit.
24611         <libintl.h>: Include.
24612         (_ and N_): Define.
24613         (parse_user_spec): Mark translatable strings.
24614
24615 2000-02-10  Jim Meyering  <meyering@lucent.com>
24616
24617         With these changes, nanosleep.[ch] are finally enough like the other
24618         lib/* replacement files to compile on a few more losing systems.
24619
24620         * lib/nanosleep.h: Don't include config.h.
24621         Remove prototype from declaration of nanosleep.
24622         (PARAMS): Remove now-unneeded definition.
24623         * lib/nanosleep.c: #undef nanosleep.
24624         (rpl_nanosleep): Rename from nanosleep.
24625
24626 2000-02-10  Jim Meyering  <meyering@lucent.com>
24627
24628         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
24629         gnu_nanosleep to rpl_nanosleep.
24630
24631 2000-02-09  Jim Meyering  <meyering@lucent.com>
24632
24633         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
24634         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
24635
24636 2000-02-08  Akim Demaille  <akim@epita.fr>
24637
24638         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
24639         `[' and `]' and remove uses of `changequote'.
24640         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
24641         (AC_SYS_LARGEFILE): Likewise.
24642         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
24643         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
24644         of changequote.
24645         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
24646         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
24647         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
24648         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
24649
24650 2000-02-05  Jim Meyering  <meyering@lucent.com>
24651
24652         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
24653         Remove explicit use of AC_HEADER_TIME.  It is required by
24654         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
24655         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
24656         in autoconf whereby the expansion of the latter ended up preceding
24657         the expansion of its prerequisite, AC_HEADER_TIME.
24658         Reported by Volker Borchert.
24659
24660 2000-02-03  Jim Meyering  <meyering@lucent.com>
24661
24662         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
24663
24664 2000-02-03  Jim Meyering  <meyering@lucent.com>
24665
24666         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
24667         rather than with `#if HAVE_UTMPNAME'.
24668
24669 2000-02-02  Jim Meyering  <meyering@lucent.com>
24670
24671         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
24672         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
24673         Reported by Eli Zaretskii.
24674
24675 2000-02-01  Jim Meyering  <meyering@lucent.com>
24676
24677         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
24678
24679 2000-01-31  Jim Meyering  <meyering@lucent.com>
24680
24681         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
24682         functions.  Add the time.h and sys/time.h headers along with the
24683         AC_REQUIRE'ment of AC_HEADER_TIME.
24684
24685 2000-01-31  Jim Meyering  <meyering@lucent.com>
24686
24687         * lib/nanosleep.h (nanosleep): Guard declaration with
24688         `#if ! HAVE_DECL_NANOSLEEP'.
24689         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
24690         the declaration in that vendor's sys/timers.h.
24691         Reported by Christian Krackowizer.
24692
24693         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
24694         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
24695         (ISPRINT): Likewise.
24696         Reported by Tom Tromey.
24697
24698 2000-01-30  Jim Meyering  <meyering@lucent.com>
24699
24700         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
24701
24702         * m4/prereq.m4 (utmp_includes): Define.
24703         Check for ut_user and ut_name members in both struct utmpx
24704         and struct utmp.
24705
24706 2000-01-30  Jim Meyering  <meyering@lucent.com>
24707
24708         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
24709         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
24710         header files where only utmpx.ut_user is declared.
24711
24712         * lib/readutmp.h (UT_USER): Define.
24713
24714 2000-01-29  Jim Meyering  <meyering@lucent.com>
24715
24716         * m4/lib-check.m4: New file containing library-related checks from
24717         fileutils and sh-utils (textutils had none).
24718
24719 2000-01-28  Jim Meyering  <meyering@lucent.com>
24720
24721         * m4/perl.m4: Change format of warning message to look more like that
24722         from the missing script.  Suggestion from François Pinard.
24723
24724 2000-01-25  Jim Meyering  <meyering@lucent.com>
24725
24726         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
24727         well as time.h in the compile check.
24728         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
24729         Fix typo in cross-compiling case: s/yes/no/.
24730
24731 2000-01-23  Jim Meyering  <meyering@lucent.com>
24732
24733         * m4/jm-macros.m4: Move df-related tests here from
24734         fileutils/configure.in
24735
24736         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
24737         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
24738
24739         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
24740         s/space/ac_fsusage_space/.
24741         (jm_FILE_SYSTEM_USAGE): Take two parameters.
24742
24743         * m4/ftruncate.m4: New file (derived from part of
24744         fileutils/configure.in).
24745         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
24746         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
24747
24748         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
24749         AC_SUBST these here, rather than just in sh-util/configure.in, so
24750         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
24751         all the same.
24752         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
24753         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
24754         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
24755         (AC_SUBST(POW_LIBM)): Likewise.
24756         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
24757
24758 2000-01-23  Jim Meyering  <meyering@lucent.com>
24759
24760         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
24761         obstack.c.
24762
24763 2000-01-22  Jim Meyering  <meyering@lucent.com>
24764
24765         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
24766
24767         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
24768
24769         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
24770         configure.in
24771         (AC_CHECK_HEADERS): Likewise for sh-utils.
24772         (AC_CHECK_HEADERS): Likewise for textutils.
24773         Merge the three lists of headers.
24774
24775         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
24776         from fileutils' configure.in.
24777
24778         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
24779         code. Moved tests into their own function (_jm_DECL_HEADERS) in
24780         check-decl.m4.
24781
24782         * m4/check-decl.m4: Use #if rather than #ifdef.
24783         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
24784         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
24785         (_jm_DECL_HEADERS): Define new function.
24786         (jm_CHECK_DECLARATIONS): Require it.
24787
24788 2000-01-22  Jim Meyering  <meyering@lucent.com>
24789
24790         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
24791         [! HAVE_DECL_STRTOULL]: Declare strtoull.
24792         Required for some AIX systems.  Reported by Christian Krackowizer.
24793         [TESTING] (main): New function.
24794
24795         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
24796         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
24797         letters.
24798
24799         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
24800         iswprint.
24801
24802         * lib/strverscmp.c (ISDIGIT): Define.
24803         (strverscmp): Use ISDIGIT, not isdigit.
24804
24805 2000-01-19  Jim Meyering  <meyering@lucent.com>
24806
24807         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
24808         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
24809         defines `struct timespec' in <sys/time.h>
24810
24811         * m4/c-bs-a.m4: Remove uses of changequote altogether.
24812         Thanks to Akim for explaining.
24813
24814 2000-01-17  Paul Eggert  <eggert@twinsun.com>
24815
24816         * lib/nanosleep.c (nanosleep):
24817         Don't use SA_INTERRUPT to decide whether to call sigaction, as
24818         POSIX.1 doesn't require SA_INTERRUPT and some systems
24819         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
24820         it's been part of POSIX.1 since day 1 (in 1988).
24821
24822 2000-01-17  Jim Meyering  <meyering@lucent.com>
24823
24824         * lib/interlock: Remove unused file.  Reported by François Pinard.
24825
24826 2000-01-16  Paul Eggert  <eggert@twinsun.com>
24827
24828         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
24829         alert, backslash, formfeed, and vertical tab unnecessarily in
24830         shell quoting style.
24831
24832 2000-01-16  Jim Meyering  <meyering@lucent.com>
24833
24834         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
24835         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
24836         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
24837         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
24838
24839 2000-01-16  Jim Meyering  <meyering@lucent.com>
24840
24841         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
24842         because the latter didn't work.
24843
24844 2000-01-15  Jim Meyering  <meyering@lucent.com>
24845
24846         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
24847         (AC_REPLACE_FUNCS): Add memcpy and memset.
24848         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
24849         Add strpbrk.
24850         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
24851
24852 2000-01-12  Jim Meyering  <meyering@lucent.com>
24853
24854         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
24855         (jm_PREREQ): Use it.
24856         (jm_PREREQ_READUTMP): New macro.
24857         (jm_PREREQ): Use it.
24858
24859 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24860
24861         Quote multibyte characters correctly.
24862         * m4/c-bs-a.m4: New file.
24863         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
24864         (jm_PREREQ): Use it.
24865
24866 2000-01-11  Paul Eggert  <eggert@twinsun.com>
24867
24868         * m4/uintmax_t.m4: Port to autoconf 2.13.
24869
24870 2000-01-08  Jim Meyering  <meyering@ascend.com>
24871
24872         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
24873         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
24874
24875 2000-01-04  Jim Meyering  <meyering@ascend.com>
24876
24877         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
24878         jm_STRUCT_DIRENT_D_TYPE.
24879         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
24880         jm_STRUCT_DIRENT_D_INO.
24881         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
24882         jm_STRUCT_UTIMBUF.
24883         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
24884         renamings.
24885         * m4/utime.m4: Likewise.
24886
24887         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
24888         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
24889
24890 2000-01-03  Paul Eggert  <eggert@twinsun.com>
24891
24892         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
24893         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
24894
24895 2000-01-02  Jim Meyering  <meyering@ascend.com>
24896
24897         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
24898         remember if this is necessary.
24899
24900 1999-12-26  Jim Meyering  <meyering@ascend.com>
24901
24902         * m4/jm-macros.m4: Use it here.
24903         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
24904
24905 1999-12-23  Jim Meyering  <meyering@ascend.com>
24906
24907         * m4/jm-macros.m4: Check for clock_gettime (moved from
24908         fileutils/configure.in)
24909         Check for gettimeofday.
24910
24911 1999-12-20  Jim Meyering  <meyering@ascend.com>
24912
24913         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
24914         autoconf-2.14a-1999-12-20.
24915
24916 1999-12-19  Jim Meyering  <meyering@ascend.com>
24917
24918         * m4/lstat-slash.m4: New file.
24919         * m4/jm-macros.m4: Use the new macro:
24920         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
24921
24922 1999-12-07  Jim Meyering  <meyering@ascend.com>
24923
24924         * m4/perl.m4: Require that File::Compare be available, too.
24925         Too many systems seem to lack it.
24926
24927         * m4/strftime.m4: Add checks for most of the cpp macros tested in
24928         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
24929
24930 1999-11-18  Paul Eggert  <eggert@twinsun.com>
24931
24932         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
24933         problem with the QNX 4.25 shell, which doesn't propagate exit
24934         status of failed commands inside shell assignments.
24935
24936 1999-11-17  Jim Meyering  <meyering@ascend.com>
24937
24938         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
24939
24940 1999-11-07  Jim Meyering  <meyering@ascend.com>
24941
24942         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
24943
24944 1999-11-06  Jim Meyering  <meyering@ascend.com>
24945
24946         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
24947         * m4/jm-macros.m4 (jm_MACROS): Use it here.
24948
24949 1999-11-05  Jim Meyering  <meyering@ascend.com>
24950
24951         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
24952         configure.in of textutils, fileutils, and sh-utils into this one
24953         (shared between those packages) file.
24954         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
24955         AC_STRUCT_ST_BLKSIZE.
24956
24957 1999-11-03  Jim Meyering  <meyering@ascend.com>
24958
24959         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
24960         of AC_CHECK_TYPE checks includes unistd.h.
24961         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
24962         Suggestion from Akim Demaille.
24963
24964 1999-10-30  Jim Meyering  <meyering@ascend.com>
24965
24966         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
24967         m4-quoted string.
24968         * m4/ls-mntd-fs.m4: Likewise.
24969         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
24970         * m4/jm-winsz1.m4: Likewise.
24971
24972         * m4/const.m4: Remove file, since the fix made it into the experimental
24973         version of autoconf.
24974         * m4/mktime.m4: Likewise.
24975
24976         * m4/check-type.m4: Remove file, now that the latest version of
24977         AC_CHECK_TYPE takes a third arg to specify additional #includes.
24978
24979         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
24980         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
24981         AC_CHECK_TYPE.
24982
24983 1999-10-04  Jim Meyering  <meyering@ascend.com>
24984
24985         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
24986
24987 1999-09-22  Paul Eggert  <eggert@twinsun.com>
24988
24989         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
24990         2.95.1 bug with HP-UX 10.20.
24991
24992 1999-09-17  Jim Meyering  <meyering@ascend.com>
24993
24994         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
24995         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
24996         due to missing strdup (against sh-utils-2.0).
24997
24998 1999-08-29  Jim Meyering  <meyering@ascend.com>
24999
25000         * m4/jm-macros.m4: Require jm_BISON.
25001         * m4/bison.m4: New file.
25002
25003 1999-08-17  Paul Eggert  <eggert@twinsun.com>
25004
25005         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
25006         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
25007
25008 1999-08-05  Jim Meyering  <meyering@ascend.com>
25009
25010         * m4/getline.m4: Rename test file from conftestdata to conftest.data
25011         to avoid conflicts with `conftest' on 8+3 filesystems.
25012         Suggestion from Eli Zaretskii.
25013
25014 1999-08-04  Jim Meyering  <meyering@ascend.com>
25015
25016         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
25017         fileutils and sh-utils (textutils's getline test was inadequate).
25018         (AM_FUNC_GETLINE): Run this test.
25019         (AC_CHECK_FUNCS): Check for getdelim.
25020         Reported by Bob Proulx.
25021
25022 1999-08-02  Jim Meyering  <meyering@ascend.com>
25023
25024         * m4/jm-macros.m4: Add a comment.
25025
25026 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25027
25028         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
25029         <inttypes.h> defines strtoumax as a macro (and not as a
25030         function).
25031
25032 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25033
25034         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
25035         that we can shift, multiply and divide unsigned long long
25036         values; Ultrix cc can't do it.
25037
25038 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25039
25040         * m4/mktime.m4: New file, which is a preview of what should appear
25041         in the next public autoconf release.
25042
25043 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25044
25045         * m4/lfs.m4: Remove this file.
25046         * m4/largefile.m4: New file.  It contains the old contents of
25047         lfs.m4, except that all names with prefix AC_LFS have been
25048         changed to use the prefix AC_SYS_LARGEFILE instead, to be
25049         compatible with future autoconf versions.  Also, some minor m4
25050         quoting problems have been fixed.
25051
25052 1999-08-01  Paul Eggert  <eggert@twinsun.com>
25053
25054         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
25055         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
25056         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
25057         and simplify the shell code.
25058
25059 1999-08-01  Jim Meyering  <meyering@ascend.com>
25060
25061         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
25062         m4.
25063
25064 1999-07-20  Jim Meyering  <meyering@ascend.com>
25065
25066         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
25067
25068 1999-07-15  Jim Meyering  <meyering@ascend.com>
25069
25070         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
25071
25072 1999-05-22  Jim Meyering  <meyering@ascend.com>
25073
25074         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
25075
25076 1999-05-20  Jim Meyering  <meyering@ascend.com>
25077
25078         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
25079         Add a colon after each `then' in case $4 is empty.
25080
25081 1999-05-16  Jim Meyering  <meyering@ascend.com>
25082
25083         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
25084
25085 1999-05-10  Jim Meyering  <meyering@ascend.com>
25086
25087         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
25088
25089         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
25090         AC_FUNC_MKTIME.
25091
25092 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
25093
25094         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
25095
25096 1999-05-04  Paul Eggert  <eggert@twinsun.com>
25097
25098         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
25099         not CPPFLAGS, so that linking works correctly in IRIX.
25100
25101 1999-04-30  Paul Eggert  <eggert@twinsun.com>
25102
25103         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
25104
25105 1999-04-20  Paul Eggert  <eggert@twinsun.com>
25106
25107         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
25108         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
25109         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
25110         jm_AC_TYPE_UNSIGNED_LONG_LONG.
25111         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
25112
25113         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
25114
25115 1999-04-20  Jim Meyering  <meyering@ascend.com>
25116
25117         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
25118         AC_REPLACE xstroull if necessary.  From Paul Eggert.
25119         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
25120
25121 1999-04-18  Jim Meyering  <meyering@ascend.com>
25122
25123         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
25124         * m4/jm-macros.m4: Use it.
25125
25126 1999-04-06  Jim Meyering  <meyering@ascend.com>
25127
25128         * m4/strftime.m4: Remove test for %f.
25129
25130 1999-03-29  Jim Meyering  <meyering@ascend.com>
25131
25132         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
25133         superset of the AC_TYPE_* checks in the textutils, fileutils,
25134         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
25135         AC_TYPE_PID_T.
25136
25137 1999-03-28  Jim Meyering  <meyering@ascend.com>
25138
25139         * m4/jm-macros.m4: Define GNU_PACKAGE here.
25140         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
25141         replaced e.g., in the *.sh files of the sh-utils.
25142
25143 1999-03-20  Jim Meyering  <meyering@ascend.com>
25144
25145         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
25146         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
25147         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
25148
25149 1999-03-19  Jim Meyering  <meyering@ascend.com>
25150
25151         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
25152
25153 1999-03-12  Jim Meyering  <meyering@ascend.com>
25154
25155         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
25156
25157 1999-03-07  Jim Meyering  <meyering@ascend.com>
25158
25159         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
25160         declared.
25161
25162 1999-02-17  Jim Meyering  <meyering@ascend.com>
25163
25164         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
25165         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
25166
25167 1999-02-07  Jim Meyering  <meyering@ascend.com>
25168
25169         * m4/group-member.m4: New file -- extracted from sh-utils'
25170         configure.in.
25171
25172         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
25173         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
25174
25175 1999-02-06  Jim Meyering  <meyering@ascend.com>
25176
25177         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
25178         * m4/fnmatch.m4: Likewise.
25179         * m4/getgroups.m4: Likewise.
25180         * m4/lstat.m4: Likewise.
25181         * m4/malloc.m4: Likewise.
25182         * m4/putenv.m4: Likewise.
25183         * m4/realloc.m4: Likewise.
25184         * m4/regex.m4: Likewise.
25185         * m4/stat.m4: Likewise.
25186         * m4/strftime.m4: Likewise.
25187         Suggestion from Alain Magloire.
25188
25189         * m4/chown.m4: Use `.$ac_objext', not `.o'.
25190         * m4/fnmatch.m4: Likewise.
25191         * m4/getgroups.m4: Likewise.
25192         * m4/getline.m4: Likewise.
25193         * m4/lstat.m4: Likewise.
25194         * m4/malloc.m4: Likewise.
25195         * m4/memcmp.m4: Likewise.
25196         * m4/putenv.m4: Likewise.
25197         * m4/realloc.m4: Likewise.
25198         * m4/regex.m4: Likewise.
25199         * m4/stat.m4: Likewise.
25200         * m4/strftime.m4: Likewise.
25201         Suggestion from Alain Magloire.
25202
25203         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
25204         an argument.
25205
25206         * m4/regex.m4: Add a run-time Test for proper operation of
25207         re_compile_pattern.
25208
25209 1999-01-31  Jim Meyering  <meyering@ascend.com>
25210
25211         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
25212
25213 1999-01-30  Jim Meyering  <meyering@ascend.com>
25214
25215         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
25216
25217         * m4/jm-mktime.m4: Make this a wrapper around the official
25218         AM_FUNC_MKTIME rather than my private copy, now that the official one
25219         is up to date.
25220         * m4/mktime.m4: Remove file.
25221
25222         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
25223         * m4/uptime.m4: Likewise.
25224         * m4/uintmax_t.m4: Likewise.
25225
25226 1999-01-28  Jim Meyering  <meyering@ascend.com>
25227
25228         * m4/jm-macros.m4: Use jm_AFS.
25229         * m4/afs.m4: New file (from fileutils' configure.in).
25230
25231         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
25232         * m4/chown.m4: Likewise.
25233         * m4/d-ino.m4: Likewise.
25234         * m4/d-type.m4: Likewise.
25235         * m4/fnmatch.m4: Likewise.
25236         * m4/getgroups.m4: Likewise.
25237         * m4/gettext.m4: Likewise.
25238         * m4/jm-mktime.m4: Likewise.
25239         * m4/jm-winsz2.m4: Likewise.
25240         * m4/lcmessage.m4: Likewise.
25241         * m4/ls-mntd-fs.m4: Likewise.
25242         * m4/malloc.m4: Likewise.
25243         * m4/memcmp.m4: Likewise.
25244         * m4/putenv.m4: Likewise.
25245         * m4/realloc.m4: Likewise.
25246         * m4/st_mtim.m4: Likewise.
25247         * m4/strftime.m4: Likewise.
25248
25249 1999-01-16  Jim Meyering  <meyering@ascend.com>
25250
25251         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
25252         (ARGMATCH_DIE_DECL): Define.
25253
25254 1999-01-12  Jim Meyering  <meyering@ascend.com>
25255
25256         * m4/Makefile.am.in: Rewrite to avoid using fmt.
25257         Reported by Lars Hecking.
25258
25259 1999-01-10  Jim Meyering  <meyering@ascend.com>
25260
25261         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
25262         gross kludge.
25263         * m4/inttypes_h.m4: Likewise.
25264         * m4/lstat.m4: Likewise.
25265         * m4/malloc.m4: Likewise.
25266         * m4/readdir.m4: Likewise.
25267         * m4/realloc.m4: Likewise.
25268         * m4/st_dm_mode.m4: Likewise.
25269         * m4/stat.m4: Likewise.
25270         * m4/utimbuf.m4: Likewise.
25271         * m4/utimes.m4: Likewise.
25272
25273         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
25274         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
25275         comments in config.h.in are meaningful.
25276
25277         * m4/jm-macros.m4: Require autoconf-2.13 here.
25278
25279         * m4/regex.m4: By default, don't use the included regex.c on systems
25280         with glibc 2.  Suggestion from Uli Drepper.
25281
25282 1999-01-02  Jim Meyering  <meyering@ascend.com>
25283
25284         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
25285
25286 1998-12-18  Jim Meyering  <meyering@ascend.com>
25287
25288         * m4/Makefile.am.in (Makefile.am): Simplify rule.
25289         Based on a suggestion from Lars Hecking.
25290
25291 1998-11-16  Paul Eggert  <eggert@twinsun.com>
25292
25293         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
25294
25295 1998-11-16  Jim Meyering  <meyering@ascend.com>
25296
25297         * m4/lfs.m4: Double-quote the `uname...` expression.
25298
25299 1998-11-14  Jim Meyering  <meyering@ascend.com>
25300
25301         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
25302         * m4/stat.m4: Likewise.
25303
25304 1998-11-03  Jim Meyering  <meyering@ascend.com>
25305
25306         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
25307         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
25308
25309 1998-10-18  Jim Meyering  <meyering@ascend.com>
25310
25311         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
25312
25313 1998-10-17  Jim Meyering  <meyering@ascend.com>
25314
25315         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
25316         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
25317         calls for those previously hard-coded headers.  Instead, take a new
25318         parameter.
25319         (jm_CHECK_DECLARATIONS): Reflect interface change.
25320         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
25321         (jm_CHECK_DECL_LOCALTIME_R): New macro.
25322
25323         * m4/mktime.m4: Test for spring-forward gap before long-running test.
25324
25325 1998-10-14  Jim Meyering  <meyering@ascend.com>
25326
25327         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
25328         instead of "TZ=America/Vancouver".  From Paul Eggert.
25329
25330 1998-10-11  Jim Meyering  <meyering@ascend.com>
25331
25332         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
25333         This adds a test for a recently added compatibility fix for mktime.c.
25334         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
25335
25336 1998-09-27  Jim Meyering  <meyering@ascend.com>
25337
25338         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
25339
25340         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
25341         ../configure.in, including a change from Gordon Matzigkeit to allow
25342         cross-compiling for the Hurd.
25343
25344         * m4/glibc.m4: New file/macro to test for the GNU C Library
25345         versions 1 and 2.  From Gordon Matzigkeit.
25346         Indent.
25347
25348 1998-09-21  Jim Meyering  <meyering@ascend.com>
25349
25350         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
25351
25352 1998-08-18  Paul Eggert  <eggert@twinsun.com>
25353
25354         Port nanosecond-resolution times to UnixWare 2.1.2 and
25355         pedantic Solaris 2.6.
25356
25357         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
25358         AC_STRUCT_ST_MTIM.
25359         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
25360         Generate name of ns member, instead of just 1 or undef.
25361         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
25362
25363 1998-08-15  Jim Meyering  <meyering@ascend.com>
25364
25365         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
25366         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
25367         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
25368         instead of jm_TYPE_SSIZE_T.
25369
25370 1998-08-12  Jim Meyering  <meyering@ascend.com>
25371
25372         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
25373
25374 1998-08-02  Jim Meyering  <meyering@ascend.com>
25375
25376         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
25377         in acconfig.h manually.
25378
25379 1998-07-31  Paul Eggert  <eggert@twinsun.com>
25380
25381         * m4/st_mtim.m4: New file.
25382
25383 1998-07-28  Jim Meyering  <meyering@ascend.com>
25384
25385         * m4/utimes.m4: Undef stat.
25386
25387 1998-07-25  Jim Meyering  <meyering@ascend.com>
25388
25389         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
25390         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
25391
25392 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
25393
25394         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
25395         uid and gid actually remain unchanged.
25396
25397 1998-07-07  Jim Meyering  <meyering@ascend.com>
25398
25399         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
25400
25401 1998-07-04  Jim Meyering  <meyering@ascend.com>
25402
25403         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
25404         to prove that this macro can be used in packages without regex.c.
25405
25406 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
25407
25408         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
25409         is to be used.
25410
25411 1998-07-03  Jim Meyering  <meyering@ascend.com>
25412
25413         * m4/gettext.m4: Add -lintl if it's found to be necessary.
25414
25415         * m4/gettext.m4: New file -- from gettext-0.10.35.
25416         * m4/lcmessage.m4: Likewise.
25417         * m4/progtest.m4: Likewise.
25418
25419         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
25420         * m4/jm-macros.m4: Require the new macro.
25421
25422 1998-06-29  Jim Meyering  <meyering@ascend.com>
25423
25424         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
25425         for the definition of NGROUPS (used in a system header included
25426         by sys/mount.h).
25427
25428 1998-06-28  Jim Meyering  <meyering@ascend.com>
25429
25430         * m4/ls-mntd-fs.m4: New file.
25431         * m4/fstypename.m4: New file.
25432
25433         * m4/jm-macros.m4: Require the new macro.
25434         * m4/jm-glibc-io.m4: New file.
25435
25436 1998-05-19  Jim Meyering  <meyering@ascend.com>
25437
25438         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
25439         * m4/lchown.m4: New file.
25440
25441         * m4/Makefile.am.in: New file.
25442         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
25443
25444 1998-05-14  Jim Meyering  <meyering@ascend.com>
25445
25446         * m4/Makefile.am (EXTRA_DIST): Add them.
25447         * m4/jm-macros.m4: New file.
25448         * m4/utimbuf.m4: New file.
25449
25450 1998-05-12  Jim Meyering  <meyering@ascend.com>
25451
25452         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
25453
25454 1998-05-11  Jim Meyering  <meyering@ascend.com>
25455
25456         * m4/isc-posix.m4: New file.
25457
25458 1998-05-10  Jim Meyering  <meyering@ascend.com>
25459
25460         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
25461
25462 1998-05-09  Jim Meyering  <meyering@ascend.com>
25463
25464         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
25465         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
25466         with automake.
25467
25468         * m4/ssize_t.m4: New file.
25469         * m4/mktime.m4: Remove file -- the new automake has this now.
25470
25471 1998-04-26  Jim Meyering  <meyering@ascend.com>
25472
25473         * m4/assert.m4: New file.
25474         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
25475
25476 1998-04-05  Jim Meyering  <meyering@ascend.com>
25477
25478         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
25479         (jm_PREREQ): Use it here.
25480
25481 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
25482
25483         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
25484         in acconfig.h.
25485
25486 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
25487
25488         * m4/prereq.m4: New file.
25489         * m4/error.m4: New file.
25490         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
25491
25492 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
25493
25494         * m4/getline.m4: Don't set am_cv_func_working_getline before the
25495         cache-check for the same variable -- that defeated the purpose of
25496         the test; the test program was never run.  This was a problem only
25497         on systems with losing getline functions -- HP-UX 10.20 is one.
25498         Reported by Bjorn Helgaas.
25499
25500 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
25501
25502         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
25503
25504 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
25505
25506         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
25507
25508         * m4/const.m4: New file.  Use an initializer in this declaration
25509         typedef int charset[2]; const charset x;
25510         Reported by Bob Glickstein.
25511
25512 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
25513
25514         * m4/chown.m4: Fix reversed types on -1 args to chown.
25515         From Kaveh Ghazi.
25516
25517 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
25518
25519         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
25520         Add lseek and memchr.
25521
25522         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
25523         T.E.Dickey <dickey@clark.net> said that some older preprocessors
25524         have a 20-character limit on names.
25525
25526 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
25527
25528         * m4/inttypes_h.m4: New file.
25529         * m4/uintmax_t.m4: New file.
25530         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
25531
25532 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
25533   Free Software Foundation, Inc.
25534 Copying and distribution of this file, with or without modification,
25535 are permitted provided the copyright notice and this notice are preserved.