Ensure AC_C_RESTRICT is invoked.
[gnulib.git] / ChangeLog
1 2007-05-13  Bruno Haible  <bruno@clisp.org>
2
3         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
4         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
5         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
6         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
7         (gl_PREREQ_STRTOK_R): Don't require it here.
8
9 2007-05-13  Bruno Haible  <bruno@clisp.org>
10
11         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
12         when used in C++ mode.
13
14 2007-05-12  Bruno Haible  <bruno@clisp.org>
15
16         * lib/linebuffer.h: Tweak doc.
17         * lib/linebuffer.c: Likewise.
18
19 2007-05-12  James Youngman  <jay@gnu.org>
20
21         * lib/linebuffer.c (readlinebuffer_delim): New function,
22         like readlinebuffer, but use a caller-specified delimiter.
23         (readlinebuffer): Just call readlinebuffer_delim with '\n'
24         as the delimiter.
25         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
26
27 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
28
29         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
30         * modules/openat (Files): Remove openat-die.c.
31         (Depends-on): Add openat-die.
32         * modules/openat-die: New module.
33
34 2007-05-06  Bruno Haible  <bruno@clisp.org>
35
36         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
37         Update with info about Cygwin.
38         * doc/functions/fprintf.texi: Update.
39         * doc/functions/printf.texi: Update.
40         * doc/functions/snprintf.texi: Update.
41         * doc/functions/sprintf.texi: Update.
42         * doc/functions/vfprintf.texi: Update.
43         * doc/functions/vprintf.texi: Update.
44         * doc/functions/vsnprintf.texi: Update.
45         * doc/functions/vsprintf.texi: Update.
46         Reported by Eric Blake.
47
48 2007-05-06  Bruno Haible  <bruno@clisp.org>
49
50         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
51         padding ourselves for the floating-point directives.
52         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
53         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
54         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
55         gl_PRINTF_FLAG_ZERO and test its result. Invoke
56         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
57         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
58         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
59         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
60         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
61         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
62         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
63         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
64         * tests/test-snprintf-posix.h (test_function): Also check the width
65         and some flags in the %f directive.
66         * tests/test-sprintf-posix.h (test_function): Likewise.
67         * tests/test-vasnprintf-posix.c (test_function): Likewise.
68         * tests/test-vasprintf-posix.c (test_function): Likewise.
69         * doc/functions/fprintf.texi: Update.
70         * doc/functions/printf.texi: Update.
71         * doc/functions/snprintf.texi: Update.
72         * doc/functions/sprintf.texi: Update.
73         * doc/functions/vfprintf.texi: Update.
74         * doc/functions/vprintf.texi: Update.
75         * doc/functions/vsnprintf.texi: Update.
76         * doc/functions/vsprintf.texi: Update.
77
78 2007-05-06  Bruno Haible  <bruno@clisp.org>
79
80         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
81         pass the ' flag character to sprintf or snprintf.
82         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
83         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
84         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
85         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
86         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
87         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
88         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
89         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
90         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
91         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
92         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
93         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
94         * tests/test-snprintf-posix.h (test_function): Also check the grouping
95         flag.
96         * tests/test-sprintf-posix.h (test_function): Likewise.
97         * tests/test-vasnprintf-posix.c (test_function): Likewise.
98         * tests/test-vasprintf-posix.c (test_function): Likewise.
99         * doc/functions/fprintf.texi: Update.
100         * doc/functions/printf.texi: Update.
101         * doc/functions/snprintf.texi: Update.
102         * doc/functions/sprintf.texi: Update.
103         * doc/functions/vfprintf.texi: Update.
104         * doc/functions/vprintf.texi: Update.
105         * doc/functions/vsnprintf.texi: Update.
106         * doc/functions/vsprintf.texi: Update.
107
108 2007-05-01  Bruno Haible  <bruno@clisp.org>
109
110         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
111
112 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
113
114         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
115         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
116
117 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
118
119         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
120         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
121         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
122
123 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
124
125         * lib/argp-help.c (struct hol_entry): New member `ord'.
126         (HOL_ENTRY_PTRCMP): Use ord for comparison
127         (hol_sort): Initialize ord.
128
129 2007-05-01  Bruno Haible  <bruno@clisp.org>
130
131         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
132         Reported by Eric Blake.
133         * doc/gnulib.texi (Function Substitutes): Update.
134
135 2007-05-01  Bruno Haible  <bruno@clisp.org>
136
137         * doc/functions.texi: Remove file, now redundant through
138         doc/functions/*.texi.
139
140 2007-05-01  Bruno Haible  <bruno@clisp.org>
141
142         * modules/argp (Depends-on): Add sleep.
143
144 2007-05-01  Bruno Haible  <bruno@clisp.org>
145
146         * modules/sleep-tests: New file.
147         * tests/test-sleep.c: New file.
148
149         * modules/sleep: New file.
150         * lib/sleep.c: New file.
151         * m4/sleep.m4: New file.
152         * lib/unistd_.h (sleep): New declaration.
153         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
154         HAVE_SLEEP.
155         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
156         * doc/functions/sleep.texi: Document the sleep module.
157
158 2007-05-01  Bruno Haible  <bruno@clisp.org>
159
160         * lib/sigprocmask.h: Remove file.
161         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
162         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
163         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
164         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
165         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
166         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
167         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
168         HAVE_SIGSET_T as a shell variable.
169         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
170         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
171         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
172         (Depends-on): Add signal. Remove verify.
173         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
174         (Include): Mention <signal.h> instead of sigprocmask.h.
175         * NEWS: Mention the change.
176         * lib/fatal-signal.c: Don't include sigprocmask.h.
177
178 2007-05-01  Bruno Haible  <bruno@clisp.org>
179
180         * modules/signal: New file.
181         * lib/signal_.h: New file.
182         * m4/signal_h.m4: New file.
183
184 2007-05-01  Bruno Haible  <bruno@clisp.org>
185
186         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
187         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
188         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
189         HAVE_WCTYPE_CTMP_BUG into wctype.h.
190
191 2007-05-01  Bruno Haible  <bruno@clisp.org>
192
193         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
194         configure time.
195         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
196         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
197         * modules/sys_stat (Makefile.am): Substitute their values into
198         sys/stat.h.
199
200 2007-05-01  Bruno Haible  <bruno@clisp.org>
201
202         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
203         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
204         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
205
206 2007-05-01  Bruno Haible  <bruno@clisp.org>
207
208         * doc/header/assert.texi: Undo last change: don't mention the gnulib
209         'assert' module here.
210
211 2007-05-01  Bruno Haible  <bruno@clisp.org>
212
213         * doc/functions/*.texi: New files.
214         * doc/functions/google-ranking.txt: New file.
215         * doc/gnulib.texi (Function Substitutes): New chapter.
216         (ctime, inet_ntoa): Remove sections.
217         * doc/ctime.texi: Remove file.
218         * doc/inet_ntoa.texi: Remove file.
219         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
220         dependencies.
221         (%.info): New rule, specifying a --reference-limit.
222
223 2007-05-01  Bruno Haible  <bruno@clisp.org>
224
225         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
226
227 2007-05-01  Bruno Haible  <bruno@clisp.org>
228
229         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
230         the portability of 'mkdir' to mingw systems.
231
232 2007-05-01  Bruno Haible  <bruno@clisp.org>
233
234         * doc/headers/google-ranking.txt: New file.
235
236 2007-04-30  Eric Blake  <ebb9@byu.net>
237
238         Prefer fseeko to fseek.
239         * modules/getpass (Depends-on): Add fseeko.
240         * lib/getpass.c (getpass): Use fseeko, not fseek.
241
242 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
243
244         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
245         assumes the sorting is stable, while most qsort implementations
246         are not.  Use argument addresses to ensure they never compare as
247         equal.
248
249         * tests/test-argp-2.sh (usage-indent test): Fix output
250         (func_compare): Restore diff options
251         * tests/test-argp.c: Restore #include "progname.h"
252
253 2007-04-29  Bruno Haible  <bruno@clisp.org>
254
255         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
256         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
257         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
258         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
259         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
260         (configure.ac): Define CHECK_SNPRINTF_POSIX.
261         (TESTS, check_PROGRAMS): Add test-snprintf.
262         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
263         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
264         (TESTS, check_PROGRAMS): Add test-vsnprintf.
265         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
266         assertions that fail on HP-UX, OSF/1, or IRIX.
267         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
268
269 2007-04-29  Bruno Haible  <bruno@clisp.org>
270
271         * MODULES.html.sh (posix_functions): Remove 'contents'.
272
273 2007-04-29  Karl Berry  <karl@gnu.org>
274
275         * config/srclist.txt (gendocs_template_min): new entry.
276
277 2007-04-29  Bruno Haible  <bruno@clisp.org>
278
279         Work around fpurge bug on BSD systems.
280         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
281         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
282         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
283         fpurge to rpl_fpurge if the system already has this function.
284         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
285         the case where the system already has this function. Correct invariants
286         on BSD systems.
287         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
288         BSD systems.
289
290 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
291
292         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
293         proposed by Sven Verdoolaege.
294
295         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
296         options.
297         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
298         (usage and help tests): Update
299
300 2007-04-29  Bruno Haible  <bruno@clisp.org>
301
302         * tests/test-fflush.c (main): Use a file of size 17, not 10.
303         Print more information in case of failure. Disable a test on BeOS.
304
305 2007-04-29  Bruno Haible  <bruno@clisp.org>
306
307         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
308         This helps debugging on systems on which no gdb is available.
309
310 2007-04-29  Bruno Haible  <bruno@clisp.org>
311
312         * lib/freading.h: Improve comments.
313         * lib/fwriting.h: Likewise.
314         * tests/test-freading.c (main): Don't check freading immediately after
315         repositioning. Needed for glibc.
316
317 2007-04-29  Bruno Haible  <bruno@clisp.org>
318
319         * lib/freading.c (freading): Trivial simplification.
320
321 2007-04-28  Bruno Haible  <bruno@clisp.org>
322
323         * tests/test-fwriting.c (main): Also test the interaction between
324         fflush and fwriting.
325         * modules/fwriting-tests (Depends-on): Add fflush.
326
327         * tests/test-freading.c (main): Also test the interaction between
328         fflush and freading.
329         * modules/freading-tests (Depends-on): Add fflush.
330
331 2007-04-28  Bruno Haible  <bruno@clisp.org>
332
333         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
334         fseeko and ftello.
335         Suggested by Eric Blake.
336
337 2007-04-28  Jim Meyering  <jim@meyering.net>
338
339         Avoid false-negative in gl_STDINT_H's C99 conformance test.
340         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
341         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
342
343 2007-04-27  Eric Blake  <ebb9@byu.net>
344
345         * doc/headers/assert.texi (assert.h): Document assert module use.
346
347 2007-04-27  Bruno Haible  <bruno@clisp.org>
348
349         * doc/headers/*.texi: New files.
350         * doc/gnulib.texi (Header File Substitutes): New chapter.
351         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
352         dependencies.
353         (standards.info ,standards.html, standards.dvi): Update dependencies.
354         (mostlyclean, clean): New targets.
355
356 2007-04-27  Bruno Haible  <bruno@clisp.org>
357
358         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
359         * modules/sysexits (Files, Makefile.am): Update.
360
361         * lib/sys_socket_.h: Renamed from lib/socket_.h.
362         * modules/sys_socket (Files, Makefile.am): Update.
363
364         * lib/sys_stat_.h: Renamed from lib/stat_.h.
365         * modules/sys_stat (Files, Makefile.am): Update.
366
367 2007-04-27  Eric Blake  <ebb9@byu.net>
368
369         * lib/freading.h: Improve comments.
370         * lib/fwriting.h: Likewise.
371         * lib/fflush.c: Likewise.
372
373         Fix closein for mingw.
374         * modules/closein-tests: Add tests for closein.
375         * tests/test-closein.c: New file.
376         * tests/test-closein.sh: Likewise.
377         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
378         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
379
380 2007-04-27  Bruno Haible  <bruno@clisp.org>
381
382         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
383         version is < 6.
384         * lib/math_.h [__DECC]: Likewise.
385         * lib/stdio_.h [__DECC]: Likewise.
386         * lib/stdlib_.h [__DECC]: Likewise.
387         * lib/string_.h [__DECC]: Likewise.
388         * lib/time_.h [__DECC]: Likewise.
389         * lib/wchar_.h [__DECC]: Likewise.
390         * lib/wctype_.h [__DECC]: Likewise.
391
392 2007-04-27  Bruno Haible  <bruno@clisp.org>
393
394         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
395
396 2007-04-27  Bruno Haible  <bruno@clisp.org>
397
398         * lib/fflush.c: Add comments.
399         * modules/fpurge-tests (Depends-on): Add fflush.
400         * modules/freadable-tests (Depends-on): Likewise.
401         * modules/fwritable-tests (Depends-on): Likewise.
402
403 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
404
405         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
406         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
407         Report by Bruno Haible <bruno@clisp.org>.
408
409 2007-04-26  Eric Blake  <ebb9@byu.net>
410
411         Fix fflush on mingw.
412         * modules/fflush (Depends-on): Add freading.
413         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
414         but unread data.
415
416 2007-04-26  Eric Blake  <ebb9@byu.net>
417         and Bruno Haible  <bruno@clisp.org>
418
419         Implement freading and fwriting.
420         * lib/freading.c: New file.
421         * lib/freading.h: Likewise.
422         * m4/freading.m4: Likewise.
423         * modules/freading: Likewise.
424         * modules/freading-tests: Likewise.
425         * tests/test-freading.c: Likewise.
426         * lib/fwriting.c: New file.
427         * lib/fwriting.h: Likewise.
428         * m4/fwriting.m4: Likewise.
429         * modules/fwriting: Likewise.
430         * modules/fwriting-tests: Likewise.
431         * tests/test-fwriting.c: Likewise.
432         * MODULES.html.sh (File stream based Input/Output): Mention them.
433
434 2007-04-26  Bruno Haible  <bruno@clisp.org>
435
436         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
437         'long' when we assume it.
438         Suggested by Eric Blake.
439
440 2007-04-26  Bruno Haible  <bruno@clisp.org>
441
442         Ensure fseeko, ftello are declared on glibc systems.
443         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
444         * modules/fseeko (configure.ac-early): Likewise.
445         * modules/ftello (configure.ac-early): Likewise.
446         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
447         AC_FUNC_FSEEKO for this.
448         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
449         (gl_CHECK_FSEEKO): Remove macro.
450
451 2007-04-26  Bruno Haible  <bruno@clisp.org>
452
453         * tests/test-fflush.c (main): Also check the ftell result after
454         fflush and fseek/fseeko.
455         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
456         file descriptor position cache in the stream.
457         * lib/fseeko.c (rpl_fseeko): Likewise.
458
459 2007-04-26  Bruno Haible  <bruno@clisp.org>
460
461         * modules/fflush-tests (Depends-on): Add fseeko.
462
463 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
464             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
465
466         * lib/argz_.h: ensure error_t definition is obtained in same
467         mechanism system argz.h would have.
468         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
469         argz facilities are known bad.  Err on the side of caution if
470         cross-compiling.
471
472 2007-04-25  Eric Blake  <ebb9@byu.net>
473
474         * lib/fpurge.c (includes): Use stdlib.h for free.
475         * tests/test-fflush.c (main): Also test fflush-fseeko.
476
477 2007-04-25  Bruno Haible  <bruno@clisp.org>
478
479         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
480         * lib/fseeko.c: New file.
481         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
482         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
483         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
484         gl_FUNC_FSEEKO.
485         (gl_FUNC_FSEEKO): Invoke it.
486         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
487         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
488         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
489
490 2007-04-25  Bruno Haible  <bruno@clisp.org>
491
492         * modules/fflush (Depends-on): Add ftello.
493
494 2007-04-25  Bruno Haible  <bruno@clisp.org>
495
496         * modules/ftello-tests: New file.
497         * tests/test-ftello.c: New file.
498
499         * modules/ftello: New file.
500         * m4/ftello.m4: New file.
501         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
502         HAVE_FTELLO.
503         * lib/stdio_.h (ftello): New declaration.
504         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
505         HAVE_FTELLO.
506
507 2007-04-25  Bruno Haible  <bruno@clisp.org>
508
509         * modules/fseeko-tests: New file.
510         * tests/test-fseeko.c: New file.
511
512         * modules/fseeko: New file.
513         * m4/fseeko.m4: New file.
514         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
515         HAVE_FSEEKO.
516         * lib/stdio_.h (fseeko): New declaration.
517         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
518         HAVE_FSEEKO.
519
520 2007-04-25  Bruno Haible  <bruno@clisp.org>
521
522         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
523
524 2007-04-25  Bruno Haible  <bruno@clisp.org>
525
526         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
527         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
528         * tests/test-unistd.c: Likewise.
529         * tests/test-fcntl.c: Likewise.
530
531 2007-04-23  Eric Blake  <ebb9@byu.net>
532
533         * lib/fflush.c: Fix missing include.
534         Reported by Bruno Haible.
535
536 2007-04-23  Bruno Haible  <bruno@clisp.org>
537
538         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
539         Reported by Eric Blake.
540
541 2007-04-23  Bruno Haible  <bruno@clisp.org>
542
543         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
544
545 2007-04-23  Bruno Haible  <bruno@clisp.org>
546
547         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
548
549 2007-04-23  Bruno Haible  <bruno@clisp.org>
550
551         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
552         Needed on HP-UX 11.
553
554 2007-04-16  Eric Blake  <ebb9@byu.net>
555
556         Make fflush rely on fpurge.
557         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
558         open coding all variants.
559         * modules/fflush (Depends-on): Add fpurge and unistd.
560         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
561         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
562
563         Fix --with-tests compilation on cygwin.
564         * modules/argmatch-tests (Makefile.am): List gnulib library first
565         in LDADD.
566         * modules/argp-tests (Makefile.am): Likewise.
567         * modules/array-list-tests (Makefile.am): Likewise.
568         * modules/array-oset-tests (Makefile.am): Likewise.
569         * modules/avltree-list-tests (Makefile.am): Likewise.
570         * modules/avltree-oset-tests (Makefile.am): Likewise.
571         * modules/avltreehash-list-tests (Makefile.am): Likewise.
572         * modules/carray-list-tests (Makefile.am): Likewise.
573         * modules/dirname-tests (Makefile.am): Likewise.
574         * modules/frexp-tests (Makefile.am): Likewise.
575         * modules/isnanl-tests (Makefile.am): Likewise.
576         * modules/linked-list-tests (Makefile.am): Likewise.
577         * modules/linkedhash-list-tests (Makefile.am): Likewise.
578         * modules/lock-tests (Makefile.am): Likewise.
579         * modules/rbtree-list-tests (Makefile.am): Likewise.
580         * modules/rbtree-oset-tests (Makefile.am): Likewise.
581         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
582         * modules/tls-tests (Makefile.am): Likewise.
583         * modules/tsearch-tests (Makefile.am): Likewise.
584         * modules/xvasprintf-tests (Makefile.am): Likewise.
585
586         Fix fpurge for cygwin.
587         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
588         value.
589         * modules/fpurge-tests (Depends-on): Clean up trash.
590
591 2007-04-16  Simon Josefsson  <simon@josefsson.org>
592
593         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
594
595         * m4/autobuild.m4: Re-indent.
596
597 2007-04-13  Bruno Haible  <bruno@clisp.org>
598
599         * modules/fpurge-tests: New file.
600         * tests/test-fpurge.c: New file.
601
602         * modules/fpurge: New file.
603         * lib/fpurge.h: New file.
604         * lib/fpurge.c: New file.
605         * m4/fpurge.m4: New file.
606
607 2007-04-13  Bruno Haible  <bruno@clisp.org>
608
609         * modules/fbufmode-tests: New file.
610         * tests/test-fbufmode.c: New file.
611
612         * modules/fbufmode: New file.
613         * lib/fbufmode.h: New file.
614         * lib/fbufmode.c: New file.
615         * m4/fbufmode.m4: New file.
616
617 2007-04-13  Bruno Haible  <bruno@clisp.org>
618
619         * modules/fwritable-tests: New file.
620         * tests/test-fwritable.c: New file.
621
622         * modules/fwritable: New file.
623         * lib/fwritable.h: New file.
624         * lib/fwritable.c: New file.
625         * m4/fwritable.m4: New file.
626
627 2007-04-13  Bruno Haible  <bruno@clisp.org>
628
629         * modules/freadable-tests: New file.
630         * tests/test-freadable.c: New file.
631
632         * modules/freadable: New file.
633         * lib/freadable.h: New file.
634         * lib/freadable.c: New file.
635         * m4/freadable.m4: New file.
636
637 2007-04-13  Bruno Haible  <bruno@clisp.org>
638
639         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
640         MOSTLYCLEANFILES.
641
642 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
643
644         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
645         gzip bootstrap.conf to avoid dragging in i18n machinery.
646         (gnulib_tool_option): Use it.
647
648 2007-04-13  Bruno Haible  <bruno@clisp.org>
649
650         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
651         %F directives.
652         * tests/test-vasprintf-posix.c (test_function): Likewise.
653         * tests/test-snprintf-posix.h (test_function): Likewise.
654         * tests/test-sprintf-posix.h (test_function): Likewise.
655         * tests/test-fprintf-posix.h (test_function): Likewise.
656         * tests/test-printf-posix.h (test_function): Likewise.
657         * tests/test-fprintf-posix.out: Likewise.
658
659 2007-04-13  Bruno Haible  <bruno@clisp.org>
660
661         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
662         * modules/tls-tests (configure.ac): Likewise.
663         Reported by Arto C. Nirkko <anirkko@insel.ch>.
664
665 2007-04-13  Bruno Haible  <bruno@clisp.org>
666
667         * lib/tls.c (glthread_tls_get): Fix return type.
668         Patch by Arto C. Nirkko <anirkko@insel.ch>.
669
670 2007-04-12  Eric Blake  <ebb9@byu.net>
671
672         * modules/gettime (Depends-on): Remove gettime.
673         Reported by Dmitry V. Levin.
674
675 2007-04-12  Bruno Haible  <bruno@clisp.org>
676
677         * modules/fflush (Include): Mention <stdio.h>.
678         * modules/strtoimax (Include): Mention <inttypes.h>.
679         * modules/strtoumax (Include): Likewise.
680
681 2007-04-12  Eric Blake  <ebb9@byu.net>
682
683         * .cvsignore: New file.
684         * .gitignore: Likewise.
685
686 2007-04-12  Bruno Haible  <bruno@clisp.org>
687
688         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
689         not before, since $(LDADD) often contains libgnu.a.
690         * modules/striconv-tests (test_striconv_LDADD): Likewise.
691         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
692         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
693         Needed on Cygwin.
694
695 2007-04-12  Eric Blake  <ebb9@byu.net>
696
697         Work around glibc's failure to flush stdin on fclose.
698         * lib/closein.c (close_stdin): Flush stdin before closing.
699
700         Work around glibc's failure to reset seekable stdin on exit.
701         * modules/closein: New module.
702         * lib/closein.c: New file.
703         * lib/closein.h: Likewise.
704         * m4/closein.m4: Likewise.
705         * MODULES.html.sh (File stream based Input/Output): Document it.
706
707 2007-04-12  Simon Josefsson  <simon@josefsson.org>
708
709         * gnulib-tool: Rename generated 'autobuild' script to
710         'do-autobuild' in --create-megatestdir output.
711
712         * doc/gnulib.texi (Build robot for gnulib): Fix.
713
714 2007-04-12  Simon Josefsson  <simon@josefsson.org>
715
716         * modules/sysexits (Depends-on): Add absolute-header.
717
718 2007-04-12  Eric Blake  <ebb9@byu.net>
719
720         No need to preserve errno on success.
721         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
722         Reported by Bruno Haible.
723
724 2007-04-12  Simon Josefsson  <simon@josefsson.org>
725
726         * MODULES.html.sh (Support for maintaining and releasing
727         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
728
729 2007-04-12  Simon Josefsson  <simon@josefsson.org>
730
731         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
732
733 2007-04-12  Simon Josefsson  <simon@josefsson.org>
734
735         * modules/autobuild: New module.
736
737         * m4/autobuild.m4: New file.
738
739 2007-04-11  Bruno Haible  <bruno@clisp.org>
740
741         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
742         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
743         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
744         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
745         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
746         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
747         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
748         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
749         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
750         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
751         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
752         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
753         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
754         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
755         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
756         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
757         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
758         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
759         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
760         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
761         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
762         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
763         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
764         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
765         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
766         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
767         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
768         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
769         Reported by Eric Blake.
770
771 2007-04-11  Bruno Haible  <bruno@clisp.org>
772
773         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
774
775 2007-04-10  Bruno Haible  <bruno@clisp.org>
776
777         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
778         for NaN and Infinity. Needed on FreeBSD 6.1.
779         * tests/test-vasnprintf-posix.c (test_function): Undo last change
780         regarding results for "%010a" of Infinity and NaN.
781         * tests/test-vasprintf-posix.c (test_function): Likewise.
782         * tests/test-snprintf-posix.h (test_function): Likewise.
783         * tests/test-sprintf-posix.h (test_function): Likewise.
784         * tests/test-fprintf-posix.h (test_function): Likewise.
785         * tests/test-printf-posix.h (test_function): Likewise.
786         * tests/test-fprintf-posix.out: Likewise.
787
788 2007-04-10  Bruno Haible  <bruno@clisp.org>
789
790         * modules/locale-tests: New file.
791         * tests/test-locale.c: New file.
792
793         * modules/locale: New file.
794         * lib/locale_.h: New file.
795         * m4/locale_h.m4: New file.
796
797 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
798             Bruno Haible  <bruno@clisp.org>
799
800         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
801         be determined, test for availability of the copysignf, copysign,
802         copysignl functions.
803         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
804         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
805         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
806
807 2007-04-09  Eric Blake  <ebb9@byu.net>
808
809         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
810         * modules/stdio (Makefile.am): Support fflush.
811         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
812         * modules/fflush: New file.
813         * lib/fflush.c: Likewise.
814         * m4/fflush.m4: Likewise.
815         * modules/fflush-tests: New test.
816         * tests/test-fflush.c: Likewise.
817         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
818
819 2007-04-06  Bruno Haible  <bruno@clisp.org>
820
821         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
822         (VASNPRINTF): Use signbit for faster determination whether to print a
823         minus sign.
824         * modules/vasnprintf (Files): Remove lib/float+.h.
825         * modules/fprintf-posix (Depends-on): Add signbit.
826         * modules/snprintf-posix (Depends-on): Likewise.
827         * modules/sprintf-posix (Depends-on): Likewise.
828         * modules/vasnprintf-posix (Depends-on): Likewise.
829         * modules/vasprintf-posix (Depends-on): Likewise.
830         * modules/vfprintf-posix (Depends-on): Likewise.
831         * modules/vsnprintf-posix (Depends-on): Likewise.
832         * modules/vsprintf-posix (Depends-on): Likewise.
833
834 2007-04-06  Bruno Haible  <bruno@clisp.org>
835
836         * tests/test-frexp.c (main): Test also the sign bit of zero results.
837         * tests/test-frexpl.c (main): Likewise.
838         * tests/test-ldexpl.c (main): Likewise.
839         * modules/frexp-tests (Depends-on): Add signbit.
840         * modules/frexpl-tests (Depdends-on): Likewise.
841         * modules/ldexpl-tests (Depdends-on): Likewise.
842
843 2007-04-06  Bruno Haible  <bruno@clisp.org>
844
845         * modules/signbit-tests: New file.
846         * tests/test-signbit.c: New file.
847
848         * modules/signbit: New file.
849         * lib/signbitf.c: New file.
850         * lib/signbitd.c: New file.
851         * lib/signbitl.c: New file.
852         * m4/signbit.m4: New file.
853         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
854         (signbit): New macro.
855         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
856         REPLACE_SIGNBIT.
857         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
858         REPLACE_FREXPL into math.h.
859
860 2007-04-06  Bruno Haible  <bruno@clisp.org>
861
862         * modules/isnanf-nolibm-tests: New file.
863         * tests/test-isnanf.c: New file.
864
865         * modules/isnanf-nolibm: New file.
866         * lib/isnanf.h: New file.
867         * lib/isnanf.c: New file.
868         * lib/isnan.c: Consider the USE_FLOAT macro.
869         * m4/isnanf.m4: New file.
870
871 2007-04-06  Bruno Haible  <bruno@clisp.org>
872
873         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
874         (Link): New section.
875
876         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
877
878 2007-04-06  Bruno Haible  <bruno@clisp.org>
879
880         Assume the 'long double' type.
881         * m4/longdouble.m4: Remove file.
882         * config/srclist.txt: Don't mention longdouble.m4.
883         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
884         * lib/float+.h: Likewise.
885         * lib/frexp.c: Likewise.
886         * lib/printf-args.h: Likewise.
887         * lib/printf-args.c: Likewise.
888         * lib/printf-frexp.c: Likewise.
889         * lib/printf-parse.c: Likewise.
890         * lib/vasnprintf.c: Likewise.
891         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
892         * m4/intl.m4: Likewise.
893         * m4/isnanl.m4: Likewise.
894         * m4/printf.m4: Likewise.
895         * m4/printf-frexpl.m4: Likewise.
896         * m4/vasnprintf.m4: Likewise.
897         * modules/allocsa (Files): Remove m4/longdouble.m4.
898         * modules/gettext (Files): Likewise.
899         * modules/relocatable-prog-wrapper (Files): Likewise.
900         * modules/vasnprintf (Files): Likewise.
901         * modules/isnanl (Files): Likewise.
902         (Include): Simplify.
903         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
904         (Include): Simplify.
905         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
906         (Include): Simplify.
907         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
908         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
909         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
910         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
911         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
912         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
913         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
914         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
915         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
916         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
917         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
918         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
919         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
920         * tests/test-isnanl.c: Likewise.
921         * tests/test-snprintf-posix.h: Likewise.
922         * tests/test-sprintf-posix.h: Likewise.
923         * tests/test-vasnprintf-posix.c: Likewise.
924         * tests/test-vasnprintf-posix2.c: Likewise.
925         * tests/test-vasprintf-posix.c: Likewise.
926
927 2007-04-06  Bruno Haible  <bruno@clisp.org>
928
929         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
930         * lib/math_.h [__DECC]: Include the overridden include file through
931         #include_next, outside the double-inclusion guard.
932         * lib/stdio_.h [__DECC]: Likewise.
933         * lib/stdlib_.h [__DECC]: Likewise.
934         * lib/string_.h [__DECC]: Likewise.
935         * lib/time_.h [__DECC]: Likewise.
936         * lib/wchar_.h [__DECC]: Likewise.
937         * lib/wctype_.h [__DECC]: Likewise.
938         * lib/inttypes_.h [__DECC]: Likewise.
939         Reported by Albert Chin <china@thewrittenword.com> in
940         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
941
942 2007-04-04  Eric Blake  <ebb9@byu.net>
943
944         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
945         1.5.x.
946
947 2007-04-04  Bruno Haible  <bruno@clisp.org>
948
949         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
950         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
951
952 2007-04-04  Bruno Haible  <bruno@clisp.org>
953
954         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
955         results for "%010a" of Infinity and NaN.
956         * tests/test-vasprintf-posix.c (test_function): Likewise.
957         * tests/test-snprintf-posix.h (test_function): Likewise.
958         * tests/test-sprintf-posix.h (test_function): Likewise.
959         * tests/test-fprintf-posix.h (test_function): Remove these tests.
960         * tests/test-printf-posix.h (test_function): Likewise.
961         * tests/test-fprintf-posix.out: Update.
962         Needed for FreeBSD 6.1.
963
964 2007-04-04  Bruno Haible  <bruno@clisp.org>
965
966         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
967         directly used by the gnulib modules nor by gnulib-tool.
968
969 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
970
971         * DEPENDENCIES: Give overall description of version dependency
972         desirability.  Use more-typical names for apps.
973         Add shell, coreutils, diffutils, grep, tar, gzip.
974
975 2007-04-04  Simon Josefsson  <simon@josefsson.org>
976
977         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
978
979 2007-04-04  Karl Berry  <karl@gnu.org>
980
981         * MODULES.html.sh (func_module): missing '.
982
983 2007-04-03  Bruno Haible  <bruno@clisp.org>
984
985         * modules/argmatch-tests (Makefile.am): New variable
986         test_argmatch_LDADD.
987         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
988         * modules/array-list-tests (Makefile.am): New variable
989         test_array_list_LDADD.
990         * modules/array-oset-tests (Makefile.am): New variable
991         test_array_oset_LDADD.
992         * modules/avltree-list-tests (Makefile.am): New variable
993         test_avltree_list_LDADD.
994         * modules/avltree-oset-tests (Makefile.am): New variable
995         test_avltree_oset_LDADD.
996         * modules/avltreehash-list-tests (Makefile.am): New variable
997         test_avltreehash_list_LDADD.
998         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
999         test_canonicalize_lgpl_LDADD.
1000         * modules/carray-list-tests (Makefile.am): New variable
1001         test_carray_list_LDADD.
1002         * modules/dirname-tests (Makefile.am): New variable
1003         test_dirname_LDADD.
1004         * modules/linked-list-tests (Makefile.am): New variable
1005         test_linked_list_LDADD.
1006         * modules/linkedhash-list-tests (Makefile.am): New variable
1007         test_linkedhash_list_LDADD.
1008         * modules/rbtree-list-tests (Makefile.am): New variable
1009         test_rbtree_list_LDADD.
1010         * modules/rbtree-oset-tests (Makefile.am): New variable
1011         test_rbtree_oset_LDADD.
1012         * modules/rbtreehash-list-tests (Makefile.am): New variable
1013         test_rbtreehash_list_LDADD.
1014         * modules/xvasprintf-tests (Makefile.am): New variable
1015         test_xvasprintf_LDADD.
1016         Reported by Eric Blake.
1017
1018 2007-04-03  Eric Blake  <ebb9@byu.net>
1019
1020         * DEPENDENCIES: Weaken m4 requirements.
1021
1022 2007-04-03  Bruno Haible  <bruno@clisp.org>
1023
1024         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
1025         * modules/isnanl-tests (configure.ac): Likewise.
1026
1027 2007-04-03  Ben Pfaff  <blp@gnu.org>
1028
1029         * modules/iconv_open: Add $(srcdir)/ to source directory
1030         references in Makefile fragments that call gperf, to fix VPATH
1031         builds.
1032
1033 2007-04-03  Bruno Haible  <bruno@clisp.org>
1034
1035         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
1036         * lib/ldexpl.c: Undo last change.
1037
1038 2007-04-03  Bruno Haible  <bruno@clisp.org>
1039
1040         * modules/printf-frexpl (Depends-on): Undo last change.
1041         (Files): Add m4/ldexpl.m4.
1042
1043 2007-04-03  Bruno Haible  <bruno@clisp.org>
1044
1045         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
1046         * modules/isnanl (Link): New section.
1047
1048         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
1049         * modules/frexp (Link): New section.
1050
1051         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
1052         * modules/frexpl (Link): New section.
1053
1054         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
1055         * modules/ldexpl (Link): New section.
1056
1057 2007-04-03  Bruno Haible  <bruno@clisp.org>
1058
1059         * modules/TEMPLATE-EXTENDED: New file.
1060         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
1061
1062 2007-04-03  Bruno Haible  <bruno@clisp.org>
1063
1064         * DEPENDENCIES: New file.
1065         Suggested by Simon Josefsson.
1066
1067 2007-04-03  Bruno Haible  <bruno@clisp.org>
1068
1069         * doc/gnulib.texi: Escape @.
1070
1071 2007-04-03  James Youngman  <jay@gnu.org>
1072         and Paul Eggert  <eggert@cs.ucla.edu>
1073
1074         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
1075         birthtime on all systems that have birthtime, not just those which
1076         use st_birthtimensec rather than st_birthtim.  Putting zero in
1077         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
1078         that the birth time is not available for files on an NFS mount.
1079
1080 2007-04-03  Simon Josefsson  <simon@josefsson.org>
1081
1082         * modules/memxor: Move back from crypto/, suggested by Bruno.
1083         * modules/crypto/hmac-sha1: Fix memxor dependency.
1084
1085         * modules/crypto/gc: Moved from ../.
1086
1087 2007-04-02  Eric Blake  <ebb9@byu.net>
1088
1089         * lib/ldexpl.c (includes): Avoid libm.
1090
1091         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
1092
1093 2007-04-02  Bruno Haible  <bruno@clisp.org>
1094
1095         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
1096         on IRIX.
1097
1098 2007-04-02  Bruno Haible  <bruno@clisp.org>
1099
1100         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
1101         x86 or x86_64 platforms running MacOS X.
1102         Reported by Ryan Schmidt <@ryandesign.com>.
1103
1104 2007-04-02  Bruno Haible  <bruno@clisp.org>
1105
1106         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
1107         i386.
1108
1109 2007-04-01  Simon Josefsson  <simon@josefsson.org>
1110
1111         * modules/crypto/arcfour: Moved from ../.
1112         * modules/crypto/arcfour-tests: Moved from ../.
1113         * modules/crypto/arctwo: Moved from ../.
1114         * modules/crypto/arctwo-tests: Moved from ../.
1115         * modules/crypto/des: Moved from ../.
1116         * modules/crypto/des-tests: Moved from ../.
1117         * modules/crypto/gc-arcfour: Moved from ../.
1118         * modules/crypto/gc-arcfour-tests: Moved from ../.
1119         * modules/crypto/gc-arctwo: Moved from ../.
1120         * modules/crypto/gc-arctwo-tests: Moved from ../.
1121         * modules/crypto/gc-des: Moved from ../.
1122         * modules/crypto/gc-des-tests: Moved from ../.
1123         * modules/crypto/gc-hmac-md5: Moved from ../.
1124         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
1125         * modules/crypto/gc-hmac-sha1: Moved from ../.
1126         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
1127         * modules/crypto/gc-md2: Moved from ../.
1128         * modules/crypto/gc-md2-tests: Moved from ../.
1129         * modules/crypto/gc-md4: Moved from ../.
1130         * modules/crypto/gc-md4-tests: Moved from ../.
1131         * modules/crypto/gc-md5: Moved from ../.
1132         * modules/crypto/gc-md5-tests: Moved from ../.
1133         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
1134         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
1135         * modules/crypto/gc-random: Moved from ../.
1136         * modules/crypto/gc-rijndael: Moved from ../.
1137         * modules/crypto/gc-rijndael-tests: Moved from ../.
1138         * modules/crypto/gc-sha1: Moved from ../.
1139         * modules/crypto/gc-sha1-tests: Moved from ../.
1140         * modules/crypto/gc-tests: Moved from ../.
1141         * modules/crypto/hmac-md5: Moved from ../.
1142         * modules/crypto/hmac-md5-tests: Moved from ../.
1143         * modules/crypto/hmac-sha1: Moved from ../.
1144         * modules/crypto/hmac-sha1-tests: Moved from ../.
1145         * modules/crypto/md2: Moved from ../.
1146         * modules/crypto/md2-tests: Moved from ../.
1147         * modules/crypto/md4: Moved from ../.
1148         * modules/crypto/md4-tests: Moved from ../.
1149         * modules/crypto/md5: Moved from ../.
1150         * modules/crypto/md5-tests: Moved from ../.
1151         * modules/crypto/memxor: Moved from ../.
1152         * modules/crypto/rijndael: Moved from ../.
1153         * modules/crypto/rijndael-tests: Moved from ../.
1154         * modules/crypto/sha1: Moved from ../.
1155
1156 2007-03-30  James Youngman  <jay@gnu.org>
1157
1158         * tests/test-stat-time.c (prepare_test): use chmod() rather than
1159         rename() to change the ctime of a file (because ctime is unaffected
1160         by rename on jfs2 on AIX 5.1).
1161         (main): Start by doing cleanup, in case a previous run failed leaving
1162         test files behind.
1163
1164 2007-03-31  Bruno Haible  <bruno@clisp.org>
1165
1166         Support old proprietary implementations of iconv.
1167         * modules/iconv_open: New file.
1168         * lib/iconv_.h: New file.
1169         * m4/iconv_h.m4: New file.
1170         * lib/iconv_open.c: New file.
1171         * lib/iconv_open-aix.gperf: New file.
1172         * lib/iconv_open-hpux.gperf: New file.
1173         * lib/iconv_open-irix.gperf: New file.
1174         * lib/iconv_open-osf.gperf: New file.
1175         * m4/iconv_open.m4: New file.
1176         * modules/linebreak (Depends-on): Add iconv_open.
1177         * modules/striconv (Depends-on): Likewise.
1178         * modules/striconveh (Depends-on): Likewise.
1179         * modules/unicodeio (Depends-on): Likewise.
1180         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
1181         (iconv_t)(-1).
1182         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
1183         conversion if cd is (iconv_t)(-1).
1184         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
1185         is not possible.
1186
1187 2007-03-31  Bruno Haible  <bruno@clisp.org>
1188
1189         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
1190         work on Solaris either. Protect also second use of "autodetect_jp".
1191
1192 2007-03-31  Bruno Haible  <bruno@clisp.org>
1193
1194         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
1195         the function is not present.
1196
1197 2007-03-31  Bruno Haible  <bruno@clisp.org>
1198
1199         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
1200         the function is not present.
1201
1202 2007-03-31  Bruno Haible  <bruno@clisp.org>
1203
1204         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
1205         a bug in HP-UX iconv_open().
1206
1207 2007-03-31  Bruno Haible  <bruno@clisp.org>
1208
1209         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
1210         (Mathematics <math.h>): New section, add fpieee.
1211         (Input/output <stdio.h>): Add fseterr.
1212         (Mathematics <math.h>): New section, add printf-frexp.
1213         (Container data structures): Add sublist.
1214         (Core language properties): Add fpucw, inline.
1215         (Functions for greatest-width integer types <inttypes.h>): Add
1216         imaxabs, imaxdiv, inttypes.
1217         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
1218         isnanl-nolibm, ldexp.
1219         (Mathematics <math.h>): New section, add printf-frexpl.
1220         (Support for systems lacking POSIX:2001): Add fprintf-posix,
1221         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
1222         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
1223         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
1224         (Unicode string functions): Add unistr/u*-mbtoucr.
1225         (Java): Add javacomp-script, javaexec-script.
1226         (C#): Add csharpcomp-script, csharpexec-script.
1227         (Support for building libraries and executables): Add havelib,
1228         relocatable-*.
1229         (Support for maintaining and releasing projects): Renamed from
1230         'Support for maintaining and release projects'. Add announce-gen.
1231
1232 2007-03-31  Bruno Haible  <bruno@clisp.org>
1233
1234         * README: Talk primarily about git.
1235         (git and CVS): Renamed from CVS.
1236         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
1237         gnulib is available through git.
1238         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
1239
1240 2007-03-30  Bruno Haible  <bruno@clisp.org>
1241
1242         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
1243         * lib/poll_.h: Likewise.
1244         * lib/stat_.h: Likewise.
1245         * lib/sys_time_.h: Likewise.
1246         * lib/sysexit_.h: Likewise.
1247         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
1248         * lib/stdbool_.h: Likewise.
1249         * lib/byteswap_.h: Add double-inclusion guard.
1250
1251 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
1252
1253         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
1254
1255 2007-03-30  Karl Berry  <karl@gnu.org>
1256
1257         * config/srclist-update: double space after USA in the license
1258         substitution, since that's how it's usually (?) written.
1259
1260 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
1261
1262         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
1263         reported by Bruno Haible.
1264
1265 2007-03-29  Bruno Haible  <bruno@clisp.org>
1266
1267         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
1268         a bug in AIX iconv().
1269
1270 2007-03-29  Bruno Haible  <bruno@clisp.org>
1271
1272         * modules/ldexpl-tests: New file.
1273         * tests/test-ldexpl.c: New file.
1274
1275 2007-03-29  Bruno Haible  <bruno@clisp.org>
1276
1277         * lib/ldexpl.c: Include fpucw.h.
1278         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
1279         multiplication.
1280         * modules/ldexpl (Depends-on): Add fpucw.
1281
1282 2007-03-29  Bruno Haible  <bruno@clisp.org>
1283
1284         * modules/ldexpl: New file.
1285         * m4/ldexpl.m4: New file.
1286         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
1287         set.
1288         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
1289         REPLACE_LDEXPL.
1290         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
1291         REPLACE_LDEXPL.
1292         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
1293         gl_FUNC_LDEXPL_WORKS.
1294         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
1295         * modules/mathl (Files): Remove lib/ldexpl.c.
1296         (Depends-on): Add ldexpl.
1297
1298 2007-03-29  Bruno Haible  <bruno@clisp.org>
1299
1300         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
1301
1302 2007-03-29  Bruno Haible  <bruno@clisp.org>
1303
1304         * tests/test-striconveh.c (main): Don't assume that a direct conversion
1305         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
1306         and possibly also HP-UX.
1307         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
1308         work on AIX, IRIX, HP-UX, OSF/1.
1309         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
1310         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
1311         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
1312         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
1313         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
1314         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
1315
1316 2007-03-29  Bruno Haible  <bruno@clisp.org>
1317
1318         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
1319
1320 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
1321
1322         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
1323         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
1324
1325 2007-03-29  Eric Blake  <ebb9@byu.net>
1326
1327         * lib/acl-internal.h: Remove redundant include.
1328         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
1329         Cygwin when a file is locked.
1330
1331 2007-03-29  Bruno Haible  <bruno@clisp.org>
1332
1333         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
1334         file.
1335         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
1336
1337 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
1338
1339         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
1340         try to remove a parent directory if the child couldn't be removed
1341         (except for the first rmdir, which could fail because the child
1342         doesn't exist).  Problem reported by Jeff Blaine in
1343         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
1344
1345 2007-03-28  Bruno Haible  <bruno@clisp.org>
1346
1347         * lib/striconveh.c (utf8conv_carefully): New function.
1348         (mem_cd_iconveh_internal): Invoke it.
1349
1350 2007-03-28  Bruno Haible  <bruno@clisp.org>
1351
1352         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
1353         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
1354         input.
1355         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
1356         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
1357         unistr/u8-uctomb.
1358
1359 2007-03-28  Bruno Haible  <bruno@clisp.org>
1360
1361         * modules/unistr/u8-mbtoucr: New file.
1362         * lib/unistr/u8-mbtoucr.c: New file.
1363         * modules/unistr/u16-mbtoucr: New file.
1364         * lib/unistr/u16-mbtoucr.c: New file.
1365         * modules/unistr/u16-mbtoucr: New file.
1366         * lib/unistr/u16-mbtoucr.c: New file.
1367         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
1368
1369 2007-03-27  Simon Josefsson  <simon@josefsson.org>
1370             Bruno Haible  <bruno@clisp.org>
1371
1372         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
1373         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
1374         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
1375
1376         * m4/stdio_h.m4: Add stubs for vasprintf too.
1377
1378         * modules/stdio: Support vasprintf in sed command.
1379
1380         * modules/vasprintf: Depend on stdio for prototypes.  Remove
1381         vasprintf.h.  Add stdio module indicator.
1382
1383         * lib/stdio_.h: Declare asprintf and vasprintf, based on
1384         vasprintf.h.
1385
1386         * lib/vasprintf.h: File removed.
1387
1388         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
1389         * lib/vasprintf.c: Ditto.
1390         * lib/xvasprintf.c: Ditto.
1391         * tests/test-vasprintf-posix.c: Ditto.
1392         * tests/test-vasprintf.c: Ditto.
1393
1394 2007-03-27  Bruno Haible  <bruno@clisp.org>
1395
1396         Make vasnprintf multithread-safe.
1397         * lib/vasnprintf.c (decimal_point_char): New function.
1398         (VASNPRINTF): Use it.
1399         Suggested by Simon Josefsson.
1400
1401 2007-03-27  Eric Blake  <ebb9@byu.net>
1402
1403         Support sub-second birthtime on cygwin.
1404         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
1405         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
1406         (get_stat_birthtime): Also work with st_birthtim.
1407
1408 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
1409
1410         * lib/stat-time.h (USE_BIRTHTIME): Remove.
1411         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
1412         (get_stat_birthtime_ns): Do not try to use "spare" fields.
1413         (get_stat_birthtime_ns): Simplify compile-time tests.
1414         (get_stat_birthtime): Change the API to look like
1415         get_stat_mtime etc., except return a negative tv_nsec on error.
1416         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
1417         Don't check for "spare" fields.
1418         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
1419         or for struct stat.st_birthtime, as these tests aren't used.
1420         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
1421
1422 2007-03-27  Bruno Haible  <bruno@clisp.org>
1423
1424         * lib/stat-time.h: Include <sys/stat.h>.
1425
1426 2007-03-27  James Youngman  <jay@gnu.org>
1427
1428         * lib/stat-time.h (get_stat_birthtime): New function for
1429           retrieving st_birthtime as provided by UFS2 (hence *BSD).
1430         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
1431           and its variants.
1432         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
1433         * modules/stat-time-test: New file.
1434         * tests/test-stat-time.c: New test, devised by Bruno Haible.
1435
1436 2007-03-26  Bruno Haible  <bruno@clisp.org>
1437
1438         Better support of signalling NaNs.
1439         * lib/atanl.c: Include isnanl.h.
1440         (atanl): Perform test for NaN at the beginning of the function and
1441         through a call to isnanl.
1442         * lib/cosl.c: Include isnanl.h.
1443         (cosl): Perform test for NaN at the beginning of the function and
1444         through a call to isnanl.
1445         * lib/ldexpl.c: Include isnanl.h.
1446         (ldexpl): Perform test for NaN through a call to isnanl.
1447         * lib/logl.c: Include isnanl.h.
1448         (logl): Perform test for NaN at the beginning of the function and
1449         through a call to isnanl.
1450         * lib/sinl.c: Include isnanl.h.
1451         (sinl): Perform test for NaN at the beginning of the function and
1452         through a call to isnanl.
1453         * lib/sqrtl.c: Include isnanl.h.
1454         (sqrtl): Perform test for NaN at the beginning of the function and
1455         through a call to isnanl.
1456         * lib/tanl.c: Include isnanl.h.
1457         (tanl): Perform test for NaN at the beginning of the function and
1458         through a call to isnanl.
1459         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
1460         * modules/mathl (Depends-on): Add isnanl.
1461
1462 2007-03-26  Eric Blake  <ebb9@byu.net>
1463
1464         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
1465         regression in logic sense of previous patch.
1466
1467 2007-03-26  Bruno Haible  <bruno@clisp.org>
1468
1469         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
1470         unportable shell command "if ! ...".
1471         Reported by Ralf Wildenhues.
1472
1473 2007-03-25  Bruno Haible  <bruno@clisp.org>
1474
1475         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
1476         <sysexits.h> file, and only add EX_CONFIG.
1477         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
1478         absolute file name and whether it is sufficient. Substitute also
1479         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
1480         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
1481         ABSOLUTE_SYSEXITS_H into sysexits.h.
1482
1483 2007-03-25  Bruno Haible  <bruno@clisp.org>
1484
1485         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
1486         hints is NULL.
1487
1488 2007-03-25  Bruno Haible  <bruno@clisp.org>
1489
1490         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
1491         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
1492
1493 2007-03-25  Bruno Haible  <bruno@clisp.org>
1494
1495         * lib/vasnprintf.c: Include langinfo.h.
1496         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
1497         multithread-safe.
1498         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
1499         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
1500         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1501         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1502         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1503         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1504         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1505         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
1506         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1507         Reported by Simon Josefsson.
1508
1509 2007-03-25  Bruno Haible  <bruno@clisp.org>
1510
1511         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
1512         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
1513         * modules/vasnprintf (Depends-on): Add stdint.
1514
1515 2007-03-25  Bruno Haible  <bruno@clisp.org>
1516
1517         * modules/fpieee: New file.
1518         * m4/fpieee.m4: New file.
1519         * modules/isnan-nolibm (Depends-on): Add fpieee.
1520         * modules/isnanl-nolibm (Depends-on): Add fpieee.
1521         * modules/isnanl (Depends-on): Add fpieee.
1522
1523 2007-03-25  Bruno Haible  <bruno@clisp.org>
1524
1525         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
1526
1527 2007-03-25  Bruno Haible  <bruno@clisp.org>
1528
1529         Avoid test failures on IRIX 6.5.
1530         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
1531         (main): Use it.
1532         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
1533         macros.
1534         (main): Use them.
1535
1536 2007-03-25  Bruno Haible  <bruno@clisp.org>
1537
1538         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
1539         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
1540         exists but doesn't work.
1541         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
1542         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
1543         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
1544         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
1545
1546 2007-03-25  Bruno Haible  <bruno@clisp.org>
1547
1548         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
1549         returns inf. Needed on IRIX 6.5.
1550
1551 2007-03-25  Bruno Haible  <bruno@clisp.org>
1552
1553         * tests/test-frexpl.c: Include isnanl-nolibm.h.
1554         (main): Use isnanl instead of x != x idiom.
1555         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
1556
1557         * tests/test-frexp.c: Include isnan.h.
1558         (main): Use isnan instead of x != x idiom.
1559         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
1560
1561 2007-03-25  Bruno Haible  <bruno@clisp.org>
1562
1563         * tests/test-frexp.c (NaN): New function/macro.
1564         (main): Use it instead of 0.0 / 0.0.
1565         * tests/test-isnan.c (NaN): New function/macro.
1566         (main): Use it instead of 0.0 / 0.0.
1567         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
1568         (test_function): Use it instead of 0.0 / 0.0.
1569         * tests/test-vasprintf-posix.c (NaN): New function/macro.
1570         (test_function): Use it instead of 0.0 / 0.0.
1571         * tests/test-snprintf-posix.h (NaN): New function/macro.
1572         (test_function): Use it instead of 0.0 / 0.0.
1573         * tests/test-sprintf-posix.h (NaN): New function/macro.
1574         (test_function): Use it instead of 0.0 / 0.0.
1575         * tests/test-fprintf-posix.h (NaN): New function/macro.
1576         (test_function): Use it instead of 0.0 / 0.0.
1577         * tests/test-printf-posix.h (NaN): New function/macro.
1578         (test_function): Use it instead of 0.0 / 0.0.
1579
1580         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
1581
1582 2007-03-25  Bruno Haible  <bruno@clisp.org>
1583
1584         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
1585
1586 2007-03-25  Bruno Haible  <bruno@clisp.org>
1587
1588         * lib/regexec.c (merge_state_with_log): Make static.
1589
1590 2007-03-25  Bruno Haible  <bruno@clisp.org>
1591
1592         * lib/trigl.c (kernel_rem_pio2): Make static.
1593
1594 2007-03-25  Bruno Haible  <bruno@clisp.org>
1595
1596         * lib/sincosl.c (sincosl_table): Make static.
1597
1598 2007-03-25  Bruno Haible  <bruno@clisp.org>
1599
1600         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
1601         if the compiler does not support C99.
1602
1603 2007-03-25  Bruno Haible  <bruno@clisp.org>
1604
1605         * modules/time (Makefile.am): Ensure all rule action lines start with a
1606         tab.
1607
1608 2007-03-24  Bruno Haible  <bruno@clisp.org>
1609
1610         * modules/tsearch-tests: New file.
1611         * tests/test-tsearch.sh: New file.
1612         * tests/test-tsearch.c: New file, mostly copied from glibc.
1613
1614         * modules/search-tests: New file.
1615         * tests/test-search.c: New file.
1616
1617         * modules/search: New file.
1618         * lib/search_.h: New file, incorporating lib/tsearch.h.
1619         * m4/search_h.m4: New file.
1620         * lib/tsearch.h: Remove file.
1621         * lib/tsearch.c: Include search.h instead of tsearch.h.
1622         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
1623         HAVE_TSEARCH.
1624         * modules/tsearch (Files): Remove lib/tsearch.h.
1625         (Depends-on): Add search.
1626         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
1627         (Include): Change tsearch.h into search.h.
1628
1629 2007-03-24  Bruno Haible  <bruno@clisp.org>
1630
1631         * modules/fpucw: New file.
1632         * lib/fpucw.h: New file.
1633         * lib/frexp.c: Include fpucw.h.
1634         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
1635         (FUNC): Use them.
1636         * lib/printf-frexp.c: Include fpucw.h.
1637         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
1638         (FUNC): Use them.
1639         * lib/vasnprintf.c: Include fpucw.h.
1640         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
1641         'long double' calculations.
1642         * tests/test-frexpl.c: Include fpucw.h.
1643         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
1644         * tests/test-printf-frexpl.c: Include fpucw.h.
1645         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
1646         * modules/frexpl (Depends-on): Add fpucw.
1647         * modules/printf-frexpl (Depends-on): Likewise.
1648         * modules/fprintf-posix (Depends-on): Likewise.
1649         * modules/snprintf-posix (Depends-on): Likewise.
1650         * modules/sprintf-posix (Depends-on): Likewise.
1651         * modules/vasnprintf-posix (Depends-on): Likewise.
1652         * modules/vasprintf-posix (Depends-on): Likewise.
1653         * modules/vfprintf-posix (Depends-on): Likewise.
1654         * modules/vsnprintf-posix (Depends-on): Likewise.
1655         * modules/vsprintf-posix (Depends-on): Likewise.
1656         * modules/frexpl-tests (Depends-on): Likewise.
1657         * modules/printf-frexpl-tests (Depends-on): Likewise.
1658
1659 2007-03-24  Bruno Haible  <bruno@clisp.org>
1660
1661         * lib/float+.h: New file.
1662         * lib/isnan.c: Include float+.h.
1663         (SIZE): New macro.
1664         (FUNC): Compare only SIZE bytes of the value.
1665         * lib/vasnprintf.c: Include float+.h.
1666         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
1667         SIZEOF_LDBL or SIZEOF_DBL bytes.
1668         * modules/isnan-nolibm (Files): Add lib/float+.h.
1669         * modules/isnanl-nolibm (Files): Add lib/float+.h.
1670         * modules/isnanl (Files): Add lib/float+.h.
1671         * modules/vasnprintf (Files): Add lib/float+.h.
1672
1673 2007-03-24  Bruno Haible  <bruno@clisp.org>
1674
1675         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
1676         include isnanl-nolibm.h.
1677
1678 2007-03-24  Bruno Haible  <bruno@clisp.org>
1679
1680         * tests/test-read-file.c (main): Don't produce spurious output for
1681         expected situations. Make the test fail if it encountered unexpected
1682         results.
1683
1684 2007-03-24  Bruno Haible  <bruno@clisp.org>
1685
1686         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
1687         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
1688
1689 2007-03-24  Bruno Haible  <bruno@clisp.org>
1690
1691         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
1692
1693 2007-03-24  Bruno Haible  <bruno@clisp.org>
1694
1695         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
1696         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
1697
1698         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
1699         * modules/utf8-ucs4: Turn into a symbolic link to module
1700         unistr/u8-mbtouc.
1701
1702         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
1703         utf8-ucs4-unsafe.
1704         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
1705         unistr/u8-mbtouc-unsafe.
1706
1707         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
1708         * modules/utf16-ucs4: Turn into a symbolic link to module
1709         unistr/u16-mbtouc.
1710
1711         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
1712         utf16-ucs4-unsafe.
1713         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
1714         unistr/u16-mbtouc-unsafe.
1715
1716         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
1717         * modules/ucs4-utf8: Turn into a symbolic link to module
1718         unistr/u8-ubtomb.
1719
1720         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
1721         * modules/ucs4-utf16: Turn into a symbolic link to module
1722         unistr/u16-ubtomb.
1723
1724 2007-03-24  Bruno Haible  <bruno@clisp.org>
1725
1726         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
1727         Enable the function only if HAVE_INLINE.
1728         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
1729         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
1730         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
1731         Enable the function only if HAVE_INLINE.
1732         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
1733         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
1734         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
1735         Enable the function only if HAVE_INLINE.
1736         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
1737         Enable the function only if HAVE_INLINE.
1738         * modules/utf8-ucs4: Update.
1739         * modules/utf8-ucs4-unsafe: Update.
1740         * modules/utf16-ucs4: Update.
1741         * modules/utf16-ucs4-unsafe: Update.
1742         * modules/ucs4-utf8: Update.
1743         * modules/ucs4-utf16: Update.
1744
1745 2007-03-24  Bruno Haible  <bruno@clisp.org>
1746
1747         * lib/utf8-ucs4.h: Remove file.
1748         * lib/utf8-ucs4-unsafe.h: Remove file.
1749         * lib/utf16-ucs4.h: Remove file.
1750         * lib/utf16-ucs4-unsafe.h: Remove file.
1751         * lib/ucs4-utf8.h: Remove file.
1752         * lib/ucs4-utf16.h: Remove file.
1753         * lib/unistr.h: Include their previous contents.
1754         * m4/utf-ucs4.m4: Remove file.
1755         * m4/ucs4-utf.m4: Remove file.
1756         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
1757         (Depends-on): Add unistr/base.
1758         (configure.ac): Remove gl_UTF_UCS4.
1759         (Makefile.am): Update.
1760         (Include): Change to unistr.h.
1761         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
1762         (Depends-on): Add unistr/base.
1763         (configure.ac): Remove gl_UTF_UCS4.
1764         (Makefile.am): Update.
1765         (Include): Change to unistr.h.
1766         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
1767         (Depends-on): Add unistr/base.
1768         (configure.ac): Remove gl_UTF_UCS4.
1769         (Makefile.am): Update.
1770         (Include): Change to unistr.h.
1771         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
1772         (Depends-on): Add unistr/base.
1773         (configure.ac): Remove gl_UTF_UCS4.
1774         (Makefile.am): Update.
1775         (Include): Change to unistr.h.
1776         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
1777         (Depends-on): Add unistr/base.
1778         (configure.ac): Remove gl_UCS4_UTF.
1779         (Makefile.am): Update.
1780         (Include): Change to unistr.h.
1781         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
1782         (Depends-on): Add unistr/base.
1783         (configure.ac): Remove gl_UCS4_UTF.
1784         (Makefile.am): Update.
1785         (Include): Change to unistr.h.
1786         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
1787         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
1788         utf8-ucs4-unsafe.h.
1789         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
1790         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
1791         utf16-ucs4-unsafe.h.
1792         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
1793         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
1794         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
1795         * lib/unistr/u8-strchr.c: Likewise.
1796         * lib/unistr/u8-strrchr.c: Likewise.
1797         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
1798         * lib/unistr/u16-strchr.c: Likewise.
1799         * lib/unistr/u16-strrchr.c: Likewise.
1800         * lib/striconveh.c: Update.
1801         * lib/linebreak.c: Update.
1802
1803 2007-03-24  Bruno Haible  <bruno@clisp.org>
1804
1805         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
1806         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
1807
1808 2007-03-22  Bruno Haible  <bruno@clisp.org>
1809
1810         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
1811
1812 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
1813
1814         * MODULES.html.sh (File system functions): New module write-any-file.
1815         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
1816         * m4/write-any-file.m4: New files.
1817
1818 2007-03-23  Eric Blake  <ebb9@byu.net>
1819
1820         * gnulib-tool: Rearrange space-tab sequences, since some editors
1821         like to eat them.
1822
1823 2007-03-23  Eric Blake  <ebb9@byu.net>
1824
1825         * lib/version-etc.c (version_etc_va): Update license wording to
1826         be more concise.  Recommended by Richard Stallman.
1827
1828 2007-03-22  Bruno Haible  <bruno@clisp.org>
1829
1830         * lib/poll.c (MSG_PEEK): New fallback definition.
1831
1832 2007-03-22  Bruno Haible  <bruno@clisp.org>
1833
1834         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
1835         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
1836         (main): Update.
1837         Fixes a compilation error on BeOS.
1838
1839 2007-03-22  Bruno Haible  <bruno@clisp.org>
1840
1841         * modules/frexpl-tests: New file.
1842         * tests/test-frexpl.c: New file.
1843
1844         * modules/frexpl: New file.
1845         * m4/frexpl.m4: New file.
1846         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
1847         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
1848         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
1849         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
1850         (Depends-on): Add frexpl. Remove isnanl-nolibm.
1851         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
1852
1853 2007-03-22  Bruno Haible  <bruno@clisp.org>
1854
1855         * lib/frexpl.c: Share code with lib/frexp.c.
1856         * modules/mathl (Files): Add lib/frexp.c.
1857         (Depends-on): Add isnanl-nolibm.
1858
1859 2007-03-22  Bruno Haible  <bruno@clisp.org>
1860
1861         * modules/printf-frexp (Files): Add m4/frexp.m4.
1862         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
1863         only if the found frexp function actually works.
1864
1865 2007-03-22  Bruno Haible  <bruno@clisp.org>
1866
1867         * lib/frexp.c: Remove older implementation that uses divisions.
1868
1869 2007-03-21  Bruno Haible  <bruno@clisp.org>
1870
1871         * modules/frexp-tests: New file.
1872         * tests/test-frexp.c: New file.
1873
1874         * modules/frexp: New file.
1875         * lib/frexp.c: New file.
1876         * m4/frexp.m4: New file.
1877         * lib/math_.h (frexp): New declaration.
1878         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
1879         REPLACE_FREXP.
1880         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
1881
1882 2007-03-21  Bruno Haible  <bruno@clisp.org>
1883
1884         * modules/isnanl-tests: New file.
1885         * tests/test-isnanl.c: New file.
1886
1887         * modules/isnanl: New file.
1888         * lib/isnanl.h: New file.
1889         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
1890         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
1891         gl_FUNC_ISNANL_WORKS.
1892         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
1893         New macros.
1894
1895 2007-03-21  Bruno Haible  <bruno@clisp.org>
1896
1897         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
1898         lib/isnanl.h.
1899         (Include): Update.
1900         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
1901         * lib/vasnprintf.c: Update.
1902         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
1903         tests/test-isnanl.h, remove tests/test-isnanl.c.
1904         (Makefile.am): Update.
1905         * tests/test-isnanl-nolibm.c: New file.
1906         * tests/test-isnanl.h: New file.
1907         * tests/test-isnanl.c: Remove file.
1908
1909 2007-03-21  Jim Meyering  <jim@meyering.net>
1910
1911         When trying to open ".", treat ESTALE like EACCES.
1912         * lib/savewd.c (savewd_save): Resort to forking not just upon
1913         failure with EACCES, but also when errno is ESTALE.
1914
1915 2007-03-20  Bruno Haible  <bruno@clisp.org>
1916
1917         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
1918         Needed on AIX 5.1. Reported by Matthew Woehlke.
1919
1920 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1921
1922         Suggestions by Bruno Haible:
1923         * lib/acl-internal.h: Include "gettext.h" rather than rolling
1924         our own.
1925         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
1926         * modules/acl (Depends-on): Add gettext.
1927
1928 2007-03-19  Bruno Haible  <bruno@clisp.org>
1929
1930         * modules/iconvme: Remove file.
1931         * lib/iconvme.h: Remove file.
1932         * lib/iconvme.c: Remove file.
1933         * m4/iconvme.m4: Remove file.
1934
1935 2007-03-19  Bruno Haible  <bruno@clisp.org>
1936
1937         * doc/relocatable-maint.texi: Break long shell script line.
1938         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1939
1940 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1941
1942         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
1943         handle file_has_acl.
1944         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
1945         * lib/acl.c: Move header inclusions and related macro defns into
1946         lib/acl-internal.h.
1947         (S_ISLNK): Remove defn, since that's now done for us.
1948         (file_has_acl): Move to lib/file-has-acl.c.
1949         Call acl_trivial if available.  This is the crucial part of the fix.
1950         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
1951         shared within the library.  Rewrite a bit, partly to make it compatible
1952         with the GNU coding style.
1953         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
1954         Remove unnecessary double-quotes.
1955         Don't test for acl_to_text; the build will catch that.
1956         Replace acl_entries if it doesn't exist and it is needed.
1957         Check for -lsec and acl_trivial (as used on Solaris 10).
1958         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
1959         lib/file-has-acl.c.
1960         (Depends-on): Add sys_stat, for S_ISLNK.
1961
1962 2007-03-19  Ben Pfaff  <blp@gnu.org>
1963
1964         * doc/gnulib.texi: Fix typos.
1965         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1966
1967 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1968
1969         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
1970         If size is zero here, buf must be zero.
1971
1972 2007-03-19  Simon Josefsson  <simon@josefsson.org>
1973
1974         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
1975         <bruno@clisp.org>.
1976
1977 2007-03-18  Bruno Haible  <bruno@clisp.org>
1978
1979         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
1980         Suggested by Eric Blake.
1981
1982 2007-03-18  Ben Pfaff  <blp@gnu.org>
1983
1984         * doc/relocatable.texi: Recommend using as prefix a directory
1985         that does not exist and will never be created.  Based on
1986         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
1987         and others.
1988
1989 2007-03-17  Bruno Haible  <bruno@clisp.org>
1990
1991         * lib/fchownat.c: Include lchown.h.
1992
1993 2007-03-17  Bruno Haible  <bruno@clisp.org>
1994
1995         Fix endless loop when the given allocated size was > INT_MAX.
1996         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
1997         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
1998         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
1999         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
2000         * lib/sprintf.c (sprintf): Likewise.
2001
2002 2007-03-17  Bruno Haible  <bruno@clisp.org>
2003
2004         * tests/test-argp-2.sh (func_compare): Output a context diff.
2005
2006 2007-03-17  Bruno Haible  <bruno@clisp.org>
2007
2008         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
2009         locale's decimal-point character.
2010
2011 2007-03-17  Bruno Haible  <bruno@clisp.org>
2012
2013         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
2014         before comparing it. Needed because on some platforms (e.g. x86) a
2015         'long double' occupies less bytes than sizeof (long double).
2016
2017 2007-03-17  Bruno Haible  <bruno@clisp.org>
2018
2019         * tests/test-crc.c (main): Make printf statements 64-bit clean.
2020         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
2021         * tests/test-getaddrinfo.c (simple): Likewise.
2022         * tests/test-read-file.c (main): Likewise.
2023
2024 2007-03-17  Bruno Haible  <bruno@clisp.org>
2025
2026         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
2027
2028 2007-03-17  Bruno Haible  <bruno@clisp.org>
2029
2030         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
2031         unused variable.
2032
2033 2007-03-17  Bruno Haible  <bruno@clisp.org>
2034
2035         * tests/test-c-strcasecmp.c: Include c-strcase.h.
2036         * tests/test-c-strncasecmp.c: Likewise.
2037
2038 2007-03-17  Bruno Haible  <bruno@clisp.org>
2039
2040         * modules/stdlib (Depends-on): Add unistd.
2041         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
2042         Needed for MacOS X 10.3.
2043
2044 2007-03-17  Bruno Haible  <bruno@clisp.org>
2045
2046         * lib/unistr/u-strdup.h: Include <stdlib.h>.
2047
2048 2007-03-17  Bruno Haible  <bruno@clisp.org>
2049
2050         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
2051
2052 2007-03-17  Bruno Haible  <bruno@clisp.org>
2053
2054         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
2055         to reflect files copied from gnulib (with or without modifications).
2056         Suggested by Jim Meyering.
2057
2058 2007-03-17  Eric Blake  <ebb9@byu.net>
2059
2060         * NEWS: Document stdlib change from 2007-02-18.
2061
2062 2007-03-17  Jim Meyering  <jim@meyering.net>
2063
2064         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
2065         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
2066         someone uses a name containing shell meta-characters.
2067         Reported by Alfred M. Szmidt.
2068
2069         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
2070
2071 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
2072
2073         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
2074         and copy gettext configuration files only if configure.ac contains
2075         a use of AM_GNU_GETTEXT_VERSION.
2076
2077 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
2078
2079         * build-aux/bootstrap (gnulib_name): New variable.
2080         (gnulib_tool_options): Use it.
2081
2082 2007-03-13  Simon Josefsson  <simon@josefsson.org>
2083
2084         * tests/test-des.c: Use new namespace.
2085
2086 2007-03-15  Bruno Haible  <bruno@clisp.org>
2087
2088         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
2089         Reported by James Youngman <jay@gnu.org>.
2090
2091 2007-03-15  Bruno Haible  <bruno@clisp.org>
2092
2093         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
2094         declared prototype. Needed with cc on OSF/1 5.1.
2095
2096 2007-03-15  Bruno Haible  <bruno@clisp.org>
2097
2098         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
2099         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
2100         (struct gl_list_implementation): Add dispose_fn argument to the
2101         'create_empty', 'create' methods.
2102         (struct gl_list_impl_base): Add field 'dispose_fn'.
2103         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
2104         argument.
2105         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
2106         dispose_fn argument.
2107         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
2108         dispose_fn on the dropped values.
2109         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
2110         dispose_fn argument.
2111         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
2112         dropped values.
2113         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
2114         (gl_tree_remove_node): Call dispose_fn on the dropped value.
2115         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
2116         (gl_tree_remove_node): Call dispose_fn on the dropped value.
2117         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
2118         argument.
2119         (gl_tree_list_free): Call dispose_fn on the dropped values.
2120         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
2121         the dropped values.
2122         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
2123         Add dispose_fn argument.
2124         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
2125         Call dispose_fn on the dropped values.
2126         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
2127         Add dispose_fn argument.
2128         (gl_sublist_create): Initialize the 'dispose_fn' field.
2129         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
2130         * tests/test-array_list.c (main): Update.
2131         * tests/test-carray_list.c (main): Update.
2132         * tests/test-avltree_list.c (main): Update.
2133         * tests/test-rbtree_list.c (main): Update.
2134         * tests/test-avltreehash_list.c (main): Update.
2135         * tests/test-rbtreehash_list.c (main): Update.
2136         * tests/test-linked_list.c (main): Update.
2137         * tests/test-linkedhash_list.c (main): Update.
2138         * tests/test-array_oset.c (main): Update.
2139
2140 2007-03-15  Bruno Haible  <bruno@clisp.org>
2141
2142         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
2143         (gl_oset_create_empty): Add dispose_fn argument.
2144         (struct gl_oset_implementation): Add dispose_fn argument to
2145         'create_empty' method.
2146         (struct gl_oset_impl_base): Add dispose_fn field.
2147         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
2148         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
2149         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
2150         values.
2151         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
2152         (gl_tree_oset_free): Call dispose_fn on the dropped values.
2153         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
2154         dropped value.
2155         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
2156         dropped value.
2157         * tests/test-array_oset.c (main): Update.
2158         * tests/test-avltree_oset.c (main): Update.
2159         * tests/test-rbtree_oset.c (main): Update.
2160         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
2161
2162 2007-03-13  Bruno Haible  <bruno@clisp.org>
2163
2164         * tests/test-stdbool.c (i): Update after last patch.
2165
2166 2007-03-12  Bruno Haible  <bruno@clisp.org>
2167
2168         * lib/quotearg.c: Include <wctype.h> early, before the definition of
2169         the iswprint macro. Needed on Solaris 2.5.1.
2170
2171 2007-03-12  Bruno Haible  <bruno@clisp.org>
2172
2173         * tests/test-printf-frexp.c (main): Declare x as volatile.
2174
2175 2007-03-12  Simon Josefsson  <simon@josefsson.org>
2176
2177         * doc/gnulib.texi (Build robot for gnulib): New section.
2178
2179 2007-03-12  Jim Meyering  <jim@meyering.net>
2180
2181         * build-aux/bootstrap: New file.
2182         * build-aux/bootstrap.conf: New file, from coreutils.
2183
2184 2007-03-11  Bruno Haible  <bruno@clisp.org>
2185
2186         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
2187
2188 2007-03-12  Simon Josefsson  <simon@josefsson.org>
2189
2190         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
2191         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
2192         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
2193
2194 2007-03-11  Bruno Haible  <bruno@clisp.org>
2195
2196         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
2197         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
2198
2199 2007-03-11  Bruno Haible  <bruno@clisp.org>
2200
2201         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
2202         formula. Needed for SunPRO C 5.0.
2203
2204 2007-03-11  Bruno Haible  <bruno@clisp.org>
2205
2206         * modules/long-options (Depends-on): Add getopt.
2207
2208 2007-03-11  Bruno Haible  <bruno@clisp.org>
2209
2210         * modules/modechange (Depends-on): Add stdbool.
2211
2212 2007-03-11  Bruno Haible  <bruno@clisp.org>
2213
2214         * modules/i-ring (Depends-on): Add stdbool.
2215
2216 2007-03-11  Bruno Haible  <bruno@clisp.org>
2217
2218         * modules/gc-des (Depends-on): Add stdbool.
2219
2220 2007-03-11  Bruno Haible  <bruno@clisp.org>
2221
2222         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
2223
2224 2007-03-11  Bruno Haible  <bruno@clisp.org>
2225
2226         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
2227
2228 2007-03-11  Bruno Haible  <bruno@clisp.org>
2229
2230         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
2231
2232 2007-03-11  Bruno Haible  <bruno@clisp.org>
2233
2234         * lib/vasnprintf.c (sprintf): Undefine.
2235
2236 2007-03-11  Bruno Haible  <bruno@clisp.org>
2237
2238         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
2239         initializers in SunPRO C and Compaq C compilers.
2240
2241 2007-03-11  Bruno Haible  <bruno@clisp.org>
2242
2243         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
2244         decrementing code ANSI C compliant.
2245
2246 2007-03-11  Bruno Haible  <bruno@clisp.org>
2247
2248         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
2249         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
2250
2251 2007-03-11  Bruno Haible  <bruno@clisp.org>
2252
2253         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
2254         <stdbool.h> substitute doesn't pass.
2255
2256 2007-03-11  Bruno Haible  <bruno@clisp.org>
2257
2258         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
2259
2260 2007-03-11  Bruno Haible  <bruno@clisp.org>
2261
2262         * gnulib-tool (func_create_megatestdir): Create also an autobuild
2263         script, for submission to autobuild.josefsson.org.
2264
2265 2007-03-10  Bruno Haible  <bruno@clisp.org>
2266
2267         * modules/canonicalize-lgpl-tests: New file.
2268         * tests/test-canonicalize-lgpl.sh: New file.
2269         * tests/test-canonicalize-lgpl.c: New file.
2270
2271         * modules/c-strcase-tests: New file.
2272         * tests/test-c-strcase.sh: New file.
2273         * tests/test-c-strcasecmp.c: New file.
2274         * tests/test-c-strncasecmp.c: New file.
2275
2276         * modules/atexit-tests: New file.
2277         * tests/test-atexit.sh: New file.
2278         * tests/test-atexit.c: New file.
2279
2280 2007-03-10  Bruno Haible  <bruno@clisp.org>
2281
2282         * tests/test-binary-io.sh: Use temporary filenames that are not so
2283         likely to clash with those of other tests (in a parallel make).
2284         * tests/test-binary-io.c: Likewise.
2285
2286 2007-03-10  Bruno Haible  <bruno@clisp.org>
2287
2288         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
2289         fallback; use #error instead.
2290         Suggested by Simon Josefsson.
2291
2292 2007-03-10  Bruno Haible  <bruno@clisp.org>
2293
2294         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
2295         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
2296         first and the last.
2297
2298 2007-03-10  Bruno Haible  <bruno@clisp.org>
2299
2300         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
2301
2302 2007-03-10  Bruno Haible  <bruno@clisp.org>
2303
2304         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
2305         "make distcheck".
2306         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
2307         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
2308         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
2309
2310 2007-03-10  Bruno Haible  <bruno@clisp.org>
2311
2312         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
2313         variable.
2314         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
2315         variable.
2316
2317 2007-03-09  Eric Blake  <ebb9@byu.net>
2318         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
2319
2320         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
2321         types are not being provided by gnulib.
2322         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
2323         types are supported.
2324
2325 2007-03-10  Bruno Haible  <bruno@clisp.org>
2326
2327         * lib/stdio_.h (__attribute__): New macro.
2328         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
2329         vsprintf): Specify __attribute__ __format__ for GCC.
2330         Suggested by Eric Blake.
2331
2332 2007-03-09  Bruno Haible  <bruno@clisp.org>
2333
2334         * modules/printf-posix-tests: New file.
2335         * tests/test-printf-posix.sh: New file.
2336         * tests/test-printf-posix.c: New file.
2337
2338         * modules/printf-posix: New file.
2339         * lib/printf.c: New file.
2340         * m4/printf-posix-rpl.m4: New file.
2341         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
2342         REPLACE_PRINTF.
2343         * lib/stdio_.h (printf): New declaration.
2344         (format, __format__, ____printf____, ____scanf____, ____strftime____,
2345         ____strfmon____): New macros.
2346         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
2347         REPLACE_PRINTF.
2348
2349 2007-03-09  Bruno Haible  <bruno@clisp.org>
2350
2351         * tests/test-vasnprintf-posix2.sh: New file.
2352         * tests/test-vasnprintf-posix2.c: New file.
2353         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
2354         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
2355         (Makefile.am): Activate test-vasnprintf-posix2.sh.
2356
2357         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
2358         a locale dependent decimal point, rather than always '.'.
2359
2360 2007-03-09  Eric Blake  <ebb9@byu.net>
2361
2362         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
2363         spite of platforms like Tandem/NSK that define it to -1.
2364
2365 2007-03-08  Bruno Haible  <bruno@clisp.org>
2366
2367         * modules/vprintf-posix-tests: New file.
2368         * tests/test-vprintf-posix.sh: New file.
2369         * tests/test-vprintf-posix.c: New file.
2370         * tests/test-printf-posix.h: New file.
2371
2372         * modules/vprintf-posix: New file.
2373         * lib/vprintf.c: New file.
2374         * m4/vprintf-posix.m4: New file.
2375         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
2376         REPLACE_VPRINTF.
2377         * lib/stdio_.h (vprintf): New declaration.
2378         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
2379         REPLACE_VPRINTF.
2380
2381 2007-03-08  Bruno Haible  <bruno@clisp.org>
2382
2383         * modules/fprintf-posix-tests: New file.
2384         * tests/test-fprintf-posix.sh: New file.
2385         * tests/test-fprintf-posix.c: New file.
2386
2387         * modules/fprintf-posix: New file.
2388         * lib/fprintf.c: New file.
2389         * m4/fprintf-posix.m4: New file.
2390         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
2391         REPLACE_FPRINTF.
2392         * lib/stdio_.h (fprintf): New declaration.
2393         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
2394         REPLACE_FPRINTF.
2395
2396 2007-03-08  Bruno Haible  <bruno@clisp.org>
2397
2398         * modules/vfprintf-posix-tests: New file.
2399         * tests/test-vfprintf-posix.sh: New file.
2400         * tests/test-vfprintf-posix.c: New file.
2401         * tests/test-fprintf-posix.h: New file.
2402         * tests/test-fprintf-posix.out: New file.
2403
2404         * modules/vfprintf-posix: New file.
2405         * lib/vfprintf.c: New file.
2406         * m4/vfprintf-posix.m4: New file.
2407         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
2408         REPLACE_VFPRINTF.
2409         * lib/stdio_.h (vfprintf): New declaration.
2410         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
2411         REPLACE_VFPRINTF.
2412
2413 2007-03-08  Bruno Haible  <bruno@clisp.org>
2414
2415         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
2416
2417 2007-03-08  Bruno Haible  <bruno@clisp.org>
2418
2419         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
2420         instead of 'expr' invocations.
2421         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2422         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2423         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2424         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2425         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2426         Suggested by Paul Eggert.
2427
2428 2007-03-08  Bruno Haible  <bruno@clisp.org>
2429
2430         * modules/fseterr-tests: New file.
2431         * tests/test-fseterr.c: New file.
2432
2433         * modules/fseterr: New file.
2434         * lib/fseterr.h: New file.
2435         * lib/fseterr.c: New file.
2436
2437 2007-03-08  Bruno Haible  <bruno@clisp.org>
2438
2439         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
2440         * lib/getopt_.h: Likewise.
2441         * lib/mbswidth.h: Likewise.
2442         * lib/setenv.h: Likewise.
2443         * lib/vasnprintf.h: Likewise.
2444         * lib/vasprintf.h: Likewise.
2445         * lib/verror.h: Likewise.
2446         * lib/xsetenv.h: Likewise.
2447         * lib/xvasprintf.h: Likewise.
2448
2449 2007-03-08  Jim Meyering  <jim@meyering.net>
2450
2451         * users.txt: Add parted.
2452
2453         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
2454
2455 2007-03-07  Bruno Haible  <bruno@clisp.org>
2456
2457         * m4/printf.m4: Make the shell script snippets copy&pastable.
2458
2459 2007-03-02  Bruno Haible  <bruno@clisp.org>
2460
2461         * lib/netinet_in_.h: New file.
2462         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
2463         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
2464         * modules/netinet_in (Files): Add lib/netinet_in_.h.
2465         (Depends-on): Add absolute-header.
2466         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
2467         into netinet/in.h.
2468
2469 2007-03-03  Bruno Haible  <bruno@clisp.org>
2470
2471         * lib/sys_select_.h: New file.
2472         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
2473         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
2474         * modules/sys_select (Files): Add lib/sys_select_.h.
2475         (Depends-on): Add absolute-header.
2476         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
2477         into sys/select.h.
2478
2479 2007-03-02  Bruno Haible  <bruno@clisp.org>
2480
2481         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
2482         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
2483         values.
2484         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
2485         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
2486         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
2487         * modules/sys_socket (Depends-on): Add absolute-header.
2488         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
2489         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
2490         (Include): Remove requirement of inclusion of <sys/types.h>.
2491
2492 2007-03-02  Bruno Haible  <bruno@clisp.org>
2493
2494         * lib/byteswap_.h (bswap_32): Fix formula.
2495
2496 2007-03-06  Bruno Haible  <bruno@clisp.org>
2497
2498         * modules/sprintf-posix-tests: New file.
2499         * tests/test-sprintf-posix.c: New file.
2500
2501         * modules/sprintf-posix: New file.
2502         * lib/sprintf.c: New file.
2503         * m4/sprintf-posix.m4: New file.
2504         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
2505         REPLACE_SPRINTF.
2506         * lib/stdio_.h (sprintf): New declaration.
2507         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
2508         REPLACE_SPRINTF.
2509
2510 2007-03-06  Bruno Haible  <bruno@clisp.org>
2511
2512         * modules/vsprintf-posix-tests: New file.
2513         * tests/test-vsprintf-posix.c: New file.
2514         * tests/test-sprintf-posix.h: New file.
2515
2516         * modules/vsprintf-posix: New file.
2517         * lib/vsprintf.c: New file.
2518         * m4/vsprintf-posix.m4: New file.
2519         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
2520         REPLACE_VSPRINTF.
2521         * lib/stdio_.h (vsprintf): New declaration.
2522         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
2523         REPLACE_VSPRINTF.
2524
2525 2007-03-06  Bruno Haible  <bruno@clisp.org>
2526
2527         * modules/vsnprintf (Depend-on): Remove minmax.
2528
2529 2007-03-06  Bruno Haible  <bruno@clisp.org>
2530
2531         * modules/snprintf-posix-tests: New file.
2532         * tests/test-snprintf-posix.c: New file.
2533
2534         * modules/snprintf-posix: New file.
2535         * m4/snprintf-posix.m4: New file.
2536         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
2537         gl_FUNC_SNPRINTF.
2538         (gl_FUNC_SNPRINTF): Invoke it.
2539         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
2540         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
2541         is set.
2542         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
2543
2544 2007-03-06  Bruno Haible  <bruno@clisp.org>
2545
2546         * modules/vsnprintf-posix-tests: New file.
2547         * tests/test-vsnprintf-posix.c: New file.
2548         * tests/test-snprintf-posix.h: New file.
2549
2550         * modules/vsnprintf-posix: New file.
2551         * m4/vsnprintf-posix.m4: New file.
2552         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
2553         gl_FUNC_VSNPRINTF.
2554         (gl_FUNC_VSNPRINTF): Invoke it.
2555         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
2556         * lib/stdio_.h (vsnprintf): Define as a replacement if
2557         REPLACE_VSNPRINTF is set.
2558         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
2559
2560 2007-03-06  Bruno Haible  <bruno@clisp.org>
2561
2562         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
2563         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
2564
2565 2007-03-06  Bruno Haible  <bruno@clisp.org>
2566
2567         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
2568         (asinl): Declare also if HAVE_DECL_ASINL is set.
2569         (atanl): Declare also if HAVE_DECL_ATANL is set.
2570         (ceill): Declare also if HAVE_DECL_CEILL is set.
2571         (cosl): Declare also if HAVE_DECL_COSL is set.
2572         (expl): Declare also if HAVE_DECL_EXPL is set.
2573         (floorl): Declare also if HAVE_DECL_FLOORL is set.
2574         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
2575         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
2576         (logl): Declare also if HAVE_DECL_LOGL is set.
2577         (sinl): Declare also if HAVE_DECL_SINL is set.
2578         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
2579         (tanl): Declare also if HAVE_DECL_TANL is set.
2580         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
2581         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
2582         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
2583         declaration of frexpl, ldexpl.
2584         * modules/printf-frexpl (Depends-on): Add math.
2585         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
2586
2587 2007-03-05  Bruno Haible  <bruno@clisp.org>
2588
2589         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
2590         frexpl and ldexpl are declared.
2591         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
2592
2593 2007-03-05  Bruno Haible  <bruno@clisp.org>
2594
2595         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
2596         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
2597
2598 2007-03-05  Bruno Haible  <bruno@clisp.org>
2599
2600         * lib/stdio_.h: Include <stddef.h>.
2601
2602 2007-03-05  Bruno Haible  <bruno@clisp.org>
2603
2604         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
2605
2606 2007-03-05  Bruno Haible  <bruno@clisp.org>
2607
2608         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
2609         NetBSD 4, from Ralf Wildenhues.
2610
2611 2007-03-04  Bruno Haible  <bruno@clisp.org>
2612
2613         * lib/vasprintf.h: Update #if logic for the case when the functions
2614         exist but are overridden.
2615
2616 2007-03-04  Bruno Haible  <bruno@clisp.org>
2617
2618         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
2619         implementations: glibc-2.4 and MacOS X 10.3.
2620         * tests/test-vasnprintf-posix.c (test_function): Test also the case
2621         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
2622         * tests/test-vasprintf-posix.c (test_function): Likewise.
2623
2624 2007-03-04  Bruno Haible  <bruno@clisp.org>
2625
2626         * modules/vasprintf-posix-tests: New file.
2627         * tests/test-vasprintf-posix.c: New file.
2628
2629         * modules/vasprintf-posix: New file.
2630         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
2631         defined.
2632         * m4/vasprintf-posix.m4: New file.
2633         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
2634         gl_FUNC_VASPRINTF.
2635         (gl_FUNC_VASPRINTF): Invoke it.
2636         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
2637         here.
2638         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
2639
2640 2007-03-04  Bruno Haible  <bruno@clisp.org>
2641
2642         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
2643         REPLACE_GETTIMEOFDAY.
2644         * modules/sys_time (Makefile.am): Likewise.
2645         * m4/sys_time_h.m4: Likewise.
2646         * m4/gettimeofday.m4: Likewise.
2647
2648 2007-03-04  Bruno Haible  <bruno@clisp.org>
2649
2650         * modules/vasnprintf-posix-tests: New file.
2651         * tests/test-vasnprintf-posix.c: New file.
2652
2653         * modules/vasnprintf-posix: New file.
2654         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
2655         printf-frexpl.h.
2656         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
2657         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
2658         REPLACE_VASNPRINTF is defined.
2659         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
2660         gl_FUNC_VASNPRINTF.
2661         (gl_FUNC_VASNPRINTF): Invoke it.
2662         * m4/vasnprintf-posix.m4: New file.
2663         * m4/printf.m4: New file.
2664
2665 2007-03-04  Bruno Haible  <bruno@clisp.org>
2666
2667         Compile progreloc.c only if --enable-relocatable is specified.
2668         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
2669         if --enable-relocatable was specified.
2670         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
2671         lib_SOURCES.
2672
2673 2007-03-04  Jim Meyering  <jim@meyering.net>
2674
2675         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
2676         Use it consistently, rather than enumerating errno constants.
2677
2678 2007-03-04  Bruno Haible  <bruno@clisp.org>
2679
2680         * modules/xvasprintf-tests: New file.
2681         * tests/test-xvasprintf.c: New file.
2682
2683         * modules/vasprintf-tests: New file.
2684         * tests/test-vasprintf.c: New file.
2685
2686         * modules/vasnprintf-tests: New file.
2687         * tests/test-vasnprintf.c: New file.
2688
2689         * modules/vsnprintf-tests: New file.
2690         * tests/test-vsnprintf.c: New file.
2691
2692         * modules/snprintf-tests: New file.
2693         * tests/test-snprintf.c: New file.
2694
2695 2007-03-04  Bruno Haible  <bruno@clisp.org>
2696
2697         Compile relocatable.c only if --enable-relocatable is specified.
2698         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
2699         gl_RELOCATABLE_LIBRARY.
2700         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
2701         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
2702         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
2703         gl_RELOCATABLE_LIBRARY.
2704         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
2705         (Makefile.am): Remove lib_SOURCES.
2706         * modules/relocatable-lib-lgpl (configure.ac): Invoke
2707         gl_RELOCATABLE_LIBRARY.
2708         (Makefile.am): Remove lib_SOURCES.
2709         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
2710         always.
2711         * modules/relocatable-prog-wrapper (configure.ac): Invoke
2712         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
2713
2714 2007-03-04  Bruno Haible  <bruno@clisp.org>
2715
2716         * modules/argmatch-tests: New file.
2717         * tests/test-argmatch.c: New file.
2718
2719         * tests/test-allocsa.c (main): Halve the number of loop runs.
2720
2721         * modules/alloca-opt-tests: New file.
2722         * tests/test-alloca-opt.c: New file.
2723
2724 2007-03-04  Jim Meyering  <jim@meyering.net>
2725
2726         Work around difference between Linux ACLs and Solaris 10 ZFS.
2727         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
2728         for EINVAL.
2729
2730 2007-03-03  Bruno Haible  <bruno@clisp.org>
2731
2732         * modules/relocatable-prog (Depends-on): Add back progreloc's
2733         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
2734
2735 2007-03-03  Bruno Haible  <bruno@clisp.org>
2736
2737         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
2738         * modules/relocatable-lib: New file.
2739
2740 2007-03-03  Bruno Haible  <bruno@clisp.org>
2741
2742         * modules/relocatable-prog: Renamed from modules/relocatable.
2743         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
2744
2745 2007-03-03  Bruno Haible  <bruno@clisp.org>
2746
2747         * modules/relocatable-script (Files): Add doc/relocatable.texi,
2748         m4/relocatable-lib.m4.
2749         (Depends-on): Remove 'relocatable'.
2750         (configure.ac): Add gl_RELOCATABLE_NOP.
2751
2752 2007-03-03  Bruno Haible  <bruno@clisp.org>
2753
2754         * modules/relocatable-prog-wrapper: New file.
2755         * modules/relocatable (Depends-on): Add it. Remove all other
2756         dependencies except progname.
2757         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
2758
2759         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
2760         (gl_FUNC_STRERROR): Nop.
2761         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
2762
2763         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
2764         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
2765
2766         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
2767         (gl_FUNC_READLINK): Update.
2768
2769         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
2770
2771 2007-03-03  Bruno Haible  <bruno@clisp.org>
2772
2773         * lib/xreadlink.c: Include <unistd.h> unconditionally.
2774         * modules/xreadlink (Depends-on): Add unistd.
2775         * modules/xreadlink-with-size (Depends-on): Likewise.
2776
2777 2007-03-03  Bruno Haible  <bruno@clisp.org>
2778
2779         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
2780         extracted from gt_FUNC_SETENV.
2781         (gt_FUNC_SETENV): Remove macro.
2782         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
2783         remove gt_FUNC_SETENV.
2784
2785 2007-03-03  Bruno Haible  <bruno@clisp.org>
2786
2787         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
2788         ENABLE_RELOCATABLE here.
2789         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
2790
2791 2007-03-03  Bruno Haible  <bruno@clisp.org>
2792
2793         * modules/rbtreehash-list-tests (Depends-on): Add progname.
2794         * tests/test-rbtreehash_list.c: Include progname.h.
2795         (main): Call set_program_name.
2796
2797         * modules/rbtree-oset-tests (Depends-on): Add progname.
2798         * tests/test-rbtree_oset.c: Include progname.h.
2799         (main): Call set_program_name.
2800
2801         * modules/rbtree-list-tests (Depends-on): Add progname.
2802         * tests/test-rbtree_list.c: Include progname.h.
2803         (main): Call set_program_name.
2804
2805         * modules/linked-list-tests (Depends-on): Add progname.
2806         * tests/test-linked_list.c: Include progname.h.
2807         (main): Call set_program_name.
2808
2809 2007-03-03  Bruno Haible  <bruno@clisp.org>
2810
2811         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
2812         All uses of __restrict changed to _Restrict_.
2813         * lib/glob_.h (__restrict): Remove macro.
2814
2815 2007-03-02  Bruno Haible  <bruno@clisp.org>
2816
2817         * modules/gettext (configure.ac): Require gettext infrastructure
2818         from version 0.16.1.
2819
2820 2007-03-02  Bruno Haible  <bruno@clisp.org>
2821
2822         * modules/linkedhash-list-tests (Depends-on): Add progname.
2823         * tests/test-linkedhash_list.c: Include progname.h.
2824         (main): Call set_program_name.
2825
2826         * modules/carray-list-tests (Depends-on): Add progname.
2827         * tests/test-carray_list.c: Include progname.h.
2828         (main): Call set_program_name.
2829
2830         * modules/avltreehash-list-tests (Depends-on): Add progname.
2831         * tests/test-avltreehash_list.c: Include progname.h.
2832         (main): Call set_program_name.
2833
2834         * modules/avltree-oset-tests (Depends-on): Add progname.
2835         * tests/test-avltree_oset.c: Include progname.h.
2836         (main): Call set_program_name.
2837
2838         * modules/avltree-list-tests (Depends-on): Add progname.
2839         * tests/test-avltree_list.c: Include progname.h.
2840         (main): Call set_program_name.
2841
2842         * modules/array-oset-tests (Depends-on): Add progname.
2843         * tests/test-array_oset.c: Include progname.h.
2844         (main): Call set_program_name.
2845
2846         * modules/array-list-tests (Depends-on): Add progname.
2847         * tests/test-array_list.c: Include progname.h.
2848         (main): Call set_program_name.
2849
2850         * modules/argp-tests (Depends-on): Add progname.
2851         * tests/test-argp.c: Include argp.h first. Include progname.h.
2852         (main): Call set_program_name.
2853
2854 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
2855
2856         * doc/gnulib-tool.texi (Initial import): Reword description of
2857         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
2858         limited effect even if defined after the first system include.
2859
2860 2007-03-01  Bruno Haible  <bruno@clisp.org>
2861
2862         * build-aux/config.libpath: Update to libtool-1.5.22.
2863         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
2864
2865 2007-03-01  Bruno Haible  <bruno@clisp.org>
2866
2867         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
2868         foo_CFLAGS.
2869         Reported by Ralf Wildenhues.
2870
2871 2007-03-01  Bruno Haible  <bruno@clisp.org>
2872
2873         * build-aux/install-reloc: Remove object files left over by some
2874         compilers.
2875         Reported by Ralf Wildenhues.
2876
2877 2007-03-01  Bruno Haible  <bruno@clisp.org>
2878
2879         * build-aux/install-reloc: Break long lines.
2880
2881 2007-03-01  Bruno Haible  <bruno@clisp.org>
2882
2883         * doc/relocatable.texi: Document that it may not work on OpenBSD.
2884         Reported by Ralf Wildenhues.
2885
2886 2007-03-01  Bruno Haible  <bruno@clisp.org>
2887
2888         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
2889         include ordering constraints.
2890
2891 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
2892
2893         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
2894         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
2895         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
2896         as another example.
2897         * lib/time_.h: Fix misspelling.
2898         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
2899         Require gl_HEADER_TIME_H_DEFAULTS.
2900         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
2901         * m4/time_r.m4 (gl_TIME_R): Likewise.
2902         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
2903
2904 2007-03-01  Bruno Haible  <bruno@clisp.org>
2905
2906         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
2907         * m4/utimens.m4 (gl_UTIMENS): Likewise.
2908
2909 2007-03-01  Jim Meyering  <jim@meyering.net>
2910
2911         * modules/xreadlink (Maintainer): Add my name.
2912         * modules/xreadlink-with-size (Depends-on): Alphabetize.
2913
2914 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
2915             Bruno Haible  <bruno@clisp.org>
2916
2917         * build-aux/install-reloc: Compile also c-ctype.c.
2918         * build-aux/relocatable.sh.in: New file.
2919         * doc/relocatable.texi: New file.
2920         * doc/relocatable-maint.texi: New file.
2921         * doc/gnulib.texi: Include relocatable-maint.texi.
2922         * lib/progreloc.c: Include unistd.h unconditionally.
2923         * lib/relocwrapper.c: Include unistd.h unconditionally.
2924         Include c-ctype.h.
2925         (add_dotbin): Use c_tolower.
2926         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
2927         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
2928         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
2929         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
2930         to m4/relocatable-lib.m4.
2931         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
2932         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
2933         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
2934         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
2935         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
2936         * modules/relocatable: New file.
2937         * modules/relocatable-lib: New file.
2938         * modules/relocatable-script: New file.
2939
2940 2007-02-28  Bruno Haible  <bruno@clisp.org>
2941
2942         Import --enable-relocatable infrastructure.
2943         * build-aux/config.libpath: New file, from GNU gettext.
2944         * build-aux/install-reloc: New file, from GNU gettext.
2945         * build-aux/reloc-ldflags: New file, from GNU gettext.
2946         * lib/relocatable.h: New file, from GNU gettext.
2947         * lib/relocatable.c: New file, from GNU gettext.
2948         * lib/relocwrapper.c: New file, from GNU gettext.
2949         * m4/relocatable.m4: New file, from GNU gettext.
2950
2951 2007-02-28  Bruno Haible  <bruno@clisp.org>
2952
2953         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
2954
2955         * modules/xreadlink: New file, from GNU gettext with modifications.
2956         * lib/xreadlink.c: New file, from GNU gettext.
2957         * lib/xreadlink.h: Add comments.
2958         (xreadlink): New declaration.
2959
2960         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
2961         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
2962         lib/xreadlink-with-size.c.
2963         (configure.ac): Remove gl_XREADLINK invocation.
2964         (Makefile.am): Augment lib_SOURCES.
2965         * m4/xreadlink.m4: Remove file.
2966         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
2967         (xreadlink_with_size): Renamed from xreadink.
2968         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
2969         * modules/canonicalize (Depends-on): Replace xreadlink with
2970         xreadlink-with-size.
2971         * lib/canonicalize.c (canonicalize_filename_mode): Update.
2972
2973 2007-02-25  Jim Meyering  <jim@meyering.net>
2974
2975         * build-aux/announce-gen: When complaining about excess arguments,
2976         list them.
2977
2978 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
2979
2980         * README: Document signed integer overflow situation more
2981         accurately.
2982
2983 2007-02-25  Bruno Haible  <bruno@clisp.org>
2984
2985         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
2986         'a' or 'A' conversion.
2987
2988 2007-02-25  Bruno Haible  <bruno@clisp.org>
2989
2990         * modules/filename: Renamed from modules/pathname.
2991         (Files): Replace lib/pathname.h with lib/filename.h. Replace
2992         lib/concatpath.c with lib/concat-filename.c.
2993         (Makefile.am): Update.
2994         (Include): Replace pathname.h with filename.h.
2995         * lib/filename.h: Renamed from lib/pathname.h.
2996         (concatenated_filename): Renamed from concatenated_pathname.
2997         * lib/concat-filename.c: Renamed from lib/concatpath.c.
2998         (concatenated_filename): Renamed from concatenated_pathname.
2999         * lib/findprog.c: Include filename.h instead of pathname.h.
3000         (find_in_path): Update.
3001         * lib/javacomp.c: Include filename.h instead of pathname.h.
3002         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
3003         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
3004         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
3005         is_oldgcj_14_13_usable, is_javac_usable): Update.
3006         * lib/javaexec.c: Include filename.h instead of pathname.h.
3007         (execute_java_class): Update.
3008         * modules/findprog: Update.
3009         * modules/javacomp: Update.
3010         * modules/javaexec: Update.
3011         * MODULES.html.sh (File system functions): Add 'filename', remove
3012         'pathname'.
3013
3014 2007-02-25  Bruno Haible  <bruno@clisp.org>
3015
3016         * modules/printf-frexpl-tests: New file.
3017         * tests/test-printf-frexpl.c: New file.
3018
3019         * modules/printf-frexpl: New file.
3020         * lib/printf-frexpl.h: New file.
3021         * lib/printf-frexpl.c: New file.
3022         * m4/printf-frexpl.m4: New file.
3023
3024 2007-02-25  Bruno Haible  <bruno@clisp.org>
3025
3026         * modules/printf-frexp-tests: New file.
3027         * tests/test-printf-frexp.c: New file.
3028
3029         * modules/printf-frexp: New file.
3030         * lib/printf-frexp.h: New file.
3031         * lib/printf-frexp.c: New file.
3032         * m4/printf-frexp.m4: New file.
3033
3034 2007-02-25  Bruno Haible  <bruno@clisp.org>
3035
3036         Assume automake >= 1.10 for the tests.
3037         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
3038         * modules/arctwo-tests: Likewise.
3039         * modules/argp-tests: Likewise.
3040         * modules/avltree-list-tests: Likewise.
3041         * modules/avltree-oset-tests: Likewise.
3042         * modules/avltreehash-list-tests: Likewise.
3043         * modules/carray-list-tests: Likewise.
3044         * modules/crc-tests: Likewise.
3045         * modules/des-tests: Likewise.
3046         * modules/gc-arcfour-tests: Likewise.
3047         * modules/gc-arctwo-tests: Likewise.
3048         * modules/gc-des-tests: Likewise.
3049         * modules/gc-hmac-md5-tests: Likewise.
3050         * modules/gc-hmac-sha1-tests: Likewise.
3051         * modules/gc-md2-tests: Likewise.
3052         * modules/gc-md4-tests: Likewise.
3053         * modules/gc-md5-tests: Likewise.
3054         * modules/gc-pbkdf2-sha1-tests: Likewise.
3055         * modules/gc-rijndael-tests: Likewise.
3056         * modules/gc-sha1-tests: Likewise.
3057         * modules/gc-tests: Likewise.
3058         * modules/getaddrinfo-tests: Likewise.
3059         * modules/hmac-md5-tests: Likewise.
3060         * modules/hmac-sha1-tests: Likewise.
3061         * modules/linked-list-tests: Likewise.
3062         * modules/linkedhash-list-tests: Likewise.
3063         * modules/lock-tests: Likewise.
3064         * modules/md2-tests: Likewise.
3065         * modules/md4-tests: Likewise.
3066         * modules/md5-tests: Likewise.
3067         * modules/rbtree-list-tests: Likewise.
3068         * modules/rbtree-oset-tests: Likewise.
3069         * modules/rbtreehash-list-tests: Likewise.
3070         * modules/read-file-tests: Likewise.
3071         * modules/rijndael-tests: Likewise.
3072         * modules/stdint-tests: Likewise.
3073         * modules/tls-tests: Likewise.
3074
3075 2007-02-24  Bruno Haible  <bruno@clisp.org>
3076
3077         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
3078         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
3079         function; instead check whether isnan with a double argument links.
3080         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
3081         function; instead check whether isnan with a 'long double' argument
3082         links.
3083         Reported by Eric Blake <ebb9@byu.net>.
3084
3085 2007-02-24  Bruno Haible  <bruno@clisp.org>
3086
3087         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
3088         defined.
3089         * lib/isnanl.c: Remove all code. Just include isnan.c.
3090         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
3091
3092 2007-02-25  Jim Meyering  <jim@meyering.net>
3093
3094         Avoid conflicting types for 'unsetenv' on FreeBSD.
3095         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
3096         conflicting with FreeBSD's (5.0 and 6.1) function declaration
3097         in stdlib.h.
3098
3099 2007-02-24  Bruno Haible  <bruno@clisp.org>
3100
3101         * modules/isnanl-nolibm-tests: New file.
3102         * tests/test-isnanl.c: New file.
3103
3104         * modules/isnanl-nolibm: New file.
3105         * lib/isnanl.h: New file.
3106         * lib/isnanl.c: New file.
3107         * m4/isnanl.m4: New file.
3108
3109 2007-02-24  Bruno Haible  <bruno@clisp.org>
3110
3111         * modules/isnan-nolibm-tests: New file.
3112         * tests/test-isnan.c: New file.
3113
3114         * modules/isnan-nolibm: New file.
3115         * lib/isnan.h: New file.
3116         * lib/isnan.c: New file.
3117         * m4/isnan.m4: New file.
3118
3119 2007-02-24  Bruno Haible  <bruno@clisp.org>
3120
3121         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
3122         assume that an exponent fits in 20 bits.
3123
3124 2007-02-24  Jim Meyering  <jim@meyering.net>
3125
3126         * m4/regex.m4: Update the description of the configure-time option,
3127         --without-included-regex, to state accurately what the defaults are,
3128         and perhaps to give people an idea why using this option is risky.
3129
3130 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
3131
3132         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
3133         loops on small arguments.  This attempts to avoid the problem
3134         Bruno Haible reported for AIX 4.3.2 in
3135         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
3136
3137 2007-02-23  Bruno Haible  <bruno@clisp.org>
3138
3139         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
3140         Needed for help2man.
3141
3142 2007-02-23  Karl Berry  <karl@gnu.org>
3143
3144         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
3145         exists, foo.h should be cvs-ignored, not committed.
3146
3147 2007-02-23  Eric Blake  <ebb9@byu.net>
3148
3149         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
3150         * lib/stat-time.h (includes): Likewise.
3151         * lib/utimecmp.c (includes): Likewise.
3152         * lib/utimens.h (includes): Likewise.
3153         * lib/getdate.y (includes): Also include "timespec.h" for use
3154         internal to the module.
3155         * modules/utimens (Depends-on): Revert yesterday's patch.
3156         * modules/nanosleep (Depends-on): Add missing dependency.
3157
3158 2007-02-22  Bruno Haible  <bruno@clisp.org>
3159
3160         * lib/glob.c: Don't include getlogin_r.h.
3161
3162 2007-02-22  Jim Meyering  <jim@meyering.net>
3163
3164         * modules/utimens (Depends-on): Add timespec, required for
3165         utimens.h's inclusion of timespec.h.
3166
3167 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
3168
3169         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
3170         long unreadable paths in GNU/Linux.  Problem reported by Andreas
3171         Schwab in
3172         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
3173         I'll try to think of a better way to fix the Solaris problem.
3174
3175         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
3176         like glibc; on Solaris 10, it fails with errno == EINVAL.
3177         POSIX says the behavior is unspecified if the first argument is NULL,
3178         so play it safe and never pass NULL to the system getcwd.
3179
3180 2007-02-21  Jim Meyering  <jim@meyering.net>
3181
3182         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
3183         of gettimeofday.  It would conflict with the one now always
3184         provided via sys_time_.h.  Reported by Matthew Woehlke, as
3185         an IRIX 6.5 build failure.
3186
3187 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
3188
3189         Minor fixups to port to Solaris 10 with Sun C 5.8.
3190         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
3191         * modules/getcwd (Depends-on): Add dirfd.
3192         * lib/putenv.c (putenv): #undef it.
3193         (rpl_putenv): New decl.
3194         (malloc, free): Include <stdlib.h> rather than prototyping separately.
3195
3196 2007-02-20  Bruno Haible  <bruno@clisp.org>
3197
3198         * modules/stdio-tests: New file.
3199         * tests/test-stdio.c: New file.
3200
3201         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
3202         (Depends-on): Add stdio.
3203         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
3204         (Include): Use <stdio.h> instead of vsnprintf.h.
3205         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
3206         HAVE_DECL_VSNPRINTF.
3207         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
3208
3209         * modules/snprintf (Files): Remove lib/snprintf.h.
3210         (Depends-on): Add stdio.
3211         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
3212         (Include): Use <stdio.h> instead of snprintf.h.
3213         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
3214         HAVE_DECL_SNPRINTF.
3215         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
3216         * lib/getaddrinfo.c: Likewise.
3217
3218         * modules/stdio: New file.
3219         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
3220         * lib/snprintf.h: Remove file.
3221         * lib/vsnprintf.h: Remove file.
3222         * lib/.cppi-disable: Remove snprintf.h.
3223         * m4/stdio_h.m4: New file.
3224         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
3225
3226 2007-02-20  Jim Meyering  <jim@meyering.net>
3227
3228         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
3229         used by e.g., mingw.  From Bruno Haible.
3230
3231 2007-02-19  Bruno Haible  <bruno@clisp.org>
3232
3233         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
3234         warnings.
3235         Reported by Ben Pfaff <blp@cs.stanford.edu>.
3236
3237 2007-02-19  Bruno Haible  <bruno@clisp.org>
3238
3239         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
3240         from mingw users.
3241
3242 2007-02-19  Bruno Haible  <bruno@clisp.org>
3243
3244         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
3245         warnings.
3246         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
3247
3248 2007-02-19  Jim Meyering  <jim@meyering.net>
3249
3250         Don't use FD after a successful "fdopendir (fd)".
3251         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
3252         Reset it by calling dirfd on the just-obtained DIR*.
3253
3254         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
3255         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
3256
3257 2007-02-18  Bruno Haible  <bruno@clisp.org>
3258
3259         * lib/readlink.c: Include <unistd.h>.
3260         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
3261         HAVE_READLINK.
3262         * modules/readlink (Depends-on): Add unistd.
3263         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3264         (Include): Add <unistd.h>.
3265
3266         * lib/getlogin_r.h: Remove file.
3267         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
3268         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
3269         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
3270         HAVE_DECL_GETLOGIN_R.
3271         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
3272         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3273         (Include): Use <unistd.h> instead of getlogin_r.h.
3274
3275         * lib/getcwd.h: Remove file.
3276         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
3277         * lib/xgetcwd.c: Likewise.
3278         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
3279         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
3280         * modules/getcwd (Files): Remove lib/getcwd.h.
3281         (Depends-on): Add unistd.
3282         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3283         (Include): Use <unistd.h> instad of getcwd.h.
3284
3285         * lib/ftruncate.c: Include <unistd.h> first.
3286         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
3287         Set HAVE_FTRUNCATE.
3288         * modules/ftruncate (Depends-on): Add unistd.
3289         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3290
3291         * lib/fchdir.c: Include <unistd.h> first.
3292         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
3293         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
3294         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
3295         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3296         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
3297
3298         * lib/dup2.c: Include <unistd.h> first.
3299         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
3300         HAVE_DUP2.
3301         * modules/dup2 (Depends-on): Add unistd.
3302         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3303
3304         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
3305         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
3306         REPLACE_CHOWN. Don't define chown as a macro here.
3307         * modules/chown (Depends-on): Add unistd.
3308         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3309
3310         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
3311         Add definition for GL_LINK_WARNING.
3312         (chown, dup2): New declarations.
3313         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
3314         link warning.
3315         (ftruncate): New declaration.
3316         (getcwd): New declaration, taken from old getcwd.h.
3317         (getlogin_r): New declaration, taken from old getlogin_r.h.
3318         (readlink): New declaration.
3319         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
3320         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
3321         (gl_PREREQ_UNISTD): Remove macro.
3322         (gl_UNISTD_MODULE_INDICATOR): New macro.
3323         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
3324         many new variables. Don't set UNISTD_H.
3325         * modules/unistd (Description): Change.
3326         (Depends-on): Add link-warning.
3327         (configure.ac): Update.
3328         (Makefile.am): Create unistd.h always. Substitute many new variables
3329         into it.
3330
3331 2007-02-18  Bruno Haible  <bruno@clisp.org>
3332
3333         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
3334         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
3335         HAVE_GETSUBOPT.
3336         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
3337         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
3338         * lib/getsubopt.h: Remove file.
3339         * modules/getsubopt (Files): Remove lib/getsubopt.h.
3340         (Depends-on): Add stdlib.
3341         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3342         (Includes): Use <stdlib.h> instead of getsubopt.h.
3343         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
3344         Set HAVE_GETSUBOPT.
3345         * lib/getsubopt.c: Don't include getsubopt.h.
3346
3347 2007-02-18  Bruno Haible  <bruno@clisp.org>
3348
3349         * modules/fchdir (Depends-on): Add dup2.
3350
3351 2007-02-18  Bruno Haible  <bruno@clisp.org>
3352
3353         * lib/stdlib_.h: Handle glibc's special invocation convention
3354         specially.
3355
3356 2007-02-18  Bruno Haible  <bruno@clisp.org>
3357
3358         * modules/stdlib-tests: New file.
3359         * tests/test-stdlib.c: New file.
3360
3361         * modules/mkstemp (Files): Remove lib/mkstemp.h.
3362         (Depends-on): Add stdlib.
3363         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3364         (Includes): Use <stdlib.h> instead of mkstemp.h.
3365         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
3366         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
3367         * lib/mkstemp.c: Don't include mkstemp.h.
3368         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
3369         * lib/stdlib--.h: Don't include mkstemp.h.
3370
3371         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
3372         (Depends-on): Add stdlib.
3373         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3374         (Includes): Use <stdlib.h> instead of mkdtemp.h.
3375         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
3376         HAVE_MKDTEMP.
3377         * lib/mkdtemp.c: Don't include mkdtemp.h.
3378         * lib/clean-temp.c: Don't include mkdtemp.h.
3379
3380         * modules/exit (Files): Remove lib/exit.h.
3381         (Depends-on): Add stdlib.
3382         (Makefile.am): Remove lib_SOURCES.
3383         (Include): Use <stdlib.h> instead of exit.h.
3384         * lib/argmatch.c: Don't include exit.h.
3385         * lib/execute.c: Likewise.
3386         * lib/pagealign_alloc.c: Likewise.
3387         * lib/pipe.c: Likewise.
3388         * lib/wait-process.c: Likewise.
3389         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
3390         * lib/exitfail.c: Likewise.
3391         * lib/savewd.c: Likewise.
3392         * lib/xsetenv.c: Likewise.
3393
3394         * modules/stdlib: New file.
3395         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
3396         and extra comments about mkstemp().
3397         * lib/exit.h: Remove file.
3398         * lib/mkdtemp.h: Remove file.
3399         * lib/mkstemp.h: Remove file.
3400         * m4/stdlib_h.m4: New file.
3401         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
3402
3403 2007-02-18  Bruno Haible  <bruno@clisp.org>
3404
3405         * modules/math-tests: New file.
3406         * tests/test-math.c: New file.
3407
3408         * modules/math: New file.
3409         * modules/mathl (Files): Remove lib/mathl.h.
3410         (Depends-on): Add math.
3411         (Makefile.am): Don't mention mathl.h.
3412         (Include): Use <math.h> instead of mathl.h.
3413         * lib/math_.h: New file.
3414         * lib/mathl.h: Remove file.
3415         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
3416         mathl.h.
3417         * lib/asinl.c: Likewise.
3418         * lib/atanl.c: Likewise.
3419         * lib/ceill.c: Likewise.
3420         * lib/cosl.c: Likewise.
3421         * lib/expl.c: Likewise.
3422         * lib/floorl.c: Likewise.
3423         * lib/frexpl.c: Likewise.
3424         * lib/ldexpl.c: Likewise.
3425         * lib/logl.c: Likewise.
3426         * lib/sincosl.c: Likewise.
3427         * lib/sinl.c: Likewise.
3428         * lib/sqrtl.c: Likewise.
3429         * lib/tanl.c: Likewise.
3430         * lib/trigl.c: Likewise.
3431         * m4/math_h.m4: New file.
3432         * MODULES.html.sh (Mathematics): Add math.
3433
3434 2007-02-17  Bruno Haible  <bruno@clisp.org>
3435
3436         * modules/wctype-tests: New file.
3437         * tests/test-wctype.c: New file.
3438
3439         * modules/wchar-tests: New file.
3440         * tests/test-wchar.c: New file.
3441
3442         * modules/unistd-tests: New file.
3443         * tests/test-unistd.c: New file.
3444
3445         * modules/time-tests: New file.
3446         * tests/test-time.c: New file.
3447
3448         * modules/sysexits-tests: New file.
3449         * tests/test-sysexits.c: New file.
3450
3451         * modules/sys_time-tests: New file.
3452         * tests/test-sys_time.c: New file.
3453
3454         * modules/sys_stat-tests: New file.
3455         * tests/test-sys_stat.c: New file.
3456
3457         * modules/sys_socket-tests: New file.
3458         * tests/test-sys_socket.c: New file.
3459
3460         * modules/sys_select-tests: New file.
3461         * tests/test-sys_select.c: New file.
3462
3463         * modules/string-tests: New file.
3464         * tests/test-string.c: New file.
3465
3466         * modules/stdbool-tests: New file.
3467         * tests/test-stdbool.c: New file.
3468
3469         * modules/netinet_in-tests: New file.
3470         * tests/test-netinet_in.c: New file.
3471
3472         * modules/inttypes-tests: New file.
3473         * tests/test-inttypes.c: New file.
3474
3475         * modules/fcntl-tests: New file.
3476         * tests/test-fcntl.c: New file.
3477
3478         * modules/byteswap-tests: New file.
3479         * tests/test-byteswap.c: New file.
3480
3481         * modules/arpa_inet-tests: New file.
3482         * tests/test-arpa_inet.c: New file.
3483
3484 2007-02-17  Bruno Haible  <bruno@clisp.org>
3485
3486         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
3487         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
3488         if the corresponding module is not enabled. Emit link warnings if
3489         the function is used nevertheless.
3490         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
3491         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
3492         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
3493         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
3494         * modules/inttypes (Depends-on): Add link-warning.
3495         (Makefile.am): Copy the contents of build-aux/link-warning.h into
3496         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
3497         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
3498         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
3499         * modules/imaxdiv (configure.ac): Likewise.
3500         * modules/strtoimax (configure.ac): Likewise.
3501         * modules/strtoumax (configure.ac): Likewise.
3502
3503 2007-02-17  Bruno Haible  <bruno@clisp.org>
3504
3505         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
3506         gl_STRING_MODULE_INDICATOR_DEFAULTS.
3507         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
3508         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
3509
3510 2007-02-17  Bruno Haible  <bruno@clisp.org>
3511
3512         * modules/link-warning: New file.
3513         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
3514         * lib/string_.h (GL_LINK_WARNING): Remove definition.
3515         * modules/string (Depends-on): Add link-warning.
3516         (Makefile.am): Copy the contents of build-aux/link-warning.h into
3517         string.h.
3518         * MODULES.html.sh (Support for building libraries and executables): Add
3519         link-warning.
3520
3521 2007-02-17  Bruno Haible  <bruno@clisp.org>
3522
3523         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
3524         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
3525         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
3526         long lines.
3527
3528 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
3529             Bruno Haible  <bruno@clisp.org>
3530
3531         * modules/tmpfile: New file.
3532         * lib/tmpfile.c: New file.
3533         * m4/tmpfile.m4: New file.
3534         * MODULES.html.sh (func_all_modules): New section "Input/output".
3535
3536 2007-02-15  Bruno Haible  <bruno@clisp.org>
3537
3538         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
3539         (supports_delete_on_close): New function.
3540         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
3541
3542 2007-02-14  Bruno Haible  <bruno@clisp.org>
3543
3544         * modules/mbspcasecmp-tests: New file.
3545         * tests/test-mbspcasecmp.sh: New file.
3546         * tests/test-mbspcasecmp.c: New file.
3547
3548         New module mbspcasecmp.
3549         * modules/mbspcasecmp: New file.
3550         * lib/mbspcasecmp.c: New file.
3551         * lib/string_.h (strncasecmp): Change warning message.
3552         (mbspcasecmp): New declaration.
3553         * m4/mbspcasecmp.m4: New file.
3554         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3555         GNULIB_MBSPCASECMP.
3556         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
3557         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
3558
3559 2007-02-14  Bruno Haible  <bruno@clisp.org>
3560
3561         * modules/mbsncasecmp-tests: New file.
3562         * tests/test-mbsncasecmp.sh: New file.
3563         * tests/test-mbsncasecmp.c: New file.
3564
3565         New module mbsncasecmp.
3566         * modules/mbsncasecmp: New file.
3567         * lib/mbsncasecmp.c: New file.
3568         * lib/string_.h (mbsncasecmp): New declaration.
3569         * m4/mbsncasecmp.m4: New file.
3570         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3571         GNULIB_MBSNCASECMP.
3572         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
3573         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
3574
3575 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
3576
3577         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
3578         Verify that it doesn't overlap with our flags.
3579         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
3580         do not have the desired effect in multibyte locales; instead, use
3581         mbscasecmp.
3582         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
3583         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
3584         we don't require GNU fnmatch ourselves (if our users require it, they
3585         should do so explicitly).
3586
3587         Fix regex code so it doesn't rely on strcasecmp.
3588         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
3589         Otherwise, include gnulib's langinfo.h.
3590         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
3591         undesirable behavior in non-C locales.  Instead, rely on localecharset.
3592         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
3593         * modules/regex (FILES): Remove m4/codeset.m4.
3594         (Depends-on): Add localcharset.  Remove strcase.
3595
3596 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3597
3598         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
3599         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
3600
3601 2007-02-13  Bruno Haible  <bruno@clisp.org>
3602
3603         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
3604         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3605
3606 2007-02-12  Bruno Haible  <bruno@clisp.org>
3607
3608         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
3609         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
3610         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
3611         time warning rather than a link error.
3612
3613 2007-02-12  Bruno Haible  <bruno@clisp.org>
3614
3615         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
3616         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
3617         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3618
3619 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
3620
3621         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
3622         args, not 2.
3623
3624 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
3625
3626         New module 'time', so that apps can include <time.h> as per
3627         POSIX and GNU instead of separate include files like time_r.h
3628         and timegm.h.  This implementation tries out a simpler approach
3629         for replacing decls in standard include files (as compared to
3630         the string module), somewhat as an experiment.
3631
3632         * config/srclist.txt: Comment out mktime.c for now.
3633         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
3634         since it doesn't apply any more.  Use generic wording instead.
3635         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
3636         'time'.
3637         * lib/time_.h, m4/time_h.m4, modules/time: New files.
3638         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
3639         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
3640         Don't include <sys/types.h>; no longer needed since we assume C89.
3641         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
3642         * lib/strftime.c: Likewise.
3643         * lib/time_r.c: Likewise.
3644         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
3645         * lib/nanosleep.c: Include <time.h> first, to check interface.
3646         * lib/strptime.c: Likewise.
3647         * lib/time_r.c: Likewise.
3648         * lib/timegm.c: Likewise.
3649         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
3650         needed.
3651         * lib/timegm.c: Don't include timegm.h; no longer needed.
3652         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
3653         time.h now handles any problems in that area.
3654         (struct timespec, nanosleep): Remove; time.h now arranges for these.
3655         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
3656         that time.h defines struct timespec.
3657         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
3658         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
3659         handles that.
3660         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
3661         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
3662         needed.  Set REPLACE_LOCALTIME.
3663         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
3664         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
3665         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
3666         nanosleep; time_h.m4 now does that.  Don't require
3667         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
3668         module handles this now.
3669         * modules/getdate (Depends-on): Remove timespec.  Add time.
3670         * modules/nanosleep (Depends-on): Likewise.
3671         * modules/stat-time (Depends-on): Likewise.
3672         * modules/nanosleep (Include): Include time.h, not timespec.h.
3673         * modules/strptime (Files): Remove lib/strptime.h.
3674         (Depends-on): Add extensions, time.
3675         (Include): Include time.h, not strptime.h.
3676         * modules/time_r (Files): Remove lib/time_r.h.
3677         (Depends-on): Add time.
3678         (Include): Include time.h, not time_r.h.
3679         * modules/timegm: Likewise.
3680         * modules/timespec (Description): Now does timespec-related decls
3681         of our own, instead of struct timespec itself.
3682         (Depends-on): Add time; remove extensions.
3683         (Maintainer): Add self.
3684         * modules/utimecmp (Depends-on): Add time; remove timespec.
3685         * modules/utimens (Depends-on): Likewise.
3686         * modules/xnanosleep (Depends-on): Likewise.
3687
3688 2007-02-11  Bruno Haible  <bruno@clisp.org>
3689
3690         * lib/c-strstr.c: Include allocsa.h.
3691         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3692         * lib/c-strcasestr.c: Include allocsa.h.
3693         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3694         * lib/strcasestr.c: Include allocsa.h.
3695         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3696         * lib/mbsstr.c: Include allocsa.h.
3697         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
3698         allocsa/freesa instead of malloc/free.
3699         * lib/mbscasestr.c: Include allocsa.h.
3700         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
3701         allocsa/freesa instead of malloc/free.
3702         * modules/c-strstr (Depends-on): Add allocsa.
3703         * modules/c-strcasestr (Depends-on): Likewise.
3704         * modules/strcasestr (Depends-on): Likewise.
3705         * modules/mbsstr (Depends-on): Likewise.
3706         * modules/mbscasestr (Depends-on): Likewise.
3707
3708 2007-02-11  Bruno Haible  <bruno@clisp.org>
3709
3710         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
3711
3712         * modules/mbsspn-tests: New file.
3713         * tests/test-mbsspn.sh: New file.
3714         * tests/test-mbsspn.c: New file.
3715
3716 2007-02-11  Bruno Haible  <bruno@clisp.org>
3717
3718         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
3719
3720         * modules/mbspbrk-tests: New file.
3721         * tests/test-mbspbrk.sh: New file.
3722         * tests/test-mbspbrk.c: New file.
3723
3724 2007-02-11  Bruno Haible  <bruno@clisp.org>
3725
3726         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
3727         unneeded cast.
3728
3729         * modules/mbscspn-tests: New file.
3730         * tests/test-mbscspn.sh: New file.
3731         * tests/test-mbscspn.c: New file.
3732
3733 2007-02-11  Bruno Haible  <bruno@clisp.org>
3734
3735         * modules/mbscasecmp-tests: New file.
3736         * tests/test-mbscasecmp.sh: New file.
3737         * tests/test-mbscasecmp.c: New file.
3738
3739 2007-02-11  Bruno Haible  <bruno@clisp.org>
3740
3741         Ensure O(n) worst-case complexity of mbscasestr.
3742         * lib/mbscasestr.c: Include stdbool.h.
3743         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
3744         functions.
3745         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
3746         the bookkeeping indicates that it's worth it.
3747         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
3748
3749         * modules/mbscasestr-tests: New file.
3750         * tests/test-mbscasestr1.c: New file.
3751         * tests/test-mbscasestr2.sh: New file.
3752         * tests/test-mbscasestr2.c: New file.
3753         * tests/test-mbscasestr3.sh: New file.
3754         * tests/test-mbscasestr3.c: New file.
3755         * tests/test-mbscasestr4.sh: New file.
3756         * tests/test-mbscasestr4.c: New file.
3757         * m4/locale-tr.m4: New file.
3758
3759 2007-02-11  Bruno Haible  <bruno@clisp.org>
3760
3761         Ensure O(n) worst-case complexity of mbsstr.
3762         * lib/mbsstr.c: Include stdbool.h.
3763         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
3764         functions.
3765         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
3766         bookkeeping indicates that it's worth it.
3767         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
3768
3769         * modules/mbsstr-tests: New file.
3770         * tests/test-mbsstr1.c: New file.
3771         * tests/test-mbsstr2.sh: New file.
3772         * tests/test-mbsstr2.c: New file.
3773         * tests/test-mbsstr3.sh: New file.
3774         * tests/test-mbsstr3.c: New file.
3775         * m4/locale-fr.m4: New file.
3776
3777 2007-02-11  Bruno Haible  <bruno@clisp.org>
3778
3779         * lib/mbsrchr.c (mbsrchr): Fix bug.
3780
3781         * modules/mbsrchr-tests: New file.
3782         * tests/test-mbsrchr.sh: New file.
3783         * tests/test-mbsrchr.c: New file.
3784
3785 2007-02-11  Bruno Haible  <bruno@clisp.org>
3786
3787         * lib/mbschr.c (mbschr): Fix bug.
3788
3789         * modules/mbschr-tests: New file.
3790         * tests/test-mbschr.sh: New file.
3791         * tests/test-mbschr.c: New file.
3792         * m4/locale-zh.m4: New file.
3793
3794 2007-02-11  Bruno Haible  <bruno@clisp.org>
3795
3796         Support for copying multibyte string iterators.
3797         * lib/mbiter.h: Include <string.h>.
3798         (mbiter_multi_copy): New function.
3799         (mbi_copy): New macro.
3800         * lib/mbuiter.h: Include <string.h>.
3801         (mbuiter_multi_copy): New function.
3802         (mbui_copy): New macro.
3803
3804 2007-02-11  Bruno Haible  <bruno@clisp.org>
3805
3806         New module mbslen.
3807         * modules/mbslen: New file.
3808         * lib/mbslen.c: New file.
3809         * lib/string_.h (mbslen): New declaration.
3810         * m4/mbslen.m4: New file.
3811         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3812         GNULIB_MBSLEN.
3813         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
3814         * MODULES.html.sh (Internationalization functions): Add mbslen.
3815
3816 2007-02-11  Bruno Haible  <bruno@clisp.org>
3817
3818         Ensure O(n) worst-case complexity of strcasestr substitute.
3819         * lib/strcasestr.c: Include stdbool.h.
3820         (knuth_morris_pratt): New function.
3821         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3822         bookkeeping indicates that it's worth it.
3823         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
3824
3825         * modules/strcasestr-tests: New file.
3826         * tests/test-strcasestr.c: New file.
3827
3828 2007-02-11  Bruno Haible  <bruno@clisp.org>
3829
3830         Ensure O(n) worst-case complexity of c_strcasestr.
3831         * lib/c-strcasestr.c: Include stdbool.h, string.h.
3832         (knuth_morris_pratt): New function.
3833         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
3834         the bookkeeping indicates that it's worth it.
3835         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
3836
3837         * modules/c-strcasestr-tests: New file.
3838         * tests/test-c-strcasestr.c: New file.
3839
3840 2007-02-11  Bruno Haible  <bruno@clisp.org>
3841
3842         Ensure O(n) worst-case complexity of c_strstr.
3843         * lib/c-strstr.c: Include stdbool.h, string.h.
3844         (knuth_morris_pratt): New function.
3845         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3846         bookkeeping indicates that it's worth it.
3847         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
3848
3849         * lib/c-strstr.c: Complete rewrite for maintainability.
3850
3851         * modules/c-strstr-tests: New file.
3852         * tests/test-c-strstr.c: New file.
3853
3854 2007-02-11  Bruno Haible  <bruno@clisp.org>
3855
3856         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
3857         5.2.1 and earlier, whereby \055 was treated just like the range
3858         delimiter '-'.
3859         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
3860
3861 2007-02-08  Bruno Haible  <bruno@clisp.org>
3862
3863         * modules/regex (Depends-on): Add stdbool.
3864         Reported by Dalibor Topic <robilad@kaffe.org>.
3865
3866 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
3867
3868         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
3869         Prefer returning from main to exiting from it.
3870         Remove unnecessary parens after sizeof.
3871
3872 2007-02-05  Bruno Haible  <bruno@clisp.org>
3873
3874         New module mbssep.
3875         * modules/mbssep: New file.
3876         * lib/mbssep.c: New file.
3877         * lib/string_.h (strsep): Add a conditional link warning.
3878         (mbssep): New declaration.
3879         * m4/mbssep.m4: New file.
3880         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3881         GNULIB_MBSSEP.
3882         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
3883         * MODULES.html.sh (Internationalization functions): Add mbssep.
3884
3885 2007-02-05  Bruno Haible  <bruno@clisp.org>
3886
3887         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
3888         Optimize search in case of 1 delimiter.
3889
3890 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3891
3892         * lib/acl.h: Include sys/types.h before sys/acl.h.
3893
3894 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3895
3896         Merge upstream fix for glibc bugzilla #3957:
3897
3898         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
3899
3900         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
3901         bit for RE_HAT_LISTS_NOT_NEWLINE.
3902         (build_charclass_op): Remove bogus comment.
3903
3904 2007-02-05  Simon Josefsson  <simon@josefsson.org>
3905
3906         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
3907
3908 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
3909
3910         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
3911         * lib/memmem.c [!defined _LIBC]: Include config.h.
3912
3913 2007-02-04  Bruno Haible  <bruno@clisp.org>
3914
3915         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
3916         warning message.
3917
3918 2007-02-04  Bruno Haible  <bruno@clisp.org>
3919
3920         New module mbstok_r.
3921         * modules/mbstok_r: New file.
3922         * lib/mbstok_r.c: New file.
3923         * lib/string_.h (strtok_r): Change argument names to match the
3924         comments. Add a conditional link warning.
3925         (mbstok_r): New declaration.
3926         * m4/mbstok_r.m4: New file.
3927         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3928         GNULIB_MBSTOK_R.
3929         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
3930         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
3931
3932 2007-02-04  Bruno Haible  <bruno@clisp.org>
3933
3934         New module mbsspn.
3935         * modules/mbsspn: New file.
3936         * lib/mbsspn.c: New file.
3937         * lib/string_.h (strspn): Add a conditional link warning.
3938         (mbsspn): New declaration.
3939         * m4/mbsspn.m4: New file.
3940         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3941         GNULIB_MBSSPN.
3942         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
3943         * MODULES.html.sh (Internationalization functions): Add mbsspn.
3944
3945 2007-02-04  Bruno Haible  <bruno@clisp.org>
3946
3947         New module mbspbrk.
3948         * modules/mbspbrk: New file.
3949         * lib/mbspbrk.c: New file.
3950         * lib/string_.h (strpbrk): Add a conditional link warning.
3951         (mbspbrk): New declaration.
3952         * m4/mbspbrk.m4: New file.
3953         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3954         GNULIB_MBSPBRK.
3955         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
3956         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
3957
3958 2007-02-04  Bruno Haible  <bruno@clisp.org>
3959
3960         New module mbscspn.
3961         * modules/mbscspn: New file.
3962         * lib/mbscspn.c: New file.
3963         * lib/string_.h (strcspn): Add a conditional link warning.
3964         (mbscspn): New declaration.
3965         * m4/mbscspn.m4: New file.
3966         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3967         GNULIB_MBSCSPN.
3968         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
3969         * MODULES.html.sh (Internationalization functions): Add mbscspn.
3970
3971 2007-02-04  Bruno Haible  <bruno@clisp.org>
3972
3973         New module mbscasestr, reduced goal of strcasestr.
3974         * modules/mbscasestr: New file.
3975         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
3976         (mbscasestr): Renamed from strcasestr.
3977         * lib/strcasestr.c: Don't include mbuiter.h.
3978         (strcasestr): Remove support for multibyte locales.
3979         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
3980         Change the conditional link warning.
3981         (mbscasestr): New declaration.
3982         * m4/mbscasestr.m4: New file.
3983         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
3984         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
3985         REPLACE_STRCASESTR.
3986         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
3987         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
3988         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3989         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
3990         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
3991         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3992         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
3993         (Depends-on): Remove mbuiter.
3994         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
3995
3996 2007-02-04  Bruno Haible  <bruno@clisp.org>
3997
3998         Simplify handling of strncasecmp.
3999         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
4000         the conditional link warning.
4001         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
4002         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
4003         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
4004         * modules/strcase (configure.ac): Don't invoke
4005         gl_STRING_MODULE_INDICATOR.
4006         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
4007
4008 2007-02-04  Bruno Haible  <bruno@clisp.org>
4009
4010         New module mbscasecmp, reduced goal of strcasecmp.
4011         * modules/mbscasecmp: New file.
4012         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
4013         (mbscasecmp): Renamed from strcasecmp.
4014         * lib/strcasecmp.c: Don't include mbuiter.h.
4015         (strcasecmp): Remove support for multibyte locales.
4016         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
4017         Change the conditional link warning.
4018         (mbscasecmp): New declaration.
4019         * m4/mbscasecmp.m4: New file.
4020         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
4021         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
4022         REPLACE_STRCASECMP.
4023         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
4024         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4025         GNULIB_MBSCASECMP.
4026         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
4027         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
4028         * modules/strcase (Files): Remove m4/mbrtowc.m4.
4029         (Depends-on): Remove mbuiter.
4030         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
4031
4032 2007-02-04  Bruno Haible  <bruno@clisp.org>
4033
4034         New module mbsstr. Remove module strstr.
4035         * modules/mbsstr: New file.
4036         * modules/strstr: Remove file.
4037         * lib/mbsstr.c: Renamed from lib/strstr.c.
4038         (mbsstr): Renamed from strstr.
4039         * lib/string_.h (strstr): Remove declaration. Change the conditional
4040         link warning.
4041         (mbsstr): New declaration.
4042         * m4/mbsstr.m4: New file.
4043         * m4/strstr.m4: Remove file.
4044         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
4045         REPLACE_STRSTR.
4046         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
4047         Don't initialize GNULIB_STRSTR.
4048         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
4049         substitute GNULIB_STRSTR and REPLACE_STRSTR.
4050         * MODULES.html.sh (Internationalization functions): Add mbsstr.
4051         (Support for systems lacking ANSI C 89): Remove strstr.
4052
4053 2007-02-04  Bruno Haible  <bruno@clisp.org>
4054
4055         New module mbsrchr.
4056         * modules/mbsrchr: New file.
4057         * lib/mbsrchr.c: New file.
4058         * lib/string_.h (strrchr): Add a conditional link warning.
4059         (mbsrchr): New declaration.
4060         * m4/mbsrchr.m4: New file.
4061         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4062         GNULIB_MBSRCHR.
4063         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
4064         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
4065
4066 2007-02-04  Bruno Haible  <bruno@clisp.org>
4067
4068         New module mbschr.
4069         * modules/mbschr: New file.
4070         * lib/mbschr.c: New file.
4071         * lib/string_.h (strchr): Add a conditional link warning.
4072         (mbschr): New declaration.
4073         * m4/mbschr.m4: New file.
4074         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4075         GNULIB_MBSCHR.
4076         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
4077         * MODULES.html.sh (Internationalization functions): Add mbschr.
4078
4079 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
4080
4081         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
4082
4083         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
4084
4085 2007-02-04  Bruno Haible  <bruno@clisp.org>
4086
4087         New module description section 'configure.ac-early'.
4088         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
4089         (func_get_autoconf_early_snippet): New function.
4090         (func_import, func_create_testdir): Use it. Remove special cases for
4091         modules 'extensions' and 'lock'.
4092         * modules/extensions (configure.ac-early): Require
4093         gl_USE_SYSTEM_EXTENSIONS.
4094         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
4095
4096 2007-02-04  Bruno Haible  <bruno@clisp.org>
4097
4098         Make use of gcj-4.3's -fsource and -ftarget option.
4099         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
4100         and if so try the options -fsource and -ftarget.
4101         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
4102         source_version, ftarget_option, target_version arguments.
4103         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
4104         (is_envjavac_oldgcj_14_14_usable): Renamed from
4105         is_envjavac_gcj_14_14_usable.
4106         (is_envjavac_oldgcj_14_13_usable): Renamed from
4107         is_envjavac_gcj_14_13_usable.
4108         (is_gcj_present): Update.
4109         (is_gcj_43, is_gcj43_usable): New functions.
4110         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
4111         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
4112         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
4113         try the options -fsource and -ftarget.
4114
4115 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
4116
4117         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
4118         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
4119         larger value.
4120
4121 2007-02-03  Jim Meyering  <jim@meyering.net>
4122
4123         Give tools a better chance to allocate space for very large buffers.
4124         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
4125
4126         Make pwd and readlink work also when run with an unreadable parent dir
4127         on systems with openat support.
4128         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
4129         provided getcwd function, even when we have openat support.
4130         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
4131
4132 2007-02-02  Bruno Haible  <bruno@clisp.org>
4133
4134         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
4135         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
4136         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
4137         portability problems if one of these functions is only used on specific
4138         platforms.
4139         Reported by Paul Eggert.
4140
4141 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
4142
4143         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
4144         is causing more trouble than it's curing.
4145         * lib/regex_internal.h (__mempcpy): Remove.
4146         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
4147         (and make the code a tad smaller to boot).
4148         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
4149
4150 2007-02-02  Jim Meyering  <jim@meyering.net>
4151
4152         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
4153         section, not in the Makefile.am: one.
4154
4155 2007-02-02  Eric Blake  <ebb9@byu.net>
4156
4157         * lib/strchrnul.c: Always include config.h first.
4158
4159         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
4160         gnulib strstr is not necessary here.
4161
4162 2007-02-02  Simon Josefsson  <simon@josefsson.org>
4163
4164         * m4/socklen.m4: Fix typo.
4165
4166 2007-02-02  Eric Blake  <ebb9@byu.net>
4167
4168         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
4169         * modules/netinet_in (Makefile.am): Likewise.
4170
4171 2007-02-01  Bruno Haible  <bruno@clisp.org>
4172
4173         * lib/string_.h (GL_LINK_WARNING): New macro.
4174         (strcasecmp, strstr, strcasestr): If provided by the system,
4175         conditionally define as a macro that leads to a warning instead of to
4176         an error.
4177         (strncasecmp): Conditionally define as a macro that leads to a warning.
4178
4179 2007-02-01  Karl Berry  <karl@gnu.org>
4180
4181         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
4182
4183 2007-02-01  Bruno Haible  <bruno@clisp.org>
4184
4185         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
4186         renamings.
4187
4188 2007-02-01  Eric Blake  <ebb9@byu.net>
4189
4190         * modules/regex (Depends-on): Revert dependence on mempcpy.
4191         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
4192         module's definition of mempcpy.
4193         Reported by Paul Eggert.
4194
4195 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
4196
4197         * lib/string_.h: If the gnulib module XYZ is not present, undefine
4198         the symbol XYZ before redefining it.  This fixes a problem with
4199         programs that don't use XYZ, when compiled on systems that define
4200         XYZ to something else.
4201
4202 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
4203
4204         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
4205         occurs when "mkdir -m foo" creates a setgid directory that is (1)
4206         writeable to group or other and (2) is intended to have a special
4207         mode bit that is set or cleared.  In such a case, the directory
4208         should be neither group- nor other-writeable until the special
4209         mode bits are right.
4210
4211 2007-01-31  Eric Blake  <ebb9@byu.net>
4212
4213         * modules/mountlist (Depends-on): Add strstr.
4214
4215         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
4216         bug.
4217         * modules/string (Makefile.am): Remove redundant replacement.
4218         * modules/regex (Depends-on): Add mempcpy.
4219
4220 2007-01-31  Bruno Haible  <bruno@clisp.org>
4221
4222         New module description field 'Link'.
4223         * gnulib-tool (func_usage): Document --extract-link-directive.
4224         (sed_extract_prog): Recognize 'Link' directive.
4225         (func_get_link_directive): New function.
4226         (func_import): Show summary of link directives.
4227         Handle --extract-link-directive option.
4228         * modules/acl (Link): New section.
4229         * modules/clock-time (Link): New section.
4230         * modules/euidaccess (Link): New section.
4231         * modules/gettext (Link): New section.
4232         * modules/iconv (Link): New section.
4233         * modules/lock (Link): New section.
4234         * modules/nanosleep (Link): New section.
4235         * modules/readline (Link): New section.
4236
4237 2007-01-27  Bruno Haible  <bruno@clisp.org>
4238
4239         Enforce the use of gnulib modules for unportable <string.h> functions.
4240         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
4241         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
4242         (gl_HEADER_STRING_H_BODY): Require it.
4243         * lib/string_.h: If the gnulib module XYZ is not present, redefine
4244         the symbol XYZ to one that gives a link error.
4245         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
4246         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
4247         * modules/mempcpy (configure.ac): Likewise.
4248         * modules/memrchr (configure.ac): Likewise.
4249         * modules/stpcpy (configure.ac): Likewise.
4250         * modules/stpncpy (configure.ac): Likewise.
4251         * modules/strcase (configure.ac): Likewise.
4252         * modules/strcasestr (configure.ac): Likewise.
4253         * modules/strchrnul (configure.ac): Likewise.
4254         * modules/strdup (configure.ac): Likewise.
4255         * modules/strndup (configure.ac): Likewise.
4256         * modules/strnlen (configure.ac): Likewise.
4257         * modules/strpbrk (configure.ac): Likewise.
4258         * modules/strsep (configure.ac): Likewise.
4259         * modules/strstr (configure.ac): Likewise.
4260         * modules/strtok_r (configure.ac): Likewise.
4261
4262 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
4263
4264         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
4265
4266 2007-01-30  Jim Meyering  <jim@meyering.net>
4267
4268         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
4269
4270 2007-01-29  Bruno Haible  <bruno@clisp.org>
4271
4272         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
4273         * lib/execute.c: Likewise.
4274         * lib/pipe.c: Likewise.
4275         * lib/printf-args.h: Likewise.
4276         * lib/printf-args.c: Likewise.
4277         * lib/printf-parse.c: Likewise.
4278         * lib/vasnprintf.c: Likewise.
4279
4280 2007-01-29  Eric Blake  <ebb9@byu.net>
4281
4282         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
4283         declaration.
4284
4285 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
4286
4287         * lib/strptime.h (strptime): Use 'restrict' for args where
4288         POSIX requires this.
4289         * lib/strptime.c (strptime): Likewise.
4290         Change license notice from LGPL to GPL, since gnulib-tool will
4291         change this as needed.
4292         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
4293         defined.
4294         Include "strptime.h" first, to check interface.
4295         Do not #undef _LIBC and _NL_CURRENT.
4296         Do not include <stdlib.h>; no longer needed.
4297         Include "time_r.h" and declare ptime_locale_status
4298         only if _LIBC is not defined.
4299         (__P): Remove unused macro.
4300         (match_string): Bring back glibc version, but use it only if _LIBC
4301         is defined.
4302         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
4303         Remove unnecessary assertion and abort() call.
4304         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
4305         * m4/strptime.m4: Fix serial number comment.
4306         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
4307         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
4308         (Depends-on): Add time_r.
4309
4310 2007-01-29  Bruno Haible  <bruno@clisp.org>
4311
4312         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
4313         strptime.
4314         * modules/strptime (Depends-on): Add stdbool.
4315         * lib/strptime.h: Include <time.h> always. Add comments.
4316
4317 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
4318
4319         * modules/strptime: New file.
4320         * lib/strptime.h: New file.
4321         * lib/strptime.c: New file.
4322         * m4/strptime.m4: New file.
4323
4324 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
4325
4326         * MODULES.html.sh: New module mpsort.
4327         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
4328
4329         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
4330         a circularity problem with HP-UX ia64 reported by Bob Proulx in
4331         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
4332         All uses changed.
4333         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
4334         All uses changed.
4335         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
4336         to _Restrict_.
4337         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
4338         the parameter matches the prototype.
4339
4340 2007-01-28  Jim Meyering  <jim@meyering.net>
4341
4342         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
4343         sys/time.h here, reverting that part of the previous patch:
4344         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
4345
4346 2007-01-28  Bruno Haible  <bruno@clisp.org>
4347
4348         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
4349         value of $(SYS_TIME_H).
4350         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
4351         remove it conditionally, too. [added by Jim Meyering]
4352         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
4353         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
4354         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
4355         GETTIMEOFDAY_REPLACEMENT to 1.
4356
4357 2007-01-28  Bruno Haible  <bruno@clisp.org>
4358
4359         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
4360         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
4361         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
4362         Set UNISTD_H instead of UNISTD_H2.
4363         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
4364
4365 2007-01-28  Bruno Haible  <bruno@clisp.org>
4366
4367         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
4368         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
4369
4370 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4371
4372         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
4373         (func_create_testdir): Ensure C locale for `grep' and `tr'
4374         character ranges.
4375         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
4376         ACLOCAL_AMFLAGS parsing state machine.
4377
4378 2007-01-27  Bruno Haible  <bruno@clisp.org>
4379
4380         * modules/unistr/base: Update.
4381
4382 2007-01-27  Bruno Haible  <bruno@clisp.org>
4383
4384         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
4385         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
4386         * modules/unistr/u32-mbtouc-unsafe: Renamed from
4387         modules/unistr/u32-mbtouc.
4388         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
4389         * lib/unistr.h: Update.
4390         * lib/linebreak.c: Update.
4391         * modules/unistr/u32-mbtouc: Renamed from
4392         modules/unistr/u32-mbtouc-safe.
4393         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
4394         * lib/unistr.h: Update.
4395         * lib/unistr/u32-to-u8.c: Update.
4396         * lib/unistr/u32-to-u16.c: Update.
4397
4398 2007-01-27  Bruno Haible  <bruno@clisp.org>
4399
4400         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
4401         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
4402         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
4403         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
4404         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
4405         * modules/unistr/u16-mbtouc-unsafe: Renamed from
4406         modules/unistr/u16-mbtouc.
4407         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
4408         * lib/unistr.h: Update.
4409         * lib/linebreak.c: Update.
4410         * modules/linebreak: Update.
4411         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
4412         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
4413         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
4414         * modules/unistr/u16-mbtouc: Renamed from
4415         modules/unistr/u16-mbtouc-safe.
4416         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
4417         * lib/unistr.h: Update.
4418         * lib/unistr/u16-to-u8.c: Update.
4419         * modules/unistr/u16-to-u8: Update.
4420         * lib/unistr/u16-to-u32.c: Update.
4421         * modules/unistr/u16-to-u32: Update.
4422
4423 2007-01-27  Bruno Haible  <bruno@clisp.org>
4424
4425         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
4426         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
4427         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
4428         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
4429         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
4430         * modules/unistr/u8-mbtouc-unsafe: Renamed from
4431         modules/unistr/u8-mbtouc.
4432         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
4433         * lib/unistr.h: Update.
4434         * lib/striconveh.c: Update.
4435         * modules/striconveh: Update.
4436         * lib/linebreak.c: Update.
4437         * modules/linebreak: Update.
4438         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
4439         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
4440         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
4441         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
4442         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
4443         * lib/unistr.h: Update.
4444         * lib/striconveh.c: Update.
4445         * modules/striconveh: Update.
4446         * lib/unistr/u8-to-u16.c: Update.
4447         * modules/unistr/u8-to-u16: Update.
4448         * lib/unistr/u8-to-u32.c: Update.
4449         * modules/unistr/u8-to-u32: Update.
4450
4451 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4452
4453         Sync from Libtool.
4454         * lib/argz.c: Do not include strings.h nor memory.h, include
4455         string.h unconditionally.  Patch by Simon Josefsson.
4456
4457 2007-01-27  Bruno Haible  <bruno@clisp.org>
4458
4459         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
4460         from gl_HEADER_STRING_H_BODY.
4461         (gl_HEADER_STRING_H_BODY): Require it.
4462         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
4463         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
4464         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
4465         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
4466         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
4467         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
4468         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
4469         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
4470         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
4471         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
4472         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
4473         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
4474         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
4475         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
4476         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
4477
4478 2007-01-27  Bruno Haible  <bruno@clisp.org>
4479
4480         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
4481         check_PROGRAMS into noinst_PROGRAMS.
4482         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
4483         check_PROGRAMS in this case.
4484         (func_import): Set for_test to false.
4485         (func_create_testdir): Set for_test to true.
4486
4487 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
4488             Bruno Haible  <bruno@clisp.org>
4489
4490         * modules/strcasestr (Files): Remove lib/strcasestr.h.
4491         (Depends-on): Add string.
4492         (Includes): Use <string.h> instead of strcasestr.h.
4493         * modules/string (Makefile.am): Also substitute the value of
4494         REPLACE_STRCASESTR.
4495         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
4496         assume strcasestr is declared in <string.h> not <strings.h>. Also
4497         set REPLACE_STRCASESTR.
4498         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
4499         REPLACE_STRCASESTR.
4500         * lib/strcasestr.h: Remove file.
4501         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
4502         * lib/string_.h (strcasestr): New declaration.
4503
4504 2007-01-27  Bruno Haible  <bruno@clisp.org>
4505
4506         * lib/string_.h: Use 'extern'.
4507
4508 2007-01-27  Jim Meyering  <jim@meyering.net>
4509
4510         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
4511         of set-but-not-used local, "q".
4512
4513         * lib/mempcpy.c: Include <config.h> before <string.h>.
4514         This fixes a compilation error on HP-UX, due to the system's
4515         "restrict"-using mempcpy prototype.
4516
4517 2007-01-26  Bruno Haible  <bruno@clisp.org>
4518
4519         Small optimization.
4520         * lib/javacomp.c: Include c-strstr.h.
4521          (is_envjavac_gcj): Use c_strstr instead of strstr.
4522         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
4523
4524 2007-01-26  Bruno Haible  <bruno@clisp.org>
4525
4526         * MODULES.html.sh (Unicode string functions): Add the new modules.
4527
4528         * modules/uniconv/u32-strconv-to-locale: New file.
4529         * lib/uniconv/u32-strconv-to-locale.c: New file.
4530
4531         * modules/uniconv/u16-strconv-to-locale: New file.
4532         * lib/uniconv/u16-strconv-to-locale.c: New file.
4533
4534         * modules/uniconv/u8-strconv-to-locale: New file.
4535         * lib/uniconv/u8-strconv-to-locale.c: New file.
4536
4537         * modules/uniconv/u32-strconv-from-locale: New file.
4538         * lib/uniconv/u32-strconv-from-locale.c: New file.
4539
4540         * modules/uniconv/u16-strconv-from-locale: New file.
4541         * lib/uniconv/u16-strconv-from-locale.c: New file.
4542
4543         * modules/uniconv/u8-strconv-from-locale: New file.
4544         * lib/uniconv/u8-strconv-from-locale.c: New file.
4545
4546         * modules/uniconv/u32-strconv-to-enc: New file.
4547         * lib/uniconv/u32-strconv-to-enc.c: New file.
4548         * modules/uniconv/u32-strconv-to-enc-tests: New file.
4549         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
4550
4551         * modules/uniconv/u16-strconv-to-enc: New file.
4552         * lib/uniconv/u16-strconv-to-enc.c: New file.
4553         * lib/uniconv/u-strconv-to-enc.h: New file.
4554         * modules/uniconv/u16-strconv-to-enc-tests: New file.
4555         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
4556
4557         * modules/uniconv/u8-strconv-to-enc: New file.
4558         * lib/uniconv/u8-strconv-to-enc.c: New file.
4559         * modules/uniconv/u8-strconv-to-enc-tests: New file.
4560         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
4561
4562         * modules/uniconv/u32-strconv-from-enc: New file.
4563         * lib/uniconv/u32-strconv-from-enc.c: New file.
4564         * modules/uniconv/u32-strconv-from-enc-tests: New file.
4565         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
4566
4567         * modules/uniconv/u16-strconv-from-enc: New file.
4568         * lib/uniconv/u16-strconv-from-enc.c: New file.
4569         * modules/uniconv/u16-strconv-from-enc-tests: New file.
4570         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
4571
4572         * modules/uniconv/u8-strconv-from-enc: New file.
4573         * lib/uniconv/u8-strconv-from-enc.c: New file.
4574         * lib/uniconv/u-strconv-from-enc.h: New file.
4575         * modules/uniconv/u8-strconv-from-enc-tests: New file.
4576         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
4577
4578         * modules/uniconv/u32-conv-from-enc: New file.
4579         * lib/uniconv/u32-conv-from-enc.c: New file.
4580         * modules/uniconv/u32-conv-from-enc-tests: New file.
4581         * tests/uniconv/test-u32-conv-from-enc.c: New file.
4582
4583         * modules/uniconv/u16-conv-from-enc: New file.
4584         * lib/uniconv/u16-conv-from-enc.c: New file.
4585         * lib/uniconv/u-conv-from-enc.h: New file.
4586         * modules/uniconv/u16-conv-from-enc-tests: New file.
4587         * tests/uniconv/test-u16-conv-from-enc.c: New file.
4588
4589         * modules/uniconv/u8-conv-from-enc: New file.
4590         * lib/uniconv/u8-conv-from-enc.c: New file.
4591         * modules/uniconv/u8-conv-from-enc-tests: New file.
4592         * tests/uniconv/test-u8-conv-from-enc.c: New file.
4593
4594         * modules/uniconv/base: New file.
4595         * lib/uniconv.h: New file.
4596
4597 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
4598
4599         * doc/gnulib-tool.texi (Initial import): Update to match current
4600         behavior with strdup module.
4601         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
4602         * lib/memmem.h: Remove; all uses removed.  This is now done
4603         by <string.h>.
4604         * lib/mempcpy.h: Likewise.
4605         * lib/memrchr.h: Likewise.
4606         * lib/stpcpy.h: Likewise.
4607         * lib/stpncpy.h: Likewise.
4608         * lib/strcase.h: Likewise.
4609         * lib/strchrnul.h: Likewise.
4610         * lib/strdup.h: Likewise.
4611         * lib/strndup.h: Likewise.
4612         * lib/strnlen.h: Likewise.
4613         * lib/strpbrk.h: Likewise.
4614         * lib/strsep.h: Likewise.
4615         * lib/strstr.h: Likewise.
4616         * lib/strtok_r.h: Likewise.
4617         * lib/string_.h: New file.
4618         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
4619         Rely on <string.h> instead.
4620         * lib/canon-host.c: Likewise.
4621         * lib/chdir-long.c: Likewise.
4622         * lib/concatpath.c: Likewise.
4623         * lib/exclude.c: Likewise.
4624         * lib/fchdir.c: Likewise.
4625         * lib/getaddrinfo.c: Likewise.
4626         * lib/getcwd.c: Likewise.
4627         * lib/getsubopt.c: Likewise.
4628         * lib/glob.c: Likewise.
4629         * lib/hard-locale.c: Likewise.
4630         * lib/iconvme.c: Likewise.
4631         * lib/javacomp.c: Likewise.
4632         * lib/mempcpy.c: Likewise.
4633         * lib/memrchr.c: Likewise.
4634         * lib/regex_internal.h: Likewise.
4635         * lib/stpncpy.c: Likewise.
4636         * lib/strcasecmp.c: Likewise.
4637         * lib/strchrnul.c: Likewise.
4638         * lib/strdup.c: Likewise.
4639         * lib/striconv.c: Likewise.
4640         * lib/striconveh.c: Likewise.
4641         * lib/striconveha.c: Likewise.
4642         * lib/strncasecmp.c: Likewise.
4643         * lib/strndup.c: Likewise.
4644         * lib/strnlen.c: Likewise.
4645         * lib/strsep.c: Likewise.
4646         * lib/strstr.c: Likewise.
4647         * lib/strtok_r.c: Likewise.
4648         * lib/userspec.c: Likewise.
4649         * lib/w32spawn.h: Likewise.
4650         * lib/xstrndup.c: Likewise.
4651         * lib/mountlist.c (strstr): Remove decl.
4652         * m4/string_h.m4: New file.
4653         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
4654         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
4655         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
4656         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
4657         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
4658         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
4659         Set REPLACE_STRCASECMP if necessary.
4660         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
4661         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
4662         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
4663         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
4664         HAVE_DECL_STRDUP if necessary.
4665         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
4666         since gl_FUNC_STRNDUP does that now.
4667         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
4668         Check for decl here...
4669         (gl_PREREQ_STRNLEN): ... not here.
4670         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
4671         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
4672         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
4673         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
4674         necessary.
4675         * modules/string: New file.
4676         * modules/memmem (Files): Remove special-purpose include file.
4677         (Depends-on): Add string.
4678         (Include): Include <string.h>, not the removed file.
4679         * modules/mempcpy: Likewise.
4680         * modules/memrchr: Likewise.
4681         * modules/stpcpy: Likewise.
4682         * modules/stpncpy: Likewise.
4683         * modules/strcase: Likewise.
4684         * modules/strchrnul: Likewise.
4685         * modules/strdup: Likewise.
4686         * modules/strndup: Likewise.
4687         * modules/strnlen: Likewise.
4688         * modules/strpbrk: Likewise.
4689         * modules/strsep: Likewise.
4690         * modules/strstr: Likewise.
4691         * modules/strtok_r: Likewise.
4692         * tests/test-dirname.c: Don't include "strdup.h", since
4693         <string.h> now suffices.
4694         * tests/test-memmem.c: Don't include "memmem.h", since
4695         <string.h> now suffices.
4696
4697 2007-01-25  Bruno Haible  <bruno@clisp.org>
4698
4699         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
4700         *resultp is 0.
4701
4702         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
4703         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
4704         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
4705         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
4706
4707         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
4708         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
4709         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
4710         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
4711         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
4712         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
4713
4714 2007-01-24  Bruno Haible  <bruno@clisp.org>
4715
4716         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
4717         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
4718         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
4719         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
4720         gl_FUNC_FTS_CORE.
4721         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
4722         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
4723         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
4724         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
4725         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
4726         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
4727         gl_FUNC_FCHOWNAT.
4728         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
4729         gl_FUNC_STRFTIME.
4730         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
4731         Reported by Ralf Wildenhues.
4732
4733 2007-01-24  Bruno Haible  <bruno@clisp.org>
4734
4735         Drop AC_REQUIRE calls that are redundant with the module dependencies.
4736         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
4737         gl_GETADDRINFO.
4738         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
4739         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
4740         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
4741
4742 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
4743
4744         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
4745         Don't use 'exit'; just return from 'main'.
4746         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
4747
4748         * lib/fnmatch_.h: Readjust white space and comments to match
4749         glibc, to avoid spurious diffs.
4750
4751 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
4752
4753         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
4754         2004-12-01 change by Jakub Jelinek, since this code won't compile
4755         if !LIBC.  Problem reported by Bob Proulx.
4756
4757 2007-01-23  Bruno Haible  <bruno@clisp.org>
4758
4759         * lib/striconveh.c: Include c-strcaseeq.h.
4760         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
4761         * modules/striconveh (Depends-on): Add c-strcaseeq.
4762
4763 2007-01-23  Bruno Haible  <bruno@clisp.org>
4764
4765         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
4766
4767         * modules/c-strcaseeq: New file.
4768         * lib/c-strcaseeq.h: New file.
4769
4770         * modules/streq: New file.
4771         * lib/streq.h: New file.
4772
4773 2007-01-23  Bruno Haible  <bruno@clisp.org>
4774
4775         * modules/striconveha-tests: New file.
4776         * tests/test-striconveha.c: New file.
4777
4778         * lib/striconveha.h: Include <stdbool.h>.
4779         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
4780         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
4781         (mem_iconveha_notranslit): Renamed from mem_iconveha.
4782         (mem_iconveha): New function.
4783         (str_iconveha_notranslit): Renamed from str_iconveha.
4784         (str_iconveha): New function.
4785         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
4786         c-strcase.
4787
4788 2007-01-23  Bruno Haible  <bruno@clisp.org>
4789
4790         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
4791         encodings without forgiving before trying any encoding with handler.
4792         (str_iconveha): Try all encodings without forgiving before trying any
4793         encoding with handler.
4794
4795 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
4796
4797         Import the following changes from libc.
4798
4799         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
4800
4801         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
4802
4803         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
4804
4805         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
4806         normal_bracket label.
4807
4808         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
4809
4810         [BZ #361]
4811         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
4812         to normal_bracket after fetching the next character.
4813
4814 2007-01-22  Bruno Haible  <bruno@clisp.org>
4815
4816         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
4817         argument.
4818         * lib/striconveh.c (iconv_carefully_1): New function.
4819         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
4820         argument.
4821         (str_cd_iconveh): Update.
4822         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
4823         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
4824         * tests/test-striconveh.c (MAGIC): New macro.
4825         (new_offsets): New function.
4826         (main): Test call with and without offsets.
4827
4828 2007-01-22  Bruno Haible  <bruno@clisp.org>
4829
4830         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
4831         * modules/sys_select (Makefile.am): Likewise.
4832         * modules/sys_socket (Makefile.am): Likewise.
4833         * modules/sys_time (Makefile.am): Likewise.
4834
4835 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
4836
4837         * modules/gettimeofday (License): Change from GPL to LGPL, since
4838         gettimeofday is a library function.
4839
4840 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4841
4842         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
4843
4844 2007-01-21  Bruno Haible  <bruno@clisp.org>
4845
4846         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
4847
4848 2007-01-21  Bruno Haible  <bruno@clisp.org>
4849
4850         * modules/striconveha: New file.
4851         * lib/striconveha.h: New file.
4852         * lib/striconveha.c: New file.
4853         * MODULES.html.sh (Internationalization functions): Add striconveha.
4854         * lib/striconv.c (str_iconv): Optimize the case of an empty input
4855         string.
4856         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
4857
4858 2007-01-21  Bruno Haible  <bruno@clisp.org>
4859
4860         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
4861         * lib/striconveh.c (str_iconveh): Likewise.
4862
4863 2007-01-21  Bruno Haible  <bruno@clisp.org>
4864
4865         * lib/striconveh.h (mem_iconveh): New declaration.
4866         * lib/striconveh.c (mem_iconveh): New function.
4867         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
4868
4869 2007-01-21  Bruno Haible  <bruno@clisp.org>
4870
4871         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
4872
4873         * lib/striconveh.h (mem_cd_iconveh): Change specification.
4874         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
4875         original result buffer.
4876         (str_cd_iconveh): Update.
4877         * tests/test-striconveh.c (main): Update.
4878
4879         * lib/striconv.h (mem_cd_iconv): Change specification.
4880         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
4881         result buffer.
4882         (str_cd_iconv): Update.
4883         * tests/test-striconv.c (main): Update.
4884
4885 2007-01-21  Bruno Haible  <bruno@clisp.org>
4886
4887         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
4888
4889 2007-01-20  Jim Meyering  <jim@meyering.net>
4890
4891         * lib/userspec.c (parse_with_separator): If a user or group string
4892         starts with "+", skip the corresponding name-to-ID look-up, since
4893         such a look-up must fail: user and group names may not include "+".
4894
4895 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
4896
4897         * lib/poll.c: Include sys/time.h and time.h unconditionally,
4898         since we now assume the sys_time module.
4899         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
4900         check for sys/time.h; no longer needed.
4901         * modules/poll (Depends-on): Depend on sys_time.
4902
4903 2007-01-18  Bruno Haible  <bruno@clisp.org>
4904
4905         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
4906         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4907
4908         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
4909         gettimeofday.
4910
4911         * tests/test-gettimeofday.c: Include <time.h>.
4912         (dummy): Remove variable.
4913
4914         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
4915         gl_HEADER_SYS_TIME_H.
4916         (gl_HEADER_SYS_TIME_H): New macro.
4917
4918         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
4919         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4920         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
4921         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
4922         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4923         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
4924         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
4925         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4926         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
4927         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
4928         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4929
4930         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
4931         last change; it caused a compilation error when cross-compiling to
4932         Cygwin.
4933
4934 2007-01-18  Jim Meyering  <jim@meyering.net>
4935
4936         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
4937         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
4938         than the race-prone "test -d sys || mkdir sys".
4939         (configure.ac): Use AC_PROG_MKDIR_P.
4940         * modules/sys_select: Likewise.
4941         * modules/sys_socket: Likewise.
4942         * modules/sys_time: Likewise.
4943
4944 2007-01-18  Eric Blake  <ebb9@byu.net>
4945
4946         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
4947         replace gettimeofday.
4948         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
4949         name, to avoid infinite recursion.
4950
4951 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
4952
4953         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
4954         module sys_time.
4955         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
4956         assume timespec.h defines struct timeval.
4957         * lib/settime.c: Likewise.
4958         * lib/utimens.c: Likewise.
4959         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
4960         since we now assume the gettimeofday module.
4961         * lib/tempname.c (__gen_tempname): Likewise.
4962         * lib/gettimeofday.h: Remove.
4963         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
4964         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
4965         Include <time.h>, for 'time()'.
4966         (localtime_buffer_addr): Also use this workaround if
4967         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
4968         to simplify the uses.  All uses changed.
4969         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
4970         that #undef is inside {}, and 'const' follows type name consistently.
4971         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
4972         (gettimeofday): Do not use the maximum possible value for
4973         tv->tv_usec, since that might break usages other than ls.c.
4974         Instead, we'll leave ls.c alone.  This undoes today's patch
4975         by Bruno.  Add a compile-time warning for 1s-clock resolution;
4976         we've never observed the problem but might as well keep the
4977         canary.
4978         * lib/nanosleep.c: Include timespec.h first, for interface check.
4979         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
4980         now assume the sys_time module.
4981         * lib/tempname.c: Likewise.
4982         * lib/timespec.h: Likewise.
4983         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
4984         needed.
4985         * lib/strftime.c: Likewise.
4986         * lib/timespec.h: Likewise.
4987         * lib/posixtm.c: Include posixtm.h first, for interface check.
4988         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
4989         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
4990         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
4991         * lib/sys_time_.h: New file.
4992         * lib/timespec.h (struct timespec): Use long int, not long.
4993         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
4994         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
4995         Remove obsolescent call to AC_HEADER_TIME.
4996         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
4997         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
4998         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4999         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
5000         Likewise.
5001         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
5002         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
5003         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
5004         into the sys_time module.  Check for gettimeofday just once.
5005         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
5006         for gettimeofday signature to just check the signature.  Merely
5007         compile it, since linking doesn't test signature.  Improve test for
5008         whether gettimeofday.o is actually needed.
5009         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
5010         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
5011         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
5012         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5013         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
5014         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
5015         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
5016         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
5017         than worrying about sys/time.h.
5018         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5019         Don't bother worrying about TIME_WITH_SYS_TIME.
5020         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
5021         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
5022         * m4/sys_time_h.m4: New file.
5023         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
5024         Don't include sys/time.h.  Return from main rather than exiting.
5025         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
5026         all uses changed.
5027         * modules/gethrxtime (Depends-on): Add sys_time.
5028         * modules/gettime (Depends-on): Likewise.
5029         * modules/gettimeofday (Depends-on): Likewise.
5030         * modules/nanosleep (Depends-on): Likewise.
5031         * modules/settime (Depends-on): Likewise.
5032         * modules/tempname (Depends-on): Likewise.
5033         * modules/utimens (Depends-on): Likewise.
5034         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
5035         (Include:) Change back to <sys/time.h>.
5036         (Maintainer:) Add self.
5037         * modules/sys_time: New file.
5038         * modules/tempname (Depends-on): Add gettimeofday.
5039         * tests/test-gettimeofday.c: Include <sys/time.h>
5040         rather than gettimeofday.h.
5041
5042 2007-01-17  Bruno Haible  <bruno@clisp.org>
5043
5044         * gnulib-tool (func_get_license): Revert last patch. Instead, let
5045         the license default to GPL.
5046         (func_create_testdir): Don't complain if a module is LGPL and its
5047         tests module depends on GPLed modules.
5048
5049 2007-01-17  Bruno Haible  <bruno@clisp.org>
5050
5051         * lib/gettimeofday.c (gettimeofday): Add code for the case
5052         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
5053         maximum possible value for tv->tv_usec, rather than the minimum one.
5054
5055 2005-10-08  Martin Lambers  <marlam@marlam.de>
5056 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
5057 2007-01-16  Bruno Haible  <bruno@clisp.org>
5058
5059         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
5060         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
5061         gl_FUNC_GETTIMEOFDAY.
5062         (Include): Add gettimeofday.h.
5063         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
5064         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
5065         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
5066         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
5067         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
5068         * lib/gettimeofday.h: New file.
5069         * lib/gettimeofday.c: Include <sys/timeb.h>.
5070         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
5071         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5072         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
5073         fall back on time().
5074
5075         * tests/test-gettimeofday.c: New file.
5076         * modules/gettimeofday-tests: New file.
5077
5078 2007-01-16  Eric Blake  <ebb9@byu.net>
5079
5080         * modules/fnmatch (Depends-on): Depend on wchar.
5081         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
5082         * m4/fnmatch.m4: Likewise.
5083         * modules/mbchar (Makefile.am): Assume <wchar.h>.
5084         * m4/mbchar.m4: Likewise.
5085         * modules/mbswidth (Depends-on): Depend on wchar.
5086         * lib/mbswidth.c: Assume <wchar.h>.
5087         * m4/mbswidth.m4: Likewise.
5088         * modules/quotearg (Depends-on): Depend on wchar.
5089         * lib/quotearg.c: Assume <wchar.h>.
5090         * m4/quotearg.m4: Likewise.
5091         * modules/regex (Depends-on): Depend on wchar.
5092         * lib/regex_internal.h: Assume <wchar.h>.
5093         * m4/regex.m4: Likewise.
5094         * modules/stdint (Depends-on): Depend on wchar.
5095         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
5096         * m4/stdint.m4: Likewise.
5097         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
5098         * modules/strftime (Depends-on): Depend on wchar.
5099         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
5100         * modules/strtol (Depends-on): Depend on wchar.
5101         * lib/strtol.c: Assume <wchar.h>.
5102         * modules/wcwidth (Depends-on): Depend on wchar.
5103         * lib/wcwidth.h: Assume <wchar.h>.
5104         * m4/wcwidth.m4: Likewise.
5105
5106 2007-01-16  Bruno Haible  <bruno@clisp.org>
5107
5108         * modules/csharpexec-script: New, created from...
5109         * modules/csharpexec: ... this.
5110
5111 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
5112
5113         * modules/javaexec-script: New, created from...
5114         * modules/javaexec: ... this.
5115
5116 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5117
5118         * modules/poll (Dependencies): Add sys_select.
5119
5120 2007-01-15  Jim Meyering  <jim@meyering.net>
5121
5122         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
5123         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
5124         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
5125         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
5126
5127 2007-01-15  Bruno Haible  <bruno@clisp.org>
5128
5129         * modules/striconveh: New file.
5130         * lib/striconveh.h: New file.
5131         * lib/striconveh.c: New file.
5132         * MODULES.html.sh (Internationalization functions): Add striconveh.
5133
5134         * modules/striconveh-tests: New file.
5135         * tests/test-striconveh.c: New file.
5136
5137 2007-01-15  Bruno Haible  <bruno@clisp.org>
5138
5139         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
5140         not from GNU libiconv or GNU libc.
5141
5142 2007-01-15  Bruno Haible  <bruno@clisp.org>
5143
5144         * doc/gnulib-intro.texi (Copyright): Explain the different license
5145         terms for module descriptions, autoconf macros, tests, documentation.
5146
5147 2007-01-14  Bruno Haible  <bruno@clisp.org>
5148
5149         * modules/striconv-tests: New file.
5150         * tests/test-striconv.c: New file.
5151
5152 2007-01-14  Bruno Haible  <bruno@clisp.org>
5153
5154         * modules/iconv-tests: New file.
5155         * tests/test-iconv.c: New file.
5156
5157 2007-01-14  Bruno Haible  <bruno@clisp.org>
5158
5159         * gnulib-tool (func_get_license): For test modules, use the license of
5160         the main module.
5161
5162 2007-01-14  Bruno Haible  <bruno@clisp.org>
5163
5164         * modules/iconv (Include): Clarify that <iconv.h> can only be included
5165         if iconv is found to exist.
5166
5167 2007-01-14  Bruno Haible  <bruno@clisp.org>
5168
5169         * modules/c-ctype-tests: New file.
5170         * tests/test-c-ctype.c: New file.
5171
5172 2007-01-14  Bruno Haible  <bruno@clisp.org>
5173
5174         * modules/binary-io-tests: New file.
5175         * tests/test-binary-io.sh: New file.
5176         * tests/test-binary-io.c: New file.
5177
5178 2007-01-14  Bruno Haible  <bruno@clisp.org>
5179
5180         * modules/array-oset-tests: New file.
5181         * tests/test-array_oset.c: New file.
5182
5183 2007-01-14  Bruno Haible  <bruno@clisp.org>
5184
5185         * modules/array-list-tests: New file.
5186         * tests/test-array_list.c: New file.
5187
5188 2007-01-14  Bruno Haible  <bruno@clisp.org>
5189
5190         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
5191         and make.
5192         Reported by Simon Josefsson in
5193         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
5194
5195 2007-01-14  Bruno Haible  <bruno@clisp.org>
5196
5197         * modules/allocsa-tests: New file.
5198         * tests/test-allocsa.c: New file.
5199
5200 2007-01-14  Bruno Haible  <bruno@clisp.org>
5201
5202         * modules/fchdir (Depends-on): Add absolute-header.
5203         * modules/unistd (Depends-on): Likewise.
5204
5205 2006-12-30  Bruno Haible  <bruno@clisp.org>
5206
5207         * modules/fchdir: New file.
5208         * modules/unistd (Files): Add lib/unistd_.h.
5209         (Makefile.am): Generate unistd.h from unistd_.h.
5210         * lib/fchdir.c: New file.
5211         * lib/dirent_.h: New file.
5212         * lib/unistd_.h: New file.
5213         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
5214         * m4/fchdir.m4: New file.
5215         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
5216         (gl_HEADER_UNISTD): Invoke it.
5217         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
5218         function.
5219         * lib/backupfile.c (opendir, closedir): Undefine.
5220         * lib/chown.c (open, close): Undefine.
5221         * lib/clean-temp.c (open, close): Undefine.
5222         * lib/copy-file.c (open, close): Undefine.
5223         * lib/execute.c (open, close): Undefine.
5224         * lib/fsusage.c (open, close): Undefine.
5225         * lib/gc-gnulib.c (open, close): Undefine.
5226         * lib/getcwd.c (opendir, closedir): Undefine.
5227         * lib/glob.c (opendir, closedir): Undefine.
5228         * lib/javacomp.c (open, close): Undefine.
5229         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
5230         * lib/openat-proc.c (open, close): Undefine.
5231         * lib/pagealign_alloc.c (open, close): Undefine.
5232         * lib/pipe.c (open, close): Undefine.
5233         * lib/progreloc.c (open, close): Undefine.
5234         * lib/savedir.c (opendir, closedir): Undefine.
5235         * lib/utime.c (open, close): Undefine.
5236         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
5237
5238 2007-01-10  Bruno Haible  <bruno@clisp.org>
5239
5240         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
5241
5242 2007-01-12  Eric Blake  <ebb9@byu.net>
5243
5244         Provide a robust <wchar.h>.  Further simplifications are now
5245         possible in other modules, but not included here.
5246         * modules/wchar: New module.
5247         * m4/wchar.m4: New file.
5248         * lib/wchar_.h: Likewise.
5249         * modules/mbchar (Depends-on): Depend on wchar, as the first use
5250         of the new module.
5251         * MODULES.html.sh (Extended multibyte and wide character utilities):
5252         New section.
5253
5254 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
5255
5256         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
5257         to a reasonable default for memory allocation.
5258         (xreadlink): Don't allocate a huge buffer, to work around a buggy
5259         file system that reports garbage st_size values for symlinks.
5260         Problem reported by Liyang Hu.
5261
5262 2007-01-11  Simon Josefsson  <simon@josefsson.org>
5263
5264         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
5265         Emacs .#* auto-save files).
5266
5267 2007-01-11  Bruno Haible  <bruno@clisp.org>
5268
5269         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
5270         directory.
5271
5272 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
5273
5274         Use @...@ consistently in lib/wctype_.h.
5275         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
5276         on it being set to 1 or 0.
5277         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
5278         go back to AC_SUBSTing it.
5279         * modules/wctype (Makefile.am): Undo previous change.
5280
5281 2007-01-10  Eric Blake  <ebb9@byu.net>
5282
5283         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
5284         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
5285         * modules/wctype (Makefile.am): Likewise.
5286         Reported by Chris McGuire.
5287
5288 2007-01-10  Jim Meyering  <jim@meyering.net>
5289
5290         fts.c: a small readability/maintainability improvement
5291         * lib/fts.c (fts_read): Make this code slightly more readable and
5292         maintainable by hoisting the "sp->fts_cur = p" assignments to
5293         immediately follow the statements that set P.  Derived from
5294         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
5295
5296 2007-01-10  Eric Blake  <ebb9@byu.net>
5297
5298         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
5299         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
5300         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
5301         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
5302         Reported by Chris McGuire.
5303
5304 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5305
5306         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
5307         in sed script.
5308
5309 2007-01-09  Bruno Haible  <bruno@clisp.org>
5310
5311         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
5312         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
5313         variables.
5314         (func_module): Use them.
5315
5316 2007-01-09  Bruno Haible  <bruno@clisp.org>
5317
5318         * modules/unistr/base: New file.
5319         * lib/unistr.h: New file.
5320
5321         * modules/unistr/u8-to-u16: New file.
5322         * lib/unistr/u8-to-u16.c: New file.
5323
5324         * modules/unistr/u8-to-u32: New file.
5325         * lib/unistr/u8-to-u32.c: New file.
5326
5327         * modules/unistr/u16-to-u8: New file.
5328         * lib/unistr/u16-to-u8.c: New file.
5329
5330         * modules/unistr/u16-to-u32: New file.
5331         * lib/unistr/u16-to-u32.c: New file.
5332
5333         * modules/unistr/u32-to-u8: New file.
5334         * lib/unistr/u32-to-u8.c: New file.
5335
5336         * modules/unistr/u32-to-u16: New file.
5337         * lib/unistr/u32-to-u16.c: New file.
5338
5339         * modules/unistr/u8-check: New file.
5340         * modules/unistr/u16-check: New file.
5341         * modules/unistr/u32-check: New file.
5342         * lib/unistr/u8-check.c: New file.
5343         * lib/unistr/u16-check.c: New file.
5344         * lib/unistr/u32-check.c: New file.
5345
5346         * modules/unistr/u8-chr: New file.
5347         * modules/unistr/u16-chr: New file.
5348         * modules/unistr/u32-chr: New file.
5349         * lib/unistr/u8-chr.c: New file.
5350         * lib/unistr/u16-chr.c: New file.
5351         * lib/unistr/u32-chr.c: New file.
5352
5353         * modules/unistr/u8-cmp: New file.
5354         * modules/unistr/u16-cmp: New file.
5355         * modules/unistr/u32-cmp: New file.
5356         * lib/unistr/u8-cmp.c: New file.
5357         * lib/unistr/u16-cmp.c: New file.
5358         * lib/unistr/u32-cmp.c: New file.
5359
5360         * modules/unistr/u8-cpy: New file.
5361         * modules/unistr/u16-cpy: New file.
5362         * modules/unistr/u32-cpy: New file.
5363         * lib/unistr/u8-cpy.c: New file.
5364         * lib/unistr/u16-cpy.c: New file.
5365         * lib/unistr/u32-cpy.c: New file.
5366         * lib/unistr/u-cpy.h: New file.
5367
5368         * modules/unistr/u8-cpy-alloc: New file.
5369         * modules/unistr/u16-cpy-alloc: New file.
5370         * modules/unistr/u32-cpy-alloc: New file.
5371         * lib/unistr/u8-cpy-alloc.c: New file.
5372         * lib/unistr/u16-cpy-alloc.c: New file.
5373         * lib/unistr/u32-cpy-alloc.c: New file.
5374         * lib/unistr/u-cpy-alloc.h: New file.
5375
5376         * modules/unistr/u8-endswith: New file.
5377         * modules/unistr/u16-endswith: New file.
5378         * modules/unistr/u32-endswith: New file.
5379         * lib/unistr/u8-endswith.c: New file.
5380         * lib/unistr/u16-endswith.c: New file.
5381         * lib/unistr/u32-endswith.c: New file.
5382         * lib/unistr/u-endswith.h: New file.
5383
5384         * modules/unistr/u8-mblen: New file.
5385         * modules/unistr/u16-mblen: New file.
5386         * modules/unistr/u32-mblen: New file.
5387         * lib/unistr/u8-mblen.c: New file.
5388         * lib/unistr/u16-mblen.c: New file.
5389         * lib/unistr/u32-mblen.c: New file.
5390
5391         * modules/unistr/u8-mbtouc: New file.
5392         * modules/unistr/u16-mbtouc: New file.
5393         * modules/unistr/u32-mbtouc: New file.
5394         * lib/unistr/u8-mbtouc.c: New file.
5395         * lib/unistr/u16-mbtouc.c: New file.
5396         * lib/unistr/u32-mbtouc.c: New file.
5397
5398         * modules/unistr/u8-mbtouc-safe: New file.
5399         * modules/unistr/u16-mbtouc-safe: New file.
5400         * modules/unistr/u32-mbtouc-safe: New file.
5401         * lib/unistr/u8-mbtouc-safe.c: New file.
5402         * lib/unistr/u16-mbtouc-safe.c: New file.
5403         * lib/unistr/u32-mbtouc-safe.c: New file.
5404
5405         * modules/unistr/u8-move: New file.
5406         * modules/unistr/u16-move: New file.
5407         * modules/unistr/u32-move: New file.
5408         * lib/unistr/u8-move.c: New file.
5409         * lib/unistr/u16-move.c: New file.
5410         * lib/unistr/u32-move.c: New file.
5411         * lib/unistr/u-move.h: New file.
5412
5413         * modules/unistr/u8-next: New file.
5414         * modules/unistr/u16-next: New file.
5415         * modules/unistr/u32-next: New file.
5416         * lib/unistr/u8-next.c: New file.
5417         * lib/unistr/u16-next.c: New file.
5418         * lib/unistr/u32-next.c: New file.
5419
5420         * modules/unistr/u8-prev: New file.
5421         * modules/unistr/u16-prev: New file.
5422         * modules/unistr/u32-prev: New file.
5423         * lib/unistr/u8-prev.c: New file.
5424         * lib/unistr/u16-prev.c: New file.
5425         * lib/unistr/u32-prev.c: New file.
5426
5427         * modules/unistr/u8-set: New file.
5428         * modules/unistr/u16-set: New file.
5429         * modules/unistr/u32-set: New file.
5430         * lib/unistr/u8-set.c: New file.
5431         * lib/unistr/u16-set.c: New file.
5432         * lib/unistr/u32-set.c: New file.
5433         * lib/unistr/u-set.h: New file.
5434
5435         * modules/unistr/u8-startswith: New file.
5436         * modules/unistr/u16-startswith: New file.
5437         * modules/unistr/u32-startswith: New file.
5438         * lib/unistr/u8-startswith.c: New file.
5439         * lib/unistr/u16-startswith.c: New file.
5440         * lib/unistr/u32-startswith.c: New file.
5441         * lib/unistr/u-startswith.h: New file.
5442
5443         * modules/unistr/u8-stpcpy: New file.
5444         * modules/unistr/u16-stpcpy: New file.
5445         * modules/unistr/u32-stpcpy: New file.
5446         * lib/unistr/u8-stpcpy.c: New file.
5447         * lib/unistr/u16-stpcpy.c: New file.
5448         * lib/unistr/u32-stpcpy.c: New file.
5449         * lib/unistr/u-stpcpy.h: New file.
5450
5451         * modules/unistr/u8-stpncpy: New file.
5452         * modules/unistr/u16-stpncpy: New file.
5453         * modules/unistr/u32-stpncpy: New file.
5454         * lib/unistr/u8-stpncpy.c: New file.
5455         * lib/unistr/u16-stpncpy.c: New file.
5456         * lib/unistr/u32-stpncpy.c: New file.
5457         * lib/unistr/u-stpncpy.h: New file.
5458
5459         * modules/unistr/u8-strcat: New file.
5460         * modules/unistr/u16-strcat: New file.
5461         * modules/unistr/u32-strcat: New file.
5462         * lib/unistr/u8-strcat.c: New file.
5463         * lib/unistr/u16-strcat.c: New file.
5464         * lib/unistr/u32-strcat.c: New file.
5465         * lib/unistr/u-strcat.h: New file.
5466
5467         * modules/unistr/u8-strchr: New file.
5468         * modules/unistr/u16-strchr: New file.
5469         * modules/unistr/u32-strchr: New file.
5470         * lib/unistr/u8-strchr.c: New file.
5471         * lib/unistr/u16-strchr.c: New file.
5472         * lib/unistr/u32-strchr.c: New file.
5473
5474         * modules/unistr/u8-strcmp: New file.
5475         * modules/unistr/u16-strcmp: New file.
5476         * modules/unistr/u32-strcmp: New file.
5477         * lib/unistr/u8-strcmp.c: New file.
5478         * lib/unistr/u16-strcmp.c: New file.
5479         * lib/unistr/u32-strcmp.c: New file.
5480
5481         * modules/unistr/u8-strcpy: New file.
5482         * modules/unistr/u16-strcpy: New file.
5483         * modules/unistr/u32-strcpy: New file.
5484         * lib/unistr/u8-strcpy.c: New file.
5485         * lib/unistr/u16-strcpy.c: New file.
5486         * lib/unistr/u32-strcpy.c: New file.
5487         * lib/unistr/u-strcpy.h: New file.
5488
5489         * modules/unistr/u8-strcspn: New file.
5490         * modules/unistr/u16-strcspn: New file.
5491         * modules/unistr/u32-strcspn: New file.
5492         * lib/unistr/u8-strcspn.c: New file.
5493         * lib/unistr/u16-strcspn.c: New file.
5494         * lib/unistr/u32-strcspn.c: New file.
5495         * lib/unistr/u-strcspn.h: New file.
5496
5497         * modules/unistr/u8-strdup: New file.
5498         * modules/unistr/u16-strdup: New file.
5499         * modules/unistr/u32-strdup: New file.
5500         * lib/unistr/u8-strdup.c: New file.
5501         * lib/unistr/u16-strdup.c: New file.
5502         * lib/unistr/u32-strdup.c: New file.
5503         * lib/unistr/u-strdup.h: New file.
5504
5505         * modules/unistr/u8-strlen: New file.
5506         * modules/unistr/u16-strlen: New file.
5507         * modules/unistr/u32-strlen: New file.
5508         * lib/unistr/u8-strlen.c: New file.
5509         * lib/unistr/u16-strlen.c: New file.
5510         * lib/unistr/u32-strlen.c: New file.
5511         * lib/unistr/u-strlen.h: New file.
5512
5513         * modules/unistr/u8-strmblen: New file.
5514         * modules/unistr/u16-strmblen: New file.
5515         * modules/unistr/u32-strmblen: New file.
5516         * lib/unistr/u8-strmblen.c: New file.
5517         * lib/unistr/u16-strmblen.c: New file.
5518         * lib/unistr/u32-strmblen.c: New file.
5519
5520         * modules/unistr/u8-strmbtouc: New file.
5521         * modules/unistr/u16-strmbtouc: New file.
5522         * modules/unistr/u32-strmbtouc: New file.
5523         * lib/unistr/u8-strmbtouc.c: New file.
5524         * lib/unistr/u16-strmbtouc.c: New file.
5525         * lib/unistr/u32-strmbtouc.c: New file.
5526
5527         * modules/unistr/u8-strncat: New file.
5528         * modules/unistr/u16-strncat: New file.
5529         * modules/unistr/u32-strncat: New file.
5530         * lib/unistr/u8-strncat.c: New file.
5531         * lib/unistr/u16-strncat.c: New file.
5532         * lib/unistr/u32-strncat.c: New file.
5533         * lib/unistr/u-strncat.h: New file.
5534
5535         * modules/unistr/u8-strncmp: New file.
5536         * modules/unistr/u16-strncmp: New file.
5537         * modules/unistr/u32-strncmp: New file.
5538         * lib/unistr/u8-strncmp.c: New file.
5539         * lib/unistr/u16-strncmp.c: New file.
5540         * lib/unistr/u32-strncmp.c: New file.
5541
5542         * modules/unistr/u8-strncpy: New file.
5543         * modules/unistr/u16-strncpy: New file.
5544         * modules/unistr/u32-strncpy: New file.
5545         * lib/unistr/u8-strncpy.c: New file.
5546         * lib/unistr/u16-strncpy.c: New file.
5547         * lib/unistr/u32-strncpy.c: New file.
5548         * lib/unistr/u-strncpy.h: New file.
5549
5550         * modules/unistr/u8-strnlen: New file.
5551         * modules/unistr/u16-strnlen: New file.
5552         * modules/unistr/u32-strnlen: New file.
5553         * lib/unistr/u8-strnlen.c: New file.
5554         * lib/unistr/u16-strnlen.c: New file.
5555         * lib/unistr/u32-strnlen.c: New file.
5556         * lib/unistr/u-strnlen.h: New file.
5557
5558         * modules/unistr/u8-strpbrk: New file.
5559         * modules/unistr/u16-strpbrk: New file.
5560         * modules/unistr/u32-strpbrk: New file.
5561         * lib/unistr/u8-strpbrk.c: New file.
5562         * lib/unistr/u16-strpbrk.c: New file.
5563         * lib/unistr/u32-strpbrk.c: New file.
5564         * lib/unistr/u-strpbrk.h: New file.
5565
5566         * modules/unistr/u8-strrchr: New file.
5567         * modules/unistr/u16-strrchr: New file.
5568         * modules/unistr/u32-strrchr: New file.
5569         * lib/unistr/u8-strrchr.c: New file.
5570         * lib/unistr/u16-strrchr.c: New file.
5571         * lib/unistr/u32-strrchr.c: New file.
5572
5573         * modules/unistr/u8-strspn: New file.
5574         * modules/unistr/u16-strspn: New file.
5575         * modules/unistr/u32-strspn: New file.
5576         * lib/unistr/u8-strspn.c: New file.
5577         * lib/unistr/u16-strspn.c: New file.
5578         * lib/unistr/u32-strspn.c: New file.
5579         * lib/unistr/u-strspn.h: New file.
5580
5581         * modules/unistr/u8-strstr: New file.
5582         * modules/unistr/u16-strstr: New file.
5583         * modules/unistr/u32-strstr: New file.
5584         * lib/unistr/u8-strstr.c: New file.
5585         * lib/unistr/u16-strstr.c: New file.
5586         * lib/unistr/u32-strstr.c: New file.
5587         * lib/unistr/u-strstr.h: New file.
5588
5589         * modules/unistr/u8-strtok: New file.
5590         * modules/unistr/u16-strtok: New file.
5591         * modules/unistr/u32-strtok: New file.
5592         * lib/unistr/u8-strtok.c: New file.
5593         * lib/unistr/u16-strtok.c: New file.
5594         * lib/unistr/u32-strtok.c: New file.
5595         * lib/unistr/u-strtok.h: New file.
5596
5597         * modules/unistr/u8-uctomb: New file.
5598         * modules/unistr/u16-uctomb: New file.
5599         * modules/unistr/u32-uctomb: New file.
5600         * lib/unistr/u8-uctomb.c: New file.
5601         * lib/unistr/u16-uctomb.c: New file.
5602         * lib/unistr/u32-uctomb.c: New file.
5603
5604         * MODULES.html.sh (Unicode string functions): Add the new modules.
5605
5606 2007-01-08  Bruno Haible  <bruno@clisp.org>
5607
5608         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
5609         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
5610         subdirectories.
5611
5612 2007-01-08  Karl Berry  <karl@gnu.org>
5613
5614         * doc/error.texi: mention that main() fns must set program_name
5615         when progname is used.
5616
5617 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
5618
5619         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
5620         WCTYPE_H is empty, for the benefit of builds from non-distclean
5621         directories.  Problem reported by Eric Blake in
5622         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
5623
5624 2007-01-08  Bruno Haible  <bruno@clisp.org>
5625
5626         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
5627         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
5628         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
5629         PROVIDE_CANONICALIZE_FILENAME_MODE.
5630         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
5631
5632 2007-01-08  Bruno Haible  <bruno@clisp.org>
5633
5634         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
5635         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
5636         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
5637         * lib/fts.c: Likewise.
5638         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
5639
5640 2006-12-25  Bruno Haible  <bruno@clisp.org>
5641
5642         * modules/utf8-ucs4-safe: New file.
5643         * lib/utf8-ucs4-safe.h: New file.
5644         * lib/unistr/utf8-ucs4-safe.c: New file.
5645
5646         * modules/utf16-ucs4-safe: New file.
5647         * lib/utf16-ucs4-safe.h: New file.
5648         * lib/unistr/utf16-ucs4-safe.c: New file.
5649
5650         * MODULES.html.sh (Unicode string functions): Add the new modules.
5651
5652 2007-01-08  Bruno Haible  <bruno@clisp.org>
5653
5654         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
5655         (Depends-on): Add unitypes.
5656         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
5657         (u8_mbtouc_aux): Move out to separate file.
5658         (u8_mbtouc): Use ucs4_t, uint8_t types.
5659         * lib/unistr/utf8-ucs4.c: New file.
5660
5661         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
5662         (Depends-on): Add unitypes.
5663         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
5664         (u16_mbtouc_aux): Move out to separate file.
5665         (u16_mbtouc): Use ucs4_t, uint16_t types.
5666         * lib/unistr/utf16-ucs4.c: New file.
5667
5668         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
5669         (Depends-on): Add unitypes.
5670         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
5671         (u8_uctomb_aux): Move out to separate file.
5672         (u8_uctomb): Use ucs4_t, uint8_t types.
5673         * lib/unistr/ucs4-utf8.c: New file.
5674
5675         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
5676         (Depends-on): Add unitypes.
5677         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
5678         (u16_uctomb_aux): Move out to separate file.
5679         (u16_uctomb): Use ucs4_t, uint16_t types.
5680         * lib/unistr/ucs4-utf16.c: New file.
5681
5682 2006-12-25  Bruno Haible  <bruno@clisp.org>
5683
5684         * modules/unitypes: New file.
5685         * lib/unitypes.h: New file.
5686         * MODULES.html.sh (func_all_modules): New section "Unicode string
5687         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
5688         this section. Add unitypes.
5689
5690 2007-01-08  Bruno Haible  <bruno@clisp.org>
5691
5692         Avoid variable names that conflict with those from libtool.
5693         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
5694         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
5695         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
5696         library_names_spec to acl_library_names_spec, hardcode_* to
5697         acl_hardcode_*.
5698         Reported by Ralf Wildenhues.
5699
5700 2007-01-08  Bruno Haible  <bruno@clisp.org>
5701
5702         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
5703         definition.
5704         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
5705         definition.
5706         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
5707         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
5708         definition.
5709         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
5710         definition.
5711         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
5712         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
5713         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
5714         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
5715         definition.
5716         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
5717         definition.
5718         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
5719         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
5720         GC_USE_<algorithm>.
5721         * lib/gc-libgcrypt.c: Likewise.
5722         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
5723         * modules/gc-arctwo (configure.ac): Likewise.
5724         * modules/gc-des (configure.ac): Likewise.
5725         * modules/gc-hmac-md5 (configure.ac): Likewise.
5726         * modules/gc-hmac-sha1 (configure.ac): Likewise.
5727         * modules/gc-md2 (configure.ac): Likewise.
5728         * modules/gc-md4 (configure.ac): Likewise.
5729         * modules/gc-md5 (configure.ac): Likewise.
5730         * modules/gc-random (configure.ac): Likewise.
5731         * modules/gc-rijndael (configure.ac): Likewise.
5732         * modules/gc-sha1 (configure.ac): Likewise.
5733
5734 2007-01-08  Bruno Haible  <bruno@clisp.org>
5735
5736         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
5737         macro definition.
5738         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
5739         definition.
5740         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
5741         definition.
5742         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
5743         * modules/fcntl-safer (configure.ac): Likewise.
5744         * modules/fopen-safer (configure.ac): Likewise.
5745         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
5746         GNULIB_FWRITEERROR macro definition.
5747
5748 2007-01-08  Bruno Haible  <bruno@clisp.org>
5749
5750         * m4/gnulib-common.m4: New file.
5751         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
5752         (func_get_filelist): Add m4/gnulib-common.m4.
5753
5754 2007-01-08  Bruno Haible  <bruno@clisp.org>
5755
5756         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
5757         command.
5758
5759 2007-01-08  Jim Meyering  <jim@meyering.net>
5760
5761         Use a more robust test for a "can't happen" condition.
5762         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
5763         narrowed the st_size value.  Presuming the "can't happen" condition
5764         is true, that narrowing could conceivably convert an invalid st_size
5765         value into a valid one.  Instead, use a change based on Matthew
5766         Woehlke's original patch.
5767
5768         Slight readability improvement: use an assert-like macro
5769         in place of literal "abort ()" uses.
5770         * lib/fts.c (fts_assert): Define.
5771         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
5772         Use this macro instead of a bare 'abort'.
5773
5774 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
5775
5776         Don't worry about using IRIX 5.3's wctype.h broken definitions;
5777         simply work around them.
5778         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
5779         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
5780         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
5781         declaring.
5782         Don't bother to define as macros, since the standard doesn't require it.
5783         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
5784         longer worry about IRIX 5.3.
5785         (HAVE_WCTYPE_CTMP_BUG): Remove.
5786
5787 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
5788
5789         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
5790         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
5791         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
5792         Problems reported by Georg Schwarz for IRIX 5.3.
5793
5794         * gnulib-tool (autoconf_minversion): Take the maximum version number
5795         found, not the minimum.  Problem reported by James Youngman.
5796
5797 2007-01-03  Karl Berry  <karl@gnu.org>
5798
5799         * doc/error.texi: new file, explaining interaction with progname.
5800         * doc/gnulib.texi: include it.  Update copyright.
5801
5802 2007-01-03  Simon Josefsson  <simon@josefsson.org>
5803
5804         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
5805         AC_CANONICAL_HOST, to improve autobuild outputs.
5806
5807 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
5808             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
5809
5810         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
5811         sockets, server sockets, and other file descriptors.  Count errors
5812         to compute the return value.  Reorder the code a bit to be easier
5813         to follow.  Don't set event bits that were not requested (except
5814         POLLERR and POLLHUP).
5815
5816 2007-01-01  Bruno Haible  <bruno@clisp.org>
5817
5818         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
5819
5820 2007-01-03  Jim Meyering  <jim@meyering.net>
5821
5822         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
5823
5824 2007-01-02  Bruno Haible  <bruno@clisp.org>
5825
5826         * modules/settime (Include): Require timespec.h.
5827         * modules/nanosleep (Include): Likewise.
5828
5829 2007-01-01  Bruno Haible  <bruno@clisp.org>
5830
5831         * gnulib-tool (func_emit_copyright_notice): Bump year.
5832         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
5833
5834 2007-01-01  Bruno Haible  <bruno@clisp.org>
5835
5836         Improve support for OpenBSD.
5837         * build-aux/config.rpath (libname_spec): Export.
5838         (library_names_spec): New variable. Export.
5839         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
5840         library_names_spec from the config.rpath output. Locate shared library
5841         through the name pattern in library_names_spec.
5842
5843 2007-01-01  Eric Blake  <ebb9@byu.net>
5844
5845         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
5846
5847 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
5848
5849         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
5850         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
5851         assume the C locale, and avoid an "eval" that could cause trouble.
5852         Problem with SORT reported by Bob Proulx.
5853
5854         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
5855         Define.  Trivial patch from Henning Nielsen Lund, originally
5856         sent to bug-grep@gnu.org today.
5857
5858 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
5859
5860         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
5861         struct stat.  Problem reported by Henning Nielsen Lund.
5862         * lib/acl.c: Include acl.h first, to check interface.  Don't
5863         bother to include sys/types.h and sys/stat.h again.
5864
5865 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
5866
5867         Import the following change from libc; problem reported by
5868         Sven Verdoolaege.
5869
5870         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
5871
5872         [BZ #1373]
5873         * lib/argp.h: Remove __NTH for __argp_usage inline function.
5874
5875 2006-12-28  Jim Meyering  <jim@meyering.net>
5876
5877         * build-aux/announce-gen: Do not assume that the package
5878         builds any of tar.gz, tar.bz2, and .xdelta files.
5879         Suggestion from Simon Josefsson.
5880
5881 2006-12-28  Simon Josefsson  <simon@josefsson.org>
5882
5883         * modules/announce-gen: New file.
5884
5885 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
5886
5887         * lib/mbchar.h: Just include <wctype.h>; the wctype module
5888         handles its gotchas now.
5889         * lib/mbswidth.c: Likewise.
5890         * lib/wcwidth.h: Likewise.
5891         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
5892         and iswcntrl; the wctype module does this stuff now.
5893         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
5894         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
5895         * modules/mbchar (Depends-on): Add wctype.
5896         * modules/mbswidth (Depends-on): Likewise.
5897         * modules/wcwidth (Depends-on): Likewise.
5898
5899 2006-12-27  Eric Blake  <ebb9@byu.net>
5900
5901         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
5902         module uses more than what <wctype.h> is required to provide.
5903
5904 2006-12-26  Eric Blake  <ebb9@byu.net>
5905
5906         * gnulib-tool (sed_extract_prog): Avoid space-tab.
5907
5908 2006-12-26  Eric Blake  <ebb9@byu.net>
5909
5910         * modules/absolute-header: New module.
5911         * modules/fcntl (Depends-on): Depend on it.
5912         * modules/inttypes (Depends-on): Likewise.
5913         * modules/stdint (Depends-on): Likewise.
5914         * modules/sys_stat (Depends-on): Likewise.
5915         * modules/wctype (Depends-on): Likewise.
5916         * MODULES.html.sh (Support for building libraries and
5917         executables): Document it.
5918
5919 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
5920
5921         * gnulib-tool (SED): Remove, undoing previous change.
5922         The problem was that it broke coreutils on Solaris, because
5923         "sed --posix" leaked into a makefile.
5924         (sed): New alias, if 'alias' and GNU sed.
5925
5926 2006-12-24  Jim Meyering  <jim@meyering.net>
5927
5928         Work around an fchownat bug in glibc-2.4:
5929         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
5930         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
5931         in spite of the -P option.
5932         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
5933         New macros.
5934         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
5935         * modules/openat (Files): Add lib/fchownat.c.
5936         * lib/openat.c (fchownat): Don't define here.  Move to...
5937         * lib/fchownat.c: ...this new file.
5938
5939 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
5940
5941         Fix bug reported by Bruno Haible in
5942         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
5943         where quotearg.c didn't compile on Mac OS X 10.2 because it
5944         lacks <wchar.h> and wint_t.
5945         * lib/wctype_.h (__wctype_wint_t): New type.
5946         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
5947         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
5948         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
5949         Arg is now of type __wctype_wint_t, not wint_t.
5950         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
5951         substitute HAVE_WINT_T.
5952         * modules/wctype (Files): Add m4/wint_t.m4.
5953         (wctype.h): Substitute HAVE_WINT_T.
5954
5955 2006-12-23  Bruno Haible  <bruno@clisp.org>
5956
5957         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
5958
5959 2006-12-23  Bruno Haible  <bruno@clisp.org>
5960
5961         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
5962         S_ISLNK.
5963         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
5964         mingw.
5965
5966 2006-12-22  Bruno Haible  <bruno@clisp.org>
5967
5968         * lib/copy-file.c: Include acl.h.
5969         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
5970         Close the file descriptors only after being done with copy_acl.
5971         * modules/copy-file (Depends-on): Add acl.
5972
5973 2006-12-22  Bruno Haible  <bruno@clisp.org>
5974
5975         * gnulib-tool (SED): New variable.
5976         Use $SED instead of sed everywhere.
5977
5978 2006-12-22  Bruno Haible  <bruno@clisp.org>
5979
5980         * modules/no-c++: New file.
5981         * m4/no-c++.m4: New file.
5982         * MODULES.html.sh (Support for building libraries and executables):
5983         Add no-c++.
5984
5985 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
5986
5987         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
5988         Include <limits.h>, and use its INT_MAX to rewrite the
5989         j loop so that it does not overflow 'int'.  Problem reported by
5990         Ralf Wildenhues in
5991         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
5992         Play it safe by shifting left by 1 rather than multiplying by 2,
5993         as GCC is less likely to optimize this away when the value
5994         is signed (when it assumes overflow leads to undefined behavior).
5995         Also, don't assume time_t uses two's complement.
5996
5997 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
5998
5999         * MODULES.html.sh: New module wctype.
6000         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
6001         * lib/fnmatch.c: Don't bother to include <wchar.h> before
6002         <wctype.h>, since the new wctype module should fix this.
6003         * lib/quotearg.c: Include <wctype.h> unconditionally, since
6004         the wctype module should arrange for it.
6005         * lib/regex_internal.h: Likewise.
6006         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
6007         since the wctype module should handle this now.
6008         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
6009         * modules/fnmatch (Depends-on): Add wctype.
6010         * modules/quotearg (Depends-on): Likewise.
6011         * modules/regex (Depends-on): Likewise.
6012
6013 2006-12-19  Bruno Haible  <bruno@clisp.org>
6014
6015         * lib/strdup.h [C++]: Wrap definitions in extern "C".
6016         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
6017
6018 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6019
6020         * modules/savewd (Depends-on): Fix dependency on fcntl.
6021
6022 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
6023
6024         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
6025         conforms to C99, rather than relying on the user's environment
6026         setting of STDINT_H.
6027
6028 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
6029         and Eric Blake  <ebb9@byu.net>
6030
6031         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
6032         This is more consistent with the other defines here.
6033         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
6034         Port to z/OS.  Problem reported by Paul Gilmartin.
6035         Change local vars to use gl_ prefix rather than ac_.
6036         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
6037         with other defines.
6038         * modules/double-slash-root: New module.
6039         * modules/dirname (Files): Remove m4/double-slash-root.m4.
6040         (Depends-on): Add double-slash-root.
6041         * MODULES.html.sh (File system functions): Mention new module.
6042
6043 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
6044
6045         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
6046         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
6047         This is for the benefit of gzip, which doesn't do i18n.
6048
6049 2006-12-12  Jim Meyering  <jim@meyering.net>
6050
6051         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
6052         Reported by Andreas Schwab <schwab@suse.de>.
6053
6054 2006-12-12  Bruno Haible  <bruno@clisp.org>
6055
6056         Merge these changes.
6057         2006-09-05  Bruno Haible  <bruno@clisp.org>
6058         * lib/iconvme.c (iconv_string): No need to save and restore errno when
6059         iconv_alloc succeeded.
6060         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
6061         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
6062         test for " && dest " at the end - dest is always != NULL there. Call
6063         iconv with 4xNULL arguments initially, to reset the state. Call iconv
6064         with 2xNULL arguments, also to flush the state storage. Handle the
6065         IRIX iconv behaviour. Realloc the final result, to throw away unused
6066         memory.
6067
6068 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
6069
6070         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
6071         and fchmodat unconditionally, since glibc 2.4 has them.
6072         Problem reported by Arkadiusz Miskiewicz.
6073
6074 2006-12-10  Bruno Haible  <bruno@clisp.org>
6075
6076         * gnulib-tool (func_import): Show the include files only for those
6077         modules that are copied and specified.
6078         Reported by Karl Berry.
6079
6080 2006-12-08  Jim Meyering  <jim@meyering.net>
6081
6082         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
6083         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
6084
6085         * build-aux/announce-gen: Add two new options, both optional:
6086         --bootstrap-tools=TOOL_LIST
6087               a comma-separated list of tools, e.g.,
6088               autoconf,automake,bison,gnulib
6089         --gnulib-snapshot-date=DATE
6090               if gnulib is in the bootstrap tool list,
6091               then report this as the snapshot date.
6092               If not specified, use the current date/time.
6093               If you specify a date here, be sure it's UTC.
6094
6095 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6096
6097         * tests/test-argp-2.sh: Fix test to match actual output.
6098         (func_compare): Fix sed script to be portable.
6099
6100 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
6101
6102         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
6103         workaround for this case.  It is not autoconfigured now; offhand
6104         it's hard to see how to autoconfigure it.
6105
6106 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
6107
6108         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
6109         a directory that is about to be chowned.  Such a directory's
6110         initial file permissions should permit the owner only and this
6111         should not be changed until after the chown, since the group and
6112         other bits would be incorrect if they granted permission before
6113         the chown.
6114
6115         Fix porting problem for iswctype reported by Georg Schwarz in:
6116         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
6117         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
6118         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
6119         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
6120         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
6121
6122 2006-12-03  Jim Meyering  <jim@meyering.net>
6123
6124         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
6125         p->fts_statp may not yet be defined.
6126         (fts_read): Instead, set it in the caller, once p->fts_statp is
6127         sure to be defined, and corresponds to a top-level directory.
6128         This bug made du -x fail.  Here's the coreutils test case:
6129         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
6130         Reported by Mike Frysinger.
6131
6132 2006-12-01  Jim Meyering  <jim@meyering.net>
6133
6134         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
6135         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
6136         Reported by Simon Josefsson.
6137
6138 2006-11-30  Jim Meyering  <jim@meyering.net>
6139
6140         * m4/warning.m4: Use the all-permissive copyright notice
6141         recommended by RMS (rather than LGPL).
6142         * m4/vararrays.m4: Likewise.
6143         * m4/flexmember.m4: Likewise.
6144
6145 2006-11-29  Bruno Haible  <bruno@clisp.org>
6146
6147         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
6148         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
6149         using +=.
6150         Reported by Simon Josefsson <simon@josefsson.org>.
6151
6152 2006-11-28  James Youngman <jay@gnu.org>
6153
6154         * README: Advise users that they might find the bug-gnulib@gnu.org
6155         and autotools-announce@gnu.org mailing lists useful.
6156
6157 2006-11-28  Bruno Haible  <bruno@clisp.org>
6158
6159         * m4/ptrdiff_max.m4: Remove file.
6160
6161 2006-11-21  Bruno Haible  <bruno@clisp.org>
6162
6163         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
6164         _AC_COMPUTE_INT.
6165         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6166         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
6167         _AC_COMPUTE_INT.
6168         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6169         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
6170         _AC_COMPUTE_INT.
6171         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6172
6173 2006-11-28  Jim Meyering  <jim@meyering.net>
6174
6175         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
6176         warning from "gcc -Wshadow" about shadowing the builtin.
6177
6178 2006-11-27  Bruno Haible  <bruno@clisp.org>
6179
6180         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
6181         _AC_COMPUTE_INT.
6182         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6183
6184 2006-11-27  Bruno Haible  <bruno@clisp.org>
6185             Paul Eggert  <eggert@cs.ucla.edu>
6186
6187         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
6188
6189 2006-11-26  Bruno Haible  <bruno@clisp.org>
6190
6191         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
6192         noinst_LTLIBRARIES.
6193
6194 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
6195             Bruno Haible  <bruno@clisp.org>
6196
6197         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
6198         if compiling with "gcc -ansi".
6199
6200 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
6201
6202         Fix some incompatibilities with gcc -ansi -pedantic.
6203         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
6204         if compiling pedantically with GCC, unless it's C99 or later.
6205         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
6206         it mishandles gcc -ansi -pedantic as well.
6207         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
6208         if gcc -pedantic.
6209         * lib/regexec.c (check_node_accept_bytes): Don't use auto
6210         initializers for struct if -pedantic, unless it's C99 or later.
6211
6212 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
6213
6214         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
6215         Don't close an fd more than once. Identical atimes indicate
6216         success, not failure.
6217
6218 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
6219
6220         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
6221
6222 2006-11-23  Jim Meyering  <jim@meyering.net>
6223
6224         * build-aux/announce-gen: New file.  From coreutils.
6225
6226 2006-11-22  Jim Meyering  <jim@meyering.net>
6227
6228         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
6229         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
6230         (fts_read): Use a temporary to narrow the overused st_size member
6231         before using it in a switch statement.  Reported by Matthew Woehlke.
6232
6233         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
6234         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
6235
6236 2006-11-20  Bruno Haible  <bruno@clisp.org>
6237
6238         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
6239         changequote instead of pairs of brackets.
6240         Reported by Andreas Schwab <schwab@suse.de>.
6241
6242 2006-11-21  Jim Meyering  <jim@meyering.net>
6243
6244         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
6245         so as to remain compatible with older compilers.
6246         Patch from Michael Deutschmann.
6247
6248 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
6249
6250         * MODULES.html.sh (File system functions): Add openat.
6251
6252         * lib/openat.h (rpl_fstatat): New macro, if
6253         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
6254         (fstatat): Define to rpl_fstatat under the same conditions,
6255         unless COMPILING_FSTATAT.
6256         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
6257         seems to have the bug.
6258         * lib/fstatat.c: New file.
6259         * modules/openat (Files): Add it.
6260
6261 2006-11-20  Bruno Haible  <bruno@clisp.org>
6262
6263         * Makefile: New file.
6264
6265 2006-11-20  Jim Meyering  <jim@meyering.net>
6266
6267         The beginnings of syntax-related checks for gnulib.
6268         * lib/Makefile: New file.
6269         * lib/t-idcache: New script.  Ensure that the two halves of
6270         idcache.c stay in sync.
6271
6272         * lib/idcache.c: Adjust comments in user- and group- portions to
6273         be more accurate, and to be consistent with one another.
6274
6275 2006-11-20  Jim Meyering  <jim@meyering.net>
6276
6277         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
6278         continue using the flexible array member (thus, this module performs
6279         half as many malloc calls), with the addition that...
6280         (getgroup, getuser): Consistently record a non-match via an empty
6281         "name" string, and map an empty string match to a NULL return value.
6282         * modules/idcache (Depends-on): Re-add flexmember.
6283
6284         * lib/idcache.c (getuser): Remove all uses of the register keyword.
6285         (getuidbyname, getgroup, getgidbyname): Likewise.
6286
6287         Use cleaner syntax: NULL rather than 0.
6288         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
6289
6290 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
6291
6292         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
6293         It mishandled the case where the group was missing.
6294         Problem reported by Greg Schafer.
6295         * modules/idcache: Likewise.
6296
6297 2006-11-18  Jim Meyering  <jim@meyering.net>
6298
6299         * check-module (%exempt_header): Add exception for some
6300         conditionally-included headers.
6301
6302         * modules/i-ring (Depends-on): Add verify.
6303         (License): Change to LGPL.
6304
6305 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
6306
6307         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
6308         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
6309         and inttostr.h.  Use snprintf rather than uinttostr, so that
6310         LGPLed code doesn't depend on GPLed.
6311
6312 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
6313
6314         * modules/inline (License): Change from GPL to LGPL.
6315
6316 2006-11-17  Jim Meyering  <jim@meyering.net>
6317
6318         * modules/d-type (License): Switch to LGPL.
6319
6320 2006-11-15  Bruno Haible  <bruno@clisp.org>
6321
6322         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
6323
6324 2006-11-15  Eric Blake  <ebb9@byu.net>
6325
6326         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
6327         the module dependency.
6328
6329 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6330             Bruno Haible  <bruno@clisp.org>
6331
6332         * gnulib-tool (func_create_testdir): Add license consistency check.
6333
6334 2006-11-15  Eric Blake  <ebb9@byu.net>
6335
6336         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
6337         random "(cached)" in configure output.
6338
6339 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6340
6341         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
6342         test for conforming inttypes.h is both announced and cached.
6343
6344         * MODULES.html.sh (seen_modules, seen_files): New variables.
6345         (func_module): Rewrite to use a few less gnulib-tool and sed
6346         invocations.  Avoid a couple of quadratic algorithms for ...
6347         (missed_modules, missed_files): ... these, with ...
6348         (func_append, func_tmpdir): ... these new functions, from
6349         gnulib-tool.  Analogously, install traps for cleanup.
6350
6351         * tests/test-gc.c (main): Remove unused variables.
6352         * tests/test-read-file.c: Include stdlib.h, for 'free'.
6353
6354 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
6355
6356         * modules/inttostr (License): Change to LGPL.
6357
6358 2006-11-14  Eric Blake  <ebb9@byu.net>
6359
6360         * modules/tempname (License): Change to LGPL.
6361
6362 2006-11-14  Eric Blake  <ebb9@byu.net>
6363
6364         * doc/functions.texi (Function Portability): *printf functions on
6365         Cygwin now understand all POSIX size specifiers.
6366
6367 2006-11-14  Bruno Haible  <bruno@clisp.org>
6368
6369         * modules/c-ctype (License): Change to LGPL.
6370
6371 2006-11-12  Bruno Haible  <bruno@clisp.org>
6372
6373         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
6374         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
6375         for GNOME libraries, for which the include files are installed in
6376         subdirectories of $prefix/include.
6377
6378 2006-11-12  Bruno Haible  <bruno@clisp.org>
6379
6380         * m4/lib-link.m4: Require at least autoconf-2.54.
6381         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
6382         name to underscores for the --with option.
6383
6384 2006-11-13  Bruno Haible  <bruno@clisp.org>
6385
6386         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
6387         the tests directory.
6388         Reported by Ralf Wildenhues.
6389
6390 2006-11-13  Bruno Haible  <bruno@clisp.org>
6391
6392         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
6393         (func_emit_initmacro_end): Undo the override here.
6394         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
6395         Works around the famous automake error in coreutils.
6396
6397 2006-11-13  Eric Blake  <ebb9@byu.net>
6398
6399         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
6400         element, not its node.
6401
6402 2006-11-12  Bruno Haible  <bruno@clisp.org>
6403
6404         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
6405         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
6406
6407 2006-11-12  Bruno Haible  <bruno@clisp.org>
6408
6409         * gnulib-tool: New option --local-symlink.
6410         (func_usage): Document it.
6411         (lsymbolic): New variable.
6412         (func_import, func_create_testdir): If --symlink was not specified,
6413         test whether --local-symlink was specified and the file comes from
6414         the local_gnulib_dir.
6415
6416 2006-11-12  Bruno Haible  <bruno@clisp.org>
6417
6418         * gnulib-tool (func_ln): New function.
6419         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
6420
6421 2006-11-12  Bruno Haible  <bruno@clisp.org>
6422
6423         Finish support for source files in subdirectories.
6424         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
6425         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
6426         AUTOMAKE_OPTIONS.
6427         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
6428
6429 2006-11-12  Bruno Haible  <bruno@clisp.org>
6430
6431         * gnulib-tool (func_get_automake_snippet): Synthesize also an
6432         EXTRA_lib_SOURCES augmentation.
6433         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
6434
6435 2006-11-12  Jim Meyering  <jim@meyering.net>
6436
6437         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
6438         file descriptors.  This also averts a failure on systems with
6439         native openat support when a traversed directory lacks "x" access.
6440         * lib/fts_.h: Include "i-ring.h"
6441         (struct FTS) [fts_fd_ring]: New member.
6442         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
6443         (FCHDIR): Add parentheses.
6444         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
6445         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
6446         When descending, rather than simply closing the previous
6447         fts_cwd_fd value, push that file descriptor onto the ring.
6448         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
6449         (fts_open): Initialize the new fd_ring member.
6450         (fts_close): Clear the ring.
6451         (fts_safe_changedir): When possible, use our new fd_ring to skip
6452         the diropen and fstat and dev/ino comparison that would normally
6453         accompany a virtual `chdir ("..")'.
6454
6455         * modules/fts (Depends-on): Add i-ring.
6456         * modules/i-ring: New module.
6457         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
6458         * m4/i-ring.m4: New file.
6459
6460 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6461
6462         * gnulib-tool (func_create_testdir): Fix replacement of
6463         `build-aux' in configure.ac.  Run autotools in gltests
6464         subdirectory.
6465         (func_create_testdir, func_create_megatestdir, test): There is
6466         no need for '--force' in most autotool invocations in a new
6467         tree.  Actually fail the whole test if any of the tools, or the
6468         configure or make stages fail.
6469
6470         Sync from Automake.
6471         * build-aux/gnupload: Revert last change.  Add pointer to upload
6472         instructions of the GNU Maintenance Instructions.
6473         Suggestion by Karl Berry.
6474
6475 2006-11-10  Jim Meyering  <jim@meyering.net>
6476
6477         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
6478
6479 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
6480
6481         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
6482         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
6483         (bind_textdomain_codeset) [! ENABLE_NLS]:
6484         Evaluate all the arguments.  That way, callers get compatible behavior
6485         if the arguments have side effects.  Also, it avoids some GCC
6486         diagnostics in some cases; Joel E. Denny reported problems when Bison
6487         was configured with --enable-gcc-warnigs.
6488
6489 2006-11-10  Jim Meyering  <jim@meyering.net>
6490
6491         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
6492         relevant options in CFLAGS (like -O, -fno-inline) are taken into
6493         account.
6494
6495 2006-11-10  Jim Meyering  <jim@meyering.net>
6496
6497         * modules/inline: New file/module.
6498         * modules/xalloc (Files): Remove m4/inline.m4.
6499         (Depends-on): Add inline, instead.
6500         * modules/oset: Likewise.
6501         * modules/list: Likewise.
6502
6503 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
6504
6505         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
6506         Problem reported by Matthew Woehlke.
6507
6508 2006-11-09  Bruno Haible  <bruno@clisp.org>
6509
6510         * lib/tempname.c (gen_tempname): Remove variant that invokes
6511         __gen_tempname.
6512         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
6513         __gen_tempname.
6514
6515 2006-11-08  Bruno Haible  <bruno@clisp.org>
6516
6517         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
6518         to 'yes' instead of 'cross-compiling'.
6519
6520 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
6521
6522         * lib/quotearg.h (quotearg_free): New decl.
6523         * lib/quotearg.c (quotearg_free): New function.
6524         (slot0, nslots, slotvec0, slotvec):
6525         Now file-scope so that quotearg_free can get at them.
6526
6527 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6528
6529         Sync from Automake.
6530         * build-aux/gnupload: Add missing 'gnu' to example URL.
6531         Report by Karl Berry.
6532
6533 2006-11-08  Bruno Haible  <bruno@clisp.org>
6534
6535         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
6536         Suggested by Paul Eggert.
6537
6538 2006-11-08  Jim Meyering  <jim@meyering.net>
6539
6540         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
6541         It's already included if !_LIBC.
6542         (fts_safe_changedir): Add a comment.
6543
6544 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
6545
6546         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
6547         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
6548         Matthew Woehlke.
6549
6550         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
6551         definitions up, to avoid colliding with change below.
6552         (static_inline) [HAVE_INLINE]: New macro.
6553         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
6554         Provide extern decls when !HAVE_INLINE.  Do not define unless
6555         static_inline is defined, either by us or by xmalloc.c.  Use
6556         static_inline rather than static inline.
6557         (XCALLOC): Optimize sizeof(T) = 1 case.
6558         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
6559
6560 2006-11-07  Bruno Haible  <bruno@clisp.org>
6561
6562         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
6563         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
6564         AC_C_INLINE.
6565         * modules/xalloc (Files): Add m4/inline.m4.
6566
6567 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6568
6569         * README: Fix typo.
6570         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
6571         (Miscellanous Notes): ...from this.
6572
6573 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
6574
6575         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
6576         Mention that offsetof should be used instead of sizeof.
6577         From Bruno Haible.
6578
6579 2006-11-07  Bruno Haible  <bruno@clisp.org>
6580
6581         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
6582
6583 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
6584
6585         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
6586         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
6587         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
6588         (gl_tree_add_before, gl_tree_add_after):
6589         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
6590         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
6591         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
6592         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
6593         (gl_linked_add_after, gl_linked_add_at): Likewise.
6594         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
6595         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
6596         (gl_tree_add_before, gl_tree_add_after): Likewise.
6597         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
6598         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
6599         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
6600
6601 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6602
6603         * lib/gl_oset.h: Use C comment style, not C++ comment style.
6604
6605 2006-11-06  Bruno Haible  <bruno@clisp.org>
6606
6607         * m4/inline.m4: New file.
6608         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
6609         * modules/list (Files): Add m4/inline.m4.
6610         * modules/oset (Files): Likewise.
6611
6612 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
6613
6614         * lib/idcache.c: Include <stddef.h>, for offsetof.
6615         (struct userid.name): Change from char * to a flexible array member.
6616         All uses changed.
6617         * modules/idcache (Depends-on): Add flexmember.
6618
6619         * MODULES.html.sh (Core language properties): New module flexmember.
6620         * modules/flexmember, m4/flexmember.m4: New files.
6621
6622         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
6623         inline functions that are identical with the old xnmalloc_inline,
6624         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
6625         that we can avoid some unnecessary integer multiplications and
6626         divisions in the common case where the element size is known at
6627         compile time.
6628         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
6629         needed.
6630         (xnboundedmalloc): Remove.
6631         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
6632         arguments, for consistency with rest of this header.
6633         (xcharalloc): Rewrite using XNMALLOC.
6634         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
6635         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
6636         versions have been moved to lib/xalloc.h and renamed to be the
6637         non-*_inline versions.
6638         (xmalloc, xrealloc): Implement without reference to the xnmalloc
6639         and xnrealloc functions, since those functions are now inline and
6640         now call us.
6641         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
6642         renaming described above.
6643         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
6644         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
6645         captures the dependency in AC_C_INLINE.
6646
6647         New module canonicalize-lgpl, proposed by Charles Wilson in
6648         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
6649         with a few small changes afterwards.
6650         * MODULES.html.sh (File system functions): New module
6651         canonicalize-lgpl.
6652         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
6653         and canonicalize_file_name.
6654         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
6655         * modules/canonicalize-lgpl: New files.
6656
6657 2006-11-05  Bruno Haible  <bruno@clisp.org>
6658
6659         * gnulib-tool (func_import, func_create_testdir): Create directories
6660         also for files in subdirectories of lib/.
6661
6662 2006-11-05  Bruno Haible  <bruno@clisp.org>
6663
6664         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
6665         ANSI C compliant.
6666
6667 2006-11-03  Bruno Haible  <bruno@clisp.org>
6668
6669         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
6670         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
6671         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
6672         (xnboundedmalloc): New inline function.
6673         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
6674         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
6675         xmalloc.
6676         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
6677         xmalloc.
6678         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
6679         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
6680         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
6681         xmalloc.
6682         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
6683         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
6684         xmalloc.
6685         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
6686         gl_tree_add_after): Use XMALLOC instead of xmalloc.
6687         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
6688         xmalloc.
6689         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
6690         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
6691         gl_tree_add_after): Use XMALLOC instead of xmalloc.
6692         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
6693         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
6694         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
6695         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
6696
6697 2006-11-03  Bruno Haible  <bruno@clisp.org>
6698
6699         * lib/c-ctype.h [C++]: Define functions without name mangling.
6700         * lib/fwriteerror.h [C++]: Likewise.
6701         * lib/gcd.h [C++]: Likewise.
6702         * lib/linebreak.h [C++]: Likewise.
6703
6704 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
6705
6706         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
6707         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
6708         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
6709         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
6710         Check for functions and headers just once.
6711         Check for declaration of canonicalize_file_name.
6712         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
6713
6714 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6715
6716         * gnulib-tool (func_import): Fix typo in actioncmd.
6717
6718 2006-11-02  Bruno Haible  <bruno@clisp.org>
6719
6720         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
6721         newline sequence in the Makefile.am snippet as a space, like "make"
6722         does.
6723         Reported by Roger Persson <perrog@gmail.com>.
6724
6725 2006-11-01  Bruno Haible  <bruno@clisp.org>
6726
6727         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
6728         already declared in <string.h>.
6729         * lib/strcase.h (strncasecmp): Don't declare it if yes.
6730
6731 2006-11-01  Bruno Haible  <bruno@clisp.org>
6732
6733         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
6734         * lib/strcase.h: Include <string.h>.
6735         (strcasecmp): Define to rpl_strcasecmp here.
6736
6737 2006-11-01  Bruno Haible  <bruno@clisp.org>
6738
6739         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
6740
6741 2006-11-01  Eric Blake  <ebb9@byu.net>
6742
6743         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
6744
6745         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
6746
6747 2006-10-29  Bruno Haible  <bruno@clisp.org>
6748
6749         Make it compile in C++ mode.
6750         * lib/full-write.c (full_rw): Add a cast.
6751
6752 2006-11-01  Bruno Haible  <bruno@clisp.org>
6753
6754         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
6755         be POSIX compliant.
6756         Reported by Roger Persson <perrog@gmail.com>.
6757
6758 2006-11-01  Eric Blake  <ebb9@byu.net>
6759
6760         * lib/getopt_.h: Fix comments.
6761
6762 2006-10-31  Eric Blake  <ebb9@byu.net>
6763
6764         * modules/tmpdir (Depends-on): Add sys_stat.
6765         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
6766         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
6767         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
6768         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
6769         tempname.
6770
6771 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
6772
6773         Avoid some C++ diagnostics reported by Bruno Haible.
6774         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
6775         xmalloc.
6776         (quotearg_alloc): Use xcharalloc rather than xmalloc.
6777         (struct slotvec): Move to top level.
6778         (quotearg_n_options): Rewrite to avoid xmalloc.
6779         * lib/xalloc.h (xcharalloc): New function.
6780         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
6781         [defined __cplusplus]: Add function template that provides result
6782         type propagation.  This part of the change is from Bruno Haible.
6783
6784 2006-10-29  Bruno Haible  <bruno@clisp.org>
6785
6786         Make it compile in C++ mode.
6787         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
6788         * lib/strnlen1.c (strnlen1): Cast memchr result.
6789         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
6790         * lib/clean-temp.c (string_equals, string_hash): Add casts.
6791         (create_temp_dir): Rename local variable 'template'.
6792         (compile_csharp_using_sscli): Add cast.
6793         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
6794         * lib/findprog.c (find_in_path): Likewise.
6795         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
6796         * lib/wait-process.c (register_slave_subprocess): Likewise.
6797
6798 2006-10-22  Bruno Haible  <bruno@clisp.org>
6799
6800         * modules/tsearch: New file.
6801         * lib/tsearch.h: New file.
6802         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
6803         * m4/tsearch.m4: New file.
6804         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
6805
6806 2006-10-29  Eric Blake  <ebb9@byu.net>
6807
6808         * lib/arcfour.c: Assume config.h.
6809         * lib/arctwo.c: Likewise.
6810         * lib/base64.c: Likewise.
6811         * lib/check-version.c: Likewise.
6812         * lib/crc.c: Likewise.
6813         * lib/des.c: Likewise.
6814         * lib/gc-gnulib.c: Likewise.
6815         * lib/gc-libgcrypt.c: Likewise.
6816         * lib/gc-pbkdf2-sha1.c: Likewise.
6817         * lib/getaddrinfo.c: Likewise.
6818         * lib/getdelim.c: Likewise.
6819         * lib/getline.c: Likewise.
6820         * lib/hmac-md5.c: Likewise.
6821         * lib/hmac-sha1.c: Likewise.
6822         * lib/iconvme.c: Likewise.
6823         * lib/md2.c: Likewise.
6824         * lib/md4.c: Likewise.
6825         * lib/memxor.c: Likewise.
6826         * lib/read-file.c: Likewise.
6827         * lib/readline.c: Likewise.
6828         * lib/rijndael-alg-fst.c: Likewise.
6829         * lib/rijndael-api-fst.c: Likewise.
6830         * lib/xgetdomainname.c: Likewise.
6831
6832 2006-10-28  Eric Blake  <ebb9@byu.net>
6833
6834         * lib/xstrndup.c: Assume config.h.
6835
6836 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
6837
6838         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
6839         stat-macros.h is now for our own macros, whereas stat_h is for
6840         macros in the <sys/stat.h> name space.
6841         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
6842         (STAT_MACROS_H): Remove.
6843         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
6844         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
6845         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
6846         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
6847         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
6848         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
6849         Move these macros to ...
6850         * lib/stat_.h: here.  Don't include stat-macros.h.
6851         * lib/canonicalize.c: Don't include stat-macros.h.
6852         * lib/chown.c: Likewise.
6853         * lib/euidaccess.c: Likewise.
6854         * lib/file-type.c: Likewise.
6855         * lib/filemode.c: Likewise.
6856         * lib/glob.c: Likewise.
6857         * lib/isapipe.c: Likewise.
6858         * lib/lchown.c: Likewise.
6859         * lib/lstat.c: Likewise.
6860         * lib/mkdir-p.c: Likewise.
6861         * lib/rmdir.c: Likewise.
6862         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
6863         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
6864         unless mkdir isn't declared, to speed up 'configure'.
6865         Always create sys/stat.h, since it's unlikely any real sys/stat.h
6866         would define all the S_* symbols.
6867         * modules/canonicalize (Depends-on):
6868         Depend on sys_stat, not stat-macros.
6869         * modules/chown: Likewise.
6870         * modules/euidaccess: Likewise.
6871         * modules/filemode: Likewise.
6872         * modules/file-type: Likewise.
6873         * modules/glob: Likewise.
6874         * modules/isapipe: Likewise.
6875         * modules/lchown: Likewise.
6876         * modules/lstat: Likewise.
6877         * modules/mkancesdirs: Likewise.
6878         * modules/rmdir: Likewise.
6879         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
6880         * modules/modechange: Likewise.
6881         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
6882         (configure.ac): Remove gl_STAT_MACROS.
6883         * modules/sys_stat (Depends-on): Remove stat-macros.
6884
6885 2006-10-27  Bruno Haible  <bruno@clisp.org>
6886
6887         * m4/signed.m4: Remove file.
6888         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
6889         invocation.
6890         * modules/vasnprintf (Files): Remove m4/signed.m4.
6891
6892 2006-10-27  Bruno Haible  <bruno@clisp.org>
6893
6894         Update to GNU gettext 0.16.
6895         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
6896         m4/inttypes-h.m4, m4/signed.m4.
6897         * m4/gettext.m4: Update to GNU gettext 0.16.
6898         * m4/intl.m4: New file, from GNU gettext.
6899         * m4/intldir.m4: New file, from GNU gettext.
6900         * config/srclist.txt: Update
6901
6902 2006-10-27  Eric Blake  <ebb9@byu.net>
6903
6904         * MODULES.html.sh: Document tempname.
6905         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
6906         dependencies.
6907         (Files): Move lib/tempname.c...
6908         * modules/tempname: ...to this new module.
6909         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
6910         (gl_PREREQ_TEMPNAME): Move...
6911         * m4/tempname.m4: ...to this new file.
6912         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
6913         * modules/sys_stat (Depends-on): Add stat-macros.
6914         * lib/stat_.h (includes): Pick up stat macros.
6915         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
6916         if stat macros are broken.
6917         * lib/tempname.c (includes): No need to include "stat-macros.h".
6918         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
6919         (direxists, __path_search) [!_LIBC]: Don't compile these in
6920         gnulib; the tmpdir module covers that.
6921         * lib/tempname.h: New file.
6922
6923 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
6924
6925         * COPYING: Explain how gnulib-tool converts licence headers.
6926         Almost all wording by Eric Blake.
6927
6928 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
6929
6930         * lib/mbchar.h (is_basic_table): Make read-only.
6931         * lib/mbchar.c (is_basic_table): Likewise.
6932         Reported by John Darrington.
6933
6934 2006-10-25  Bruno Haible  <bruno@clisp.org>
6935
6936         * lib/progname.h (set_program_name): Undefine before defining.
6937
6938 2006-10-25  Bruno Haible  <bruno@clisp.org>
6939
6940         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
6941         false for non-gcc C++ compilers.
6942         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
6943
6944 2006-10-24  Bruno Haible  <bruno@clisp.org>
6945
6946         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
6947         iconv implementations like Irix iconv.
6948
6949 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6950
6951         * modules/vararrays: New file.
6952         * m4/vararrays.m4: New file, taken from diffutils.
6953         * MODULES.html.sh: New module vararrays.
6954
6955 2006-10-24  Karl Berry  <karl@gnu.org>
6956
6957         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
6958         Don't call GNU Unix.
6959
6960 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6961
6962         * users.txt: Add Libtool.
6963
6964         Sync from Libtool:
6965
6966         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6967
6968         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
6969         to gnulib's policy of including config.h unconditionally.
6970
6971 2006-10-24  Bruno Haible  <bruno@clisp.org>
6972
6973         * modules/wcwidth (Files): Add m4/wint_t.m4.
6974         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
6975         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
6976
6977 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6978
6979         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
6980         to pacify GCC with some -W flags enabled.  Problem reported by
6981         Bruno Haible.
6982
6983 2006-10-24  Jim Meyering  <jim@meyering.net>
6984
6985         * MODULES.html.sh: Remove uinttostr.  It's not a module.
6986         Reported by Karl Berry.
6987
6988 2006-10-23  Bruno Haible  <bruno@clisp.org>
6989
6990         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
6991
6992 2006-10-24  Bruno Haible  <bruno@clisp.org>
6993
6994         * lib/gl_list.h: Use C comment style, not C++ comment style.
6995
6996 2006-10-23  Eric Blake  <ebb9@byu.net>
6997
6998         * lib/getaddrinfo.c (includes): Add missing include.
6999
7000 2006-10-23  Bruno Haible  <bruno@clisp.org>
7001             Paul Eggert  <eggert@cs.ucla.edu>
7002
7003         Ability to rename obstack_free.
7004         * lib/obstack.h (__obstack_free): New macro. Declare instead of
7005         obstack_free.
7006         (obstack_free): Invoke the __obstack_free macro.
7007         * lib/obstack.c (obstack_free): Use __obstack_free macro.
7008
7009 2006-10-23  Bruno Haible  <bruno@clisp.org>
7010             Paul Eggert  <eggert@cs.ucla.edu>
7011
7012         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
7013         __argc, __argv from the declaration. (They are defined as macros on
7014         mingw.)
7015
7016 2006-10-22  Bruno Haible  <bruno@clisp.org>
7017
7018         * doc/gnulib-intro.texi: New file.
7019         * doc/gnulib.texi: Include it.
7020
7021 2006-10-21  Bruno Haible  <bruno@clisp.org>
7022
7023         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
7024         "Introduction", "Miscellanous Notes", "Particular Modules".
7025
7026 2006-10-21  Bruno Haible  <bruno@clisp.org>
7027
7028         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7029         Change mostlyclean-local rule to avoid sh syntax error from bash
7030         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
7031
7032 2006-10-23  Jim Meyering  <jim@meyering.net>
7033
7034         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
7035         in place of snprintf.
7036
7037         * modules/inttostr (Files): Add lib/uinttostr.c.
7038         * lib/uinttostr.c (inttostr): New file/function.
7039         * lib/inttostr.h (uinttostr): Declare.
7040         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
7041         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7042         Add uinttostr.
7043         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
7044
7045 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
7046
7047         * lib/canonicalize.c (ELOOP): Define if not already defined.
7048         Problem reported by Bruno Haible in
7049         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
7050
7051 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
7052
7053         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
7054         Problem reported by Perry Smith and Ville Laurikari.
7055
7056         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
7057         uses.
7058
7059 2006-10-19  Bruno Haible  <bruno@clisp.org>
7060
7061         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
7062         for mingw.
7063
7064 2006-10-19  Bruno Haible  <bruno@clisp.org>
7065
7066         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
7067         Needed for mingw.
7068
7069 2006-10-19  Bruno Haible  <bruno@clisp.org>
7070
7071         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
7072
7073 2006-10-19  Bruno Haible  <bruno@clisp.org>
7074
7075         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
7076         it.
7077
7078 2006-10-19  Bruno Haible  <bruno@clisp.org>
7079
7080         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
7081         invocation.
7082
7083 2006-10-19  Bruno Haible  <bruno@clisp.org>
7084
7085         * gnulib-tool (func_create_testdir): Don't include ftruncate and
7086         mountlist by default.
7087
7088 2006-10-16  Bruno Haible  <bruno@clisp.org>
7089
7090         * lib/c-strstr.c: Include c-strstr.h.
7091
7092 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
7093
7094         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
7095         in a slash.
7096
7097 2006-10-18  Bruno Haible  <bruno@clisp.org>
7098
7099         * lib/lock.h [C++]: Wrap definitions in extern "C".
7100
7101 2006-10-18  Bruno Haible  <bruno@clisp.org>
7102
7103         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
7104         gl_LIBOBJS list.
7105
7106 2006-10-18  Bruno Haible  <bruno@clisp.org>
7107
7108         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
7109
7110 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
7111
7112         * lib/xstrtol.h: Include gettext.h.
7113         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
7114         Problem reported by Eric Blake.
7115         * modules/xstrtol (Depends-on): Add gettext-h.
7116
7117 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
7118
7119         * lib/strftime.c (advance): New macro.
7120         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
7121         incomplete type, so you can't add 0 to it.  Problem and patch
7122         reported by Eelco Dolstra for dietlibc.
7123
7124 2006-10-18  Jim Meyering  <jim@meyering.net>
7125
7126         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
7127         type for a local, and rename it: s/up/user_proc/.
7128
7129 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
7130
7131         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
7132         READ_UTMP_USER_PROCESS.
7133         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
7134
7135 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
7136
7137         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
7138         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
7139
7140 2006-10-17  Eric Blake  <ebb9@byu.net>
7141
7142         * lib/sigprocmask.c (sigprocmask): Fix typo.
7143
7144         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
7145
7146         * modules/clean-temp (Makefile.am): Don't add to make output...
7147         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
7148         config.h.
7149
7150 2006-10-17  Bruno Haible  <bruno@clisp.org>
7151
7152         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
7153         differently if DEFAULT_TEXT_DOMAIN is set.
7154
7155 2006-10-16  Bruno Haible  <bruno@clisp.org>
7156
7157         * lib/clean-temp.c: Include fwriteerror.h.
7158
7159 2006-10-16  Bruno Haible  <bruno@clisp.org>
7160
7161         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
7162
7163 2006-10-16  Bruno Haible  <bruno@clisp.org>
7164
7165         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
7166         * lib/sigprocmask.h: Include <sys/types.h>.
7167         (sigset_t): Use the system's definition if present.
7168
7169 2006-10-17  Eric Blake  <ebb9@byu.net>
7170
7171         * lib/xvasprintf.c (includes): Assume config.h.
7172         * lib/xasprintf.c (includes): Likewise.
7173
7174 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
7175
7176         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
7177         at least as wide as intmax_t.
7178
7179 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
7180
7181         (Imported from Automake.)
7182         * build-aux/gnupload: Update to version 1.1 of directive file.
7183
7184 2006-10-16  Eric Blake  <ebb9@byu.net>
7185
7186         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
7187         match Automake 1.10a.
7188
7189 2006-10-14  Bruno Haible  <bruno@clisp.org>
7190
7191         * modules/sigprocmask: New file.
7192         * lib/sigprocmask.h: New file.
7193         * lib/sigprocmask.c: New file.
7194         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
7195         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
7196         request sigprocmask.o.
7197         (gl_PREREQ_SIGPROCMASK): New macro.
7198         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
7199         (Depends-on): Add sigprocmask.
7200         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
7201         gt_SIGNALBLOCKING. Test for 'raise' only once.
7202         * lib/fatal-signal.c: Include sigprocmask.h.
7203         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
7204         unblock_fatal_signals): Define always.
7205         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
7206         sigprocmask.
7207
7208 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
7209
7210         Sync from Automake.
7211         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
7212         which incorrectly sets the mode of an existing destination
7213         directory.  In some cases the unpatched install-sh could do the
7214         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
7215         system.  We hope this is rare in practice, but it's clearly worth
7216         fixing.  Problem reported by Alex Unleashed in
7217         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
7218         Also, don't bother to check for -m bugs unless we're using -m;
7219         suggested by Stepan Kasal.
7220
7221 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7222
7223         Sync from Automake.
7224         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
7225         `-c' flag, so they appear at the same position as in %FASTDEP%
7226         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
7227         which ignores unknown options only after the first non-option.
7228         Bug report against M4 by Nelson H. F. Beebe.
7229
7230 2006-10-13  Jim Meyering  <jim@meyering.net>
7231
7232         Fix a bug in yesterday's change.
7233         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
7234         p->fts_statp->st_dev would be used uninitialized.
7235         Ensures that we always call fts_stat on the very first entry.
7236         Miklos Szeredi reported that find -xdev stopped working.
7237
7238 2006-10-12  Bruno Haible  <bruno@clisp.org>
7239
7240         * gnulib-tool (func_get_automake_snippet): Append an automatically
7241         computed EXTRA_DIST augmentation.
7242         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
7243         * modules/alloca-opt (Makefile.am): Likewise.
7244         * modules/allocsa (Makefile.am): Likewise.
7245         * modules/arcfour (Makefile.am): Likewise.
7246         * modules/arctwo (Makefile.am): Likewise.
7247         * modules/argmatch (Makefile.am): Likewise.
7248         * modules/argz (Makefile.am): Likewise.
7249         * modules/atexit (Makefile.am): Likewise.
7250         * modules/backupfile (Makefile.am): Likewise.
7251         * modules/byteswap (Makefile.am): Likewise.
7252         * modules/c-strtod (Makefile.am): Likewise.
7253         * modules/c-strtold (Makefile.am): Likewise.
7254         * modules/calloc (Makefile.am): Likewise.
7255         * modules/canon-host (Makefile.am): Likewise.
7256         * modules/canonicalize (Makefile.am): Likewise.
7257         * modules/chdir-long (Makefile.am): Likewise.
7258         * modules/chdir-safer (Makefile.am): Likewise.
7259         * modules/check-version (Makefile.am): Likewise.
7260         * modules/chown (Makefile.am): Likewise.
7261         * modules/cloexec (Makefile.am): Likewise.
7262         * modules/close-stream (Makefile.am): Likewise.
7263         * modules/closeout (Makefile.am): Likewise.
7264         * modules/crc (Makefile.am): Likewise.
7265         * modules/csharpexec (Makefile.am): Likewise.
7266         * modules/cycle-check (Makefile.am): Likewise.
7267         * modules/des (Makefile.am): Likewise.
7268         * modules/dev-ino (Makefile.am): Likewise.
7269         * modules/dirfd (Makefile.am): Likewise.
7270         * modules/dirname (Makefile.am): Likewise.
7271         * modules/dup2 (Makefile.am): Likewise.
7272         * modules/eealloc (Makefile.am): Likewise.
7273         * modules/error (Makefile.am): Likewise.
7274         * modules/euidaccess (Makefile.am): Likewise.
7275         * modules/exclude (Makefile.am): Likewise.
7276         * modules/exitfail (Makefile.am): Likewise.
7277         * modules/fcntl-safer (Makefile.am): Likewise.
7278         * modules/fcntl (Makefile.am): Likewise.
7279         * modules/file-type (Makefile.am): Likewise.
7280         * modules/fileblocks (Makefile.am): Likewise.
7281         * modules/filemode (Makefile.am): Likewise.
7282         * modules/filenamecat (Makefile.am): Likewise.
7283         * modules/fnmatch (Makefile.am): Likewise.
7284         * modules/fopen-safer (Makefile.am): Likewise.
7285         * modules/fpending (Makefile.am): Likewise.
7286         * modules/fprintftime (Makefile.am): Likewise.
7287         * modules/free (Makefile.am): Likewise.
7288         * modules/fsusage (Makefile.am): Likewise.
7289         * modules/ftruncate (Makefile.am): Likewise.
7290         * modules/fts (Makefile.am): Likewise.
7291         * modules/gc-arcfour (Makefile.am): Likewise.
7292         * modules/gc-des (Makefile.am): Likewise.
7293         * modules/gc-hmac-md5 (Makefile.am): Likewise.
7294         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
7295         * modules/gc-md4 (Makefile.am): Likewise.
7296         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
7297         * modules/gc-sha1 (Makefile.am): Likewise.
7298         * modules/gc (Makefile.am): Likewise.
7299         * modules/getaddrinfo (Makefile.am): Likewise.
7300         * modules/getcwd (Makefile.am): Likewise.
7301         * modules/getdelim (Makefile.am): Likewise.
7302         * modules/getdomainname (Makefile.am): Likewise.
7303         * modules/getgroups (Makefile.am): Likewise.
7304         * modules/gethostname (Makefile.am): Likewise.
7305         * modules/gethrxtime (Makefile.am): Likewise.
7306         * modules/getline (Makefile.am): Likewise.
7307         * modules/getloadavg (Makefile.am): Likewise.
7308         * modules/getlogin_r (Makefile.am): Likewise.
7309         * modules/getndelim2 (Makefile.am): Likewise.
7310         * modules/getopt (Makefile.am): Likewise.
7311         * modules/getpagesize (Makefile.am): Likewise.
7312         * modules/getpass-gnu (Makefile.am): Likewise.
7313         * modules/getpass (Makefile.am): Likewise.
7314         * modules/getsubopt (Makefile.am): Likewise.
7315         * modules/gettime (Makefile.am): Likewise.
7316         * modules/gettimeofday (Makefile.am): Likewise.
7317         * modules/getugroups (Makefile.am): Likewise.
7318         * modules/getusershell (Makefile.am): Likewise.
7319         * modules/glob (Makefile.am): Likewise.
7320         * modules/group-member (Makefile.am): Likewise.
7321         * modules/hard-locale (Makefile.am): Likewise.
7322         * modules/hash (Makefile.am): Likewise.
7323         * modules/hmac-md5 (Makefile.am): Likewise.
7324         * modules/hmac-sha1 (Makefile.am): Likewise.
7325         * modules/human (Makefile.am): Likewise.
7326         * modules/idcache (Makefile.am): Likewise.
7327         * modules/imaxabs (Makefile.am): Likewise.
7328         * modules/imaxdiv (Makefile.am): Likewise.
7329         * modules/inet_ntop (Makefile.am): Likewise.
7330         * modules/inet_pton (Makefile.am): Likewise.
7331         * modules/intprops (Makefile.am): Likewise.
7332         * modules/inttostr (Makefile.am): Likewise.
7333         * modules/inttypes (Makefile.am): Likewise.
7334         * modules/isapipe (Makefile.am): Likewise.
7335         * modules/javaversion (Makefile.am): Likewise.
7336         * modules/lchmod (Makefile.am): Likewise.
7337         * modules/lchown (Makefile.am): Likewise.
7338         * modules/localcharset (Makefile.am): Likewise.
7339         * modules/long-options (Makefile.am): Likewise.
7340         * modules/lstat (Makefile.am): Likewise.
7341         * modules/malloc (Makefile.am): Likewise.
7342         * modules/mathl (Makefile.am): Likewise.
7343         * modules/mbchar (Makefile.am): Likewise.
7344         * modules/md2 (Makefile.am): Likewise.
7345         * modules/md4 (Makefile.am): Likewise.
7346         * modules/md5 (Makefile.am): Likewise.
7347         * modules/memcasecmp (Makefile.am): Likewise.
7348         * modules/memchr (Makefile.am): Likewise.
7349         * modules/memcmp (Makefile.am): Likewise.
7350         * modules/memcoll (Makefile.am): Likewise.
7351         * modules/memcpy (Makefile.am): Likewise.
7352         * modules/memmem (Makefile.am): Likewise.
7353         * modules/memmove (Makefile.am): Likewise.
7354         * modules/mempcpy (Makefile.am): Likewise.
7355         * modules/memrchr (Makefile.am): Likewise.
7356         * modules/memset (Makefile.am): Likewise.
7357         * modules/memxor (Makefile.am): Likewise.
7358         * modules/mkancesdirs (Makefile.am): Likewise.
7359         * modules/mkdir-p (Makefile.am): Likewise.
7360         * modules/mkdir (Makefile.am): Likewise.
7361         * modules/mkdtemp (Makefile.am): Likewise.
7362         * modules/mkstemp (Makefile.am): Likewise.
7363         * modules/mktime (Makefile.am): Likewise.
7364         * modules/modechange (Makefile.am): Likewise.
7365         * modules/mountlist (Makefile.am): Likewise.
7366         * modules/nanosleep (Makefile.am): Likewise.
7367         * modules/obstack (Makefile.am): Likewise.
7368         * modules/openat (Makefile.am): Likewise.
7369         * modules/pagealign_alloc (Makefile.am): Likewise.
7370         * modules/pathmax (Makefile.am): Likewise.
7371         * modules/physmem (Makefile.am): Likewise.
7372         * modules/poll (Makefile.am): Likewise.
7373         * modules/posixtm (Makefile.am): Likewise.
7374         * modules/posixver (Makefile.am): Likewise.
7375         * modules/putenv (Makefile.am): Likewise.
7376         * modules/quote (Makefile.am): Likewise.
7377         * modules/quotearg (Makefile.am): Likewise.
7378         * modules/raise (Makefile.am): Likewise.
7379         * modules/read-file (Makefile.am): Likewise.
7380         * modules/readline (Makefile.am): Likewise.
7381         * modules/readlink (Makefile.am): Likewise.
7382         * modules/readtokens (Makefile.am): Likewise.
7383         * modules/readutmp (Makefile.am): Likewise.
7384         * modules/realloc (Makefile.am): Likewise.
7385         * modules/regex (Makefile.am): Likewise.
7386         * modules/rename-dest-slash (Makefile.am): Likewise.
7387         * modules/rename (Makefile.am): Likewise.
7388         * modules/rijndael (Makefile.am): Likewise.
7389         * modules/rmdir (Makefile.am): Likewise.
7390         * modules/rpmatch (Makefile.am): Likewise.
7391         * modules/safe-read (Makefile.am): Likewise.
7392         * modules/safe-write (Makefile.am): Likewise.
7393         * modules/same-inode (Makefile.am): Likewise.
7394         * modules/same (Makefile.am): Likewise.
7395         * modules/save-cwd (Makefile.am): Likewise.
7396         * modules/savedir (Makefile.am): Likewise.
7397         * modules/setenv (Makefile.am): Likewise.
7398         * modules/settime (Makefile.am): Likewise.
7399         * modules/sha1 (Makefile.am): Likewise.
7400         * modules/sig2str (Makefile.am): Likewise.
7401         * modules/snprintf (Makefile.am): Likewise.
7402         * modules/stat-macros (Makefile.am): Likewise.
7403         * modules/stat-time (Makefile.am): Likewise.
7404         * modules/stdbool (Makefile.am): Likewise.
7405         * modules/stdint (Makefile.am): Likewise.
7406         * modules/stdlib-safer (Makefile.am): Likewise.
7407         * modules/stpcpy (Makefile.am): Likewise.
7408         * modules/stpncpy (Makefile.am): Likewise.
7409         * modules/strcase (Makefile.am): Likewise.
7410         * modules/strcasestr (Makefile.am): Likewise.
7411         * modules/strchrnul (Makefile.am): Likewise.
7412         * modules/strcspn (Makefile.am): Likewise.
7413         * modules/strdup (Makefile.am): Likewise.
7414         * modules/strerror (Makefile.am): Likewise.
7415         * modules/strftime (Makefile.am): Likewise.
7416         * modules/strndup (Makefile.am): Likewise.
7417         * modules/strnlen (Makefile.am): Likewise.
7418         * modules/strpbrk (Makefile.am): Likewise.
7419         * modules/strsep (Makefile.am): Likewise.
7420         * modules/strstr (Makefile.am): Likewise.
7421         * modules/strtod (Makefile.am): Likewise.
7422         * modules/strtoimax (Makefile.am): Likewise.
7423         * modules/strtok_r (Makefile.am): Likewise.
7424         * modules/strtol (Makefile.am): Likewise.
7425         * modules/strtoll (Makefile.am): Likewise.
7426         * modules/strtoul (Makefile.am): Likewise.
7427         * modules/strtoull (Makefile.am): Likewise.
7428         * modules/strtoumax (Makefile.am): Likewise.
7429         * modules/strverscmp (Makefile.am): Likewise.
7430         * modules/sys_socket (Makefile.am): Likewise.
7431         * modules/sys_stat (Makefile.am): Likewise.
7432         * modules/sysexits (Makefile.am): Likewise.
7433         * modules/time_r (Makefile.am): Likewise.
7434         * modules/timegm (Makefile.am): Likewise.
7435         * modules/timespec (Makefile.am): Likewise.
7436         * modules/tmpfile-safer (Makefile.am): Likewise.
7437         * modules/trim (Makefile.am): Likewise.
7438         * modules/unistd-safer (Makefile.am): Likewise.
7439         * modules/unlinkdir (Makefile.am): Likewise.
7440         * modules/unlocked-io (Makefile.am): Likewise.
7441         * modules/userspec (Makefile.am): Likewise.
7442         * modules/utime (Makefile.am): Likewise.
7443         * modules/utimecmp (Makefile.am): Likewise.
7444         * modules/utimens (Makefile.am): Likewise.
7445         * modules/vasnprintf (Makefile.am): Likewise.
7446         * modules/vasprintf (Makefile.am): Likewise.
7447         * modules/vsnprintf (Makefile.am): Likewise.
7448         * modules/xalloc (Makefile.am): Likewise.
7449         * modules/xgetcwd (Makefile.am): Likewise.
7450         * modules/xnanosleep (Makefile.am): Likewise.
7451         * modules/xreadlink (Makefile.am): Likewise.
7452         * modules/xstrtod (Makefile.am): Likewise.
7453         * modules/xstrtol (Makefile.am): Likewise.
7454         * modules/xstrtold (Makefile.am): Likewise.
7455         * modules/yesno (Makefile.am): Likewise.
7456         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
7457
7458 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
7459
7460         * modules/error (Makefile.am): Distribute files through
7461         EXTRA_DIST, not lib_SOURCES.
7462
7463 2006-10-12  Eric Blake  <ebb9@byu.net>
7464
7465         * modules/error (Makefile.am): Distribute files in /lib.
7466         * modules/obstack (Makefile.am): Likewise.
7467
7468 2006-10-12  Bruno Haible  <bruno@clisp.org>
7469
7470         * modules/acl (Makefile.am): Distribute all files in lib/ through
7471         EXTRA_DIST.
7472         * modules/arcfour (Makefile.am): Likewise.
7473         * modules/arctwo (Makefile.am): Likewise.
7474         * modules/argmatch (Makefile.am): Likewise.
7475         * modules/argz (Makefile.am): Likewise.
7476         * modules/atexit (Makefile.am): Likewise.
7477         * modules/backupfile (Makefile.am): Likewise.
7478         * modules/c-strtod (Makefile.am): Likewise.
7479         * modules/c-strtold (Makefile.am): Likewise.
7480         * modules/calloc (Makefile.am): Likewise.
7481         * modules/canon-host (Makefile.am): Likewise.
7482         * modules/canonicalize (Makefile.am): Likewise.
7483         * modules/chdir-long (Makefile.am): Likewise.
7484         * modules/chdir-safer (Makefile.am): Likewise.
7485         * modules/check-version (Makefile.am): Likewise.
7486         * modules/chown (Makefile.am): Likewise.
7487         * modules/cloexec (Makefile.am): Likewise.
7488         * modules/close-stream (Makefile.am): Likewise.
7489         * modules/closeout (Makefile.am): Likewise.
7490         * modules/crc (Makefile.am): Likewise.
7491         * modules/cycle-check (Makefile.am): Likewise.
7492         * modules/des (Makefile.am): Likewise.
7493         * modules/dirfd (Makefile.am): Likewise.
7494         * modules/dirname (Makefile.am): Likewise.
7495         * modules/dup2 (Makefile.am): Likewise.
7496         * modules/euidaccess (Makefile.am): Likewise.
7497         * modules/exclude (Makefile.am): Likewise.
7498         * modules/exitfail (Makefile.am): Likewise.
7499         * modules/fcntl-safer (Makefile.am): Likewise.
7500         * modules/file-type (Makefile.am): Likewise.
7501         * modules/fileblocks (Makefile.am): Likewise.
7502         * modules/filemode (Makefile.am): Likewise.
7503         * modules/filenamecat (Makefile.am): Likewise.
7504         * modules/fnmatch (Makefile.am): Likewise.
7505         * modules/fopen-safer (Makefile.am): Likewise.
7506         * modules/fpending (Makefile.am): Likewise.
7507         * modules/fprintftime (Makefile.am): Likewise.
7508         * modules/free (Makefile.am): Likewise.
7509         * modules/fsusage (Makefile.am): Likewise.
7510         * modules/ftruncate (Makefile.am): Likewise.
7511         * modules/fts (Makefile.am): Likewise.
7512         * modules/gc (Makefile.am): Likewise.
7513         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
7514         * modules/getaddrinfo (Makefile.am): Likewise.
7515         * modules/getcwd (Makefile.am): Likewise.
7516         * modules/getdelim (Makefile.am): Likewise.
7517         * modules/getdomainname (Makefile.am): Likewise.
7518         * modules/getgroups (Makefile.am): Likewise.
7519         * modules/gethostname (Makefile.am): Likewise.
7520         * modules/gethrxtime (Makefile.am): Likewise.
7521         * modules/getline (Makefile.am): Likewise.
7522         * modules/getloadavg (Makefile.am): Likewise.
7523         * modules/getlogin_r (Makefile.am): Likewise.
7524         * modules/getopt (Makefile.am): Likewise.
7525         * modules/getpass (Makefile.am): Likewise.
7526         * modules/getpass-gnu (Makefile.am): Likewise.
7527         * modules/getsubopt (Makefile.am): Likewise.
7528         * modules/gettime (Makefile.am): Likewise.
7529         * modules/gettimeofday (Makefile.am): Likewise.
7530         * modules/getugroups (Makefile.am): Likewise.
7531         * modules/getusershell (Makefile.am): Likewise.
7532         * modules/glob (Makefile.am): Likewise.
7533         * modules/group-member (Makefile.am): Likewise.
7534         * modules/hard-locale (Makefile.am): Likewise.
7535         * modules/hash (Makefile.am): Likewise.
7536         * modules/hmac-md5 (Makefile.am): Likewise.
7537         * modules/hmac-sha1 (Makefile.am): Likewise.
7538         * modules/human (Makefile.am): Likewise.
7539         * modules/idcache (Makefile.am): Likewise.
7540         * modules/imaxabs (Makefile.am): Likewise.
7541         * modules/imaxdiv (Makefile.am): Likewise.
7542         * modules/inet_ntop (Makefile.am): Likewise.
7543         * modules/inet_pton (Makefile.am): Likewise.
7544         * modules/inttostr (Makefile.am): Likewise.
7545         * modules/isapipe (Makefile.am): Likewise.
7546         * modules/lchown (Makefile.am): Likewise.
7547         * modules/long-options (Makefile.am): Likewise.
7548         * modules/lstat (Makefile.am): Likewise.
7549         * modules/malloc (Makefile.am): Likewise.
7550         * modules/mathl (Makefile.am): Likewise.
7551         * modules/mbchar (Makefile.am): Likewise.
7552         * modules/md2 (Makefile.am): Likewise.
7553         * modules/md4 (Makefile.am): Likewise.
7554         * modules/md5 (Makefile.am): Likewise.
7555         * modules/memcasecmp (Makefile.am): Likewise.
7556         * modules/memchr (Makefile.am): Likewise.
7557         * modules/memcmp (Makefile.am): Likewise.
7558         * modules/memcoll (Makefile.am): Likewise.
7559         * modules/memcpy (Makefile.am): Likewise.
7560         * modules/memmem (Makefile.am): Likewise.
7561         * modules/memmove (Makefile.am): Likewise.
7562         * modules/mempcpy (Makefile.am): Likewise.
7563         * modules/memrchr (Makefile.am): Likewise.
7564         * modules/memset (Makefile.am): Likewise.
7565         * modules/memxor (Makefile.am): Likewise.
7566         * modules/mkancesdirs (Makefile.am): Likewise.
7567         * modules/mkdir (Makefile.am): Likewise.
7568         * modules/mkdir-p (Makefile.am): Likewise.
7569         * modules/mkdtemp (Makefile.am): Likewise.
7570         * modules/mkstemp (Makefile.am): Likewise.
7571         * modules/mktime (Makefile.am): Likewise.
7572         * modules/modechange (Makefile.am): Likewise.
7573         * modules/mountlist (Makefile.am): Likewise.
7574         * modules/nanosleep (Makefile.am): Likewise.
7575         * modules/openat (Makefile.am): Likewise.
7576         * modules/pagealign_alloc (Makefile.am): Likewise.
7577         * modules/physmem (Makefile.am): Likewise.
7578         * modules/poll (Makefile.am): Likewise.
7579         * modules/posixtm (Makefile.am): Likewise.
7580         * modules/posixver (Makefile.am): Likewise.
7581         * modules/putenv (Makefile.am): Likewise.
7582         * modules/quote (Makefile.am): Likewise.
7583         * modules/quotearg (Makefile.am): Likewise.
7584         * modules/raise (Makefile.am): Likewise.
7585         * modules/read-file (Makefile.am): Likewise.
7586         * modules/readline (Makefile.am): Likewise.
7587         * modules/readlink (Makefile.am): Likewise.
7588         * modules/readtokens (Makefile.am): Likewise.
7589         * modules/readutmp (Makefile.am): Likewise.
7590         * modules/realloc (Makefile.am): Likewise.
7591         * modules/regex (Makefile.am): Likewise.
7592         * modules/rename (Makefile.am): Likewise.
7593         * modules/rename-dest-slash (Makefile.am): Likewise.
7594         * modules/rijndael (Makefile.am): Likewise.
7595         * modules/rmdir (Makefile.am): Likewise.
7596         * modules/rpmatch (Makefile.am): Likewise.
7597         * modules/safe-read (Makefile.am): Likewise.
7598         * modules/safe-write (Makefile.am): Likewise.
7599         * modules/same (Makefile.am): Likewise.
7600         * modules/save-cwd (Makefile.am): Likewise.
7601         * modules/savedir (Makefile.am): Likewise.
7602         * modules/setenv (Makefile.am): Likewise.
7603         * modules/settime (Makefile.am): Likewise.
7604         * modules/sha1 (Makefile.am): Likewise.
7605         * modules/sig2str (Makefile.am): Likewise.
7606         * modules/snprintf (Makefile.am): Likewise.
7607         * modules/stdlib-safer (Makefile.am): Likewise.
7608         * modules/stpcpy (Makefile.am): Likewise.
7609         * modules/stpncpy (Makefile.am): Likewise.
7610         * modules/strcase (Makefile.am): Likewise.
7611         * modules/strcasestr (Makefile.am): Likewise.
7612         * modules/strchrnul (Makefile.am): Likewise.
7613         * modules/strcspn (Makefile.am): Likewise.
7614         * modules/strdup (Makefile.am): Likewise.
7615         * modules/strerror (Makefile.am): Likewise.
7616         * modules/strftime (Makefile.am): Likewise.
7617         * modules/strndup (Makefile.am): Likewise.
7618         * modules/strnlen (Makefile.am): Likewise.
7619         * modules/strpbrk (Makefile.am): Likewise.
7620         * modules/strsep (Makefile.am): Likewise.
7621         * modules/strstr (Makefile.am): Likewise.
7622         * modules/strtod (Makefile.am): Likewise.
7623         * modules/strtoimax (Makefile.am): Likewise.
7624         * modules/strtok_r (Makefile.am): Likewise.
7625         * modules/strtol (Makefile.am): Likewise.
7626         * modules/strtoll (Makefile.am): Likewise.
7627         * modules/strtoul (Makefile.am): Likewise.
7628         * modules/strtoull (Makefile.am): Likewise.
7629         * modules/strtoumax (Makefile.am): Likewise.
7630         * modules/strverscmp (Makefile.am): Likewise.
7631         * modules/time_r (Makefile.am): Likewise.
7632         * modules/timegm (Makefile.am): Likewise.
7633         * modules/tmpfile-safer (Makefile.am): Likewise.
7634         * modules/unistd-safer (Makefile.am): Likewise.
7635         * modules/unlinkdir (Makefile.am): Likewise.
7636         * modules/userspec (Makefile.am): Likewise.
7637         * modules/utime (Makefile.am): Likewise.
7638         * modules/utimecmp (Makefile.am): Likewise.
7639         * modules/utimens (Makefile.am): Likewise.
7640         * modules/vasnprintf (Makefile.am): Likewise.
7641         * modules/vasprintf (Makefile.am): Likewise.
7642         * modules/vsnprintf (Makefile.am): Likewise.
7643         * modules/xalloc (Makefile.am): Likewise.
7644         * modules/xgetcwd (Makefile.am): Likewise.
7645         * modules/xnanosleep (Makefile.am): Likewise.
7646         * modules/xreadlink (Makefile.am): Likewise.
7647         * modules/xstrtod (Makefile.am): Likewise.
7648         * modules/xstrtol (Makefile.am): Likewise.
7649         * modules/xstrtold (Makefile.am): Likewise.
7650         * modules/yesno (Makefile.am): Likewise.
7651
7652 2006-10-12  Jim Meyering  <jim@meyering.net>
7653
7654         * m4/getloadavg.m4: Revert the change below.
7655
7656         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
7657         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
7658         fail with a symlink, which is what coreutils' ./bootstrap now
7659         creates by default.
7660
7661 2006-10-12  Bruno Haible  <bruno@clisp.org>
7662
7663         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
7664         mingw.
7665         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
7666         MSVC and mingw explicitly.
7667
7668 2006-10-11  Simon Josefsson  <jas@extundo.com>
7669             Bruno Haible  <bruno@clisp.org>
7670
7671         Add support for multiple gnulib-tool invocations in the scope of a
7672         single configure.ac file.
7673         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
7674         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
7675         with the same contents as the _LIBADD variable.
7676         (func_emit_initmacro_start, func_emit_initmacro_end,
7677         func_emit_initmacro_done): New functions.
7678         (func_import, func_create_testdir): Invoke them. Allow the identifiers
7679         gl_LIBOBJS and gl_LTLIBOBJS.
7680
7681 2006-10-11  Bruno Haible  <bruno@clisp.org>
7682
7683         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
7684         (func_create_testdir): Don't create po/Makefile.am, don't invoke
7685         autoreconf. Instead, invoke autopoint explicitly but move back the
7686         *.m4 files from gnulib.
7687
7688 2006-10-11  Bruno Haible  <bruno@clisp.org>
7689
7690         * gnulib-tool (func_usage): Make module names after --create-testdir
7691         optional.
7692         (func_create_testdir): If no module was specified, use nearly all
7693         modules.
7694
7695 2006-10-12  Jim Meyering  <jim@meyering.net>
7696
7697         Big performance improvement for fts-based tools that use FTS_NOSTAT.
7698         Avoid spurious inode-mismatch problems on non-POSIX file systems.
7699         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
7700         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
7701         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
7702         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
7703         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
7704         (fts_set_stat_required): New function.
7705         (fts_open): Defer the calls to fts_stat, if possible or requested.
7706         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
7707         into fts_stat itself.
7708         (fts_read): Perform any required (deferred) fts_stat call.
7709         (fts_build): Likewise, for the directory we're about to open and read.
7710         In the readdir loop, carefully decide whether each entry will require
7711         an eventual call to fts_stat, using dirent.d_type info if available.
7712         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
7713         a command line argument into this function.  Update all callers.
7714         Map a return value of FTS_DOT to FTS_D for a command line argument.
7715         * modules/fts (Depends-on): Add d-type.  Alphabetize.
7716         Thanks to Miklos Szeredi for his tenacity and for the initial
7717         bug report about "find" failing on a FUSE-based file system.
7718
7719         * lib/fts.c (fts_open): Use consistent indentation.
7720
7721 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
7722
7723         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
7724         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
7725         reported by Jim Meyering.  All uses of cache variables renamed
7726         to match Autoconf's.
7727         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
7728         the other one.
7729
7730         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
7731         Fix misspelling in diagnostic.
7732
7733 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
7734
7735         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
7736         defined.  Problem reported by Matthew Woehlke.
7737
7738         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
7739         Add support for Tandem NonStop R series.
7740         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
7741         Use new macro.
7742
7743         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
7744         (has_trailing_slash): Omit size arg; all callers changed.
7745         Omit 'inline', since it doesn't help performance and we'd
7746         need to configure it.
7747         Don't count //, ///, etc. as having a trailing slash.
7748         As a side effect, this removes a C99ism reported by Matthew Woehlke.
7749         (rpl_rename_dest_slash): On failure, use rename's errno rather
7750         than (in some cases) an incorrect or junk errno.
7751         Simplify code by removing need to compute length; this does
7752         cause it to make two passes instead of one over the file name,
7753         but it's worth it.
7754
7755         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
7756         change, since Autoconf's version may no longer be appropriate now
7757         that we are using CVS Autoconf's version.  Add support for Tandem.
7758
7759 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
7760             Bruno Haible  <bruno@clisp.org>
7761
7762         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
7763         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
7764         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
7765         gl_AC_TYPE_LONG_LONG.
7766
7767         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
7768         instead of HAVE_LONG_LONG.
7769         * lib/printf-args.c (printf_fetchargs): Likewise.
7770         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
7771         * lib/vasnprintf.c (VASNPRINTF): Likewise.
7772         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
7773         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
7774         gl_AC_TYPE_LONG_LONG.
7775
7776 2006-10-11  Bruno Haible  <bruno@clisp.org>
7777
7778         * m4/longlong.m4: Add comments.
7779         * m4/ulonglong.m4: Likewise.
7780
7781 2006-10-10  Bruno Haible  <bruno@clisp.org>
7782
7783         Make it possible to #define stpcpy, strdup to aliases.
7784         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
7785         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
7786
7787 2006-10-10  Bruno Haible  <bruno@clisp.org>
7788
7789         Make it possible to #define gcd to an alias.
7790         * lib/gcd.c: Include config.h.
7791
7792 2006-10-10  Bruno Haible  <bruno@clisp.org>
7793
7794         Make it possible to #define c_isascii to an alias.
7795         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
7796         defined. Undefine the macros before defining them, to avoid gcc
7797         warnings.
7798         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
7799         define NO_C_CTYPE_MACROS early.
7800
7801 2006-10-10  Bruno Haible  <bruno@clisp.org>
7802
7803         Make it possible to #define set_program_name to an alias.
7804         * lib/progname.c: Don't undefine set_program_name; instead, undefine
7805         ENABLE_RELOCATABLE early.
7806
7807 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
7808
7809         Port to Tandem NSK OSS, which has 64-bit signed int but at most
7810         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
7811         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
7812         More generally, don't assume that 64-bit signed int is available
7813         if unsigned int is, and vice versa.
7814         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
7815         unsigned symbols, not on their signed counterparts.
7816         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
7817         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
7818         (UINT64_C, UINTMAX_C):
7819         Likewise.
7820         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
7821         unsigned counterparts.
7822         (Have_long_long, Unsigned): New macros.
7823         (Int): Renamed from INT.
7824         (strtoimax): Use the new macros.
7825         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
7826         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
7827         * modules/inttypes (inttypes.h): Substitute
7828         HAVE_UNSIGNED_LONG_LONG_INT.
7829         * modules/stdint (stdint.h): Likewise.
7830         (Files): Add m4/ulonglong.m4.
7831
7832 2006-10-10  Bruno Haible  <bruno@clisp.org>
7833
7834         Fix a gcc -Wshadow warning.
7835         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
7836         to 'bucket'.
7837         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
7838         gl_linked_indexof_from_to): Likewise.
7839         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
7840         Likewise.
7841         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
7842         Likewise.
7843         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
7844         Reported by Eric Blake.
7845
7846 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
7847
7848         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
7849         for NetBSD.  Problem reported by Bruno Haible.
7850
7851 2006-10-09  Jim Meyering  <jim@meyering.net>
7852
7853         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
7854         Patch from Bruno Haible.
7855
7856 2006-10-09  Jim Meyering  <jim@meyering.net>
7857
7858         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
7859         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
7860         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
7861
7862 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7863
7864         Don't include <config.h> twice; this doesn't work in some cases,
7865         e.g., when config.h has "#define intmax_t long long int" and
7866         we include <config.h>, <inttypes.h>, <config.h> in that order.
7867         Problem reported by Matthew Woehlke in:
7868         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
7869         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
7870         * lib/fts-cycle.c: Don't include config.h.
7871         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
7872         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
7873         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
7874         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
7875         inttypes.h.
7876         * lib/xstrtoumax.c: Likewise.
7877         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
7878         __strtol and the like, so that this module is more like its siblings.
7879         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
7880         Remove; no longer needed now that we assume gnulib inttypes.h.
7881
7882 2006-10-08  Bruno Haible  <bruno@clisp.org>
7883
7884         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
7885         option.
7886
7887 2006-10-07  Jim Meyering  <jim@meyering.net>
7888
7889         * modules/inttypes (inttypes.h): Revert what seems to have been
7890         an inadvertent part of today's change: use "|", not "/" in the
7891         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
7892
7893 2006-10-07  Bruno Haible  <bruno@clisp.org>
7894
7895         * modules/sublist: New file.
7896
7897 2006-10-07  Bruno Haible  <bruno@clisp.org>
7898
7899         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
7900         * modules/argz (argz.h): Likewise.
7901         * modules/arpa_inet (arpa/inet.h): Likewise.
7902         * modules/byteswap (byteswap.h): Likewise.
7903         * modules/configmake (configmake.h): Likewise.
7904         * modules/fcntl (fcntl.h): Likewise.
7905         * modules/fnmatch (fnmatch.h): Likewise.
7906         * modules/getopt (getopt.h): Likewise.
7907         * modules/glob (glob.h): Likewise.
7908         * modules/inttypes (inttypes.h): Likewise.
7909         * modules/netinet_in (netinet/in.h): Likewise.
7910         * modules/poll (poll.h): Likewise.
7911         * modules/stdbool (stdbool.h): Likewise.
7912         * modules/stdint (stdint.h): Likewise.
7913         * modules/sys_select (sys/select.h): Likewise.
7914         * modules/sys_socket (sys/socket.h): Likewise.
7915         * modules/sys_stat (sys/stat.h): Likewise.
7916         * modules/sysexits (sysexits.h): Likewise.
7917         * modules/unistd (unistd.h): Likewise.
7918         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7919         Add a "DO NOT EDIT" comment to the generated file.
7920         (func_import): Likewise for gnulib-comp.m4.
7921
7922 2006-10-07  Bruno Haible  <bruno@clisp.org>
7923
7924         * lib/gl_sublist.h: New file.
7925         * lib/gl_sublist.c: New file.
7926
7927 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
7928
7929         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
7930         name (relative to the original working directory) and the file
7931         name component (relative to the temporary working directory).  All
7932         callers changed.
7933         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
7934         * lib/mkdir-p.c (make_dir_parents): Likewise.
7935         * lib/mkdir-p.h (make_dir_parents): Likewise.
7936
7937 2006-10-06  Eric Blake  <ebb9@byu.net>
7938
7939         Define several macros for use by the clean-temp module.
7940         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
7941         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
7942         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
7943
7944         * lib/clean-temp.h (close_stream_temp): New declaration.
7945         * lib/clean-temp.c (includes): Pull in headers according to what
7946         other modules are in use.
7947         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
7948
7949 2006-10-06  Bruno Haible  <bruno@clisp.org>
7950
7951         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
7952         instead of fopen, fwriteerror.
7953
7954 2006-10-06  Bruno Haible  <bruno@clisp.org>
7955
7956         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
7957         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
7958         int.
7959         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
7960         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
7961         Return an error indicator.
7962         Suggested by Eric Blake.
7963
7964 2006-10-06  Bruno Haible  <bruno@clisp.org>
7965
7966         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
7967         Reported by Eric Blake.
7968
7969 2006-10-06  Bruno Haible  <bruno@clisp.org>
7970
7971         * modules/closeout (Description): Mention stderr too.
7972
7973 2006-10-06  Bruno Haible  <bruno@clisp.org>
7974         and Paul Eggert  <eggert@cs.ucla.edu>
7975
7976         * lib/closeout.c (close_stdout): Also close stderr.
7977         * lib/closeout.h: Update comment.
7978
7979 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
7980
7981         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
7982         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
7983         * lib/dirchownmod.c: Include lchown.h.
7984         * lib/lchown.c: Don't include files that lchown.h now includes.
7985         Don't declare chown, since lchown.h now does that.
7986         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
7987         (lchown): Define to rpl_chown if lchown is declared but
7988         does not exist.  Declare using a prototype if lchown is not
7989         declared.  Add a copyright notice.
7990         * lib/mkstemp.h: Include <unistd.h>.
7991         * lib/openat.c: Include lchown.h.
7992
7993         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
7994         we now test for that separately.
7995         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
7996         rather than O_NOFOLLOW, when testing whether it's possible to
7997         avoid a race condition reliably.
7998         * lib/savewd.c (savewd_chdir): Likewise.
7999
8000         Remove macros that are no longer needed now that stdint.h is
8001         reliable.
8002         * lib/fsusage.c (UINTMAX_MAX): Remove.
8003         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
8004         * lib/utimecmp.c (SIZE_MAX): Remove.
8005
8006         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
8007
8008         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
8009         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
8010         O_NOATIME works.
8011
8012 2006-10-05  Bruno Haible  <bruno@clisp.org>
8013
8014         * lib/gl_list.h (gl_sortedlist_search_from_to,
8015         gl_sortedlist_indexof_from_to): New declarations.
8016         (gl_list_implementation): New fields sortedlist_search_from_to,
8017         sortedlist_indexof_from_to.
8018         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
8019         inline functions.
8020         * lib/gl_list.c (gl_sortedlist_search_from_to,
8021         gl_sortedlist_indexof_from_to): New functions.
8022         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
8023         function.
8024         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
8025         (gl_array_sortedlist_search_from_to): New function.
8026         (gl_array_list_implementation): Update.
8027         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
8028         function.
8029         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
8030         (gl_carray_sortedlist_search_from_to): New function.
8031         (gl_carray_list_implementation): Update.
8032         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
8033         gl_linked_sortedlist_indexof_from_to): New functions.
8034         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
8035         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
8036         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
8037         gl_tree_sortedlist_indexof_from_to): New functions.
8038         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
8039         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
8040         Update.
8041         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
8042         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
8043         Update.
8044
8045 2006-10-05  Bruno Haible  <bruno@clisp.org>
8046
8047         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
8048         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
8049         (struct gl_list_implementation): Add fields search_from_to,
8050         indexof_from_to. Remove fields search, indexof.
8051         (gl_list_search): Use the search_from_to method.
8052         (gl_list_search_from, gl_list_search_from_to): New functions.
8053         (gl_list_indexof): Use the indexof_from_to method.
8054         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
8055         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
8056         (gl_list_search_from, gl_list_search_from_to): New functions.
8057         (gl_list_indexof): Use the indexof_from_to method.
8058         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
8059         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
8060         gl_array_indexof. Add start_index, end_index arguments.
8061         (gl_array_search_from_to): Renamed from gl_array_search. Add
8062         start_index, end_index arguments.
8063         (gl_array_remove, gl_array_list_implementation): Update.
8064         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
8065         gl_carray_indexof. Add start_index, end_index arguments.
8066         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
8067         start_index, end_index arguments.
8068         (gl_carray_remove, gl_carray_list_implementation): Update.
8069         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
8070         gl_linked_search. Add start_index, end_index arguments.
8071         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
8072         start_index, end_index arguments.
8073         (gl_linked_remove): Update.
8074         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
8075         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
8076         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
8077         field to 'size_t'.
8078         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
8079         gl_tree_search. Add start_index, end_index arguments.
8080         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
8081         start_index, end_index arguments.
8082         (gl_tree_remove): Update.
8083         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
8084         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
8085         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
8086         function.
8087         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
8088         gl_tree_search. Add start_index, end_index arguments.
8089         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
8090         start_index, end_index arguments.
8091         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
8092         Update.
8093         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
8094
8095 2006-10-05  Bruno Haible  <bruno@clisp.org>
8096
8097         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
8098
8099         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
8100         fwriteerror_temp): New declarations.
8101         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
8102         (descriptors): New variable.
8103         (cleanup): First, close the descriptors.
8104         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
8105         fclose_temp, fwriteerror_temp): New functions.
8106
8107 2006-10-04  Jim Meyering  <jim@meyering.net>
8108
8109         * lib/fts.c (fts_open): Tiny comment change.
8110
8111 2006-10-04  Bruno Haible  <bruno@clisp.org>
8112
8113         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
8114         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
8115         gl_LOCK_BODY.
8116         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
8117         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
8118         gl_LOCK_EARLY_BODY.
8119         (gl_LOCK): Require gl_LOCK_BODY.
8120
8121 2006-10-04  Bruno Haible  <bruno@clisp.org>
8122
8123         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
8124         (gl_oset_search_atleast): New declaration.
8125         (struct gl_oset_implementation): Add field 'search_atleast'.
8126         (gl_oset_search_atleast): New inline function.
8127         * lib/gl_oset.c (gl_oset_search_atleast): New function.
8128         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
8129         (gl_array_oset_implementation): Update.
8130         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
8131         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
8132         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
8133
8134 2006-10-04  Bruno Haible  <bruno@clisp.org>
8135
8136         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
8137
8138 2006-10-03  Bruno Haible  <bruno@clisp.org>
8139
8140         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
8141         from gl_avltreehash_list_implementation.
8142
8143 2006-10-03  Bruno Haible  <bruno@clisp.org>
8144
8145         * lib/gl_oset.c (gl_oset_add): Fix return type.
8146
8147 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
8148
8149         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
8150
8151 2006-10-02  Eric Blake  <ebb9@byu.net>
8152
8153         * modules/strnlen (Depends-on): Add extensions.
8154
8155 2006-10-02  Eric Blake  <ebb9@byu.net>
8156
8157         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
8158         definition in 2.60+.
8159
8160 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
8161
8162         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
8163         checks.
8164
8165 2006-10-02  Bruno Haible  <bruno@clisp.org>
8166
8167         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
8168         to the AUTOMAKE_OPTIONS.
8169         Reported by Jim Meyering.
8170
8171 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
8172
8173         Work around bug in Solaris 10 /proc file system:
8174         /proc/self/fd/NNN/.. isn't the parent directory of
8175         the directory whose file descriptor is NNN.  This needs to
8176         be worked around at run time, not compile time, since a
8177         program might be built on Solaris 8, where things work, and
8178         run on Solaris 10.
8179         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
8180         to use the following interface instead:
8181         (OPENAT_BUFFER_SIZE): New macro.
8182         (openat_proc_name): New function.
8183         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
8184         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
8185         Likewise.
8186         * lib/openat-proc.c: New file.
8187         * modules/openat (Files): Add lib/openat-proc.c.
8188         (Depends-on): Add same-inode, stdbool.
8189         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
8190
8191 2006-09-29  Bruno Haible  <bruno@clisp.org>
8192
8193         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
8194         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
8195         argument. Set stdout_closed before testing for ferror, not after.
8196         (fwriteerror, fwriteerror_no_ebadf): New functions.
8197
8198 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8199
8200         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
8201
8202 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
8203
8204         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
8205         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
8206
8207 2006-09-28  Jim Meyering  <jim@meyering.net>
8208
8209         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
8210         Include <unistd.h>.
8211
8212 2006-09-28  Bruno Haible  <bruno@clisp.org>
8213
8214         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
8215         * modules/linkedhash-list (Depends-on): Likewise.
8216         * modules/rbtreehash-list (Depends-on): Likewise.
8217
8218 2006-09-28  Bruno Haible  <bruno@clisp.org>
8219
8220         * lib/strndup.h: Simplify the redefinition of strndup.
8221         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
8222         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
8223
8224 2006-09-28  Bruno Haible  <bruno@clisp.org>
8225
8226         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
8227         * lib/gl_linkedhash_list.c: Likewise.
8228         * lib/gl_rbtreehash_list.c: Likewise.
8229
8230 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
8231
8232         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
8233         getaddrinfo.
8234
8235         * lib/__fpending.h: Don't include <stdio_ext.h> unless
8236         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
8237         it causes <stdio_ext.h> to cause a compile-time error.
8238         Problem reported by Nelson H. F. Beebe.
8239         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
8240         of HAVE_DECL___PENDING.
8241
8242         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
8243         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
8244         declaration.
8245
8246 2006-09-27  Jim Meyering  <jim@meyering.net>
8247
8248         This file could end up with a definition for a function
8249         named __strndup, rather than rpl_strndup on a system with
8250         incomplete weak_alias support.
8251         * lib/strndup.c (strndup): Rename from __strndup.
8252         Remove #defines that used to map __strndup to strndup.
8253         Don't use K&R prototypes.
8254         Remove LIBC-related code, since this file is not sync'd with glibc.
8255         * lib/strndup.h: Revamp, accordingly.
8256         * m4/strndup.m4: Modernize.
8257
8258 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
8259
8260         * modules/savewd (Depends-on): Add 'raise'.
8261         * lib/savewd.c: Include <signal.h>, for 'raise'.
8262
8263 2006-09-26  Jim Meyering  <jim@meyering.net>
8264
8265         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
8266         when we detect Darwin 8.7.0's acl_get_file bug.
8267         Rearrange to perform the new (below) run-test while $LIBS
8268         contains any acl-related library.  Set USE_ACL at the end.
8269         (gl_ACL_GET_FILE): New function.
8270
8271 2006-09-26  Eric Blake  <ebb9@byu.net>
8272
8273         * lib/verror.c: Include <config.h> unconditionally.
8274
8275 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
8276
8277         * modules/clock-time (Maintainer): Add self.
8278         * modules/getlogin_r (Depends-on): Add extensions.
8279
8280 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8281
8282         * modules/clock-time: New module.
8283         * modules/nanosleep (Depends-on): Add clock-time.
8284         * modules/gethrxtime (Depends-on): Likewise.
8285         * modules/gettime (Depends-on): Likewise.
8286         * modules/settime (Depends-on): Likewise.
8287
8288         * modules/fts-lgpl: Depend on openat.
8289         * modules/mkancesdirs: Depend on savewd.
8290         * modules/mkdir-p: Likewise.
8291
8292 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8293
8294         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
8295
8296         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
8297         `gl_have_arbitrary_file_name_length_limit' to
8298         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
8299         actually works between configure runs.
8300
8301 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8302             Bruno Haible  <bruno@clisp.org>
8303
8304         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
8305
8306 2006-09-25  Jim Meyering  <jim@meyering.net>
8307
8308         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
8309         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
8310
8311 2006-09-25  Eric Blake  <ebb9@byu.net>
8312
8313         * gnulib-tool (func_import, func_create_testdir): Fix typos in
8314         exec's in 2006-09-18 patch when shuffling fds.
8315
8316 2006-09-25  Bruno Haible  <bruno@clisp.org>
8317
8318         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
8319         Reported by Jim Meyering.
8320
8321 2006-09-24  Jim Meyering  <jim@meyering.net>
8322
8323         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
8324         compare a pointer against a literal "0".  That caused failures with
8325         at least HP-UX's hpcc.
8326
8327 2006-09-22  Simon Josefsson  <jas@extundo.com>
8328
8329         * modules/gc-sha1:
8330         * modules/gc-md4:
8331         * modules/gc-hmac-sha1:
8332         * modules/gc-hmac-md5:
8333         * modules/gc-des:
8334         * modules/gc-arcfour: Distribute more files.
8335
8336 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8337
8338         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
8339         (gl_linked_iterator_from_to): Initialize struct completely.
8340         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
8341         (gl_tree_iterator_from_to): Likewise
8342         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
8343         * lib/gl_array_list.c [lint] (gl_array_iterator)
8344         (gl_array_iterator_from_to): Likewise.
8345         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
8346         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
8347         (gl_carray_iterator_from_to): Likewise.
8348
8349         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
8350         * lib/md4.c (md4_process_block): Remove unused variable.
8351         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
8352         parentheses for clarity.
8353
8354 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8355
8356         * modules/bison-i18n (Depends-on): Add gettext.
8357
8358 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8359
8360         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
8361         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
8362         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
8363         also add missing comma that caused broken test.
8364         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
8365         stdlib.h, for `abort'.
8366         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
8367         variables.
8368         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
8369         include unistd.h if present, for `rmdir'.
8370         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
8371         variables.
8372         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
8373         in the process include standard headers for prototypes.
8374         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
8375         gets declared on GNU/Linux.
8376         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
8377         unistd.h, for `rmdir'.
8378         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
8379
8380         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
8381         always true.
8382         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
8383
8384         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
8385
8386 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8387
8388         * gnulib-tool (func_version): Create output all at once.  This
8389         may help avoid triggering unnecessary SIGPIPEs, and at any
8390         rate it doesn't hurt.
8391
8392 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8393             Bruno Haible  <bruno@clisp.org>
8394
8395         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
8396         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8397         * m4/signed.m4 (bh_C_SIGNED): Likewise.
8398
8399         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
8400         (gl_FUNC_VASPRINTF): Invoke it.
8401
8402 2006-09-22  Bruno Haible  <bruno@clisp.org>
8403
8404         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
8405         getloadavg.c as first argument.
8406
8407 2006-09-22  Bruno Haible  <bruno@clisp.org>
8408
8409         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
8410         at the beginning of the gl_INIT macro.
8411         * modules/getloadavg (configure.ac): Pass $gl_source_base to
8412         gl_GETLOADAVG.
8413
8414 2006-09-22  Bruno Haible  <bruno@clisp.org>
8415
8416         * gnulib-tool (func_create_megatestdir): Don't include the config-h
8417         module.
8418         Suggested by Ralf Wildenhues.
8419
8420 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
8421
8422         Import this patch from libc:
8423
8424         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
8425
8426         * lib/regex_internal.c (re_string_reconstruct): Handle
8427         offset < pstr->valid_raw_len && pstr->offsets_needed case.
8428         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
8429         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
8430         re_string_context_at.
8431
8432         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
8433         now requires it.
8434         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
8435         gl_REGEX now does it for us.
8436         (gl_REGEX): Add test taken from
8437         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
8438
8439         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
8440         Check that large offsets work.  Modernize Autoconf usages.
8441         Prefer "yes" to mean a good thing rather than a bad.
8442         Don't put "#define mkstemp" in config.h, as this might interfere
8443         with standard system headers that "#define mkstemp mkstemp64".
8444
8445         * modules/mkstemp (Depends-on): Add extensions, so that
8446         mkstemp is visible on some platforms.
8447         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
8448         (Include): Change to "mkstemp.h" from <stdlib.h>.
8449         (Files): Add mkstemp.h.
8450
8451         * lib/mkstemp.h: New file, since some standard headers
8452         #define mkstemp.
8453         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
8454         Include "mkstemp.h".
8455         Make the _LIBC code resemble glibc original more,
8456         e.g., use K&R style.
8457         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
8458         (mkstemp): Remove, since mkstemp.h does this for us.
8459         * lib/stdlib--.h: Include mkstemp.h.
8460
8461         Import this patch from libc:
8462
8463         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
8464
8465         * lib/tempname.c (__gen_tempname): Change attempts_min
8466         into a macro.  Use preprocessor to decide how to initialize
8467         attempts [Coverity CID 67].
8468
8469 2006-09-20  Bruno Haible  <bruno@clisp.org>
8470
8471         * lib/mkdtemp.c: Import from libc.
8472         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
8473                 * sysdeps/posix/tempname.c (__gen_tempname): Change
8474                 attempts_min into a macro.  Use preprocessor to decide how to
8475                 initialize attempts [Coverity CID 67].
8476         2001-11-27  Paul Eggert  <eggert@twinsun.com>
8477                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
8478                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
8479
8480 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8481
8482         * gnulib-tool (func_exit): New function, to allow to pass the
8483         exit status portably through the trap.  Use everywhere.
8484         (--help, --version): Signal a write error.
8485         (trap): catch SIGPIPE, for write errors.
8486         Exit at the end of the trap, with the correct exit status.
8487
8488 2006-09-19  Karl Berry  <karl@gnu.org>
8489
8490         * doc/gnulib.texi: note about the license texinfo files.
8491
8492 2006-09-19  Eric Blake  <ebb9@byu.net>
8493
8494         * gnulib-tool: Avoid space-tab.
8495
8496 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
8497
8498         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
8499         that prevented coreutils 6.1 from building.  Problem reported
8500         by Petter Reinholdtsen.
8501
8502 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
8503
8504         * gnulib-tool (avoidlist): Fix typo that broke options like
8505         --avoid=lock that are used by coreutils bootstrap.
8506
8507 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
8508
8509         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
8510         more systematically.
8511
8512 2006-09-18  Jim Meyering  <jim@meyering.net>
8513
8514         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
8515
8516 2006-09-18  Bruno Haible  <bruno@clisp.org>
8517
8518         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
8519
8520 2006-09-18  Bruno Haible  <bruno@clisp.org>
8521
8522         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
8523         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
8524         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
8525         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
8526         * m4/gettext.m4: Require autoconf >= 2.52.
8527         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
8528         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
8529         of gl_cv_header_inttypes_h.
8530
8531 2006-09-18  Bruno Haible  <bruno@clisp.org>
8532
8533         * lib/javaversion.c: Include configmake.h.
8534
8535 2006-09-18  Bruno Haible  <bruno@clisp.org>
8536
8537         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
8538         avoid that the while loops be executed in a subshell.
8539
8540 2006-09-18  Bruno Haible  <bruno@clisp.org>
8541
8542         * MODULES.html.sh (func_module): Break long lines.
8543         Suggested by Bruce Korb <bkorb@gnu.org>.
8544
8545 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8546
8547         Speed up by a factor of 1.12.
8548         * gnulib-tool (nl): New variable.
8549         (func_import): Rewrite include directive extraction to only read each
8550         directive once.
8551
8552 2006-09-17  Bruno Haible  <bruno@clisp.org>
8553
8554         * modules/javaversion (Makefile.am): Remove DEFS setting.
8555         (Depends-on): Add configmake, for PKGDATADIR definition.
8556
8557 2006-09-17  Bruno Haible  <bruno@clisp.org>
8558
8559         * gnulib-tool (func_create_testdir): Rewrite all files at once.
8560
8561 2006-09-17  Bruno Haible  <bruno@clisp.org>
8562
8563         * gnulib-tool (func_append): New function, stolen from libtool.m4.
8564         (func_modules_transitive_closure, func_modules_add_dummy,
8565         func_modules_to_filelist, func_import, func_create_testdir,
8566         func_create_megatestdir, ...): Use it wherever possible.
8567         Suggested by Ralf Wildenhues.
8568
8569 2006-09-16  Karl Berry  <karl@gnu.org>
8570
8571         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
8572         to avoid sectioning errors.
8573         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
8574         [ifinfo]: blank line after @center-ed titles.
8575         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
8576         Spell FSF address consistently with others.
8577         (These changes approved by rms.)
8578
8579 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8580
8581         Speed up by a factor of 1.61.
8582         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
8583         already checked module names again.
8584
8585 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8586
8587         Speed up by a factor of 1.13.
8588         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
8589         for new_files, and the input to func_add_or_update.
8590
8591 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8592
8593         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
8594         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
8595
8596 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8597
8598         * modules/mkancesdirs (Depends-on): Add fcntl.
8599         * modules/savewd: New file.
8600         * MODULES.html.sh (File system functions): Add savewd.
8601
8602         * modules/configmake (Makefile.am): Add support for the
8603         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
8604
8605 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8606
8607         * m4/savewd.m4: New file.
8608
8609 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8610
8611         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
8612         (dirchownmod): New arg FD.  All callers changed.
8613         Use FD rather than opening the directory ourself, as opening is
8614         now the caller's responsibility.
8615         * lib/dirchownmod.h: Likewise.
8616         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
8617         hosts that require <sys/types.h> before <sys/stat.h>.  Include
8618         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
8619         (test_dir): Remove.
8620         (mkancesdirs): Return length of prefix of FILE that has already
8621         been made, or -2 if there is a child doing the work.  Redo
8622         algorithm so that it is O(N) rather than O(N**2).  Optimize away
8623         ".", and treat ".." specially since it might stray back into
8624         already-created areas.  Use a subprocess if necessary.  New arg
8625         WD; all users changed.  MAKE_DIR function should now return 1
8626         if it creates a directory that is not readable.  Return -2 if
8627         a child process is spun off.
8628         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
8629         Adjust signature to match code.
8630         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
8631         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
8632         all users changed.
8633         * lib/savewd.c, lib/savewd.h: New files.
8634
8635 2006-09-15  Jim Meyering  <jim@meyering.net>
8636
8637         * modules/rename-dest-slash: New module.
8638         * MODULES.html.sh (posix_compat): Add it here.
8639
8640         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
8641
8642 2006-09-15  Jim Meyering  <jim@meyering.net>
8643
8644         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
8645         file.
8646
8647         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
8648
8649 2006-09-15  Jim Meyering  <jim@meyering.net>
8650
8651         * lib/rename-dest-slash.c (has_trailing_slash): Use
8652         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
8653         (rpl_rename_dest_slash): Perform the cheaper trailing slash
8654         test before testing whether SRC is a directory.
8655         Suggestions from Bruno Haible.
8656
8657         Avoid a warning about an unused variable.
8658         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
8659         into the #ifdef block where it's used.
8660
8661         * lib/rename-dest-slash.c: New file.
8662
8663 2006-09-14  Bruno Haible  <bruno@clisp.org>
8664
8665         * lib/allocsa.c: Include <config.h> unconditionally.
8666         * lib/asnprintf.c: Likewise.
8667         * lib/asprintf.c: Likewise.
8668         * lib/c-strcasecmp.c: Likewise.
8669         * lib/c-strcasestr.c: Likewise.
8670         * lib/c-strncasecmp.c: Likewise.
8671         * lib/c-strstr.c: Likewise.
8672         * lib/classpath.c: Likewise.
8673         * lib/clean-temp.c: Likewise.
8674         * lib/concatpath.c: Likewise.
8675         * lib/copy-file.c: Likewise.
8676         * lib/csharpcomp.c: Likewise.
8677         * lib/csharpexec.c: Likewise.
8678         * lib/execute.c: Likewise.
8679         * lib/fatal-signal.c: Likewise.
8680         * lib/findprog.c: Likewise.
8681         * lib/fwriteerror.c: Likewise.
8682         * lib/gl_array_list.c: Likewise.
8683         * lib/gl_array_oset.c: Likewise.
8684         * lib/gl_avltree_list.c: Likewise.
8685         * lib/gl_avltree_oset.c: Likewise.
8686         * lib/gl_avltreehash_list.c: Likewise.
8687         * lib/gl_carray_list.c: Likewise.
8688         * lib/gl_linked_list.c: Likewise.
8689         * lib/gl_linkedhash_list.c: Likewise.
8690         * lib/gl_list.c: Likewise.
8691         * lib/gl_oset.c: Likewise.
8692         * lib/gl_rbtree_list.c: Likewise.
8693         * lib/gl_rbtree_oset.c: Likewise.
8694         * lib/gl_rbtreehash_list.c: Likewise.
8695         * lib/imaxabs.c: Likewise.
8696         * lib/imaxdiv.c: Likewise.
8697         * lib/javacomp.c: Likewise.
8698         * lib/javaexec.c: Likewise.
8699         * lib/javaversion.c: Likewise.
8700         * lib/linebreak.c: Likewise.
8701         * lib/localcharset.c: Likewise.
8702         * lib/lock.c: Likewise.
8703         * lib/mbchar.c: Likewise.
8704         * lib/mbswidth.c: Likewise.
8705         * lib/mkdtemp.c: Likewise.
8706         * lib/pipe.c: Likewise.
8707         * lib/printf-args.c: Likewise.
8708         * lib/printf-parse.c: Likewise.
8709         * lib/progname.c: Likewise.
8710         * lib/progreloc.c: Likewise.
8711         * lib/readlink.c: Likewise.
8712         * lib/sh-quote.c: Likewise.
8713         * lib/stpcpy.c: Likewise.
8714         * lib/stpncpy.c: Likewise.
8715         * lib/strcasecmp.c: Likewise.
8716         * lib/strcasestr.c: Likewise.
8717         * lib/strcspn.c: Likewise.
8718         * lib/striconv.c: Likewise.
8719         * lib/strncasecmp.c: Likewise.
8720         * lib/strnlen1.c: Likewise.
8721         * lib/strstr.c: Likewise.
8722         * lib/strtok_r.c: Likewise.
8723         * lib/tls.c: Likewise.
8724         * lib/tmpdir.c: Likewise.
8725         * lib/unicodeio.c: Likewise.
8726         * lib/unsetenv.c: Likewise.
8727         * lib/vasnprintf.c: Likewise.
8728         * lib/vasprintf.c: Likewise.
8729         * lib/wait-process.c: Likewise.
8730         * lib/xallocsa.c: Likewise.
8731         * lib/xsetenv.c: Likewise.
8732         * lib/xstriconv.c: Likewise.
8733
8734 2006-09-13  Simon Josefsson  <jas@extundo.com>
8735
8736         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
8737         that internally, suggested by Ralf Wildenhues
8738         <Ralf.Wildenhues@gmx.de>.
8739
8740 2006-09-13  Simon Josefsson  <jas@extundo.com>
8741
8742         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
8743         @LIBOBJS@.
8744         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8745
8746 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
8747
8748         * lib/_fpending.c: Include <config.h> unconditionally, since we no
8749         longer worry about uses that don't define HAVE_CONFIG_H.
8750         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
8751         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
8752         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
8753         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
8754         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
8755         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
8756         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
8757         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
8758         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
8759         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
8760         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
8761         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
8762         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
8763         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
8764         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
8765         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
8766         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
8767         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
8768         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
8769         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
8770         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
8771         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
8772         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
8773         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
8774         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
8775         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
8776         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
8777         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
8778         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
8779         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
8780         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
8781         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
8782         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
8783         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
8784         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
8785         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
8786         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
8787         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
8788         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
8789         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
8790         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
8791         Likewise.
8792
8793 2006-09-13  Eric Blake  <ebb9@byu.net>
8794
8795         * lib/getopt.c: Fix typo in last commit.
8796
8797 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
8798
8799         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
8800         dgettext.
8801
8802 2006-09-12  Jim Meyering  <jim@meyering.net>
8803
8804         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
8805         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
8806         Reported by Nelson H. F. Beebe.
8807
8808 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8809
8810         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
8811         program_invocation_name and program_invocation_short_name are
8812         initialized.
8813         * lib/argp-namefrob.h: Move declarations of program_invocation_name
8814         and program_invocation_short_name to argp.h, so they are visible
8815         to user programs.
8816         * lib/argp.h: Likewise
8817
8818 2006-09-10  Bruno Haible  <bruno@clisp.org>
8819
8820         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
8821         m4/inttypes_h.m4, m4/uintmax_t.m4.
8822
8823 2006-09-10  Bruno Haible  <bruno@clisp.org>
8824
8825         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
8826         gl_AC_TYPE_UINTMAX_T.
8827
8828 2006-09-10  Bruno Haible  <bruno@clisp.org>
8829
8830         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
8831
8832 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8833
8834         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
8835         convention.  Text proposed by Bruno Haible.
8836         (struct argp_option): Document the use of N_() wrappers.
8837
8838         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
8839         '\v', and translate the two parts separately, instead of feeding
8840         the whole string to gettext.  This allows to exclude
8841         '\v' from the strings visible to the translator by writing doc
8842         strings as N_("..") "\v" N_("..").
8843
8844 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
8845
8846         * config/srclist.txt: Undo latest change; the bug was fixed.
8847
8848 2006-09-09  Bruno Haible  <bruno@clisp.org>
8849
8850         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
8851         assignments if building a library without libtool.
8852         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
8853         in func_emit_lib_Makefile_am.
8854         (func_import): When building a static library libfoo.a, arrange to
8855         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
8856         (func_create_testdir): Likewise.
8857         * modules/gc (configure.ac, Makefile.am): If building statically,
8858         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
8859         * modules/iconvme (configure.ac, Makefile.am): Likewise.
8860         * modules/striconv (configure.ac, Makefile.am): Likewise.
8861         Based on a suggestion by Ralf Wildenhues.
8862
8863 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8864
8865         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8866         Check for unistd.h too, since Autoconf doesn't assume POSIX.
8867         Also:
8868
8869         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8870         Add year_2050_test to catch glibc bug 2821
8871         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8872
8873         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8874         Prefer #ifdef to #if.
8875
8876         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
8877         Return from 'main' instead of calling 'exit'.
8878
8879 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8880
8881         * lib/mktime.c (guess_time_tm): Fix bug where mktime
8882         returned the maximum time_t value rather than (time_t) -1.
8883         Problem originally reported by William Bardwell
8884         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8885
8886         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8887         Moved to here ...
8888         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8889         ... from here.
8890
8891 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8892
8893         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
8894         2821 is fixed.
8895
8896 2006-09-08  Jim Meyering  <jim@meyering.net>
8897
8898         Don't make generated files read-only.  That would bother too many
8899         people.  However, do retain the ability to work when targets are
8900         read-only: remove the destination and temporary files before writing
8901         them (when generated via sed or echo), or by using the -f option for
8902         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
8903         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8904         * modules/byteswap, modules/configmake, modules/fcntl:
8905         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8906         * modules/localcharset, modules/netinet_in, modules/poll:
8907         * modules/stdbool, modules/stdint, modules/sys_select:
8908         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8909
8910 2006-09-08  Jim Meyering  <jim@meyering.net>
8911
8912         Avoid new build failure on FreeBSD 6.0.
8913         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
8914         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
8915         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
8916
8917 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8918
8919         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
8920
8921 2006-09-07  Jim Meyering  <jim@meyering.net>
8922
8923         Fix global typo in last change: use chmod u-w, not chmod u-x.
8924         Spotted by Paul Eggert and Bruce Korb.
8925         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8926         * modules/byteswap, modules/configmake, modules/fcntl:
8927         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8928         * modules/localcharset, modules/netinet_in, modules/poll:
8929         * modules/stdbool, modules/stdint, modules/sys_select:
8930         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8931
8932 2006-09-06  Jim Meyering  <jim@meyering.net>
8933
8934         Make generated files be read-only.
8935         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
8936         Ensure that each generated file is now read-only.
8937         * modules/argz: Likewise.
8938         * modules/arpa_inet: Likewise.
8939         * modules/byteswap: Likewise.
8940         * modules/configmake: Likewise.
8941         * modules/fcntl: Likewise.
8942         * modules/fnmatch: Likewise.
8943         * modules/getopt: Likewise.
8944         * modules/glob: Likewise.
8945         * modules/inttypes: Likewise.
8946         * modules/netinet_in: Likewise.
8947         * modules/poll: Likewise.
8948         * modules/stdbool: Likewise.
8949         * modules/stdint: Likewise.
8950         * modules/sys_select: Likewise.
8951         * modules/sys_socket: Likewise.
8952         * modules/sys_stat: Likewise.
8953         * modules/sysexits: Likewise.
8954         * modules/localcharset: Same as above, but continue using temporary
8955         file named "t-$@" (why different?) rather than the "$@-t" used
8956         everywhere else.
8957
8958         * modules/sysexits (Makefile.am): Replace literal occurrences
8959         of "sysexit.h" more readable, and more consistent, "$@".
8960
8961 2006-09-06  Bruno Haible  <bruno@clisp.org>
8962
8963         * modules/striconv: New file.
8964         * modules/xstriconv: New file.
8965         * MODULES.html.sh (Internationalization functions): Add striconv,
8966         xstriconv.
8967
8968 2006-09-06  Bruno Haible  <bruno@clisp.org>
8969
8970         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
8971         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
8972         not using libtool correctly.
8973
8974 2006-09-06  Bruno Haible  <bruno@clisp.org>
8975
8976         * lib/striconv.h: New file.
8977         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
8978         iconvstring.c.
8979         * lib/xstriconv.h: New file.
8980         * lib/xstriconv.c: New file.
8981
8982 2006-09-06  Bruno Haible  <bruno@clisp.org>
8983
8984         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8985         lib_..._LDFLAGS.
8986
8987 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8988
8989         * lib/argz_.h: Sync from Libtool.
8990
8991         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
8992                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8993
8994         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
8995
8996 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
8997
8998         * modules/trim: New file.
8999
9000 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
9001
9002         * lib/trim.h: New file.
9003         * lib/trim.c: New file.
9004
9005 2006-09-05  Bruno Haible  <bruno@clisp.org>
9006
9007         * MODULES.html.sh (String handling): Add trim.
9008
9009 2006-09-04  Karl Berry  <karl@gnu.org>
9010
9011         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
9012         until next release.
9013
9014 2006-09-03  Bruno Haible  <bruno@clisp.org>
9015
9016         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
9017         correctly.
9018
9019 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9020
9021         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
9022         not gl_GETLOADAVG.  Omit unneeded semicolons.
9023         Problems reported by Ralf Wildenhues in
9024         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
9025         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
9026         at the end, which is the usual gnulib style.
9027
9028         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
9029         of doing all the work ourselves.
9030         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
9031         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
9032
9033 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9034
9035         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
9036         Problem reported by Ralf Wildenhues in
9037         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
9038
9039         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
9040         HAVE_STRUCT_STATFS_F_FSTYPENAME.
9041
9042 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9043
9044         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
9045         yesterday's patch by changing test -n to test -z.
9046
9047 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9048
9049         * modules/getloadavg (Files): Add m4/getloadavg.m4.
9050         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
9051         the former is now obsolescent.
9052
9053         * modules/chdir-long (Depends-on): Add fcntl.
9054
9055 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9056
9057         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
9058         obsolescent, and programs should use gnulib instead.
9059         * m4/getloadavg.m4: New file, with contents taken from Autoconf
9060         but with prefixes changed.
9061
9062 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9063
9064         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
9065         or stdbool.h, because they might not exist while configuring.
9066
9067         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
9068         Don't include unistd.h or limits.h; not needed, since chdir-long.h
9069         does that for us.
9070         (O_DIRECTORY): Remove.
9071
9072 2006-08-31  Eric Blake  <ebb9@byu.net>
9073
9074         * gnulib-tool: Don't let emacs change spaces to TAB.
9075
9076 2006-08-31  Bruno Haible  <bruno@clisp.org>
9077
9078         * gnulib-tool: When calling func_import more than once, do it in a
9079         subshell.
9080         Reported by Eric Blake <ebb9@byu.net>.
9081
9082 2006-08-31  Bruno Haible  <bruno@clisp.org>
9083
9084         * gnulib-tool (nl): Remove variable.
9085         (sed_transform_lib_file): Use more robust test for config-h module.
9086         (func_import): Fix typo in 2006-08-25 patch.
9087
9088 2006-08-31  Bruno Haible  <bruno@clisp.org>
9089
9090         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
9091         specified, augment Makefile.am variables instead of assigning them.
9092
9093 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9094
9095         Work around a bug in both the Linux and SunOS 64-bit kernels:
9096         nanosleep mishandles sleeps for longer than 2**31 seconds.
9097         Problem reported by Frank v Waveren in
9098         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
9099         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
9100         Check for nanosleep bug.
9101         (LIB_NANOSLEEP): Append clock_gettime library if needed.
9102
9103 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9104
9105         Work around a bug in both the Linux and SunOS 64-bit kernels:
9106         nanosleep mishandles sleeps for longer than 2**31 seconds.
9107         Problem reported by Frank v Waveren in
9108         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
9109         * lib/nanosleep.c (BILLION): New constant.
9110         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
9111         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
9112         implementation.
9113
9114 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9115
9116         * modules/nanosleep (Depends-on): Add gettime.
9117
9118 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9119         and Simon Josefsson  <jas@extundo.com>
9120         and Oskar Liljeblad  <oskar@osk.mine.nu>
9121
9122         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
9123         * gnulib-tool (func_import): New license type 'unmodifiable license
9124         text'.
9125         * modules/fdl: Use it.  Longer description.
9126         * module/gpl, module/lgpl: New files.
9127
9128 2006-08-30  Jim Meyering  <jim@meyering.net>
9129
9130         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
9131         shadowing the parameter.
9132
9133 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9134
9135         Sync from Libtool:
9136
9137         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9138
9139         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
9140         sharing with gnulib.  Report by Eric Blake.
9141
9142 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9143
9144         * modules/isapipe: New file.
9145         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
9146
9147 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9148
9149         * modules/configmake (Makefile.am): Add a comment, and omit
9150         the CONFIGMAKE_ prefix from generated macro names.  Suggested
9151         by Bruno Haible.
9152
9153 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9154
9155         * m4/isapipe.m4: New file.
9156
9157 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9158
9159         * lib/isapipe.c, lib/isapipe.h: New files.
9160
9161 2006-08-29  Jim Meyering  <jim@meyering.net>
9162
9163         * modules/configmake (Makefile.am): Make configmake.h depend on
9164         Makefile.  Otherwise, a stale configmake.h could hang around.
9165
9166 2006-08-29  Eric Blake  <ebb9@byu.net>
9167
9168         * lib/error.c (error_at_line, print_errno_message): Match libc, after
9169         resolution of upstream bug 3044.
9170
9171 2006-08-29  Bruno Haible  <bruno@clisp.org>
9172
9173         * modules/localcharset (Depends-on): Add configmake.
9174         (Makefile.am): Remove setting of LIBDIR through DEFS.
9175
9176 2006-08-29  Bruno Haible  <bruno@clisp.org>
9177
9178         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
9179         defined.
9180
9181 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9182
9183         * modules/fcntl: New file.
9184         * modules/chdir-safer (Depends-on): Add fcntl.
9185         * modules/fts: Likewise.
9186         * modules/mkdir-p: Likewise.
9187
9188         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
9189         This undoes the most recent change, since we're now addressing the
9190         problem in a different way.
9191
9192         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
9193         into output, since the output might be called Makefile.am even
9194         if $makefile_name is something different.
9195         (func_import): Use $makefile_am rather than
9196         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
9197         empty.
9198
9199         * modules/inttypes (Files): Add m4/inttypes-h.m4.
9200
9201 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9202
9203         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
9204         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
9205         recent change to stdint.m4, since we're now addressing the problem in a
9206         different way.
9207
9208 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9209
9210         * m4/fcntl_h.m4: New file.
9211
9212 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9213
9214         * lib/fcntl_.h: New file.
9215         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
9216         the fcntl module.
9217         * lib/dirchownmod.c: Likewise.
9218         * lib/fts.c: Likewise.
9219
9220         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
9221         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
9222         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
9223         just before including <inttypes.h>, to avoid circular inclusion.
9224
9225 2006-08-28  Jim Meyering  <jim@meyering.net>
9226
9227         * doc/visibility.texi: Actually read and correct the grammar of the
9228         sentence affected by yesterday's change.
9229
9230 2006-08-28  Eric Blake  <ebb9@byu.net>
9231
9232         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
9233         needs wrapper.
9234
9235 2006-08-28  Eric Blake  <ebb9@byu.net>
9236
9237         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
9238
9239 2006-08-28  Eric Blake  <ebb9@byu.net>
9240
9241         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
9242
9243 2006-08-28  Bruno Haible  <bruno@clisp.org>
9244
9245         * modules/c-strstr: New file, from GNU gettext.
9246         * MODULES.html.sh (String handling): Add c-strstr.
9247
9248 2006-08-28  Bruno Haible  <bruno@clisp.org>
9249
9250         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
9251         macros.
9252         Reported by Eric Blake.
9253
9254 2006-08-28  Bruno Haible  <bruno@clisp.org>
9255
9256         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
9257         (VASNPRINTF): Return a string of length > INT_MAX without failing.
9258         * lib/vasprintf.c: Include errno.h, limits.h.
9259         (EOVERFLOW): New fallback definition.
9260         (vasprintf): Test here whether the string length is > INT_MAX.
9261         * lib/vsnprintf.c: Include errno.h, limits.h.
9262         (EOVERFLOW): New fallback definition.
9263         (vsnprintf): Fix bug when generated string was too long for the buffer.
9264         Test here whether the string length is > INT_MAX.
9265
9266 2006-08-28  Bruno Haible  <bruno@clisp.org>
9267
9268         * lib/inttypes_.h (SCNX*): Remove definitions.
9269         Reported by Eric Blake.
9270
9271 2006-08-28  Bruno Haible  <bruno@clisp.org>
9272
9273         * lib/c-strstr.h: New file, from GNU gettext.
9274         * lib/c-strstr.c: New file, from GNU gettext.
9275
9276 2006-08-28  Bruno Haible  <bruno@clisp.org>
9277
9278         * gnulib-tool: Reorder some statements.
9279
9280 2006-08-28  Bruno Haible  <bruno@clisp.org>
9281
9282         * gnulib-tool: New option --makefile-name.
9283         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
9284         $makefile_name.
9285         (func_import): Write $makefile_name to the cache file, and read it from
9286         there unless explicitly specified. Use $makefile_name as file name
9287         instead of Makefile.am. Adjust the recommendations accordingly.
9288
9289 2006-08-28  Bruno Haible  <bruno@clisp.org>
9290
9291         * gnulib-tool (func_verify_module): Check against misapplying patch.
9292
9293 2006-08-28  Bruno Haible  <bruno@clisp.org>
9294
9295         * gnulib-tool (func_relativize, func_relconcat): New functions.
9296         Give an error if --local-dir is given with --update.
9297         Remove trailing slashes from $local_gnulib_dir.
9298         (func_import): Store the relativized $local_gnulib_dir in
9299         gnulib-cache.m4, and read it from there if not specified explicitly.
9300
9301 2006-08-28  Bruno Haible  <bruno@clisp.org>
9302
9303         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
9304         is the current directory. Respect also $local_gnulib_dir.
9305
9306 2006-08-28  Bruno Haible  <bruno@clisp.org>
9307             Simon Josefsson  <jas@extundo.com>
9308
9309         BeOS portability.
9310         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
9311
9312 2006-08-27  Jim Meyering  <jim@meyering.net>
9313
9314         * doc/visibility.texi: Remove duplicate word: "pointer".
9315
9316 2006-08-26  Bruno Haible  <bruno@clisp.org>
9317
9318         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
9319         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
9320         (Makefile.am): Create inttypes.h from inttypes_.h.
9321         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
9322
9323         * modules/imaxabs: New file.
9324
9325         * modules/imaxdiv: New file.
9326
9327 2006-08-26  Bruno Haible  <bruno@clisp.org>
9328
9329         * m4/inttypes.m4: New file.
9330         * m4/_inttypes_h.m4: Remove file.
9331         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
9332         PRI_MACROS_BROKEN.
9333         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
9334
9335         * m4/imaxabs.m4: New file.
9336
9337         * m4/imaxdiv.m4: New file.
9338
9339 2006-08-26  Bruno Haible  <bruno@clisp.org>
9340
9341         * lib/inttypes_.h: New file.
9342         * lib/inttypes.h: Remove file.
9343         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
9344
9345         * lib/imaxabs.c: New file.
9346
9347         * lib/imaxdiv.c: New file.
9348
9349 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
9350
9351         New config-h module, so that "make" output needn't be cluttered
9352         by -DHAVE_CONFIG_H.
9353         * MODULES.html.sh (Support for building libraries and executables):
9354         Add config-h.
9355         * modules/config-h: New file.
9356         * gnulib-tool (nl, sed_transform_lib_file): New vars.
9357         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
9358         the config-h module is used.
9359
9360         New configmake module, so that "make" output needn't be cluttered
9361         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
9362         * MODULES.html.sh (Support for building libraries and executables):
9363         Add configmake.
9364         * modules/configmake: New file.
9365
9366 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
9367
9368         * m4/config-h.m4: New file.
9369
9370 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
9371
9372         * config/srclist.txt: Add elisp-comp.
9373
9374 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
9375
9376         * MODULES.html.sh (Support for building libraries and executables):
9377         Add elisp-comp.
9378         * build-aux/elisp-comp: New file.
9379         * modules/elisp-comp: New file.
9380
9381 2006-08-24  Bruno Haible  <bruno@clisp.org>
9382
9383         * gnulib-tool (func_create_testdir): Use non-default values of
9384         sourcebase and m4base.
9385
9386 2006-08-24  Bruno Haible  <bruno@clisp.org>
9387
9388         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
9389         HTML structure.
9390
9391 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
9392
9393         * modules/openat (Depends-on): Add lchown.
9394
9395 2006-08-23  Bruno Haible  <bruno@clisp.org>
9396
9397         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
9398         of gl_LOCK_EARLY instead of gl_LOCK.
9399
9400 2006-08-23  Bruno Haible  <bruno@clisp.org>
9401
9402         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
9403         on OSF/1 to no.
9404         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
9405
9406 2006-08-23  Bruno Haible  <bruno@clisp.org>
9407
9408         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
9409         as unusable.
9410
9411         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
9412         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
9413         (gl_LOCK): New macro.
9414
9415 2006-08-22  Simon Josefsson  <jas@extundo.com>
9416
9417         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
9418         to md5 module.
9419
9420 2006-08-22  Simon Josefsson  <jas@extundo.com>
9421
9422         * MODULES.html.sh: Add "Support for maintaining and release
9423         projects".
9424
9425         * build-aux/gnupload: New file, from coreutils.
9426
9427 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9428
9429         Avoid the need for AC_LIBSOURCES in m4 macros.
9430         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
9431         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
9432         * modules/check-version (EXTRA_DIST): Add check-version.h.
9433         * modules/crc (EXTRA_DIST): Add crc.h.
9434         * modules/des (EXTRA_DIST): Add des.h.
9435         * modules/gc (EXTRA_DIST): Add gc.h.
9436         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
9437         * modules/getline (EXTRA_DIST): Add getline.h.
9438         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
9439         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
9440         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
9441         * modules/md2 (EXTRA_DIST): Add md2.h.
9442         * modules/md4 (EXTRA_DIST): Add md4.h.
9443         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
9444         * modules/read-file (EXTRA_DIST): Add read-file.h.
9445         * modules/readline (EXTRA_DIST): Add readline.h.
9446         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
9447         rijndael-api-fst.h.
9448
9449 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9450
9451         * m4/rijndael.m4 (gl_ARCFOUR):
9452         * m4/arctwo.m4 (gl_ARCTWO):
9453         * m4/check-version.m4 (gl_CHECK_VERSION):
9454         * m4/crc.m4 (gl_CRC):
9455         * m4/des.m4 (gl_DES):
9456         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
9457         * m4/gc.m4 (gl_GC):
9458         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
9459         * m4/getline.m4 (gl_FUNC_GETLINE):
9460         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
9461         * m4/hmac-md5.m4 (gl_HMAC_MD5):
9462         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
9463         * m4/md2.m4 (gl_MD2):
9464         * m4/md4.m4 (gl_MD4):
9465         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
9466         * m4/read-file.m4 (gl_FUNC_READ_FILE):
9467         * m4/readline.m4 (gl_FUNC_READLINE):
9468         * m4/rijndael.m4 (gl_RIJNDAEL):
9469         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
9470         to get the necessary .h files and whatnot.
9471
9472 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9473
9474         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
9475         gnulib rather than the other way around.
9476         * config/srclistvars.sh (COREUTILS): Remove.
9477
9478 2006-08-22  Jim Meyering  <jim@meyering.net>
9479
9480         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
9481
9482         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
9483
9484 2006-08-22  Eric Blake  <ebb9@byu.net>
9485
9486         * modules/regexprops-generic: New file.
9487         * MODULES.html.sh (Support for building documentation): List it.
9488
9489 2006-08-22  Eric Blake  <ebb9@byu.net>
9490
9491         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
9492         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
9493         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
9494         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
9495
9496 2006-08-22  Bruno Haible  <bruno@clisp.org>
9497
9498         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
9499         and lib_LTLIBRARIES like the other lib_* variables.
9500
9501 2006-08-22  Bruno Haible  <bruno@clisp.org>
9502
9503         * build-aux/x-to-1.in: New file, from GNU gettext.
9504
9505 2006-08-22  Bruno Haible  <bruno@clisp.org>
9506
9507         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
9508         <utmpx.h> exists.
9509
9510 2006-08-22  Bruno Haible  <bruno@clisp.org>
9511
9512         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
9513         <utmpx.h> exists.
9514
9515 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
9516
9517         BeOS portability.
9518         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
9519         exist.
9520         Problem reported by Bruno Haible.
9521
9522 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
9523
9524         Avoid the need for AC_LIBSOURCES in m4 macros.
9525         * modules/acl (EXTRA_DIST): Add acl.h.
9526         * modules/argmatch (Files): Add m4/argmatch.m4.
9527         (configure.ac): Add gl_ARGMATCH.
9528         (EXTRA_DIST): Renamed from lib_SOURCES, for
9529         consistency with the other modules.  Remove argmatch.c.
9530         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
9531         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
9532         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
9533         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
9534         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
9535         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
9536         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
9537         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
9538         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
9539         * modules/closeout (EXTRA_DIST): Add closeout.h.
9540         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
9541         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
9542         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
9543         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
9544         dirname.h; remove basename.c and stripslash.c.
9545         * modules/exclude (EXTRA_DIST): Add exclude.h.
9546         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
9547         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
9548         * modules/file-type (EXTRA_DIST): Add file-type.h.
9549         * modules/filemode (EXTRA_DIST): Add filemode.h.
9550         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
9551         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
9552         * modules/fpending (EXTRA_DIST): Add __fpending.h.
9553         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
9554         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
9555         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
9556         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
9557         * modules/getdate (EXTRA_DIST): Add getdate.c.
9558         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
9559         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
9560         * modules/getpass (EXTRA_DIST): Add getpass.h.
9561         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
9562         * modules/group-member (EXTRA_DIST): Add group-member.h.
9563         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
9564         * modules/hash (EXTRA_DIST): Add hash.h.
9565         * modules/human (EXTRA_DIST): Add human.h.
9566         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
9567         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
9568         * modules/lchown (EXTRA_DIST): Add lchown.h.
9569         * modules/long-options (EXTRA_DIST): Add long-options.h.
9570         * modules/lstat (EXTRA_DIST): Add lstat.h.
9571         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
9572         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
9573         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
9574         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
9575         * modules/memxor (EXTRA_DIST): Add memxor.h.
9576         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
9577         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
9578         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
9579         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
9580         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
9581         * modules/physmem (EXTRA_DIST): Add physmem.h.
9582         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
9583         * modules/posixver (EXTRA_DIST): Add posixver.h.
9584         * modules/quote (EXTRA_DIST): Add quote.h.
9585         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
9586         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
9587         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
9588         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
9589         regex_internal.h regexec.c.
9590         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
9591         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
9592         * modules/same (EXTRA_DIST): Add same.h.
9593         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
9594         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
9595         * modules/savedir (EXTRA_DIST): Add savedir.h.
9596         * modules/sha1 (EXTRA_DIST): Add sha1.h.
9597         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
9598         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
9599         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
9600         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
9601         * modules/strdup (EXTRA_DIST): Add strdup.h.
9602         * modules/strftime (EXTRA_DIST): Add strftime.h.
9603         * modules/strndup (EXTRA_DIST): Add strndup.h.
9604         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
9605         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
9606         * modules/time_r (EXTRA_DIST): Add time_r.h.
9607         * modules/timespec (EXTRA_DIST): Add timespec.h.
9608         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
9609         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
9610         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
9611         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
9612         * modules/userspec (EXTRA_DIST): Add userspec.h.
9613         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
9614         * modules/utimens (EXTRA_DIST): Add utimens.h.
9615         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
9616         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
9617         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
9618         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
9619         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
9620         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
9621         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
9622         * modules/yesno (EXTRA_DIST): Add yesno.h.
9623
9624 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
9625
9626         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
9627
9628         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
9629         * m4/dev-ino.m4, same-inode.m4: Remove.
9630
9631         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
9632         * m4/acl.m4 (AC_FUNC_ACL):
9633         * m4/backupfile.m4 (gl_BACKUPFILE):
9634         * m4/c-strtod.m4 (gl_C99_STRTOLD):
9635         * m4/canon-host.m4 (gl_CANON_HOST):
9636         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
9637         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
9638         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
9639         * m4/cloexec.m4 (gl_CLOEXEC):
9640         * m4/close-stream.m4 (gl_CLOSE_STREAM):
9641         * m4/closeout.m4 (gl_CLOSEOUT):
9642         * m4/dirfd.m4 (gl_FUNC_DIRFD):
9643         * m4/dirname.m4 (gl_DIRNAME):
9644         * m4/exclude.m4 (gl_EXCLUDE):
9645         * m4/exitfail.m4 (gl_EXITFAIL):
9646         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
9647         * m4/file-type.m4 (gl_FILE_TYPE):
9648         * m4/filemode.m4 (gl_FILEMODE):
9649         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
9650         * m4/fpending.m4 (gl_FUNC_FPENDING):
9651         * m4/fprintftime.m4 (gl_FPRINTFTIME):
9652         * m4/fts.m4 (gl_FUNC_FTS):
9653         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
9654         * m4/getdate.m4 (gl_GETDATE):
9655         * m4/gethrxtime.m4 (gl_GETHRXTIME):
9656         * m4/getpagesize.m4 (gl_GETPAGESIZE):
9657         * m4/getpass.m4 (gl_FUNC_GETPASS):
9658         * m4/gettime.m4 (gl_GETTIME):
9659         * m4/getugroups.m4 (gl_GETUGROUPS):
9660         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
9661         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
9662         * m4/hard-locale.m4 (gl_HARD_LOCALE):
9663         * m4/hash.m4 (gl_HASH):
9664         * m4/idcache.m4 (gl_IDCACHE):
9665         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
9666         * m4/lchown.m4 (gl_FUNC_LCHOWN):
9667         * m4/long-options.m4 (gl_LONG_OPTIONS):
9668         * m4/lstat.m4 (gl_FUNC_LSTAT):
9669         * m4/md5.m4 (gl_MD5):
9670         * m4/memcasecmp.m4 (gl_MEMCASECMP):
9671         * m4/memcoll.m4 (gl_MEMCOLL):
9672         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
9673         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
9674         * m4/memxor.m4 (gl_MEMXOR):
9675         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
9676         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
9677         * m4/modechange.m4 (gl_MODECHANGE):
9678         * m4/mountlist.m4 (gl_MOUNTLIST):
9679         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
9680         * m4/openat.m4 (gl_FUNC_OPENAT):
9681         * m4/pathmax.m4 (gl_PATHMAX):
9682         * m4/physmem.m4 (gl_PHYSMEM):
9683         * m4/posixtm.m4 (gl_POSIXTM):
9684         * m4/posixver.m4 (gl_POSIXVER):
9685         * m4/quote.m4 (gl_QUOTE):
9686         * m4/quotearg.m4 (gl_QUOTEARG):
9687         * m4/readtokens.m4 (gl_READTOKENS):
9688         * m4/readutmp.m4 (gl_READUTMP):
9689         * m4/regex.m4 (gl_REGEX):
9690         * m4/safe-read.m4 (gl_SAFE_READ):
9691         * m4/safe-write.m4 (gl_SAFE_WRITE):
9692         * m4/same.m4 (gl_SAME):
9693         * m4/save-cwd.m4 (gl_SAVE_CWD):
9694         * m4/savedir.m4 (gl_SAVEDIR):
9695         * m4/settime.m4 (gl_SETTIME):
9696         * m4/sha1.m4 (gl_SHA1):
9697         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
9698         * m4/stat-macros.m4 (gl_STAT_MACROS):
9699         * m4/stat-time.m4 (gl_STAT_TIME):
9700         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
9701         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
9702         * m4/strdup.m4 (gl_FUNC_STRDUP):
9703         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
9704         * m4/strndup.m4 (gl_FUNC_STRNDUP):
9705         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
9706         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
9707         * m4/time_r.m4 (gl_TIME_R):
9708         * m4/timespec.m4 (gl_TIMESPEC):
9709         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
9710         * m4/unlinkdir.m4 (gl_UNLINKDIR):
9711         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
9712         * m4/userspec.m4 (gl_USERSPEC):
9713         * m4/utimecmp.m4 (gl_UTIMECMP):
9714         * m4/utimens.m4 (gl_UTIMENS):
9715         * m4/xalloc.m4 (gl_XALLOC):
9716         * m4/xgetcwd.m4 (gl_XGETCWD):
9717         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
9718         * m4/xreadlink.m4 (gl_XREADLINK):
9719         * m4/xstrtod.m4 (gl_XSTRTOD):
9720         * m4/yesno.m4 (gl_YESNO):
9721         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
9722         to get the necessary .h files and whatnot.
9723
9724 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
9725             Bruno Haible  <bruno@clisp.org>
9726
9727         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
9728         /bin/sh understanding of '!' conditional negation.
9729
9730 2006-08-21  Jim Meyering  <jim@meyering.net>
9731
9732         * modules/openat (Depends-on): Really alphabetize.
9733
9734         * modules/acl (Depends-on): Add error and quote.
9735
9736         * check-module (find_included_lib_files): Add at-func.c to the
9737         ok-to-include-more-than-once white list.
9738
9739         * modules/openat (Depends-on): Add lstat.  Alphabetize.
9740
9741 2006-08-21  Bruno Haible  <bruno@clisp.org>
9742
9743         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9744         Emit a pkgdata_DATA variable only if some snippets add contents to it.
9745         Reported by Martin Lambers <marlam@marlam.de>.
9746
9747 2006-08-21  Bruno Haible  <bruno@clisp.org>
9748
9749         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
9750         specify an installation location, don't emit a noinst_LIBRARIES or
9751         noinst_LTLIBRARIES assignment.
9752
9753 2006-08-21  Bruno Haible  <bruno@clisp.org>
9754
9755         BeOS portability.
9756         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
9757         BeOS has mbrtowc() but no <wctype.h>.
9758
9759 2006-08-21  Bruno Haible  <bruno@clisp.org>
9760
9761         BeOS portability.
9762         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
9763         exist.
9764
9765 2006-08-21  Bruno Haible  <bruno@clisp.org>
9766
9767         BeOS portability.
9768         * lib/mbchar.h: Include <wctype.h> only if it exists.
9769
9770 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9771
9772         Remove files that are no longer needed by their respective modules.
9773         * m4/obstack.m4: Remove.
9774         * m4/strerror_r.m4: Remove.
9775         * m4/uint32_t.m4: Remove.
9776         * m4/uintptr_t.m4: Remove.
9777         * m4/ullong_max.m4: Remove.
9778         * m4/xstrtoimax.m4: Remove.
9779         * m4/xstrtoumax.m4: Remove.
9780
9781         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
9782         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
9783         dependencies now capture this.
9784
9785         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
9786         Do not use AC_LIBSOURCES, since gnulib modules now do this.
9787         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
9788         * m4/human.m4 (gl_HUMAN): Likewise.
9789         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
9790         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
9791
9792         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
9793
9794         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
9795         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
9796         stdint.
9797         * m4/human.m4 (gl_HUMAN): Likewise.
9798         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
9799         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
9800         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9801         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9802         * m4/xstrtol (gl_XSTRTOL): Likewise.
9803
9804         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
9805         AC_TYPE_LONG_LONG_INT.
9806         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9807         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
9808         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
9809         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9810
9811         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
9812         on stdbool.
9813
9814         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
9815         (gl_PREREQ_XSTRTOUL): Remove.
9816
9817         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
9818
9819         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
9820         mode.
9821
9822 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9823
9824         Add and change modules to make it easier for coreutils to use
9825         gnulib-tool.
9826         * modules/backupfile (Files): Remove m4/d-ino.m4.
9827         (Depends-on): Add d-ino.
9828         * modules/cycle-check (Depends-on): Add stdint.
9829         (lib_SOURCES): Add cycle-check.h.
9830         * modules/d-ino: New module.
9831         * modules/d-type: New module.
9832         * modules/error (Files): Remove m4/strerror_r.m4.
9833         * modules/filemode (Files): Add m4/st_dm_mode.m4.
9834         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
9835         m4/inttypes_h.m4, m4/uintmax_t.m4.
9836         (Depends-on): Add stdint.
9837         (lib_SOURCES): Add fsusage.h.
9838         * modules/getcwd (Files): Remove d-ino.m4.
9839         (Depends-on): Add d-ino.
9840         * modules/getndelim2 (Depends-on): Add stdint.
9841         * modules/glob (Files): Remove m4/d-type.m4.
9842         (Depends-on): Add d-type.
9843         * modules/host-os: New module.
9844         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
9845         m4/inttypes_h.m4, m4/uintmax_t.m4.
9846         * Depends-on: Add stdint.
9847         (lib_SOURCES): Add human.h.
9848         * modules/inttostr (Files): Remove m4/intmax_t.m4,
9849         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
9850         m4/uintmax_t.m4, m4/ulonglong.m4.
9851         (Depends-on): Add stdint.
9852         (EXTRA_DIST): Add inttostr.h.
9853         * modules/lchmod: New module.
9854         * modules/link-follow: New module.
9855         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
9856         (Depends-on): Add lchmod.
9857         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
9858         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
9859         (Depends-on): Add stdint.
9860         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
9861         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
9862         (Depends-on): Add stdint.
9863         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
9864         * modules/perl: New module.
9865         * modules/regex (Depends-on): Add stdint.
9866         * modules/rmdir-errno: New module.
9867         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9868         m4/intmax_t.m4.
9869         (Depends-on): Add stdint.
9870         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9871         m4/uintmax_t.m4.
9872         (Depends-on): Add stdint.
9873         * modules/unlink-busy: New module.
9874         * modules/utimecmp (Depends-on): Add stdint.
9875         * modules/uptime: New module.
9876         * modules/winsz-ioctl: New module.
9877         * modules/winsz-termios: New module.
9878         * modules/xnanosleep (Depends-on): Add nanosleep.
9879         * modules/ullong_max: Remove.
9880         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
9881         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
9882         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
9883         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
9884         (Depends-on): Add inttypes.
9885         (lib_SOURCES): Add xstrtol.h.
9886         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
9887         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
9888         * MODULES.html.sh: Move 'assert' into the assert section.
9889         Move 'dummy' into the linking section.
9890         Remove ullong_max.
9891         Add section for compatibility checks for POSIX:2001 functions,
9892         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
9893         winsz-ioctl, and winsz-termios into it.
9894         Add lchmod.
9895         Add top-level Misc section and put host-os, perl, and uptime
9896         into it.
9897
9898 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9899
9900         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
9901         now assume the stdint module.  Do not include inttypes.h.
9902         * lib/fsusage.h: Likewise.
9903         * lib/getndelim2.c: Likewise.
9904         * lib/human.h: Likewise.
9905         * lib/inttostr.h: Likewise.
9906         * lib/obstack.c: Likewise.
9907         * lib/regex_internal.h: Likewise.
9908         * lib/tempname.c: Likewise.
9909         * lib/utimecmp.c: Likewise.
9910         * lib/xstrtol.h: Likewise.
9911
9912         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
9913
9914         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
9915         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
9916         * lib/xtime.h: Likewise.
9917
9918 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9919
9920         * modules/openat (Files): Add lib/fchmodat.c.
9921         Fixes problem reported by Jay Youngman.
9922
9923 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9924
9925         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
9926         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
9927
9928 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
9929             Bruno Haible  <bruno@clisp.org>
9930
9931         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
9932         and is a script that invokes bison. Tighten the code. Add comments.
9933
9934 2006-08-18  Jim Meyering  <jim@meyering.net>
9935
9936         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
9937         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
9938         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
9939         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
9940
9941 2006-08-18  Bruno Haible  <bruno@clisp.org>
9942
9943         * modules/bison-i18n: New file.
9944         * MODULES.html.sh (Internationalization functions): Add it.
9945
9946 2006-08-18  Bruno Haible  <bruno@clisp.org>
9947
9948         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
9949         sys/statvfs.h. When getmntinfo was found, check its declaration and
9950         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
9951
9952 2006-08-18  Bruno Haible  <bruno@clisp.org>
9953
9954         * m4/bison-i18n.m4: New file, from bison.
9955
9956 2006-08-18  Bruno Haible  <bruno@clisp.org>
9957
9958         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
9959         (ME_DUMMY): Treat "kernfs" as a dummy.
9960         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
9961
9962 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9963
9964         Update from coreutils.
9965
9966         2006-08-15  Jim Meyering  <jim@meyering.net>
9967
9968         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
9969
9970         2006-01-17  Jim Meyering  <jim@meyering.net>
9971
9972         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
9973
9974         2006-01-11  Jim Meyering  <jim@meyering.net>
9975
9976         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
9977         Check for the lchmod function.
9978
9979 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9980
9981         Update from coreutils.
9982
9983         * lib/__fpending.h: Add copyright notice.
9984         * lib/fprintftime.h: Likewise.
9985         * lib/savedir.c: Use (C) in copyright notice.
9986         * lib/savedir.h: Likewise.
9987
9988         2006-08-15  Jim Meyering  <jim@meyering.net>
9989
9990         * lib/at-func.c: New file, with the logic of all emulated at-functions.
9991         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
9992         in support of the EXPECTED_ERRNO macro.
9993         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
9994         definitions.  Instead, define the appropriate symbols and include
9995         "at-func.c".
9996         * lib/mkdirat.c (mkdirat): Likewise.
9997         * lib/fchmodat.c (fchmodat): Likewise.
9998         (ENOSYS): Remove definition.
9999         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
10000         it.  Don't include "unistd--.h" -- it wasn't ever used.
10001
10002         2006-01-17  Jim Meyering  <jim@meyering.net>
10003
10004         Rewrite fts.c not to change the current working directory,
10005         by using openat, fstatat, fdopendir, etc..
10006
10007         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
10008         (HAVE_OPENAT_SUPPORT): Define.
10009         [_LIBC] (fchdir): Don't undef or define; no longer used.
10010         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
10011         Now, this `function' always succeeds, and consumes its file descriptor
10012         parameter -- so callers must not close such FDs.  Update callers.
10013         (diropen_fd, opendirat, cwd_advance_fd): New functions.
10014         (diropen): Add parameter, SP.  Adjust all callers.
10015         Implement using diropen_fd, rather than open.
10016         (fts_open): Initialize new member, fts_cwd_fd.
10017         Remove fts_rft-setting code.
10018         (fts_close): Close fts_cwd_fd, if necessary.
10019         (__opendir2): Define in terms of opendir or opendirat,
10020         depending on whether the FST_NOCHDIR flag is set.
10021         (fts_build): Since fts_safe_changedir consumes its FD, and since
10022         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
10023         and close the dup'd file descriptor upon failure.
10024         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
10025         (fts_safe_changedir): Tweak semantics to reflect that this function
10026         now calls cwd_advance_fd and hence consumes its FD argument.
10027         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
10028         [struct FTS] (fts_rft): Remove now-unused member.
10029         [struct FTS] (fts_cycle.state): Improve comment.
10030
10031         * lib/openat.c (openat_needs_fchdir): New function.
10032         * lib/openat.h (openat_needs_fchdir): Declare it.
10033
10034 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
10035
10036         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
10037         Problem and fix reported by Pádraig Brady in
10038         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
10039
10040 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10041
10042         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
10043
10044 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10045
10046         * lib/memcoll.c (memcoll): Optimize for the common case where the
10047         arguments are bytewise equal.
10048
10049 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10050
10051         * doc/regexprops-generic.texi: Add a copyright notice.
10052
10053 2006-08-15  Bruno Haible  <bruno@clisp.org>
10054
10055         * modules/tmpdir (License): Change to LGPL.
10056
10057 2006-08-15  Bruno Haible  <bruno@clisp.org>
10058
10059         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
10060         module.
10061
10062 2006-08-14  Simon Josefsson  <jas@extundo.com>
10063
10064         * config/srclist.txt: Add gnupload.
10065
10066 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10067
10068         Change copyright notice from LGPL 2 to GPL 2, since that's the
10069         standard form used in the gnulib repository.
10070         * tests/test-lock.c: Likewise.
10071         * tests/test-stdint.c: Likewise.
10072         * tests/test-tls.c: Likewise.
10073
10074         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
10075         prelude-manager.  User shorter URLs for GNU projects, without '?'.
10076         Add copyright notice.
10077
10078         * check-module: Add copyright notice.  Output a copyright
10079         notice if "--version" is specified.
10080         * modules/COPYING: New file.
10081         * tests/test-getaddrinfo.c: Add copyright notice.
10082         * tests/test-verify.c: Likewise.
10083
10084 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10085
10086         Change copyright notice from LGPL 2 to GPL 2, since that's the
10087         standard form used in the gnulib repository.
10088         * lib/lock.c: LGPL -> GPL.
10089         * lib/lock.h: Likewise.
10090         * lib/strnlen1.c: Likewise.
10091         * lib/strnlen1.h: Likewise.
10092         * lib/tls.c: Likewise.
10093         * lib/tls.h: Likewise.
10094         * lib/tmpdir.c: Likewise.
10095
10096         * lib/TODO: Remove; this belongs only in coreutils.
10097
10098 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10099
10100         Add copyright notices to long-enough files that lack them, since
10101         otherwise the files aren't clearly free.  Use the same notice that
10102         getdate.texi already uses.
10103         * doc/alloca-opt.texi: Add copyright notice.
10104         * doc/alloca.texi: Likewise.
10105         * doc/ctime.texi: Likewise.
10106         * doc/functions.texi: Likewise.
10107         * doc/gcd.texi: Likewise.
10108         * doc/gnulib-tool.texi: Likewise.
10109         * doc/inet_ntoa.texi: Likewise.
10110         * doc/visibility.texi: Likewise.
10111
10112         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
10113         * doc/quote.texi: Add copyright notice.
10114
10115         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
10116         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
10117         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
10118         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
10119         is now obsolete, and give a pointer to the Sun list.
10120         Add copyright notice.
10121
10122 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10123
10124         * config/srclistvars.sh: Add copyright notice.
10125
10126 2006-08-14  Eric Blake  <ebb9@byu.net>
10127
10128         Import the following change from libc:
10129
10130         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
10131
10132         Upstream bug 2997.
10133         * lib/misc/error.c: Add space between program name and message if file
10134         name is missing.
10135
10136 2006-08-12  Karl Berry  <karl@gnu.org>
10137
10138         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
10139         remove, these originate in gnulib now.
10140
10141 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10142
10143         * doc/Makefile (standards.info standards.html standards.dvi):
10144         Also depend on make-stds.texi.
10145
10146 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
10147
10148         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
10149         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
10150
10151         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
10152         in wchar_t.  Problem reported by Eric Blake.
10153
10154         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
10155         LEN is smaller than SIZE.  Suggested by Bruno Haible.
10156         Also, help the compiler to keep LEN in a register.
10157
10158 2006-08-11  Eric Blake  <ebb9@byu.net>
10159
10160         * users.txt: Sort.  Add tar.
10161
10162 2006-08-11  Bruno Haible  <bruno@clisp.org>
10163
10164         * users.txt: New file.
10165
10166 2006-08-11  Bruno Haible  <bruno@clisp.org>
10167
10168         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
10169         before <wchar.h>. Needed for OSF/1 and BSD/OS.
10170
10171 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
10172
10173         * modules/snprintf (Depends-on): Remove minmax.
10174         (Maintainer): Add self and Bruno.
10175
10176 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
10177
10178         * lib/.cppi-disable: Add snprintf.h, socket_.h.
10179         * lib/snprintf.c: Include <errno.h> and <limits.h>.
10180         (EOVERFLOW): Define if the system does not.
10181         Do not include "minmax.h"; it wasn't used.
10182         (snprintf): Don't assume size_t promotes to an unsigned type.
10183         Fix bug when generated string was too long for the buffer: the
10184         buffer's contents are supposed to be the initial prefix of the
10185         output.  Don't assume vasnprintf returns EOVERFLOW if the size
10186         exceeds INT_MAX; do the check ourselves.
10187
10188         Import the following changes from libc:
10189
10190         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
10191
10192         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
10193         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
10194         set wc to the byte which couldn't be converted.
10195         (re_string_reconstruct): Don't clear valid_raw_len before calling
10196         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
10197         tip_context using re_string_context_at.
10198
10199         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
10200
10201         * lib/posix/regex.h: g++ still cannot handled [restrict].
10202
10203         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
10204
10205         * lib/posix/regex.h: Remove special handling for VMS.
10206
10207 2006-08-10  Jim Meyering  <jim@meyering.net>
10208
10209         * modules/same-inode: New module.
10210         * modules/dev-ino: New module.
10211         * modules/cycle-check: Depend on these modules, rather than simply
10212         including their .h files.
10213         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
10214         required via m4/cycle-check.m4.
10215         * modules/same: Depend on new same-inode module, rather than
10216         including same-inode.h.
10217         * modules/chdir-safer: New file.
10218
10219         * modules/chown (Depends-on): Add stat-macros.
10220
10221 2006-08-10  Jim Meyering  <jim@meyering.net>
10222
10223         * m4/cycle-check.m4: New file.
10224         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
10225         * m4/dev-ino.m4, m4/same-inode.m4: New files.
10226
10227 2006-08-10  Eric Blake  <ebb9@byu.net>
10228
10229         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
10230         in from original proposal.
10231
10232 2006-08-10  Eric Blake  <ebb9@byu.net>
10233         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10234
10235         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
10236         namespace.
10237
10238 2006-08-10  Bruno Haible  <bruno@clisp.org>
10239
10240         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
10241         as well.
10242
10243 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10244
10245         Sync from coreutils.
10246
10247         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
10248
10249         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
10250         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
10251
10252 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10253
10254         * modules/restrict: Remove; no longer needed now that we assume
10255         Autoconf 2.59 or later.
10256         * MODULES.html.sh: Remove 'restrict'.
10257         * modules/argp (Depends-on): Remove 'restrict'.
10258         * modules/base64 (Depends-on): Likewise.
10259         * modules/gc (Depends-on): Likewise.
10260         * modules/getaddrinfo (Depends-on): Likewise.
10261         * modules/glob (Depends-on): Likewise.
10262         * modules/inet_ntop (Depends-on): Likewise.
10263         * modules/inet_pton (Depends-on): Likewise.
10264         * modules/memxor (Depends-on): Likewise.
10265         * modules/regex (Depends-on): Likewise.
10266         * modules/strtok_r (Depends-on): Likewise.
10267         * modules/time_r (Depends-on): Likewise.
10268
10269 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10270
10271         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
10272         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
10273         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
10274         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
10275         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
10276         * m4/memxor.m4 (gl_MEMXOR): Likewise.
10277         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
10278         gl_C_RESTRICT replaced by AC_C_RESTRICT.
10279
10280         Merge from coreutils.
10281         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
10282         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
10283         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
10284         * m4/time_r.m4 (gl_TIME_R): Likewise.
10285
10286 2006-08-09  Karl Berry  <karl@gnu.org>
10287
10288         * config/srclist.txt: no more gettext-tools, per Bruno.
10289
10290 2006-08-08  Eric Blake  <ebb9@byu.net>
10291
10292         * modules/verror: New module.
10293         * MODULES.html.sh: Document it.
10294
10295 2006-08-08  Eric Blake  <ebb9@byu.net>
10296
10297         * lib/verror.h, lib/verror.c: New files.
10298
10299 2006-08-08  Eric Blake  <ebb9@byu.net>
10300
10301         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
10302         verror_at_line output complies with GNU Coding Standards even when
10303         file is NULL.
10304
10305 2006-08-07  Bruno Haible  <bruno@clisp.org>
10306
10307         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
10308         versions of AIX.
10309         Reported by Ralf Wildenhues.
10310
10311 2006-08-07  Bruno Haible  <bruno@clisp.org>
10312
10313         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
10314         in an AC_DEFUN. Needed so that the autoconf snippets can use
10315         AC_REQUIRE.
10316
10317 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10318
10319         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10320         Initialize pkgdata_DATA.
10321         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
10322         overriding it.
10323
10324 2006-08-06  Eric Blake  <ebb9@byu.net>
10325
10326         * lib/error.h: Fold in some upstream changes from glibc.
10327         * lib/error.c: Likewise.
10328
10329 2006-08-04  Bruno Haible  <bruno@clisp.org>
10330
10331         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10332         Make the mostlyclean-local rule depend on mostlyclean-generic.
10333         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
10334
10335 2006-07-31  Bruno Haible  <bruno@clisp.org>
10336
10337         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
10338         <stdlib.h>, <string.h>.
10339
10340 2006-07-30  Bruno Haible  <bruno@clisp.org>
10341
10342         * modules/readlink (License): Change to LGPL.
10343
10344 2006-07-30  Bruno Haible  <bruno@clisp.org>
10345
10346         * modules/javaversion (Makefile.am): Distribute javaversion.java and
10347         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
10348         set PKGDATADIR to point to it.
10349
10350 2006-07-30  Bruno Haible  <bruno@clisp.org>
10351
10352         * modules/csharpexec (configure.ac): Comment out macro invocation.
10353         * modules/javaexec (configure.ac): Likewise.
10354         * modules/javacomp-script (configure.ac): Likewise.
10355
10356         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
10357
10358 2006-07-30  Bruno Haible  <bruno@clisp.org>
10359
10360         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
10361         linked-list.
10362
10363 2006-07-30  Bruno Haible  <bruno@clisp.org>
10364
10365         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
10366
10367 2006-07-30  Bruno Haible  <bruno@clisp.org>
10368
10369         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10370         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
10371         get removed.
10372
10373 2006-07-29  Bruno Haible  <bruno@clisp.org>
10374
10375         Make it possible for gnulib-tool to work with locally modified or
10376         augmented gnulib repositories.
10377         * gnulib-tool (func_usage): Document --local-dir option.
10378         (local_gnulib_dir): New variable.
10379         Handle --local-dir option.
10380         (func_lookup_file): New function.
10381         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
10382         (func_get_description, func_get_filelist, func_get_description,
10383         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
10384         func_get_automake_snippet, func_get_include_directive,
10385         func_get_license, func_get_maintainer): Use func_lookup_file.
10386         (func_import, func_create_testdir): Use func_lookup_file.
10387
10388 2006-07-29  Bruno Haible  <bruno@clisp.org>
10389
10390         * modules/setenv (Depends-on): Add unistd.
10391
10392 2006-07-29  Bruno Haible  <bruno@clisp.org>
10393
10394         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
10395
10396 2006-07-29  Bruno Haible  <bruno@clisp.org>
10397
10398         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
10399
10400 2006-07-29  Bruno Haible  <bruno@clisp.org>
10401
10402         * gnulib-tool (import, update): If there is no Makefile.am, look at
10403         aclocal.m4, instead of bailing out.
10404
10405 2006-07-29  Bruno Haible  <bruno@clisp.org>
10406
10407         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
10408         Categorize the options by when they are useful.
10409
10410 2006-07-29  Bruno Haible  <bruno@clisp.org>
10411
10412         * gnulib-tool (func_usage): Document option --no-libtool.
10413         Handle option --no-libtool.
10414         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
10415         for changed semantics of $libtool variable.
10416         (func_import): Likewise. If libtool is not used, show this through
10417         an option --no-libtool.
10418         (func_create_testdir): Update.
10419
10420 2006-07-29  Bruno Haible  <bruno@clisp.org>
10421
10422         * gnulib-tool (func_import): Extend error message about missing
10423         --doc-base.
10424
10425 2006-07-29  Bruno Haible  <bruno@clisp.org>
10426
10427         * gnulib-tool (func_import): Don't create the $docbase directory if
10428         there is no file to store there.
10429
10430 2006-07-29  Bruno Haible  <bruno@clisp.org>
10431
10432         * gnulib-tool (autoconf_minversion): If a --dir option is given and
10433         relevant, look for configure.ac there, not in the current directory.
10434         Also use a simple search for AC_PREREQ, not "autoconf --trace".
10435
10436 2006-07-29  Bruno Haible  <bruno@clisp.org>
10437
10438         * gnulib-tool (SORT): New variable.
10439         (func_usage): Undocument --assume-autoconf option.
10440         Remove --assume-autoconf option handling.
10441         (autoconf_minversion): Determine from the contents of configure.ac.
10442         (func_import): Remove autoconf_minversion handling.
10443         Suggested by Eric Blake.
10444
10445 2006-07-29  Bruno Haible  <bruno@clisp.org>
10446
10447         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
10448
10449 2006-07-29  Bruno Haible  <bruno@clisp.org>
10450
10451         * config/srclist.txt (*setenv.[ch]): Remove rules.
10452
10453 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10454
10455         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
10456
10457 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10458
10459         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
10460         arpa/inet.h.
10461
10462 2006-07-28  Simon Josefsson  <jas@extundo.com>
10463
10464         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
10465         * modules/inet_pton (Depends-on): Likewise.
10466
10467 2006-07-28  Simon Josefsson  <jas@extundo.com>
10468
10469         * m4/netinet_in_h.m4: New file.
10470
10471 2006-07-28  Simon Josefsson  <jas@extundo.com>
10472
10473         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
10474         #include's.
10475
10476 2006-07-28  Simon Josefsson  <jas@extundo.com>
10477
10478         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
10479         #include's.
10480
10481 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
10482
10483         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
10484         setgid on directories only if they set these bits.
10485         * lib/modechange.h: Remove obsolete comment about masks.
10486
10487 2006-07-28  Eric Blake  <ebb9@byu.net>
10488
10489         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
10490         macro expansion.
10491
10492 2006-07-28  Bruno Haible  <bruno@clisp.org>
10493
10494         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
10495
10496 2006-07-28  Bruno Haible  <bruno@clisp.org>
10497
10498         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
10499
10500 2006-07-28  Bruno Haible  <bruno@clisp.org>
10501
10502         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
10503         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
10504         Define fallbacks.
10505         Avoids link error on FreeBSD 4.x.
10506         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
10507
10508         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
10509         encoding.
10510         * lib/mbswidth.c (iswcntrl): Likewise.
10511
10512 2006-07-27  Bruno Haible  <bruno@clisp.org>
10513
10514         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
10515         test.
10516
10517 2006-07-27  Bruno Haible  <bruno@clisp.org>
10518
10519         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
10520         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
10521         defined.
10522
10523 2006-07-26  Eric Blake  <ebb9@byu.net>
10524
10525         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
10526
10527 2006-07-26  Eric Blake  <ebb9@byu.net>
10528
10529         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
10530         like mingw that lack mkstemp.
10531         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
10532         avoid compilation warning on mingw.
10533
10534 2006-07-26  Bruno Haible  <bruno@clisp.org>
10535
10536         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
10537         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
10538         INT_FAST*_MIN, INTPTR_MIN.
10539
10540 2006-07-25  Bruno Haible  <bruno@clisp.org>
10541
10542         * modules/version-etc (Depends-on): Add stdarg.
10543
10544 2006-07-25  Bruno Haible  <bruno@clisp.org>
10545
10546         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
10547         complex commands.
10548
10549 2006-07-25  Bruno Haible  <bruno@clisp.org>
10550
10551         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
10552         defined in <stdarg.h> or config.h.
10553
10554 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
10555
10556         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
10557         (gl_STDIO_SAFER): Remove.
10558
10559 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
10560
10561         * MODULES.html.sh (File stream based Input/Output):
10562         Add fopen-safer, tmpfile-safer; remove stdio-safer.
10563         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
10564         * modules/fopen-safer, modules/tmpfile-safer: New files.
10565         * modules/stdio-safer: Remove.
10566
10567 2006-07-24  Bruno Haible  <bruno@clisp.org>
10568
10569         * modules/tmpdir: New file.
10570         * MODULES.html.sh (File system functions): Add it.
10571
10572 2006-07-24  Bruno Haible  <bruno@clisp.org>
10573
10574         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
10575         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
10576
10577 2006-07-24  Bruno Haible  <bruno@clisp.org>
10578
10579         * modules/clean-temp: New file.
10580
10581 2006-07-24  Bruno Haible  <bruno@clisp.org>
10582
10583         * m4/tmpdir.m4: New file, from GNU gettext.
10584
10585 2006-07-24  Bruno Haible  <bruno@clisp.org>
10586
10587         * lib/tmpdir.h: New file, from GNU gettext.
10588         * lib/tmpdir.c: New file, from GNU gettext.
10589
10590 2006-07-24  Bruno Haible  <bruno@clisp.org>
10591
10592         * lib/clean-temp.h: New file, from GNU gettext.
10593         * lib/clean-temp.c: New file, from GNU gettext.
10594
10595 2006-07-23  Eric Blake  <ebb9@byu.net>
10596
10597         * modules/stdio-safer (Files): Add tmpfile-safer.c.
10598         (Depends-on): Add binary-io.
10599
10600 2006-07-23  Eric Blake  <ebb9@byu.net>
10601
10602         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
10603
10604 2006-07-23  Eric Blake  <ebb9@byu.net>
10605
10606         * lib/tmpfile-safer.c: New file.
10607         * lib/stdio-safer.h (fopen_safer): Add prototype.
10608         * lib/stdio--.h (tmpfile): Make safer.
10609
10610 2006-07-23  Bruno Haible  <bruno@clisp.org>
10611
10612         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
10613         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
10614         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
10615         gl_linked_remove_at): Use it.
10616
10617 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10618         and Simon Josefsson <jas@extundo.com>
10619
10620         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
10621
10622         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
10623
10624 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10625
10626         * modules/close-stream: New file.
10627         * modules/closeout (Description): Make it clear that it exits
10628         with a diagnostic on error.
10629         (Depends-on): Add close-stream.  Remove fpending, stdbool.
10630         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
10631
10632 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10633
10634         * m4/close-stream.m4: New file.
10635
10636 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10637
10638         * lib/close-stream.c, lib/close-stream.h: New files.
10639
10640 2006-07-22  Bruno Haible  <bruno@clisp.org>
10641
10642         Merge from GNU gettext 0.15.
10643
10644         2006-05-01  Bruno Haible  <bruno@clisp.org>
10645
10646                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
10647
10648         2006-07-22  Bruno Haible  <bruno@clisp.org>
10649
10650                 * modules/javaversion: New file.
10651                 * MODULES.html.sh (Java): Add javaversion.
10652
10653         2006-03-12  Bruno Haible  <bruno@clisp.org>
10654
10655                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
10656
10657         2005-12-04  Bruno Haible  <bruno@clisp.org>
10658
10659                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
10660                 (untested).
10661
10662         2006-06-21  Bruno Haible  <bruno@clisp.org>
10663
10664                 Avoid warnings from recent versions of mcs.
10665                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
10666                 -o, -L, -r any more. Use options documented since mcs-1.0
10667                 instead. Similarly for -g.
10668
10669         2005-12-04  Bruno Haible  <bruno@clisp.org>
10670
10671                 * build-aux/csharpcomp.sh.in: Suffix for resources is
10672                 .resources, not .resource.
10673
10674         2005-07-09  Bruno Haible  <bruno@clisp.org>
10675
10676                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
10677                 add a .dll suffix.
10678                 Reported by Mark Junker <mjscod@gmx.de>.
10679
10680         2006-07-22  Bruno Haible  <bruno@clisp.org>
10681
10682                 * modules/gettext: Upgrade to gettext-0.15.
10683                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
10684                 m4/visibility.m4.
10685                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
10686
10687 2006-07-22  Bruno Haible  <bruno@clisp.org>
10688
10689         Merge from GNU gettext 0.15.
10690
10691         2006-03-25  Bruno Haible  <bruno@clisp.org>
10692
10693                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
10694
10695         2006-07-21  Bruno Haible  <bruno@clisp.org>
10696
10697                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
10698                 "1.1".
10699
10700         2006-05-09  Bruno Haible  <bruno@clisp.org>
10701
10702                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
10703                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
10704                 for the conftestver execution.
10705
10706         2006-05-01  Bruno Haible  <bruno@clisp.org>
10707
10708                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
10709                 optional target-version argument. Verify that the compiler
10710                 groks source of the specified source-version, or add -source
10711                 option as necessary. Verify that the compiler produces
10712                 bytecode in the specified target-version, or add -target and
10713                 -source options as necessary. Make the result of the test
10714                 available as variable CONF_JAVAC. Also log error output in
10715                 config.log.
10716
10717         2006-03-11  Bruno Haible  <bruno@clisp.org>
10718
10719                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
10720
10721         2006-05-09  Bruno Haible  <bruno@clisp.org>
10722
10723                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
10724                 CLASSPATH_SEPARATOR to a semicolon.
10725
10726         2006-03-12  Bruno Haible  <bruno@clisp.org>
10727
10728                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
10729                 available as variable CONF_JAVA, for subsequent autoconf
10730                 tests. Also log error output in config.log.
10731
10732         2006-07-19  Bruno Haible  <bruno@clisp.org>
10733
10734                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
10735                 that getline works on glibc2 systems. Needed to avoid trouble
10736                 in relocatable.c.
10737                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
10738
10739         2005-12-04  Bruno Haible  <bruno@clisp.org>
10740
10741                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
10742                 launcher (untested).
10743
10744         2005-12-04  Bruno Haible  <bruno@clisp.org>
10745
10746                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
10747
10748         2006-07-22  Bruno Haible  <bruno@clisp.org>
10749
10750                 * gettext.m4: Update from GNU gettext-0.15.
10751                 * nls.m4: Likewise.
10752                 * po.m4: Likewise.
10753                 * inttypes-pri.m4: Likewise.
10754                 * inttypes-h.m4: Renamed from inttypes.m4.
10755                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
10756
10757 2006-07-22  Bruno Haible  <bruno@clisp.org>
10758
10759         Merge from GNU gettext 0.15.
10760
10761         2005-07-05  Bruno Haible  <bruno@clisp.org>
10762
10763                 * printf-args.c (printf_fetchargs): Work around broken
10764                 definition of wint_t on mingw.
10765
10766         2005-02-12  Bruno Haible  <bruno@clisp.org>
10767
10768                 * xallocsa.h: Add extern "C" for C++.
10769
10770         2006-05-17  Bruno Haible  <bruno@clisp.org>
10771
10772                 Cygwin portability.
10773                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
10774
10775         2006-04-30  Bruno Haible  <bruno@clisp.org>
10776
10777                 * progreloc.c: Include <mach-o/dyld.h> if available.
10778                 (find_executable): Use _NSGetExecutablePath when possible.
10779
10780         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
10781
10782                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
10783                 function.
10784
10785         2005-12-29  Bruno Haible  <bruno@clisp.org>
10786
10787                 * progreloc.c (set_program_name_and_installdir): Fix
10788                 compilation error.
10789
10790         2005-12-04  Bruno Haible  <bruno@clisp.org>
10791
10792                 Cygwin portability.
10793                 * progreloc.c: Include <windows.h> also on Cygwin.
10794                 (find_executable): Add support for Cygwin.
10795                 (set_program_name_and_installdir): Handle also platforms with
10796                 nonempty EXEEXT.
10797
10798         2006-07-11  Bruno Haible  <bruno@clisp.org>
10799
10800                 * javacomp.c: Fix a comment.
10801                 Reported by Jim Meyering.
10802
10803         2006-04-30  Bruno Haible  <bruno@clisp.org>
10804
10805                 * javacomp.h (compile_java_class): Add source_version,
10806                 target_version arguments.
10807                 * javacomp.c: Rewritten to choose only a compiler that
10808                 respects the specified source_version and target_version.
10809
10810         2006-06-27  Bruno Haible  <bruno@clisp.org>
10811
10812                 Assume correct S_ISDIR macro.
10813                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
10814
10815         2006-07-22  Bruno Haible  <bruno@clisp.org>
10816
10817                 * javaversion.h: New file, from GNU gettext.
10818                 * javaversion.c: New file, from GNU gettext.
10819                 * javaversion.java: New file, from GNU gettext.
10820                 * javaversion.class: New file, from GNU gettext.
10821
10822         2006-05-17  Bruno Haible  <bruno@clisp.org>
10823
10824                 Cygwin portability.
10825                 * javaexec.c (execute_java_class): Test for jview program
10826                 also on Cygwin.
10827
10828         2006-04-09  Bruno Haible  <bruno@clisp.org>
10829
10830                 * fatal-signal.c: Don't include string.h.
10831                 (at_fatal_signal): Use a copying loop instead of memcpy.
10832
10833         2005-12-04  Bruno Haible  <bruno@clisp.org>
10834
10835                 * csharpexec.c: Add support for 'clix' launcher (untested).
10836                 (execute_csharp_using_sscli): New function.
10837                 (execute_csharp_program): Call it.
10838
10839         2006-06-21  Bruno Haible  <bruno@clisp.org>
10840
10841                 Avoid warnings from recent versions of mcs.
10842                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
10843                 -o, -L, -r any more. Use options documented since mcs-1.0
10844                 instead. Similarly for -g.
10845
10846         2005-07-09  Bruno Haible  <bruno@clisp.org>
10847
10848                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
10849                 add a .dll suffix.
10850                 Reported by Mark Junker <mjscod@gmx.de>.
10851
10852         2006-06-17  Bruno Haible  <bruno@clisp.org>
10853
10854                 * config.charset: Update for NetBSD 3.0.
10855
10856         2006-05-17  Bruno Haible  <bruno@clisp.org>
10857
10858                 Cygwin portability.
10859                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
10860
10861         2006-05-16  Bruno Haible  <bruno@clisp.org>
10862
10863                 * localcharset.c [CYGWIN]: Include <windows.h>.
10864                 (get_charset_aliases): For Cygwin, return the same CPxxx
10865                 aliases list as under WIN32.
10866                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
10867                 the environment variables. Fall back to GetACP().
10868
10869         2006-04-05  Bruno Haible  <bruno@clisp.org>
10870
10871                 * config.charset: Update Juan Manuel Guerrero's address.
10872
10873         2005-02-12  Bruno Haible  <bruno@clisp.org>
10874
10875                 * allocsa.h: Add extern "C" for C++.
10876
10877         2005-02-10  Bruno Haible  <bruno@clisp.org>
10878
10879                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
10880                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
10881
10882         2006-07-22  Bruno Haible  <bruno@clisp.org>
10883
10884                 * gettext.h: Update to GNU gettext-0.15.
10885
10886 2006-07-22  Bruno Haible  <bruno@clisp.org>
10887
10888         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
10889         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
10890         lib-prefix.m4, longdouble.m4, ssize_t.m4.
10891
10892 2006-07-21  Eric Blake  <ebb9@byu.net>
10893
10894         * modules/stdlib-safer: New file.
10895         * MODULES.html.sh (File stream based Input/Output): Add
10896         stdlib-safer.
10897
10898 2006-07-21  Eric Blake  <ebb9@byu.net>
10899
10900         * lib/stdlib-safer.h: New file from coreutils, required by
10901         stdlib--.h.
10902
10903 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
10904
10905         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
10906
10907 2006-07-20  Bruno Haible  <bruno@clisp.org>
10908
10909         * gnulib-tool: Recognize new option --assume-autoconf.
10910         (autoconf_minversion): New variable.
10911         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
10912
10913 2006-07-20  Bruno Haible  <bruno@clisp.org>
10914
10915         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
10916
10917 2006-07-19  Derek R. Price  <derek@ximbiot.com>
10918
10919         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
10920         Reindent and repaginate.
10921
10922 2006-07-19  Derek Price  <derek@ximbiot.com>
10923
10924         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
10925         Correct grammar.
10926
10927 2006-07-17  Bruno Haible  <bruno@clisp.org>
10928
10929         * modules/list: New file.
10930         * modules/array-list: New file.
10931         * modules/carray-list, modules/carray-list-tests: New files.
10932         * modules/linked-list, modules/linked-list-tests: New files.
10933         * modules/avltree-list, modules/avltree-list-tests: New files.
10934         * modules/rbtree-list, modules/rbtree-list-tests: New files.
10935         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
10936         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
10937         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
10938         * modules/oset: New file.
10939         * modules/array-oset: New file.
10940         * modules/avltree-oset, modules/avltree-oset-tests: New files.
10941         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
10942         * tests/test-carray_list.c: New file.
10943         * tests/test-linked_list.c: New file.
10944         * tests/test-avltree_list.c: New file.
10945         * tests/test-rbtree_list.c: New file.
10946         * tests/test-linkedhash_list.c: New file.
10947         * tests/test-avltreehash_list.c: New file.
10948         * tests/test-rbtreehash_list.c: New file.
10949         * tests/test-avltree_oset.c: New file.
10950         * tests/test-rbtree_oset.c: New file.
10951         * MODULES.html.sh (Container data structures): New section.
10952
10953 2006-07-17  Bruno Haible  <bruno@clisp.org>
10954
10955         * m4/gl_list.m4: New file.
10956
10957 2006-07-17  Bruno Haible  <bruno@clisp.org>
10958
10959         * lib/gl_list.h: New file.
10960         * lib/gl_list.c: New file.
10961         * lib/gl_array_list.h: New file.
10962         * lib/gl_array_list.c: New file.
10963         * lib/gl_carray_list.h: New file.
10964         * lib/gl_carray_list.c: New file.
10965         * lib/gl_linked_list.h: New file.
10966         * lib/gl_linked_list.c: New file.
10967         * lib/gl_anylinked_list1.h: New file.
10968         * lib/gl_anylinked_list2.h: New file.
10969         * lib/gl_avltree_list.h: New file.
10970         * lib/gl_avltree_list.c: New file.
10971         * lib/gl_anyavltree_list1.h: New file.
10972         * lib/gl_anyavltree_list2.h: New file.
10973         * lib/gl_rbtree_list.h: New file.
10974         * lib/gl_rbtree_list.c: New file.
10975         * lib/gl_anyrbtree_list1.h: New file.
10976         * lib/gl_anyrbtree_list2.h: New file.
10977         * lib/gl_anytree_list1.h: New file.
10978         * lib/gl_anytree_list2.h: New file.
10979         * lib/gl_linkedhash_list.h: New file.
10980         * lib/gl_linkedhash_list.c: New file.
10981         * lib/gl_anyhash_list1.h: New file.
10982         * lib/gl_anyhash_list2.h: New file.
10983         * lib/gl_avltreehash_list.h: New file.
10984         * lib/gl_avltreehash_list.c: New file.
10985         * lib/gl_rbtreehash_list.h: New file.
10986         * lib/gl_rbtreehash_list.c: New file.
10987         * lib/gl_anytreehash_list1.h: New file.
10988         * lib/gl_anytreehash_list2.h: New file.
10989
10990         * lib/gl_oset.h: New file.
10991         * lib/gl_oset.c: New file.
10992         * lib/gl_array_oset.h: New file.
10993         * lib/gl_array_oset.c: New file.
10994         * lib/gl_avltree_oset.h: New file.
10995         * lib/gl_avltree_oset.c: New file.
10996         * lib/gl_rbtree_oset.h: New file.
10997         * lib/gl_rbtree_oset.c: New file.
10998         * lib/gl_anytree_oset.h: New file.
10999
11000 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11001
11002         * m4/mkancesdirs.m4: New file.
11003         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
11004         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
11005         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
11006         it.
11007
11008 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11009
11010         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
11011         * lib/mkancesdirs.h: New files.
11012         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
11013         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
11014         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
11015         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
11016         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
11017         callers changed.  Revamp internals significantly, by not
11018         attempting to create directories that are temporarily more
11019         permissive than the final results.  Do not attempt to use
11020         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
11021         This removes some race conditions, fixes some bugs, and simplifies
11022         things.  Use new dirchownmod function to do owner and mode changes.
11023         * lib/mkdir-p.h: Likewise.
11024         * lib/modechange.c (octal_to_mode): New function.
11025         (struct mode_change): New member mentioned.
11026         (make_node_op_equals): New arg mentioned.  All callers changed.
11027         (mode_compile): Keep track of which mode bits the user has explicitly
11028         mentioned.
11029         (mode_adjust): New arg DIR, so that we implement the X op correctly.
11030         New arg PMODE_BITS, to keep track of which mode bits the user
11031         mentioned; it treats S_ISUID and S_ISGID speciall.
11032         All callers changed.
11033         * lib/modechange.h: Likewise.
11034
11035 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11036
11037         * MODULES.html.sh: Add mkancestors.
11038         * modules/mkancesdirs: New module.
11039         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
11040         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
11041         The chdir-safer and afs files are now orphans; I'll remove them
11042         unless someone speaks up.
11043         Add lib/dirchownmod.c, lib/dirchownmod.h.
11044         (Depends-on): Remove alloca, chown, save-cwd, dirname.
11045         Add lchown, mkancesdirs.
11046         (Maintainer): Add self.
11047
11048 2006-07-15  Karl Berry  <karl@gnu.org>
11049
11050         * gnulib-tool: help message wording/arrangement.
11051
11052 2006-07-14  Simon Josefsson  <jas@extundo.com>
11053
11054         * doc/gnulib.texi (Libtool and Windows): New section.
11055
11056 2006-07-12  Simon Josefsson  <jas@extundo.com>
11057
11058         * modules/gendocs (License): Fix license, approved by Karl.
11059
11060 2006-07-12  Eric Blake  <ebb9@byu.net>
11061
11062         * MODULES.html.sh: Add gendocs.
11063
11064 2006-07-11  Eric Blake  <ebb9@byu.net>
11065
11066         * modules/fdl: New module, to install doc/fdl.texi.
11067         * MODULES.html.sh: Add new section for documentation modules.
11068         * gnulib-tool: Avoid space-tab.
11069         (--doc-base): New option, to manage files from doc.
11070
11071 2006-07-11  Eric Blake  <ebb9@byu.net>
11072
11073         * m4/absolute-header.m4: Fix comments to match recent change.
11074
11075 2006-07-11  Eric Blake  <ebb9@byu.net>
11076
11077         * gnulib-tool: List --doc-base before --tests-base.
11078
11079 2006-07-11  Derek R. Price  <derek@ximbiot.com>
11080
11081         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
11082
11083 2006-07-11  Bruno Haible  <bruno@clisp.org>
11084
11085         * README: Mention where to put documentation.
11086
11087 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11088
11089         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
11090
11091 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
11092
11093         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
11094         to stdint.m4.
11095
11096 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
11097
11098         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
11099         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
11100         "no/such/file/stdint.h" when there is no such file, so that
11101         the resulting C code can be parsed by dodgy compilers.
11102         Problems reported by Bob Proulx.
11103
11104 2006-07-10  Derek R. Price  <derek@ximbiot.com>
11105
11106         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
11107         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
11108         macros into the GNU _D_EXACT_NAMLEN.
11109         * lib/savedir.c:  Likewise.
11110         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
11111
11112 2006-07-10  Derek R. Price  <derek@ximbiot.com>
11113         and Paul Eggert  <eggert@cs.ucla.edu>
11114
11115         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
11116         * m4/savedir.m4:
11117         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
11118         macros into the GNU _D_EXACT_NAMLEN.
11119
11120 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11121
11122         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
11123         around the absolute name, to work around a problem with the HP-UX
11124         11.23 native C compiler, reported by Bob Proulx.
11125
11126 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11127
11128         * doc/maintain.texi, make-stds.texi: Sync from
11129         <http://savannah.gnu.org/projects/gnustandards>.
11130
11131 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11132
11133         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
11134
11135 2006-07-09  Jim Meyering  <jim@meyering.net>
11136
11137         * m4/glob.m4: Remove a doubled word in a comment.
11138
11139 2006-07-09  Jim Meyering  <jim@meyering.net>
11140
11141         * lib/argp-pv.c: Remove a doubled word in a comment.
11142         * lib/check-version.c (check_version): Likewise.
11143         * lib/javacomp.c (compile_java_class): Likewise.
11144
11145 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11146
11147         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
11148         for the benefit of people using Autoconf 2.60.  If you want to
11149         support older Autoconf versions you can copy m4/onceonly_2_57.m4
11150         (or m4/onceonly.m4, if pre-2.57) manually.
11151
11152 2006-07-08  Jim Meyering  <jim@meyering.net>
11153
11154         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
11155         comment.
11156         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
11157         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
11158         comment.
11159
11160 2006-07-08  Jim Meyering  <jim@meyering.net>
11161
11162         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
11163
11164 2006-07-07  Simon Josefsson  <jas@extundo.com>
11165
11166         * tests/test-crc.c: Change expected crc value, the test vector
11167         were probably computed using the old broken crc.c?
11168
11169 2006-07-06  Simon Josefsson  <jas@extundo.com>
11170
11171         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
11172         now the canonical place for the M4 file).
11173
11174         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
11175         from the sys_socket dependency now.
11176
11177         * modules/inet_pton (Files): Ditto.
11178
11179         * modules/inet_ntop (Files): Ditto.
11180
11181 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11182
11183         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
11184         not gl_PREREQ_GETUSERSHELL.
11185
11186 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11187
11188         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
11189         with only one argument, for Autoconf 2.60.
11190         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
11191         expand to nothing, so add a shell command to avoid syntax error.
11192         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11193
11194 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11195
11196         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
11197
11198 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11199
11200         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
11201         no longer needed.  Check for isblank decl.
11202         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
11203         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
11204         of existence.
11205
11206 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11207
11208         * lib/getloadavg.c: Use __VMS, not VMS.
11209         * lib/getopt.c: Likewise.
11210         * lib/getpagesize.h: Likewise.
11211         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
11212         and probably does not work.
11213
11214 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11215
11216         * lib/.cppi-disable: Add wcwidth.
11217         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
11218         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
11219         (ISGRAPH): Remove.  All uses changed to isgraph.
11220         (FOLD) [!defined _LIBC]: Remove special case.
11221         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
11222         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
11223         HAVE_ISBLANK.
11224         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
11225         case.
11226
11227 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
11228
11229         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
11230         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
11231         brackets.  Other minor changes to suppress some compiler
11232         warnings.
11233
11234 2006-07-06  Derek R. Price  <derek@ximbiot.com>
11235         and Paul Eggert  <eggert@cs.ucla.edu>
11236
11237         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
11238         of invoking obsolescent AC_HEADER_DIRENT macro.
11239         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
11240         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
11241         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
11242         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
11243         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
11244         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
11245         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
11246         * m4/readdir.m4: Remove; no longer needed.
11247
11248 2006-07-06  Derek R. Price  <derek@ximbiot.com>
11249         and Paul Eggert  <eggert@cs.ucla.edu>
11250
11251         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
11252         Don't worry about this obsolete case any more.
11253         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
11254         directories.
11255         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
11256         worry about this obsolete case any more.
11257         * lib/fts.c: Likewise.
11258         * lib/getcwd.c: Likewise.
11259         * lib/glob.h: Likewise.
11260         * lib/savedir.c: Likewise.
11261
11262 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11263
11264         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
11265         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
11266         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
11267         needed.
11268         All uses removed.
11269         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11270         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
11271         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
11272         needed.
11273         * m4/getdate.m4 (gl_GETDATE): Likewise.
11274         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
11275         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
11276         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
11277         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11278         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
11279         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
11280         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
11281         needed.
11282
11283 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11284
11285         * lib/memcasecmp.c: Include <limits.h>.
11286         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
11287         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
11288         Don't assume isdigit succeeds only on '0' through '9'.
11289
11290 2006-07-05  Eric Blake  <ebb9@byu.net>
11291
11292         * modules/getaddrinfo (Depends-on): Add snprintf.
11293
11294 2006-07-05  Eric Blake  <ebb9@byu.net>
11295
11296         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
11297         to avoid 'header present but could not be compiled' on cygwin.
11298
11299 2006-07-05  Eric Blake  <ebb9@byu.net>
11300
11301         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
11302         missing from netdb.h.
11303         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
11304
11305 2006-07-05  Derek R. Price  <derek@ximbiot.com>
11306
11307         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
11308         no longer needed.
11309         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
11310         * m4/getdate.m4 (gl_GETDATE): Likewise.
11311         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
11312         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
11313         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
11314         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11315         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
11316
11317 2006-07-05  Derek R. Price  <derek@ximbiot.com>
11318
11319         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
11320         All uses of is_space replaced by isspace.
11321         * lib/exit.h: Don't talk about STDC_HEADERS.
11322         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
11323         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
11324         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
11325         replaced by isprint etc.
11326         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
11327         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
11328         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
11329         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
11330         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
11331         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
11332
11333 2006-07-05  Bruno Haible  <bruno@clisp.org>
11334
11335         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
11336         the function exists, before testing against AIX.
11337         Reported by Martin Lambers <marlam@marlam.de>.
11338
11339 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
11340
11341         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
11342         From Mark D. Baushke.
11343
11344 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
11345
11346         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
11347         to the absolute name, not just one, to bypass Sun C 5.8's
11348         "warning: #include of /usr/include/... may be non-portable".
11349
11350 2006-07-04  Eric Blake  <ebb9@byu.net>
11351
11352         * modules/dirname-tests: New test module.
11353         * tests/test-dirname.c: New file, replacing dirname.c
11354         TEST_DIRNAME section that was recently deleted.
11355
11356 2006-07-04  Bruno Haible  <bruno@clisp.org>
11357
11358         Assume ANSI C header files and <ctype.h> functions.
11359         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
11360         (mbsnwidth): Use isprint, iscntrl instead.
11361
11362 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11363
11364         Merge from coreutils.
11365         * MODULES.html.sh: Add xstrtold.
11366         * modules/xstrtold: New file.
11367         * modules/cycle-check (Files): Add lib/same-inode.h.
11368         * modules/dirname (Files): Add m4/double-slash-root.m4.
11369         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
11370         * modules/mkdir-p (Files): Add lib/same-inode.h.
11371         * modules/same (Files): Add lib/same-inode.h.
11372
11373 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11374
11375         * m4/absolute-header.m4: Renamed from full-header-path.m4.
11376         This is to keep the terminology clean; POSIX talks about
11377         "absolute pathnames", not "full pathnames", but the GNU
11378         Coding Standards say to use "path" for something else;
11379         so use "absolute" to keep both sides happy.
11380         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
11381         Set gl_absolute_header, not gl_full_header_path.
11382         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
11383         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
11384         All uses changed.
11385
11386         Merge from coreutils.
11387
11388         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
11389
11390         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
11391         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
11392         want to require the building of c-strtod.o.
11393         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
11394         needs -lm directly.
11395         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
11396
11397         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
11398
11399         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
11400         --as-needed option if available.  Problem reported by Albert Chin in
11401         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
11402         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
11403         cc merely issues a bunch of annoying warnings for --as-needed
11404         (this problem was reported by Bob Proulx).  Also, try linking with
11405         -lm to detect a bug in binutils 2.16 (this problem was reported
11406         by Ralf Wildenhues).
11407
11408         2006-06-18  Jim Meyering  <jim@meyering.net>
11409
11410         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
11411         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
11412         macro.
11413         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
11414         also check for glibc-2.4's abort-inducing bug.
11415
11416         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
11417         Low-probability clean-up should be to use rmdir to get rid of
11418         the just-created directory, not unlink.
11419
11420         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
11421         configure fail, and request a bug report to inform us about it.
11422         Add a comment that, barring reports to the contrary, in 2007 we'll
11423         assume ftruncate is universally available.
11424
11425         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
11426
11427         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
11428
11429         2006-03-12  Jim Meyering  <jim@meyering.net>
11430
11431         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
11432         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
11433         * m4/same.m4 (gl_SAME): Likewise.
11434         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
11435
11436         2006-03-11  Eric Blake  <ebb9@byu.net>
11437
11438         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
11439         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
11440         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
11441         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
11442
11443 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11444
11445         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
11446         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
11447         reported by Mark D. Baushke, one in
11448         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
11449
11450         Merge from coreutils.
11451
11452         * lib/.cppi-disable: Add stdint_.h.
11453         * lib/.cvsignore: Add stdint.h.
11454
11455         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
11456
11457         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
11458         both double and long double versions.
11459         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
11460         * lib/xstrtold.c: New file.
11461         * lib/xstrtod.h (xstrtold): New decl.
11462
11463         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
11464
11465         * lib/filemode.c (setst): Remove.
11466         (strmode): Rewrite to avoid setst.  This makes the code shorter,
11467         (arguably) clearer, and the generated code is a bit smaller on my
11468         Debian GNU/Linux stable x86 host.
11469
11470         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
11471
11472         * lib/filemode.c: Include "filemode.h" first, to test the interface.
11473         Assume that filemode.h includes sys/types.h and sys/stat.h.
11474         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
11475         (ftypelet): Reorder to put common cases first, for efficiency.
11476         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
11477         to do 'M'.
11478         (strmode): Renamed from mode_string, and now stores 12 bytes instead
11479         of 10, for compatibility with FreeBSD.  All callers changed.
11480         (filemodestring): Now stores 12 bytes instead of 10, and sets file
11481         types that can't be deduced solely from st_mode.  First arg is now a
11482         const pointer.
11483         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
11484         (strmode): Renamed from mode_string.
11485         (filemodestring): New decl.
11486         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
11487         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
11488         needed.
11489         (S_ISPORT, S_ISWHT): New macros, if not already defined.
11490
11491         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
11492
11493         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
11494         fsusage.h now does that.  Include fsusage.h first, to test interface.
11495         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
11496         at most one method (the old code could have generated decls that
11497         didn't conform to C89, not that this was ever exercised).
11498         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
11499
11500         2006-03-19  Jim Meyering  <jim@meyering.net>
11501
11502         Work even in a chroot where d_ino values for entries in "/"
11503         don't match the stat.st_ino values for the same names.
11504         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
11505         number, iterate through all entries again, using lstat instead.
11506         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
11507         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
11508
11509         * lib/getcwd.c (__getcwd): Clarify a comment.
11510         Use memcpy in place of a call to strcpy.
11511
11512         2006-03-12  Jim Meyering  <jim@meyering.net>
11513
11514         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
11515         matches that of the current directory (which we're about to chdir ".."
11516         out of), then save the dev-ino of the parent, instead.
11517
11518         * lib/same-inode.h (SAME_INODE): New file/macro.
11519         * lib/chdir-safer.c (SAME_INODE): Remove definition.
11520         Include "same-inode.h", instead.
11521         * lib/same.c: Likewise.
11522         * lib/cycle-check.h: Include "same-inode.h".
11523         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
11524         * lib/cycle-check.c (SAME_INODE): Remove definition.
11525         * lib/root-dev-ino.h: Include "same-inode.h".
11526
11527         2006-03-11  Eric Blake  <ebb9@byu.net>
11528
11529         * lib/same.c (same_name): s/base_name/last_component/
11530         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
11531         * lib/filenamecat.c (file_name_concat): Likewise.
11532
11533         2006-03-11  Eric Blake  <ebb9@byu.net>,
11534                     Paul Eggert  <eggert@cs.ucla.edu>
11535
11536         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
11537         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
11538         drive prefix.
11539         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
11540         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
11541         (last_component): New method.
11542         * lib/dirname.c (dir_len): Determine when drive letters need a
11543         subsequent slash.  Preserve // when it is special.
11544         (dir_name): Don't append dot when drive letter is absolute.
11545         [TEST_DIRNAME]: Move into a full-blown gnulib test.
11546         * lib/basename.c (base_name): New semantics - malloc the result.
11547         Preserve // when it is special.  Preserve relative files that look
11548         like drive letters.
11549         (base_len): Preserve // when it is special.
11550         (last_component): New method, similar to old base_name semantics.
11551         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
11552         base_name.  Strip redundant slashes from ///.
11553
11554 2006-07-03  Jim Meyering  <jim@meyering.net>
11555
11556         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
11557         macro is used before the first cycle_check call.
11558
11559 2006-07-03  Eric Blake  <ebb9@byu.net>
11560
11561         * modules/dirname (Depends-on): Add xstrndup.
11562
11563 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
11564
11565         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
11566         test cases, so that config.log is a bit easier to follow.
11567
11568 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
11569
11570         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
11571         both are 64 bits, since this seems to be the tradition, and this
11572         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
11573         we ever run into a host that prefers long long to long in this
11574         case, we'll need another configure-time test.  Problem reported by
11575         Jim Meyering.
11576
11577 2006-07-02  Eric Blake  <ebb9@byu.net>
11578
11579         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
11580
11581 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11582
11583         * modules/inttypes (Depends-on): No longer depends on stdint.
11584         * modules/stdint (Description): Say more about assumptions.
11585         Say that the fast types might differ.  Say macros are used.
11586         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
11587         (Makefile.am): Revise list of substituted symbols to match
11588         new stdint.m4.
11589         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
11590         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
11591         * tests/test-stdint.c (verify_same_types)
11592         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
11593         the code conforms to C99/C89.
11594         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
11595         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
11596
11597 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11598
11599         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
11600         but fix a bug, by requiring at least 64 bits.
11601         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
11602         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
11603         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
11604         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
11605
11606         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
11607         changes.  Make 2.59 a prerequisite.  Check and substitute for
11608         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
11609         inttypes.h.  Do not use special include files; just use the
11610         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
11611         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
11612         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
11613         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
11614         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
11615         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
11616         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
11617         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
11618         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
11619         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
11620         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
11621         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
11622         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
11623         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
11624         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
11625         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
11626         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
11627         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
11628         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
11629         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
11630         WINT_MAX.  Check for C99 conformance more strictly, by detecting
11631         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
11632         not check for things that C99 does not require, e.g., int8_t.  If
11633         a test isn't needed unless <stdint.h> isn't working, and is
11634         unlikely to be needed for any other reason, then don't do it
11635         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
11636         size_t, since we assume C89 freestanding at least.  Do not check
11637         for sig_atomic_t, wchar_t, or wint_t, since the code now does
11638         the right thing even if the types are not defined.  Instead use:
11639         (gl_STDINT_TYPE_PROPERTIES): New macro.
11640         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
11641         testing whether <sys/types.h> clashes, as Autoconf does this for
11642         us now.  All uses removed.
11643         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
11644         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
11645         (gl_CHECK_TYPE_SAME):
11646         Remove; no longer needed.
11647         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
11648         exists, since we'll return 0 anyway in that case.
11649         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
11650
11651 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11652
11653         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
11654         possible collision with system files.
11655         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
11656         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
11657         WCHAR_MIN and WCHAR_MAX in this case.
11658         (<stddef.h>): Do not include; no longer needed.
11659         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
11660         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
11661         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
11662         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
11663         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
11664         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
11665         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
11666         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
11667         !defined(__c99))]: Include in this case too, since it's harmless
11668         now.
11669         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
11670         dangerous to do so.
11671         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
11672         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
11673         (_STDINT_MIN, _STDINT_MAX): New macros.
11674         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
11675         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
11676         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
11677         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
11678         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
11679         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
11680         macros, not typedefs; this simplifies things quite a bit.
11681         Use long int for all types narrower than int64_t.
11682         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
11683         Define in terms of long long int or int64_t or long int,
11684         not int64_t or int32_t.  This saves some compile-time testing.
11685         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
11686         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
11687         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
11688         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
11689         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
11690         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
11691         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
11692         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
11693         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
11694         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
11695         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
11696         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
11697         undef any previous version and define our own version, for
11698         simplicity and consistency with the new macros for types.
11699         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
11700         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
11701         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
11702         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
11703         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
11704         @WINT_T_SUFFIX@ to keep things simple here.
11705         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
11706         Simplify by assuming typical 8/16/32/64 host, since we're
11707         already doing that elsewhere anyway.
11708         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
11709         and assume long long int is 64 bits if available.  This
11710         speeds up 'configure'.
11711
11712 2006-07-01  Eric Blake  <ebb9@byu.net>
11713
11714         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
11715         Reported by Andreas Buening.
11716
11717 2006-07-01  Eric Blake  <ebb9@byu.net>
11718
11719         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
11720
11721 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
11722
11723         * lib/getaddrinfo.c: fixed typo
11724
11725 2006-06-29  Jim Meyering  <jim@meyering.net>
11726
11727         * modules/strftime (Maintainer): Add my name, since with the
11728         FPRINTFTIME changes strftime.c has forked from glibc.
11729
11730 2006-06-29  Eric Blake  <ebb9@byu.net>
11731
11732         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
11733
11734 2006-06-29  Eric Blake  <ebb9@byu.net>
11735
11736         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
11737
11738 2006-06-29  Eric Blake  <ebb9@byu.net>
11739
11740         * lib/stat_.h: New file.
11741
11742 2006-06-29  Eric Blake  <ebb9@byu.net>
11743
11744         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
11745         unused static function.
11746
11747 2006-06-29  Eric Blake  <ebb9@byu.net>
11748
11749         * doc/functions.texi (Function Portability): Document missing lstat
11750         on mingw.
11751
11752 2006-06-29  Eric Blake  <ebb9@byu.net>
11753
11754         * MODULES.html.sh: Add sys_stat.
11755         * modules/sys_stat: New module.
11756         * modules/mkstemp (Depends-on): Add sys_stat.
11757
11758 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11759
11760         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
11761
11762 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11763
11764         * m4/c-bs-a.m4: Removed.
11765
11766 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11767
11768         * lib/strftime.c: Assume strftime() exists.
11769
11770 2006-06-29  Derek Price  <derek@ximbiot.com>
11771
11772         * modules/c-bs-a: Removed - \a is C89.
11773         * MODULES.html.sh: Remove c-bs-a.
11774
11775 2006-06-29  Bruno Haible  <bruno@clisp.org>
11776
11777         * modules/wcwidth (License): Change to LGPL.
11778
11779 2006-06-28  Simon Josefsson  <jas@extundo.com>
11780
11781         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
11782         on _WIN32.
11783
11784         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
11785         getnameinfo.
11786
11787 2006-06-28  Simon Josefsson  <jas@extundo.com>
11788
11789         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
11790
11791 2006-06-28  Simon Josefsson  <jas@extundo.com>
11792
11793         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
11794         functions there.  It will succeed on Windows XP, but on Windows
11795         2000 and (presumably) earlier, it will fail, and use the internal
11796         re-implementation.
11797         (use_win32_p): New function.
11798         (getaddrinfo): Use strtoul on servname, to support numeric ports.
11799         Support AI_NUMERICSERV to disable getservbyname.
11800         (getnameinfo): New function, only supports
11801         NI_NUMERICHOST|NI_NUMERICSERV for now.
11802
11803         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
11804         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
11805         getnameinfo.
11806
11807 2006-06-28  Eric Blake  <ebb9@byu.net>
11808
11809         * modules/wcwidth: New file.
11810         * modules/mbchar (Depends-on): Add wcwidth.
11811         * modules/mbswidth (Depends-on): Add wcwidth.
11812         * MODULES.html.sh: Add wcwidth.
11813
11814 2006-06-28  Eric Blake  <ebb9@byu.net>
11815
11816         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
11817         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
11818
11819 2006-06-28  Eric Blake  <ebb9@byu.net>
11820
11821         * lib/xvasprintf.h: Fix comments.
11822
11823 2006-06-28  Eric Blake  <ebb9@byu.net>
11824
11825         * lib/mbchar.h (wcwidth): Include wcwidth.h.
11826         * lib/mbswidth.c (wcwidth): Move from here...
11827         * lib/wcwidth.h: ...to this new file.
11828
11829 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11830
11831         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
11832
11833         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
11834         it's obsolete.
11835         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
11836
11837 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11838
11839         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
11840         Autoconf 2.60 says this stuff was obsolete.
11841
11842 2006-06-28  Bruno Haible  <bruno@clisp.org>
11843
11844         * modules/wcwidth (Files): Add m4/wchar_t.m4.
11845
11846 2006-06-28  Bruno Haible  <bruno@clisp.org>
11847
11848         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
11849         gt_TYPE_WCHAR_T.
11850
11851 2006-06-28  Bruno Haible  <bruno@clisp.org>
11852
11853         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
11854         declaration for wcwidth.
11855         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
11856
11857 2006-06-28  Bruno Haible  <bruno@clisp.org>
11858
11859         * lib/mkdtemp.c [MINGW]: Include <io.h>.
11860         (mkdir): Define using _mkdir.
11861
11862 2006-06-28  Bruno Haible  <bruno@clisp.org>
11863
11864         * lib/getaddrinfo.h: Fix POSIX URL.
11865         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
11866         _WIN32.
11867         (use_win32_p): Make static.
11868         (getaddrinfo): Reject service name if it is empty or does not consist
11869         solely of decimal digits, or if its value is > 65535.
11870         (getnameinfo): Remove useless casts.
11871
11872 2006-06-27  Simon Josefsson  <jas@extundo.com>
11873
11874         * modules/sys_select: New file, suggested by Bruno Haible, Paul
11875         Eggert and Martin Lambers.
11876
11877 2006-06-27  Simon Josefsson  <jas@extundo.com>
11878
11879         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
11880         Eggert and Martin Lambers.
11881
11882 2006-06-27  Bruno Haible  <bruno@clisp.org>
11883
11884         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
11885         result to 0, not to empty.
11886         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
11887
11888 2006-06-27  Bruno Haible  <bruno@clisp.org>
11889
11890         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
11891
11892 2006-06-26  Simon Josefsson  <jas@extundo.com>
11893
11894         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
11895         present.
11896
11897 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
11898
11899         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
11900         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
11901         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
11902
11903 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
11904
11905         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
11906
11907 2006-06-26  Bruno Haible  <bruno@clisp.org>
11908
11909         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
11910
11911 2006-06-26  Bruno Haible  <bruno@clisp.org>
11912
11913         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
11914
11915 2006-06-26  Bruno Haible  <bruno@clisp.org>
11916
11917         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
11918         SGI C compiler in pre-C99 mode.
11919         Suggested by Mark D. Baushke and Larry Jones.
11920
11921 2006-06-26  Bruno Haible  <bruno@clisp.org>
11922
11923         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
11924         WCHAR_MAX.
11925         Reported by Mark D. Baushke and Larry Jones.
11926
11927 2006-06-26  Bruno Haible  <bruno@clisp.org>
11928
11929         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
11930         in pre-C99 mode.
11931         Suggested by Mark D. Baushke and Larry Jones.
11932
11933 2006-06-23  Simon Josefsson  <jas@extundo.com>
11934             Bruno Haible  <bruno@clisp.org>
11935
11936         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
11937         Emit mostlyclean-local rule.
11938         (func_emit_tests_Makefile_am): Likewise.
11939         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
11940
11941 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
11942
11943         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
11944
11945 2006-06-23  Bruno Haible  <bruno@clisp.org>
11946
11947         * tests/test-stdint.c: Update to match ISO C 99 Technical
11948         Corrigendum 1.
11949
11950 2006-06-23  Bruno Haible  <bruno@clisp.org>
11951
11952         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
11953
11954 2006-06-23  Bruno Haible  <bruno@clisp.org>
11955
11956         * lib/stdint_.h: Treat IRIX like OpenBSD.
11957
11958 2006-06-23  Bruno Haible  <bruno@clisp.org>
11959
11960         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
11961         ISO C 99 Technical Corrigendum 1.
11962
11963 2006-06-22  Simon Josefsson  <jas@extundo.com>
11964
11965         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
11966         MinGW.
11967
11968 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11969
11970         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
11971         needed.  Some compiler complained about some of them.  Problem reported
11972         by Larry Jones in
11973         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
11974
11975 2006-06-21  Simon Josefsson  <jas@extundo.com>
11976
11977         * tests/test-getaddrinfo.c: New file.
11978
11979         * modules/getaddrinfo-tests: New file.
11980
11981         * MODULES.html.sh: Add inet_pton.
11982
11983         * modules/inet_pton: New file.
11984
11985 2006-06-21  Simon Josefsson  <jas@extundo.com>
11986
11987         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
11988         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
11989         of using the (limited) gnulib implementation on Windows XP.
11990
11991         * m4/inet_pton.m4: New file.
11992
11993 2006-06-21  Simon Josefsson  <jas@extundo.com>
11994
11995         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
11996         variable.
11997
11998         * lib/socket_.h: Don't define WINVER.
11999
12000         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
12001         slightly modified to work in gnulib.
12002
12003 2006-06-21  Simon Josefsson  <jas@extundo.com>
12004
12005         * doc/gnulib.texi (Windows sockets): Add.
12006
12007 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
12008
12009         * lib/read-file.c (fread_file): Start with buffer allocation of
12010         0 bytes rather than 1 byte; this simplifies the code.
12011         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
12012         code to free buffer and save/restore errno.
12013         (internal_read_file): Remove unused local.
12014
12015 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
12016
12017         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
12018         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
12019         Problem reported by Denis Excoffier in
12020         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
12021
12022 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12023
12024         * modules/sys_socket, modules/socklen: Include sys/types since
12025         FreeBSD 4.x's sys/socket.h needs it.
12026
12027 2006-06-19  Simon Josefsson  <jas@extundo.com>
12028
12029         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
12030
12031 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
12032
12033         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
12034
12035 2006-06-19  Bruno Haible  <bruno@clisp.org>
12036
12037         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
12038         and FULL_PATH_INTTYPES_H in angle brackets.
12039         Reported by Mark D. Baushke <mdb@gnu.org>.
12040
12041 2006-06-17  Eric Blake  <ebb9@byu.net>
12042
12043         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
12044         errno.
12045
12046 2006-06-17  Bruno Haible  <bruno@clisp.org>
12047
12048         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
12049         <sys/inttypes.h>.
12050
12051 2006-06-17  Bruno Haible  <bruno@clisp.org>
12052
12053         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
12054         whether errno is declared. Assume <errno.h> declares errno.
12055
12056 2006-06-17  Bruno Haible  <bruno@clisp.org>
12057
12058         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
12059
12060 2006-06-17  Bruno Haible  <bruno@clisp.org>
12061
12062         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
12063         problem on Solaris 2.5.1.
12064
12065 2006-06-16  Eric Blake  <ebb9@byu.net>
12066
12067         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
12068         * lib/unicodeio.c [!defined errno]: Likewise.
12069         * lib/strtol.c [!defined errno]: Likewise.
12070         * lib/strtod.c [!defined errno]: Likewise.
12071
12072 2006-06-15  Eric Blake  <ebb9@byu.net>
12073
12074         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
12075
12076 2006-06-15  Eric Blake  <ebb9@byu.net>
12077
12078         * config/srclist.txt (ssize_t.m4): Lose sync.
12079
12080 2006-06-15  Bruno Haible  <bruno@clisp.org>
12081
12082         * modules/stdint (Files): Include m4/full-header-path.m4,
12083         m4/size_max.m4, m4/wchar_t.m4.
12084         (Makefile.am): Many more substitutions.
12085         * modules/stdint-tests: New file.
12086         * tests/test-stdint.c: New file.
12087
12088 2006-06-15  Bruno Haible  <bruno@clisp.org>
12089
12090         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
12091         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
12092         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
12093         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
12094         gl_CHECK_TYPE_SAME): New macros.
12095
12096 2006-06-15  Bruno Haible  <bruno@clisp.org>
12097
12098         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
12099
12100 2006-06-15  Bruno Haible  <bruno@clisp.org>
12101
12102         * lib/stdint_.h: Rewritten to be fully auto-configured.
12103         Fixes bug on HP-UX/IA64.
12104
12105 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
12106
12107         * lib/getdate.y (__attribute__): Don't define if already defined.
12108         Problem reported by Larry Jones.
12109         * lib/utimens.c (__attribute__): Likewise.
12110
12111 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
12112
12113         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
12114         reported by Andreas Schwab.
12115
12116 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12117             Bruno Haible  <bruno@clisp.org>
12118
12119         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
12120         check for the declaration of strnlen and a run test that exposes the
12121         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
12122         rpl_strndup.
12123
12124 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12125             Bruno Haible  <bruno@clisp.org>
12126
12127         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
12128
12129 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12130
12131         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
12132         compile test, for Tru64 4.0D.
12133
12134 2006-05-28  Karl Berry  <karl@gnu.org>
12135
12136         * config/srclist.txt (printf-args.c): lose sync.
12137
12138 2006-05-26  Martin Lambers  <marlam@marlam.de>
12139
12140         * lib/getpass.c: Updates the test for the native W32 API, and adds
12141         missing includes, thus fixing compilation warnings.
12142
12143 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
12144
12145         * lib/exclude.c (exclude_fnmatch): New function.
12146         (excluded_file_name): Call exclude_fnmatch.
12147         * lib/exclude.h (excluded_file_name): New prototype
12148
12149 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
12150
12151         * lib/tempname.c (small_open, large_open): New macros.
12152         (__open, __open64) [!_LIBC]: Remove.
12153         (__gen_tempname): Use small_open and large_open instead of __open
12154         and __open64.  This fixes a portability bug on HP-UX 11.11i
12155         reported by Simon Wing-Tang in
12156         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
12157
12158 2006-05-24  Bruno Haible  <bruno@clisp.org>
12159
12160         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
12161         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
12162         Reported by Thorsten Maerz <torte@netztorte.de> via
12163         Aaron Stone <aaron@serendipity.cx>.
12164
12165 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
12166
12167         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
12168         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
12169         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
12170         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
12171         not really conditional on the cache.
12172         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
12173
12174 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
12175
12176         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
12177         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
12178         (my_usleep): Don't mishandle maximum value.
12179
12180 2006-05-19  Jim Meyering  <jim@meyering.net>
12181
12182         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
12183
12184 2006-05-17  Bruno Haible  <bruno@clisp.org>
12185
12186         Cygwin portability.
12187         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
12188
12189 2006-05-17  Bruno Haible  <bruno@clisp.org>
12190
12191         * lib/stdint_.h: Fix recognition of Cygwin.
12192
12193 2006-05-15  Bruno Haible  <bruno@clisp.org>
12194
12195         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
12196         on libtool patch by Ralf Wildenhues.
12197
12198 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12199
12200         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
12201         test for C99 conformance; (bool) 0.5 is an integer constant
12202         expression, but (bool) -0.5 is not.  Problem reported by Fedor
12203         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
12204
12205 2006-05-11  Simon Josefsson  <jas@extundo.com>
12206
12207         * m4/xvasprintf.m4: Fix obvious typo.
12208
12209 2006-05-11  Jim Meyering  <jim@meyering.net>
12210
12211         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
12212         James Lemley.
12213
12214 2006-05-10  Simon Josefsson  <jas@extundo.com>
12215
12216         * lib/md4.c: Typo fix, update copyright years.
12217         (K1, K2): Don't use L because it turn computations into 64-bit on
12218         64-bit platforms.
12219
12220 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
12221
12222         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
12223         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
12224         unwanted sign propagation, e.g., on hosts with 64-bit int.
12225         There still are some problems with reeelly weird theoretical hosts
12226         (e.g., 33-bit int) but it's not worth worrying about now.
12227         * lib/sha1.c (rol): Likewise.
12228         (K1, K2, K3, K4): Remove unnecessary L suffix.
12229
12230 2006-05-10  Bruno Haible  <bruno@clisp.org>
12231
12232         * lib/des.c: Cast to avoid warnings.
12233
12234 2006-05-09  Bruno Haible  <bruno@clisp.org>
12235
12236         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
12237         (Depends-on): Depend also on xsize, stdarg.
12238         (configure.ac): Add gl_XVASPRINTF.
12239
12240 2006-05-09  Bruno Haible  <bruno@clisp.org>
12241
12242         * m4/xvasprintf.m4: New file.
12243
12244 2006-05-09  Bruno Haible  <bruno@clisp.org>
12245
12246         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
12247         (EOVERFLOW): Define fallback value.
12248         (xstrcat): New function.
12249         (xvasprintf): Recognize the special case of a string concatenation.
12250
12251 2006-05-08  Eric Blake  <ebb9@byu.net>
12252
12253         * gnulib-tool (func_version): Base copyright year on CVS date.
12254         (func_emit_copyright_notice): New function.
12255         (func_emit_lib_Makefile_am): Use it.
12256         (func_emit_tests_Makefile_am): Likewise.
12257         (func_import): Likewise.
12258
12259 2006-05-08  Bruno Haible  <bruno@clisp.org>
12260
12261         * modules/stdarg: New file.
12262         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
12263
12264 2006-05-08  Bruno Haible  <bruno@clisp.org>
12265
12266         * m4/stdarg.m4: New file, from GNU gettext.
12267
12268 2006-05-08  Bruno Haible  <bruno@clisp.org>
12269
12270         * config/srclist.txt (build-aux/config.rpath): different from latest
12271         release.
12272
12273 2006-05-08  Bruno Haible  <bruno@clisp.org>
12274
12275         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
12276
12277 2006-05-05  Jim Meyering  <jim@meyering.net>
12278
12279         * m4/warning.m4: New file, derived from bison's file by the same name.
12280
12281 2006-05-03  Bruno Haible  <bruno@clisp.org>
12282
12283         * lib/stdint_.h: Shorter URL.
12284         * lib/inttypes.h: Likewise.
12285
12286 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12287
12288         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
12289
12290 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12291
12292         * lib/verify.h: Document the internals better.  Most of this change
12293         was written by Bruno Haible.
12294
12295 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12296
12297         * doc/verify.texi: New file, partly based on a proposal by
12298         Bruno Haible.
12299
12300 2006-05-02  Bruno Haible  <bruno@clisp.org>
12301
12302         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
12303         test from here...
12304         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
12305
12306 2006-04-29  Bruno Haible  <bruno@clisp.org>
12307
12308         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
12309         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
12310
12311 2006-04-29  Bruno Haible  <bruno@clisp.org>
12312
12313         * gnulib-tool: Make --update option actually work.
12314
12315 2006-04-29  Bruno Haible  <bruno@clisp.org>
12316
12317         * doc/gcd.texi: New file.
12318         * doc/gnulib.texi: Include it.
12319
12320 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
12321
12322         * lib/getdate.y (get_date): When adding relative date, start with the
12323         initial time, not with the result of the first mktime call.
12324
12325 2006-04-25  Bruno Haible  <bruno@clisp.org>
12326
12327         * gnulib-tool (func_import): Output the include directives in three
12328         blocks, sorted separately.
12329         Reported by Ben Pfaff <blp@cs.stanford.edu>.
12330
12331 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
12332
12333         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
12334         to define main with arguments, for C++.  Reported by Eric Blake.
12335         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
12336         Prefer 'int main ()' to 'int main (void)', for C++.
12337         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
12338         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
12339         for 'main', for C99 and C++.
12340
12341 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
12342
12343         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
12344         Don't assume that exit status -1 is valid.
12345         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
12346         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
12347         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
12348         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
12349         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
12350         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
12351         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
12352         functions can be used without declaring them, or that you can
12353         exit with status -1.
12354         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
12355
12356 2006-04-24  Karl Berry  <karl@gnu.org>
12357
12358         * config/srclist.txt (longdouble.m4): sync lost.
12359
12360 2006-04-24  Eric Blake  <ebb9@byu.net>
12361
12362         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
12363
12364 2006-04-24  Bruno Haible  <bruno@clisp.org>
12365
12366         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
12367         poll() implementation in AIX.
12368         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12369
12370 2006-04-24  Bruno Haible  <bruno@clisp.org>
12371
12372         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
12373         assigned exactly once.
12374
12375 2006-04-23  Claudio Fontana  <claudio@gnu.org>
12376             Bruno Haible  <bruno@clisp.org>
12377
12378         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
12379         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
12380         for AM_CPPFLAGS.
12381
12382 2006-04-23  Bruno Haible  <bruno@clisp.org>
12383
12384         * modules/copy-file: Depend on unistd.
12385         * modules/execute: Likewise.
12386         * modules/fatal-signal: Likewise.
12387         * modules/findprog: Likewise.
12388         * modules/mkdtemp : Likewise.
12389         * modules/pipe: Likewise.
12390         * modules/wait-process: Likewise.
12391
12392 2006-04-23  Bruno Haible  <bruno@clisp.org>
12393
12394         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
12395         condition was already detected.
12396         Reported by Ben Pfaff <blp@cs.stanford.edu>.
12397
12398 2006-04-23  Bruno Haible  <bruno@clisp.org>
12399
12400         * lib/copy-file.c: Include <unistd.h> unconditionally.
12401         * lib/execute.c: Likewise.
12402         * lib/fatal-signal.c: Likewise.
12403         * lib/findprog.c: Likewise.
12404         * lib/mkdtemp.c: Likewise.
12405         * lib/pipe.h: Likewise.
12406         * lib/pipe.c: Likewise.
12407         * lib/wait-process.h: Likewise.
12408
12409 2006-04-23  Bruno Haible  <bruno@clisp.org>
12410
12411         * gnulib-tool (func_usage): Fix --import description. Document
12412         --update.
12413         (func_import): Create temporary file in a temporary directory, if
12414         --dry-run is specified. Silence errors from 'grep' when there are no
12415         m4 files in $m4dir.
12416         (func_create_testdir): Silence errors from 'grep' when there are no
12417         m4 files in $m4dir.
12418         Reported by Karl Berry <karl@freefriends.org>.
12419
12420 2006-04-20  Bruno Haible  <bruno@clisp.org>
12421
12422         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
12423         one argument, so that the code will be portable to Autoconf 2.60.
12424         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
12425         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
12426         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
12427
12428 2006-04-19  Derek Price  <derek@ximbiot.com>
12429             Eric Blake  <ebb9@byu.net>
12430
12431         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
12432         rather than "/full/path.h".  Update comment to match.  Shorten &
12433         generalize m4_translit call via AS_TR_CPP.
12434
12435 2006-04-19  Derek Price  <derek@ximbiot.com>
12436             Eric Blake  <ebb9@byu.net>
12437
12438         * lib/inttypes.h: Correct grammar in comment.
12439
12440 2006-04-18  Derek Price  <derek@ximbiot.com>
12441             Paul Eggert  <eggert@cs.ucla.edu>
12442
12443         * modules/inttypes: New file.
12444         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
12445
12446 2006-04-18  Derek Price  <derek@ximbiot.com>
12447             Paul Eggert  <eggert@cs.ucla.edu>
12448
12449         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
12450         New files.
12451
12452 2006-04-18  Derek Price  <derek@ximbiot.com>
12453             Paul Eggert  <eggert@cs.ucla.edu>
12454
12455         * lib/inttypes.h: New file.
12456         * lib/strtoimax.c: Assume <inttypes.h>.
12457
12458 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
12459
12460         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
12461         isn't mounted.  Problem reported by Kir Kolyshkin.
12462
12463 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12464
12465         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
12466         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
12467         Derek R. Price.
12468         * lib/regex.h (RE_DUP_MAX): Update comment to match current
12469         implementation.
12470
12471 2006-04-12  Eric Blake  <ebb9@byu.net>
12472
12473         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
12474         is now done automatically by the corresponding Autoconf macro.
12475
12476 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
12477
12478         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
12479         time_r.h.
12480
12481 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12482
12483         Merge regex changes from libc, removing some of our
12484         POSIX-conformance changes that were rejected and redoing them in a
12485         less-intrusive way.
12486
12487         * lib/regcomp.c (re_compile_internal, init_dfa):
12488         Length arg is now size_t, not Idx.  All uses changed.
12489         (peek_token): Forward decl now says internal_function.
12490         (__re_error_msgid, __re_error_msgid_idx):
12491         Now static rather than extern with attribute_hidden.
12492         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
12493         For some reason libc prefers K&R style defns for external functions.
12494         (regerror) [!defined _LIBC]: Likewise.
12495         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
12496         (seek_collating_symbol_entry, lookup_collation_sequence_value):
12497         (build_range_exp, build_collating_symbol):
12498         Use K&R-style defn.
12499         (re_compile_fastmap): Use '\0' to memset, not 0.
12500         (utf8_sb_map): Make the calculations more obvious.
12501         (init_dfa, parse_bracket_exp, build_charclass_op):
12502         Call calloc and cast result, as glibc does.
12503         (init_word_char, fetch_token, peek_token, peek_token_bracket):
12504         (build_range_exp, build_collating_symbol):
12505         Now internal functions.
12506
12507         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
12508
12509         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
12510         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
12511         Don't depend on VMS; depend on __VMS instead, for POSIX
12512         namespace cleanness.
12513         (regoff_t): Define to ssize_t, not long int.
12514
12515         Remove the REG_ macros named below.  Instead, make the old names
12516         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
12517         __USE_GNU_REGEX.
12518         (REG_BACKSLASH_ESCAPE_IN_LISTS):
12519         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
12520         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
12521         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
12522         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
12523         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
12524         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
12525         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
12526         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
12527         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
12528         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
12529         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
12530         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
12531         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
12532         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
12533         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
12534         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
12535         (REG_NREGS):
12536         Remove.  All uses replaced by the old RE_* names.
12537         (RE_BACKSLASH_ESCAPE_IN_LISTS):
12538         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
12539         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
12540         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
12541         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
12542         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
12543         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
12544         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
12545         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
12546         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
12547         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
12548         Don't bother having these macros be independent of each others'
12549         values, since they no longer exist in the POSIX name space.
12550
12551         Rename the following member names back to their old names,
12552         unless !__USE_GNU_REGEX.  All uses changed back.
12553         (buffer): Renamed from re_buffer.
12554         (allocated): Renamed from re_allocated.
12555         (used): Renamed from re_used.
12556         (syntax): Renamed from re_syntax.
12557         (fastmap): Renamed from re_fastmap.
12558         (translate): Renamed from re_translate.
12559         (can_be_null): Renamed from re_can_be_null.
12560         (regs_allocated): Renamed from re_regs_allocated.
12561         (fastmap_accurate): Renamed from re_fastmap_accurate.
12562         (no_sub): Renamed from re_no_sub.
12563         (not_bol): Renamed from re_not_bol.
12564         (not_eol): Renamed from re_not_eol.
12565         (newline_anchor): Renamed from re_newline_anchor.
12566         (num_regs): Renamed from rm_num_regs.
12567         (start): Renamed from rm_start.
12568         (end): Renamed from rm_end.
12569
12570         (free_state): Move up a bit.
12571
12572         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
12573         #define to be empty.
12574         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
12575         when that is what is intended.
12576         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
12577         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
12578         (MAX): New macro.
12579         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
12580         All uses changed back to re_malloc, etc.  It's now the caller's
12581         responsibility to check for overflow; all callers changed.
12582         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
12583         (re_x2nrealloc): Remove.
12584         (free_state): Remove decl.
12585
12586         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
12587         (re_set_registers, re_exec):
12588         Use K&R-style defn.
12589
12590         2006-01-31  Roland McGrath  <roland@redhat.com>
12591
12592         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
12593         Reported by Mike Frysinger <vapier@gentoo.org>.
12594
12595         2006-01-15  Andreas Jaeger  <aj@suse.de>
12596
12597         [BZ #1950]
12598         * lib/regex_internal.c (re_string_reconstruct): Adjust for
12599         build_wcs_upper_buffer change.
12600         (build_wcs_upper_buffer): Change return type.
12601
12602         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
12603
12604         * lib/regex_internal.h: Include <stdint.h> if available.
12605
12606         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
12607
12608         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
12609
12610         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
12611
12612         * lib/regcomp.c: Adjust for changed secondary hash function.
12613
12614         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
12615
12616         * lib/regex.h: Pretty printing.
12617         Clean up namespace a bit.
12618
12619         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
12620
12621         * lib/regexec.c (update_cur_sifted_state, check_arrival,
12622         check_arrival_add_next_nodes): Avoid using uninitialized variable.
12623
12624         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
12625                     Ulrich Drepper  <drepper@redhat.com>
12626
12627         [BZ #1302]
12628         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
12629         changed.
12630         (bitset_word_t): Renamed from bitset_word.  All uses changed.
12631
12632         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
12633
12634         [BZ #281]
12635         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
12636         * lib/regcomp.c: Remove unnecessary uses of
12637         unsigned RE_TRANSLATE_TYPE.
12638         * lib/regex_internal.h: Likewise.
12639         * lib/regex_internal.c: Likewise.
12640         * lib/regexec.c: Likewise.
12641         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
12642
12643         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
12644
12645         * lib/regexec.c (find_recover_state): Remove unnecessary
12646         initialization.
12647         (transit_state_bkref): Make DFA a const pointer.
12648         (get_subexp): Likewise.
12649         (check_arrival): Likewise.
12650         (update_cur_sifted_state): Likewise.
12651         (re_search_internal): Likewise.
12652         (prune_impossible_nodes): Likewise.
12653         (acquire_init_state_context): Likewise.
12654         (proceed_next_node): Likewise.
12655         (set_regs): Likewise.
12656         (free_fail_stack_return): Likewise.
12657         (check_arrival_expand_ecl): Mark DFA parameter as const.
12658         (check_arrival_expand_ecl_sub): Likewise.
12659         (check_subexp_limits): Likewise.
12660         (sub_epsilon_src_nodes):  Likewise.
12661         (add_epsilon_src_nodes):  Likewise.
12662         (merge_state_array): Likewise.
12663         (update_regs): Likewise.
12664         (build_trtable): Likewise.
12665         (sift_states_backward): Mark MCTX parameter as const.
12666         (build_sifted_states): Likewise.
12667         (update_cur_sifted_state): Likewise.
12668         (sift_states_mkref): Likewise.
12669         (check_arrival_expand_ecl): Mark eclosure as const.
12670         (check_dst_limits_calc_pos_1): Likewise.
12671         * lib/regex_internal.h (re_match_context_t): Make dfa a const
12672         pointer.
12673
12674         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
12675
12676         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
12677         (transit_state_sb): Likewise.
12678         (transit_state_mb): Likewise.
12679         (sift_states_iter_mb): Likewise.
12680         (check_arrival_add_next_nodes): Likewise.
12681         (check_node_accept_bytes): Change first parameter to pointer-to-const.
12682         [_LIBC] (re_search_2_stub): Use mempcpy.
12683
12684         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
12685         mbrtowc for very simple UTF-8 case.
12686
12687         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
12688         a pointer-to-const.
12689         (re_acquire_state_context): Likewise.
12690         * lib/regex_internal.h: Adjust prototypes.
12691
12692         * lib/regex.c: Prevent using C++ compilers.
12693
12694         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
12695         (re_acquire_state_context): Likewise.
12696
12697 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12698
12699         * modules/regex (Depends-on): Add ssize_t.
12700
12701 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12702
12703         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
12704         translation table.
12705
12706 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12707
12708         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
12709
12710 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
12711             Bruno Haible  <bruno@clisp.org>
12712
12713         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
12714         <sys/types.h> and <inttypes.h>.
12715
12716 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12717
12718         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
12719         `__error_t_defined', so argp.h will not typedef the former.
12720
12721 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
12722
12723         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
12724         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
12725         glibc names.  Even if glibc is changed to conform to POSIX, the
12726         traditional names will be available anyway, since regex depends on
12727         the extensions module.  Also, fix a longstanding typo in the
12728         implementation of Spencer ERE test #75 from grep 2.3.  Problems
12729         reported by Emanuele Giaquinta.  Also, change sense of cached
12730         variable, so that the message makes sense.
12731
12732 2006-03-24  Simon Josefsson  <jas@extundo.com>
12733
12734         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
12735         including some doc fixes.
12736         (base64_encode_alloc): Fix +1 bug on allocation failures.
12737
12738 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12739
12740         * lib/base64.c (base64_encode): Do not read past end of array with
12741         unsanitized input on systems with CHAR_BIT > 8.
12742
12743 2006-03-24  Eric Blake  <ebb9@byu.net>
12744
12745         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
12746
12747 2006-03-22  Karl Berry  <karl@gnu.org>
12748
12749         * config/srclist.txt (*setenv.[ch]): get from coreutils.
12750         * config/srclistvars.sh (COREUTILS): new var.
12751
12752 2006-03-17  Jim Meyering  <jim@meyering.net>
12753
12754         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
12755         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
12756
12757 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
12758
12759         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
12760         no longer needs it.  Instead, check that regoff_t is as least
12761         as wide as ptrdiff_t.
12762
12763         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
12764         so that our regex.h stays compatible with the installed regex.
12765         This is helpful for installers who configure --without-included-regex.
12766         Problem reported by Emanuele Giaquinta.
12767
12768 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
12769
12770         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
12771         Typedef to long int, not to off_, as POSIX will likely change
12772         in that direction.
12773
12774 2006-03-15  Eric Blake  <ebb9@byu.net>
12775
12776         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
12777
12778 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
12779
12780         * lib/argp-help.c (validate_uparams): Fix typo
12781         * lib/argp-parse.c (argp_default_options): Consistently begin help
12782         messages with a lowercase letter.
12783
12784 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
12785
12786         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
12787         overrun buffers and shouldn't be used (much as gets shouldn't be
12788         used).
12789         * lib/time_r.c (asctime_r, ctime_r): Likewise.
12790
12791 2006-03-08  Simon Josefsson  <jas@extundo.com>
12792
12793         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
12794         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12795
12796 2006-03-08  Simon Josefsson  <jas@extundo.com>
12797
12798         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
12799         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12800
12801 2006-03-08  Simon Josefsson  <jas@extundo.com>
12802
12803         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
12804         signal that configure disabled the device.
12805
12806 2006-03-08  Simon Josefsson  <jas@extundo.com>
12807
12808         * build-aux/maint.mk: Fix refresh-po, to handle no translated
12809         languages.
12810
12811 2006-03-07  Simon Josefsson  <jas@extundo.com>
12812
12813         * modules/getopt (Depends-on): Add unistd.
12814
12815         * modules/unistd: New file.
12816
12817 2006-03-07  Simon Josefsson  <jas@extundo.com>
12818
12819         * modules/gc-random: New file.
12820
12821 2006-03-07  Simon Josefsson  <jas@extundo.com>
12822
12823         * m4/unistd_h.m4: New file.
12824
12825 2006-03-07  Simon Josefsson  <jas@extundo.com>
12826
12827         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
12828         test to be side-effect free by storing the result in the cache
12829         variable gl_cv_lib_readline, and moving the assignment of
12830         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
12831         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12832
12833 2006-03-07  Simon Josefsson  <jas@extundo.com>
12834
12835         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
12836         error on missing devices (the functions will return an error).
12837
12838         * m4/gc.m4: Move random stuff to gc-random.m4
12839
12840 2006-03-07  Simon Josefsson  <jas@extundo.com>
12841
12842         * lib/unistd_.h: New file.
12843
12844 2006-03-07  Simon Josefsson  <jas@extundo.com>
12845
12846         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
12847
12848 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12849
12850         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
12851         Problem reported by Juan Manuel Guerrero.
12852
12853 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12854
12855         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
12856         the unistd module.
12857         * lib/getlogin_r.c: Likewise.
12858         * lib/getlogin_r.h: Likewise.
12859         * lib/glob.c: Likewise.
12860         * lib/pagealign_alloc.c: Likewise.
12861         * lib/unistd_.h: Remove; no longer needed.
12862
12863 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12864
12865         * MODULES.html.sh (Support for systems lacking POSIX:2001):
12866         Add unistd.
12867         * modules/c-stack (Depends-on): Add unistd.
12868         * modules/getlogin_r: Likewise.
12869         * modules/glob: Likewise.
12870         * modules/pagealign_alloc: Likewise.
12871         * modules/unistd (Files): Remove lib/unistd_.h.
12872         (EXTRA_DIST): Remove.
12873         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
12874         need unistd_.h.
12875         (MOSTLYCLEANFILES): Remove unistd.h-t.
12876
12877 2006-03-03  Simon Josefsson  <jas@extundo.com>
12878
12879         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
12880
12881 2006-03-03  Simon Josefsson  <jas@extundo.com>
12882
12883         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
12884         libidn and bison.
12885
12886 2006-03-03  Simon Josefsson  <jas@extundo.com>
12887
12888         * build-aux/maint.mk: Add indent target.
12889
12890 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
12891
12892         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
12893         our replacement poll.h in any case, to avoid a differing
12894         declaration from a system header.  Seen on AIX.
12895
12896 2006-03-01  Simon Josefsson  <jas@extundo.com>
12897
12898         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
12899         <kasal@ucw.cz>.
12900
12901 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12902
12903         * modules/gettime (Depends-on): Add extensions module.
12904         * modules/nanosleep (Depends-on): Likewise.
12905         * modules/settime (Depends-on): Likewise.
12906
12907 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12908
12909         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
12910         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
12911         pedantically.
12912         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
12913         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
12914
12915         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
12916         not "==".  Reported by Ralf Wildenhues.
12917
12918 2006-03-01  Karl Berry  <karl@gnu.org>
12919
12920         * doc/Copyright/request-*: new files, synced from gnuorg.
12921
12922 2006-03-01  Karl Berry  <karl@gnu.org>
12923
12924         * config/srclist.txt (Copyright/*): new entries.
12925
12926 2006-02-28  Simon Josefsson  <jas@extundo.com>
12927
12928         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
12929
12930 2006-02-27  Simon Josefsson  <jas@extundo.com>
12931
12932         * lib/base64.h: Indent #define's.  From Jim Meyering
12933         <jim@meyering.net>.
12934
12935 2006-02-27  Jim Meyering  <jim@meyering.net>
12936
12937         Revert the change of 2006-02-24, so these files can continue
12938         to be sync'd from gettext.
12939         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
12940         of `config.h'.
12941
12942 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
12943
12944         * modules/intprops: New file.
12945         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
12946         Add intprops.
12947         * modules/getloadavg (Files): Remove lib/intprops.h.
12948         (Depends-on): Add intprops.
12949         * modules/human: Likewise.
12950         * modules/inttostr: Likewise.
12951         * modules/openat: Likewise.
12952         * modules/sig2str: Likewise.
12953         * modules/userspec: Likewise.
12954         * modules/utimecmp: Likewise.
12955         * modules/xnanosleep: Likewise.
12956         * modules/xstrtol: Likewise.
12957
12958 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
12959
12960         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
12961         * modules/lock-tests (TESTS): Use $(EXEEXT).
12962         * modules/tls-tests: Likewise.
12963         * modules/argp-tests: Likewise.
12964         (check_PROGRAMS): New var, replacing...
12965         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
12966
12967 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12968
12969         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
12970         `config.h'.
12971
12972 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
12973
12974         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
12975
12976 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12977
12978         Sync from coreutils.
12979         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
12980         gl_CHDIR_SAFER.
12981
12982 2006-02-22  Jim Meyering  <jim@meyering.net>
12983
12984         Sync from coreutils.
12985         * m4/chdir-safer.m4: New file.
12986
12987 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
12988
12989         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
12990         AT_FDCWD exceeds INT_MAX.
12991         * lib/openat.h (AT_FDCWD): Likewise.
12992
12993 2006-02-17  Eric Blake  <address@hidden>
12994
12995         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
12996
12997 2006-02-16  Simon Josefsson  <jas@extundo.com>
12998
12999         * modules/getaddrinfo (Depends-on): Add sys_socket.
13000
13001 2006-02-15  Simon Josefsson  <jas@extundo.com>
13002
13003         * build-aux/maint.mk: Add dsyntax-check rule.
13004
13005 2006-02-15  Eric Blake  <ebb9@byu.net>
13006
13007         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
13008         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
13009         'present but cannot compile' warnings on cygwin.
13010         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
13011         use ws2tcpip.h if sys/socket.h works.
13012         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
13013         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
13014
13015 2006-02-14  Simon Josefsson  <jas@extundo.com>
13016
13017         * modules/maintainer-makefile (Files): Rename.
13018
13019         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
13020         and (the local) Makefile.cfg to maint-cfg.mk.
13021
13022         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
13023         to the latter.
13024
13025         * modules/maintainer-makefile: New module.
13026
13027         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
13028         severaly stripped to make it possible to build it up from scratch
13029         with reliable tests.
13030
13031         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
13032         fixes to permit overriding the default actions when configure and
13033         makefile are not available.
13034
13035 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
13036
13037         Sync from coreutils.
13038         * modules/lstat (Depends-on): Don't depend on xalloc.
13039         (License): Change from GPL to LGPL, since this is now simply a
13040         replacement for a libc function.
13041
13042 2006-02-14  Jim Meyering  <jim@meyering.net>
13043
13044         Sync from coreutils.
13045
13046         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
13047         failure on deficient systems, and simplify gnulib lgpl dependencies.
13048         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
13049         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
13050
13051         * lib/xalloc-die.c: Remove unused definition of N_.
13052
13053 2006-02-14  Jim Meyering  <jim@meyering.net>
13054
13055         Sync from coreutils.
13056         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
13057         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
13058         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
13059         double-quote uses of that variable, to accommodate the rare case in
13060         which getmntent is available in none of the libraries checked.  This
13061         happens at least on FreeBSD 5.0.
13062
13063 2006-02-13  Simon Josefsson  <jas@extundo.com>
13064
13065         * gnulib-tool (Usage): Fix --import, from
13066         karl@freefriends.org (Karl Berry).
13067
13068 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
13069
13070         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
13071
13072 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
13073
13074         * lib/argp-namefrob.h: Restore changes accidentally lost during the
13075         "autoupdate" on 2005-12-12.
13076
13077 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
13078
13079         * modules/closeout (Depends-on): Remove atexit.
13080
13081 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
13082
13083         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
13084         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
13085
13086 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
13087
13088         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
13089         __EXTENSIONS__ if this causes compilation to fail.  Problem
13090         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
13091         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
13092
13093 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
13094
13095         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
13096         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
13097         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
13098         All uses changed.
13099
13100 2006-01-26  Simon Josefsson  <jas@extundo.com>
13101
13102         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
13103         prototype is visible on mingw32.
13104
13105         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
13106         for mingw32.
13107
13108         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
13109         mingw32).
13110
13111 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
13112
13113         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
13114         attempt to open for write; this always fails, at least on POSIX
13115         hosts.  This reinstates the 2006-01-09 change, which was
13116         inadvertently removed.
13117
13118 2006-01-26  Bruno Haible  <bruno@clisp.org>
13119
13120         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
13121         Reported by Paul Eggert.
13122
13123 2006-01-26  Bruno Haible  <bruno@clisp.org>
13124             Paul Eggert  <eggert@cs.ucla.edu>
13125
13126         * lib/stdbool_.h (_Bool)
13127         [(! (defined __cplusplus || defined __BEOS__)
13128           && !defined __GNUC__
13129           && !(defined __HP_cc || defined __xlc__
13130                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
13131                || defined __sgi))]:
13132         #define to signed char in these cases too; this simplifies
13133         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
13134         etc., separately) and makes it more conservative.
13135
13136 2006-01-25  Simon Josefsson  <jas@extundo.com>
13137
13138         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
13139         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
13140         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
13141
13142 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
13143
13144         * lib/argp-namefrob.h: Bugfix. Remove stray #
13145
13146 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
13147
13148         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
13149         so that we test the test.
13150         Check for yet another HP-UX cc bug involving *bool |= bool.
13151
13152 2006-01-25  Karl Berry  <karl@gnu.org>
13153
13154         * config/srclist.txt (vasnprintf.c): sync lost.
13155
13156 2006-01-25  Jim Meyering  <jim@meyering.net>
13157
13158         Sync from the stable (b5) branch of coreutils:
13159
13160         * lib/fts.c (fts_children): Don't let close() clobber errno from
13161         failed fchdir().
13162
13163         * lib/fts.c (fts_stat): When following a symlink-to-directory,
13164         don't necessarily interpret stat-fails+lstat-succeeds as indicating
13165         a dangling symlink.  That can also happen at least for ELOOP.
13166         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
13167         FYI, this bug predates the inclusion of fts.c in coreutils.
13168
13169         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
13170         in their own block, so pre-c99 compilers don't object.
13171
13172         Avoid the double-free (first in fts_read, second in fts_close) that
13173         would occur when an `active' directory is made inaccessible (e.g.,
13174         via chmod a-x) during a traversal.
13175         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
13176         before returning.  Reproduce this failure by
13177         mkdir -p a/b; cd a; chmod a-x . b
13178         Reported by Stavros Passas.
13179
13180 2006-01-25  Jim Meyering  <jim@meyering.net>
13181
13182         * lib/fileblocks.c: Remove more useless parentheses.
13183         * lib/readutmp.h: Likewise.
13184
13185 2006-01-25  Bruno Haible  <bruno@clisp.org>
13186
13187         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
13188         warnings.
13189         Reported by Paul Eggert.
13190
13191 2006-01-25  Bruno Haible  <bruno@clisp.org>
13192
13193         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
13194         rid of a trap command. For Solaris sh.
13195         Reported by Mark D. Baushke <mdb@gnu.org>.
13196
13197 2006-01-24  Simon Josefsson  <jas@extundo.com>
13198
13199         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
13200         Bruno.
13201
13202 2006-01-24  Karl Berry  <karl@gnu.org>
13203
13204         * config/srclist.txt (argp-namefrob.h): sync lost.
13205
13206 2006-01-24  Jim Meyering  <jim@meyering.net>
13207
13208         * modules/openat (Files): Add lib/intprops.h.
13209         From Mark D. Baushke.
13210
13211 2006-01-24  Jim Meyering  <jim@meyering.net>
13212
13213         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
13214         Reported by Mark D. Baushke.
13215
13216 2006-01-24  Jim Meyering  <jim@meyering.net>
13217
13218         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
13219
13220 2006-01-24  Bruno Haible  <bruno@clisp.org>
13221
13222         * modules/strnlen (Maintainer): Change from glibc to all.
13223
13224 2006-01-24  Bruno Haible  <bruno@clisp.org>
13225
13226         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
13227         Patch by Paul Eggert.
13228
13229 2006-01-24  Bruno Haible  <bruno@clisp.org>
13230
13231         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
13232         already has it.
13233         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
13234         2005-11-26.
13235
13236         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
13237         'signed char' to avoid problems with the built-in _Bool type.
13238         Reported by Paul Eggert on 2005-11-26.
13239
13240 2006-01-24  Bruno Haible  <bruno@clisp.org>
13241
13242         * gnulib-tool (func_import): Avoid constructing complicated sed
13243         expressions inside backquote.
13244         Report and solution by Mark D. Baushke <mdb@gnu.org>.
13245
13246 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
13247
13248         These changes imported from libc.
13249         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
13250         test and two separate function calls.
13251         * lib/strndup.c (__strndup): Add libc_hidden_def.
13252
13253 2006-01-23  Simon Josefsson  <jas@extundo.com>
13254
13255         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
13256         Remove the test_*_SOURCES variable: automake infers it by default.
13257         * modules/tls-tests: Likewise.
13258
13259 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13260
13261         Work around porting bugs reported by Dieter in
13262         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
13263         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
13264         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
13265         Include "getopt.h" first, to check interface.
13266         (getenv): Declare only if defined HAVE_DECL_GETENV &&
13267         !HAVE_DECL_GETENV.
13268         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
13269         (__strndup): Revert to K&R-style function dfns, the glibc style.
13270         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
13271         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
13272         Include strnlen.h first, to get prototype properly.
13273         (strnlen): Renamed from __strnlen.
13274         Remove weak alias.
13275
13276 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13277
13278         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
13279
13280 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13281
13282         * config/srclist.txt: Adjust to reflect glibc reorganization.
13283         This affects only comments.
13284
13285 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13286
13287          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
13288          Reported by Bruce Korb <bkorb@gnu.org>.
13289
13290 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
13291
13292         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
13293         to pacify gcc -Wswitch-default.
13294
13295 2006-01-22  Bruno Haible  <bruno@clisp.org>
13296
13297         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
13298         temporary buffer for sprintf, take into account the precision also
13299         for 'd', 'i', 'u', 'o', 'x', 'X'.
13300
13301 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
13302
13303         * modules/argp-tests: New module
13304         * tests/test-argp.c: New file
13305         * tests/test-argp-2.sh: New file
13306
13307 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
13308
13309         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
13310         (__argp_base_name): Removed
13311         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
13312         typo.
13313         (__argp_base_name): Provide macro definition or extern declaration
13314         depending on the configuration
13315
13316 2006-01-20  Simon Josefsson  <jas@extundo.com>
13317
13318         * modules/inet_ntop (Depends-on): Depend on sys_socket.
13319
13320 2006-01-20  Simon Josefsson  <jas@extundo.com>
13321
13322         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
13323
13324 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13325
13326         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
13327         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
13328         Suggested by Bruno Haible.
13329
13330 2006-01-20  Karl Berry  <karl@gnu.org>
13331
13332         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
13333         until changes propagate, I guess.
13334
13335 2006-01-19  Simon Josefsson  <jas@extundo.com>
13336
13337         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
13338
13339 2006-01-19  Simon Josefsson  <jas@extundo.com>
13340
13341         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
13342
13343 2006-01-19  Simon Josefsson  <jas@extundo.com>
13344
13345         * gnulib-tool: Set check_PROGRAMS.
13346
13347         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
13348         modules/des-tests, modules/gc-arcfour-tests,
13349         modules/gc-arctwo-tests, modules/gc-des-tests,
13350         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
13351         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
13352         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
13353         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
13354         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
13355         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
13356         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
13357         test_*_SOURCES.
13358
13359 2006-01-18  Simon Josefsson  <jas@extundo.com>
13360
13361         * modules/socklen (Depends-on): Depend on sys_socket.
13362
13363 2006-01-18  Simon Josefsson  <jas@extundo.com>
13364
13365         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
13366         modules/des-tests, modules/gc-arcfour-tests,
13367         modules/gc-arctwo-tests, modules/gc-des-tests,
13368         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
13369         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
13370         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
13371         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
13372         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
13373         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
13374         $(EXEEXT) to automake TESTS variable, for mingw32.
13375
13376 2006-01-17  Simon Josefsson  <jas@extundo.com>
13377
13378         * modules/socklen (Include): Need sys/socket.h.
13379
13380 2006-01-17  Bruno Haible  <bruno@clisp.org>
13381
13382         * modules/ssize_t (Include): Add <sys/types.h>.
13383
13384 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
13385
13386         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
13387         it's not portable and it doesn't work with cross-compiles.
13388         Problem reported by Bruno Haible.  Fix missing-$ typo in
13389         'test "gl_cv_ignore_unused_libraries" ...' that prevented
13390         -zignore from being used with Sun's C compiler.
13391
13392 2006-01-12  Simon Josefsson  <jas@extundo.com>
13393
13394         * lib/base64.c: Fix warning, reported by Bruno Haible
13395         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
13396
13397 2006-01-12  Bruno Haible  <bruno@clisp.org>
13398
13399         * modules/ldd: New file.
13400         * build-aux/ldd.sh.in: New file.
13401         * MODULES.html.sh (Support for building libraries and executables): Add
13402         ldd.
13403
13404 2006-01-12  Bruno Haible  <bruno@clisp.org>
13405
13406         * m4/ldd.m4: New file.
13407
13408 2006-01-12  Bruno Haible  <bruno@clisp.org>
13409
13410         * gnulib-tool (func_import, func_create_testdir): Don't go into an
13411         endless loop while replacing $auxdir with build-aux.
13412
13413 2006-01-11  Simon Josefsson  <jas@extundo.com>
13414
13415         * lib/stdint_.h (SIZE_MAX): Add missing (.
13416
13417 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
13418
13419         Sync from coreutils.
13420         * lib/md5.c: Fix commentary typos.
13421         (alignof, UNALIGNED_P): No need for a GCC-specific version.
13422         * lib/md5.h (__attribute__): Remove; unused.
13423         * lib/sha1.c: Fix commentary to match md5 better.
13424         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
13425         so that we don't need to worry about alignment.  All uses changed.
13426         This merges the 2005-10-28 md5 change into sha1.
13427
13428 2006-01-11  Jim Meyering  <jim@meyering.net>
13429
13430         Sync from coreutils.
13431         * lib/md5.c (OP): Fix spacing.
13432
13433 2006-01-11  Bruno Haible  <bruno@clisp.org>
13434
13435         Ensure automatic ordering between gl_LOCK and gl_ARGP.
13436         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
13437         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
13438
13439 2006-01-11  Bruno Haible  <bruno@clisp.org>
13440
13441         Ensure automatic ordering between gl_LOCK and gl_ARGP.
13442         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
13443         the "early" section as well.
13444
13445 2006-01-11  Bruno Haible  <bruno@clisp.org>
13446
13447         Avoid "ar: no archive members specified" error on MacOS X.
13448         * gnulib-tool (func_modules_add_dummy): New function.
13449         (func_import, func_create_testdir): Invoke it.
13450
13451 2006-01-11  Bruno Haible  <bruno@clisp.org>
13452
13453         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
13454         with $auxdir in AC_CONFIG_FILES statements.
13455
13456 2006-01-11  Bruno Haible  <bruno@clisp.org>
13457
13458         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
13459         Initialize also noinst_HEADERS to empty.
13460
13461 2006-01-11  Bruno Haible  <bruno@clisp.org>
13462
13463         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
13464         variables.
13465         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
13466         autoreconf.
13467
13468 2006-01-11  Bruno Haible  <bruno@clisp.org>
13469
13470         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
13471         overridable by the user.
13472         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13473
13474 2006-01-10  Simon Josefsson  <jas@extundo.com>
13475
13476         * modules/sys_socket: New file.
13477
13478 2006-01-10  Simon Josefsson  <jas@extundo.com>
13479
13480         * m4/sys_socket_h.m4: New file.
13481
13482 2006-01-10  Simon Josefsson  <jas@extundo.com>
13483
13484         * lib/socket_.h: New file.
13485
13486 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13487
13488         * modules/readutmp (Maintainer): Add myself.
13489
13490 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13491
13492         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
13493         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
13494         People who are still concerned with buggy memcmp implementations
13495         can invoke gl_FUNC_MEMCMP themselves.
13496
13497 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13498
13499         * lib/regex_internal.h (BITSET_WORD_BITS):
13500         Work around a bug in 64-bit PGC (before version 6.1-2), where the
13501         preprocessor mishandles large unsigned values as if they were signed.
13502         Problem reported by Claudio Fontana in
13503         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
13504
13505 2006-01-10  Jim Meyering  <jim@meyering.net>
13506
13507         Avoid the double-free (first in fts_read, second in fts_close) that
13508         would occur when an `active' directory is made inaccessible (e.g.,
13509         via chmod a-x) during a traversal.
13510         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
13511         before returning.  Reproduce this failure by
13512         mkdir -p a/b; cd a; chmod a-x . b
13513         Reported by Stavros Passas.
13514
13515         Sync from coreutils.
13516         * lib/sha1.c: Tweak grammar in a comment.
13517
13518 2006-01-10  Jim Meyering  <jim@meyering.net>
13519
13520         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
13521         Patch by Joerg Sonnenberger.
13522
13523 2006-01-10  Bruno Haible  <bruno@clisp.org>
13524
13525         * modules/readutmp: Depend on module free.
13526         * modules/strtok_r: Depend on module restrict.
13527
13528 2006-01-10  Bruno Haible  <bruno@clisp.org>
13529
13530         * modules/gettext (configure.ac): Add an invocation of
13531         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
13532
13533 2006-01-10  Bruno Haible  <bruno@clisp.org>
13534
13535         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
13536         Reported by Werner Lemberg <wl@gnu.org>.
13537
13538 2006-01-10  Bruno Haible  <bruno@clisp.org>
13539
13540         * lib/localcharset.c: Update from GNU gettext.
13541
13542 2006-01-10  Bruno Haible  <bruno@clisp.org>
13543
13544         * lib/argp.h (__const): Remove macro. Use const instead.
13545         * lib/argp-fmtstream.h (__const): Likewise.
13546         * lib/glob_.h (__const): Remove macro.
13547         * lib/glob-libc.h: Use const instead of __const.
13548
13549 2006-01-10  Bruno Haible  <bruno@clisp.org>
13550
13551         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
13552         variable.
13553         Needed to avoid an automake error regarding the 'gettext' module.
13554
13555 2006-01-09  Simon Josefsson  <jas@extundo.com>
13556
13557         * modules/inet_ntop (Depends-on): Add restrict.
13558
13559 2006-01-09  Simon Josefsson  <jas@extundo.com>
13560
13561         * modules/gc-rijndael-tests (License): Put under LGPL.
13562
13563         * modules/gc-des-tests (License): Likewise.
13564
13565         * modules/gc-arcfour-tests (License): Likewise.
13566
13567         * modules/gc-arctwo-tests (License): Likewise.
13568
13569         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
13570
13571         * modules/gc-hmac-sha1-tests (Files): Likewise.
13572
13573         * modules/gc-hmac-md5-tests (License): Likewise.
13574
13575         * modules/gc-sha1-tests (License): Likewise.
13576
13577         * modules/gc-md5-tests (License): Likewise.
13578
13579         * modules/gc-md4-tests (License): Likewise.
13580
13581         * modules/gc-md2-tests (License): Likewise.
13582
13583         * modules/gc-tests (License): Likewise.
13584
13585         * modules/des-tests (License): Likewise.
13586
13587         * modules/md4-tests (License): Likewise.
13588
13589         * modules/md2-tests (License): Likewise.
13590
13591 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13592
13593         Sync from coreutils:
13594
13595         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
13596         * modules/lib-ignore: New file.
13597         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
13598         chdir-safer.m4, lchmod.m4.
13599         * modules/openat: Add mkdirat.c, openat-priv.h.
13600
13601 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13602
13603         Sync from coreutils.
13604         * m4/lib-ignore.m4: New file.
13605         * m4/lchmod.m4: New file.
13606
13607 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13608
13609         Sync from coreutils.
13610         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
13611         for write access: POSIX says that must fail.
13612         * lib/fts.c (diropen): Likewise.
13613         * lib/save-cwd.c (save_cwd): Likewise.
13614         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
13615         well, for minor improvements on hosts that lack O_DIRECTORY.
13616         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
13617         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
13618         Fall back on chown if open failed with EACCES.
13619
13620         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
13621         Report an error at compile-time if only a 1-second nominal clock
13622         resolution is found.
13623
13624         * lib/lchmod.h: New file.
13625         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
13626         (make_dir_parents): Use lchown rather than chown, and
13627         lchmod rather than chmod.
13628
13629         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
13630         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
13631         "proc" reported by n0dalus.
13632
13633         * lib/mountlist.c: Include <limits.h>.
13634         (dev_from_mount_options)
13635         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
13636         New function.  It no longer assumes "dev=" has the System V meaning
13637         on Linux (since it doesn't).  It also parses "dev=" more carefully.
13638         (read_file_system_list)
13639         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
13640         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
13641         dev= in that case.
13642
13643         * lib/posixtm.h (PDS_PRE_2000): New macro.
13644         * lib/posixtm.c (year): Arg is now syntax_bits rather than
13645         allow_century.  All usages changed.  Reject dates outside the range
13646         1969-1999 if PDS_PRE_2000 is used.
13647
13648 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13649
13650         Sync from coreutils.
13651         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
13652         (Time of day items): Mention the possibility of leap seconds.
13653         Problem reported by Dr. David Alan Gilbert.
13654
13655 2006-01-09  Jim Meyering  <jim@meyering.net>
13656
13657         Sync from coreutils.
13658
13659         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
13660
13661         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
13662
13663         * lib/modechange.c (mode_compile): Reject an invalid mode string
13664         that starts with an octal digit.  From Andreas Gruenbacher.
13665
13666         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
13667         and dup to open_safer and dup_safer, respectively.
13668         (openat_permissive): Fix typo in comment.
13669
13670         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
13671         "gettext.h"; either no longer needed or are guaranteed by openat.h.
13672         (_): Remove; no longer needed.
13673         (openat): Renamed from rpl_openat; no need for rpl_openat
13674         since openat.h renames openat for us.
13675         Replace most of the body with a call to openat_permissive,
13676         to avoid duplicate code.
13677         Port to (probably hypothetical) environments were mode_t is
13678         wider than int.
13679         (openat_permissive): Require mode arg, so that we can check
13680         types better.  Put it just after flags.  Change cwd failure
13681         indicator from pointer-to-bool to pointer-to-errno-value.
13682         All callers changed.
13683         Invoke openat_save_fail and/or openat_restore_fail if
13684         cwd_errno is null, so that openat can call us.
13685         (openat_permissive, fdopendir, fstatat, unlinkat):
13686         Simplify errno handling to avoid some duplicate code,
13687         as it's OK to set errno on success.
13688         * lib/openat.h: Revamp code so that function macros depend on
13689         __OPENAT_PREFIX only, not also on AT_FDCWD.
13690         (openat_ro): Remove.  Caller changed to use openat_permissive.
13691         (openat_permissive): Now a macro, if not a function.
13692         (openat_restore_fail, openat_save_fail): Now always functions,
13693         since mkdirat needs them even if __OPENAT_PREFIX is defined.
13694
13695         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
13696         and openat.c.
13697         * lib/mkdirat.c: Include openat-priv.h.
13698         Remove definitions of macros defined therein.
13699         * lib/openat.c: Likewise.
13700
13701         * lib/mkdirat.c (mkdirat): New file and function.
13702         * lib/openat.h (mkdirat): Declare.
13703
13704         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
13705
13706         * lib/openat.h (openat_permissive): Declare.
13707         (openat_ro): Define.
13708
13709         * lib/openat.c (EXPECTED_ERRNO): New macro.
13710         (openat_permissive): New function -- used in remove.c rewrite.
13711         (all functions): Set errno just before returning, only if there
13712         was an actual failure.
13713         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
13714
13715         Emulate openat-family functions using Linux's procfs, if possible.
13716         Idea and some code based on Ulrich Drepper's glibc changes.
13717
13718         * lib/openat.c: (BUILD_PROC_NAME): New macro.
13719         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
13720         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
13721         before falling back on save_cwd and restore_cwd.
13722         (fdopendir, fstatat, unlinkat): Likewise.
13723
13724         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
13725         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
13726
13727         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
13728         as second argument to va_arg.  Otherwise, some versions of gcc
13729         warn that `if this code is reached, the program will abort'.
13730
13731 2006-01-09  Jim Meyering  <jim@meyering.net>
13732
13733         Sync from coreutils.
13734         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
13735         Require openat-priv.h.
13736
13737 2006-01-09  Bruno Haible  <bruno@clisp.org>
13738
13739         * modules/strnlen (Include): Use strnlen.h.
13740
13741 2006-01-09  Bruno Haible  <bruno@clisp.org>
13742
13743         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
13744
13745 2006-01-09  Bruno Haible  <bruno@clisp.org>
13746
13747         * lib/sysexit_.h (EX_OK): New macro.
13748         Suggested by Martin Lambers <marlam@marlam.de>.
13749
13750 2006-01-09  Bruno Haible  <bruno@clisp.org>
13751
13752         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
13753         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
13754
13755 2006-01-09  Bruno Haible  <bruno@clisp.org>
13756
13757         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
13758         numbers.
13759
13760 2006-01-09  Bruno Haible  <bruno@clisp.org>
13761
13762         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
13763         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
13764         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
13765         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
13766
13767 2006-01-09  Bruno Haible  <bruno@clisp.org>
13768
13769         * build-aux/javacomp.sh.in: New file, moved from lib/.
13770         * modules/javacomp-script (Files): Update.
13771         (configure.ac): Add AC_CONFIG_FILES invocation.
13772         (EXTRA_DIST): Remove variable.
13773
13774         * build-aux/javaexec.sh.in: New file, moved from lib/.
13775         * modules/javaexec (Files): Update.
13776         (configure.ac): Add AC_CONFIG_FILES invocation.
13777         (EXTRA_DIST): Remove javaexec.sh.in.
13778
13779         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
13780         * modules/csharpcomp-script (Files): Update.
13781         (configure.ac): Add AC_CONFIG_FILES invocation.
13782         (EXTRA_DIST): Remove variable.
13783
13784         * build-aux/csharpexec.sh.in: New file, moved from lib/.
13785         * modules/csharpexec (Files): Update.
13786         (configure.ac): Add AC_CONFIG_FILES invocation.
13787         (EXTRA_DIST): Remove csharpexec.sh.in.
13788
13789 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13790
13791         Sync from coreutils.
13792
13793         Add POSIX ACL support
13794         * lib/acl.h (copy_acl, set_acl): Add declarations.
13795         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
13796         systems other than Linux.
13797         (chmod_or_fchmod): New function: use fchmod when possible,
13798         and chmod otherwise.
13799         (file_has_acl): Add a POSIX ACL implementation, with a
13800         Linux-specific subcase.
13801         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
13802         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
13803         acls are unsupported.
13804         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
13805         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
13806         are unsupported.
13807
13808 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13809
13810         Sync from coreutils.
13811         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
13812
13813 2006-01-07  Bruno Haible  <bruno@clisp.org>
13814
13815         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
13816         gl_EARLY.
13817
13818 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13819
13820         * lib/strftime.c (tzname): Don't declare if it is already #defined.
13821         Problem reported for Mingw by Mark Junker.
13822
13823 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13824
13825         * README: Gnulib normally doesn't generate a tarball.
13826
13827 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
13828
13829         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
13830         long int, not int, for nanosecond counts, so that people who are
13831         used to POSIX struct timespec won't be surprised.  Reported by Jim
13832         Meyering.
13833
13834 2005-12-28  Bruno Haible  <bruno@clisp.org>
13835
13836         * build-aux/config.rpath: Update from GNU gettext.
13837
13838 2005-12-16  Jim Meyering  <jim@meyering.net>
13839
13840         * modules/fprintftime: New module.
13841         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
13842
13843 2005-12-16  Jim Meyering  <jim@meyering.net>
13844
13845         * m4/fprintftime.m4: New file.
13846
13847 2005-12-16  Jim Meyering  <jim@meyering.net>
13848
13849         * lib/fprintftime.c, lib/fprintftime.h: New files.
13850
13851 2005-12-15  Simon Josefsson  <jas@extundo.com>
13852
13853         * modules/socklen (configure.ac): Fix M4 macro name, to align with
13854         new m4/socklen.m4.
13855
13856 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13857
13858         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
13859         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
13860
13861 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13862
13863         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
13864         * lib/argp-help.c (fill_in_uparams): Check if the constructed
13865         struct uparams is valid. Fall back to the default values if it is
13866         not.
13867
13868 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13869
13870         * modules/argp (Files): Add argp-pin.c
13871         (Depends-on): dirname
13872         (lib_SOURCES): Add argp-pin.c
13873
13874 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13875
13876         * m4/argp.m4:  Check if program_invocation_name and
13877         program_invocation_short_name are declared and define appropriate
13878         macros if they are not.
13879
13880 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13881
13882         * lib/argp-help.c (__argp_base_name): New function
13883         (__argp_short_program_name): Rewrite using __argp_base_name
13884         * lib/argp-namefrob.h: Define program_invocation_name and
13885         program_invocation_short_name if requested
13886         (__argp_base_name): Add prototype
13887         * lib/argp-parse.c (argp_def): Use gettext wrappers
13888         (argp_default_parser): Use __argp_base_name
13889         * lib/argp-pin.c: New file. Defines program_invocation_name and
13890         program_invocation_short_name on systems that lack them.
13891
13892 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13893
13894         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
13895         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13896         porting problem reported by Georg Schwarz in
13897         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13898
13899 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13900
13901         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
13902         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13903         porting problem reported by Georg Schwarz in
13904         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13905
13906 2005-12-05  Bruno Haible  <bruno@clisp.org>
13907
13908         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
13909         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
13910         Reported by Mark Junker <mjscod@gmx.de>.
13911
13912 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
13913
13914         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
13915         Use implementation from Albert Chin, with some
13916         comments/corrections by Stepan Kasal and myself.
13917
13918 2005-12-02  Bruno Haible  <bruno@clisp.org>
13919
13920         * gnulib-tool (func_import): Accept GPLed build tool modules when
13921         --lgpl is given.
13922         * modules/csharpcomp-script: New file.
13923         * modules/csharpcomp: Depend on it.
13924         * modules/javacomp-script: New file.
13925         * modules/javacomp: Depend on it.
13926         Suggested by Simon Josefsson.
13927
13928 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
13929
13930         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
13931         statement, to work around an HP-UX 10.20 compiler bug reported by
13932         Peter O'Gorman.
13933
13934 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13935
13936         * modules/savedir (Depends-on): Add openat.
13937
13938 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13939
13940         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
13941         (uintmax_t) [defined uintmax_t]: Do not declare.
13942         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
13943         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
13944         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
13945         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
13946         sake of portability to weird hosts that C allows (though we don't
13947         know of any practical examples).
13948
13949         * lib/savedir.h (fdsavedir): New decl.
13950         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
13951         contains most of the former guts of savedir.
13952         (savedir): Use savedirstream.
13953         Include "openat.h".
13954
13955 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13956
13957         * modules/obstack (Files): Add m4/ulonglong.m4.
13958         Problem reported by Davide Angelocola.
13959
13960 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
13961
13962         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
13963         coreutils no longer futzes with rounding modes.
13964
13965 2005-11-14  Jim Meyering  <jim@meyering.net>
13966
13967         * lib/mkstemp-safer.c: Include <config.h>, required for possible
13968         replacement of mkstemp.
13969
13970 2005-11-10  Simon Josefsson  <jas@extundo.com>
13971
13972         * lib/readline.c: Remove EOL.
13973
13974 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13975
13976         * modules/gethrxtime (Depends-on): Add gettime.
13977
13978 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13979
13980         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
13981         or gettimeofday; no longer needed.
13982
13983 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13984
13985         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
13986         time business.
13987         (gethrxtime) [! (HAVE_NANOUPTIME
13988         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
13989         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
13990         our own approximation.
13991
13992 2005-11-08  Eric Blake  <ebb9@byu.net>
13993
13994         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13995
13996 2005-11-08  Eric Blake  <ebb9@byu.net>
13997
13998         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13999
14000 2005-11-04  Bruno Haible  <bruno@clisp.org>
14001
14002         * gnulib-tool: Implement --update mode.
14003
14004 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
14005
14006         Fix porting problem reported by Theodoros V. Kalamatianos.
14007         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
14008         Don't assume that futimes failing means we must fail.
14009
14010 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
14011
14012         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
14013         variables to suggest the intended function of the PATH_MAX check.
14014
14015 2005-10-30  Kean Johnston  <jkj@sco.com>
14016
14017         Trivial changes to support SCO systems.
14018         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
14019         as PATH_MAX.
14020         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
14021         where __ptr is null when no I/O is pending.
14022
14023 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14024
14025         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
14026         leave errno alone.  Problem reported by Dmitry V. Levin.
14027
14028 2005-10-28  Simon Josefsson  <jas@extundo.com>
14029
14030         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
14031         Test more.
14032
14033         * tests/test-gc-md2.c, tests/test-md2.c: New files.
14034
14035         * modules/md2, modules/md2-tests: New files.
14036
14037 2005-10-28  Simon Josefsson  <jas@extundo.com>
14038
14039         * m4/inet_ntop.m4: More tests.
14040
14041         * m4/gc-md2.m4, md2.m4: New file.
14042
14043 2005-10-28  Simon Josefsson  <jas@extundo.com>
14044
14045         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
14046         "restrict" keywords, as per POSIX.  Protect the function
14047         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
14048         Don't use K&R prototypes.  Check the sprintf return values.
14049         Re-define EAFNOSUPPORT if not present.  Indent.
14050
14051         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
14052         suggested by Bruno Haible <bruno@clisp.org>.
14053
14054         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
14055
14056         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
14057
14058         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
14059         libgcrypt).
14060
14061         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
14062
14063         * lib/md2.h, lib/md2.c: New files.
14064
14065 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
14066
14067         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
14068         errno alone.  Problem reported by Frederic Jolliton.
14069
14070 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
14071
14072         * modules/verify (License): Change from GPL to LGPL.  This is a
14073         tiny module and there are apparently near-equivalents that are
14074         under the BSD license.
14075
14076 2005-10-24  Simon Josefsson  <jas@extundo.com>
14077
14078         * modules/sha1: Relicense to LGPL.
14079
14080 2005-10-24  Simon Josefsson  <jas@extundo.com>
14081
14082         * lib/md4.h: Shrink buffer size, now that we changed the type.
14083
14084 2005-10-23  Simon Josefsson  <jas@extundo.com>
14085
14086         * gnulib-tool (func_import): Fix --tests-base.
14087
14088 2005-10-22  Simon Josefsson  <jas@extundo.com>
14089
14090         * modules/arcfour (Depends-on): Need stdint.
14091
14092 2005-10-22  Simon Josefsson  <jas@extundo.com>
14093
14094         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
14095         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
14096
14097 2005-10-22  Simon Josefsson  <jas@extundo.com>
14098
14099         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
14100         suggested by Bruno Haible <bruno@clisp.org>.
14101
14102 2005-10-22  Simon Josefsson  <jas@extundo.com>
14103
14104         * lib/crc.h: Include stddef.h, for size_t.
14105
14106 2005-10-22  Simon Josefsson  <jas@extundo.com>
14107
14108         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
14109         arcfour_context struct (simplify test vector testing in GNU
14110         Shishi).
14111
14112 2005-10-21  Simon Josefsson  <jas@extundo.com>
14113
14114         * modules/des, modules/des-tests: New files.
14115
14116         * modules/gc-des, modules/gc-des-tests: New files.
14117
14118         * tests/test-des.c, tests/test-gc-des.c: New file.
14119
14120 2005-10-21  Simon Josefsson  <jas@extundo.com>
14121
14122         * modules/arctwo, modules/arctwo-tests: New files.
14123
14124         * tests/test-arctwo.c: New file.
14125
14126         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
14127
14128         * tests/test-gc-arctwo.c: New file.
14129
14130 2005-10-21  Simon Josefsson  <jas@extundo.com>
14131
14132         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
14133         Bruno Haible <bruno@clisp.org>.
14134
14135         * m4/gc-des.m4: New file.
14136
14137 2005-10-21  Simon Josefsson  <jas@extundo.com>
14138
14139         * m4/arctwo.m4: New file.
14140
14141         * m4/gc-arctwo.m4: New file.
14142
14143 2005-10-21  Simon Josefsson  <jas@extundo.com>
14144
14145         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
14146         block.
14147
14148 2005-10-21  Simon Josefsson  <jas@extundo.com>
14149
14150         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
14151         <bruno@clisp.org>.
14152
14153         * lib/hmac-sha1.c (hmac_sha1): Likewise.
14154
14155         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
14156         Bruno Haible <bruno@clisp.org>.
14157
14158         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
14159         <bruno@clisp.org>.
14160
14161 2005-10-21  Simon Josefsson  <jas@extundo.com>
14162
14163         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
14164
14165 2005-10-21  Simon Josefsson  <jas@extundo.com>
14166
14167         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
14168
14169 2005-10-21  Simon Josefsson  <jas@extundo.com>
14170
14171         * lib/des.h, lib/des.c: New files.
14172
14173         * lib/gc-gnulib.c: Support DES.c
14174
14175 2005-10-21  Simon Josefsson  <jas@extundo.com>
14176
14177         * lib/arctwo.h, lib/arctwo.c: New files.
14178
14179         * lib/gc-gnulib.c: Support ARCTWO.
14180
14181 2005-10-21  Simon Josefsson  <jas@extundo.com>
14182
14183         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
14184         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14185
14186 2005-10-21  Simon Josefsson  <jas@extundo.com>
14187
14188         * gnulib-tool (func_import, func_create_testdir): Define automake
14189         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
14190         Makefile.am snippet),
14191         suggested by Bruno Haible <bruno@clisp.org>.
14192
14193         * modules/gc (Makefile.am): Use it.
14194
14195 2005-10-21  Bruno Haible  <bruno@clisp.org>
14196
14197         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
14198         patch.
14199
14200 2005-10-19  Simon Josefsson  <jas@extundo.com>
14201
14202         * tests/test-gc-rijndael.c: New file.
14203
14204         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
14205
14206 2005-10-19  Simon Josefsson  <jas@extundo.com>
14207
14208         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
14209         interface too.
14210
14211 2005-10-19  Simon Josefsson  <jas@extundo.com>
14212
14213         * tests/test-gc-arcfour.c: New file.
14214
14215         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
14216
14217 2005-10-19  Simon Josefsson  <jas@extundo.com>
14218
14219         * modules/gc-md4, modules/gc-md4-tests: New file.
14220
14221         * tests/test-gc-md4.c: New file.
14222
14223 2005-10-19  Simon Josefsson  <jas@extundo.com>
14224
14225         * m4/gc-md4.m4: New file.
14226
14227 2005-10-19  Simon Josefsson  <jas@extundo.com>
14228
14229         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
14230         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
14231         <kasal@ucw.cz>.
14232
14233 2005-10-19  Simon Josefsson  <jas@extundo.com>
14234
14235         * m4/gc-arcfour.m4: New file.
14236
14237         * m4/gc-rijndael.m4: New file.
14238
14239 2005-10-19  Simon Josefsson  <jas@extundo.com>
14240
14241         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
14242
14243 2005-10-19  Simon Josefsson  <jas@extundo.com>
14244
14245         * lib/gc-gnulib.c: Support ARCFOUR.
14246
14247 2005-10-19  Simon Josefsson  <jas@extundo.com>
14248
14249         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
14250         support.
14251
14252         * lib/gc.h: Add ECB enum type.
14253
14254         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
14255
14256 2005-10-18  Simon Josefsson  <jas@extundo.com>
14257
14258         * tests/test-md5.c: New file.
14259
14260         * modules/md5-tests: New file.
14261
14262 2005-10-18  Simon Josefsson  <jas@extundo.com>
14263
14264         * tests/test-md4.c: New file.
14265
14266         * modules/md4, modules/md4-tests: New files.
14267
14268 2005-10-18  Simon Josefsson  <jas@extundo.com>
14269
14270         * m4/md4.m4: New file.
14271
14272 2005-10-18  Simon Josefsson  <jas@extundo.com>
14273
14274         * lib/md4.h, lib/md4.c: New files, based on md5.?.
14275
14276 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
14277
14278         * gnulib-tool (func_create_testdir): Omit the second check whether
14279         BUILT_SOURCES in nonempty.
14280
14281 2005-10-17  Simon Josefsson  <jas@extundo.com>
14282
14283         * tests/test-rijndael.c: New file.
14284
14285 2005-10-17  Simon Josefsson  <jas@extundo.com>
14286
14287         * modules/sha1: Depend on stdint instead of md5.
14288
14289         * modules/md5: Depend on stdint, remove uint32_t.
14290
14291 2005-10-17  Simon Josefsson  <jas@extundo.com>
14292
14293         * modules/gc-sha1-tests: New file.
14294
14295         * tests/test-gc-sha1.c: New file.
14296
14297 2005-10-17  Simon Josefsson  <jas@extundo.com>
14298
14299         * m4/md5.m4: Remove call to uint32_t.m4.
14300
14301 2005-10-17  Simon Josefsson  <jas@extundo.com>
14302
14303         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
14304
14305         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
14306         md5.h.
14307
14308         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
14309
14310         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
14311
14312 2005-10-17  Simon Josefsson  <jas@extundo.com>
14313
14314         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
14315
14316 2005-10-17  Simon Josefsson  <jas@extundo.com>
14317
14318         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
14319
14320 2005-10-17  Simon Josefsson  <jas@extundo.com>
14321
14322         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
14323
14324         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
14325
14326 2005-10-17  Bruno Haible  <bruno@clisp.org>
14327
14328         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
14329         that it can also be used in a test.
14330
14331 2005-10-16  Bruno Haible  <bruno@clisp.org>
14332
14333         * gnulib-tool (func_emit_tests_Makefile_am): Also define
14334         TESTS_ENVIRONMENT, so that individual tests can augment it.
14335
14336         * gnulib-tool (func_create_testdir): Use an intermediate target for
14337         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
14338         macros, like $(ALLOCA_H), which cannot be passed through the command
14339         line.
14340
14341 2005-10-15  Simon Josefsson  <jas@extundo.com>
14342
14343         * modules/rijndael-tests: New file.
14344
14345         * modules/rijndael: New file.
14346
14347 2005-10-15  Simon Josefsson  <jas@extundo.com>
14348
14349         * m4/rijndael.m4: New file.
14350
14351 2005-10-15  Simon Josefsson  <jas@extundo.com>
14352
14353         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
14354
14355         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
14356
14357 2005-10-14  Simon Josefsson  <jas@extundo.com>
14358
14359         * tests/test-arcfour.c: New file.
14360
14361         * modules/arcfour, modules/arcfour-tests: New files.
14362
14363 2005-10-14  Simon Josefsson  <jas@extundo.com>
14364
14365         * m4/arcfour.m4: New file.
14366
14367 2005-10-14  Simon Josefsson  <jas@extundo.com>
14368
14369         * lib/arcfour.h, lib/arcfour.c: New files.
14370
14371 2005-10-14  Roland McGrath  <roland@redhat.com>
14372
14373         Import from libc.  [BZ #1331]
14374         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
14375         macro argument.
14376         Reported by Matej Vela <vela@debian.org>.
14377
14378 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
14379
14380         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
14381         include <wchar.h>; no longer needed.
14382
14383 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
14384
14385         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
14386
14387 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
14388         and  Ulrich Drepper  <drepper@redhat.com>
14389
14390         Import from libc.
14391         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
14392         instead of inline stream orientation test and two separate
14393         function calls.  Pay no attention to USE_IN_LIBIO.
14394
14395 2005-10-13  Simon Josefsson  <jas@extundo.com>
14396
14397         * modules/gc-hmac-md5-tests: New file.
14398
14399         * tests/test-gc-hmac-sha1.c: New file.
14400
14401         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
14402
14403         * modules/gc-hmac-md5-tests: New file.
14404
14405         * tests/test-gc-md5.c: New file.
14406
14407         * modules/gc-md5-tests: New file.
14408
14409 2005-10-13  Simon Josefsson  <jas@extundo.com>
14410
14411         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
14412         Move memory allocation outside of loop.
14413
14414 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
14415
14416         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
14417         intermediate directory is in a read-only file system.  Problem
14418         reported by Eric Blake.
14419
14420 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
14421
14422         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
14423
14424 2005-10-12  Simon Josefsson  <jas@extundo.com>
14425
14426         * tests/test-hmac-sha1.c: New file.
14427
14428         * modules/hmac-sha1-tests: New file.
14429
14430         * modules/hmac-sha1: New file.
14431
14432 2005-10-12  Simon Josefsson  <jas@extundo.com>
14433
14434         * modules/gc-sha1: New file.
14435
14436 2005-10-12  Simon Josefsson  <jas@extundo.com>
14437
14438         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
14439
14440         * tests/test-gc-pbkdf2-sha1.c: New file.
14441
14442 2005-10-12  Simon Josefsson  <jas@extundo.com>
14443
14444         * modules/gc-md5, modules/gc-hmac-md5: New files.
14445
14446         * modules/gc (Files): Remove md5, memxor and hmac files.
14447
14448 2005-10-12  Simon Josefsson  <jas@extundo.com>
14449
14450         * m4/gc-pbkdf2-sha1.m4: New file.
14451
14452         * m4/gc-hmac-sha1.m4: New file.
14453
14454         * m4/gc-sha1: New file.
14455
14456         * m4/hmac-sha1.m4: New file.
14457
14458 2005-10-12  Simon Josefsson  <jas@extundo.com>
14459
14460         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
14461
14462         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
14463
14464 2005-10-12  Simon Josefsson  <jas@extundo.com>
14465
14466         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
14467         suggested by Bruno Haible <bruno@clisp.org>.
14468
14469 2005-10-12  Simon Josefsson  <jas@extundo.com>
14470
14471         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
14472
14473 2005-10-12  Simon Josefsson  <jas@extundo.com>
14474
14475         * lib/gc-pbkdf2-sha1.c: New file.
14476
14477         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
14478
14479 2005-10-12  Simon Josefsson  <jas@extundo.com>
14480
14481         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
14482
14483         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
14484
14485 2005-10-12  Simon Josefsson  <jas@extundo.com>
14486
14487         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
14488         GC_USE_HMAC_MD5, respectively.
14489
14490         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
14491         (gc_md5): Fix typo.
14492
14493         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
14494
14495         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
14496
14497         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
14498
14499 2005-10-12  Bruno Haible  <bruno@clisp.org>
14500
14501         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
14502         Reported by Stepan Kasal <kasal@ucw.cz>.
14503
14504 2005-10-11  Simon Josefsson  <jas@extundo.com>
14505
14506         * tests/test-crc.c: New file.
14507
14508         * modules/crc, modules/crc-tests: New files.
14509
14510 2005-10-11  Simon Josefsson  <jas@extundo.com>
14511
14512         * m4/crc.m4: New file.
14513
14514 2005-10-11  Simon Josefsson  <jas@extundo.com>
14515
14516         * lib/gc.h: Add gc_hash and gc_hash_buffer.
14517
14518         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
14519
14520         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
14521
14522 2005-10-11  Simon Josefsson  <jas@extundo.com>
14523
14524         * lib/crc.h, lib/crc.c: New files.
14525
14526         * lib/gc.h (gc_hash_buffer): Add doc.
14527
14528 2005-10-11  Bruno Haible  <bruno@clisp.org>
14529
14530         * modules/c-strcasestr: New file.
14531         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
14532
14533 2005-10-11  Bruno Haible  <bruno@clisp.org>
14534
14535         * modules/c-strcase: New file.
14536         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
14537
14538 2005-10-11  Bruno Haible  <bruno@clisp.org>
14539
14540         * lib/strcasecmp.c: Include limits.h.
14541         (strcasecmp): Avoid integer overflow on exotic platforms.
14542         * lib/strncasecmp.c: Include limits.h.
14543         (strncasecmp): Avoid integer overflow on exotic platforms.
14544         Reported by Paul Eggert.
14545
14546 2005-10-11  Bruno Haible  <bruno@clisp.org>
14547
14548         * lib/c-strcasestr.h: New file, from GNU gettext.
14549         * lib/c-strcasestr.c: New file, from GNU gettext.
14550
14551 2005-10-11  Bruno Haible  <bruno@clisp.org>
14552
14553         * lib/c-strcase.h: New file, from GNU gettext.
14554         * lib/c-strcasecmp.c: New file, from GNU gettext.
14555         * lib/c-strncasecmp.c: New file, from GNU gettext.
14556
14557 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
14558
14559         * modules/mempcpy (License): GPL -> LGPL.
14560         * modules/strchrnul (License): Likewise.
14561         * modules/sysexits (License): Likewise.
14562
14563 2005-10-08  Simon Josefsson  <jas@extundo.com>
14564
14565         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
14566
14567 2005-10-07  Simon Josefsson  <jas@extundo.com>
14568
14569         * m4/memxor.m4: Remove gl_C_RESTRICT call.
14570
14571 2005-10-06  Simon Josefsson  <jas@extundo.com>
14572
14573         * tests/test-hmac-md5.c: New file.
14574
14575         * modules/hmac-md5-tests: New file.
14576
14577         * modules/hmac-md5: New file.
14578
14579 2005-10-06  Simon Josefsson  <jas@extundo.com>
14580
14581         * m4/hmac-md5.m4: New file.
14582
14583         * m4/memxor.m4: Require gl_C_RESTRICT.
14584
14585 2005-10-06  Simon Josefsson  <jas@extundo.com>
14586
14587         * lib/memxor.c (memxor): Avoid casts and warnings.
14588
14589 2005-10-06  Simon Josefsson  <jas@extundo.com>
14590
14591         * lib/hmac-md5.c: New file.
14592
14593         * lib/hmac.h: New file.
14594
14595 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14596
14597         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
14598         promotes to int, not unsigned int, to catch the AIX 5.3
14599         compiler bug.
14600
14601 2005-10-05  Simon Josefsson  <jas@extundo.com>
14602
14603         * modules/memxor: New file.
14604
14605         * modules/iconv (Files): Move config.rpath to havelib, it is used
14606         there.
14607
14608         * modules/havelib (Files): Add config.rpath.
14609
14610 2005-10-05  Simon Josefsson  <jas@extundo.com>
14611
14612         * m4/memxor.m4: New file.
14613
14614 2005-10-05  Simon Josefsson  <jas@extundo.com>
14615
14616         * lib/memxor.c (memxor): Fix compiler error.
14617
14618         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
14619         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
14620
14621         * lib/memxor.h, lib/memxor.c: New files.
14622
14623         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
14624         we assume all systems have it, suggested by Jim Meyering
14625         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
14626         any systems lack sys/socket.h; mingw32 is known to lack it, but we
14627         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
14628         same reasons.
14629
14630 2005-10-05  Simon Josefsson  <jas@extundo.com>
14631
14632         * config/srclist.txt: Add glibc bug 1423 for md5.h.
14633
14634 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
14635
14636         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
14637         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
14638         needed, since the source code now assumes these .h files.
14639
14640 2005-10-05  Derek Price  <derek@ximbiot.com>
14641
14642         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
14643
14644 2005-10-05  Bruno Haible  <bruno@clisp.org>
14645
14646         * modules/stdint (License): Change to LGPL.
14647
14648 2005-10-04  Simon Josefsson  <jas@extundo.com>
14649
14650         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
14651         D. Baushke" <mdb@gnu.org>.
14652
14653 2005-10-04  Bruno Haible  <bruno@clisp.org>
14654
14655         * lib/verify.h (verify_true): Provide alternative definition for C++.
14656
14657 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
14658
14659         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
14660         (SSIZE_MAX): New macro, if not already defined.
14661         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
14662         than 2 GiB.
14663
14664 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14665
14666         Sync from coreutils.
14667         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
14668         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
14669         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
14670         ULLONG_MAX doesn't work with 2.7.2.1.
14671
14672 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14673
14674         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
14675         From Ben Pfaff.
14676
14677         * modules/exclude (Depends-on): Depend on verify.
14678         * modules/strtoimax (Depends-on): Likewise.
14679         * modules/utimecmp (Depends-on): Likewise.
14680
14681 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14682
14683         * lib/exclude.c: Include verify.h.
14684         (verify): Remove.  All callers changed to use verify.h's version.
14685         * lib/strtoimax.c: Likewise.
14686         * lib/utimecmp.c: Likewis.e
14687
14688         Sync from coreutils.
14689         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
14690         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
14691         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
14692         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
14693         bother returning ENOSYS if settimeofday or stime fails; just let
14694         them return whatever errno they want to return.
14695         * lib/utimens.c: Include unistd.h, for dup2.
14696         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
14697         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
14698
14699 2005-10-02  Jim Meyering  <jim@meyering.net>
14700
14701         Sync from coreutils.
14702         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
14703         from glibc-2.2.5 that fails for read-only files.
14704
14705 2005-10-02  Jim Meyering  <jim@meyering.net>
14706
14707         Sync from coreutils.
14708         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
14709         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
14710         `#if HAVE_CONFIG_H'.
14711         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
14712         Remove AT_FDCWD test.
14713         Do not consume the fd unless successful.
14714         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
14715         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
14716         block, so that we don't even try to compile it if settimeofday is
14717         available.  This works around a compilation failure on OSF1 V5.1,
14718         due to stime requiring a `long int*' while tv_sec is `int'.
14719
14720 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
14721
14722         Sync from coreutils.
14723         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
14724         against `yes', rather than just testing for nonempty.
14725
14726 2005-10-01  Simon Josefsson  <jas@extundo.com>
14727
14728         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
14729         and Darwin.
14730
14731         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
14732         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
14733         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
14734         freeaddrinfo and gai_strerror are declared by the POSIX headers.
14735         Check if struct addrinfo is declared.
14736
14737 2005-10-01  Simon Josefsson  <jas@extundo.com>
14738
14739         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
14740         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
14741         AI_* and EAI_* definitions.  Protect function declarations.
14742
14743 2005-10-01  Jim Meyering  <jim@meyering.net>
14744
14745         Sync from coreutils.
14746
14747         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
14748         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
14749         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
14750         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
14751         in the inet and nsl libraries.  Required on Solaris 5.7.
14752
14753 2005-10-01  Jim Meyering  <jim@meyering.net>
14754
14755         Sync from coreutils.
14756         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
14757         in the inet and nsl libraries.  Required on Solaris 5.7.
14758
14759 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
14760
14761         * lib/getdelim.c (getdelim): Remove unused variables.
14762
14763 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
14764
14765         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
14766         so that the code works even with ancient cpp.  Portability problem
14767         with GCC 2.7.2.1 reported by Thomas M.Ott.
14768
14769 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
14770
14771         * modules/regex (Depends-on): Add strcase.
14772
14773         * modules/gethostname (Licence): Change from GPL to LGPL, since
14774         gethostname.c is a trivial implementation of a standard library
14775         function.
14776         * modules/poll (License): Change from GPL to LGPL, since it's
14777         derived from LGPL code.
14778
14779 2005-09-27  Jim Meyering  <jim@meyering.net>
14780
14781         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
14782         HAVE_CONFIG_H.
14783
14784         * lib/intprops.h (signed_type_or_expr__): Define.
14785         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
14786         for unsigned types.
14787
14788 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
14789
14790         * lib/verify.h (verify_expr): Remove, replacing with:
14791         (verify_true): New macro that returns true instead of void.
14792         (verify_type__): Remove.
14793         (verify): Use verify_true rather than verify_type__.
14794
14795 2005-09-26  Bruno Haible  <bruno@clisp.org>
14796
14797         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
14798         is necessary.
14799         (lib_SOURCES): Remove mbchar.c.
14800         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
14801         (Files): Add m4/mbrtowc.m4.
14802         * modules/mbiter: Likewise.
14803         * modules/mbuiter: Likewise.
14804
14805 2005-09-26  Bruno Haible  <bruno@clisp.org>
14806
14807         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
14808         compile mbchar.c if they are not both present.
14809         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
14810         * m4/mbiter.m4 (gl_MBITER): Likewise.
14811         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
14812         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
14813         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
14814
14815 2005-09-25  Jim Meyering  <jim@meyering.net>
14816
14817         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
14818         also uses socklen_t.
14819
14820 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
14821
14822         * lib/utimens.c (ENOSYS): Define if not already defined.
14823         (futimens): Support having a null PATH if the file descriptor
14824         is nonnegative.
14825
14826         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
14827         Remove.
14828         (__attribute): Define to empty unless GCC 3.1 or later.
14829         This works around a core dump on OpenBSD 3.4, which has GCC
14830         2.95.3, which dumps core when given __attribute__(()).  It also
14831         simplifies other tests, since we really don't want to bother with
14832         worrying about which ancient version of GCC supported what.
14833         Original problem reported by Yoann Vandoorselaere, with part of
14834         the fix suggested by Derek Price.
14835
14836 2005-09-24  Jim Meyering  <jim@meyering.net>
14837
14838         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
14839         so we can once again use a positive bitfield width of 1 -- now we
14840         don't have to explain why we were using a bitfield width of 2.
14841
14842 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14843
14844         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
14845         and similarly for the other external symbols.  Problem reported
14846         by James Gallager.
14847
14848         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
14849         bug reported by Jim Meyering.
14850
14851         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
14852         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
14853         not needed, since socklen is a prerequisite module.
14854
14855 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14856
14857         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
14858         Problem reported by Eric Blake.
14859         (getaddrinfo): Initialize se so that it's not garbage.
14860         Redo internal storage allocation so that it doesn't make unportable
14861         assumptions about alignment.
14862         Fix a memory leak.
14863
14864         * lib/utimens.c (futimens): Use futimesat if available.
14865         Prefer it to futimes since it doesn't have the futimes bug.
14866
14867         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
14868         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
14869         Instead, declare a function that returns a pointer to an array,
14870         and use verify_type__ to declare the size of the array.
14871         Problem and germ of a solution reported by Bruno Haible.
14872         (verify_type__): Use 2, not 1, for bitfield size, to avoid
14873         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
14874
14875 2005-09-23  Jim Meyering  <jim@meyering.net>
14876
14877         Sync from coreutils.
14878         Correct build failure (socklen_t not defined) on at least
14879         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
14880         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
14881
14882 2005-09-23  Jim Meyering  <jim@meyering.net>
14883
14884         * modules/getaddrinfo (Depends-on): Add socklen.
14885
14886 2005-09-23  Bruno Haible  <bruno@clisp.org>
14887
14888         * tests/test-verify.c: New file.
14889
14890 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14891
14892         Sync from coreutils.
14893
14894         * modules/argmatch (Depends-on): Add verify.
14895         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
14896         unistd-safer.
14897         * modules/save-cwd (Depends-on): Likewise.
14898
14899         * modules/openat (Files): Add lib/openat-die.c.
14900         (Depends-on): Remove error, exitfail.
14901         Add dirname.
14902
14903         * modules/verify: New file.
14904         * MODULES.html.sh (Diagnostics <assert.h>): New section,
14905         with "verify" module.
14906
14907 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14908
14909         Sync from coreutils.
14910
14911         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
14912         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
14913         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
14914         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
14915         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
14916         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
14917         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
14918         Don't bother checking for string.h, stdlib.h, unistd.h.
14919         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
14920         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
14921         module's job.
14922         * m4/jm-macros.m4 (gl_MACROS): Likewise.
14923         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
14924
14925         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
14926         (gl_GETDATE): Use it.
14927
14928         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
14929
14930 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14931
14932         Sync from coreutils.
14933
14934         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
14935         stat-time.h.
14936         * lib/argmatch.h: Include verify.h
14937         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
14938         (ARGMATCH_ASSERT): Remove; unused.
14939         * lib/canonicalize.c: Assume STDC_HEADERS.
14940         * lib/exclude.c: Include "strcase.h".
14941         * lib/regex_internal.h [!defined _LIBC]: Likewise.
14942         * lib/getusershell.c: Include stdio--.h rather than stdio.h
14943         and stdio-safer.h.
14944         (getusershell): Call fopen, not fopen_safer.
14945         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
14946         Do not include unistd-safer.h.
14947         (save_cwd): Don't call fd_safer; no longer needed
14948         now that we include fcntl--.h.
14949
14950         * lib/getdate.y (relative_time): New type.
14951         (RELATIVE_TIME_0): New constant.
14952         (parser_control): Use relative_time instead of doing it ourselves.
14953         (%union): Add new relative_time rel member.
14954         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
14955         Now typeless.
14956         (relunit, relunit_snumber): Now of type rel.
14957         (zone, rel, relunit, get_date): Adjust to above changes.
14958
14959         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
14960         Do not include unistd-safer.h.
14961         (getloadavg): Don't call fd_safer; no longer needed
14962         now that we include fcntl--.h.
14963
14964         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
14965         (make_dir_parents): Treat ENOSYS like EEXIST.
14966
14967         Improve quality of diagnostics on restore_cwd failure.
14968         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
14969         (make_dir_parents): Last arg is now int * (for errno), not bool *.
14970         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
14971         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
14972         each time through the loop.  Do not diagnose restore_cwd failure;
14973         that is the caller's job (and perhaps the caller does not care).
14974
14975         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
14976         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
14977         If the file already exists but is not a directory, don't bother
14978         to try to make its parents.
14979         Close potential file descriptor leak if we can't chdir("/") (!).
14980         Don't always return true if chdir($PWD) fails; return true only
14981         if the requested action was done successfully (except for the
14982         chdir($PWD)).
14983         Don't log final directory unless we actually made it.
14984         Refactor to avoid duplicate code to fix up permissions.
14985         Don't attempt to fix up parent permissions if chdir($PWD) fails.
14986
14987         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
14988         to make it a bit faster and (I hope) clearer.
14989         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
14990         Fix bug in formats like %2N.
14991
14992         * lib/verify.h: New file.
14993
14994 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14995
14996         Sync from coreutils.
14997         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
14998
14999 2005-09-22  Jim Meyering  <jim@meyering.net>
15000
15001         Sync from coreutils.
15002
15003         * m4/lstat.m4 (gl_FUNC_LSTAT):
15004         Use AC_LIBSOURCES to require lstat.c and lstat.h.
15005         Remove obsolete comment.
15006         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
15007         * m4/xstrtod.m4: Likewise.
15008
15009         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
15010
15011 2005-09-22  Jim Meyering  <jim@meyering.net>
15012
15013         Sync from coreutils.
15014
15015         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
15016
15017         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
15018         the .tm_year member, since otherwise gcc-4.0 would now warn about
15019         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
15020
15021         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
15022         order to avoid an unsuppressible warning from gcc on 64-bit systems.
15023
15024         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
15025         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
15026         when run in a time zone for which daylight savings time is in effect
15027         for the starting date.
15028
15029         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
15030         stop us from restricting permissions of just-created absolute-named
15031         directories.
15032         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
15033         to restore initial working directory.
15034         * lib/mkdir-p.c (make_dir_parents): New parameter:
15035         different_working_dir, to tell caller if/when we change the working
15036         directory and are unable to return to the initial one.
15037         * lib/mkdir-p.h (make_dir_parents): Update prototype.
15038         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
15039         `return false'.  This fixes a bug introduced on 2004-07-30.
15040
15041         * lib/openat.c (fdopendir): Be sure to close the supplied
15042         file descriptor before returning.  This makes our replacement
15043         implementation a little closer to Solaris's, where fdopendir
15044         ties the file descriptor to the returned DIR* pointer.
15045         * lib/openat.c (unlinkat): New function.
15046         * lib/openat.h (unlinkat): Add prototype.
15047         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
15048         (openat_restore_fail): Rename from openat_restore_die.
15049         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
15050
15051         Provide an alternative to exiting immediately upon save_cwd or
15052         restore_cwd failure.  Now, an application can arrange e.g.,
15053         to perform a longjump in that case.
15054         * lib/openat.c: Include dirname.h.
15055         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
15056         (rpl_openat, fdopendir, fstatat): Call openat_save_die
15057         and openat_restore_die rather than calling error directly.
15058         Don't include "error.h" or "exitfail.h"; they're no longer needed.
15059
15060         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
15061         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
15062         define.
15063
15064         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
15065         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
15066                             int utc, int nanoseconds);
15067         Background:
15068         date should not have to allocate a megabyte of virtual memory to
15069         handle a format argument like +%1048575T.  When implemented with
15070         strftime, it must allocate such a buffer, use strftime to fill it
15071         in, print it, then free it.
15072         With fprintftime, it simply prints everything and exits.
15073         With no need for memory allocation, that's one fewer way to fail.
15074         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
15075         optional field width, not before, so we accept %9:z, not %:9z.
15076         (my_strftime): Be sure to use L_('x') for literals.
15077
15078         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
15079         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
15080         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
15081         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
15082         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
15083         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
15084         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
15085         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
15086         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
15087         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
15088         * lib/xgethostname.c, lib/xreadlink.c:
15089         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
15090
15091         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
15092         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
15093         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
15094         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
15095         and don't include <sys/file.h>).
15096
15097 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
15098
15099         Sync from coreutils.
15100
15101         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
15102         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
15103         [!LDAV_DONE]: Avoid unused variable warning.
15104
15105 2005-09-21  Bruno Haible  <bruno@clisp.org>
15106
15107         * lib/unicodeio.h (unicode_to_mb): New declaration.
15108
15109 2005-09-20  Derek Price  <derek@ximbiot.com>
15110
15111         * lib/getaddrinfo.c: Don't include <netdb.h> included from
15112         getaddrinfo.h.
15113
15114 2005-09-20  Bruno Haible  <bruno@clisp.org>
15115
15116         * gnulib-tool: Remove trailing slashes from the values specified for
15117         --source-base, --m4-base, --tests-base, --aux-dir.
15118         Suggested by Simon Josefsson <jas@extundo.com>.
15119
15120 2005-09-20  Bruno Haible  <bruno@clisp.org>
15121
15122         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
15123         func_modules_to_filelist, func_import, func_create_testdir): Make all
15124         sorting results locale-independent, so that gnulib-cache.m4 doesn't
15125         change when gnulib-tool is invoked in a different locale.
15126
15127 2005-09-19  Simon Josefsson  <jas@extundo.com>
15128
15129         * m4/socklen.m4: Fix typo.
15130
15131 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15132
15133         Use a consistent style for including <config.h>.
15134         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
15135         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
15136         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
15137         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
15138         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
15139         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
15140         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
15141         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
15142         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
15143         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
15144         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
15145         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
15146         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
15147         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
15148         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
15149         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
15150         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
15151         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
15152         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
15153         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
15154         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
15155         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
15156         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
15157         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
15158         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
15159         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
15160         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
15161         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
15162         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
15163         lib/xstrtoumax.c, lib/yesno.c:
15164         Standardize inclusion of config.h.
15165         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
15166         lib/inttostr.h:  Removed inclusion of config.h from header files.
15167         * lib/inttostr.c:  Adjusted in-tree users.
15168         * lib/timespec.h: Remove superfluous warning to include config.h.
15169         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
15170         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
15171         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
15172         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
15173         config.h with HAVE_CONFIG_H.
15174
15175 2005-09-19  Jim Meyering  <jim@meyering.net>
15176
15177         * modules/pathmax (License): Change to LGPL.
15178
15179 2005-09-19  Derek Price  <derek@ximbiot.com>
15180
15181         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
15182
15183 2005-09-19  Bruno Haible  <bruno@clisp.org>
15184
15185         * gnulib-tool (import): Provide default for --tests-base.
15186
15187 2005-09-19  Bruno Haible  <bruno@clisp.org>
15188
15189         * doc/quote.texi: New file, extracted from gnulib.texi.
15190         * doc/ctime.texi: New file, extracted from gnulib.texi.
15191         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
15192         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
15193         * doc/gnulib.texi: Include them.
15194
15195 2005-09-18  Bruno Haible  <bruno@clisp.org>
15196
15197         Portability fix.
15198         * gnulib-tool (func_readlink): New function.
15199         (func_ln_if_changed): Use it.
15200
15201 2005-09-18  Bruno Haible  <bruno@clisp.org>
15202
15203         * gnulib-tool: Support --with-tests also with --import.
15204         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
15205         (func_import): Use variables $testsbase and $inctests. Emit a
15206         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
15207         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
15208         SUBDIRS += $testsdir.
15209         (func_create_testdir): Update.
15210
15211 2005-09-18  Bruno Haible  <bruno@clisp.org>
15212
15213         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
15214         instead of $dry_run.
15215         (func_cp_if_changed, func_mv_if_changed): Remove functions.
15216         (func_ln_if_changed): Don't handle dry-run here.
15217         (func_import): In dry-run mode, detect more precisely which actions
15218         would be performed, and don't use "...ing" verbs.
15219
15220 2005-09-18  Bruno Haible  <bruno@clisp.org>
15221
15222         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
15223         (func_import): Use join on two temporary files instead of three nested
15224         loops, in order to determine which files are new or old.
15225
15226 2005-09-18  Bruno Haible  <bruno@clisp.org>
15227
15228         * gnulib-tool (func_import): Comment out code that spits out the
15229         new files with --dry-run.
15230
15231 2005-09-18  Bruno Haible  <bruno@clisp.org>
15232
15233         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
15234
15235 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15236
15237         * lib/stat-time.h: New file.
15238         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
15239         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
15240         in a different way.
15241         (timespec_cmp): New function.
15242         * lib/utimecmp.c: Include stat-time.h.
15243         (SYSCALL_RESOLUTION): Depend on whether various struct stat
15244         members exist, not on the obsolescent ST_MTIM_NSEC.
15245         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
15246
15247 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15248
15249         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
15250
15251 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15252
15253         * MODULES.html.sh (File system functions): Add stat-time.
15254         * modules/stat-time: New file.
15255         * modules/timespec (Files): Remove m4/st_mtim.m4; this
15256         is now done in a different way, by the stat-time module.
15257         * modules/utimecmp (Depends-on): Add stat-time.
15258
15259 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
15260
15261         * m4/st_mtim.m4: Remove.  Superseded by...
15262         * m4/stat-time.m4: New file.
15263         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
15264         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
15265
15266 2005-09-15  Derek Price  <derek@ximbiot.com>
15267
15268         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
15269
15270 2005-09-15  Derek Price  <derek@ximbiot.com>
15271
15272         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
15273         * lib/regex_internal.c: Ditto, using this...
15274         (__GNUC_PREREQ): ...new macro.
15275         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
15276         using...
15277         (__GNUC_PREREQ): ...this new macro.
15278
15279         * lib/strstr.h: Include string.h. Define strstr as a macro here.
15280
15281 2005-09-15  Derek Price  <derek@ximbiot.com>
15282             Paul Eggert  <eggert@cs.ucla.edu>
15283
15284         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
15285         changes, consolidating in...
15286         * lib/regex_internal.h: ...this file.
15287
15288 2005-09-13  Jim Meyering  <jim@meyering.net>
15289
15290         * lib/canon-host.c: Filter through gnu indent and reword comments
15291         slightly.
15292         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
15293
15294 2005-09-13  Derek Price  <derek@ximbiot.com>
15295
15296         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
15297         failure.
15298         Reported by Jim Meyering  <jim@meyering.net>.
15299
15300 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15301
15302         * lib/base64.c: Typo.
15303         (base64_encode): Put b64str in initialized data section.
15304
15305 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
15306
15307         Merge glibc and coreutils changes into gnulib, plus a few
15308         extra fixes.
15309         * lib/md5.c: Use #error rather than a string.
15310         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
15311         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
15312         (__attribute__): Define to empty for non recent-GCC.
15313         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
15314         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
15315         Renamed from their non-__ counterparts, with new macros replacing
15316         them if not _LIBC.  Add __THROW attribute.
15317         (rol): Remove.
15318         (struct md5_ctx): Align buffer if using GCC.
15319         * lib/sha1.h (struct sha1_ctx): Likewise.
15320         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
15321         The old name was backwards.
15322         (NOTSWAP): Remove; not used.
15323         (rol): New macro, moved here from md5.h.
15324         (sha1_process_block): Remove a FIXME that doesn't make sense.
15325
15326 2005-09-12  Derek Price  <derek@ximbiot.com>
15327
15328         Return usable errors from canon-host.
15329         * lib/canon-host.h: New file.
15330         * lib/canon-host.c (canon_host): Wrap...
15331         (canon_host_r): ...this new function, which now relies exclusively on
15332         getaddrinfo.
15333         (ch_strerror): New function.
15334         (last_cherror): New global.
15335         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
15336         interface.
15337         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
15338         void *.
15339         (freeaddrinfo): Free ai->ai_canonname when set.
15340
15341 2005-09-12  Derek Price  <derek@ximbiot.com>
15342
15343         Make canon-host require getaddrinfo.
15344         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
15345         AC_LIBSOURCE canon-host.h.  Call...
15346         (gl_PREREQ_CANON_HOST): ...this new function, which requires
15347         gl_GETADDRINFO.
15348         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
15349
15350 2005-09-12  Derek Price  <derek@ximbiot.com>
15351
15352         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
15353         LGPL.
15354         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
15355
15356 2005-09-12  Derek Price  <derek@ximbiot.com>
15357
15358         * lib/gai_strerror.c: Include config.h when available.  Include
15359         getaddrinfo.h before other headers to test interface.
15360         Reported by Larry Jones <lawrence.jones@ugs.com>.
15361
15362 2005-09-12  Derek Price  <derek@ximbiot.com>
15363             Paul Eggert  <eggert@cs.ucla.edu>
15364
15365         * modules/glob (Files): Add glob-libc.h.
15366
15367 2005-09-12  Derek Price  <derek@ximbiot.com>
15368             Paul Eggert  <eggert@cs.ucla.edu>
15369
15370         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
15371         glob_.h, glob-libc.h.
15372         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
15373
15374 2005-09-12  Derek Price  <derek@ximbiot.com>
15375             Paul Eggert  <eggert@cs.ucla.edu>
15376
15377         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
15378         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
15379         protecting things that should be done only in gnulib contexts.
15380         * lib/glob_.h: New file, containing only the glob things needed for
15381         gnulib.
15382         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
15383         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
15384         (glob, globfree, glob_pattern_p): Now defined simply in terms of
15385         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
15386         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
15387         and to respect the namespace rules better.
15388
15389 2005-09-08  Simon Josefsson  <jas@extundo.com>
15390
15391         * modules/socklen: New file.
15392
15393 2005-09-08  Simon Josefsson  <jas@extundo.com>
15394
15395         * m4/socklen.m4: New file.
15396
15397 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15398
15399         * modules/utimens (Files): Add m4/utimbuf.m4, since
15400         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
15401         Reported by Sergey Poznyakoff.
15402
15403 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15404
15405         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
15406         definitions, since that's the preferred style in glibc.
15407         Fix a minor spacing issue, and update copyright notice to match
15408         glibc's.
15409
15410 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15411
15412         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
15413
15414 2005-09-06  Simon Josefsson  <jas@extundo.com>
15415
15416         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
15417         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
15418
15419 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15420
15421         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
15422         warning.
15423
15424 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15425
15426         * config/srclist.txt: Add glibc bug 1302.
15427
15428 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
15429
15430         Change bitset word type from unsigned int to unsigned long int,
15431         as this has better performance on typical 64-bit hosts.
15432         Port bitset code to hosts with unusual word sizes.
15433         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
15434         (build_collating_symbol):
15435         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
15436         argument is a bitset.  This is merely a style issue, but it makes
15437         it clearer that an entire array is expected.
15438         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
15439         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
15440         Port to the case where bitset_word is not the same as unsigned int.
15441         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
15442         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
15443         Likewise.
15444         * lib/regexec.c (check_dst_limits_calc_pos_1,
15445         check_subexp_matching_top):
15446         (build_trtable, group_nodes_into_DFAstates):
15447         Likewise.
15448         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
15449         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
15450         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
15451         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
15452         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
15453         * lib/regcomp.c (optimize_subexps, lower_subexp):
15454         Work even if bitset_word has holes in its bitwise representation.
15455         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
15456         * lib/regexec.c (check_dst_limits_calc_pos_1,
15457         check_subexp_matching_top):
15458         Likewise.
15459         * lib/regex_internal.c (re_string_reconstruct):
15460         Don't assume UCHAR_MAX == 255.
15461         * lib/regex_internal.h (bitset_set_all): Likewise.
15462         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
15463         All uses changed.
15464         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
15465         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
15466         All uses changed.
15467         (BITSET_WORD_MAX): New macro.
15468         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
15469         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
15470         (bitset_empty, bitset_copy):
15471         Prefer sizeof (bitset) to multiplying it out ourselves.
15472         (bitset_not_merge): Remove; unused.
15473         (bitset_contain): Return bool, not unsigned int with one bit on.
15474         All callers changed.
15475         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
15476         alignment than re_node_set; do this by defining a new internal
15477         type struct dests_alloc and using it to allocate memory.
15478
15479 2005-09-05  Bruno Haible  <bruno@clisp.org>
15480
15481         * gnulib-tool (func_import): Fix comparison in handling of symbolic
15482         links.
15483
15484 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
15485
15486         * modules/size_max (Makefile.am): Add size_max.h
15487
15488 2005-09-04  Derek Price  <derek@ximbiot.com>
15489
15490         * gnulib-tool (func_import): Fix reversed $symbolic logic.
15491
15492 2005-09-03  Simon Josefsson  <jas@extundo.com>
15493
15494         * gnulib-tool: Fix typo.
15495
15496 2005-09-03  Simon Josefsson  <jas@extundo.com>
15497
15498         * config/srclist.txt: Add glibc bug 1293.
15499
15500 2005-09-03  Derek Price  <derek@ximbiot.com>
15501
15502         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
15503         From Larry Jones <lawrence.jones@ugs.com>.
15504
15505 2005-09-02  Simon Josefsson  <jas@extundo.com>
15506
15507         * modules/socklen: New file.
15508
15509 2005-09-02  Simon Josefsson  <jas@extundo.com>
15510
15511         * modules/havelib: New module.
15512
15513         * modules/gettext, modules/iconv, modules/lock, modules/readline:
15514         Use havelib.
15515
15516 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
15517
15518         Check for arithmetic overflow when calculating sizes, to prevent
15519         some buffer-overflow issues.  These patches are conservative, in the
15520         sense that when I couldn't determine whether an overflow was possible,
15521         I inserted a run-time check.
15522         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
15523         macros.
15524         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
15525         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
15526         (re_xnrealloc, re_x2nrealloc): New inline functions.
15527         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
15528         parse_bracket_exp):
15529         (build_equiv_class, build_charclass): Check for arithmetic overflow
15530         in size expression calculations.
15531         * lib/regex_internal.c (re_string_realloc_buffers):
15532         (build_wcs_upper_buffer, re_node_set_add_intersect):
15533         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
15534         (re_dfa_add_node, register_state): Likewise.
15535         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
15536         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
15537         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
15538         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
15539
15540 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
15541
15542         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
15543         m4/ulonglong.m4.  Problem reported by Martin Lambers.
15544
15545 2005-09-02  Bruno Haible  <bruno@clisp.org>
15546
15547         Support for lib vs. lib64 distinction on biarch platforms.
15548         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
15549         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
15550         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
15551
15552 2005-09-02  Bruno Haible  <bruno@clisp.org>
15553
15554         * gnulib-tool (import): In the other first-use case, provide defaults
15555         as well.
15556
15557 2005-09-02  Bruno Haible  <bruno@clisp.org>
15558
15559         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
15560         patches not yet found in the latest gettext release.
15561
15562 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
15563
15564         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
15565         to avoid a collision with bits/local_lim.h in glibc.
15566         All uses changed.  Problem reported by Dmitry V. Levin in
15567         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
15568
15569         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
15570         bugs in int versus size_t comparisons.
15571         (re_string_context_at): Fix bug where the code assumed that
15572         Idx is signed.
15573
15574         Use bool where appropriate.
15575         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
15576         All callers changed.
15577         (calc_eclosure_iter): Likewise, for ROOT arg.
15578         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
15579         (build_charclass_op): Likewise, for NON_MATCH arg.
15580         * lib/regex_internal.c (re_string_allocate, re_string_construct):
15581         (re_string_construct_common): Likewise, for ICASE arg.
15582         * lib/regexec.c (re_search_2_stub, re_search_stub):
15583         Likewise, for RET_LEN arg.
15584         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
15585         (set_regs): Likewise, for FL_BACKTRACK arg.
15586         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
15587         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
15588         (calc_eclosure_iter, parse_bracket_exp):
15589         Use bool for internal variables that are booleans.
15590         * lib/regexec.c (re_search_internal, check_matching,
15591         proceed_next_node):
15592         (set_regs, build_sifted_states, sift_states_bkref):
15593         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
15594         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
15595         (find_collation_sequence_value):
15596         Likewise.
15597         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
15598         (re_node_set_compare):
15599         Return bool, not int. All callers changed.
15600         * lib/regexec.c (check_halt_node_context, check_dst_limits):
15601         (build_trtable, check_node_accept): Likewise.
15602         * lib/regex_internal.h: Include stdbool.h.
15603
15604         Fix bugs uncovered when converting to bool.
15605         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
15606         failure instead of charging ahead blindly.
15607         * lib/regex_internal.c (register_state): Likewise.
15608         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
15609         for freeing internal storage.
15610         (group_nodes_into_DFA_states): Use unsigned int, not int, for
15611         bitset pieces used as boolean, to avoid undefined behavior
15612         on hosts that do int overflow checking.
15613
15614 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
15615
15616         * config/srclist.txt: Add glibc bugs 1285-1287.
15617
15618 2005-09-01  Jim Meyering  <jim@meyering.net>
15619
15620         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
15621         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
15622         Require gl_STAT_MACROS, too.
15623
15624 2005-09-01  Bruno Haible  <bruno@clisp.org>
15625
15626         * gnulib-tool (import): In the first-use case, provide defaults.
15627
15628 2005-09-01  Bruno Haible  <bruno@clisp.org>
15629
15630         * gnulib-tool (func_import): Remove the .tmp files.
15631
15632 2005-09-01  Bruno Haible  <bruno@clisp.org>
15633
15634         * gnulib-tool (func_import): Fix handling of symbolic links.
15635
15636 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15637
15638         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
15639         old glibc regex code mishandles strings longer than 2**31 bytes.
15640         This patch fixes this when the regex code is used in gnulib
15641         (i.e., outside glibc).
15642
15643         This patch should not affect the use of the regex code inside
15644         glibc.  No doubt this problem also needs to be handled for glibc
15645         as well, but the result will be an incompatible change to the
15646         glibc ABI, and the old ABI will have to be supported too.  That
15647         can be the the subject for another patch.
15648
15649         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
15650         governing whether the rest of this patch is active.  By default,
15651         the macro is disabled and the patch has no effect.
15652         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
15653         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
15654         (struct re_pattern_buffer, re_search, re_search_2, re_match):
15655         (re_match_2, re_set_registers): Use the new types.
15656         * lib/regex_internal.h (Idx, re_hashval_t): New types.
15657         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
15658         New macros.
15659         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
15660         (re_string_context_at, bin_tree_t, re_dfastate_t):
15661         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
15662         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
15663         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
15664         (re_string_char_size_at, re_string_wchar_at):
15665         (re_string_elem_size_at):
15666         Use the new types and macros to port to 64-bit hosts.
15667         Use unsigned types for internal values, so that the code
15668         mostly works even for arrays larger than SSIZE_MAX.
15669         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
15670         (search_duplicated_node, calc_eclosure_iter, fetch_number):
15671         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
15672         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
15673         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
15674         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
15675         (calc_inveclosure, parse_dup_op, build_range_exp):
15676         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
15677         (fetch_number, create_token_tree, mark_opt_subexp):
15678         Likewise.
15679         * lib/regex_internal.c (re_string_construct_common,
15680         create_ci_newstate):
15681         (create_cd_newstate, re_string_allocate, re_string_construct):
15682         (re_string_realloc_buffers, build_wcs_upper_buffer):
15683         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
15684         (re_string_reconstruct, re_string_peek_byte_case):
15685         (re_string_fetch_byte_case, re_string_context_at):
15686         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
15687         (re_node_set_init_copy, re_node_set_add_intersect):
15688         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15689         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15690         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
15691         (re_acquire_state, re_acquire_state_context, register_state):
15692         Likewise.
15693         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
15694         search_cur_bkref_entry):
15695         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
15696         (re_search_internal, re_search_2_stub, re_search_stub)
15697         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
15698         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
15699         (update_cur_sifted_state, check_dst_limits):
15700         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
15701         (check_subexp_limits, sift_states_bkref, merge_state_array):
15702         (check_subexp_matching_top, get_subexp, get_subexp_sub):
15703         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
15704         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
15705         (expand_bkref_cache, check_node_accept_bytes):
15706         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
15707         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
15708         (acquire_init_state_context, check_halt_node_context):
15709         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
15710         (sift_states_backward, clean_state_log_if_needed):
15711         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
15712         (find_recover_state, transit_state_sb, transit_state_mb):
15713         (transit_state_bkref, build_trtable, match_ctx_clean):
15714         Likewise.
15715         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
15716         to work around an assumption that REG_MISSING is negative.
15717
15718         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
15719         (seek_collating_symbol_entry) [defined _LIBC]:
15720         (lookup_collation_sequence_value) [defined _LIBC]:
15721         (build_range_exp, build_collating_symbol) [defined _LIBC]:
15722         Use prototypes rather than old-style function definitions.
15723         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
15724         (transit_state_sb) [0]:
15725         (find_collation_sequence_value) [defined _LIBC]: Likewise.
15726
15727         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
15728         rm_eo.
15729
15730         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
15731         (optimize_subexps, lower_subexp):
15732         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
15733         since the signed shift might overflow.  Use 1u<<31 instead.
15734         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
15735         Likewise.
15736         * lib/regexec.c (check_dst_limits_calc_pos_1,
15737         check_subexp_matching_top): Likewise.
15738
15739         * lib/regcomp.c (optimize_subexps, lower_subexp):
15740         Use CHAR_BIT rather than 8, for clarity.
15741         * lib/regexec.c (check_dst_limits_calc_pos_1):
15742         (check_subexp_matching_top): Likewise.
15743         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
15744         have to worry about portability issues when shifting it left.
15745         Remove no-longer-needed test for table_size > 0.
15746         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
15747         in a word, as the resulting behavior is undefined.
15748         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
15749         in one case, a <= should have been an <, and in another case the
15750         whole test was missing.
15751         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
15752         the standard name CHAR_BIT.
15753         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
15754         this is not true on one's complement and signed-magnitude hosts.
15755
15756         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
15757         next_last_offset.
15758         (struct re_dfa_t): Remove unused member states_alloc.
15759         * lib/regcomp.c (init_dfa): Don't initialize unused members.
15760
15761 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15762
15763         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
15764         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
15765         and large-file glibc and in 32-bit large-file Solaris.
15766
15767 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15768
15769         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
15770         lengths fit in regoff_t; this isn't true if regoff_t is the same
15771         width as size_t.
15772         * lib/regex.c (re_search_internal): 5th arg is LAST_START
15773         (= START + RANGE) instead of RANGE.  This avoids overflow
15774         problems when regoff_t is the same width as size_t.
15775         All callers changed.
15776         (re_search_2_stub): Check for overflow when adding the
15777         sizes of the two strings.
15778         (re_search_stub): Check for overflow when adding START
15779         to RANGE; if it occurs, substitute the extreme value.
15780
15781 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15782
15783         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
15784
15785 2005-08-31  Jim Meyering  <jim@meyering.net>
15786
15787         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
15788         a pointer-to-const.
15789         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
15790         (register_state): Likewise.
15791         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
15792         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
15793         (group_nodes_into_DFAstates): Likewise.
15794
15795 2005-08-31  Jim Meyering  <jim@meyering.net>
15796
15797         * check-module: Add a FIXME comment.
15798
15799 2005-08-31  Eric Blake  <ebb9@byu.net>
15800
15801         * modules/unistd-safer (Files): Add unistd--.h.
15802         * modules/stdio-safer (Files): Add stdio--.h.
15803
15804 2005-08-31  Derek Price  <derek@ximbiot.com>
15805
15806         * lib/getdelim.c (getdelim): Return EOF on EOF.
15807         Reported by Larry Jones <lawrence.jones@ugs.com>.
15808
15809 2005-08-31  Bruno Haible  <bruno@clisp.org>
15810
15811         Avoid unnecessary diffs in the generated lib/Makefile.am.
15812         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
15813         the generated files.
15814         (func_import): Don't set cmd.
15815
15816 2005-08-31  Bruno Haible  <bruno@clisp.org>
15817
15818         * lib/strstr.c: Include <stddef.h>, for NULL.
15819         * lib/strcasestr.c: Likewise.
15820         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
15821
15822 2005-08-31  Bruno Haible  <bruno@clisp.org>
15823
15824         * gnulib-tool: New option --macro-prefix.
15825         (func_import): Use macro_prefix.
15826         (import): Handle option --macro-prefix.
15827
15828 2005-08-31  Bruno Haible  <bruno@clisp.org>
15829
15830         * gnulib-tool (import): Rename most ac_* variables to cached_*.
15831         Also use new variables cached_lgpl, cached_libtool.
15832
15833 2005-08-31  Bruno Haible  <bruno@clisp.org>
15834
15835         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
15836         always instantiating them.
15837
15838 2005-08-31  Bruno Haible  <bruno@clisp.org>
15839
15840         * gnulib-tool (func_import): Read the previous cached settings
15841         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
15842         earlier added by gnulib but are now dropped. Warn when a gnulib file
15843         overwrites a non-gnulib file.
15844
15845 2005-08-31  Bruno Haible  <bruno@clisp.org>
15846
15847         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
15848         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
15849         projects that don't keep autogenerated files in CVS. Put into
15850         actioncmd only the specified modules, not the transitive closure.
15851
15852 2005-08-31  Bruno Haible  <bruno@clisp.org>
15853
15854         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
15855         Create directories that shall be filled.
15856         (import): Don't look for gl_* macros in configure.ac. Recurse across
15857         all directories containing a gnulib-cache.m4 files, if meaningful.
15858
15859 2005-08-31  Bruno Haible  <bruno@clisp.org>
15860
15861         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
15862         (import): Set seen_libtool when we see gl_LIBTOOL.
15863
15864 2005-08-31  Bruno Haible  <bruno@clisp.org>
15865
15866         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
15867         declaration macro definitions from generated gnulib.m4.
15868
15869 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
15870
15871         * lib/iconvme.h: Add prototype for iconv_alloc.
15872
15873 2005-08-29  Simon Josefsson  <jas@extundo.com>
15874
15875         * lib/iconvme.c: Fix errno.
15876
15877 2005-08-29  Bruno Haible  <bruno@clisp.org>
15878
15879         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
15880         that it works when the directory contains spaces.
15881
15882 2005-08-29  Bruno Haible  <bruno@clisp.org>
15883
15884         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
15885
15886 2005-08-29  Bruno Haible  <bruno@clisp.org>
15887
15888         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
15889         Emit more advice.
15890
15891 2005-08-29  Bruno Haible  <bruno@clisp.org>
15892         and Stepan Kasal  <kasal@ucw.cz>
15893
15894         * check-module: If more parameters are given, check each of them
15895         separately; add more exceptions, as noted by Jim Meyering.
15896         (check_module): New procedure.
15897         (%exempt_header): Now contains all exceptions.
15898
15899 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
15900
15901         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
15902
15903 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
15904
15905         * lib/iconvme.c: Split iconv_string into iconv_alloc.
15906
15907 2005-08-28  Bruno Haible  <bruno@clisp.org>
15908
15909         * m4/gnulib-tool.m4: New file.
15910
15911 2005-08-27  Jim Meyering  <jim@meyering.net>
15912
15913         * modules/unistd-safer (Files): Add pipe-safer.c.
15914         * modules/fcntl-safer (Files): Add creat-safer.c.
15915
15916 2005-08-27  Jim Meyering  <jim@meyering.net>
15917
15918         * m4/stdlib-safer.m4: New file.  From coreutils.
15919         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
15920         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
15921         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
15922         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
15923         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
15924
15925 2005-08-27  Jim Meyering  <jim@meyering.net>
15926
15927         * lib/fopen-safer.c: Merge minor changes from coreutils.
15928         * lib/dup-safer.c: Likewise.
15929         * lib/fd-safer.c: Likewise.
15930
15931         Merge from coreutils.
15932         * lib/stdio--.h: New file.
15933         * lib/stdlib--.h: New file.
15934         * lib/mkstemp-safer.c: New file.
15935
15936         GNU tar needs these.
15937         * lib/pipe-safer.c: New file.
15938         * lib/creat-safer.c: New file.
15939         * lib/fcntl--.h (creat): Define to creat_safer.
15940         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
15941         * lib/unistd--.h (pipe): Define to pipe_safer.
15942         * lib/unistd-safer.h: Declare pipe_safer.
15943
15944 2005-08-26  Simon Josefsson  <jas@extundo.com>
15945
15946         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
15947         Haible <bruno@clisp.org>.
15948
15949 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
15950
15951         * lib/regex_internal.h: Remove all references to
15952         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
15953         or better.
15954         (bitset_not, bitset_merge, bitset_not_merge):
15955         (bitset_mask, re_string_allocate, re_string_construct):
15956         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
15957         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
15958         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
15959         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
15960         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15961         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15962         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
15963         (re_acquire_state_context):
15964         Remove unnecessary forward decls.
15965         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
15966         Put __attribute at function definition,
15967         now that the function decl has been removed.
15968         * lib/regex_internal.c (re_string_peek_byte_case):
15969         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
15970         Likewise.
15971
15972 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
15973
15974         * m4/regex.m4: Add AC_PREREQ(2.50).
15975         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
15976
15977 2005-08-25  Simon Josefsson  <jas@extundo.com>
15978
15979         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
15980         __fsetlocking.
15981
15982 2005-08-25  Simon Josefsson  <jas@extundo.com>
15983
15984         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
15985         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
15986         GLIBC specific code.
15987
15988 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15989
15990         Make regex safe for g++.  This fixes one real bug (an "err"
15991         that should have been "*err").  g++ problem reported by
15992         Sam Steingold.
15993         * lib/regex_internal.h (re_calloc): New macro, consistent with
15994         re_malloc etc.  All callers of calloc changed to use re_calloc.
15995         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
15996         not int.  All callers changed.
15997         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
15998         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
15999         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
16000         (find_recover_state): Change "err" to "*err"; this fixes what
16001         appears to be a real bug.
16002         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
16003         versus int.
16004
16005 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16006
16007         * modules/regex (Depends-on): Add malloc, since the code
16008         assumes that !malloc(0) means failure.
16009
16010 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16011
16012         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
16013
16014         alloca modernization/simplification for regex.
16015         * lib/regex.c: Remove portability cruft for alloca.  This no longer
16016         needs to be at the start of the file, and can be moved into
16017         regex_internal.h and simplified.
16018         * lib/regex_internal.h: Include <alloca.h>.
16019         (__libc_use_alloca) [!defined _LIBC]: New macro.
16020         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
16021         now works outside glibc.
16022
16023 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16024
16025         * config/srclist.txt: Add glibc bugs 1241, 1245.
16026
16027 2005-08-25  Jim Meyering  <jim@meyering.net>
16028
16029         * lib/open-safer.c: Include <config.h>.
16030         Otherwise, we'd lose LARGEFILE support in any file using
16031         e.g. "fcntl--.h"
16032
16033 2005-08-25  Bruno Haible  <bruno@clisp.org>
16034
16035         * m4/minmax.m4: Require autoconf 2.52.
16036         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
16037         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
16038         alternatives of translit over the alphabet.
16039         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
16040
16041 2005-08-24  Simon Josefsson  <jas@extundo.com>
16042
16043         * tests/test-getpass.c: New file.
16044
16045 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16046
16047         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
16048         for GNU regex features.
16049
16050 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16051
16052         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
16053         * lib/regex.h (regerror): Likewise.
16054
16055         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
16056         requires this.  (The code never needed it.)
16057
16058         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
16059         All uses of recently-renamed identifiers changed to use the new,
16060         POSIX-compliant names.  The code will build and run just fine
16061         without these changes, but it's better to eat our own dog food
16062         and use the standard-conforming names.
16063
16064         * lib/regex.h: Fix a multitude of POSIX name space violations.
16065         These changes have an effect only for programs that define
16066         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
16067         do not change anything for programs compiled in the normal way.
16068         Also, there is no effect on the ABI.
16069
16070         (_REGEX_SOURCE): New macro.
16071         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
16072         defined and _GNU_SOURCE is not; this fixes a name space violation.
16073
16074         Rename the following macros to obey POSIX requirements.
16075         The old names are still visible as macros if _REGEX_SOURCE is defined.
16076         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
16077         RE_BACKSLASH_ESCAPE_IN_LISTS.
16078         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
16079         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
16080         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
16081         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
16082         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
16083         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
16084         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
16085         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
16086         (REG_INTERVALS): renamed from RE_INTERVALS.
16087         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
16088         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
16089         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
16090         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
16091         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
16092         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
16093         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
16094         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
16095         RE_UNMATCHED_RIGHT_PAREN_ORD.
16096         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
16097         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
16098         (REG_DEBUG): renamed from RE_DEBUG.
16099         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
16100         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
16101         unusual, since we can't clash with the POSIX REG_ICASE.
16102         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
16103         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
16104         (REG_NO_SUB): renamed from RE_NO_SUB.
16105         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
16106         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
16107         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
16108         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
16109         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
16110         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
16111         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
16112         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
16113         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
16114         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
16115         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
16116         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
16117         RE_SYNTAX_POSIX_MINIMAL_BASIC.
16118         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
16119         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
16120         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
16121         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
16122         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
16123         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
16124         (REG_FIXED): Renamed from REGS_FIXED.
16125         (REG_NREGS): Renamed from RE_NREGS.
16126
16127         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
16128         of other REG_* macros, since POSIX says the user is allowed to
16129         #undef these macros selectively.
16130
16131         (reg_errcode_t): Update comment stating what other tables need
16132         to be consistent.
16133
16134         Rename the following enum values to obey POSIX requirements.
16135         The old names are still visible as macros.
16136         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
16137         is not defined, since GNU is supposed to be a superset of POSIX as
16138         much as possible, and since we want reg_errcode_t to be a signed
16139         type for implementation consistency.
16140         (_REG_NOERROR): Renamed from REG_NOERROR.
16141         (_REG_NOMATCH): Renamed from REG_NOMATCH.
16142         (_REG_BADPAT): Renamed from REG_BADPAT.
16143         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
16144         (_REG_ECTYPE): Renamed from REG_ECTYPE.
16145         (_REG_EESCAPE): Renamed from REG_EESCAPE.
16146         (_REG_ESUBREG): Renamed from REG_ESUBREG.
16147         (_REG_EBRACK): Renamed from REG_EBRACK.
16148         (_REG_EPAREN): Renamed from REG_EPAREN.
16149         (_REG_EBRACE): Renamed from REG_EBRACE.
16150         (_REG_BADBR): Renamed from REG_BADBR.
16151         (_REG_ERANGE): Renamed from REG_ERANGE.
16152         (_REG_ESPACE): Renamed from REG_ESPACE.
16153         (_REG_BADRPT): Renamed from REG_BADRPT.
16154         (_REG_EEND): Renamed from REG_EEND.
16155         (_REG_ESIZE): Renamed from REG_ESIZE.
16156         (_REG_ERPAREN): Renamed from REG_ERPAREN.
16157         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
16158         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
16159         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
16160         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
16161
16162         (_REG_RE_NAME, _REG_RM_NAME): New macros.
16163         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
16164         changed.  But support the old name if the new one is not defined
16165         and if _REGEX_SOURCE.
16166
16167         Change the following member names in struct re_pattern_buffer.
16168         The old names are still supported if !_REGEX_SOURCE.
16169         The new names are always supported, regardless of _REGEX_SOURCE.
16170         (re_buffer): Renamed from buffer.
16171         (re_allocated): Renamed from allocated.
16172         (re_used): Renamed from used.
16173         (re_syntax): Renamed from syntax.
16174         (re_fastmap): Renamed from fastmap.
16175         (re_translate): Renamed from translate.
16176         (re_can_be_null): Renamed from can_be_null.
16177         (re_regs_allocated): Renamed from regs_allocated.
16178         (re_fastmap_accurate): Renamed from fastmap_accurate.
16179         (re_no_sub): Renamed from no_sub.
16180         (re_not_bol): Renamed from not_bol.
16181         (re_not_eol): Renamed from not_eol.
16182         (re_newline_anchor): Renamed from newline_anchor.
16183
16184         Change the following member names in struct re_registers.
16185         The old names are still supported if !_REGEX_SOURCE.
16186         The new names are always supported, regardless of _REGEX_SOURCE.
16187         (rm_num_regs): Renamed from num_regs.
16188         (rm_start): Renamed from start.
16189         (rm_end): Renamed from end.
16190
16191         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
16192         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
16193         Prepend __ to parameter names.
16194
16195         Undo yesterday's changes.
16196
16197 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16198
16199         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
16200         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
16201         lib/regex.c.
16202
16203 2005-08-24  Jim Meyering  <jim@meyering.net>
16204
16205         Sync from coreutils.
16206         * m4/fcntl-safer.m4: New file.
16207
16208         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
16209         and object files for this module.
16210
16211 2005-08-24  Jim Meyering  <jim@meyering.net>
16212
16213         Sync from coreutils.
16214         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
16215
16216 2005-08-24  Jim Meyering  <jim@meyering.net>
16217
16218         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
16219         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
16220
16221 2005-08-24  Jim Meyering  <jim@meyering.net>
16222
16223         * modules/fcntl-safer: New module.
16224         * modules/fts (Depends-on): Add fcntl-safer.
16225         * MODULES.html.sh (File descriptor based Input/Output):
16226         Add fcntl-safer.
16227
16228 2005-08-24  Bruno Haible  <bruno@clisp.org>
16229
16230         Support for unit test modules.
16231         * modules/README: Mention tests modules.
16232         * modules/TEMPLATE-TESTS: New file.
16233         * gnulib-tool: New options --extract-tests-module, --with-tests and
16234         --tests-base (unused for the moment).
16235         (testsbase, inctests): New variables.
16236         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
16237         (func_verify_module): Exclude TEMPLATE-TESTS.
16238         (func_verify_nontests_module, func_verify_tests_module): New functions.
16239         (func_get_dependencies): Add implicit dependency for tests modules.
16240         (func_get_tests_module): New function.
16241         (func_modules_transitive_closure): When --with-tests was specified,
16242         include the unit tests as well, unless explicitly avoided.
16243         (func_emit_lib_Makefile_am): Ignore the tests modules here.
16244         (func_emit_tests_Makefile_am): New function.
16245         (func_create_testdir): When --with-tests was specified, emit a
16246         tests/ directory.
16247         * MODULES.html.sh (Future developments): Update.
16248
16249 2005-08-24  Bruno Haible  <bruno@clisp.org>
16250
16251         * modules/tls-tests: New file.
16252         * tests/test-tls.c: New file, from GNU gettext.
16253
16254 2005-08-24  Bruno Haible  <bruno@clisp.org>
16255
16256         * modules/lock-tests: New file.
16257         * tests/test-lock.c: New file, from GNU gettext.
16258
16259 2005-08-24  Bruno Haible  <bruno@clisp.org>
16260
16261         * lib/lock.h: Add multiple inclusion guard.
16262         * lib/tls.h: Add multiple inclusion guard.
16263
16264 2005-08-24  Bruno Haible  <bruno@clisp.org>
16265
16266         * gnulib-tool: Add support for the --aux-dir option to
16267         --create-testdir, --create-megatestdir, --test, --megatest.
16268         (func_create_testdir, func_create_megatestdir): Optionally emit a
16269         AC_CONFIG_AUX_DIR directive.
16270         (create-testdir, create-megatestdir, test, megatest): Provide a
16271         default value for $auxdir.
16272
16273 2005-08-24  Bruno Haible  <bruno@clisp.org>
16274
16275         * gnulib-tool (import): Use compound statement instead of subshell
16276         where possible.
16277
16278 2005-08-24  Bruno Haible  <bruno@clisp.org>
16279
16280         * gnulib-tool (import): Change --aux-dir default to "build-aux".
16281
16282 2005-08-24  Bruno Haible  <bruno@clisp.org>
16283
16284         * gnulib-tool (func_version): Update.
16285
16286 2005-08-24  Bruno Haible  <bruno@clisp.org>
16287
16288         * gnulib-tool (func_import, func_create_testdir,
16289         func_create_megatestdir): Quote all autoconf macro arguments.
16290
16291 2005-08-24  Bruno Haible  <bruno@clisp.org>
16292
16293         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
16294         option --force, because --force causes the aclocal.m4 of each
16295         subdirectory to be newer than the corresponding config.h.in.
16296
16297 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16298
16299         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
16300         All contents moved to gl_REGEX.
16301         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
16302         assume that it does.
16303
16304 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16305
16306         * lib/regex.h (REG_NOSYS)
16307         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
16308         Define, since POSIX requires it as of 2001.
16309         (_REG_ENOSYS)
16310         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
16311         New private symbol, used to keep the enum signed in all cases.
16312         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
16313         Youngman in
16314         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
16315
16316         * lib/regex_internal.c (re_string_skip_chars, register_state):
16317         (calc_state_hash):
16318         Remove forward decls; no longer needed now that we use prototypes.
16319         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
16320         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
16321         (clean_state_log_if_needed): Likewise.
16322
16323 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16324
16325         * config/srclist.txt: Add glibc bugs 1231-1233.
16326
16327 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16328
16329         Fix problems reported by Sam Steingold in
16330         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
16331         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
16332         assumed that reg_errcode_t is a signed type, which is not
16333         necessarily true if _XOPEN_SOURCE is not defined.
16334         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
16335         since some compilers warn about it otherwise.
16336
16337 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16338
16339         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
16340         (init_word_char, create_initial_state, duplicate_node_closure):
16341         (fetch_token, peek_token_bracket, build_range_exp):
16342         (build_collating_symbol): Remove forward decls; no longer needed
16343         now that we use prototypes.
16344
16345         * lib/regcomp.c:
16346         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
16347         (re_compile_fastmap_iter, regcomp, regerror, regfree):
16348         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
16349         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
16350         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
16351         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
16352         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
16353         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
16354         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
16355         (build_range_exp, build_collating_symbol, parse_bracket_exp):
16356         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
16357         (build_charclass, build_charclass_op, fetch_number, create_tree):
16358         (create_token_tree, mark_opt_subexp, duplicate_tree):
16359         Use prototypes rather than old-style definitions.
16360
16361         * lib/regex_internal.c:
16362         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
16363         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
16364         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
16365         (re_string_reconstruct, re_string_peek_byte_case):
16366         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
16367         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
16368         (re_node_set_init_copy, re_node_set_add_intersect):
16369         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
16370         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
16371         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
16372         (re_acquire_state, re_acquire_state_context, register_state):
16373         (create_ci_newstate, create_cd_newstate, free_state):
16374         Likewise.
16375         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
16376         re_search_2):
16377         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
16378         (re_search_internal, prune_impossible_nodes):
16379         (acquire_init_state_context, check_matching, static):
16380         (check_halt_node_context, check_halt_state_context, proceed_next_node):
16381         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
16382         (update_regs, sift_states_backward, build_sifted_states):
16383         (clean_state_log_if_needed, merge_state_array):
16384         (update_cur_sifted_state, add_epsilon_src_nodes):
16385         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
16386         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
16387         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
16388         (find_recover_state, check_subexp_matching_top, transit_state_mb):
16389         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
16390         (check_arrival, check_arrival_add_next_nodes):
16391         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
16392         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
16393         (check_node_accept_bytes, check_node_accept, extend_buffers):
16394         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
16395         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
16396         (sift_ctx_init):
16397         Likewise.
16398
16399         * lib/regex_internal.h:
16400         (re_string_allocate, re_string_construct, re_string_reconstruct):
16401         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
16402         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
16403         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
16404         (re_string_context_at, re_string_peek_byte_case):
16405         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
16406         is defined, since we now use prototypes always.
16407
16408         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
16409         C89 or better.  All uses removed.
16410
16411 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16412
16413         * config/srclist.txt: Add glibc bugs 1220-1227.
16414
16415 2005-08-20  Jim Meyering  <jim@meyering.net>
16416
16417         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
16418         of unused local, dfa.
16419
16420 2005-08-20  Bruno Haible  <bruno@clisp.org>
16421
16422         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
16423
16424 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16425
16426         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
16427         (re_node_set_insert_last, re_dfa_add_node):
16428         Rename local variables to avoid GCC shadowing warnings.
16429
16430 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16431
16432         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
16433         [defined lint]: Suppress bogus uninitialized-variable warnings.
16434
16435         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
16436         and let the caller return REG_ESPACE if out of space.  This
16437         removes an uninitialied-variable warning with GCC 4.0.1, and also
16438         avoids taking the address of a local variable.  All callers
16439         changed.
16440
16441 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16442
16443         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
16444         $LIBCSRC/posix/regexec.c.
16445         Add glibc bug 1217 for regcomp.c.
16446
16447 2005-08-19  Jim Meyering  <jim@meyering.net>
16448
16449         * lib/regexec.c (proceed_next_node): Redo local variables to
16450         avoid GCC shadowing warnings.
16451
16452 2005-08-18  Bruno Haible  <bruno@clisp.org>
16453
16454         * lib/strstr.c (strstr): Fix return value in multibyte case.
16455         * lib/strcasestr.c (strcasestr): Likewise.
16456
16457 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
16458
16459         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
16460
16461 2005-08-17  Jim Meyering  <jim@meyering.net>
16462
16463         Make the %s format (seconds since the epoch) work for a negative
16464         number and when used with a zero-padded field width, e.g. %015s.
16465
16466         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
16467         label so that it precedes the code to set `digits'.  Otherwise,
16468         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
16469         print `00-22'.  Now, it prints `-0022', as it should.
16470
16471 2005-08-17  Bruno Haible  <bruno@clisp.org>
16472
16473         * modules/strstr (Files): Add m4/mbrtowc.m4.
16474         (Depends-on): Add mbuiter.
16475
16476 2005-08-17  Bruno Haible  <bruno@clisp.org>
16477
16478         * modules/strcasestr: New file.
16479         * MODULES.html.sh (String handling, based on ANSI C 89): Add
16480         strcasestr.
16481
16482 2005-08-17  Bruno Haible  <bruno@clisp.org>
16483
16484         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
16485
16486 2005-08-17  Bruno Haible  <bruno@clisp.org>
16487
16488         * modules/mbuiter: New file.
16489         * MODULES.html.sh (Extended multibyte and wide character utilities):
16490         Add mbuiter.
16491
16492 2005-08-17  Bruno Haible  <bruno@clisp.org>
16493
16494         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
16495         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
16496
16497 2005-08-17  Bruno Haible  <bruno@clisp.org>
16498
16499         * m4/strcasestr.m4: New file.
16500
16501 2005-08-17  Bruno Haible  <bruno@clisp.org>
16502
16503         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
16504         * lib/strstr.c: Completely rewritten, with multibyte locale support.
16505
16506 2005-08-17  Bruno Haible  <bruno@clisp.org>
16507
16508         * lib/strcasestr.h: New file.
16509         * lib/strcasestr.c: New file.
16510
16511 2005-08-17  Bruno Haible  <bruno@clisp.org>
16512
16513         * lib/strcasecmp.c: Use mbuiter.h.
16514
16515 2005-08-17  Bruno Haible  <bruno@clisp.org>
16516
16517         * lib/mbuiter.h: New file.
16518
16519 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
16520
16521         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
16522         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
16523         and gl_GETOPT are both invoked via different paths (as happens
16524         with GNU tar CVS because it uses both argp and getopt), the former
16525         wins.
16526
16527 2005-08-16  Bruno Haible  <bruno@clisp.org>
16528
16529         * modules/tls: New file.
16530         * MODULES.html.sh (Multithreading): Add tls.
16531
16532 2005-08-16  Bruno Haible  <bruno@clisp.org>
16533
16534         * modules/strnlen1: New file.
16535         * MODULES.html.sh (String handling): Add strnlen1.
16536
16537 2005-08-16  Bruno Haible  <bruno@clisp.org>
16538
16539         * modules/strcase (Files): Add m4/mbrtowc.m4.
16540         (Depends-on): Add strnlen1, mbchar.
16541
16542 2005-08-16  Bruno Haible  <bruno@clisp.org>
16543
16544         * modules/mbiter: New file.
16545         * MODULES.html.sh (Extended multibyte and wide character utilities):
16546         Add mbiter.
16547
16548 2005-08-16  Bruno Haible  <bruno@clisp.org>
16549
16550         * modules/mbfile: New file.
16551         * MODULES.html.sh (Extended multibyte and wide character utilities):
16552         Add mbfile.
16553
16554 2005-08-16  Bruno Haible  <bruno@clisp.org>
16555
16556         * modules/mbchar: New file.
16557         * MODULES.html.sh (Extended multibyte and wide character utilities):
16558         New section.
16559
16560 2005-08-16  Bruno Haible  <bruno@clisp.org>
16561
16562         * m4/tls.m4: New file, from GNU gettext.
16563
16564 2005-08-16  Bruno Haible  <bruno@clisp.org>
16565
16566         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
16567         always.
16568         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
16569
16570 2005-08-16  Bruno Haible  <bruno@clisp.org>
16571
16572         * m4/mbiter.m4: New file.
16573
16574 2005-08-16  Bruno Haible  <bruno@clisp.org>
16575
16576         * m4/mbfile.m4: New file.
16577
16578 2005-08-16  Bruno Haible  <bruno@clisp.org>
16579
16580         * m4/mbchar.m4: New file.
16581
16582 2005-08-16  Bruno Haible  <bruno@clisp.org>
16583
16584         * lib/tls.h: New file, from GNU gettext.
16585         * lib/tls.c: New file, from GNU gettext.
16586
16587 2005-08-16  Bruno Haible  <bruno@clisp.org>
16588
16589         * lib/strnlen1.h: New file.
16590         * lib/strnlen1.c: New file.
16591
16592 2005-08-16  Bruno Haible  <bruno@clisp.org>
16593
16594         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
16595         (mbi_init): Update.
16596         (mbi_avail, mbi_advance): Let the iteration end before the terminating
16597         NUL byte, not after it.
16598
16599 2005-08-16  Bruno Haible  <bruno@clisp.org>
16600
16601         * lib/strcase.h (strcasecmp): Add note in comments.
16602         * lib/strncasecmp.c: Use code from strcasecmp.c.
16603         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
16604         (strcasecmp): Work correctly in multibyte locales.
16605
16606 2005-08-16  Bruno Haible  <bruno@clisp.org>
16607
16608         * lib/mbiter.h: New file.
16609
16610 2005-08-16  Bruno Haible  <bruno@clisp.org>
16611
16612         * lib/mbfile.h: New file.
16613
16614 2005-08-16  Bruno Haible  <bruno@clisp.org>
16615
16616         * lib/mbchar.h: New file.
16617         * lib/mbchar.c: New file.
16618
16619 2005-08-16  Bruno Haible  <bruno@clisp.org>
16620
16621         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
16622         the valid ones. Makes the comparison operations transitive:
16623         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
16624         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
16625
16626 2005-08-15  Simon Josefsson  <jas@extundo.com>
16627
16628         * modules/ssize_t (License): Change to 'unlimited'.
16629
16630         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
16631
16632 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
16633
16634         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
16635         Add comments for each pending glibc patch.
16636
16637 2005-08-15  Bruno Haible  <bruno@clisp.org>
16638
16639         * lib/regex.h (__restrict_arr): Don't define to __restrict if
16640         __cplusplus is defined.
16641
16642 2005-08-14  Jim Meyering  <jim@meyering.net>
16643
16644         Sync from coreutils.
16645
16646         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
16647         Use the hash-table-based cycle-detection code not just when
16648         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
16649         Reported by James Youngman in
16650         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
16651         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
16652         FTS_TIGHT_CYCLE_CHECK.
16653         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
16654         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
16655         once again.
16656         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
16657         * lib/fts.c (fd_safer): Remove decl.
16658         Include fcntl--.h rather than unistd-safer.h
16659         (fts_safe_changedir): Don't call fd_safer; no longer needed
16660         now that we include fcntl--.h.
16661
16662 2005-08-12  Simon Josefsson  <jas@extundo.com>
16663
16664         * modules/getndelim2: Use ssize_t module.
16665         * modules/getnline: Likewise.
16666         * modules/safe-read: Likewise.
16667         * modules/xreadlink: Likewise.
16668
16669         * modules/ssize_t: New file.
16670
16671 2005-08-12  Simon Josefsson  <jas@extundo.com>
16672
16673         * m4/readline.m4: Look for termcap, curses or ncurses if required.
16674
16675 2005-08-12  Simon Josefsson  <jas@extundo.com>
16676
16677         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16678         ssize_t.
16679
16680 2005-08-12  Simon Josefsson  <jas@extundo.com>
16681
16682         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
16683         readline, getdelim and check_version.
16684         (Support for systems lacking ISO C 99: Sizes of integer types):
16685         Add size_max.
16686
16687 2005-08-12  Bruno Haible  <bruno@clisp.org>
16688
16689         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
16690
16691 2005-08-11  Simon Josefsson  <jas@extundo.com>
16692
16693         * modules/readline: New file.
16694
16695         * modules/strnlen (Files): Add strnlen.h.
16696
16697 2005-08-11  Simon Josefsson  <jas@extundo.com>
16698
16699         * m4/readline.m4: New file.
16700
16701 2005-08-11  Simon Josefsson  <jas@extundo.com>
16702
16703         * lib/readline.h, readline.c: New file.
16704
16705 2005-08-11  Simon Josefsson  <jas@extundo.com>
16706
16707         * doc/gnulib.texi (Initial import, Finishing touches): Mention
16708         gl_AVOID.
16709
16710 2005-08-11  Bruno Haible  <bruno@clisp.org>
16711
16712         * lib/strnlen.h (strnlen): Change parameter name to match comment.
16713
16714 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
16715
16716         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
16717
16718 2005-08-10  Simon Josefsson  <jas@extundo.com>
16719
16720         * tests/test-iconvme.c: New file.
16721
16722 2005-08-10  Simon Josefsson  <jas@extundo.com>
16723
16724         * m4/strnlen.m4: New file.
16725
16726         * m4/strndup.m4: Don't check for strnlen declaration, done in
16727         strnlen.m4.
16728
16729 2005-08-10  Simon Josefsson  <jas@extundo.com>
16730
16731         * lib/strndup.c: Use strnlen.h.
16732
16733         * lib/strnlen.h: New file.
16734
16735 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
16736
16737         * README: Typos.
16738
16739 2005-08-02  Simon Josefsson  <jas@extundo.com>
16740
16741         * modules/readline: New file.
16742
16743 2005-08-02  Simon Josefsson  <jas@extundo.com>
16744
16745         * modules/getdelim: New file.
16746
16747         * modules/getline: Rewrite, don't use getndelim2.
16748
16749 2005-08-02  Simon Josefsson  <jas@extundo.com>
16750
16751         * m4/getline.m4: Separate out getdelim stuff into separate module.
16752
16753         * m4/getdelim.m4: New file.
16754
16755 2005-08-02  Simon Josefsson  <jas@extundo.com>
16756
16757         * lib/getline.h, getline.c: Rewrite.
16758
16759         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
16760
16761 2005-07-31  Bruno Haible  <bruno@clisp.org>
16762
16763         * lib/lock.h (gl_lock_initializer): New macro.
16764         (gl_lock_define_initialized): Use it.
16765         (gl_rwlock_initializer): New macro.
16766         (gl_rwlock_define_initialized): Use it.
16767         (gl_recursive_lock_initializer): New macro.
16768         (gl_recursive_lock_define_initialized): Use it.
16769
16770 2005-07-30  Karl Berry  <karl@gnu.org>
16771
16772         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
16773         Report from Ben Pfaff, regarding getopt.
16774
16775 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
16776
16777         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
16778         normal way.
16779         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
16780         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
16781         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
16782         (gl_GETOPT): Use the new macros.  Most of the implementation
16783         is moved to the new macros.  This is for programs like Emacs
16784         that don't want all the functionality of gl_GETOPT.
16785
16786 2005-07-26  Bruno Haible  <bruno@clisp.org>
16787
16788         * m4/lock.m4: Update from GNU gettext.
16789
16790 2005-07-26  Bruno Haible  <bruno@clisp.org>
16791
16792         * lib/lock.h: Update from GNU gettext.
16793         * lib/lock.c: Update from GNU gettext.
16794
16795 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
16796
16797         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
16798         obsolescent AC_TRY_RUN.  Include the default includes files, for
16799         'exit'.
16800
16801 2005-07-24  Bruno Haible  <bruno@clisp.org>
16802
16803         * modules/visibility: New file.
16804         * MODULES.html.sh (Misc): Add visibility.
16805
16806 2005-07-24  Bruno Haible  <bruno@clisp.org>
16807
16808         * m4/visibility.m4: New file.
16809
16810 2005-07-24  Bruno Haible  <bruno@clisp.org>
16811
16812         * doc/visibility.texi: New file.
16813
16814 2005-07-22  Bruno Haible  <bruno@clisp.org>
16815
16816         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
16817         $(ALLOCA_H), redundant through BUILT_SOURCES.
16818         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
16819         redundant through BUILT_SOURCES.
16820         * modules/byteswap (Makefile.am): Remove explicit dependency on
16821         $(BYTESWAP_H), redundant through BUILT_SOURCES.
16822         * modules/fnmatch (Makefile.am): Remove explicit dependency on
16823         $(FNMATCH_H), redundant through BUILT_SOURCES.
16824         * modules/getopt (Makefile.am): Remove explicit dependency on
16825         $(GETOPT_H), redundant through BUILT_SOURCES.
16826         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
16827         redundant through BUILT_SOURCES.
16828         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
16829         redundant through BUILT_SOURCES.
16830         * modules/stdbool (Makefile.am): Remove explicit dependency on
16831         $(STDBOOL_H), redundant through BUILT_SOURCES.
16832         * modules/stdint (Makefile.am): Remove explicit dependency on
16833         $(STDINT_H), redundant through BUILT_SOURCES.
16834         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
16835         Remove explicit dependency on $(SYSEXITS_H).
16836         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
16837
16838 2005-07-18  Simon Josefsson  <jas@extundo.com>
16839
16840         * lib/check-version.c (check_version): Accept identical versions too.
16841
16842 2005-07-18  Bruno Haible  <bruno@clisp.org>
16843
16844         * modules/lock: New file.
16845         * MODULES.html.sh (Multithreading): New section.
16846
16847 2005-07-18  Bruno Haible  <bruno@clisp.org>
16848
16849         * m4/lock.m4: New file, from GNU gettext.
16850
16851 2005-07-18  Bruno Haible  <bruno@clisp.org>
16852
16853         * lib/lock.h: New file, from GNU gettext.
16854         * lib/lock.c: New file, from GNU gettext.
16855
16856 2005-07-18  Bruno Haible  <bruno@clisp.org>
16857
16858         * lib/lock.h (gl_once_t): New type.
16859         (gl_once_define, gl_once): New macros.
16860         * lib/lock.c (fresh_once): New variable.
16861         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
16862         functions.
16863
16864 2005-07-16  Simon Josefsson  <jas@extundo.com>
16865
16866         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
16867         workaround, suggested by Bruno.
16868
16869 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16870
16871         * modules/xalloc (Depends-on): Add xalloc-die.
16872         * modules/xvasprintf (Depends-on): Add xalloc-die.
16873
16874 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16875
16876         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
16877         with a minor change.
16878
16879 2005-07-15  Bruno Haible  <bruno@clisp.org>
16880
16881         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
16882         When using lib/poll.c, define poll as rpl_poll.
16883
16884 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
16885
16886         * modules/argp (Depends-on): Remove unlocked-io.
16887
16888 2005-07-14  Derek Price  <derek@ximbiot.com>
16889
16890         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
16891         for glob symlink bug.
16892
16893 2005-07-14  Bruno Haible  <bruno@clisp.org>
16894
16895         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
16896         Instead, test for *_unlocked function declarations directly.
16897
16898 2005-07-11  Simon Josefsson  <jas@extundo.com>
16899
16900         * modules/size_max: New file.
16901
16902         * modules/xsize: Depend on size_max module for size_max.m4.
16903
16904 2005-07-11  Simon Josefsson  <jas@extundo.com>
16905
16906         * lib/size_max.h: New file.
16907
16908 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
16909
16910         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
16911         copyright symbol and the year.
16912         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
16913         (version_etc_va): Use parameterized copyright notice.
16914         Reword to conform to the current GNU coding standards.
16915
16916 2005-07-11  Karl Berry  <karl@gnu.org>
16917
16918         * doc/gnulib.texi (Quoting): new node.
16919         (Initial import): more info, from Patrice.
16920
16921 2005-07-11  Bruno Haible  <bruno@clisp.org>
16922
16923         * gnulib-tool (func_usage): Document option --avoid.
16924         (Command line options): Handle --avoid.
16925         (func_acceptable): New function.
16926         (func_modules_transitive_closure): Use it.
16927
16928 2005-07-11  Bruno Haible  <bruno@clisp.org>
16929
16930         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
16931         Reported by Jim Meyering.
16932
16933 2005-07-10  Bruno Haible  <bruno@clisp.org>
16934
16935         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
16936         Needed when size_t is smaller than 'unsigned int'.
16937         Reported by Paul Eggert.
16938
16939 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16940
16941         * modules/argp (Depends-on): Add unlocked-io
16942
16943 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16944
16945         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
16946         block of defines.
16947
16948 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
16949
16950         * config/srclist.txt: Comment out regcomp.c, since we have a porting
16951         fix now.
16952
16953 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
16954         and Paul Eggert  <eggert@cs.ucla.edu>
16955
16956         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
16957         in wint_t, not wchar_t.  Remove now-unnecessary cast.
16958
16959 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16960
16961         * modules/regex (Files): Add lib/regex_internal.c,
16962         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
16963         (Depends-on): Add extensions.
16964         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
16965
16966 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16967
16968         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
16969         pathconf.
16970         * m4/same.m4 (gl_SAME): Likewise.
16971         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
16972
16973         * m4/regex.m4: Adjust to new libc regex implementation.
16974         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
16975         all the .c and .h parts of (the new) regex.
16976         Quote the m4 stuff better.
16977         Check for RE_ICASE bug of old gnulib.
16978         Check for REG_STARTEND of recent libc.
16979         Rename local variables from jm_* to gl_*.
16980         Quote operand of "test -f".
16981         Say "recent enough" version of libc, not "version 2".
16982         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
16983         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
16984         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
16985         Remove check for btowc, isascii.
16986         Require AM_LANGINFO_CODESET.
16987
16988 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16989
16990         * lib/regex.c, regex.h: Sync from libc.
16991         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
16992         * lib/regexec.c:
16993         New files, synced from libc, except that regex_internal.h
16994         currently has a small porting fix.
16995
16996 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16997
16998         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
16999         regex_internal.c, regexec.c.
17000         Add regex_internal.h too, but as a comment, since the libc version
17001         is currently broken in gnulib mode.
17002
17003 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
17004
17005         Support programs like Emacs that use gnulib but not gettext.
17006         * MODULES.html.sh (Internationalization functions): Add gettext-h.
17007         * modules/gettext-h: New file.
17008         * modules/gettext (Files): Remove lib/gettext.h.
17009         (Depends-on): Add gettext-h.
17010         (Makefile.am): Remove lib_SOURCES.
17011         * modules/argmatch, modules/c-stack, modules/closeout:
17012         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
17013         * modules/execute, modules/file-type, modules/getaddrinfo:
17014         * modules/getopt, modules/human, modules/javacomp:
17015         * modules/javaexec, modules/mkdir-p, modules/obstack:
17016         * modules/openat, modules/pagealign_alloc, modules/pipe:
17017         * modules/quotearg, modules/regex, modules/rpmatch:
17018         * modules/unicodeio, modules/userspec, modules/version-etc:
17019         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
17020         * modules/xsetenv:
17021         Depend on gettext-h, not gettext.
17022
17023 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
17024
17025         * gnulib-tool (func_import): Add support for 'public domain' license.
17026         * modules/alloca, modules/atexit, modules/memmove:
17027         Now public domain, not GPL.
17028         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
17029         * modules/realloc, modules/strerror, modules/strtod:
17030         Now LGPL, not GPL.
17031
17032 2005-07-05  Bruno Haible  <bruno@clisp.org>
17033
17034         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
17035         autoconf CVS. Needed for mingw.
17036
17037 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17038
17039         Remove the dependency of the strftime module on the tzset module.
17040         * modules/strftime (Depends-on): Remove dependency on tzset.
17041
17042 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17043
17044         Remove the dependency of the strftime module on the tzset module.
17045         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
17046         gl_FUNC_TZSET_CLOBBER.
17047
17048 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17049
17050         Remove the dependency of the strftime module on the tzset module.
17051         * lib/strftime.c (my_strftime)
17052         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
17053         Copy the input structure, to work around some of the bug with
17054         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
17055         Solaris releases, you should also use the tzset module, but we won't
17056         require it as a dependency any more since we don't want LGPLed code
17057         to depend on GPLed code.
17058
17059 2005-07-02  Jim Meyering  <jim@meyering.net>
17060
17061         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
17062         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
17063         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
17064         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
17065
17066 2005-07-02  Jim Meyering  <jim@meyering.net>
17067
17068         * lib/backupfile.c (backup_args): Change a `0' to NULL.
17069
17070 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
17071
17072         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
17073         declares only 'struct timespec;' (!).
17074
17075 2005-07-01  Jim Meyering  <jim@meyering.net>
17076
17077         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
17078         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
17079         * lib/save-cwd.c, tempname.c:
17080         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17081         and don't include <sys/file.h>).
17082
17083 2005-06-29  Jim Meyering  <jim@meyering.net>
17084
17085         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
17086         type name.  Use the variable name instead.
17087         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
17088         Likewise.
17089
17090 2005-06-28  Simon Josefsson  <jas@extundo.com>
17091
17092         * modules/check-version (Files): Add check-version.m4.
17093
17094 2005-06-28  Simon Josefsson  <jas@extundo.com>
17095
17096         * m4/check-version.m4: New file, suggested by Jim Meyering
17097         <jim@meyering.net>.
17098
17099 2005-06-28  Simon Josefsson  <jas@extundo.com>
17100
17101         * lib/check-version.h, lib/check-version.c: New files.
17102
17103 2005-06-28  Simon Josefsson  <jas@extundo.com>
17104
17105         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
17106         collision with global variable.  Better indentation.  Don't
17107         increment buffer pointer beyond buffer end.  Based on comments
17108         from Paul Eggert <eggert@cs.ucla.edu>.
17109
17110         * lib/base64.h: Indent.
17111
17112 2005-06-28  Simon Josefsson  <jas@extundo.com>
17113
17114         * doc/gnulib.texi (Library version handling): New section.
17115
17116 2005-06-28  Jim Meyering  <jim@meyering.net>
17117
17118         * check-module (find_included_lib_files): Hard-code another
17119         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
17120         but modules/fts-lgpl (correctly) does not list those files.
17121
17122         * modules/canonicalize (Files): Add lib/pathmax.h.
17123
17124 2005-06-25  Simon Josefsson  <jas@extundo.com>
17125
17126         * modules/check-version: New file.
17127
17128 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
17129
17130         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
17131         initializer of struct addrinfo, as an indication that we don't
17132         care how many members the structure has.
17133
17134 2005-06-24  Derek Price  <derek@ximbiot.com>
17135         and Bruno Haible  <bruno@clisp.org>
17136
17137         Remove stat module & update lstat.
17138         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
17139         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
17140         * m4/stat.m4: Remove this file.
17141
17142 2005-06-24  Derek Price  <derek@ximbiot.com>
17143         and Bruno Haible  <bruno@clisp.org>
17144
17145         Remove stat module & update lstat.
17146         * lib/stat.c: Remove this file...
17147         (slash_aware_lstat): ...moving this content and its support...
17148         * lib/lstat.c (rpl_lstat): ...into here.
17149         * lib/lstat.h: New file.
17150
17151 2005-06-24  Derek Price  <derek@ximbiot.com>
17152         and Bruno Haible  <bruno@clisp.org>
17153
17154         Remove stat module & update lstat.
17155         * config/srclist.txt (libc sources): Remove stat.
17156
17157 2005-06-24  Derek Price  <derek@ximbiot.com>
17158         and Bruno Haible  <bruno@clisp.org>
17159
17160         Remove stat module & update lstat.
17161         * MODULES.html.sh (stat): Remove.
17162         * MODULES.html: Regenerated.
17163         * modules/lstat (Description): Correct function name.
17164         (Files): Add "lstat.h".
17165         (Depends-on): Remove stat, add xalloc, stat-macros.
17166         * modules/stat: Remove this file.
17167         (Include): Add "lstat.h", remove <sys/stat.h>.
17168
17169 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
17170
17171         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
17172         (ranged_convert): Don't save conversion in a temporary struct.
17173         This causes a warning with GCC 4.0.0, and anyway in the typical
17174         case it's not worth the extra 100 bytes or so of code.
17175         (ranged_convert, __mktime_internal): When calling a function via a
17176         pointer P, use P () rather than (*P) (), as we now assume C89 or
17177         better.
17178
17179 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
17180
17181         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
17182         "who -r" failed to give output.  Problem reported by Tim Waugh.
17183
17184         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
17185         (xcalloc): Use it to avoid needless tests.
17186         Problem reported by Jim Meyering.
17187
17188 2005-06-20  Derek Price  <derek@ximbiot.com>
17189
17190         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
17191         unnecessary for Autoconfs > 2.59c.
17192
17193 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17194
17195         * lib/argp.h (__option_is_short): Check upper limit of
17196         __key. Isprint() requires its argument to have the value
17197         of an unsigned char or EOF.
17198
17199 2005-06-16  Jim Meyering  <jim@meyering.net>
17200
17201         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
17202         when either N or S is zero.
17203
17204 2005-06-16  Derek Price  <derek@ximbiot.com>
17205
17206         * m4/bison.m4: Declare YACC & YFLAGS precious.
17207
17208 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
17209
17210         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
17211         multibyte string or pattern, fall back on unibyte matching.
17212         Problem reported by James Youngman.
17213
17214 2005-06-08  Bruno Haible  <bruno@clisp.org>
17215
17216         * modules/csharpcomp: New file.
17217         * MODULES.html.sh (C#): Add csharpcomp.
17218
17219 2005-06-08  Bruno Haible  <bruno@clisp.org>
17220
17221         * m4/csharpcomp.m4: New file, from GNU gettext.
17222
17223 2005-06-08  Bruno Haible  <bruno@clisp.org>
17224
17225         * lib/csharpcomp.h: New file, from GNU gettext.
17226         * lib/csharpcomp.c: New file, from GNU gettext.
17227         * lib/csharpcomp.sh.in: New file, from GNU gettext.
17228
17229 2005-06-08  Bruno Haible  <bruno@clisp.org>
17230
17231         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
17232         warning on mingw.
17233
17234 2005-06-07  Derek Price  <derek@ximbiot.com>
17235
17236         Sync from CVS.
17237         * lib/glob_.h: Indent nested #ifdef.
17238
17239 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17240
17241         Sync from coreutils.
17242         Use "file name" when talking about file names, instead of "filename"
17243         or "path", as per the GNU coding standards.
17244         * lib/mkdir-p.c: Renamed from makepath.c.
17245         (make_dir_parents): Renamed from make_path.  All callers changed.
17246         * lib/mkdir-p.h: Likewise.  All includers changed.
17247         * lib/filenamecat.c: Renamed from path-concat.c.
17248         (file_name_concat): Renamed from path_concat.  All callers changed.
17249         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
17250         * lib/filenamecat.h: Likewise.  All includers changed.
17251         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
17252         in comments or local variable names.
17253         * lib/basename.c: Likewise.
17254         * lib/canonicalize.c, canonicalize.h: Likewise.
17255         * lib/dirname.c, dirname.h: Likewise.
17256         * lib/euidaccess.c: Likewise.
17257         * lib/exclude.c: Likewise
17258         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
17259         * lib/fsusage.c, fsuage.h: Likewise.
17260         * lib/fts.c, fts_.h: Likewise.
17261         * lib/getcwd.c: Likewise.
17262         * lib/getloadavg.c: Likewise.
17263         * lib/mkstemp.c: Likewise.
17264         * lib/mountlist.c, mountlist.h: Likewise.
17265         * lib/openat.c, openat.h: Likewise.
17266         * lib/readlink-stub.c: Likewise.
17267         * lib/readutmp.c, readutmp.h: Likewise.
17268         * lib/rename.c: Likewise.
17269         * lib/rmdir.c: Likewise.
17270         * lib/same.c: Likewise.
17271         * lib/savedir.c: Likewise.
17272         * lib/stripslash.c: Likewise.
17273         * lib/tempname.c: Likewise.
17274         * lib/xreadlink.c: Likewise.
17275         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
17276         All uses changed.
17277         * lib/exclude.h: Likewise.
17278
17279         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
17280         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17281         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
17282         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17283         * lib/pathmax.h: Include <limits.h> unconditionally, since other
17284         files have been getting away with it for years (MORE/BSD 4.3
17285         is extinct now).
17286         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
17287         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17288
17289         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
17290         Define to 256, not 255, as per modern POSIX.
17291
17292 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17293
17294         Sync from coreutils.
17295         Use "file name" when talking about file names, instead of "filename"
17296         or "path", as per the GNU coding standards.
17297         * MODULES.html.sh: mkdir-p renamed from makepath.
17298         filenamecat renamed from path-concat.
17299         * modules/filenamecat: Renamed from modules/path-concat.
17300         (Files): filenamecat.h and filenamecat.c renamed from
17301         path-concat.h and path-concat.c.
17302         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
17303         (Include): filenamecat.h, not path-concat.h.
17304         * modules/mkdir-p: Renamed from modules/makepath.
17305         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
17306         makepath.c.
17307         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
17308         (Include): mkdir-p.h, not makepath.h.
17309
17310 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17311
17312         Sync from coreutils.
17313         * m4/mkdir-p.m4: Renamed from makepath.m4.
17314         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
17315         Rename files from makepath.c to mkdir-p.c, and from
17316         makepath.h to mkdir-p.h.
17317         * m4/filenamecat.m4: Renamed from path-concat.m4.
17318         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
17319         Rename files from path-concat.c to filenamecat.c,
17320         and from path-concat.h to filenamecat.h.
17321         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
17322         "file name" in local variables or comments.
17323         * m4/rename.m4: Likewise.
17324
17325 2005-06-01  Bruno Haible  <bruno@clisp.org>
17326
17327         * modules/csharpexec: New file.
17328         * MODULES.html.sh (C#): New section.
17329
17330 2005-06-01  Bruno Haible  <bruno@clisp.org>
17331
17332         * m4/csharp.m4: New file, from GNU gettext.
17333         * m4/csharpexec.m4: New file, from GNU gettext.
17334
17335 2005-06-01  Bruno Haible  <bruno@clisp.org>
17336
17337         * lib/csharpexec.h: New file, from GNU gettext.
17338         * lib/csharpexec.c: New file, from GNU gettext.
17339         * lib/csharpexec.sh.in: New file, from GNU gettext.
17340
17341 2005-05-31  Derek Price  <derek@ximbiot.com>
17342             Paul Eggert  <eggert@cs.ucla.edu>
17343
17344         Sync from cvs.
17345         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
17346
17347 2005-05-31  Derek Price  <derek@ximbiot.com>
17348             Paul Eggert  <eggert@cs.ucla.edu>
17349
17350         Sync from cvs.
17351         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
17352
17353 2005-05-29  Derek Price  <derek@ximbiot.com>
17354
17355         * config/srclist.txt (glob_.h, glob.c): Add these files.
17356
17357 2005-05-29  Derek Price  <derek@ximbiot.com>
17358
17359         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
17360         * modules/glob: New file.
17361         * modules/getlogin_r: Add link to POSIX spec in description.
17362
17363 2005-05-29  Derek Price  <derek@ximbiot.com>
17364             Paul Eggert  <eggert@cs.ucla.edu>
17365
17366         * m4/glob.m4: New file.
17367
17368 2005-05-29  Derek Price  <derek@ximbiot.com>
17369             Paul Eggert  <eggert@cs.ucla.edu>
17370
17371         * lib/glob_.h, lib/glob.c: New files.
17372
17373 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17374
17375         * modules/fts (Files): Remove m4/inttypes-pri.m4.
17376         * modules/fts-lgpl (Depends-on): Remove gettext.
17377
17378 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17379
17380         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
17381         and don't require gt_INTTYPES_PRI.
17382
17383 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17384
17385         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
17386
17387         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
17388         the configuration hassle isn't worth it.
17389         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
17390         (LONGEST_MODIFIER, PRIuMAX): Remove.
17391
17392 2005-05-27  Bruno Haible  <bruno@clisp.org>
17393
17394         * lib/getlogin_r.h: Remove second include of <stddef.h>.
17395
17396 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
17397
17398         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
17399         _POSIX_PTHREAD_SEMANTICS for Solaris.
17400
17401 2005-05-25  Derek Price  <derek@ximbiot.com>
17402
17403         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
17404
17405 2005-05-25  Derek Price  <derek@ximbiot.com>
17406             Paul Eggert  <eggert@cs.ucla.edu>
17407
17408         * modules/getlogin_r, m4/getlogin_r.m4: New files.
17409         * lib/getlogin_r.c, getlogin_r.h: New files.
17410
17411 2005-05-25  Bruno Haible  <bruno@clisp.org>
17412             Derek Price  <derek@ximbiot.com>
17413
17414         * lib/getlogin_r.h: Simplify API documentation.
17415
17416 2005-05-23  Derek Price  <derek@ximbiot.com>
17417
17418         * modules/minmax (Files): Add m4/minmax.m4.
17419         (configure.ac): Add gl_MINMAX.
17420
17421 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
17422
17423         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
17424         so that unistd-safer.h (GPL'ed code) need not be included.
17425
17426 2005-05-22  Bruno Haible  <bruno@clisp.org>
17427
17428         * m4/minmax.m4: New file.
17429         Based on a patch by Derek Price <derek@ximbiot.com>.
17430
17431 2005-05-22  Bruno Haible  <bruno@clisp.org>
17432
17433         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
17434         (INT64_MIN): Fix definition.
17435         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
17436
17437         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
17438         NEED_SIGNED_INT_TYPES.
17439
17440         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
17441         HAVE_SYSTEM_INTTYPES.
17442
17443 2005-05-22  Bruno Haible  <bruno@clisp.org>
17444
17445         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
17446         Also include <sys/param.h> if it defines MIN, MAX.
17447         Based on a patch by Derek Price <derek@ximbiot.com>.
17448
17449 2005-05-21  Jim Meyering  <jim@meyering.net>
17450
17451         * modules/fts (Files): Add m4/inttypes-pri.m4.
17452         (Depends-on): Add lstat and remove gettext.  Alphabetize.
17453
17454 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17455
17456         New fts module.
17457         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
17458         (setup_dir, free_dir): New functions.
17459         (enter_dir, leave_dir): Define trivial
17460         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
17461         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
17462         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
17463         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
17464         Move to fts-cycle.c.
17465         (fts_open): Use setup_dir.
17466         (fts_close): Use free_dir.
17467         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
17468         This adds a label and some gotos, but the alternatives were messier.
17469         Check for memory allocation failure when entering a dir.
17470         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
17471         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
17472         (FTS): New member fts_cycle, that is a union that contains the
17473         old active_dir_ht and cycle_state.  All uses changed to mention
17474         fts_cycle.ht and fts_cycle.state.
17475         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
17476         fts.c, with the following changes:
17477         (setup_dir, free_dir): New functions.
17478         (enter_dir): Now returns bool.  Return true if successful, false
17479         if memory exhausted.  All callers changed.
17480         Do not bother partly cleaning up on
17481         memory allocation failure; that is free_dir's job.
17482         However, free ad if hash_insert fails, to avoid memory leak.
17483         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
17484         fts->fts_options to see which union member to use.
17485
17486 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17487
17488         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
17489         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
17490
17491 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17492
17493         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
17494
17495 2005-05-20  Jim Meyering  <jim@meyering.net>
17496
17497         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
17498         Now a macro, to pacify GCC.
17499
17500 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
17501
17502         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
17503         of -1.
17504
17505 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
17506
17507         * lib/chown.c (rpl_chown): Return -1 on failure.
17508
17509 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
17510
17511         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
17512         Don't check for stddef.h.
17513         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
17514         don't use its results.
17515         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
17516         since we include them unconditionally.  Don't require
17517         AM_STDBOOL_H, since stdbool is a prerequisite.
17518         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
17519         since we assume C89 or better.
17520         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
17521         as we don't use their results.
17522         Don't check for fchdir, memmove, memset, strrchr, as we use
17523         them unconditionally.
17524         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
17525         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
17526
17527 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
17528
17529         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
17530         Include <stddef.h> unconditionally, since we assume C89 now.
17531         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
17532         * lib/fts.c: Include fts_.h first, to check interface.
17533         Do not include intprops.h; no longer needed.
17534         Include cycle-check.h and hash.h, since fts_.h no longer does.
17535         Remove unnecessary casts of closedir to void.
17536         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
17537         decide whether to decrement nlinks.
17538         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
17539         (FTS): Use struct hash_table * instead of Hash_table, so that
17540         we no longer need to include hash.h here.
17541
17542 2005-05-18  Jim Meyering  <jim@meyering.net>
17543
17544         * modules/dirfd (License): Change to LGPL.  Most of the code
17545         is already in the public domain.
17546
17547 2005-05-18  Jim Meyering  <jim@meyering.net>
17548
17549         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
17550         Reported by Yoann Vandoorselaere.
17551
17552 2005-05-17  Jim Meyering  <jim@meyering.net>
17553
17554         * m4/fts.m4: New file, from coreutils.
17555
17556 2005-05-17  Jim Meyering  <jim@meyering.net>
17557
17558         * lib/fts.c, lib/fts_.h: New files, from coreutils.
17559
17560 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
17561
17562         Sync from coreutils.
17563         * m4/unlinkdir.m4: New file.
17564
17565 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
17566
17567         Sync from coreutils.
17568         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
17569         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
17570         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
17571         White space changes only.
17572         * lib/makepath.c (make_path): Port to hosts where leading "//" is
17573         special.
17574         * lib/yesno.c: Include getline.h, not ctype.h.
17575         (yesno): Don't remove leading white space; POSIX doesn't allow it.
17576         Use getline to remove arbitrary restriction on response length.
17577
17578 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
17579
17580         * config/srclist-update: Spell out "Street" in FSF postal
17581         mail address; this is the style the FSF seems to prefer.
17582
17583         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
17584         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
17585         this updates FSF postal mail address.
17586
17587         Sync from coreutils.
17588         * modules/unlinkdir: New file.
17589         * modules/yesno (Depends-on): Add getline.
17590         * MODULES.html.sh (File system functions): Add unlinkdir.
17591
17592 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
17593
17594         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
17595         lib/strsep.h:
17596         Change the initial comment to refer to GPL, not LGPL.
17597         gnulib-tool will change it to LGPL as needed.
17598
17599         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
17600         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
17601         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
17602         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
17603         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
17604         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
17605         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
17606         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
17607         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
17608         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
17609         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
17610         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
17611         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
17612         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
17613         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
17614         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
17615         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
17616         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
17617         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
17618         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
17619         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
17620         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
17621         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
17622         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
17623         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
17624         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
17625         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
17626         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
17627         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
17628         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
17629         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
17630         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
17631         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
17632         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
17633         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
17634         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
17635         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
17636         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
17637         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
17638         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
17639         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
17640         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
17641         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
17642         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
17643         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
17644         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
17645         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
17646         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
17647         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
17648         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
17649         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
17650         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
17651         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
17652         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
17653         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
17654         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
17655         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
17656         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
17657         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
17658         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
17659         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
17660         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
17661         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
17662         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
17663         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
17664         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
17665         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
17666         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
17667         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
17668         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
17669         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
17670         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
17671         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
17672         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
17673         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
17674         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
17675         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
17676         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
17677         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
17678         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
17679         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
17680         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
17681         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
17682         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
17683         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
17684         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
17685         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
17686         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
17687         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
17688         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
17689         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
17690         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
17691         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
17692         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
17693         lib/yesno.c, lib/yesno.h:
17694         Update FSF postal mail address.
17695
17696 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
17697
17698         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
17699         tests/test-memmem.c, tests/test-stpncpy.c:
17700         Update FSF postal mail address.
17701
17702 2005-05-13  Bruno Haible  <bruno@clisp.org>
17703
17704         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
17705         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
17706         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
17707         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
17708         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
17709         Add support for 64-bit integers in the MSVC compiler.
17710
17711 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17712
17713         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
17714
17715 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
17716
17717         * gnulib-tool (func_import): Sort and uniquify recommended includes.
17718
17719 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
17720
17721         * doc/getdate.texi (General date syntax): Don't say that date
17722         date --iso-8601=ns generates acceptable dates; it doesn't yet.
17723         Problem reported by Nic Ferrier.
17724
17725 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17726
17727         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
17728         specified in ai_socktype. Fix invalid ai_protocol
17729         check. ai_protocol is usually set to 0 or depending on
17730         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
17731         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
17732         ai_socktype / ai_protocol in the returned addrinfo structure.
17733
17734 2005-05-10  Simon Josefsson  <jas@extundo.com>
17735
17736         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
17737         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17738
17739 2005-05-10  Karl Berry  <karl@gnu.org>
17740
17741         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
17742         (from http://www.gnu.org/licenses).
17743         * doc/COPYING.LIB: also rename to COPYING.LESSER.
17744         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
17745         fdl.texi suffices.
17746
17747 2005-05-10  Karl Berry  <karl@gnu.org>
17748
17749         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
17750         (COPYING.DOC): remove.
17751
17752         * config/srclist-update: new FSF address.
17753
17754 2005-05-10  Derek Price  <derek@ximbiot.com>
17755
17756         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
17757         possible.
17758
17759 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17760             Bruno Haible  <bruno@clisp.org>
17761
17762         * modules/inet_ntop: New file.
17763         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17764         inet_ntop.
17765
17766 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17767             Bruno Haible  <bruno@clisp.org>
17768
17769         * m4/inet_ntop.m4: New file.
17770
17771 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17772             Bruno Haible  <bruno@clisp.org>
17773
17774         * lib/inet_ntop.h: New file.
17775         * lib/inet_ntop.c: New file, from glibc with modifications.
17776
17777 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
17778
17779         * modules/time_r (License): Change to LGPL.
17780         * modules/extensions (License): Change to LGPL.  Actually,
17781         the license is more permissive than that, but currently gnulib-tool
17782         doesn't know how to handle more-permissive licenses.
17783
17784         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
17785         Problem reported by Dave Love.
17786
17787 2005-05-08  Jim Meyering  <jim@meyering.net>
17788
17789         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
17790         blank.
17791
17792 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
17793
17794         * modules/argmatch (Depends-on): Add stdbool.
17795         * modules/backupfile (Depends-on): Likewise.
17796         * modules/chdir-long (Depends-on): Likewise.
17797         * modules/closeout (Depends-on): Likewise.
17798         * modules/cycle-check (Depends-on): Likewise.
17799         * modules/dirname (Depends-on): Likewise.
17800         * modules/fnmatch (Depends-on): Likewise.
17801         * modules/fsusage (Depends-on): Likewise.
17802         * modules/fwriteerror (Depends-on): Likewise.
17803         * modules/getcwd (Depends-on): Likewise.
17804         * modules/getloadavg (Depends-on): Likewise.
17805         * modules/hard-locale (Depends-on): Likewise.
17806         * modules/makepath (Depends-on): Likewise.
17807         * modules/mountlist (Depends-on): Likewise.
17808         * modules/nanosleep (Depends-on): Likewise.
17809         * modules/posixtm (Depends-on): Likewise.
17810         * modules/quotearg (Depends-on): Likewise.
17811         * modules/readtokens (Depends-on): Likewise.
17812         * modules/readtokens0 (Depends-on): Likewise.
17813         * modules/readutmp (Depends-on): Likewise.
17814         * modules/save-cwd (Depends-on): Likewise.
17815         * modules/strftime (Depends-on): Likewise.
17816         * modules/userspec (Depends-on): Likewise.
17817         * modules/utimecmp (Depends-on): Likewise.
17818         * modules/xgetcwd (Depends-on): Likewise.
17819         * modules/xnanosleep (Depends-on): Likewise.
17820         * modules/xstrtod (Depends-on): Likewise.
17821         * modules/yesno (Depends-on): Likewise.
17822
17823 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
17824
17825         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
17826         needless checks.
17827
17828 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17829
17830         Merge from coreutils.  Among other things,
17831         add bulletproofing for cases where stdin, stdout, or stderr are closed.
17832         * lib/fd-safer.c: New file.
17833         * lib/fcntl-safer.h, open-safer.c: Remove.
17834         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
17835         * lib/dup-safer.c: Include unistd-safer.h first.
17836         Don't include errno.h.
17837         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
17838         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
17839         * lib/file-type.c: Rely on file-type.h change.
17840         * lib/getloadavg.c: Include unistd-safer.h.
17841         (getloadavg): Use safer open.
17842         * lib/getusershell.c: Include "stdio-safer.h".
17843         (getusershell): Use safer fopen.
17844         * lib/long-options.c (long_options): Use NULL rather than 0.
17845         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
17846         'free'.
17847         * lib/modechange.c: Likewise.
17848         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
17849         (MODE_DONE): New constant.
17850         (struct mode_change): Remove 'next' member.
17851         (make_node_op_equals): New function; like the old one of the
17852         same name, except it allocates an array.
17853         (mode_compile, mode_create_from_ref): Use it.
17854         (mode_compile): Allocate result as an array, not a linked list.
17855         Parse octal string ourself, so that we catch mistakes like "+0".
17856         (mode_adjust): Arg is an array, not a linked list.
17857         * lib/modechange.c: Include stat-macros.h, xalloc.h.
17858         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
17859         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
17860         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
17861         Remove.  This is now stat-macros.h's job.
17862         (talloc): Remove.  All callers replaced by xalloc, so that
17863         our invokers don't have to worry about reporting memory failures.
17864         (make_node_op_equals): Remove.
17865         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17866         New constants.
17867         (struct mode_change): Moved here from modechange.h.
17868         (mode_append_entry): Remove.
17869         (mode_compile): Remove MASKED_OPS arg, since it encouraged
17870         apps to have incorrect behavior.  Use simpler algorithm for head
17871         and tail.  Don't futz with umask; that's now the job of mode_adjust.
17872         Detect more invalid usages rather than having somewhat-random behavior.
17873         Don't insert an "a=" action, as that leads to incorrect behavior.
17874         (mode_compile, mode_create_from_ref): Return NULL on error instead
17875         of an enum, since now there's only one way to have an error.  All
17876         callers changed.
17877         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
17878         at the correct time.  Simplify calculation of "+u" and its ilk.
17879         Don't mishandle "+X".
17880         (mode_free): Remove "register" and localize decls.
17881         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17882         (struct mode_change): Move to modechange.c; callers don't
17883         need to see this stuff.
17884         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
17885         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
17886         (mode_change, mode_adjust): Reflect the new signatures noted above.
17887         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
17888         that might redefine system include files.
17889         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
17890         (my_usleep): Use NULL rather than (void *) 0.
17891         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
17892         Use siginterrupt to specify that system calls should be interrupted.
17893         (rpl_nanosleep): Move initialization of suspended closer to call of
17894         my_usleep.
17895         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
17896         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
17897         (desirable_utmp_entry): New function.
17898         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
17899         using x2nrealloc, to simplify logic.
17900         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
17901         size calculation.  Do not assume utmp file is a regular file.
17902         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
17903         (READ_UTMP_CHECK_PIDS): New constant.
17904         * lib/save-cwd.c: Include unistd-safer.h.
17905         (save_cwd): Use fd_safer.
17906         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
17907         [!_LIBC] Include "stat-macros.h" instead.
17908         * lib/unistd-safer.h (fd_safer): New decl.
17909
17910 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17911
17912         * modules/getloadavg (Depends-on): Add unistd-safer.
17913         * modules/getusershell (Depends-on): Add stdio-safer.
17914         * modules/lstat (Depends-on): Remove xalloc.
17915         * modules/mkstemp (Depends-on): Add stat-macros.
17916         * modules/modechange (Depends-on): Remove xstrtol.
17917         Add stat-macros, xalloc.
17918         * modules/save-cwd (Depends-on): Add unistd-safer.
17919         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
17920         * modules/unistd-safer (Files): Add lib/fd-safer.c
17921         (Makefile.am): Remove lib_SOURCES.
17922
17923         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
17924         Remove fcntl-safer; unistd-safer supersedes it.
17925
17926 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17927
17928         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
17929         AC_HEADER_STAT.
17930         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
17931         (gl_PREREQ_CHOWN): Remove.
17932         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
17933         it.  Don't require AC_HEADER_STAT.
17934         (gl_PREREQ_LSTAT): Remove.
17935         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
17936         Don't require AC_HEADER_STAT.
17937         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
17938         (gl_PREREQ_RMDIR): Remove.
17939         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
17940         mention stat-macros.h or AC_HEADER_STAT, since we'll make
17941         the stat-macros module a prerequisite.
17942         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
17943         * m4/filemode.m4 (gl_FILEMODE): Likewise.
17944         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
17945         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
17946         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
17947         variable names.
17948         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
17949         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
17950         variable prefixes.
17951         * m4/fcntl-safer.m4: Remove.
17952         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
17953         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
17954         Invoke gl_PREREQ_FD_SAFER.
17955         (gl_PREREQ_FD_SAFER): New macro.
17956         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
17957         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
17958         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
17959         Remove duplicate call to AC_LIBOBJ(readutmp).
17960         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
17961
17962         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
17963         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
17964
17965 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17966
17967         * MODULES.html.sh (Misc): Add byteswap.
17968
17969 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17970
17971         * modules/getcwd (Depends-on): Add extensions.
17972         * modules/openat (Depends-on): Likewise.
17973
17974 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17975
17976         * modules/byteswap: New file.
17977
17978 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17979
17980         * m4/byteswap.m4: New file.
17981
17982 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17983
17984         * lib/byteswap_.h: New file.
17985
17986 2005-04-25  Karl Berry  <karl@gnu.org>
17987
17988         * m4/gettext.m4: Update from GNU gettext 0.14.4.
17989
17990 2005-04-25  Albert Chin  <china@thewrittenword.com>
17991
17992         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
17993         Toolkit C bug.
17994
17995 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
17996
17997         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
17998         (func_ln_if_changed) Remove forcibly for no error message
17999         in case file does not exist.
18000
18001 2005-04-19  Simon Josefsson  <jas@extundo.com>
18002
18003         * gnulib-tool (Options): Make --symlink mean --symbolic.
18004
18005 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
18006
18007         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
18008
18009 2005-04-16  Simon Josefsson  <jas@extundo.com>
18010
18011         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
18012
18013 2005-04-15  Simon Josefsson  <jas@extundo.com>
18014
18015         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
18016
18017 2005-04-15  Simon Josefsson  <jas@extundo.com>
18018
18019         * gnulib-tool: Rename --symlink to --symbolic.
18020
18021 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
18022
18023         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
18024         symbolic links to files instead of copying/moving.  Add --aux-dir,
18025         specifying directory relative --dir where auxiliary build tools
18026         are placed.
18027
18028 2005-04-14  Bruno Haible  <bruno@clisp.org>
18029
18030         * modules/allocsa (License): Change to LGPL.
18031         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
18032
18033 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
18034
18035         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
18036         that "UTC +1 second" continues to work.  Problem reported
18037         by Dmitry V. Levin.
18038         (relunit_snumber): New rule.
18039         (relunit): Use it.
18040
18041 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
18042
18043         * lib/getdate.y (universal_time_zone_table): New constant.
18044         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
18045         universal_time_zone_table.
18046         (lookup_zone): Prefer universal_time_zone_table to
18047         local_time_zone_table, so that "GMT" time stamps are allowed in
18048         London during the summer.  Problem reported by Ian Abbott.
18049
18050 2005-04-12  Jim Meyering  <jim@meyering.net>
18051
18052         * lib/human.c (humblock): Set *options even when returning due to
18053         xstrtoumax conversion failure.  Thanks to a used-uninitialized
18054         warning from gcc-4.
18055
18056 2005-04-09  Jim Meyering  <jim@meyering.net>
18057
18058         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
18059         -Wuninitialized: initialize tm0.tm_year.
18060
18061 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
18062
18063         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
18064         count, since there's no maximum.  All uses changed.
18065         Add member dsts_seen.
18066         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
18067         not being INT_MAX.
18068         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
18069         Use pc_rels_seen to decide whther a date is absolute.
18070
18071         * lib/getdate.y (number): Don't overwrite year.
18072         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
18073         check.
18074
18075 2005-04-02  Simon Josefsson  <jas@extundo.com>
18076
18077         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
18078         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
18079
18080 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
18081
18082         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
18083         where no absolute path name can be longer than PATH_MAX.
18084
18085 2005-03-27  Jim Meyering  <jim@meyering.net>
18086
18087         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
18088
18089 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
18090
18091         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
18092         "one's complement" -> "ones' complement" in comment, as per Knuth.
18093         "value of type" -> "type or expression" in comment.
18094         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
18095
18096 2005-03-26  Jim Meyering  <jim@meyering.net>
18097
18098         Comment nits.
18099         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
18100         Correct typos: s/or/of/.
18101
18102 2005-03-26  Jim Meyering  <jim@meyering.net>
18103
18104         * modules/check-include-files: Move to ../ and rename to...
18105         * check-module: ...this.
18106
18107 2005-03-25  Jim Meyering  <jim@meyering.net>
18108
18109         * modules/xvasprintf (Files): Add xalloc.h.
18110
18111 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
18112
18113         * modules/gettext (Files): config/config.rpath ->
18114         build-aux/config.rpath
18115         * modules/iconv (Files): Likewise.
18116         Problem reported by Oskar Liljeblad.
18117
18118 2005-03-23  Jim Meyering  <jim@meyering.net>
18119
18120         * modules/check-include-files: New script to check for
18121         missing dependencies, multiple includes, etc.
18122
18123         * modules/c-strtold (Depends-on): Add xalloc.
18124         * modules/c-strtod (Depends-on): Add xalloc.
18125         * modules/hash (Depends-on): Add xalloc.
18126         (Files): Remove lib/xalloc.h.
18127
18128         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
18129         * modules/userspec (Files): Add lib/inttostr.h.
18130
18131 2005-03-23  Jim Meyering  <jim@meyering.net>
18132
18133         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
18134
18135 2005-03-22  Jim Meyering  <jim@meyering.net>
18136
18137         * modules/stat-macros: New module.
18138         * modules/canonicalize, modules/euidaccess, modules/file-type,
18139         * modules/filemode, modules/lchown, modules/makepath,
18140         * modules/rmdir, modules/stat: Depend on new stat-macros module
18141         rather than listing lib/stat-macros.h manually.
18142         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
18143
18144 2005-03-22  Jim Meyering  <jim@meyering.net>
18145
18146         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
18147
18148 2005-03-22  Bruno Haible  <bruno@clisp.org>
18149
18150         * config/srclist.txt: Replace target directory 'config' with
18151         'build-aux'.
18152         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
18153         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
18154         ../build-aux/.
18155
18156 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
18157
18158         * modules/chdir-long (Depends-on): Add mempcpy.
18159
18160         * modules/acl, modules/backupfile, modules/c-strtod,
18161         modules/c-strtold, modules/canon-host, modules/canonicalize,
18162         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
18163         modules/exclude, modules/exitfail, modules/file-type,
18164         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
18165         modules/getdate, modules/getline, modules/getpagesize,
18166         modules/getpass, modules/getugroups, modules/group-member,
18167         modules/hard-locale, modules/hash, modules/human, modules/idcache,
18168         modules/inttostr, modules/long-options, modules/makepath,
18169         modules/md5, modules/memcasecmp, modules/memcoll,
18170         modules/modechange, modules/mountlist, modules/path-concat,
18171         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
18172         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
18173         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
18174         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
18175         modules/strftime, modules/strndup, modules/strverscmp,
18176         modules/timespec, modules/unlocked-io, modules/userspec,
18177         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
18178         modules/yesno:
18179         Remove lib_SOURCES line from Makefile.am section, as this is now
18180         done automatically by the corresponding Autoconf macro.
18181
18182 2005-03-21  Jim Meyering  <jim@meyering.net>
18183
18184         Changes imported from coreutils.
18185
18186         * lib/cycle-check.c: Don't include xalloc.h.
18187
18188         * lib/path-concat.c: Don't include assert.h.
18189         (path_concat): Remove assertion that would have triggered
18190         for ABASE starting with more than one slash.
18191         Reported by Andreas Schwab.
18192
18193         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
18194         properly when ABASE is an absolute file name.
18195         Correct the description of this function.
18196         Include <assert.h>.
18197         Add an assertion and a test driver.
18198         This fixes a bug introduced on 2004-07-02.
18199         Andreas Schwab reported the resulting failure of cp --parents:
18200         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
18201
18202 2005-03-21  Jim Meyering  <jim@meyering.net>
18203
18204         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
18205         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
18206
18207 2005-03-21  Jim Meyering  <jim@meyering.net>
18208         and  Paul Eggert  <eggert@cs.ucla.edu>
18209
18210         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
18211         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
18212         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
18213         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
18214         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
18215         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
18216         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
18217         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
18218         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
18219         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
18220         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
18221         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
18222         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
18223         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
18224         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
18225         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
18226         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
18227         for these modules.
18228
18229 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
18230
18231         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
18232         (which shouldn't happen), generate nothing instead of returning 0
18233         immediately, so that nstrftime (NULL, ...) doesn't return 0.
18234
18235 2005-03-16  Bruno Haible  <bruno@clisp.org>
18236
18237         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
18238         HAVE_LONGLONG_64BIT.
18239
18240 2005-03-16  Bruno Haible  <bruno@clisp.org>
18241
18242         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
18243         HAVE_LONGLONG_64BIT.
18244
18245 2005-03-16  Bruno Haible  <bruno@clisp.org>
18246
18247         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
18248         HAVE_LONGLONG_64BIT.
18249
18250 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
18251
18252         * lib/strftime.c (my_strftime): Prepend space to format so that we can
18253         reliably distinguish strftime failure from empty output on POSIX
18254         hosts.
18255
18256 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
18257
18258         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
18259         (iconv_string): Don't guess a size-zero buffer, as that might cause
18260         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
18261         result would be 'too large', where 'too large' is (heuristically)
18262         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
18263         overflow concerns.  This will prevent some unwanted malloc failures
18264         when the inputs are very large.
18265
18266 2005-03-15  Karl Berry  <karl@gnu.org>
18267
18268         * config/srclist.txt (config.rpath): from gettext.
18269         * config/config.rpath: update.
18270
18271 2005-03-15  Bruno Haible  <bruno@clisp.org>
18272
18273         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
18274         to 'negate'.
18275
18276         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
18277         variable.
18278
18279         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
18280         results.
18281
18282 2005-03-14  Simon Josefsson  <jas@extundo.com>
18283
18284         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
18285         <fx@gnu.org>.
18286
18287 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
18288
18289         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
18290         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
18291         intprops.h.
18292         * lib/strtol.c: Likewise.
18293
18294 2005-03-14  Jim Meyering  <jim@meyering.net>
18295
18296         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
18297         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
18298         to be nonzero so that we (and caller) can detect the difference
18299         between a valid zero-length expansion and an error return, even
18300         when the underlying strftime fails before writing anything into
18301         that location.
18302
18303 2005-03-14  Bruno Haible  <bruno@clisp.org>
18304
18305         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
18306         Update from GNU gettext 0.14.3.
18307
18308 2005-03-10  Jim Meyering  <jim@meyering.net>
18309
18310         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
18311
18312 2005-03-10  Jim Meyering  <jim@meyering.net>
18313
18314         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
18315         so that this module works on systems without fchdir.
18316
18317 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
18318
18319         Factor int-properties macros into a single file, except for
18320         glibc-related files.
18321         * lib/intprops.h: New file.
18322         * lib/getloadavg.c: Include it instead of limits.h.
18323         (INT_STRLEN_BOUND): Remove.
18324         * lib/human.c: Include intprops.h.
18325         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
18326         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
18327         302/1000.
18328         * lib/inttostr.h: Include intprops.h instead of limits.h.
18329         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
18330         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
18331         for consistency with intprops.h.
18332         (time_t_is_integer, twos_complement_arithmetic): Use them.
18333         * lib/sig2str.h: Include <signal.h>, intprops.h.
18334         (INT_STRLEN_BOUND): Remove.
18335         * lib/strftime.c (TYPE_SIGNED): Remove.
18336         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
18337         * lib/strtol.c: Adjust comments to match intprops.h.
18338         * lib/userspec.c: Include intprops.h.
18339         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
18340         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
18341         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
18342         instead of rolling our own expressions.
18343         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
18344
18345         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
18346         instead of int.
18347         (my_strftime): Do not mishandle years close to INT_MAX, by doing
18348         the right thing even if adding 1900 would overflow.  Similarly
18349         for tm_mon + 1 and tm_yday + 1.
18350         Make %Y always equivalent to %C%y, and similarly for %G and %g.
18351         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
18352         (DO_SIGNED_NUMBER): New macro.
18353         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
18354
18355 2005-03-07  Bruno Haible  <bruno@clisp.org>
18356
18357         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
18358
18359 2005-03-07  Bruno Haible  <bruno@clisp.org>
18360
18361         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
18362
18363 2005-03-04  Derek R. Price  <derek@ximbiot.com>
18364
18365         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
18366         (func_import): Only replace files via --import when they have actually
18367         changed.
18368
18369 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18370
18371         * m4/mmap-anon.m4: New file.
18372         * m4/pagealign_alloc.m4: New file.
18373
18374 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18375             Bruno Haible  <bruno@clisp.org>
18376
18377         * modules/pagealign_alloc: New file.
18378         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
18379
18380 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18381             Bruno Haible  <bruno@clisp.org>
18382
18383         * lib/pagealign_alloc.h: New file.
18384         * lib/pagealign_alloc.c: New file.
18385
18386 2005-03-03  Bruno Haible  <bruno@clisp.org>
18387
18388         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
18389         Use an all-permissive copyright notice, recommended by RMS.
18390
18391 2005-03-02  Bruno Haible  <bruno@clisp.org>
18392
18393         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
18394         of AIX, the replacement has to be done only after <string.h> is
18395         included, therefore not in config.h. stpncpy.h does the replacement,
18396         and stpncpy.c uses it.
18397
18398 2005-03-02  Bruno Haible  <bruno@clisp.org>
18399
18400         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
18401         stpncpy.c uses it.
18402
18403 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18404
18405         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
18406         The workaround isn't strictly needed for POSIX conformance, and
18407         it's too much of a pain to configure and maintain.  We'll ask
18408         people to fix their kernels instead.
18409         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
18410         (NANOSLEEP_BUG_WORKAROUND): Remove.
18411         (xnanosleep): Remove the workaround.
18412
18413 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18414
18415         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
18416         Reported by Derek Price.
18417         (Include): Add "timespec.h".
18418
18419         * modules/xnanosleep (Depends-on): Remove gethrxtime.
18420
18421 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18422
18423         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
18424         to detect nanosleep bug.
18425
18426 2005-03-01  Bruno Haible  <bruno@clisp.org>
18427
18428         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
18429
18430 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
18431
18432         * modules/gethrxtime: New file.
18433         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
18434         (Depends-on): Add gethrxtime.
18435         (configure.ac): Add gl_XNANOSLEEP.
18436         (Makefile.am): Remove lib_SOURCES line.
18437
18438 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
18439
18440         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
18441         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
18442
18443 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
18444
18445         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
18446         * lib/timespec.h (gettime): Return void, since it always
18447         succeeds now.  All uses changed.
18448         * lib/gettime.c (gettime) Likewise.
18449         [HAVE_NANOTIME]: Prefer nanotime.
18450         Assume gettimeofday succeeds, as POSIX requires.
18451         Assime time () succeeds, since other code already does.
18452         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
18453         (timespec_subtract): Remove.
18454         (NANOSLEEP_BUG_WORKAROUND): New constant.
18455         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
18456         things considerably.  Use it only on GNU/Linux hosts, since the
18457         workaround shouldn't be needed elsewhere.
18458
18459 2005-02-24  Bruno Haible  <bruno@clisp.org>
18460
18461         * modules/gettext (Files): Add m4/glibc2.m4.
18462
18463 2005-02-24  Bruno Haible  <bruno@clisp.org>
18464
18465         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
18466         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
18467         * m4/progtest.m4:
18468         Update from GNU gettext 0.14.2.
18469         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
18470
18471 2005-02-24  Bruno Haible  <bruno@clisp.org>
18472
18473         * lib/localcharset.c: Update from GNU gettext 0.14.2.
18474         * lib/config.charset: Update from GNU gettext 0.14.2.
18475
18476 2005-02-24  Bruno Haible  <bruno@clisp.org>
18477
18478         * lib/gettext.h: Update from GNU gettext 0.14.2.
18479
18480 2005-02-23  Simon Josefsson  <jas@extundo.com>
18481
18482         * m4/iconvme.m4: New file.
18483
18484 2005-02-23  Jim Meyering  <jim@meyering.net>
18485
18486         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
18487         change.
18488         Thanks to Bruno Haible for catching it.
18489
18490 2005-02-22  Simon Josefsson  <jas@extundo.com>
18491
18492         * modules/iconvme: New file.
18493
18494         * MODULES.html.sh: Add iconvme.
18495
18496 2005-02-22  Simon Josefsson  <jas@extundo.com>
18497
18498         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
18499
18500 2005-02-22  Simon Josefsson  <jas@extundo.com>
18501
18502         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
18503
18504 2005-02-22  Jim Meyering  <jim@meyering.net>
18505
18506         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
18507         s/ifndef/ifdef/.
18508
18509 2005-02-20  Neil Conway  <neilc@samurai.com>
18510
18511         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
18512         returned by OSX/Darwin if the specified buffer is not large
18513         enough for the hostname.
18514
18515 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18516
18517         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
18518         pass it to _help, otherwise the latter coredumps trying to
18519         dereference state.root_argp.
18520
18521 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
18522
18523         * modules/chdir-long (Depends-on): Add memrchr.
18524         * modules/memrchr (Files): Add lib/memrchr.h.
18525         (Include): "memrchr.h".
18526
18527 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
18528
18529         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
18530
18531 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
18532
18533         * lib/memrchr.h: New file.
18534         * lib/chdir-long.c: Include it.
18535         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
18536         Don't bother including stddef.h.
18537
18538 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
18539
18540         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
18541         inclusion.
18542         Include <sys/types.h>, for dev_t.
18543         (ME_DUMMY, ME_REMOTE): Move from here....
18544         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
18545         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
18546         Dmitry V. Levin.
18547         Include mountlist.h first, to test the interface.
18548
18549 2005-01-29  Bruno Haible  <bruno@clisp.org>
18550
18551         * lib/progname.c (program_name): Initialize.
18552         Needed when linking statically on MacOS X.
18553
18554 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
18555
18556         Sync from coreutils.
18557         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
18558         (Depends-on): Add c-strtod.
18559         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
18560
18561 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
18562
18563         Sync from coreutils.
18564         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
18565
18566         Remove files that are specific to coreutils.
18567         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
18568
18569 2005-01-28  Bruno Haible  <bruno@clisp.org>
18570
18571         * modules/javacomp: New file.
18572         * MODULES.html.sh (Java): Add javacomp.
18573
18574 2005-01-28  Bruno Haible  <bruno@clisp.org>
18575
18576         * m4/javacomp.m4: New file, from GNU gettext.
18577
18578 2005-01-28  Bruno Haible  <bruno@clisp.org>
18579
18580         * lib/javacomp.sh.in: New file, from GNU gettext.
18581         * lib/javacomp.h: New file, from GNU gettext.
18582         * lib/javacomp.c: New file, from GNU gettext.
18583
18584 2005-01-26  Simon Josefsson  <jas@extundo.com>
18585
18586         * lib/gai_strerror.c: Use GPL in header.
18587
18588 2005-01-26  Bruno Haible  <bruno@clisp.org>
18589
18590         * modules/javaexec: New file.
18591         * MODULES.html.sh (Java): Add javaexec.
18592
18593 2005-01-26  Bruno Haible  <bruno@clisp.org>
18594
18595         * m4/javaexec.m4: New file, from GNU gettext.
18596
18597 2005-01-26  Bruno Haible  <bruno@clisp.org>
18598
18599         * lib/javaexec.sh.in: New file, from GNU gettext.
18600         * lib/javaexec.h: New file, from GNU gettext.
18601         * lib/javaexec.c: New file, from GNU gettext.
18602
18603 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18604
18605         * modules/lchown (Depends-on): Remove lchown.h
18606
18607 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18608
18609         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
18610         must be defined if the header file was not found, in order
18611         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
18612
18613 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18614
18615         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
18616         initializers for struct pentry_state.
18617         (__argp_error): Check return value of __asprintf
18618         (__argp_failure): Translate error message
18619
18620         * lib/argp-parse.c: Removed braces around the expansion of N_()
18621
18622 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
18623
18624         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
18625         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
18626         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
18627         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
18628         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
18629         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
18630         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
18631         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
18632         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
18633         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
18634         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
18635         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
18636         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
18637         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
18638         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
18639         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
18640         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
18641         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
18642         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
18643         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
18644         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
18645         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
18646         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
18647         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
18648         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
18649         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
18650         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
18651         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
18652         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
18653         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
18654         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
18655         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
18656         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
18657         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
18658         xstrtol.m4, xstrtoumax.m4, yesno.m4:
18659         Use an all-permissive copyright notice, recommended by RMS.
18660
18661 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
18662
18663         * modules/chdir-long (Depends-on): Remove mempcpy.
18664
18665 2005-01-21  Jim Meyering  <jim@meyering.net>
18666
18667         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
18668         same value as for Solaris 9.
18669
18670         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
18671         component length.  This included changing the parameter to be
18672         of type `char *' rather than `char const *'.
18673         * lib/chdir-long.h (chdir_long): Update prototype.
18674
18675         * lib/openat.c (fdopendir, fstatat): New functions.
18676         * lib/openat.h: Include headers required for use of DIR and struct
18677         stat.
18678         [AT_SYMLINK_NOFOLLOW]: Define.
18679         (fdopendir, fstatat): Add prototypes.
18680
18681 2005-01-21  Bruno Haible  <bruno@clisp.org>
18682
18683         * modules/classpath: New file.
18684         * MODULES.html.sh (Java): Add classpath.
18685
18686 2005-01-21  Bruno Haible  <bruno@clisp.org>
18687
18688         * lib/classpath.h: New file, from GNU gettext.
18689         * lib/classpath.c: New file, from GNU gettext.
18690
18691 2005-01-20  Simon Josefsson  <jas@extundo.com>
18692
18693         * modules/version-etc-fsf: New file.
18694
18695 2005-01-20  Simon Josefsson  <jas@extundo.com>
18696
18697         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
18698         * lib/version-etc.c: Remove version_etc_copyright.
18699         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
18700         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
18701
18702 2005-01-20  Simon Josefsson  <jas@extundo.com>
18703
18704         * lib/base64.h (isbase64): Add.
18705
18706         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
18707         using a unsigned prototype, don't inline.
18708         (base64_decode): Use it.
18709
18710 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18711
18712         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
18713         it.
18714
18715 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18716
18717         * lib/save-cwd.c (save_cwd): Remove code to support the case
18718         where fchdir is missing or flaky.
18719
18720 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18721
18722         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
18723
18724 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
18725
18726         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
18727         AC_LIBSOURCES now does this.
18728         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
18729         with new ullong_max module.
18730
18731 2005-01-19  Bruno Haible  <bruno@clisp.org>
18732
18733         * modules/sh-quote: New file.
18734         * MODULES.html.sh (Executing programs): Add sh-quote.
18735
18736 2005-01-19  Bruno Haible  <bruno@clisp.org>
18737
18738         * lib/sh-quote.h: New file, from GNU gettext.
18739         * lib/sh-quote.c: New file, from GNU gettext.
18740
18741 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18742
18743         Merge from coreutils.
18744         * m4/ullong_max.m4: New file.
18745         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
18746         (gl_MACROS): Assume localeconv exists.
18747
18748 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18749
18750         Merge changes from coreutils, as described below in several
18751         changelogs dated today.
18752
18753         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
18754         (O_DIRECTORY): Remove; not needed here, since "." must be
18755         a directory.  All uses removed.
18756         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
18757         universal on Suns, and we also need to test for IRIX.
18758         Revamp code to use 'if' rather than '#if'.
18759         Avoid unnecessary comparison of cwd->desc to 0.
18760
18761         * lib/utimens.c (futimens): Robustify the previous patch, by checking
18762         for known valid error numbers rather than observed invalid ones.
18763
18764 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18765
18766         * modules/ullong_max: New file.
18767
18768         * modules/chdir-long, modules/openat: New files.
18769         * modules/save-cwd (Depends-on): Depend on chdir-long.
18770         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
18771
18772 2005-01-18  Jim Meyering  <jim@meyering.net>
18773
18774         Merge from coreutils.
18775         * m4/chdir-long.m4, m4/openat.m4: New files.
18776         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
18777         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
18778         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
18779         is sane and DOES follow symlinks.  Besides, testing 20 different
18780         systems found no broken chown implementations.
18781         Prompted by a change in rsync's copy of this macro.
18782         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
18783
18784         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
18785
18786         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
18787         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
18788         NULL-means-set-to-current-time semantics.
18789         Remove temporary file immediately, rather than waiting
18790         for configure's at-exit trap code to do it.
18791
18792 2005-01-18  Jim Meyering  <jim@meyering.net>
18793
18794         * lib/version-etc.c (version_etc_copyright): Update copyright date.
18795
18796         * lib/utimens.c (futimens): Account for the fact that futimes
18797         can also fail with errno == ENOSYS or errno == ENOENT.
18798         Patch from Dmitry V. Levin.
18799
18800         Change the name of the robust chdir function from chdir to chdir_long.
18801         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
18802         (restore_cwd): Use chdir_long, not chdir.
18803         * lib/chdir-long.c: Renamed from chdir.c.
18804         * lib/chdir-long.h: Renamed from chdir.h.
18805         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
18806         Hurd.
18807
18808 2005-01-18  Bruno Haible  <bruno@clisp.org>
18809
18810         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
18811         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
18812         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
18813         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
18814         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
18815         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
18816         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
18817         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
18818         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
18819         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
18820         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
18821         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
18822         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
18823         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
18824         Use an all-permissive copyright notice, recommended by RMS.
18825
18826 2005-01-18  Bob Proulx  <bob@proulx.com>
18827
18828         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
18829         simplify offsetof() macro construct to avoid compile failure with
18830         native HP-UX 11.0 ANSI C compiler.
18831
18832 2005-01-17  Bruno Haible  <bruno@clisp.org>
18833
18834         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
18835         redundant because stpncpy.m4 takes care of it.
18836
18837 2005-01-17  Bruno Haible  <bruno@clisp.org>
18838
18839         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
18840
18841 2005-01-17  Bruno Haible  <bruno@clisp.org>
18842
18843         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
18844         used.
18845
18846 2005-01-17  Bruno Haible  <bruno@clisp.org>
18847
18848         * lib/fwriteerror.h (fwriteerror): Change specification to include
18849         fclose.
18850         * lib/fwriteerror.c: Include <stdbool.h>.
18851         (fwriteerror): At the end, close the file stream. Record whether
18852         stdout was already closed.
18853
18854 2005-01-17  Bruno Haible  <bruno@clisp.org>
18855
18856         * lib/execute.c (environ): Declare if needed.
18857         * lib/pipe.c (environ): Likewise.
18858         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
18859
18860 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18861
18862         * modules/argp: Depend on vsnprintf
18863
18864 2005-01-10  Jim Meyering  <jim@meyering.net>
18865
18866         * modules/closeout (Depends-on): Add atexit.
18867
18868 2005-01-06  Bruno Haible  <bruno@clisp.org>
18869
18870         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
18871
18872 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
18873
18874         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
18875         definitions to be after all include files, to avoid collisions.
18876         Problem reported by Bob Proulx.
18877
18878 2005-01-04  Jim Meyering  <jim@meyering.net>
18879
18880         Changes imported from coreutils.
18881         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
18882         as the mkstemp template, use a temporary directory and an
18883         8.3-friendly template to avoid trouble on systems like DJGPP.
18884         Reported by Juan M. Guerrero via Stepan Kasal.
18885         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
18886         close. Remove the temporary directory right away, rather than waiting
18887         for configure's at-exit trap code to do it.
18888         Suggestion from Stepan Kasal.
18889
18890 2005-01-01  Simon Josefsson  <jas@extundo.com>
18891
18892         * gnulib-tool: Print #include directives when --import'ing.
18893
18894 2004-12-28  Simon Josefsson  <jas@extundo.com>
18895
18896         * tests/test-base64.c: Include required header files.  Remove
18897         unused variables.
18898
18899 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18900
18901         * modules/error (Depends-on): Remove gettext.
18902
18903 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18904
18905         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
18906         not needed.  This removes a dependency on the gettext module.
18907         [defined _LIBC]: Do not include <libintl.h>; not needed.
18908
18909 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18910
18911         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
18912         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
18913
18914 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18915
18916         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
18917         HAVE_DECL_STRTOLD.
18918
18919 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18920
18921         * modules/getdate (Depends-on): Remove alloca-opt.
18922
18923 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18924
18925         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
18926
18927 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18928
18929         * lib/argp-parse.c: Include <stddef.h>.
18930         (alignof, alignto): New macros.
18931         (parser_init): Don't assume that void * is aligned sufficiently
18932         for struct option.
18933
18934         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
18935         need to extend the stack.
18936         (YYINITDEPTH): New macro, so that the initial stack isn't overly
18937         large.
18938
18939 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18940
18941         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
18942
18943 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18944
18945         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
18946         (2004-10-24) change.  Apparently this was a false alarm.
18947
18948         * modules/getdate: Depend on alloca-opt, not alloca.
18949
18950 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18951
18952         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
18953         Remove now-obsolete comment about AIX.
18954         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
18955         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
18956         (YYMAXDEPTH): New macro.
18957
18958 2004-12-18  Simon Josefsson  <jas@extundo.com>
18959
18960         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
18961
18962 2004-12-18  Bruno Haible  <bruno@clisp.org>
18963
18964         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
18965
18966 2004-12-18  Bruno Haible  <bruno@clisp.org>
18967
18968         * lib/fatal-signal.c (fatal_signals): Make non-const.
18969         (init_fatal_signals): New function.
18970         (uninstall_handlers, install_handlers): Ignore signals that were set to
18971         SIG_IGN.
18972         (at_fatal_signal): Call init_fatal_signals.
18973         (init_fatal_signal_set): Likewise. Ignore signals that were set to
18974         SIG_IGN.
18975         Reported by Paul Eggert.
18976
18977 2004-12-18  Bruno Haible  <bruno@clisp.org>
18978
18979         * doc/alloca.texi: New file.
18980         * doc/alloca-opt.texi: New file.
18981
18982 2004-12-17  Jim Meyering  <jim@meyering.net>
18983
18984         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
18985         Otherwise, install-sh could exit with improper exit status when
18986         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
18987
18988 2004-12-16  Simon Josefsson  <jas@extundo.com>
18989
18990         * tests/test-base64.c: Add license.
18991
18992 2004-12-15  Stepan Kasal  <address@hidden>
18993
18994         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
18995
18996 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
18997
18998         * modules/getcwd (Files): Add m4/d-ino.m4.
18999         Suggested by Mark D. Baushke.
19000
19001 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
19002
19003         * lib/getdate.y (textint): New member "negative".
19004         (time_zone_hhmm): New function.
19005         Expect 14 shift-reduce conflicts, not 13.
19006         (o_colon_minutes): New rule.
19007         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
19008         (yylex): Set the "negative" member of signed numbers.
19009
19010 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
19011
19012         * doc/getdate.texi (Time of day items, Time zone items):
19013         Describe new formats +00:00, UTC+00:00.
19014
19015 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
19016
19017         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
19018         spurious "-l"s.  Problem reported by Stepan Kasal.
19019
19020 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
19021
19022         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
19023         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
19024
19025 2004-12-04  Simon Josefsson  <jas@extundo.com>
19026
19027         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
19028         Vandoorselaere <yoann@prelude-ids.org>.
19029
19030 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19031
19032         Changes imported from coreutils.
19033         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
19034         exist.
19035         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
19036
19037 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19038
19039         Changes imported from coreutils.
19040         * lib/hard-locale.c: Assume <locale.h> exists.
19041         Include "strdup.h".
19042         (GLIBC_VERSION): New macro.
19043         (hard_locale): Assume setlocale exists.
19044         Rewrite to avoid #ifdef.
19045         Use strdup rather than malloc + strcpy.
19046         * lib/human.c: Assume <locale.h> exists.
19047         (human_readable): Assume localeconv exists.
19048
19049 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19050
19051         * modules/hard-locale (Depends-on): Add strdup.
19052
19053 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
19054
19055         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
19056         convert T2, not T.  (Imported from libc.)
19057
19058 2004-11-30  Simon Josefsson  <jas@extundo.com>
19059
19060         * modules/restrict (License): Change to LGPL.
19061
19062 2004-11-30  Simon Josefsson  <jas@extundo.com>
19063
19064         * m4/restrict.m4: Add copyright and copying conditions.
19065
19066 2004-11-30  Simon Josefsson  <jas@extundo.com>
19067
19068         * m4/base64.m4: New file.
19069
19070 2004-11-30  Simon Josefsson  <jas@extundo.com>
19071
19072         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
19073         base64.
19074
19075         * tests/test-base64.c: New file.
19076
19077         * modules/base64: New file.
19078
19079 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
19080
19081         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
19082         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
19083
19084         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
19085
19086 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
19087
19088         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
19089         (__getcwd.c): Don't restore errno; glibc doesn't.
19090         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
19091         first, falling back to our code only if its results look suspicious.
19092         Ensure that the resulting buffer is only as large as necessary.
19093
19094         * lib/readutmp.c: Include readutmp.h first.
19095         Include <errno.h>, since readutmp.h no longer does that.
19096         * lib/readutmp.h: Don't include <errno.h>,
19097         <sys/param.h>, <time.h>; not needed to establish interface.
19098         (errno): Remove decl.
19099         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
19100         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
19101         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
19102
19103 2004-11-28  Simon Josefsson  <jas@extundo.com>
19104
19105         * lib/base64.h, base64.c: New file.
19106
19107 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
19108
19109         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
19110
19111 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
19112
19113         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
19114         (Depends-on): Remove pathmax, same.  Add mempcpy.
19115         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
19116         (Makefile.am): Append getcwd.h to lib_SOURCES.
19117         (Include): Add getcwd.h.
19118         (Maintainer): Change from Jim Meyering to "all, glibc",
19119         since getdate now uses intended-for-glibc code.
19120         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
19121         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
19122
19123 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
19124
19125         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
19126         HP's ANSI C compiler.
19127         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
19128         Declaring int functions causes warnings on some modern systems and
19129         shouldn't be needed to compile on ancient ones.
19130         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
19131         defined.
19132
19133         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
19134         with the following changes.
19135         (__set_errno): Parenthesize properly.
19136         Include <stdbool.h>.
19137         (MIN, MAX, MATCHING_INO): New macros.
19138         (__getcwd): Define with prototype, not K&R form.
19139         Use heuristics to allocate default buffer on stack if possible.
19140         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
19141         behavior, and to avoid the PATH_MAX limit when computing
19142         ../../../../...
19143         Use MATCHING_INO to compare inode number to file.
19144         Check for arithmetic overflow in size calculations.
19145         Fix bug in reallocation of dot array that caused getcwd to fail
19146         on directories nested deeper than 75.
19147         Be more careful about saving errno on error.
19148         Do not use realloc; use only free+malloc, as this is a bit
19149         more flexible and avoids a needless copy operation.
19150         Do not inspect st_dev and st_ino for symbolic links; POSIX
19151         doesn't specify the latter.
19152         Check for closedir errors.
19153         Avoid needless casts.
19154         Use "#ifdef weak_alias" around weak_alias, to be like other
19155         glibc code.
19156         The following changes to getcwd.c have effect only when used in
19157         gnulib; they have no effect inside glibc proper.
19158         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
19159         as alloca isn't used.
19160         (alloca, __alloca): Likewise.
19161         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
19162         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
19163         unconditionally, as gnulib assumes C89 or better.
19164         Do not include <sys/param.h>.
19165         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
19166         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
19167         better.
19168         (NULL) [!defined NULL]: Remove; we assume C89 or better.
19169         Include <dirent.h> in a way that is compatible with modern Autoconf.
19170         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
19171         New macros, if not already defined.
19172         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
19173         Use "_LIBC", not "defined _LIBC", for consistency.
19174         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
19175         a mempcpy module.
19176         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
19177         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
19178         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
19179         credit only to Jim Meyering and adjust the copyright dates.
19180         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
19181         <stdlib.h>, <unistd.h>, "pathmax.h".
19182         Instead, include "xgetcwd.h" (first) and "getcwd.h".
19183         (INITIAL_BUFFER_SIZE): Remove.
19184         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
19185
19186 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
19187
19188         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
19189         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
19190         Use the _ONCE methods, for efficiency.
19191         Check for fcntl.h.  In test program, include <errno.h>
19192         and <fcntl.h> if available.  Remove old K&R cruft from
19193         test program.  Check for common errors in GNU/Linux,
19194         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
19195         don't do AC_LIBOBJ, as that's getcwd.m4's job.
19196         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
19197         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
19198         name accordingly.
19199         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
19200         accommodate new getcwd.c.
19201         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
19202         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
19203         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
19204         that's all we need now.
19205
19206 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19207
19208         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
19209         argp-parse.c depends on getopt internals, that means we should
19210         always use our getopt, to be on the safe side.
19211         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
19212         order not to spoil the result of an eventual previous invocation
19213         of gl_GETOPT_SUBSTITUTE.
19214
19215 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19216
19217         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
19218         redefinition warnings. To avoid them, include the defines
19219         in `#if !defined __need_getopt ... #endif'. The only place
19220         where __getopt_argv_const is used is in definitions
19221         of getopt_long and getopt_long_only below, which are as well
19222         protected by `#ifndef __need_getopt'.
19223         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
19224         __need_getopt after including <stdio.h> and <unistd.h> These
19225         headers might have defined it.
19226
19227 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
19228
19229         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
19230
19231 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
19232
19233         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
19234         (futimens): New function, which uses futimes if available.
19235         (futimens, utimens): Support timespec==NULL, with same semantics
19236         as utime and utimens.
19237         * lib/utimens.h (futimens): New decl.
19238
19239 2004-11-23  Jim Meyering  <jim@meyering.net>
19240
19241         * lib/getopt_.h: Remove trailing blanks.
19242
19243 2004-11-23  Jim Meyering  <jim@meyering.net>
19244
19245         * lib/__fpending.c: Add comment.
19246
19247 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
19248
19249         * modules/canonicalize (Depends-on): Add xreadlink.
19250         Problem reported by James Youngman.
19251
19252 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
19253
19254         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
19255         New macros.
19256         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
19257         optopt): Use them instead of invoking ## directly; otherwise, the
19258         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
19259
19260 2004-11-19  Bruno Haible  <bruno@clisp.org>
19261
19262         * lib/strtok_r.c: Move comments from here...
19263         * lib/strtok_r.h: ... to here.
19264
19265 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
19266
19267         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
19268         implementations that mishandle size_t overflow.
19269
19270 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
19271
19272         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
19273         might fail.  Problem reported by Yoann Vandoorselaere.
19274         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
19275         implementations that mishandle size_t overflow.
19276
19277 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19278
19279         * modules/canon-host (Depends-on): Add strdup.
19280
19281 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19282
19283         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
19284
19285 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19286
19287         * lib/canon-host.c: Include "strdup.h".
19288         (canon_host): Use getaddrinfo if available, so that IPv6 works.
19289         Use strdup instead of malloc/strcpy to duplicate strings.
19290
19291         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
19292         (human_space_before_unit): New constant.
19293         * lib/human.c (human_readable): Support it.
19294
19295         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
19296         (xgetcwd): Set errno correctly when failing.
19297         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
19298         the failure is actually due to a PATH_MAX problem.
19299
19300         Further getopt changes to make it more likely that glibc will
19301         buy the changes back.
19302         * lib/getopt.c (POSIXLY_CORRECT): New constant.
19303         (getopt): Use it, so to preserve glibc semantic
19304         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
19305         when compiling for libc.
19306         * lib/getopt_.h (__getopt_argv_const): Bring it back.
19307         (getopt_long, getopt_long_only): Use it.
19308
19309         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
19310         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
19311         (getopt): Argv is now char * const *, as per standard.
19312         (_getopt_internal_r, _getopt_internal): Argv is now char **,
19313         not char *__getopt_argv_const *.
19314         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
19315         _getopt_long_only_r): Likewise.
19316         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
19317         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
19318         _getopt_long_r, _getopt_long_only_r): Likewise.
19319         * lib/getopt_.h (__getopt_argv_const): Remove.
19320         (getopt): Argv is now char * const *, as per standard.
19321
19322         * lib/getdate.y (tORDINAL): New token.
19323         (day, relunit): Allow it for relative times.
19324         (relative_time_table): Use tORDINAL for ordinals.
19325
19326 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19327
19328         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
19329         Document that "second" isn't allowed as an ordinal number.
19330
19331 2004-11-16  Jim Meyering  <jim@meyering.net>
19332
19333         * modules/closeout (Depends-on): Add fpending.
19334
19335 2004-11-15  Jim Meyering  <jim@meyering.net>
19336
19337         * lib/closeout.c: Include "__fpending.h" once again.
19338         Include <stdbool.h>.
19339         (close_stdout): Don't fail just because stdout was closed initially,
19340         since some programs don't write to stdout in the normal course of
19341         operation (other than --version and --help), and we don't want this
19342         function to make e.g. `touch file >&-' fail.
19343         But do fail if it was closed and someone has tried to write to it.
19344         E.g., `printf foo >&-' must fail.
19345
19346 2004-11-13  Jim Meyering  <jim@meyering.net>
19347
19348         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
19349
19350 2004-11-12  Simon Josefsson  <jas@extundo.com>
19351
19352         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
19353         small doc fix is still pending.
19354
19355 2004-11-11  Simon Josefsson  <jas@extundo.com>
19356
19357         * modules/strtok_r: New file.
19358
19359         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19360         strtok_r.
19361
19362 2004-11-11  Simon Josefsson  <jas@extundo.com>
19363
19364         * m4/strtok_r.m4: New file.
19365
19366         * m4/getopt.m4: Replace opterr.
19367
19368 2004-11-11  Simon Josefsson  <jas@extundo.com>
19369
19370         * lib/strtok_r.h, strtok_r.c: New file.
19371
19372 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
19373
19374         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
19375         of replacing opterr, getopt, etc.  This should handle the
19376         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
19377
19378 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
19379
19380         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
19381         we can stop lying to compilers about the constness of argv when we
19382         are compiled outside glibc.
19383         (getopt, getopt_long, getopt_long_only): Use it.
19384         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
19385         _getopt_internal, getopt): Likewise.
19386         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
19387         _getopt_long_only_r): Likewise.
19388         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
19389         _getopt_long_r, _getopt_long_only_r): Likewise.
19390
19391         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
19392         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
19393         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
19394         the other external symbols.
19395         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
19396         declaration, since the above renaming now works around collisions.
19397
19398 2004-11-11  Jim Meyering  <jim@meyering.net>
19399
19400         * lib/linebreak.c: Remove trailing blanks.
19401         * lib/alloca_.h: Likewise.
19402         * lib/acosl.c: Likewise.
19403         * lib/euidaccess.c: Likewise.
19404         * lib/allocsa.h: Likewise.
19405
19406 2004-11-10  Simon Josefsson  <jas@extundo.com>
19407
19408         * m4/getaddrinfo.m4: New file.
19409
19410 2004-11-10  Simon Josefsson  <jas@extundo.com>
19411
19412         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
19413
19414 2004-11-10  Simon Josefsson  <jas@extundo.com>
19415
19416         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19417         getaddrinfo.
19418
19419         * modules/getaddrinfo: New file.
19420
19421 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
19422
19423         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
19424
19425 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
19426
19427         * lib/mktime.c (SHR): New macro, which is a portable
19428         substitute for >> that should work even on Crays.
19429         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
19430         Problem reported by Mark D. Baushke in
19431         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
19432         * lib/getdate.y (SHR): Likewise.
19433         (tm_diff): Use it.
19434         * lib/strftime.c (SHR): Likewise.
19435         (tm_diff): Use it.
19436         * lib/quotearg.c (struct quoting_options): Use unsigned int for
19437         quote_these_too, so that right shifts are well defined.  All uses
19438         changed.
19439
19440 2004-11-10  Jim Meyering  <jim@meyering.net>
19441
19442         Ensure that no close failure goes unreported.
19443         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
19444         return early when it seems there's nothing to flush.
19445         Don't include __fpending.h.
19446
19447 2004-11-10  Jim Meyering  <jim@meyering.net>
19448
19449         * modules/closeout (Depends-on): Remove fpending.
19450
19451 2004-11-10  Jim Meyering  <jim@meyering.net>
19452
19453         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
19454
19455 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
19456
19457         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
19458         gl_FUNC_STRFTIME.
19459         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
19460         and AC_REQUIRE when possible, to avoid duplicate checks.
19461         Check for <wchar.h>.
19462
19463 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
19464
19465         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
19466
19467 2004-11-09  Bruno Haible  <bruno@clisp.org>
19468
19469         * m4/sockpfaf.m4: New file.
19470
19471 2004-11-05  Bruno Haible  <bruno@clisp.org>
19472
19473         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
19474         Reported by Mark D. Baushke <mdb@cvshome.org>.
19475
19476 2004-11-04  Bruno Haible  <bruno@clisp.org>
19477
19478         2004-09-11  Bruno Haible  <bruno@clisp.org>
19479                 * allocsa.valgrind: New file.
19480         2004-02-06  Bruno Haible  <bruno@clisp.org>
19481                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
19482                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
19483                 Reported by Christopher Seip <chris.seip@hp.com>.
19484
19485 2004-11-04  Bruno Haible  <bruno@clisp.org>
19486
19487         * modules/allocsa (Files): Add lib/allocsa.valgrind.
19488         (Makefile.am): Distribute it.
19489
19490 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
19491
19492         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
19493         with errno == ERANGE if the buffer is too small.
19494         Problem reported by Mark D. Baushke.
19495
19496 2004-11-03  Albert Chin  <china@thewrittenword.com>
19497             Paul Eggert  <eggert@cs.ucla.edu>
19498
19499         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
19500         equivalent, substitute $ac_type for equivalent type rather than
19501         blindly using uint32_t *always* which won't work if uint32_t is not
19502         available.  Define _UINT32_T to work around typedef of uint32_t if
19503         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
19504         2.5.1.
19505
19506 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
19507
19508         * m4/jm-macros.m4: Sync from coreutils.
19509         (gl_MACROS): Check for mbrlen, for pathchk.
19510         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
19511
19512 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
19513
19514         * lib/xreadlink.c (MAXSIZE): New macro.
19515         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
19516         size does not exceed MAXSIZE.  Avoid cast.
19517         As suggested by Mark D. Baushke in
19518         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
19519         if readlink fails with buffer size just under MAXSIZE, try again
19520         with MAXSIZE.
19521
19522 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
19523
19524         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
19525
19526 2004-11-02  Derek R. Price  <derek@ximbiot.com>
19527         and  Paul Eggert  <eggert@cs.ucla.edu>
19528
19529         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
19530         (get_date): Overparenthesize to avoid GCC warning.
19531
19532 2004-11-02  Bruno Haible  <bruno@clisp.org>
19533
19534         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
19535         returns void.
19536
19537 2004-11-02  Bruno Haible  <bruno@clisp.org>
19538
19539         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
19540         function returns void.
19541
19542 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
19543
19544         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
19545         fflush_unlocked, flockfile, funlockfile, funlockfile,
19546         fputs_unlocked, putc_unlocked.
19547
19548 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
19549
19550         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
19551         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
19552         already declared.
19553
19554 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
19555
19556         * modules/getdate (Files): Add doc/getdate.texi.
19557         (Depends-on): Add setenv, xalloc.
19558
19559 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
19560
19561         * lib/getdate.y: Add support for TZ="foo" within a date string.
19562         Fix some bugs near time_t boundaries.  Reject dates with
19563         out-of-range components, e.g., "Sept 31".
19564         Include <stdlib.h>, "setenv.h", "xalloc.h".
19565         (ISDIGIT_LOCALE): Remove; unused.
19566         Note that the TZ and time functions used here are not reentrant.
19567         (mktime_ok, get_tz): New functions.
19568         (TZBUFSIZE): New constant.
19569         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
19570         This requires that we sometimes generate our own TZ="XXX..." setting.
19571
19572 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
19573
19574         * doc/getdate.texi: New file, from coreutils with modifications for
19575         the new TZ parsing.
19576
19577 2004-10-27  Derek R. Price  <derek@ximbiot.com>
19578
19579         * lib/mktime.c (not_equal_tm): Remove redundant check.
19580
19581 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
19582
19583         * modules/regex (lib_SOURCES): Add regex.c.
19584         Reported by James Youngman in
19585         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
19586
19587 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
19588
19589         * lib/getdate.y: Use Bison 1.875 features, and some minor
19590         code cleanups.  This change does not affect semantics.
19591         Don't include <stdlib.h>; no longer needed.
19592         Don't include unlocked-io.h; only the "#if TEST" code uses
19593         stdio, and performance isn't crucial there.
19594         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
19595         Bison 1.875 features as described below.
19596         All uses of "PC." replaced by "pc->".
19597         (YYSTYPE): Add a forward declaration.
19598         (yylex, yyerror): Use full prototypes in forward decls.
19599         Use "%pure-parser" rather than obsolescent "%pure_parser".
19600         Use %parse-param and %lex-param instead of obsolescent
19601         YYPARSE_PARAM and YYLEX_PARAM.
19602         (meridian_table, month_and_day_table, time_units_table,
19603         relative_time_table, time_zone_table, military_table,
19604         lookup_zone, lookup_word, get_date):
19605         Use NULL instead of 0 where appropriate.
19606         (to_hour): Avoid abort (), to avoid a dependency on
19607         stdlib.h.
19608         (yyerror, yylex): Now accepts parser_control * arg.
19609         (main) [TEST]: Use '\0' rather than 0 for char.
19610
19611 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
19612
19613         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
19614
19615 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
19616
19617         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
19618         It's now the caller's responsibility to handle the case where
19619         !HAVE_GETPAGESIZE && !defined getpagesize.
19620
19621         * lib/mktime.c (leapyear): Arg is long int, not int.
19622
19623 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
19624
19625         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
19626
19627 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
19628
19629         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
19630         missing.  Problem reported by James Youngman.
19631
19632 2004-10-16  Simon Josefsson  <jas@extundo.com>
19633
19634         * gnulib-tool: Fix comments.  Fix parse problem.
19635         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
19636
19637 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
19638
19639         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
19640         implementation of getopt_long.  Problem reported by Alexander Taler in:
19641         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
19642
19643 2004-10-15  Bruno Haible  <bruno@clisp.org>
19644
19645         * gnulib-tool: Untabify. Initialize supplied_libname.
19646         (func_usage): More homogenous output.
19647         (func_modules_transitive_closure, func_modules_to_filelist,
19648         func_emit_lib_Makefile_am): New functions.
19649         (func_import): New function, extracted from big case statement. Use
19650         func_get_license, func_modules_transitive_closure,
19651         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
19652         opt_lgpl. Don't use test -a, as it's not portable.
19653         (func_create_testdir): Use func_modules_transitive_closure,
19654         func_modules_to_filelist, func_emit_lib_Makefile_am.
19655
19656 2004-10-15  Bruno Haible  <bruno@clisp.org>
19657
19658         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
19659
19660 2004-10-15  Bruno Haible  <bruno@clisp.org>
19661
19662         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
19663         the portions belonging to each module.
19664         Suggested by Derek Robert Price <derek@ximbiot.com>.
19665
19666 2004-10-12  Simon Josefsson  <jas@extundo.com>
19667
19668         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
19669         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
19670         to real functions.
19671
19672 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19673
19674         * modules/vsnprintf: New file.
19675
19676 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19677
19678         * m4/vsnprintf.m4: New file.
19679
19680 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19681
19682         * lib/vsnprintf.h: New file.
19683         * lib/vsnprintf.c: New file.
19684
19685 2004-10-11  Bruno Haible  <bruno@clisp.org>
19686
19687         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
19688         vsnprintf.
19689
19690 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
19691
19692         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
19693
19694 2004-10-07  Bruno Haible  <bruno@clisp.org>
19695
19696         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
19697         fits into the provided buffer.
19698
19699 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
19700
19701         * lib/diacrit.c, diacrit.h: Add GPL notice.
19702
19703         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
19704         notice.
19705         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
19706         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
19707         This avoids a potential constant-folding bug.
19708
19709 2004-10-05  Bruno Haible  <bruno@clisp.org>
19710
19711         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
19712         for the declaration of strsep.
19713
19714 2004-10-05  Bruno Haible  <bruno@clisp.org>
19715
19716         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
19717
19718 2004-10-04  Simon Josefsson  <jas@extundo.com>
19719
19720         * modules/memmem: New file.
19721         * tests/test-memmem.c: New file.
19722         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
19723
19724 2004-10-04  Simon Josefsson  <jas@extundo.com>
19725
19726         * m4/memmem.m4: New file.
19727
19728 2004-10-04  Simon Josefsson  <jas@extundo.com>
19729
19730         * lib/memmem.h: New file.
19731         * lib/memmem.c: New file, taken from glibc.
19732
19733 2004-10-04  Simon Josefsson  <jas@extundo.com>
19734
19735         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
19736         '#ifdef USE_UNLOCKED_IO'.
19737
19738 2004-10-04  Simon Josefsson  <jas@extundo.com>
19739
19740         * config/srclist.txt: Add memmem from glibc.
19741
19742 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19743
19744         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
19745
19746         * modules/argmatch, modules/argp, modules/closeout, modules/error,
19747         modules/exclude, modules/getdate, modules/getline,
19748         modules/getndelim2, modules/getpass, modules/getpass-gnu,
19749         modules/getusershell, modules/linebuffer, modules/md5,
19750         modules/mountlist, modules/posixtm, modules/readtokens,
19751         modules/readutmp, modules/regex, modules/sha1,
19752         modules/version-etc, modules/yesno:
19753         Remove dependency on unlocked-io.
19754
19755 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19756
19757         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
19758
19759         * m4/unlocked-io.m4: Add copyright notice.
19760         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
19761
19762 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19763
19764         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
19765         * lib/xmalloc.c (xmemdup): Likewise.
19766         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
19767         XFREE): Remove these long-obsolescent macros.
19768         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
19769         * lib/xstrdup.c: Remove.
19770
19771         * lib/regex.c (re_comp): Cast gettext return value to char *,
19772         Problem reported by Martin Neitzel via Mark D. Baushke.
19773
19774 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19775
19776         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
19777         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
19778         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
19779         regex.c, sha1.c, version-etc.c, yesno.c:
19780         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
19781         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
19782         the includer's responsibility.
19783
19784         Sync from coreutils.
19785
19786         * lib/modechange.c (mode_compile): Don't decrement a pointer that
19787         points to the start of a string, as the C Standard says the
19788         resulting behavior is undefined.
19789
19790         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
19791         simple -> simple_backups, numbered_existing ->
19792         numbered_existing_backups, numbered -> numbered_backups
19793         to avoid shadowing problems.  All uses changed.
19794         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
19795         * lib/backupfile.c (check_extension, numbered_backup):
19796         Rename locals to avoid shadowing 'basename'.
19797         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
19798         once.
19799
19800         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
19801         * lib/.cvsignore: Add getopt.h.
19802
19803 2004-10-04  Bruno Haible  <bruno@clisp.org>
19804
19805         * modules/README: New file.
19806         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
19807         not a module.
19808
19809 2004-10-02  Jim Meyering  <jim@meyering.net>
19810
19811         * lib/dirfd.h, getpagesize.h: Add copyright notice.
19812
19813 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19814
19815         * modules/strsep: New file.
19816
19817 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19818
19819         * m4/strsep.m4: New file.
19820
19821 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19822
19823         * lib/strsep.h: New file.
19824         * lib/strsep.c: New file.
19825
19826 2004-10-01  Simon Josefsson  <jas@extundo.com>
19827
19828         * lib/snprintf.c (snprintf): Handle size==0.
19829
19830 2004-10-01  Simon Josefsson  <jas@extundo.com>
19831             Bruno Haible  <bruno@clisp.org>
19832
19833         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
19834         (snprintf): Declare 'args'.
19835
19836 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
19837
19838         * lib/snprintf.c: Remove comments as to why each header is needed.
19839
19840 2004-10-01  Bruno Haible  <bruno@clisp.org>
19841
19842         * MODULES.html.sh: Add strsep.
19843
19844 2004-09-30  Simon Josefsson  <jas@extundo.com>
19845
19846         * modules/snprintf: New file.
19847
19848 2004-09-30  Simon Josefsson  <jas@extundo.com>
19849
19850         * m4/snprintf.m4: New file.
19851
19852 2004-09-30  Simon Josefsson  <jas@extundo.com>
19853
19854         * lib/snprintf.h, lib/snprintf.c: New files.
19855
19856 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19857
19858         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
19859         (hol_entry_help): Never translate an empty string.
19860         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
19861         * lib/argp.h (OPTION_NO_TRANS): New option.
19862
19863 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19864
19865         * modules/argp (Maintainer): Replace Simon Josefsson
19866         by Sergey Poznyakoff.
19867
19868 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19869
19870         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
19871         changes merged back into glibc.
19872
19873 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19874
19875         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
19876
19877 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
19878
19879         * lib/xvasprintf.c: Include xalloc.h.
19880         (xvasprintf): Use xalloc_die, not xmalloc_die.
19881
19882 2004-09-29  Bruno Haible  <bruno@clisp.org>
19883
19884         * modules/alloca-opt: New file, derived from modules/alloca.
19885         * modules/allocsa: Depend on alloca-opt instead of alloca.
19886         * modules/setenv: Likewise.
19887         * modules/vasnprintf: Likewise.
19888         * MODULES.html.sh: Add alloca-opt.
19889
19890 2004-09-28  Simon Josefsson  <jas@extundo.com>
19891
19892         * gnulib-tool: New parameter --lgpl, to asseert that modules are
19893         LGPL, and to replace license template from GPL to LGPL.
19894
19895 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19896
19897         * modules/dummy: Change license to LGPL.
19898
19899 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19900
19901         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
19902
19903 2004-09-24  Simon Josefsson  <jas@extundo.com>
19904
19905         * modules/minmax (License): Change from GPL to LGPL.
19906
19907 2004-09-23  Simon Josefsson  <jas@extundo.com>
19908
19909         * gnulib-tool (--import): Typo.
19910
19911 2004-09-23  Simon Josefsson  <jas@extundo.com>
19912
19913         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
19914
19915 2004-09-22  Bruno Haible  <bruno@clisp.org>
19916
19917         * modules/*: Add 'License' field.
19918         * gnulib-tool: Accept --extract-license option.
19919         (func_get_license): New function.
19920
19921 2004-09-21  Bruno Haible  <bruno@clisp.org>
19922
19923         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
19924         Reported by Simon Josefsson.
19925
19926 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19927
19928         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
19929         gl_AC_TYPE_LONG_LONG.
19930
19931 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19932
19933         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
19934
19935 2004-09-18  Simon Josefsson  <jas@extundo.com>
19936         and  Paul Eggert  <eggert@cs.ucla.edu>
19937
19938         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
19939         calls with autoreconf.  Define GL_LIB.
19940
19941 2004-09-14  Karl Berry  <karl@gnu.org>
19942
19943         * config/srclist.txt: unsync setenv.c, sigh.
19944
19945 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19946
19947         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
19948         Problem reported by Bruno Haible in:
19949         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
19950
19951 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19952
19953         * config/srclist.txt: Comment out argp-pvh.c.
19954
19955 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
19956
19957         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
19958         in case some system header has #define'd it.  Problem reported by
19959         Soeren D. Schulze in
19960         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
19961
19962 2004-09-09  Karl Berry  <karl@gnu.org>
19963
19964         * regex.[ch]: delete from the root.  These were supposed to be
19965                 synced with emacs cvs, but this has not happened for about
19966                 a year, and anyway nothing else uses emacs regex.[ch].
19967                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
19968                 lib/regex[.ch] is untouched.
19969
19970 2004-09-09  Bruno Haible  <bruno@clisp.org>
19971
19972         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
19973
19974 2004-09-09  Bruno Haible  <bruno@clisp.org>
19975
19976         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
19977         modifications.
19978         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
19979
19980 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19981
19982         * modules/xvasprintf: New file.
19983         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
19984
19985 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19986
19987         * lib/xvasprintf.h: New file.
19988         * lib/xvasprintf.c: New file.
19989         * lib/xasprintf.c: New file.
19990
19991 2004-09-08  Bruno Haible  <bruno@clisp.org>
19992
19993         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
19994
19995 2004-09-08  Bruno Haible  <bruno@clisp.org>
19996
19997         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
19998         length is > INT_MAX.
19999         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
20000         more.
20001
20002 2004-09-08  Bruno Haible  <bruno@clisp.org>
20003
20004         * lib/stdint_.h: New file, taken from GNU clisp.
20005
20006 2004-09-08  Bruno Haible  <bruno@clisp.org>
20007             Oskar Liljeblad  <oskar@osk.mine.nu>
20008
20009         * modules/stdint: New file.
20010         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
20011
20012 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20013
20014         Import from coreutils.
20015         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
20016         strings on unbounded length.  alloca's performance benefits aren't
20017         that important here.
20018         (V_STRDUP): Remove.
20019         (parse_with_separator): New function, with most of the internals
20020         of the old parse_user_spec.  Allow user to omit both user and group,
20021         for compatibility with FreeBSD.
20022         Clone only the user name, not the entire spec.
20023         Do not set *uid, *gid unless entirely successful.
20024         Avoid memory leak in some failing cases.
20025         Fix regression for USER.GROUP reported by Dmitry V. Levin in
20026         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
20027         (parse_user_spec): Rewrite to use parse_with_separator.
20028
20029 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20030
20031         * modules/userspec: Don't depend on alloca.
20032
20033 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20034
20035         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
20036
20037 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
20038
20039         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
20040         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
20041         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
20042
20043 2004-08-16  Simon Josefsson  <jas@extundo.com>
20044
20045         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
20046         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
20047         Add --dry-run for --import.
20048         Let user provided command line parameters override configure.ac
20049         settings.
20050
20051 2004-08-12  Simon Josefsson  <jas@extundo.com>
20052
20053         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
20054         as discussed with Paul Eggert in threads rooted at
20055         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
20056         and
20057         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
20058         Before, the test was empty, and relied on ELIDE_CODE in source
20059         code.)
20060         (gl_PREREQ_GETOPT): New macro.
20061         (gl_GETOPT): Use them.
20062
20063 2004-08-12  Simon Josefsson  <jas@extundo.com>
20064
20065         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
20066         * lib/getopt_.h: Renamed from getopt.h.
20067
20068 2004-08-12  Simon Josefsson  <jas@extundo.com>
20069
20070         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
20071         Change default library name from libfoo to libgnu.
20072         Now, if you have a configure.ac that says:
20073                 gl_SOURCE_BASE(gl)
20074                 gl_M4_BASE(gl/m4)
20075                 gl_MODULES(error getopt etcetera)
20076                 gl_INIT
20077         you can import all you need by running:
20078                 ../gnulib/gnulib-tool --import
20079
20080         * modules/getopt (Files): Rename getopt.h to getopt_.h.
20081         (Makefile.am): Rewrite, use logic from argz.
20082         (Include): Use <getopt.h> instead of "getopt.h".
20083
20084 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20085
20086         * modules/argp (Files): Add m4/unlocked-io.m4.
20087         (Depends-on): Add extensions.
20088
20089 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20090
20091         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
20092         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
20093         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
20094         Check for program_invocation_name, program_invocation_short_name,
20095         flockfile, funlockfile, features.h, _getopt_long_only_r.
20096
20097 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20098
20099         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
20100         its complicated substitute.
20101         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
20102         and program_invocation_name.
20103         (__argp_basename) [!_LIBC]: Remove; the only use was
20104         replaced by its body.
20105         (__argp_short_program_name): Change condition from
20106         !defined __argp_short_program_name to
20107         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
20108         to match argp-namefrob.h.
20109         (__argp_failure): Don't assume strerror_r returns char *.
20110         * lib/argp-parse.c (N_): Define unconditionally.
20111         (argp_default_options): Fill out initializers with 0 to avoid
20112         gcc warnings.
20113
20114 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20115
20116         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
20117         getopt1.c.
20118
20119 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20120
20121         Merge from coreutils.
20122
20123         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
20124
20125         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
20126         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
20127
20128 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20129
20130         Merge from coreutils.
20131
20132         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
20133         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
20134         for Reliant Unix 5.43.
20135
20136         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
20137         (union fooround): Use uintmax_t, not long int.
20138         The rest is a merge from libc:
20139         [defined _LIBC]: Include <shlib-compat.h>.
20140         (_obstack) [defined _LIBC]: Remove after 2.3.4.
20141
20142         * lib/settime.c (settime): Recode to avoid warning with
20143         Sun Forte C 6U2.
20144
20145         * lib/strverscmp.c: Convert to UTF-8.
20146
20147 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20148
20149         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
20150         m4/uintmax_t.m4.
20151
20152 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20153
20154         * modules/xalloc-die: New file.
20155         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
20156
20157         * modules/md5 (Files): Add m4/uint32_t.m4.
20158         * modules/sha1: Renamed from modules/sha.
20159         (Files):
20160         Rename lib/sha.h to lib/sha1.h.
20161         Rename lib/sha.c to lib/sha1.c.
20162         Rename m4/sha.m4 to m4/sha1.m4.
20163         (lib_SOURCES): Likewise.
20164         (configure.ac): Rename gl_SHA to gl_SHA1.
20165         (Include): sha.h -> sha1.h.
20166
20167 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20168
20169         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
20170         * m4/sha1.m4: Renamed from sha.m4.
20171         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
20172
20173 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20174
20175         * lib/obstack.h (obstack_empty_p):
20176         Don't assume that chunk->contents is suitably aligned.
20177         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
20178         Likewise. Problem reported by Benno in
20179         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
20180
20181         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
20182         readable.  This could be improved further but it'd take some work.
20183
20184 2004-08-08  Simon Josefsson  <jas@extundo.com>
20185
20186         * modules/xgethostname (Depends-on): Remove exit and error (not
20187         used).
20188
20189         * modules/getpass-gnu: Add getpass.h.
20190         (Depends-on): Add stdbool.
20191         * modules/getpass: Add getpass.h.
20192
20193 2004-08-08  Simon Josefsson  <jas@extundo.com>
20194
20195         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
20196         Check getpass declaration.
20197
20198 2004-08-08  Simon Josefsson  <jas@extundo.com>
20199
20200         * lib/xgethostname.c: Don't include error.h (not used).
20201
20202         * lib/getpass.h: Add.
20203         * lib/getpass.c: Include getpass.h first.
20204
20205 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
20206
20207         * lib/xalloc-die.c: New file.
20208         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
20209         All uses removed.
20210         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
20211         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
20212         xalloc-die.c.
20213         (_, N_, xalloc_die): Move to xalloc-die.c.
20214         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
20215         so that we needn't mess with xalloc_msg_memory_exhausted.
20216
20217         * lib/sha1.h: Renamed from sha.h.
20218         (SHA1_H): Renamed from _SHA_H.
20219         (sha1_ctx): Renamed from sha_ctx.
20220         (sha1_init_ctx): Renamed from sha_init_ctx.
20221         (sha1_process_block): Renamed from sha_process_block.
20222         (sha1_process_bytes): Renamed from sha_process_bytes.
20223         (sha1_finish_ctx): Renamed from sha_finish_ctx.
20224         (sha1_read_ctx): Renamed from sha_read_ctx.
20225         (sha1_stream): Renamed from sha_stream.
20226         (sha1_buffer): Renamed from sha_buffer.
20227         * lib/sha1.c: Likewise; renamed from sha.c.
20228         Do not include <sys/types.h>.
20229         Include <stddef.h> rather than <stdlib.h>.
20230
20231 2004-08-08  Bruno Haible  <bruno@clisp.org>
20232
20233         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
20234         FILESYSTEM_PREFIX_LEN.
20235         * lib/progreloc.c: Likewise.
20236         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
20237
20238 2004-08-06  Simon Josefsson  <jas@extundo.com>
20239
20240         * modules/progname (Depends-on): Don't depend on stdbool.
20241
20242 2004-08-06  Simon Josefsson  <jas@extundo.com>
20243
20244         * modules/getsubopt: New file.
20245         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
20246         getsubopt.
20247
20248 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20249
20250         More merge from coreutils.
20251
20252         * m4/utimens.m4, m4/utimecmp.m4: New files.
20253         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
20254         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
20255         prereq.m4, sha.m4: Import changes from coreutils.
20256
20257 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20258
20259         More merge from coreutils.
20260         * modules/raise, modules/readtokens0, modules/utimens:
20261         * modules/utimecmp, module/xnanosleep: New files.
20262         * modules/strftime: Add lib/strftime.h.
20263         Change include from <time.h> to "strftime.h".
20264         * modules/yesno: Add lib/yesno.h.
20265         * modules/backupfile: Remove lib/addext.c.
20266         * modules/euidaccess: Add stat-macros.h.
20267         * modules/canonicalize, modules/euidaccess,
20268         modules/filemode, modules/lchown, modules/makepath,
20269         modules/rmdir, modules/stat: Likewise.
20270
20271 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20272
20273         Merge from tar.
20274         * lib/argp-help.c (make_hol, hol_append): Don't assume that
20275         SIZE_MAX is a valid preprocessor constant.
20276         (__argp_basename): Change from "#ifndef _LIBC"
20277         to "#ifndef __argp_short_program_name", so that
20278         we don't compile these functions for tar.
20279
20280         More merges from coreutils.
20281         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
20282         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
20283         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
20284         * lib/addext.c: Remove; no longer needed.
20285         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
20286         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
20287         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
20288         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
20289         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
20290         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
20291         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
20292         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
20293         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
20294         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
20295         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
20296         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
20297         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
20298         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
20299         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
20300         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
20301         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
20302         Import changes from coreutils.
20303
20304 2004-08-05  Simon Josefsson  <jas@extundo.com>
20305
20306         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
20307
20308 2004-08-05  Simon Josefsson  <jas@extundo.com>
20309
20310         * m4/getsubopt.m4: New file.
20311
20312 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20313
20314         Merge from coreutils.
20315
20316         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
20317         * m4/getcwd-path-max.m4: New files.
20318
20319         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
20320         FILESYSTEM_PREFIX_LEN ->
20321         FILE_SYSTEM_PREFIX_LEN.
20322         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
20323         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
20324         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
20325         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
20326
20327         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
20328         prerequisite modules now handle the DOS stuff.
20329         Don't check for unistd.h.
20330
20331 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20332
20333         Merge from coreutils.
20334
20335         * lib/.gdb-history: Remove; this doesn't belong here.
20336
20337         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
20338         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
20339         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
20340         * lib/getcwd.c: New files.
20341
20342         * lib/dirname.h: Include <stdbool.h>.
20343         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
20344         for consistency with POSIX terminology.  All uses changed.
20345         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
20346         (strip_trailing_slashes): Use bool for booleans.
20347         * lib/stripslash.c (strip_trailing_slashes): Likewise.
20348
20349         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
20350         sometimes returns a positive errno value even when it succeeds.
20351         (print_errno_message) [!LIBC]: Fall back on strerror if
20352         __strerror_r fails.
20353
20354         * lib/path-concat.c (mempcpy): Don't define if a system header defines
20355         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
20356         (longest_relative_suffix): New function.
20357         (path_concat): Use it.  Assume first argument is not NULL.
20358         Port to DOS.  Omit redundant separators.
20359         Report an error instead of returning NULL.
20360         Use mempcpy instead of memcpy.
20361         (xpath_concat): Remove: not declared or used.
20362
20363         * lib/same.h: Include <stdbool.h>
20364         (same_name): Return bool, not int.
20365         * lib/same.c (same_name): Likewise.
20366         (errno): Don't declare; we assume C89 or better now.
20367
20368         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
20369         if not already defined.
20370
20371         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
20372         * lib/dup-safer.c (errno): Likewise.
20373
20374 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20375
20376         Merge from coreutils.
20377         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
20378         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
20379         * modules/path-concat: Don't depend on strdup.
20380
20381 2004-08-03  Simon Josefsson  <jas@extundo.com>
20382
20383         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
20384         * lib/progname.h: Don't include stdbool.h.
20385
20386 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20387
20388         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
20389         * MODULES.html.sh (func_all_modules): Remove fatal.
20390
20391 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20392
20393         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
20394
20395 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20396
20397         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
20398         working.
20399
20400 2004-08-02  Simon Josefsson  <jas@extundo.com>
20401
20402         * lib/getsubopt.h: New file, with comments from Bruno Haible.
20403         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
20404         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
20405
20406 2004-08-01  Simon Josefsson  <jas@extundo.com>
20407
20408         * lib/xgetdomainname.c: Include stdlib.h, for free().
20409
20410 2004-07-19  Bruno Haible  <bruno@clisp.org>
20411
20412         * MODULES.html.sh (func_all_modules): Add dummy.
20413
20414 2004-07-16  Simon Josefsson  <jas@extundo.com>
20415
20416         * modules/dummy: New file.
20417
20418 2004-07-16  Simon Josefsson  <jas@extundo.com>
20419
20420         * lib/dummy.c: New file.
20421
20422 2004-07-16  Bruno Haible  <bruno@clisp.org>
20423
20424         * lib/backupfile.h: Add extern "C" for C++.
20425         * lib/closeout.h: Likewise.
20426         * lib/copy-file.h: Likewise.
20427         * lib/findprog.h: Likewise.
20428         * lib/full-write.h: Likewise.
20429         * lib/pathname.h: Likewise.
20430         * lib/progname.h: Likewise.
20431         * lib/stpcpy.h: Likewise.
20432         * lib/stpncpy.h: Likewise.
20433         * lib/strcase.h: Likewise.
20434         * lib/strstr.h: Likewise.
20435         * lib/xalloc.h: Likewise.
20436
20437         * lib/mbswidth.h: Add extern "C" for C++.
20438         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
20439
20440 2004-07-13  Robert Millan  <robertmh@gnu.org>
20441
20442         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
20443
20444 2004-07-09  Simon Josefsson  <jas@extundo.com>
20445
20446         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
20447         failed without this.)
20448
20449 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
20450
20451         * modules/chown (Files): Add lib/fchown-stub.c, since
20452         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
20453
20454 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
20455
20456         * lib/fchown-stub.c: New file.
20457
20458 2004-06-24  Jim Meyering  <jim@meyering.net>
20459
20460         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
20461
20462 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20463
20464         * modules/argz: Omit "#include".
20465
20466         * MODULES.html.sh (func_all_modules): Add calloc, to match
20467         2004-06-01 addition of calloc module.
20468
20469 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20470
20471         * m4/argz.m4: New file, which is autoupdated from libtool.
20472
20473 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20474
20475         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
20476         libtool.
20477
20478 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20479
20480         * config/srclist-update: Don't insist on "USA." before the
20481         close-comment, as libtool omits the period and puts the */ on a
20482         separate line.
20483         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
20484         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
20485
20486 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
20487
20488         * modules/argz: New file.
20489         * MODULES.html.sh (func_all_modules): Add argz.
20490
20491 2004-06-12  Jim Meyering  <jim@meyering.net>
20492         and  Paul Eggert  <eggert@cs.ucla.edu>
20493
20494         * modules/hash (Files): Add lib/xalloc.h.
20495         * modules/pipe (Depends-on): Add wait-process.
20496         * modules/stat (Depends-on): Add xalloc.
20497         * modules/userspec (Files): Add lib/userspec.h.
20498         * modules/xstrto
20499
20500         Upgrade from gettext-0.13.
20501         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
20502         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
20503         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
20504
20505 2004-06-10  Jim Meyering  <jim@meyering.net>
20506
20507         * lib/calloc.c: New file.
20508
20509 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
20510
20511         * lib/getdate.y (yylex): Allow space between sign and number.
20512         Problem reported by Dan Jacobson.
20513
20514 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
20515
20516         Merge from coreutils CVS.
20517
20518         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
20519         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
20520         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
20521         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
20522         xstrtol.m4: Fix copyright date and/or serial number.
20523
20524         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
20525         See if we need an fchown replacement.
20526         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
20527         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
20528         and use the replacement function if we detect either defect.
20529
20530         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
20531         gl_UTIMECMP.
20532
20533 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
20534         and  Jim Meyering  <jim@meyering.net>
20535
20536         Merge from coreutils CVS.
20537
20538         * lib/stat-macros.h: New file, with contents from file-type.h
20539         and coreutils' system.h.
20540         * lib/file-type.c: Include "stat-macros.h".
20541         * lib/file-type.h (file_type): Move all macro definitions to new file,
20542         stat-macros.h.
20543
20544         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
20545         Wrap old code with this conditional.
20546         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
20547         function that does not dereference symlinks.
20548         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
20549
20550         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
20551         dependency problems.
20552         (xreadlink): Accept new arg SIZE, for efficiency.
20553         All decls and uses changed.
20554         * lib/xreadlink.h: Include <stddef.h>, for size_t.
20555
20556         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
20557         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
20558
20559         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
20560         sysexits.h.
20561
20562 2004-06-01  Jim Meyering  <jim@meyering.net>
20563
20564         * m4/calloc.m4: New file.
20565
20566 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
20567
20568         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
20569         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
20570         Also, fix a typo in a diagnostic.
20571
20572 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
20573
20574         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
20575         or AC_FUNC_REALLOC.
20576
20577 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
20578
20579         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
20580         macros to be defined.
20581         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
20582         the allocator returns NULL because the requested size is zero.
20583
20584 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
20585
20586         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
20587         var.  Add comment explaining why libc still defines it.  This
20588         merges the following patch from glibc:
20589         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
20590
20591 2004-05-20  Andreas Schwab  <schwab@suse.de>
20592
20593         * m4/free.m4: Replace free if it not known to work, not the other
20594         way round.
20595
20596 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
20597
20598         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
20599         present in glibc since revision 1.1 of this file.
20600         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
20601         obstack_alignment_mask, obstack_alloc, obstack_base,
20602         obstack_blank, obstack_blank_fast, obstack_chunk_size,
20603         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
20604         obstack_grow0, obstack_init, obstack_int_grow,
20605         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
20606         obstack_next_free, obstack_object_size, obstack_ptr_grow,
20607         obstack_ptr_grow_fast, obstack_room): Remove declarations of
20608         nonexistent functions.
20609
20610 2004-05-18  Karl Berry  <karl@gnu.org>
20611
20612         * config/srclist.txt: break link for vasnprintf.c.
20613
20614 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
20615
20616         Port obstack to the AS/400, where pointers are 16 bytes wide and
20617         you cannot cast an integer to a valid pointer.  This patch is
20618         currently waiting to be integrated into glibc; see
20619         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
20620
20621         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
20622         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
20623         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
20624         (struct obstack): temp member is now a union of a pointer and
20625         an integer, instead of an integer.  All integer uses changed.
20626         This does not affect the physical layout of struct obstack,
20627         except on hosts (like the AS/400) where the size or alignment of
20628         void * is greater than that of ptrdiff_t.
20629         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
20630         __STDC__)]: Store temporary in pointer member of union, not
20631         integer member.
20632         * lib/obstack.c: Include <stddef.h>, for offsetof.
20633         (struct fooalign): Remove; it doesn't need a name.
20634         (union fooround): Change double to long double, and add void *.
20635         (DEFAULT_ALIGNMENT): Use offsetof to compute.
20636         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
20637         not a macro.  Hence the values are always int; so remove all
20638         casts-to-int in uses.
20639
20640 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
20641
20642         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
20643         we can get this patch merged into glibc.
20644
20645 2004-05-17  Derek R. Price  <derek@ximbiot.com>
20646             Paul Eggert  <eggert@cs.ucla.edu>
20647
20648         * m4/argp: Depend on alloca.
20649
20650 2004-05-17  Derek R. Price  <derek@ximbiot.com>
20651             Paul Eggert  <eggert@cs.ucla.edu>
20652
20653         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
20654         freecoding.
20655
20656 2004-05-17  Bruno Haible  <bruno@clisp.org>
20657
20658         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
20659         precision that consists of a '.' followed by an empty digit string.
20660         Patch by Tor Lillqvist <tml@iki.fi>.
20661
20662 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
20663
20664         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
20665         for backward compatibility with older code.  We need our own
20666         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
20667         it under some other name, and our alloca.h will define it.
20668
20669 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
20670             Derek Price  <derek@ximbiot.com>
20671
20672         * lib/alloca.c: Include <alloca.h>, to get our interface.
20673         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
20674         include <alloca.h> first.  Use C89 prototype for alloca; this
20675         requires including <stddef.h> for size_t.  Use extern "C" if C++.
20676         Use #elif for simplicity, since we can assume C89 now.
20677         Don't try to source the system alloca.h since it will not be found
20678         and to prevent recursively including its replacement.
20679         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
20680         * lib/regex.c: Likewise.
20681
20682 2004-05-16  Derek Price  <derek@ximbiot.com>
20683             Paul Eggert  <eggert@cs.ucla.edu>
20684
20685         getline cleanup.  This changes the getndelim2 API: both order of
20686         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
20687         no delimiter).
20688
20689         * lib/getline.c: Don't include stddef.h or stdio.h, since our
20690         interface does that.
20691         (getline): Always use getdelim, so that we don't have two
20692         copies of this code.
20693         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
20694         if available.
20695         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
20696         (GETNDELIM2_MAXIMUM): New macro.
20697         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
20698         instead of the old practice of delim2==0.  All callers changed.
20699         Return -1 on overflow, instead of returning junk.
20700         Do not set *linesize unless allocation succeeds.
20701         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
20702         that we include sys/types.h.
20703         * lib/getnline.h: Likewise.
20704         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
20705         (getndelim2): Reorder arguments.
20706         * lib/getnline.c (getnline, getndelim):
20707         Don't discard the NMAX argument.
20708         (getnline): Invoke getndelim, to avoid code duplication.
20709         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
20710         of (size_t) -1 by callers of the getnline family.
20711
20712 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20713
20714         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
20715         Check for gettimeofday.
20716         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
20717         Check for settimeofday, stime.
20718
20719 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20720
20721         * lib/nanosleep.c (suspended): Change its type from int to
20722         sig_atomic_t volatile.
20723         (first_call): Make it private to rpl_nanosleep, and have it
20724         be zero initially as that's a bit faster.
20725         (my_usleep): Round up fractional times instead of truncating them,
20726         as this is the usual meaning for 'sleep'.
20727
20728         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
20729         doesn't work.
20730         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
20731         (ENOSYS): Define if not defined.
20732         (settime): Fall back on stime if it exists and settimeofday fails.
20733         But don't bother with fallbacks if a method fails with errno == EPERM.
20734
20735 2004-05-11  Jim Meyering  <jim@meyering.net>
20736
20737         Prior to this change, the save_cwd caller required read access to the
20738         current directory on most systems (ones with the fchdir function).
20739
20740         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
20741         fails, try write-only, and finally, resort to using xgetcwd.
20742
20743 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
20744
20745         * lib/obstack.c, obstack.h: Import changes from libc.
20746
20747 2004-04-28  Bruno Haible  <bruno@clisp.org>
20748
20749         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
20750         also implicitly appends .exe to executables.
20751         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
20752         accepts Windows pathnames.
20753         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
20754         Treat Cygwin like Windows, since it now accepts Windows pathnames.
20755         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
20756         Treat Cygwin like Windows, since it now accepts Windows pathnames.
20757         Reported by Derek Robert Price <derek@ximbiot.com>.
20758
20759 2004-04-21  Karl Berry  <karl@gnu.org>
20760
20761         * config/srclist.txt (localcharset.c): break sync.
20762
20763 2004-04-20  Paul Eggert  <eggert@twinsun.com>
20764
20765         * m4/host-os.m4: Add a copyright notice.
20766
20767 2004-04-20  Jim Meyering  <jim@meyering.net>
20768
20769         Change UTILS_ to gl_ in AC_DEFINE'd names.
20770         Change utils_- and jm_-prefixed variables, too.
20771         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
20772         UTILS_FUNC_MKDIR_TRAILING_SLASH.
20773         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
20774
20775         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
20776         Don't emit trailing blanks.
20777         Also rename jm_-prefixed variables to have gl_ prefix.
20778
20779         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
20780         Also rename jm_-prefixed variables to have gl_ prefix.
20781
20782         * m4/jm-macros.m4: Reflect the renamings.
20783         * m4/prereq.m4: Likewise.
20784
20785 2004-04-20  Jim Meyering  <jim@meyering.net>
20786
20787         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
20788         memory.
20789
20790 2004-04-20  Jim Meyering  <jim@meyering.net>
20791             Bruno Haible  <bruno@clisp.org>
20792
20793         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
20794         memory when realloc fails.
20795
20796 2004-04-19  Jim Meyering  <jim@meyering.net>
20797
20798         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
20799         now that readutmp.c may call `free (0)'.
20800
20801 2004-04-19  Bruno Haible  <bruno@clisp.org>
20802
20803         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
20804         * m4/inttypes_h.m4: Likewise.
20805         * m4/stdint_h.m4: Likewise.
20806         * m4/intmax_t.m4: Likewise.
20807         * m4/uintmax_t.m4: Likewise.
20808
20809 2004-04-18  Jim Meyering  <jim@meyering.net>
20810
20811         * m4/prereq.m4: Don't forbid jm_ prefix.
20812
20813         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
20814         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
20815         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
20816         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
20817         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
20818         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
20819         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
20820         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
20821         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
20822         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
20823         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
20824         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
20825         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
20826         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
20827         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
20828         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
20829         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
20830         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
20831         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
20832
20833 2004-04-18  Jim Meyering  <jim@meyering.net>
20834
20835         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
20836         failure, don't leak memory and do call END_UTMP_ENT.
20837
20838 2004-04-16  Jim Meyering  <jim@meyering.net>
20839
20840         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
20841         coreutils' stat program.
20842         (gl_PREREQ): Don't require jm_PREREQ_STAT.
20843
20844 2004-04-11  Paul Eggert  <eggert@twinsun.com>
20845
20846         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
20847         C89.
20848         (CHAR_BIT): Remove, since we assume C89.
20849         Include <stdint.h> if available, as per current Autoconf CVS advice.
20850
20851 2004-03-31  Jim Meyering  <jim@meyering.net>
20852
20853         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
20854         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
20855         * m4/xalloc.m4: Likewise.
20856
20857 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20858
20859         Merge from coreutils.
20860
20861         * m4/inttostr.m4: New file.
20862         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
20863         Require AM_STDBOOL_H and gl_TIMESPEC instead.
20864         Require gl_CLOCK_TIME.
20865         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
20866
20867 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20868
20869         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
20870         not bool, to be more consistent with Unix conventions.
20871         Suggested by Bruno Haible.
20872
20873         Merge from coreutils.
20874
20875         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
20876         * lib/umaxtostr.c: New files.
20877
20878         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
20879         the usual <time.h> dance.
20880         (get_date): Change signature to support fractional time stamps.
20881         All callers changed.
20882         * lib/getdate.y: Include "getdate.h" first, as we can now
20883         assume C89 and don't need to worry about 'const'.
20884         Similarly, include "unlocked-io.h" near start, not in middle.
20885         Include <limits.h>.
20886         (textint.value): Use long int rather than int.
20887         (textint.digits): Use size_t rather than int.
20888         (BILLION, LOG10_BILLION): New constants.
20889         (parser_control): New member rel_ns.  Members day_ordinal,
20890         time_zone, month, day, hour, minutes, rel_year, rel_month,
20891         rel_day, rel_hour, rel_minutes, rel_seconds
20892         are now long int, not int.  Member seconds is now struct timespec,
20893         not int.  New member timespec_seen.  Members dates_seen, days_seen,
20894         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
20895         not int.
20896         (%union.intval): Now long int, not int.
20897         New member timespec.
20898         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
20899         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
20900         (spec): Now is a timespec or an item list.
20901         (timespec, items): New nonterminals.
20902         (time, rel, relunit, number, get_date):
20903         Add support for fractional seconds.
20904         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
20905         (gmtime, localtime, mktime): Remove decls; not needed with C89.
20906         (to_hour): First arg is now long int, not int.
20907         (to_year): Returns long int, not int.
20908         Don't treat year -70 like 70.
20909         (tm_diff): Returns long int, not int.
20910         (lookup_word): Use bool instead of int when appropriate.
20911         (yylex): Use size_t for count, not int.
20912         Detect overflow when parsing large integer constants.
20913         Add support for fractions.
20914         (get_date): Make pointers 'const' if possible.
20915         Use more-portable code to detect integer overflow.
20916         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
20917         Don't use ctime; it's not reliable if the year has >4 digits.
20918
20919         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
20920         This is for compatibility with BSD.
20921
20922         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
20923         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
20924         From coreutils' system.h.
20925
20926         * lib/userspec.c: Don't include "posixver.h".
20927         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
20928         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
20929         compatible extension.  Simplify code by removing a boolean int
20930         that was always nonzero if a string was nonnull.
20931
20932 2004-03-30  Jim Meyering  <jim@meyering.net>
20933
20934         Merge from coreutils.
20935
20936         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
20937         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
20938         on some systems one must include <grp.h> before it.
20939         Reported by Christian Krackowizer.
20940
20941 2004-03-30  Jim Meyering  <jim@meyering.net>
20942
20943         Merge from coreutils.
20944
20945         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
20946
20947         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
20948         an empty input stream.
20949
20950         * lib/readtokens.c: Include <stdbool.h>.
20951         (readtoken): Use `size_t' rather than int/long.
20952         All callers adjusted.
20953         Use `bool' rather than `int' where appropriate.
20954         Use memset rather than an explicit loop.
20955         Use x2nrealloc rather than xrealloc.
20956         Allow the use of `\0' as a delimiter.
20957         (readtokens): Likewise.
20958         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
20959
20960 2004-03-30  Jim Meyering  <jim@meyering.net>
20961
20962         * m4/realloc.m4: Remove file, since now it does no more than
20963         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
20964         the `configure.ac' section of module/realloc.
20965         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
20966
20967 2004-03-30  Bruno Haible  <bruno@clisp.org>
20968
20969         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
20970         nonnull.
20971
20972 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20973
20974         Merge changes to getloadavg.c from coreutils and Emacs.
20975
20976         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
20977         Define to an expression, not to the empty string.
20978         Include cloexec.h and xalloc.h.
20979         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
20980         Use set_cloexec_flag rather than rolling our own.
20981         * lib/cloexec.c, lib/cloexec.h: New files.
20982
20983 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20984
20985         * m4/cloexec.m4: New file.
20986
20987 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20988
20989         * lib/getopt.h: Sync with libc CVS.
20990
20991 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20992             Bruno Haible  <bruno@clisp.org>
20993
20994         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
20995         mbswidth.
20996
20997 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20998             Bruno Haible  <bruno@clisp.org>
20999
21000         * lib/mbswidth.h: Include <wchar.h> only if
21001         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
21002         <wchar.h>.
21003         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
21004
21005 2004-03-09  Paul Eggert  <eggert@twinsun.com>
21006
21007         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
21008         Sync with libc CVS.
21009         * lib/getopt_int.h: New file, also synced from libc.
21010
21011 2004-03-09  Paul Eggert  <eggert@twinsun.com>
21012
21013         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
21014         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
21015         Bring back getopt.c, getopt.h, getopt1.c.
21016
21017 2004-03-07  Paul Eggert  <eggert@twinsun.com>
21018
21019         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
21020         All uses changed.  Check for sa_sigaction member; this fixes
21021         a bug first reported by Jason Andrade in
21022         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
21023
21024 2004-03-07  Paul Eggert  <eggert@twinsun.com>
21025
21026         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
21027         '#if' expressions.  Unlike the code it replaces, it does not
21028         depend on (defined _SC_PAGESIZE).  However, it does depend on
21029         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
21030         first reported by Jason Andrade in
21031         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
21032
21033 2004-02-25  Simon Josefsson  <jas@extundo.com>
21034
21035         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
21036
21037 2004-02-25  Simon Josefsson  <jas@extundo.com>
21038
21039         * lib/strdup.h: New file.
21040         * lib/strdup.c: Include it.
21041         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
21042         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
21043
21044 2004-02-23  Karl Berry  <karl@gnu.org>
21045
21046         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
21047         (from fencepost.gnu.org:/gd/gnuorg).
21048
21049 2004-02-23  Karl Berry  <karl@gnu.org>
21050
21051         * config/srclistvars.sh (GNUORG) [karl]: redefine.
21052         * config/srclist.txt: add maintain/standards documents.
21053
21054 2004-02-18  Bruno Haible  <bruno@clisp.org>
21055
21056         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
21057         Reported by Derek Robert Price <derek@ximbiot.com>.
21058
21059 2004-02-16  Karl Berry  <karl@gnu.org>
21060
21061         * config/mkinstalldirs, install-sh: update from automake.
21062
21063 2004-02-06  Karl Berry  <karl@gnu.org>
21064
21065         * m4/po.m4: update from gettext 0.14.1.
21066
21067 2004-02-06  Karl Berry  <karl@gnu.org>
21068
21069         * lib/config.charset: update from gettext 0.14.1.
21070
21071 2004-02-05  Paul Eggert  <eggert@twinsun.com>
21072
21073         Add comments and code, prompted by suggestions from Bruno Haible
21074         for sh-quote.
21075         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
21076         describing the enum quoting_style values.
21077         * lib/quotearg.c (quotearg_alloc): New function.
21078         (quotearg_buffer_restyled): Treat lone { and } as special.
21079         Treat = as special.  Work around bug with older shells
21080         that "see" a '\' that is really the 2nd byte of a multibyte char.
21081         Quote empty string with shell_quoting_style.
21082
21083 2004-02-03  Bruno Haible  <bruno@clisp.org>
21084
21085         * m4/pipe.m4: New file, from GNU gettext.
21086
21087 2004-02-03  Bruno Haible  <bruno@clisp.org>
21088
21089         * lib/pipe.h: New file, from GNU gettext.
21090         * lib/pipe.c: New file, from GNU gettext.
21091
21092 2004-01-27  Bruno Haible  <bruno@clisp.org>
21093
21094         * m4/execute.m4: New file, from GNU gettext.
21095
21096 2004-01-27  Bruno Haible  <bruno@clisp.org>
21097
21098         * lib/execute.h: New file, from GNU gettext.
21099         * lib/execute.c: New file, from GNU gettext.
21100         * lib/w32spawn.h: New file, from GNU gettext.
21101
21102 2004-01-24  Paul Eggert  <eggert@twinsun.com>
21103
21104         Merge from diffutils.
21105
21106         * lib/file-type.c (file_type): Add typed memory objects.
21107         * lib/file-type.h (S_TYPEISTMO): New macro.
21108
21109         * lib/c-stack.h (c_stack_action): Remove argv argument.
21110         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
21111         (die): Don't calculate message unless segv_action returns.
21112         (get_stack_location, min_address_from_argv, max_address_from_argv,
21113         volatile stack_base, volatile_stack_size): Remove.
21114         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
21115         that every segmentation violation is a stack overflow.  (Ouch!)
21116         See Debian bug 136249 (still outstanding) for more info about why
21117         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
21118
21119 2004-01-24  Paul Eggert  <eggert@twinsun.com>
21120
21121         Exit-status fix from coreutils.
21122
21123         Use exit_failure consistently in place of EXIT_FAILURE,
21124         so that program exit statuses are consistent on failure.
21125
21126         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
21127         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
21128         * lib/argmatch.h: Comment fix to match the above.
21129         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
21130         Now a macro referring to exit_failure, instead of a separate
21131         variable.  Include "exitfail.h" to get it.
21132         * lib/xstrtol.h: Include "exitfail.h".
21133         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
21134
21135         * lib/long-options.c (parse_long_options): Use prototype
21136         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
21137         for clarity.
21138
21139 2004-01-21  Jim Meyering  <jim@meyering.net>
21140
21141         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
21142         so as not to conflict with a different-sized __mktime_internal
21143         function in GNU libc.
21144         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
21145         Problem building statically-linked `ls' reported by Michael Brunnbauer.
21146
21147 2004-01-20  Karl Berry  <karl@gnu.org>
21148
21149         * config/config.guess: update from config.
21150
21151         * config/srclistvars.sh: GNUWWWLICENSES for karl.
21152
21153 2004-01-20  Bruno Haible  <bruno@clisp.org>
21154
21155         Safer stack allocation.
21156         * lib/setenv.c: Include allocsa.h.
21157         (alloca): Remove fallback definition.
21158         (freea): Remove macro.
21159         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
21160         instead of freea.
21161
21162 2004-01-20  Bruno Haible  <bruno@clisp.org>
21163
21164         * m4/eealloc.m4: New file, from GNU gettext.
21165
21166 2004-01-20  Bruno Haible  <bruno@clisp.org>
21167
21168         * m4/allocsa.m4: New file, from GNU gettext.
21169
21170 2004-01-20  Bruno Haible  <bruno@clisp.org>
21171
21172         * lib/xallocsa.h: New file, from GNU gettext.
21173         * lib/xallocsa.c: New file, from GNU gettext.
21174
21175 2004-01-20  Bruno Haible  <bruno@clisp.org>
21176
21177         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
21178
21179 2004-01-20  Bruno Haible  <bruno@clisp.org>
21180
21181         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
21182         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
21183         specially.
21184
21185 2004-01-20  Bruno Haible  <bruno@clisp.org>
21186
21187         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
21188         patch.
21189
21190 2004-01-20  Bruno Haible  <bruno@clisp.org>
21191
21192         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
21193
21194 2004-01-20  Bruno Haible  <bruno@clisp.org>
21195
21196         * lib/eealloc.h: New file.
21197
21198 2004-01-20  Bruno Haible  <bruno@clisp.org>
21199
21200         * lib/binary-io.h: Avoid warnings on Cygwin.
21201
21202 2004-01-20  Bruno Haible  <bruno@clisp.org>
21203
21204         * lib/allocsa.h: New file, from GNU gettext.
21205         * lib/allocsa.c: New file, from GNU gettext.
21206
21207 2004-01-18  Karl Berry  <karl@gnu.org>
21208
21209         * doc/gpl.texi, doc/lgpl.texi: new files.
21210
21211 2004-01-18  Karl Berry  <karl@gnu.org>
21212
21213         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
21214         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
21215
21216 2004-01-15  Paul Eggert  <eggert@twinsun.com>
21217
21218         Merge from coreutils.
21219
21220         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
21221         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
21222         (gl_DEFAULT_POSIX2_VERSION): Move
21223         the documentation from 'configure' into 'config.hin',
21224         so that 'configure --help' isn't burdened by it and
21225         we don't have to worry about its formatting there.
21226         Reword the documentation so that it's more succinct
21227         and can be run together into a single paragraph.
21228         * m4/same.m4 (gl_SAME): Check for pathconf.
21229
21230 2004-01-15  Paul Eggert  <eggert@twinsun.com>
21231
21232         Merge from coreutils.
21233
21234         * lib/posixver.c: Include posixver.h.
21235
21236         * lib/same.c: Include <stdbool.h>, <limits.h>.
21237         (_POSIX_NAME_MAX): Define if not defined.
21238         (MIN): New macro.
21239         (same_name): If file names are silently truncated, report
21240         that the file names are the same if they are the same after
21241         the silent truncation.
21242
21243         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
21244         conversion function.
21245         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
21246         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
21247         longer needed.
21248
21249 2004-01-15  Jim Meyering  <jim@meyering.net>
21250
21251         Merge from coreutils.
21252
21253         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
21254         if no library is required.
21255         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
21256         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
21257         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
21258         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
21259         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
21260         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
21261         value, $ac_cv_search_crypt, if it's "none required".
21262         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
21263         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
21264         not gl_FUNC_GETLOADAVG.
21265         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
21266         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
21267
21268 2004-01-15  Jim Meyering  <jim@meyering.net>
21269
21270         Merge from coreutils.
21271
21272         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
21273         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
21274         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
21275
21276         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
21277         optional configure-time default.
21278
21279         * lib/version-etc.c (version_etc_copyright): Update copyright date.
21280
21281         * lib/xreadlink.c (xreadlink): Correct outdated comment.
21282
21283 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
21284
21285         Merge from coreutils.
21286
21287         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
21288         value, $ac_cv_search_nanosleep, if it's "none required".
21289
21290 2004-01-14  Paul Eggert  <eggert@twinsun.com>
21291
21292         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
21293         with like-named macro in fnmatch.c.
21294         (EXT): Use an internal constant instead.
21295
21296         Merge fnmatch patches from glibc.
21297         * lib/fnmatch.c (mbsinit): Remove define.
21298         Add libc_hidden_ver (__fnmatch, fnmatch).
21299         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
21300         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
21301
21302 2004-01-14  Karl Berry  <karl@gnu.org>
21303
21304         * config/install-sh: update from automake.
21305
21306 2004-01-13  Karl Berry  <karl@gnu.org>
21307
21308         * config/install-sh: update from automake.
21309
21310 2004-01-09  Karl Berry  <karl@gnu.org>
21311
21312         * config/install-sh: update from automake.
21313
21314 2004-01-05  Karl Berry  <karl@gnu.org>
21315
21316         * config/config.{sub,guess}: update from config.
21317
21318 2003-12-31  Karl Berry  <karl@gnu.org>
21319
21320         * config/depcomp: update from automake.
21321
21322 2003-12-14  Karl Berry  <karl@gnu.org>
21323
21324         * lib/config.charset: update from gettext-runtime.
21325
21326 2003-12-03  Paul Eggert  <eggert@twinsun.com>
21327
21328         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
21329         Bug reported by Alfred M. Szmidt.
21330
21331 2003-12-03  Bruno Haible  <bruno@clisp.org>
21332
21333         * m4/gettext.m4: Upgrade from gettext-0.13.
21334         * m4/po.m4: Upgrade from gettext-0.13.
21335         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
21336         * m4/intmax.m4: New file, from gettext-0.13.
21337         * m4/printf-posix.m4: New file, from gettext-0.13.
21338
21339 2003-11-29  Karl Berry  <karl@gnu.org>
21340
21341         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
21342
21343 2003-11-25  Paul Eggert  <eggert@twinsun.com>
21344             Bruno Haible  <bruno@clisp.org>
21345
21346         * lib/printf-parse.h: Don't include sys/types.h.
21347         (ARG_NONE): New macro.
21348         (char_directive): Change type of *arg_index fields to size_t.
21349         * lib/printf-parse.c: Don't include sys/types.h.
21350         (SSIZE_MAX): Remove macro.
21351         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
21352         Remove unnecessary overflow check.
21353         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
21354         fields.
21355
21356 2003-11-25  Bruno Haible  <bruno@clisp.org>
21357
21358         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
21359
21360 2003-11-25  Bruno Haible  <bruno@clisp.org>
21361
21362         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
21363         gt_TYPE_SSIZE_T.
21364
21365 2003-11-24  Paul Eggert  <eggert@twinsun.com>
21366
21367         * modules/alloca: Remove dependency on xalloc.
21368
21369 2003-11-24  Paul Eggert  <eggert@twinsun.com>
21370
21371         * lib/alloca.c: Remove dependency on xalloc module.
21372         (xalloc_die): Remove.
21373         (memory_full) [!defined emacs]: New macro.
21374         [!defined emacs]: Don't include xalloc.h.
21375         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
21376         address arithmetic overflows.  Change datatypes a bit to avoid
21377         unnecessary casts.
21378
21379 2003-11-22  Jim Meyering  <jim@meyering.net>
21380
21381         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
21382         s/size/size_t/.
21383
21384 2003-11-21  Karl Berry  <karl@gnu.org>
21385
21386         * config/config.{sub,guess}: update from config.
21387
21388 2003-11-18  Karl Berry  <karl@gnu.org>
21389
21390         * config/config.{sub,guess}: update from config.
21391
21392         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
21393
21394 2003-11-17  Paul Eggert  <eggert@twinsun.com>
21395
21396         * README: Mention that S+T cannot overflow if S is the size of
21397         an existing object and T is sufficiently small.
21398
21399 2003-11-17  Jim Meyering  <jim@meyering.net>
21400
21401         On systems without utime and without a utimes function capable of
21402         dealing with a NULL struct utimbuf* argument, this utime replacement
21403         could -- in unusual circumstances -- leak a file descriptor.
21404         * lib/utime.c: Include <unistd.h> and <errno.h>.
21405         (utime_null): Be sure to close `fd' and to preserve errno.
21406         Reported by Geoff Collyer via Arnold Robbins.
21407
21408 2003-11-17  Bruno Haible  <bruno@clisp.org>
21409
21410         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
21411         (Depends-on): Add xsize.
21412
21413 2003-11-17  Bruno Haible  <bruno@clisp.org>
21414
21415         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
21416
21417 2003-11-17  Bruno Haible  <bruno@clisp.org>
21418
21419         * lib/vasnprintf.c (alloca): Remove fallback definition.
21420         (freea): Remove definition.
21421         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
21422         Reported by Paul Eggert.
21423
21424 2003-11-16  Paul Eggert  <eggert@twinsun.com>
21425             Bruno Haible  <bruno@clisp.org>
21426
21427         Protect against address arithmetic overflow.
21428         * lib/printf-args.h: Include stddef.h.
21429         (arguments): Change type of field 'count' to size_t.
21430         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
21431         'unsigned int' where appropriate.
21432         * lib/printf-parse.h: Include sys/types.h.
21433         (char_directive): Change type of *arg_index fields to ssize_t.
21434         (char_directives): Change type of fields 'count', max_*_length to
21435         size_t.
21436         * lib/printf-parse.c: Include sys/types.h and xsize.h.
21437         (SSIZE_MAX): Define fallback value.
21438         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
21439         instead of 'int' where appropriate. Check a_allocated, d_allocated
21440         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
21441         * lib/vasnprintf.c: Include xsize.h.
21442         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
21443         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
21444         overflow. Avoid wraparound when converting a width or precision from
21445         decimal to binary.
21446
21447 2003-11-16  Bruno Haible  <bruno@clisp.org>
21448
21449         Update from GNU gettext.
21450         * lib/printf-parse.c: Generalize to it can be compiled for wide
21451         strings.
21452         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
21453         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
21454         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
21455         SNPRINTF): New macros.
21456         Don't include <alloca.h> if the file is used inside libintl.
21457         (local_wcslen): New function, for Solaris 2.5.1.
21458         (VASNPRINTF): Use it instead of wcslen.
21459
21460 2003-11-16  Bruno Haible  <bruno@clisp.org>
21461
21462         * lib/xsize.h (xmax): New function.
21463         (xsum, xsum3, xsum4): Declare as "pure" functions.
21464
21465 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21466
21467         * modules/xalloc (Files): Undo latest change, since xalloc.h
21468         no longer needs SIZE_MAX or PTRDIFF_MAX.
21469
21470 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21471
21472         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
21473         gl_PTRDIFF_MAX.
21474
21475 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21476
21477         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
21478         "return", to pacify some unknown compiler.  Problem reported
21479         by Joerg Schilling.
21480
21481 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21482
21483         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
21484         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
21485         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
21486         heuristic is just as accurate as far as we know, and it removes a
21487         dependency on size_max.m4 and ptrdiff_max.m4.
21488
21489 2003-11-11  Bruno Haible  <bruno@clisp.org>
21490
21491         * modules/xsize (Files): Add m4/size_max.m4.
21492         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
21493
21494 2003-11-11  Bruno Haible  <bruno@clisp.org>
21495
21496         * m4/size_max.m4: New file.
21497         * m4/ptrdiff_max.m4: New file.
21498         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
21499         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
21500         (gl_XALLOC): Invoke it.
21501
21502 2003-11-11  Bruno Haible  <bruno@clisp.org>
21503
21504         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
21505         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
21506         defined.
21507
21508 2003-11-10  Paul Eggert  <eggert@twinsun.com>
21509
21510         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
21511         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
21512         rejected some allocations of exactly SIZE_MAX - 2 bytes.
21513         From Bruno Haible.
21514         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
21515         not (size_t) -1, since it's defined here.
21516
21517 2003-11-09  Karl Berry  <karl@gnu.org>
21518
21519         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
21520
21521 2003-11-06  Paul Eggert  <eggert@twinsun.com>
21522
21523         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
21524         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
21525         Reject sizes of exactly SIZE_MAX bytes.
21526         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
21527         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
21528
21529 2003-11-05  Bruno Haible  <bruno@clisp.org>
21530
21531         * lib/xsize.h: Include limits.h, to avoid a possible collision with
21532         SIZE_MAX defined in <limits.h> on Solaris.
21533
21534 2003-11-04  Jim Meyering  <jim@meyering.net>
21535
21536         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
21537         variable names, rather than @VAR@.
21538         * modules/poll: Likewise.
21539
21540 2003-11-04  Bruno Haible  <bruno@clisp.org>
21541
21542         * modules/xsize: New file.
21543         * modules/linebreak: Depend on xsize.
21544         * MODULES.html.sh (func_all_modules): Add xsize.
21545
21546 2003-11-04  Bruno Haible  <bruno@clisp.org>
21547
21548         * m4/xsize.m4: New file.
21549
21550 2003-11-04  Bruno Haible  <bruno@clisp.org>
21551
21552         * lib/xsize.h: New file.
21553         * lib/linebreak.c: Include xsize.h.
21554         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
21555         argument for overflow.
21556         Suggested by Paul Eggert.
21557
21558 2003-11-03  Karl Berry  <karl@gnu.org>
21559
21560         * config/config.{guess,sub}: update from config.
21561
21562 2003-11-03  Jim Meyering  <jim@meyering.net>
21563
21564         * modules/userspec (lib_SOURCES): Add userspec.h.
21565         (Include): Add "userspec.h".
21566         Improve description.
21567
21568 2003-11-03  Jim Meyering  <jim@meyering.net>
21569
21570         * lib/userspec.c: Include "userspec.h".
21571         * lib/userspec.h: New file.
21572
21573 2003-11-03  Bruno Haible  <bruno@clisp.org>
21574
21575         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
21576
21577 2003-11-03  Bruno Haible  <bruno@clisp.org>
21578
21579         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
21580         available, to avoid (extremely rare) race condition.
21581         Suggested by Paul Eggert.
21582
21583 2003-11-02  Karl Berry  <karl@gnu.org>
21584
21585         * config/srclist.txt (vasprintf.c): sync broken, sigh.
21586
21587 2003-10-31  Paul Eggert  <eggert@twinsun.com>
21588
21589         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
21590         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
21591         (read_filesystem_list): Set and use me_type_malloced.
21592         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
21593         whatever the type happens to be), for brevity and consistency.
21594         Check for size calculation overflow on Alphas running OSF/1.
21595
21596 2003-10-31  Jim Meyering  <jim@meyering.net>
21597
21598         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
21599
21600         * lib/linebuffer.c: Include <string.h> for declaration of memset.
21601
21602 2003-10-30  Paul Eggert  <eggert@twinsun.com>
21603             Bruno Haible  <bruno@clisp.org>
21604
21605         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
21606         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
21607
21608 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
21609
21610         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
21611         netbsd*-gnu*.  Suggested by Robert Millan.
21612
21613 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21614
21615         * modules/group-member: Depend on stdbool.
21616
21617 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21618
21619         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
21620
21621 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21622
21623         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
21624         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
21625         after the 'gnu' in these cases.  This fixes some bugs in the
21626         previous change, and is based on suggestions by Robert Millan.
21627
21628 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21629
21630         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
21631         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
21632         no longer needed.
21633         * lib/quotearg.c (quotearg_n_options): Use it.
21634         * lib/group-member.c: Include <stdbool.h>.
21635         (free_group_info): Arg is now const *; don't free arg.
21636         (get_group_info): Now returns bool and accepts struct group_info *,
21637         rather than returning a malloc'ed struct group_info *.
21638         All uses changed.  Check for overflow in internal size calculation.
21639
21640         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
21641         rather than xmalloc/xrealloc.
21642         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
21643         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
21644         conformance bug: the old code used a pointer after freeing the
21645         storage that it addressed.
21646         * lib/hash.c (hash_initialize): Simplify the code by using
21647         xalloc_oversized rather than doing it by hand.
21648         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
21649         the buffer preserved.  Use free and xmalloc instead.
21650         * lib/quotearg.c (quotearg_n_options): Likewise.
21651         Use a simpler test for size overflow.  Don't use xalloc_oversized
21652         because unsigned int might be wider than size_t (!); this suggests
21653         that we should switch from unsigned int to size_t for slot numbers.
21654
21655 2003-10-28  Paul Eggert  <eggert@twinsun.com>
21656
21657         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
21658         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
21659         NetBSD kernels.  Requested by Richard Stallman.
21660
21661 2003-10-27  Paul Eggert  <eggert@twinsun.com>
21662
21663         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
21664         to allocate the returned structure.  Do not allocate a subarray,
21665         as x2nrealloc will do that.
21666         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
21667         instead of xnrealloc.
21668         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
21669
21670 2003-10-27  Bruno Haible  <bruno@clisp.org>
21671
21672         * lib/stdbool_.h: Better support for BeOS.
21673
21674 2003-10-26  Paul Eggert  <eggert@twinsun.com>
21675
21676         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
21677         now uses inline.
21678
21679 2003-10-26  Paul Eggert  <eggert@twinsun.com>
21680
21681         * lib/xalloc.h (xalloc_oversized): New static inline function, for
21682         callers that want to do their own size-overflow checking.  Include
21683         <stdbool.h>, since xalloc_oversized returns bool.
21684         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
21685         to use xalloc_oversized.
21686
21687         Add two functions x2realloc, x2nrealloc, for programs that grow
21688         arrays dynamically by doubling their sizes.
21689         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
21690         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
21691         New functions.
21692
21693         Port to C99 semantics for 'inline' of external functions.
21694         Bug reported by Bruno Haible.
21695         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
21696         with the old contents of xnmalloc.
21697         (xnmalloc, xmalloc): Use it.
21698         (xnrealloc_inline): New static inline function,
21699         with the old contents of xnrealloc.
21700         (xnrealloc, xrealloc): Use it.
21701
21702         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
21703         that.
21704
21705 2003-10-26  Karl Berry  <karl@gnu.org>
21706
21707         * config/srclist.txt (COPYING.DOC): no longer available from
21708         /gd/gnuorg; don't know where the ultimate source is.
21709
21710 2003-10-25  Paul Eggert  <eggert@twinsun.com>
21711
21712         Fix several address-calculation bugs in the hash modules,
21713         plus some minor code cleanup.
21714
21715         * lib/hash.h: Include <stdbool.h>, for bool.
21716         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
21717         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
21718         hash_get_n_entries, hash_get_max_bucket_length,
21719         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
21720         hash_rehash): Use size_t rather than unsigned.
21721         * lib/hash.c (struct hash_table, hash_get_n_buckets,
21722         hash_get_n_buckets_used, hash_get_n_entries,
21723         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
21724         hash_get_entries, hash_do_for_each, hash_string, is_prime,
21725         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
21726         Likewise.
21727         (SIZE_MAX): Define if not defined.
21728         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
21729         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
21730         hash_print):
21731         Use const * when possible.
21732         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
21733         (check_tuning): Fix bug: if tuning parameters were very close to
21734         0 or 1, rounding errors could have caused subscript violations.
21735         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
21736         (hash_initialize): Add 'fail:' label
21737         to free table and return NULL, and use it to simplify code.
21738         Use calloc rather than clearing the storage ourself.
21739         (hash_initialize, hash_rehash): Check for arithmetic overflow in
21740         buffer size calculations.
21741         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
21742         Include <stddef.h>, for size_t.
21743         * lib/hash-pjw.c (hash_pjw): Likewise.
21744         Switch to method described by Bruno Haible.
21745         Include <limits.h>, for CHAR_BIT.
21746         (SIZE_BITS): New macro.
21747
21748 2003-10-23  Paul Eggert  <eggert@twinsun.com>
21749
21750         * m4/getline.m4 (AM_FUNC_GETLINE):
21751         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
21752         hosts.  Problem reported by Derek Robert Price in
21753         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
21754         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
21755         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
21756
21757 2003-10-21  Paul Eggert  <eggert@twinsun.com>
21758
21759         * lib/getndelim2.c (getndelim2): When size calculation overflows,
21760         ceiling the allocation at NMAX bytes rather than silently
21761         discarding input bytes before NMAX is reached.  This makes
21762         a difference only if NMAX exceeds SIZE_MAX / 2.
21763
21764         * lib/obstack.c: Merge from glibc.
21765         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
21766         Add libc_hidden_def (_obstack_newchunk).
21767         (_obstack_free) [! defined _LIBC]: Remove.
21768         [defined _LIBC]: Make a strong alias from obstack_free, rather than
21769         a clone of the function body.
21770         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
21771         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
21772
21773         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
21774         glibc.
21775         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
21776         arg to memcpy.
21777
21778         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
21779         (obstack_ptr_grow_fast, obstack_int_grow_fast):
21780         Don't use lvalue casts, as GCC plans to remove support for them
21781         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
21782         was also present in the non-GCC version, indicating that this
21783         code had always been buggy and had never been widely used.
21784         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
21785         Use the fast variant of each macro, rather than copying the
21786         definiens of the fast variant; that way, we'll be more likely to
21787         catch future bugs in the fast variants.
21788
21789 2003-10-20  Bruno Haible  <bruno@clisp.org>
21790
21791         * modules/wait-process: New file.
21792         * MODULES.html.sh (func_all_modules): Add wait-process.
21793
21794 2003-10-20  Bruno Haible  <bruno@clisp.org>
21795
21796         * m4/wait-process.m4: New file.
21797
21798 2003-10-20  Bruno Haible  <bruno@clisp.org>
21799
21800         * lib/wait-process.h: New file, from GNU gettext.
21801         * lib/wait-process.c: New file, from GNU gettext.
21802
21803 2003-10-19  Jim Meyering  <jim@meyering.net>
21804
21805         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
21806         HPUX 10.20.
21807
21808 2003-10-18  Karl Berry  <karl@gnu.org>
21809
21810         * config/config.guess: update from config.
21811
21812 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21813
21814         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
21815         (getgroups): First arg is int, not size_t.
21816         Don't let 'free' mangle errno.
21817
21818 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21819
21820         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
21821
21822 2003-10-16  Karl Berry  <karl@gnu.org>
21823
21824         * config/config.{guess,sub}: update from config.
21825
21826 2003-10-16  Jim Meyering  <jim@meyering.net>
21827
21828         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
21829         memcpy.
21830
21831 2003-10-15  Paul Eggert  <eggert@twinsun.com>
21832
21833         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
21834         (SIZE_MAX): Remove.
21835         (new_exclude, add_exclude_file): Initial size no longer needs to
21836         be a power of 2.
21837         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
21838         our own address arithmetic overflow checking.
21839
21840         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
21841         (fnmatch): Do not alloca more than 2000 wide characters;
21842         instead, use malloc for large buffers.
21843         Check for address arithmetic overflow, and return -1
21844         with errno set to ENOMEM in that case.
21845         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
21846         (NEW_PATTERN): Do not alloca more than 8000 bytes;
21847         instead, return -1.  Check for address arithmetic overflow.
21848
21849 2003-10-14  Paul Eggert  <eggert@twinsun.com>
21850
21851         Handle invalid suffixes and overflow independently, so that
21852         callers can treat them independently as needed.  Fix some bugs in
21853         suffix handling, e.g., "100k@" was not diagnosed as an invalid
21854         suffix for a human-readable blocksize.  The major caller-visible
21855         change is the addition of a new
21856         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
21857         that both overflow and suffix chars were found.
21858
21859         * lib/human.c (humblock): Don't check separately for invalid suffix
21860         char; that is xstrtoumax's job (now that its bug is fixed).
21861         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
21862         INTMAX_MAX]: New macros.
21863         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
21864         TYPE_MAXIMUM): New macros.
21865         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
21866         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
21867         if overflow occurs, as it's what __strtol does and it's more useful
21868         in practice.
21869         (__xstrtol): If __strtol reports some error other than ERANGE,
21870         reflect it to the caller as LONGINT_INVALID.  If it reports
21871         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
21872         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
21873         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
21874         value.
21875         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
21876         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
21877         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
21878         [defined UINTMAX_MAX]: New macros.
21879
21880 2003-10-14  Bruno Haible  <bruno@clisp.org>
21881
21882         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
21883
21884 2003-10-14  Bruno Haible  <bruno@clisp.org>
21885
21886         * m4/sig_atomic_t: New file, from GNU gettext.
21887         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
21888
21889 2003-10-14  Bruno Haible  <bruno@clisp.org>
21890
21891         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
21892         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
21893         Also use volatile where needed.
21894
21895 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21896
21897         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
21898         Change maintainer from Bruno Haible to 'all'.
21899
21900 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21901
21902         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
21903
21904 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21905
21906         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
21907         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
21908         and define in terms of the other primitives.
21909         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
21910         (SIZE_MAX): Define if not already defined.
21911         (array_size_overflow): New function.
21912         (xalloc_die): Abort instead of exiting if 'error' returns.
21913         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
21914         (xmalloc, xrealloc): Use them.
21915         (xcalloc): Check for address arithmetic overflow.
21916         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
21917         a bit faster than strcpy.
21918
21919 2003-10-10  Simon Josefsson  <jas@extundo.com>
21920
21921         * modules/argp (Depends-on): Add restrict and strcase.
21922
21923 2003-10-10  Simon Josefsson  <jas@extundo.com>
21924
21925         * m4/argp.m4: Add AC_C_INLINE.
21926
21927 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21928
21929         Merge getpass from libc, plus a few fixes.
21930
21931         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
21932         Include <stdbool.h>.
21933         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
21934         __fsetlocking to empty.
21935         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
21936         do include <bits/libc-lock.h>.
21937         Do not include <fcntl.h>; not needed.
21938         [_LIBC]: Include <wchar.h>.
21939         (NOTCANCEL_MODE): New macro.
21940         (flockfile, funlockfile) [_LIBC]: New macros.
21941         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
21942         [!_LIBC]: New macros.
21943         (call_fclose): New function.
21944         (getpass): Use it.  Save tty stream separately; this simplifies the
21945         code and makes it more reliable if stdin happens to equal stdout.
21946         Invoke __fsetlocking on tty.
21947         Handle thread cancellation if needed.
21948         Namespace cleanup (use __tcgetattr, __getline).
21949         Use bool for Booleans.
21950         [USE_IN_LIBIO]: Handle wide streams.
21951         [!_LIBC]: Unconditionally do the fseek, since we don't know what
21952         stream might go where.
21953
21954         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
21955         doesn't have to include <stdio.h> before us.
21956         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
21957         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
21958         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
21959         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
21960         if not declared, so that we can use getpass.c code from libc without
21961         rewriting it.
21962         (flockfile, ftrylockfile, funlockfile): New macros.
21963
21964 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21965
21966         * modules/getpass: Depend on stdbool.
21967
21968 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21969
21970         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
21971
21972 2003-10-07  Karl Berry  <karl@gnu.org>
21973
21974         * config/config.{guess,sub}: update from config.
21975
21976 2003-10-06  Jim Meyering  <jim@meyering.net>
21977             Bruno Haible  <bruno@clisp.org>
21978
21979         This lets translators provide better translations for the
21980         "Written by ..." part of --version output.
21981         * lib/version-etc.h: Include stdarg.h.
21982         (version_etc_copyright): Declare as readonly.
21983         (version_etc): Make this function variadic with a NULL-terminated list
21984         of author name strings.
21985         (version_etc_va): New declaration.
21986         * lib/version-etc.c: Include stdarg.h, stdlib.h.
21987         (version_etc_copyright): Declare as readonly.
21988         (version_etc_va): New function. Provide a different translatable string
21989         for each possible number of authors < 10. Abbreviate when there are 10
21990         authors or more.
21991         (version_etc): Make this function variadic. Call version_etc_va.
21992         Suggestion from Gary V. Vaughan.
21993
21994         * lib/long-options.h (parse_long_options): Change prototype: the
21995         authors string is moved to the end and becomes variadic.
21996         * lib/long-options.c: Include stdarg.h.
21997         (parse_long_options): Make this function variadic, too.
21998         Call version_etc_va, not version_etc.
21999
22000 2003-10-06  Bruno Haible  <bruno@clisp.org>
22001
22002         * modules/version-etc-2: Remove file.
22003         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
22004
22005 2003-10-06  Bruno Haible  <bruno@clisp.org>
22006
22007         * modules/fatal-signal: New file.
22008         * MODULES.html.sh (func_all_modules): Add fatal-signal.
22009
22010 2003-10-06  Bruno Haible  <bruno@clisp.org>
22011
22012         * m4/fatal-signal.m4: New file.
22013         * m4/signalblocking.m4: New file, from GNU gettext.
22014
22015 2003-10-06  Bruno Haible  <bruno@clisp.org>
22016
22017         * lib/version-etc-2.h: Remove file.
22018         * lib/version-etc-2.c: Remove file.
22019
22020 2003-10-06  Bruno Haible  <bruno@clisp.org>
22021
22022         * lib/fatal-signal.h: New file, from GNU gettext.
22023         * lib/fatal-signal.c: New file, from GNU gettext.
22024
22025 2003-10-05  Paul Eggert  <eggert@twinsun.com>
22026
22027         * README: Rework advice for preventing empty .o files.
22028         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
22029         not <sys/types.h>.
22030
22031 2003-10-04  Karl Berry  <karl@gnu.org>
22032
22033         * lib/argp*: update from libc.
22034
22035 2003-10-04  Karl Berry  <karl@gnu.org>
22036
22037         * config/config.{guess,sub}: update from config.
22038
22039 2003-10-02  Bruno Haible  <bruno@clisp.org>
22040
22041         * modules/lchown (Include): Add lchown.h.
22042         * modules/time_r (Include): Use "..." syntax.
22043         * modules/xgetdomainname (Include): Add xgetdomainname.h.
22044
22045 2003-10-01  Simon Josefsson  <jas@extundo.com>
22046
22047         * MODULES.html.sh (func_all_modules): Move gethostname from section
22048         'based on' to section 'lacking' POSIX:2001.
22049
22050 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
22051
22052         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
22053         to output mode on the same stream.
22054
22055 2003-09-29  Paul Eggert  <eggert@twinsun.com>
22056
22057         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
22058         Fix arg typo in previous patch.
22059
22060 2003-09-28  Jim Meyering  <jim@meyering.net>
22061
22062         * lib/error.c: Correct cpp indentation.
22063
22064 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22065
22066         * modules/free: New file.
22067
22068 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22069
22070         * m4/free.m4: New file.
22071
22072 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22073
22074         * lib/minmax.h (MIN, MAX)
22075         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
22076         Omit the special code that used __typeof__, since we worry that
22077         it could be more trouble than it's worth.  See:
22078         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
22079         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
22080
22081         * lib/free.c: New file.
22082
22083 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
22084
22085         Trivial fixes to Makefile.am parts of module listings.
22086         * modules/strstr: Append strstr.h to lib_SOURCES.
22087         * modules/strcase: Likewise, for strcase.h.
22088
22089 2003-09-27  Karl Berry  <karl@gnu.org>
22090
22091         * config/mkinstalldirs: update from automake.
22092
22093 2003-09-26  Paul Eggert  <eggert@twinsun.com>
22094
22095         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
22096         (error_tail): Do not loop, reallocating temporary buffer, since
22097         the output cannot contain more wide characters than the input
22098         contains bytes, the size must be big enough already.  This avoids
22099         one potential size overflow calculation.  Check for size overflow
22100         when calculating temporary buffer size.  Free temporary buffer
22101         when done, if it was allocated with malloc; this plugs a memory
22102         leak.  Remove casts from void * to pointers, that are no longer
22103         needed now that we're assuming C89 or better.
22104
22105         Merge error changes from glibc.
22106
22107         * lib/error.c, error.h: Update copyright notice header to match glibc.
22108         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
22109         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
22110         Disable cancellation while printing error.
22111         * lib/error.h: Prepend __ to parameter names.
22112
22113 2003-09-26  Jim Meyering  <jim@meyering.net>
22114
22115         * lib/error.c (error_tail): Move some declarations
22116         into inner scope where the local variables are used.
22117
22118 2003-09-26  Bruno Haible  <bruno@clisp.org>
22119
22120         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
22121         stpncpy().
22122         Don't define stpncpy through config.h; it's now done through stpncpy.h.
22123
22124 2003-09-26  Bruno Haible  <bruno@clisp.org>
22125
22126         * lib/stpncpy.h (gnu_stpncpy): New declaration.
22127         (stpncpy): Define as alias for gnu_stpncpy.
22128         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
22129
22130 2003-09-25  Simon Josefsson  <jas@extundo.com>
22131
22132         * lib/xgetdomainname.h: New file.
22133         * lib/xgetdomainname.c: New file.
22134
22135 2003-09-25  Simon Josefsson  <jas@extundo.com>
22136             Bruno Haible  <bruno@clisp.org>
22137
22138         * modules/getdomainname: New file.
22139         * modules/xgetdomainname: New file.
22140         * MODULES.html.sh (func_all_modules): Add getdomainname,
22141         xgetdomainname.
22142
22143 2003-09-25  Simon Josefsson  <jas@extundo.com>
22144             Bruno Haible  <bruno@clisp.org>
22145
22146         * m4/getdomainname.m4: New file.
22147
22148 2003-09-25  Simon Josefsson  <jas@extundo.com>
22149             Bruno Haible  <bruno@clisp.org>
22150
22151         * lib/getdomainname.h: New file.
22152         * lib/getdomainname.c: New file.
22153
22154 2003-09-25  Karl Berry  <karl@gnu.org>
22155
22156         * lib/argp-fmtstream.c, argp-help.c: update from libc.
22157
22158 2003-09-25  Karl Berry  <karl@gnu.org>
22159
22160         * config/install-sh: update from automake.
22161
22162 2003-09-25  Bruno Haible  <bruno@clisp.org>
22163
22164         * modules/version-etc-2: New file, from modules/version-etc with
22165         modifications.
22166         * MODULES.html.sh (func_all_modules): Add version-etc-2.
22167
22168 2003-09-25  Bruno Haible  <bruno@clisp.org>
22169
22170         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
22171         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
22172
22173 2003-09-24  Simon Josefsson  <jas@extundo.com>
22174
22175         * modules/xgethostname: Add xgethostname.h.
22176
22177 2003-09-24  Paul Eggert  <eggert@twinsun.com>
22178
22179         * lib/linebuffer.c (freebuffer): Don't free the argument, just
22180         the buffer associated with the argument.  Bug reported by
22181         Simon Josefsson.
22182
22183 2003-09-24  Paul Eggert  <eggert@twinsun.com>
22184
22185         * README: Document assumptions that 'int' is at least 32 bits
22186         wide, that integer arithmetic is 2's complement without overflow,
22187         that there are no holes in integer values, that adding sizes of
22188         two nonoverlapping objects can't overflow, and that all-bits-zero
22189         yields scalar zero.  Fix spelling and capitalization typos.
22190
22191 2003-09-19  Karl Berry  <karl@gnu.org>
22192
22193         * lib/argp.h: update from libc.
22194
22195 2003-09-17  Paul Eggert  <eggert@twinsun.com>
22196
22197         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
22198         to avoid spurious warnings like "AC_RUN_IFELSE was called before
22199         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
22200
22201 2003-09-17  Paul Eggert  <eggert@twinsun.com>
22202
22203         * gnulib-tool: Use "test -h", not "test -L", for portability
22204         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
22205         (tags_regexp): Remove, since \| doesn't conform to POSIX.
22206         (sed_extract_prog): Issue s commands one-by-one, rather than
22207         using \| in one s command.
22208
22209 2003-09-16  Paul Eggert  <eggert@twinsun.com>
22210
22211         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
22212         input error, instead of returning NULL the next time we are called
22213         (and therefore losing track of errno).
22214
22215 2003-09-16  Bruno Haible  <bruno@clisp.org>
22216
22217         * gnulib-tool (func_create_testdir): Warn about duplicated
22218         dependencies.
22219
22220 2003-09-15  Paul Eggert  <eggert@twinsun.com>
22221
22222         * modules/argmatch, modules/fatal, modules/obstack,
22223         modules/xalloc, modules/xgethostname: Sort dependencies by
22224         importance, not alphabetically.
22225
22226 2003-09-15  Paul Eggert  <eggert@twinsun.com>
22227
22228         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
22229         fails, so that the caller gets the proper errno.
22230
22231         * lib/readutmp.c (read_utmp): Likewise.
22232         Check for fstat error.  Close stream and free storage
22233         when failing.
22234
22235 2003-09-14  Karl Berry  <karl@gnu.org>
22236
22237         * config/srclist.txt (strdup.c): disable for c89 changes.
22238
22239 2003-09-14  Jim Meyering  <jim@meyering.net>
22240
22241         * lib/getloadavg.c: Correct cpp indentation.
22242         * lib/strdup.c: Likewise.
22243         * lib/vasnprintf.c: Likewise.
22244
22245 2003-09-14  Bruno Haible  <bruno@clisp.org>
22246
22247         * modules/fwriteerror: New file.
22248         * MODULES.html.sh (func_all_modules): Add fwriteerror.
22249
22250 2003-09-14  Bruno Haible  <bruno@clisp.org>
22251
22252         * lib/fwriteerror.h: New file.
22253         * lib/fwriteerror.c: New file.
22254
22255 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22256
22257         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
22258         modules/xgethostname, modules/xalloc: Depend on exit.
22259
22260 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22261
22262         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
22263
22264         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
22265         and AC_MINIX, too, so that their extensions are available.
22266
22267         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
22268         This macro has been superseded by gl_BACKUPFILE.
22269
22270         More patches to assume C89 or better.
22271
22272         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
22273
22274         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
22275         unconditionally.
22276         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
22277         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
22278         Include <string.h>, <stdlib.h> unconditionally.
22279         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
22280         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
22281         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
22282         headers or for string.h.
22283         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
22284         or strtoul.
22285
22286         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
22287         headers.
22288         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
22289         * m4/userspec.m4 (gl_USERSPEC): Likewise.
22290         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
22291         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
22292         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
22293         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
22294         memcpy, memset.
22295         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
22296         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
22297         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
22298         strtol.
22299         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
22300         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
22301         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
22302         strtoul.
22303
22304 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22305
22306         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
22307         * lib/obstack.c [!defined _LIBC]: Likewise.
22308         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
22309         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
22310         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
22311
22312         More changes to assume C89 or better.
22313
22314         * lib/error.c (error_tail): Assume vprintf.
22315
22316         * lib/argmatch.c (getenv): Remove decl.
22317         * lib/progreloc.c (get_full_program_name): Define via prototype.
22318         * lib/setenv.c (clearenv): Likewise.
22319         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
22320         needed.
22321         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
22322         (malloc, memcpy): Remove decls.
22323         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
22324         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
22325         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
22326         (memcpy): Remove macro.
22327         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
22328         (__P): Remove.  All uses removed.
22329         (PTR): Remove.  All uses changed to void *.
22330         (CHAR_BIT, NULL): Remove.
22331         (spaces, zeros, memset_space, memset_zero)
22332         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
22333         Remove.
22334         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
22335         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
22336         Define with prototype.
22337         Remove now-unnecessary prototype decl.
22338         (extra_args_spec): Assume ANSI C.  All uses changed.
22339         (extra_args_spec_iso): Remove.
22340         (my_strftime, emacs_strftimeu): Define via prototype.
22341         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
22342         unconditionally.
22343         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
22344         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
22345         (strtoul, strtol): Remove decls.
22346         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
22347         LONG_MAX): Remove.
22348         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
22349         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
22350         (LOCALE_PARAM_PROTO): New macro.
22351         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
22352         (INTERNAL (strtol), strtol): Define with a prototype.
22353         (PARAMS): Remove.  All uses removed.
22354         * lib/tempname.c: Include <string.h> unconditionally.
22355         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
22356         * lib/xgethostname.c (main): Define with a prototype.
22357         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
22358         Include <stdlib.h> unconditionally.
22359         (calloc, malloc, realloc, free): Remove decls.
22360         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
22361         Include <stdlib.h> unconditionally.  Sort include file names.
22362         (strtod): Remove.
22363         (xstrtod): Define with a prototype.
22364         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
22365         (strtol, strtoul): Remove decls.
22366
22367 2003-09-11  Paul Eggert  <eggert@twinsun.com>
22368
22369         More patches to assume C89 or better.
22370         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
22371         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
22372         string.h, memchr, STDC_HEADERS.
22373
22374 2003-09-11  Paul Eggert  <eggert@twinsun.com>
22375
22376         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
22377         Include <stdlib.h>, <string.h> unconditionally.
22378         Remove now-unnecessary cast to char *.
22379         * lib/strnlen.c: Include <string.h> unconditionally.
22380         * lib/yesno.c (yesno): Define with a prototype.
22381
22382 2003-09-11  Bruno Haible  <bruno@clisp.org>
22383
22384         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
22385
22386 2003-09-10  Jim Meyering  <jim@meyering.net>
22387
22388         * lib/error.c: Correct indentation of cpp directives.
22389
22390 2003-09-10  Bruno Haible  <bruno@clisp.org>
22391
22392         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
22393         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
22394         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
22395         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
22396         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
22397         <stdlib.h> and <string.h> checks.
22398         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
22399         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
22400
22401 2003-09-10  Bruno Haible  <bruno@clisp.org>
22402
22403         * lib/strcspn.c: Include <string.h> unconditionally.
22404         * lib/strpbrk.c: Include <string.h> unconditionally.
22405         * lib/strstr.c: Include <string.h> unconditionally.
22406         * lib/unicodeio.c: Include <string.h> unconditionally.
22407         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
22408         * lib/unsetenv.c: Likewise.
22409         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
22410         * lib/yesno.c: Include <stdlib.h> unconditionally.
22411         (rpmatch): Add prototype.
22412
22413 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22414
22415         More patches to assume C89 or better.
22416         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
22417         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
22418         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
22419         or for string.h.
22420         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
22421         stdlib.h.
22422         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
22423         C headers.
22424         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
22425         string.h.
22426         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
22427         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
22428         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
22429         or for string.h.
22430         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
22431         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
22432         C headers.
22433         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
22434         memcpy.
22435         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
22436         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
22437         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
22438         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
22439         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
22440         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
22441         string.h, free.
22442         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
22443         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
22444         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
22445         C headers, or for string.h.
22446         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
22447         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
22448         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
22449         headers, memory.h, stdlib.h, string.h, strings.h.
22450         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
22451         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
22452         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
22453         strchr.
22454         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
22455         headers, memory.h, string.h.
22456         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
22457         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
22458         free.
22459         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
22460         headers.
22461         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
22462         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
22463         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
22464         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
22465         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
22466
22467 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22468
22469         More K&R removal.
22470
22471         * lib/acosl.c (main): Use a prototype.
22472         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
22473         tanl.c: Likewise.
22474
22475         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
22476
22477         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
22478         (getopt, etopt_long, getopt_long_only, _getopt_internal)
22479         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
22480         with a prototype.
22481         * lib/getopt.c (const): Remove macro.
22482         Include <string.h> unconditionally.
22483         (my_index): Remove; all uses changed to strchr.
22484         (strlen): Remove decl.
22485         (exchange): Remove forward decl; no longer needed.
22486         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
22487         Define with prototype.
22488         * lib/getopt1.c (const): Remove macro.
22489         (getopt_long, getopt_long_only, main): Define with prototype.
22490
22491         * lib/getugroups.c: Include <string.h> unconditionally.
22492
22493         * lib/getusershell.c: Include <stdlib.h> unconditionally.
22494         (getusershell, setusershell, endusershell, readname, main):
22495         Define with prototypes.
22496
22497         * lib/group-member.c: Include group-member.h first.
22498         Include <stdlib.h> unconditionally.
22499
22500         * lib/hard-locale.c: Include hard-locale.h first.
22501         Include <stdlib.h>, <string.h> unconditionally.
22502
22503         * lib/hash.c (free, malloc): Remove decls.
22504         Include <stdlib.h> unconditionally.
22505
22506         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
22507         (getenv): Do not declare.
22508
22509         * lib/idcache.c: Include <string.h> unconditionally.
22510
22511         * lib/long-options.c: Include long-options.h first, to test interface.
22512         Include <stdlib.h> unconditionally.
22513
22514         * lib/makepath.c: Include makepath.h first, to test interface.
22515         Include <stdlib.h> and <string.h> unconditionally.
22516
22517         * lib/linebuffer.c: Include <stdlib.h>.
22518         (free): Remove decl.
22519
22520         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
22521         stddef.h. rpl_malloc returns void *, not char *.
22522         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
22523         prototype.
22524
22525         * lib/md5.h: Include <limits.h> unconditionally.
22526         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
22527         (__P): Remove; all uses removed.
22528         * lib/md5.c: Include "md5.h" first.
22529         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
22530         md5_buffer, md5_process_bytes, md5_process_block):
22531         Define with prototypes.
22532         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
22533         * lib/sha.c: Include "sha.h" first.
22534         Include <stdlib.h>, <string.h> unconditionally.
22535
22536         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
22537         * lib/memcmp.c (__ptr_t): Likewise.
22538         * lib/memrchr.c (__ptr_t): Likewise.
22539         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
22540         Include <string.h> unconditionally.
22541         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
22542         * lib/memchr.c: Include <stdlib.h> unconditionally.
22543         * lib/memchr.c (LONG_MAX): Remove.
22544         * lib/memrchr.c (LONG_MAX): Likewise.
22545         * lib/memchr.c (__memchr): Define via a prototype.
22546         * lib/memrchr.c (__memrchr): Likewise.
22547         * lib/memcmp.c (__P): Remove, and remove all uses.
22548         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
22549         Remove forward decls; no longer needed.
22550         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
22551         Use types required by C89 in prototype.
22552
22553         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
22554         * lib/savedir.c: Likewise.
22555         * lib/mkdir.c (free): Remove decl.
22556         * lib/rmdir.c (rmdir): Define with a prototype.
22557         * lib/savedir.c: Include savedir.h first, to test interface.
22558
22559         * lib/mktime.c (STDC_HEADERS): Remove.
22560         Include <stdlib.h>, <string.h> unconditionally.
22561
22562         * lib/modechange.c: Include <stdlib.h> unconditionally.
22563         (malloc): Remove decl.
22564
22565         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
22566         (free): Remove decl.
22567
22568         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
22569         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
22570         (This type really should be intptr_t, but that's a C99ism.)
22571         (_obstack_memcpy): Remove: all uses changed to memcpy.
22572         Include <string.h> unconditionally.
22573         (struct obstack): Assume __STDC__ for types of members
22574         chunkfun, freefun, extra_arg.
22575         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
22576         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
22577         obstack_begin, obstack_specify_allocation,
22578         obstack_specify_allocation_with_arg, obstack_chunkfun,
22579         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
22580         Remove unprototyped decls and the macros that use them.
22581         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
22582         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
22583         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
22584         (defined __STDC__ && __STDC__)]:
22585         Remove nonprototyped code.
22586         Include <stdlib.h> unconditionally.
22587         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
22588         _obstack_allocated_p, _obstack_free, obstack_free,
22589         _obstack_memory_used, print_and_abort):
22590         Define using prototypes.
22591         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
22592         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
22593         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
22594         obstack_next_free, obstack_object_size, obstack_room) [0]:
22595         Remove unused, unprototyped code.
22596
22597         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
22598
22599         * lib/physmem.c (physmem_total, physmem_available, main): Define
22600         with prototypes.
22601
22602         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
22603         (main): Define with a prototype.
22604
22605         * lib/posixver.c (getenv): Remove decl.
22606
22607         * lib/putenv.c (malloc): Returns void *, not char *.
22608         Include <string.h> unconditionally.
22609         (strchr, memcpy, NULL): Do not define.
22610
22611         * lib/readtokens.c: Include readtokens.h first, to test interface.
22612         Include <stdlib.h>, <string.h> unconditionally.
22613         (init_tokenbuffer): Define with a prototype.
22614
22615         * lib/regex.c (PARAMS): Remove.  All uses removed.
22616         All uses of _RE_ARGS removed, too.
22617         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
22618         unconditionally.
22619         (bzero): Assume memset exists.
22620         (memcmp, memcpy, NULL): Remove.
22621         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
22622         char, or assignments to local vars of type signed char.
22623         (init_syntax_once, PREFIX(extract_number_and_incr),
22624         PREFIX(print_partial_compiled_pattern),
22625         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
22626         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
22627         PREFIX(regex_grow_registers), PREFIX(regex_compile),
22628         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
22629         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
22630         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
22631         wcs_compile_range, byte_compile_range, truncate_wchar,
22632         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
22633         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
22634         count_mbs_length, wcs_re_match_2_internal,
22635         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
22636         PREFIX(alt_match_null_string_p),
22637         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
22638         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
22639         regfree, PREFIX(extract_number)): Define with prototype.  Remove
22640         now-unnecessary declaration, if any.
22641         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
22642         regcomp, regexec):
22643         Remove now-unnecessary casts among pointer types.
22644         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
22645
22646         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
22647         (free): Remove decl.
22648
22649         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
22650
22651         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
22652         (free): Remove decl.
22653
22654         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
22655         * lib/xgetcwd.c: Likewise.
22656
22657         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
22658         (free): Remove decl.
22659
22660         * lib/strchrnul.c (strchrnul): Define with a prototype.
22661         Fix bug: c_in was not converted to char before searching.
22662
22663         The following changes are not K&R related:
22664
22665         * lib/group-member.h: Include <sys/types.h>, so that this file is
22666         self-contained.
22667         * lib/makepath.h: Likewise.
22668
22669         * lib/getusershell.c (readname, default_index, line_size, readname):
22670         Use size_t, not int, for sizes.
22671         (readname): If the size overflows, report an error instead of
22672         looping forever.
22673
22674 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22675
22676         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
22677         libc.
22678
22679 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22680
22681         * README: New section: portability guidelines.
22682
22683 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
22684
22685         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
22686         C89 spec.
22687
22688 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
22689
22690         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
22691
22692 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22693
22694         Assume C89 or better; remove K&R cruft.
22695         A few of these changes were first proposed by Derek Robert Price
22696         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
22697
22698         * lib/addext.c: Include <string.h> unconditionally.
22699         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
22700         Don't declare getenv or malloc.
22701
22702         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
22703         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
22704         (NULL): Remove.
22705         (find_stack_direction, alloca): Use prototypes.
22706
22707         * lib/atexit.c (atexit): Define using a prototype.
22708
22709         * lib/basename.c, dirname.c, stripslash.c:
22710         Include <string.h> unconditionally.
22711
22712         * lib/bcopy.c: Include <stddef.h>.
22713         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
22714
22715         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
22716
22717         * lib/error.h (error, error_at_line, error_print_progname)
22718         [! (defined (__STDC__) && __STDC__)]: Remove decls.
22719         * lib/error.c: Include error.h first, to check interface.
22720         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
22721         (VA_START): Remove; all uses changeed to va_start.
22722         (exit, strerror): Remove decls.
22723         (error_print_progname): Prototype uncondionally.
22724         Don't include <errno.h>; no longer needed.
22725         (private_strerror): Remove.
22726         (error_tail): Always define.
22727         (error, error_at_line): Assume C89 or better; always use prototypes.
22728         * lib/fatal.c: Include "fatal.h" first, to test interface.
22729         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
22730         (VA_START): Remove; all uses changed to va_start.
22731         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
22732         this case.
22733         (exit): Remove decl.
22734         (fatal): Prototype unconditionally.  Assume va_start works.
22735         Abort at end, to pacify gcc.
22736
22737         * lib/euidaccess.c (main): Define with a prototype.
22738
22739         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
22740
22741         * lib/exitfail.c: Include <stdlib.h> unconditionally.
22742
22743         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
22744         prototypes.
22745         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
22746         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
22747         (getenv): Remove decl.
22748         (fnmatch): Define using a prototype.
22749         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
22750         (FCT): Define using a prototype.
22751
22752         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
22753
22754         * lib/gethostname.c: Include <stddef.h>.
22755         (gethostname): Define with prototype.  Length is size_t, not int.
22756
22757 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22758
22759         Assume C89 or better; remove K&R cruft.
22760         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
22761         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
22762         string.h, getenv, malloc.
22763         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
22764         headers.
22765         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
22766         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
22767         do not check for strerror.
22768         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
22769         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
22770         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
22771         do not check for doprnt or vprintf.
22772         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
22773         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
22774
22775 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22776
22777         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
22778         getversion.c should have been removed then, but was accidentally
22779         preserved.
22780
22781         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
22782         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
22783
22784 2003-09-08  Karl Berry  <karl@gnu.org>
22785
22786         * config/config.sub, config.guess, srclistvars.sh: update from savannah
22787                 config, forget about prep.
22788
22789         * config/depcomp, missing: update from automake.
22790
22791 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22792
22793         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
22794         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22795
22796 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22797
22798         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
22799         copy_tm_result.  Bug reported by Simon Josefsson in
22800         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22801
22802 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22803
22804         * m4/time_r.m4: New file.
22805         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
22806         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
22807         is. Check for timegm declaration.
22808         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
22809         Do not check for gmtime_r.
22810         Replace mktime if __mktime_internal does not exist and if mktime
22811         hasn't been replaced already.
22812
22813 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22814
22815         * lib/time_r.c, lib/time_r.h: New files.
22816
22817         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
22818         __localtime_r.
22819         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
22820         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
22821
22822         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
22823         __gmtime_r.
22824         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
22825         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
22826         Include <time_r.h>.
22827
22828         * lib/timegm.c: Switch to glibc implementation, with the following
22829         changes:
22830         [defined HAVE_CONFIG_H]: Include <config.h>.
22831         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
22832         (__mktime_internal) [!defined _LIBC]: New decl.
22833         (__gmtime_r) [!defined _LIBC]: New macro and function.
22834         (timegm): Use a prototype, since gnulib assumes C89.
22835         Do not bother declaring tmp to be const, as it's not really usefu.
22836         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
22837         (timegm): Declare only if HAVE_DECL_TIMEGM.
22838
22839 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22840
22841         * MODULES.html.sh (func_all_modules): Add time_r.
22842         * modules/time_r: New file.
22843         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
22844         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
22845
22846 2003-09-03  Paul Eggert  <eggert@twinsun.com>
22847
22848         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
22849         Bug reported by Lute Kamstra in
22850         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
22851
22852         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
22853         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
22854         course with correspondingly smaller numbers for tomorrow and
22855         yesterday.  From Tadayoshi Funaba.  Originally installed into
22856         sh-utils on 1999-08-07, but the patch got lost (I guess during the
22857         coreutils merge?).
22858
22859 2003-08-31  Simon Josefsson  <jas@extundo.com>
22860
22861         * modules/timegm: New file.
22862         * MODULES.html.sh (func_all_modules): Add timegm.
22863
22864 2003-08-31  Simon Josefsson  <jas@extundo.com>
22865
22866         * m4/timegm.m4: New file.
22867
22868 2003-08-31  Simon Josefsson  <jas@extundo.com>
22869
22870         * lib/timegm.h: New file.
22871         * lib/timegm.c: New file.  Based on
22872         wget-1.8.2/src/http.c:mktime_from_utc.
22873
22874 2003-08-31  Karl Berry  <karl@gnu.org>
22875
22876         * lib/argp.h: update from libc.
22877
22878 2003-08-28  Bruno Haible  <bruno@clisp.org>
22879
22880         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
22881         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
22882         followed by '#define fnmatch fnmatch_posix' gives an error.
22883
22884 2003-08-28  Bruno Haible  <bruno@clisp.org>
22885
22886         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
22887         warning on QNX, which defines O_BINARY to 000000.
22888
22889 2003-08-27  Jim Meyering  <jim@meyering.net>
22890
22891         * m4/mkstemp.m4: Require that the system mkstemp be able to create
22892         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
22893         would fail after 32.  Reported by Danny Levinson.  Details here:
22894         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
22895
22896 2003-08-24  Bruno Haible  <bruno@clisp.org>
22897
22898         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
22899         MSVC7 <stdio.h> is included later.
22900
22901 2003-08-22  Simon Josefsson  <jas@extundo.com>
22902
22903         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
22904
22905 2003-08-20  Karl Berry  <karl@gnu.org>
22906
22907         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
22908
22909 2003-08-20  Bruno Haible  <bruno@clisp.org>
22910
22911         * modules/progname: New file.
22912         * MODULES.html.sh (func_all_modules): Add progname.
22913
22914 2003-08-20  Bruno Haible  <bruno@clisp.org>
22915
22916         * lib/progname.h: New file, from GNU gettext.
22917         * lib/progname.c: New file, from GNU gettext.
22918         * lib/progreloc.c: New file, from GNU gettext.
22919
22920 2003-08-19  Jim Meyering  <jim@meyering.net>
22921
22922         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
22923         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
22924
22925 2003-08-19  Bruno Haible  <bruno@clisp.org>
22926
22927         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
22928         more.
22929
22930 2003-08-19  Bruno Haible  <bruno@clisp.org>
22931
22932         * lib/xstrdup.c: Assume <string.h> exists.
22933
22934 2003-08-18  Paul Eggert  <eggert@twinsun.com>
22935
22936         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
22937         in makefile rules.
22938
22939 2003-08-18  Jim Meyering  <jim@meyering.net>
22940
22941         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
22942         * m4/lib-ld.m4: Likewise.
22943
22944 2003-08-18  Jim Meyering  <jim@meyering.net>
22945
22946         * lib/setenv.h: Indent nested cpp directive.
22947         * lib/vasnprintf.c: Remove trailing blanks.
22948
22949 2003-08-17  Simon Josefsson  <jas@extundo.com>
22950
22951         * modules/xstrndup: New file.
22952         * MODULES.html.sh (func_all_modules): Add xstrndup.
22953
22954 2003-08-17  Simon Josefsson  <jas@extundo.com>
22955
22956         * modules/argp: Fix autoconf macro name. Add more dependencies.
22957
22958 2003-08-17  Simon Josefsson  <jas@extundo.com>
22959
22960         * m4/xstrndup.m4: New file.
22961
22962 2003-08-17  Simon Josefsson  <jas@extundo.com>
22963
22964         * m4/argp.m4: New file.
22965
22966 2003-08-17  Simon Josefsson  <jas@extundo.com>
22967             Bruno Haible  <bruno@clisp.org>
22968
22969         * lib/xstrndup.h: New file.
22970         * lib/xstrndup.c: New file.
22971
22972 2003-08-17  Bruno Haible  <bruno@clisp.org>
22973
22974         * modules/strndup (Files, Include): Add lib/strndup.h.
22975
22976 2003-08-17  Bruno Haible  <bruno@clisp.org>
22977
22978         * modules/euidaccess (Files): Add lib/euidaccess.h.
22979
22980 2003-08-17  Bruno Haible  <bruno@clisp.org>
22981
22982         * lib/strndup.h: New file.
22983
22984 2003-08-17  Bruno Haible  <bruno@clisp.org>
22985
22986         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
22987         like AC_GNU_SOURCE.
22988         * modules/extensions (configure.ac): Comment out the invocation of
22989         gl_USE_SYSTEM_EXTENSIONS.
22990
22991 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22992
22993         Merges from coreutils, etc.
22994         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
22995         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
22996         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
22997         fixing a typo.
22998         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
22999         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
23000
23001 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23002
23003         Document merge from coreutils.
23004         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
23005         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
23006         * modules/utime: Add m4/utimes-null.m4.
23007
23008 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23009
23010         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
23011         space, undoing this 2003-08-12 change:
23012         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
23013
23014 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23015
23016         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
23017         strtoul.c from libc, undoing this 2003-08-12 change:
23018         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
23019
23020 2003-08-16  Jim Meyering  <jim@meyering.net>
23021
23022         Merges from coreutils.
23023         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
23024         prefix.  Adjust cache variables similarly.  Create 500 rather than
23025         just 300 files, to exercise bug on Darwin6.5, too.
23026         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
23027         $missing_dir.
23028         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
23029         AM_SYS_POSIX_TERMIOS.
23030         Reported by mkc@mathdogs.com.
23031         Also change use of $am_cv_sys_posix_termios
23032         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
23033         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
23034         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
23035         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
23036         in /proc/mounts until it finds one with matching device number.  This
23037         is unnecessary when the FILE argument *is* a mount point.  No stat call
23038         is necessary in that case.  So, disable the statvfs-testing code on
23039         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
23040         as RedHat bug# 84846.
23041         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
23042         to 1MB, so as not to render systems with no stack size limit (e.g.,
23043         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
23044         Include <unistd.h>.  On some systems,
23045         it is required for the definition of _SC_PAGESIZE.
23046
23047 2003-08-16  Jim Meyering  <jim@meyering.net>
23048
23049         Merge from coreutils.
23050         * lib/xstrtoimax.c: #else #if -> #elif.
23051         * lib/xstrtoumax.c: Likewise.
23052
23053 2003-08-16  Jim Meyering  <jim@meyering.net>
23054
23055         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
23056         * m4/utimes.m4: Removed.
23057         * m4/utimes-null.m4: Renamed from utimes.m4.
23058
23059         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
23060         to 1MB, so as not to render systems with no stack size limit (e.g.,
23061         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
23062         Include <unistd.h>.  On some systems,
23063         it is required for the definition of _SC_PAGESIZE.
23064
23065 2003-08-16  Jim Meyering  <jim@meyering.net>
23066         and Paul Eggert  <eggert@cs.ucla.edu>
23067
23068         Merges from coreutils, etc.
23069
23070         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
23071         using the latest version from cvs.  This avoids problems with #line
23072         directives using a vendor (Sun) compiler.
23073         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
23074         Don't set GETGROUPS_LIB here; now it's
23075         done via getgroups.m4's wrapper function.
23076         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
23077         rather than just in sh-util/configure.in, so that the
23078         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
23079         same.
23080         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
23081         AC_FUNC_GETLOADAVG where to find getloadavg.c.
23082         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
23083         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
23084         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
23085         Remove code that is now done by the newly-required macros.
23086         Append $(EXEEXT) to DF_PROG.
23087         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
23088         Do not invoke or require the following here,
23089         since prereq.m4 or some gnulib .m4 now does this for us:
23090         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
23091         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
23092         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
23093         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
23094         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
23095         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
23096         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
23097         AC_FUNC_OBSTACK.
23098         Do not replace the following functions, as this is now the job
23099         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
23100         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
23101         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
23102         atexit getpass, strdup, getpagesize.
23103         Replace 'raise'.
23104         Do not check for the following functions, as this is now the job
23105         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
23106         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
23107         setregid.
23108         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
23109         Check for sys/sysctl.h.
23110         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
23111         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
23112         of checking for ssize_t ourselves.
23113
23114         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
23115         Require every macro that gnulib/modules/* suggests for us.
23116         (jm_PREREQ_ADDEXT): New macro.
23117         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
23118         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
23119
23120         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
23121         (gl_PHYSMEM): Use it.
23122         Also check for `table' function.
23123         Check for new headers and functions.
23124         Add check for sys/sysmp.h.
23125         With suggestions from Kaveh Ghazi.
23126         Ignore headers that are present but cannot be compiled.  This
23127         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
23128         C 5.4.
23129
23130 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23131
23132         Document merge from coreutils.
23133         * modules/userspec: Depend on posixver.
23134         * modules/strftime: Depend on tzset.
23135
23136 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23137
23138         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
23139         rather than tab, after '#' in shell-script copyright notices.
23140         Suggested by Bruno Haible.
23141
23142 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23143
23144         * config/srclist-update: Use three spaces, rather than tab, after '#'
23145         in shell-script copyright notices.  Suggested by Bruno Haible.
23146         Remove unnecessary parenthesization in regular expression.
23147
23148 2003-08-15  Jim Meyering  <jim@meyering.net>
23149
23150         Merge from coreutils.
23151         * lib/xgethostname.c: Include <stdlib.h>.
23152         (xghostname): Don't exit for anything other than memory-related
23153         failure; just return NULL.
23154         * lib/userspec.c: Include "posixver.h".
23155         (parse_user_spec): Accept `.' as a separator only
23156         in pre-POSIX-200112 mode.
23157         * lib/strtoimax.c: Use #elif rather than #else #if.
23158         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
23159         Remove function, now that we can rely on a working tzset function.
23160         [!_LIBC]: Ensure that the required autoconf test has been run.
23161         [!defined _NL_CURRENT && HAVE_STRFTIME]:
23162         Use underlying_strftime for %r.
23163         * lib/sha.c: Merge in some clean-up and optimization changes from
23164         glibc.
23165         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
23166         Ensure that it is a multiple of 64.
23167         Rearrange loop exit tests so as to avoid performing an
23168         additional fread after encountering an error or EOF.
23169         * lib/realloc.c: Update copyright date.
23170
23171 2003-08-15  Jim Meyering  <jim@meyering.net>
23172         and Paul Eggert  <eggert@twinsun.com>
23173
23174         Merge from coreutils.
23175         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
23176         member but strut utmpx does not.  Needed for AIX 4.3.3.
23177         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
23178
23179 2003-08-15  Jim Meyering  <jim@meyering.net>
23180         and Paul Eggert  <eggert@cs.ucla.edu>
23181
23182         Merges from coreutils, etc.
23183         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
23184         Require gl_FUNC_TZSET_CLOBBER.
23185         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
23186         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
23187         members.
23188
23189 2003-08-14  Paul Eggert  <eggert@twinsun.com>
23190
23191         Help the merge from coreutils.
23192         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
23193         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
23194         * m4/tzset.m4: Use it too.
23195
23196 2003-08-14  Paul Eggert  <eggert@twinsun.com>
23197
23198         * modules/tzset: New file.
23199
23200 2003-08-14  Jim Meyering  <jim@meyering.net>
23201
23202         Merges from coreutils.
23203         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
23204         variable names, rather than @FNMATCH_H@.
23205         * modules/alloca: Likewise for $(ALLOCA_H).
23206
23207         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
23208         the three copies of the literal target, `fnmatch.h'.
23209         * modules/alloca (alloca.h): Likewise.
23210
23211 2003-08-14  Jim Meyering  <jim@meyering.net>
23212
23213         Merge from coreutils.
23214         * m4/tzset.m4: New file.
23215         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
23216         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
23217         otherwise, AIX 5.1 systems would end up using the latter.
23218         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
23219         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
23220         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
23221         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
23222
23223 2003-08-14  Jim Meyering  <jim@meyering.net>
23224
23225         Merge from coreutils.
23226         * lib/obstack.h: Whitespace changes.
23227         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
23228         and xcalloc return values.
23229         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
23230         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
23231         hang on OSF/1 5.1 for DIR on both local and remote file systems.
23232         Reported by (and fix confirmed by) Nelson H. F. Beebe.
23233         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23234         error from mntctl.
23235         Use mntctl's return value to drive the entry-processing loop, since
23236         we can't rely on the value of the vmt_length member in the last
23237         entry.  On some systems doing so could result in exhausting
23238         virtual memory.  Based in part on a patch from Mike Jetzer.
23239
23240 2003-08-14  Jim Meyering  <jim@meyering.net>
23241         and Paul Eggert  <eggert@twinsun.com>
23242
23243         Merges from coreutils, plus other fixes.
23244         * lib/physmem.c: Merge in portability changes from gcc/libiberty
23245         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
23246         for credits and details.  Thanks to Kaveh Ghazi for helping
23247         to keep these files in sync.
23248         (ARRAY_SIZE): Define it.
23249         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
23250         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
23251         (memcasecmp): Don't assume size_t fits in unsigned int.
23252         Remove casts and duplicate code.
23253         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
23254         (memcpy): Remove definition.
23255         Merge in some clean-up and optimization changes from glibc.
23256         [BLOCKSIZE]: Move definition to top of file.
23257         Ensure that it is a multiple of 64.
23258         Rearrange loop exit tests so as to avoid performing an
23259         additional fread after encountering an error or EOF.
23260         * lib/md5.h (md5_uintptr): Define.
23261         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
23262         return to the initial working directory.  Preserve errno
23263         for caller.
23264         * lib/idcache.c: Include "xalloc.h".
23265         (xmalloc, xrealloc): Remove decls.
23266         (getuser): Remove casts no longer required in C89.
23267         * lib/human.c: Include stdio.h, for sprintf.
23268         * lib/group-member.c: Include "xalloc.h".
23269         (xmalloc, xrealloc): Remove decls.
23270         (get_group_info): Remove casts no longer required in C89.
23271         * lib/getusershell.c (readname): Remove casts no longer required in
23272         C89.
23273         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
23274         * lib/getline.c: Whitespace fix, from coreutils.
23275
23276 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23277
23278         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
23279         Check for isascii.
23280
23281         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
23282         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
23283         Undo previous (whitespace-only) change.
23284
23285 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23286
23287         * lib/exclude.c: Include <ctype.h>
23288         (IN_CTYPE_DOMAIN): New macro.
23289         (is_space): New fn.
23290         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
23291         and empty lines.
23292
23293         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
23294         Undo previous (whitespace-only) change.
23295
23296 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23297
23298         * config/srclist-update: Change update back to the old behavior,
23299         leaving whitespace alone.  Use one 'sed' command rather than a
23300         pipeline.
23301         (fixlicense): Now a variable, not a function.
23302         (remove_trailing_blanks): Remove.
23303         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
23304         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
23305         Undo previous (whitespace-only) change.
23306
23307 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23308
23309         Merge from coreutils.
23310         * modules/euidaccess: Add lib_SOURCES, include for new
23311         file euidaccess.h
23312
23313 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23314
23315         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
23316         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
23317         Normalize leading white space and remove trailing white space.
23318
23319         Merge from coreutils
23320         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
23321
23322         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
23323         0.12.1.  These files are now being upgraded automatically by
23324         ../config/srclist-update.
23325
23326 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23327
23328         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
23329         Normalize leading white space and remove trailing white space.
23330         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
23331         notice, as per ../config/srclist-update.
23332
23333         Merge from coreutils.
23334         * lib/euidaccess.h: New file.
23335         * lib/euidaccess.c: Include it.
23336         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
23337         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
23338         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
23339
23340 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23341
23342         * config/srclist-update: Add copyright notice.
23343         (remove_id_lines, remove_trailing_blanks): New constants.
23344         (fixfile): Use them to normalize spacing a bit in copied files.
23345         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
23346         Normalize leading white space and remove trailing white space.
23347
23348         * config/texinfo.tex: Sync with texinfo.
23349
23350         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
23351         strtoul.c from libc, to merge coreutils whitespace changes.
23352
23353         * config/srclist.txt: Get the following m4 files from gettext:
23354         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
23355         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
23356         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
23357         wint_t.m4.
23358
23359 2003-08-12  Karl Berry  <karl@gnu.org>
23360
23361         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
23362         been made.
23363
23364 2003-08-11  Paul Eggert  <eggert@twinsun.com>
23365
23366         * modules/gnu-source, m4/gnu-source.m4:
23367         Remove; we're assuming Autoconf 2.54 or later now.
23368         Suggested by Bruno Haible.
23369         * MODULES.html.sh (func_all_modules): Remove gnu-source.
23370
23371 2003-08-11  Bruno Haible  <bruno@clisp.org>
23372
23373         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
23374
23375 2003-08-11  Bruno Haible  <bruno@clisp.org>
23376
23377         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
23378         (vasnprintf): Use it instead of wcslen.
23379
23380 2003-08-11  Bruno Haible  <bruno@clisp.org>
23381
23382         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
23383         value to ensure that _Bool promotes to int. Use #define for _Bool when
23384         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
23385
23386 2003-08-10  Karl Berry  <karl@gnu.org>
23387
23388         * lib/regex.h: update from libc (whitespace fix).
23389
23390 2003-08-09  Paul Eggert  <eggert@twinsun.com>
23391
23392         Merge some files from coreutils.  These changes were
23393         originally made by Jim Meyering.
23394         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
23395         many older Unixes require this.
23396         * lib/alloca.c (alloca): Remove cast to argument of free;
23397         no longer needed in C89.
23398         * lib/alloca_.h, regex.h: Fix white space to match
23399         what GNU indent does.
23400
23401 2003-08-09  Paul Eggert  <eggert@twinsun.com>
23402
23403         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
23404         apparently Emacs's Unicode mode got confused before my 2003-08-05
23405         checkin.
23406
23407 2003-08-08  Paul Eggert  <eggert@twinsun.com>
23408
23409         * m4/extensions.m4: New file.
23410         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
23411         Require gl_USE_SYSTEM_EXTENSIONS.
23412         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
23413         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
23414
23415 2003-08-08  Paul Eggert  <eggert@twinsun.com>
23416
23417         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
23418         * modules/extensions, modules/gnu-source: New files.
23419         * modules/timespec, modules/unlocked-io: Depend on extensions.
23420
23421 2003-08-07  Paul Eggert  <eggert@twinsun.com>
23422
23423         * modules/restrict: New file.
23424         * MODULES.html.sh (func_all_modules): Add restrict.
23425         * modules/regex: Depend on restrict.
23426
23427 2003-08-07  Paul Eggert  <eggert@twinsun.com>
23428
23429         * m4/restrict.m4: New file.
23430         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
23431
23432 2003-08-07  Bruno Haible  <bruno@clisp.org>
23433
23434         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
23435         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
23436
23437 2003-08-07  Bruno Haible  <bruno@clisp.org>
23438
23439         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
23440         makes the module 'getndelim2' compatible with the module 'getline'.
23441
23442 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23443
23444         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
23445         byte with "\201" to avoid glitches when editing that source file
23446         with multi-gnome-terminal.
23447
23448 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23449
23450         * lib/bumpalloc.h: Remove.
23451
23452 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23453
23454         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
23455         * modules/bumpalloc: Remove.
23456
23457 2003-08-04  Paul Eggert  <eggert@twinsun.com>
23458
23459         * lib/getloadavg.c: Change copyright notice and spacing to conform to
23460         GNU coding style.
23461
23462         Merge from coreutils.
23463         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
23464         1. From glibc.
23465         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
23466         from Karl Berry, implemented by Jim Meyering.
23467         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
23468         from Dmitry V. Levin.
23469         Remove anachronistic cast of xrealloc.
23470         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
23471         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
23472         type. Otherwise, it wouldn't compile with at least /bin/cc on
23473         ymp-cray-unicos9.0.2.X.
23474         Combine two mostly-identical uses of alloca into one.
23475         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
23476
23477 2003-08-04  Dave Love  <d.love@dl.ac.uk>
23478
23479         [From Emacs.]
23480
23481         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
23482         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
23483         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
23484         obsolete NLIST_NAME_UNION.
23485         [__GNU__]: Undef BSD and FSCALE.
23486         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
23487
23488 2003-08-03  Paul Eggert  <eggert@twinsun.com>
23489
23490         * lib/stdbool_.h (_Bool): Make it signed char, instead of
23491         an enum type, so that it's guaranteed to promote to int.  See:
23492         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
23493
23494 2003-08-03  Karl Berry  <karl@gnu.org>
23495
23496         * config/depcomp: update from automake.
23497
23498 2003-07-31  Paul Eggert  <eggert@twinsun.com>
23499
23500         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
23501         (strerror): Don't assume that a printable int fits in 14 bytes.
23502
23503 2003-07-31  Bruno Haible  <bruno@clisp.org>
23504
23505         * modules/getpass-gnu: New file.
23506         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
23507
23508 2003-07-31  Bruno Haible  <bruno@clisp.org>
23509
23510         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
23511
23512 2003-07-24  Karl Berry  <karl@gnu.org>
23513
23514         * config/missing: update from automake.
23515
23516 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
23517             Bruno Haible  <bruno@clisp.org>
23518
23519         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
23520         * lib/getline.c (getline, getdelim): Likewise.
23521         Remove _GNU_SOURCE define; now it's defined in config.h through
23522         m4/getline.m4.
23523
23524 2003-07-23  Karl Berry  <karl@gnu.org>
23525
23526         * config/config.sub: update from prep.
23527
23528 2003-07-22  Paul Eggert  <eggert@twinsun.com>
23529
23530         * modules/xalloc (Depends-on): Add exitfail.
23531         * modules/xmemcoll: Likewise.
23532
23533 2003-07-22  Paul Eggert  <eggert@twinsun.com>
23534
23535         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
23536         over-parenthesization in macros.
23537
23538         Sync with coreutils.
23539
23540         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
23541         required by C99.
23542
23543         Use `exit_failure' for xalloc and xmemcoll instead of their own
23544         private exit-failure variables.
23545         * lib/xalloc.h (xalloc_exit_failure): Remove.
23546         * lib/xmalloc.c: Likewise.  Include exitfail.h.
23547         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
23548         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
23549         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
23550         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
23551
23552 2003-07-20  Jim Meyering  <jim@meyering.net>
23553
23554         * modules/closeout (Depends-on): Add exitfail.
23555         Suggestion from Bruno Haible.
23556
23557 2003-07-19  Karl Berry  <karl@gnu.org>
23558
23559         * config/config.sub: update from prep.
23560
23561 2003-07-18  Paul Eggert  <eggert@twinsun.com>
23562
23563         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
23564         Remove.
23565         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
23566         to test that it can stand by itself.  Include "exitfail.h".
23567         Clients should set exit_failure instead.
23568         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
23569
23570 2003-07-18  Bruno Haible  <bruno@clisp.org>
23571
23572         * modules/getndelim2: New file.
23573         * modules/getline: Share files with module getndelim2.
23574         * modules/getnline: Depend on getndelim2 instead of sharing files with
23575         it. Add getnline.c to lib_SOURCES.
23576         * MODULES.html.sh (func_all_modules): Add getndelim2.
23577
23578 2003-07-18  Bruno Haible  <bruno@clisp.org>
23579
23580         * m4/getndelim2.m4: New file.
23581         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
23582         invoke gl_PREREQ_GETNDELIM2.
23583         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
23584         gl_PREREQ_GETNDELIM2.
23585         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
23586         gl_GETNDELIM2.
23587
23588 2003-07-18  Bruno Haible  <bruno@clisp.org>
23589
23590         * lib/getndelim2.h: New file.
23591         * lib/getndelim2.c: Make into a module of its own. Include config.h,
23592         getndelim2.h.
23593         (getndelim2): Make non-static. Change return type to ssize_t.
23594         * lib/getline.h: Change argument names.
23595         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
23596         * lib/getnline.c: Include getndelim2.h.
23597
23598 2003-07-18  Andreas Schwab  <schwab@suse.de>
23599
23600         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
23601
23602 2003-07-17  Karl Berry  <karl@gnu.org>
23603
23604         * config/config.sub: update from prep.
23605
23606 2003-07-17  Bruno Haible  <bruno@clisp.org>
23607
23608         * modules/getnline: New file.
23609         * modules/getline: Add lib/getndelim2.c to source file list.
23610         * MODULES.html.sh (func_all_modules): Add getnline.
23611
23612 2003-07-17  Bruno Haible  <bruno@clisp.org>
23613
23614         * m4/getnline.m4: New file.
23615
23616 2003-07-17  Bruno Haible  <bruno@clisp.org>
23617
23618         * m4/Makefile.am.in: Remove file.
23619         * m4/Makefile.am: Remove file.
23620         * m4/Makefile.in: Remove file.
23621
23622 2003-07-17  Bruno Haible  <bruno@clisp.org>
23623
23624         * lib/getnline.h: New file.
23625         * lib/getnline.c: New file.
23626         * lib/getndelim2.c: New file, extracted from getline.c.
23627         (getndelim2): Renamed from getdelim2, with added nmax argument.
23628         * lib/getline.c: Include getndelim2.c.
23629         (getdelim2): Moved out to getndelim2.c.
23630         (getline, getdelim): Update.
23631
23632 2003-07-17  Bruno Haible  <bruno@clisp.org>
23633
23634         * lib/Makefile.am: Remove file.
23635         * lib/Makefile.in: Remove file.
23636
23637 2003-07-17  Bruno Haible  <bruno@clisp.org>
23638
23639         * configure.in: Remove file.
23640         * Makefile.in: Remove file.
23641
23642 2003-07-17  Bruno Haible  <bruno@clisp.org>
23643
23644         * MODULES.html.sh: Put the </BODY> right before </HTML>.
23645
23646 2003-07-16  Karl Berry  <karl@gnu.org>
23647
23648         * config/srclist-update: was running fixlicense twice, which caused
23649                 texinfo.tex to be nullified for some reason.  Simplify,
23650                 $gplsrc is no longer needed as far as I can see?
23651
23652 2003-07-16  Jim Meyering  <jim@meyering.net>
23653
23654         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
23655
23656 2003-07-15  Paul Eggert  <eggert@twinsun.com>
23657
23658         * config/srclist.txt: Get the following files from gettext-runtime/intl
23659         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
23660         ref-del.sin.  From Bruno Haible.
23661         * config/srclist-update (fixfile): Change grep pattern again, since the
23662         previous fix didn't work (there was another trailing $).  Use
23663         '[$]' to escape the $s.
23664
23665 2003-07-15  Karl Berry  <karl@gnu.org>
23666
23667         * lib/vasnprintf.c: update from gettext.
23668
23669 2003-07-15  Karl Berry  <karl@gnu.org>
23670
23671         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
23672         gets expanded when surrounded by '$'.
23673
23674 2003-07-15  Jim Meyering  <jim@meyering.net>
23675
23676         * modules/save-cwd: Don't depend on error.  From Derek Price.
23677
23678 2003-07-15  Jim Meyering  <jim@meyering.net>
23679
23680         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
23681
23682 2003-07-14  Simon Josefsson  <jas@extundo.com>
23683
23684         * modules/mempcpy: New file.
23685         * MODULES.html.sh (func_all_modules): Add mempcpy.
23686
23687 2003-07-14  Simon Josefsson  <jas@extundo.com>
23688
23689         * m4/mempcpy.m4: New file.
23690
23691 2003-07-14  Simon Josefsson  <jas@extundo.com>
23692
23693         * lib/mempcpy.h: New file.
23694         * lib/mempcpy.c: New file.
23695
23696 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23697
23698         * modules/getdate, modules/posixtm: Depend on mktime.
23699
23700 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23701
23702         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
23703         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
23704         unicodeio.c, unicodeio.h, unlocked-io.h:
23705         Switch from LGPL to GPL.
23706
23707 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23708
23709         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
23710         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
23711         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
23712         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
23713         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
23714         updated automatically by ../config/srclist-update.  This changes
23715         their license from LPGL to GPL.
23716
23717 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23718
23719         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
23720         assumed to refer to the root of the most recent stable gettext version.
23721         * config/srclistvars.sh: Add defaults for eggert.
23722         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
23723         Match "This program" as well as "The program".  This is needed
23724         for gettext.
23725
23726 2003-07-14  Jim Meyering  <jim@meyering.net>
23727
23728         Don't emit diagnostics.  Let callers do that.
23729         * lib/save-cwd.c: Don't include "error.h".
23730         (save_cwd): Don't call error.  Ensure that errno is valid
23731         when returning nonzero.
23732
23733         * lib/save-cwd.h (restore_cwd): Update prototype.
23734         * lib/save-cwd.c (restore_cwd): Remove two parameters.
23735         Simplify.  Don't call error upon failure.  Let callers do that.
23736         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
23737         when auditing is enabled.  But don't bother updating the #if.
23738
23739 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
23740
23741         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
23742         it breaks C++ compilation.
23743         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
23744
23745 2003-07-10  Simon Josefsson  <jas@extundo.com>
23746
23747         * modules/strchrnul (Makefile.am): Add strchrnul.h.
23748
23749 2003-07-10  Jim Meyering  <jim@meyering.net>
23750
23751         * m4/clock_time.m4: Remove trailing blank.
23752         * m4/intmax_t.m4: Likewise.
23753
23754 2003-07-10  Jim Meyering  <jim@meyering.net>
23755
23756         * lib/vasnprintf.c: Remove trailing blanks.
23757         Make cpp indentation consistent.
23758
23759 2003-07-09  Paul Eggert  <eggert@twinsun.com>
23760
23761         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
23762         posixver.c, strftime.c, strnlen.c, strverscmp.c:
23763         Switch from LGPL to GPL.
23764
23765 2003-07-09  Paul Eggert  <eggert@twinsun.com>
23766
23767         * config/srclist.txt: Sort sublists.  Add
23768         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
23769         that differ from gnulib for one reason or another; we'd like this list
23770         to be smaller but for now let's document what we have.
23771
23772 2003-07-08  Paul Eggert  <eggert@twinsun.com>
23773
23774         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
23775         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
23776         and sweeter "eval x=$x".
23777         * config/srclist.txt: Get lib/argp* from glibc.
23778
23779 2003-07-07  Paul Eggert  <eggert@twinsun.com>
23780
23781         * lib/mktime.c: Fix some boundary cases and remove need for floating
23782         point.
23783
23784         Issue a compile-time diagnostic if time_t is floating point, or if
23785         two's complement arithmetic is not in effect, or if arithmetic
23786         right shift does not propagate the sign.  These assumptions were
23787         all in the original code but they weren't checked.
23788
23789         (TIME_T_MIDPOINT, verify): New macros.
23790         (__isleap): Remove; it has integer overflow problems.
23791         (leapyear): New function, without those problems.
23792         (ydhms_tm_diff): Remove; splitting into two parts.
23793         (ydhms_diff): New function, containing the arithmetic part of
23794         the old ydhms_tm_diff function.  Issue a compile-time
23795         diagnostic if we are not using C99 integer division.
23796         Avoid casts when possible.
23797         (guess_time_tm): New function, containing the checking part of
23798         the old ydhms_tm_diff function.  Return the new value, rather than
23799         the difference between it and the old.  Accept a new argument T
23800         so that *T specifies the old value.  Check for overflow in the result.
23801
23802         (__mktime_internal): Use a time_t offset, not a long int offset.
23803         This undoes the 2003-06-04 change, which is no longer needed now
23804         that we have better overflow checking.
23805         (localtime_offset): Likewise.
23806
23807         (__mktime_internal): Avoid harmful overflow on hosts where time_t
23808         and long are 64-bit but int is only 32-bit.
23809         (ydhms_diff): Use long int to store year1 and yday1.
23810         Issue a compile-time diagnostic if long int is not wide enough.
23811
23812         (__mktime_internal): Use long int to store adjusted year and yday.
23813         Use plain C rather than preprocessor commands, if that doesn't
23814         affect efficiency.
23815         Check for overflow (and try to repair) after each probe
23816         rather than checking only at the very end.  This avoids some bugs
23817         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
23818         does not equal GMT offset at maximum time).
23819         Use integer to check for overflow rather than floating point; this
23820         is more portable to non-IEEE hosts, and is a tad faster.
23821         When we detect that we are oscillating between two values,
23822         don't check whether tm_isdst has the requested value, since
23823         we already know the answer.  When tm_isdst has the wrong value,
23824         use a different heuristic to find the right one, based on the
23825         extreme values actually observed in practice in tz2003a,
23826         rather than the (overly optimistic) "previous 3 calendar quarters".
23827
23828         (not_equal_tm, print_tm, check_result): Use "const T" rather than
23829         "T const" to accommodate glibc style.
23830         (check_result): Use less-confusing report format.  "long" -> "long int.
23831         (main): Likewise.
23832         Don't loop if the iteration overflows time_t.
23833         Allow a negative step in the iteration.
23834
23835 2003-07-06  Karl Berry  <karl@gnu.org>
23836
23837         * config/depcomp: update from automake.
23838         * config/config.sub: update from prep.
23839
23840 2003-07-03  Karl Berry  <karl@gnu.org>
23841
23842         * config/config.guess: update from prep.
23843
23844 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23845
23846         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
23847         xreadlink.c now includes it unconditionally.
23848
23849 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23850
23851         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
23852         having it depend on HAVE_SYS_TYPES_H.
23853
23854 2003-07-01  Bruno Haible  <bruno@clisp.org>
23855
23856         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
23857         <sys/types.h> should be sufficient.
23858         Reported by Paul Eggert.
23859
23860 2003-06-26  Karl Berry  <karl@gnu.org>
23861
23862         * config/depcomp: update from automake.
23863
23864 2003-06-26  Bruno Haible  <bruno@clisp.org>
23865
23866         * modules/human: Depend on module stdbool.
23867
23868 2003-06-25  Bruno Haible  <bruno@clisp.org>
23869
23870         * modules/readlink: New file.
23871         * modules/xreadlink: Depend on it.
23872         * MODULES.html.sh (func_all_modules): Add readlink.
23873
23874 2003-06-25  Bruno Haible  <bruno@clisp.org>
23875
23876         * m4/readlink.m4: New file.
23877
23878 2003-06-25  Bruno Haible  <bruno@clisp.org>
23879
23880         * lib/readlink.c: New file.
23881
23882 2003-06-22  Karl Berry  <karl@gnu.org>
23883
23884         * config/srclist.txt: update mkinstalldirs from automake.
23885         * config/mkinstalldirs: update.
23886
23887 2003-06-22  Bruno Haible  <bruno@clisp.org>
23888
23889         Portability to mingw32.
23890         * m4/ssize_t.m4: New file, from GNU gettext.
23891         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
23892         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
23893
23894 2003-06-22  Bruno Haible  <bruno@clisp.org>
23895
23896         * modules/safe-read: Add m4/ssize_t.m4.
23897         * modules/xreadlink: Add m4/ssize_t.m4.
23898
23899 2003-06-20  Bruno Haible  <bruno@clisp.org>
23900
23901         Assume C89, so PARAMS isn't needed.
23902         * lib/unicodeio.h (PARAMS): Remove.
23903         * lib/unicodeio.c: Don't use PARAMS.
23904
23905 2003-06-18  Karl Berry  <karl@gnu.org>
23906
23907         * config/config.{guess,sub}: update from prep.
23908
23909 2003-06-18  Jim Meyering  <jim@meyering.net>
23910
23911         Merge changes from coreutils.
23912         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
23913         Remove explicit declarations of xmalloc and realloc.
23914         Include xalloc.h.
23915         (read_utmp): Remove anachronistic cast of xmalloc.
23916
23917 2003-06-17  Paul Eggert  <eggert@twinsun.com>
23918
23919         Assume C89, so PARAMS isn't needed.
23920         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
23921         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
23922         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
23923         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
23924         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
23925         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
23926         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
23927         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
23928         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
23929         lib/xstrtod.h, lib/xstrtol.h: Likewise.
23930         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
23931         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
23932         no longer needed. Anyway, config.h should always be included before any
23933         other file.
23934
23935 2003-06-11  Simon Josefsson  <jas@extundo.com>
23936
23937         * modules/sysexits: New file.
23938         * MODULES.html.sh (func_all_modules): Add sysexits.
23939
23940 2003-06-11  Simon Josefsson  <jas@extundo.com>
23941
23942         * lib/sysexit_.h: New file.
23943
23944 2003-06-11  Derek Price  <derek@ximbiot.com>
23945
23946         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
23947         necessary.
23948
23949 2003-06-11  Bruno Haible  <bruno@clisp.org>
23950
23951         * m4/sysexits.m4: New file.
23952
23953 2003-06-10  Simon Josefsson  <jas@extundo.com>
23954
23955         * lib/argp.h: New file, from glibc.
23956         * lib/argp-ba.c: New file, from glibc.
23957         * lib/argp-eexst.c: New file, from glibc.
23958         * lib/argp-fmtstream.c: New file, from glibc.
23959         * lib/argp-fmtstream.h: New file, from glibc.
23960         * lib/argp-fs-xinl.c: New file, from glibc.
23961         * lib/argp-help.c: New file, from glibc.
23962         * lib/argp-namefrob.h: New file, from glibc.
23963         * lib/argp-parse.c: New file, from glibc.
23964         * lib/argp-pv.c: New file, from glibc.
23965         * lib/argp-pvh.c: New file, from glibc.
23966         * lib/argp-xinl.c: New file, from glibc.
23967
23968 2003-06-10  Simon Josefsson  <jas@extundo.com>
23969
23970         * modules/strchrnul: New file.
23971
23972 2003-06-10  Simon Josefsson  <jas@extundo.com>
23973
23974         * modules/argp: New file.
23975
23976 2003-06-10  Simon Josefsson  <jas@extundo.com>
23977
23978         * m4/strchrnul.m4: New file.
23979
23980 2003-06-10  Simon Josefsson  <jas@extundo.com>
23981
23982         * lib/strchrnul.h: New file.
23983         * lib/strchrnul.c: New file.
23984
23985 2003-06-10  Bruno Haible  <bruno@clisp.org>
23986
23987         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
23988
23989 2003-06-07  Karl Berry  <karl@gnu.org>
23990
23991         * config/config.{guess,sub}: update from prep.
23992
23993 2003-06-07  Jim Meyering  <jim@meyering.net>
23994
23995         * modules/strtod: Use $(...) notation, not @...@ for
23996         AC_REPLACE'd variables.
23997         * modules/localcharset: Likewise.
23998
23999 2003-06-07  Jim Meyering  <jim@meyering.net>
24000
24001         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
24002         in place of my name in the copyright comment.
24003         Remove definition and uses of __P.
24004
24005         From coreutils.
24006         * lib/stat.c: Don't declare xmalloc explicitly.
24007         Instead, include "xalloc.h".
24008         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
24009         xrealloc, and xcalloc return values.
24010         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
24011         Improve comment.
24012         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
24013
24014 2003-06-07  Bruno Haible  <bruno@clisp.org>
24015
24016         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
24017         avoid AC_CONFIG_LINKS.
24018         * modules/fnmatch (Makefile.am): Use explicit creation rule for
24019         fnmatch.h, to avoid AC_CONFIG_LINKS.
24020         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
24021
24022 2003-06-07  Bruno Haible  <bruno@clisp.org>
24023
24024         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
24025         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
24026         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
24027         directory.
24028         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
24029         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
24030         directory.
24031
24032 2003-06-06  Jim Meyering  <jim@meyering.net>
24033
24034         Merge from coreutils.
24035         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
24036         Consolidate declarations and initializations of *_base* locals.
24037
24038         Merge from coreutils.
24039         This avoids a core dump on systems without GNU putenv,
24040         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
24041         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
24042         (unsetenv): New static function, from GNU libc.
24043         (rpl_putenv): Use it.
24044
24045         * lib/modechange.c: Remove trailing blanks.
24046
24047         Merge from coreutils.
24048         * lib/fsusage.c: Remove declaration of statfs.
24049         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
24050
24051         * lib/posixtm.c: Include <stdbool.h> unconditionally.
24052
24053 2003-06-06  Jim Meyering  <jim@meyering.net>
24054
24055         * lib/stdbool_.h: Renamed from stdbool.h.in.
24056
24057 2003-06-06  Jim Meyering  <jim@meyering.net>
24058             Bruno Haible  <bruno@clisp.org>
24059
24060         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
24061         Adjust Makefile.am snippet not to redirect directly to target.
24062         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
24063
24064 2003-06-05  Paul Eggert  <eggert@twinsun.com>
24065
24066         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
24067         mismatch, look in future quarters as well as past.  This fixes a
24068         bug when processing fall-backwards gaps immediately after a long
24069         period of daylight-saving time.
24070
24071         * lib/mktime.c: Assume freestanding C89 or better.
24072         (HAVE_LIMITS_H): Remove.  Assume it's 1.
24073         (__P): Remove; not used.
24074         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
24075         (mktime, not_equal_tm, print_tm, check_result,
24076         main): Use prototypes.  Use const * where appropriate.
24077         (main): Fix typo in testing code that uncovered by above changes.
24078         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
24079
24080 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24081
24082         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
24083         locale.h, localeconv.  This merges changes from coreutils.
24084
24085         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
24086         It can be removed after the next Autoconf is released.
24087         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
24088         needed.
24089
24090 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24091
24092         * lib/mktime.c: Fix Debian bug 177940
24093         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
24094         (localtime_offset): Now long int, not time_t, because we want it
24095         to be guaranteed to be signed.  All uses changed.
24096         (__mktime_internal): If overflow would occur when adding offset,
24097         don't add it.
24098
24099         Merge 'human' changes from coreutils.  Rewrite to support
24100         locale-specific notations like thousands separators.
24101         * lib/human.c: Simplify authorship notice.
24102         Include human.h immediately after config.h.
24103         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
24104         <limits.h>: Do not include, since human.h does.
24105         (SIZE_MAX, UINTMAX_MAX): New macros.
24106         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
24107         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
24108         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
24109         (power_letter): Renamed from suffixes.
24110         (generate_suffix_backwards): Remove.
24111         (adjust_value): Now takes int style (because of human.h changes)
24112         and long double value (for greater precision on some platforms).
24113         (group_number): New function.
24114         (human_readable): Use it.  Use integer options, not enum.
24115         Put the options before the sizes in the arg list.
24116         Support all the new options.
24117         The old human_readable function has been removed;
24118         use inttostr.h instead.
24119         (human_readable, default_block_size, humblock):
24120         Use uintmax_t, not int, for block sizes.
24121         (human_readable_inexact, block_size_types): Remove.
24122         (block_size_opts): New constant.
24123         (human_options): Renamed from human_block_size, with new signature
24124         that allows block sizes up to UINTMAX_MAX.  All callers changed.
24125         * lib/human.h: Add copyright and authorship notice.
24126         Include <limits.h> and <stdbool.h> unconditionally.
24127         (PARAMS): Remove.  All uses removed.
24128         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
24129         (enum human_inexact_style): Remove tag; now a nameless enum.
24130         (human_floor, human_ceiling, human_round_to_even): Now have
24131         values 2, 0, 1 rather than -1, 1, 0.
24132         (human_group_digits, human_suppress_point_zero, human_autoscale,
24133         human_base_1024, human_SI, human_B): New constants.
24134         (human_readable_inexact, human_block_size): Remove.
24135         (human_readable): Size args are now uintmax_t, not int.
24136         (human_options): New decl.
24137
24138         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
24139         unnecessary now that we assume C89 or better.  This change
24140         imported from coreutils.
24141
24142         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
24143         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
24144         in the 2003-05-30 sync from glibc.
24145
24146         .h files should stand alone, but we shouldn't include <sys/types.h>
24147         if we can get away with just <stddef.h>.
24148
24149         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
24150         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
24151         rather than <sys/types.h>, as we merely need size_t.
24152         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
24153         to get size_t.
24154         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
24155         Include <stdio.h>, to get FILE.
24156         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
24157         memcasecmp.h has included <stddef.h> and all we need is size_t.
24158         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
24159         our interface, instead of including <sys/types.h>
24160
24161 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24162
24163         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
24164         now, as glibc mktime is buggy on non-glibc systems.
24165
24166 2003-06-03  Karl Berry  <karl@gnu.org>
24167
24168         * config/config.sub: update from prep.
24169
24170 2003-06-02  Paul Eggert  <eggert@twinsun.com>
24171
24172         [from coreutils]
24173         Fix some minor time-related bugs with POSIX time arguments.
24174         Some valid time stamps were being rejected (notably -1, and
24175         time stamps before 1900 on 64-bit hosts).  And some invalid
24176         time stamps were being accepted, e.g. September 31.
24177
24178         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
24179         that we can return (time_t) -1 successfully.
24180         * lib/posixtm.c: Likewise.
24181         [HAVE_STDBOOL_H]: Include <stdbool.h>.
24182         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
24183         (t): Remove static var.
24184         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
24185         of static var.  All uses changed.
24186         (year): Do not reject years before 1900; they can occur with
24187         64-bit time_t.
24188         (posix_time_parse): Do not check for out-of-range components;
24189         that is now the caller's responsibility, since our checks were
24190         only approximations.
24191         (posixtime): Use mktime to check for out-of-range components,
24192         since it knows them exactly.
24193         If mktime returns (time_t) -1, check whether an error actually occurred
24194         by invoking localtime on -1.
24195         (main) [TEST_POSIXTIME]: Check for input data errors, and report
24196         posixtime failures better.
24197         Improve the test data (in comments only).
24198
24199 2003-06-02  Karl Berry  <karl@gnu.org>
24200
24201         * config/mkinstalldirs (version): new variable.
24202         (--version): new option.
24203         (usage): improve message.
24204
24205 2003-05-30  Karl Berry  <karl@gnu.org>
24206
24207         * lib/mktime.c: update from libc.
24208
24209 2003-05-30  Bruno Haible  <bruno@clisp.org>
24210
24211         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
24212         * config/config.rpath: Upgrade to gettext-0.12.1.
24213
24214 2003-05-30  Bruno Haible  <bruno@clisp.org>
24215
24216         * m4/gettext.m4: Upgrade to gettext-0.12.1.
24217         * m4/nls.m4: New file, from gettext-0.12.1.
24218         * m4/po.m4: New file, from gettext-0.12.1.
24219         * m4/progtest.m4: Upgrade to gettext-0.12.1.
24220
24221 2003-05-30  Bruno Haible  <bruno@clisp.org>
24222
24223         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
24224         * lib/localcharset.h: Likewise.
24225         * lib/localcharset.c: Likewise.
24226
24227 2003-05-29  Karl Berry  <karl@gnu.org>
24228
24229         * config/config.rpath: update from gettext.
24230
24231 2003-05-28  Paul Eggert  <eggert@twinsun.com>
24232
24233         Assume the headers required for C89 freestanding compilers.
24234         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
24235         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
24236         * m4/human.m4 (gl_HUMAN): Likewise.
24237         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
24238         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
24239         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24240         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
24241         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24242         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
24243
24244 2003-05-28  Paul Eggert  <eggert@twinsun.com>
24245
24246         Assume the headers required for C89 freestanding compilers.
24247         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
24248         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
24249         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
24250         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
24251         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
24252         define, since <limits.h> is guaranteed to do that.
24253         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
24254         * lib/exclude.c: Include <stdbool.h> unconditionally.
24255         * lib/tempname.c: Include <stddef.h> unconditionally.
24256         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
24257         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
24258         <stddef.h> does that.
24259         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
24260         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
24261         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
24262         needed.
24263         * lib/xstrtol.c: Likewise.
24264         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
24265         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
24266
24267         * lib/addext.c (addext): Use assignment rather than cast, to avoid
24268         warnings on some platforms.
24269
24270         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
24271         arbitrarily.
24272
24273 2003-05-26  Jim Meyering  <jim@meyering.net>
24274
24275         Merge in a change from coreutils:
24276         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
24277         that is guaranteed to be `no'.  Use `no_such_member' to indicate
24278         that condition, rather than `-1' which is slightly misleading.
24279         Change the name of the cache variable to have the gl_ prefix.
24280         Prompted by a patch from Richard Dawe for DJGPP.
24281
24282 2003-05-24  Karl Berry  <karl@gnu.org>
24283
24284         * config/config.guess: update from prep.
24285
24286 2003-05-22  Karl Berry  <karl@gnu.org>
24287
24288         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
24289
24290 2003-05-20  Karl Berry  <karl@gnu.org>
24291
24292         * config/config.guess: update from prep.
24293
24294 2003-05-18  Karl Berry  <karl@gnu.org>
24295
24296         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
24297         might actually be set by the user.
24298
24299         * config/depcomp, install-sh, mdate-sh: update from automake.
24300
24301 2003-05-17  Bruno Haible  <bruno@clisp.org>
24302
24303         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
24304         invalid expansion for AC_EGREP_CPP.
24305         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
24306         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
24307         Suggested by Akim Demaille <akim@epita.fr> in
24308         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
24309
24310 2003-05-12  Jim Meyering  <jim@meyering.net>
24311
24312         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
24313         the space-padded-by-default conversion specifiers, %e, %k, %l.
24314
24315 2003-05-12  Bruno Haible  <bruno@clisp.org>
24316
24317         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
24318         the string is longer than 4 KB.
24319
24320 2003-05-11  Karl Berry  <karl@gnu.org>
24321
24322         * config/config.{guess,sub}: update from prep.
24323
24324 2003-05-09  Bruno Haible  <bruno@clisp.org>
24325
24326         * modules/error: Add m4/strerror_r.m4 to file list.
24327
24328 2003-05-03  Bruno Haible  <bruno@clisp.org>
24329
24330         Upgrade to Unicode-4.0.
24331         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
24332         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
24333         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
24334         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
24335         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
24336         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
24337         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
24338         Change width of U+E0100..U+E01EF from 1 to 0.
24339
24340 2003-04-25  Jim Meyering  <jim@meyering.net>
24341
24342         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
24343         of type size_t, not int.
24344
24345 2003-04-25  Bruno Haible  <bruno@clisp.org>
24346
24347         * lib/copy-file.c: Include <stddef.h>, for size_t.
24348
24349 2003-04-21  Paul Eggert  <eggert@twinsun.com>
24350
24351         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
24352         code which expansion is under static control.  Patch imported from
24353         Akim Demaille's patch to Bison; see
24354         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
24355
24356 2003-04-14  Bruno Haible  <bruno@clisp.org>
24357
24358         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
24359
24360 2003-04-11  Jim Meyering  <jim@meyering.net>
24361
24362         Merge changes from Coreutils.
24363
24364         2003-03-22  Jim Meyering  <jim@meyering.net>
24365
24366         * lib/strftime.c (widen): Cast alloca return value to proper type.
24367
24368         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
24369
24370         From GNU libc.
24371         * lib/strftime.c (my_strftime): Handle very large width
24372         specifications for numeric values correctly.  Improve checks for
24373         overflow.
24374
24375         2003-01-19  Jim Meyering  <jim@meyering.net>
24376
24377         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
24378         definitions.
24379         (nl_get_alt_digit) [! defined my_strftime]: Define.
24380         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
24381         _nl_get_alt_digit and _nl_get_walt_digit.
24382
24383         * lib/strftime.c (my_strftime): Merge in locale-related changes from
24384         libc. These changes have no effect outside of _LIBC.
24385
24386 2003-04-10  Bruno Haible  <bruno@clisp.org>
24387
24388         * modules/findprog: New file.
24389         * MODULES.html.sh (func_all_modules): Add it.
24390
24391 2003-04-10  Bruno Haible  <bruno@clisp.org>
24392
24393         * m4/findprog.m4: New file.
24394         * m4/eaccess.m4: New file.
24395
24396 2003-04-10  Bruno Haible  <bruno@clisp.org>
24397
24398         * lib/findprog.h: New file, from GNU gettext.
24399         * lib/findprog.c: New file, from GNU gettext.
24400
24401 2003-04-05  Jim Meyering  <jim@meyering.net>
24402
24403         Merge changes from Coreutils.
24404
24405         * lib/exclude.h (PARAMS): Remove definition and uses.
24406         * lib/exclude.c: Remove uses of `PARAMS'.
24407
24408         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
24409         Add test-cases for DOS filenames. Declare program_name.
24410         (main): Set up program_name.  Patch by Rich Dawe.
24411
24412         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
24413         error from mntctl.
24414         Use mntctl's return value to drive the entry-processing loop, since
24415         we can't rely on the value of the vmt_length member in the last
24416         entry.  On some systems doing so could result in exhausting
24417         virtual memory.  Based in part on a patch from Mike Jetzer.
24418
24419 2003-04-04  Bruno Haible  <bruno@clisp.org>
24420
24421         * modules/linebreak: New file.
24422         * MODULES.html.sh (func_all_modules): Add it.
24423
24424 2003-04-04  Bruno Haible  <bruno@clisp.org>
24425
24426         * m4/linebreak.m4: New file.
24427
24428 2003-04-04  Bruno Haible  <bruno@clisp.org>
24429
24430         * lib/linebreak.h: New file, from GNU gettext.
24431         * lib/linebreak.c: New file, from GNU gettext with slight
24432         modifications.
24433         * lib/lbrkprop.h: New file, from GNU gettext.
24434
24435 2003-04-03  Bruno Haible  <bruno@clisp.org>
24436
24437         * modules/utf8-ucs4: New file.
24438         * modules/utf16-ucs4: New file.
24439         * modules/ucs4-utf8: New file.
24440         * modules/ucs4-utf16: New file.
24441         * MODULES.html.sh (func_all_modules): Add them.
24442
24443 2003-04-03  Bruno Haible  <bruno@clisp.org>
24444
24445         * m4/utf-ucs4.m4: New file.
24446         * m4/ucs4-utf.m4: New file.
24447
24448 2003-04-03  Bruno Haible  <bruno@clisp.org>
24449
24450         * lib/utf8-ucs4.h: New file, from GNU gettext.
24451         * lib/utf16-ucs4.h: New file, from GNU gettext.
24452         * lib/ucs4-utf8.h: New file, from GNU gettext.
24453         * lib/ucs4-utf16.h: New file, from GNU gettext.
24454
24455 2003-04-02  Bruno Haible  <bruno@clisp.org>
24456
24457         * modules/binary-io: New file.
24458         * MODULES.html.sh (func_all_modules): Add it.
24459
24460 2003-04-02  Bruno Haible  <bruno@clisp.org>
24461
24462         * lib/binary-io.h: New file, from GNU gettext.
24463
24464 2003-04-01  Bruno Haible  <bruno@clisp.org>
24465
24466         * modules/pathname: New file.
24467         * MODULES.html.sh (func_all_modules): Add it.
24468
24469 2003-04-01  Bruno Haible  <bruno@clisp.org>
24470
24471         * lib/pathname.h: New file, from GNU gettext.
24472         * lib/concatpath.c: New file, from GNU gettext.
24473
24474 2003-03-30  Bruno Haible  <bruno@clisp.org>
24475
24476         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
24477
24478 2003-03-30  Bruno Haible  <bruno@clisp.org>
24479
24480         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
24481         function chown() doesn't exist.
24482
24483 2003-03-28  Bruno Haible  <bruno@clisp.org>
24484
24485         * modules/copy-file: New file.
24486         * MODULES.html.sh (func_all_modules): Add it.
24487
24488 2003-03-28  Bruno Haible  <bruno@clisp.org>
24489
24490         * m4/copy-file.m4: New file.
24491
24492 2003-03-28  Bruno Haible  <bruno@clisp.org>
24493
24494         * lib/copy-file.h: New file, from GNU gettext.
24495         * lib/copy-file.c: New file, from GNU gettext.
24496
24497 2003-03-18  Jim Meyering  <jim@meyering.net>
24498
24499         * lib/quote.c (quote_n): Fix typo in comment.
24500
24501 2003-03-18  Bruno Haible  <bruno@clisp.org>
24502
24503         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
24504         checking.
24505         * m4/onceonly_2_57.m4: Likewise.
24506
24507 2003-03-17  Bruno Haible  <bruno@clisp.org>
24508
24509         * m4/onceonly.m4: Require autoconf 2.54 or newer.
24510         (m4_quote): Remove macro.
24511         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
24512
24513 2003-03-14  Jim Meyering  <jim@meyering.net>
24514
24515         Merge changes from Coreutils.
24516         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
24517         to be const, in order to avoid warnings.
24518         (obstack_room): Likewise.
24519         (obstack_empty_p): Likewise.
24520
24521 2003-03-14  Bruno Haible  <bruno@clisp.org>
24522
24523         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
24524         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
24525
24526 2003-03-13  Paul Eggert  <eggert@twinsun.com>
24527
24528         Merge changes from Bison.
24529         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
24530         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
24531         when compiling Bison 1.875's `bitset bset = obstack_alloc
24532         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
24533         * lib/hash.c: Include <stdbool.h> unconditionally.
24534
24535 2003-03-13  Paul Eggert  <eggert@twinsun.com>
24536
24537         * m4/onceonly.m4 (m4_quote): New macro.
24538         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
24539         Quote AC_FOREACH variable-expansions properly.
24540
24541 2003-03-13  Paul Eggert  <eggert@twinsun.com>
24542
24543         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
24544
24545 2003-03-09  Paul Eggert  <eggert@twinsun.com>
24546
24547         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
24548         Reported by Bruce Becker; see:
24549         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
24550
24551 2003-03-03  Paul Eggert  <eggert@twinsun.com>
24552             Bruno Haible  <bruno@clisp.org>
24553
24554         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
24555         Reported by John Hughes, see
24556         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
24557
24558 2003-02-20  Bruno Haible  <bruno@clisp.org>
24559
24560         * MODULES.html.sh (func_all_modules): Add poll.
24561
24562 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
24563
24564         * modules/poll: New file.
24565
24566 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
24567
24568         * lib/poll_.h: New file.
24569         * lib/poll.c: New file.
24570
24571 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
24572
24573         * m4/poll.m4: New file.
24574
24575 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
24576
24577         * modules/mathl: New file.
24578
24579 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
24580
24581         * lib/mathl.h: New file.
24582         * lib/acosl.c: New file.
24583         * lib/asinl.c: New file.
24584         * lib/atanl.c: New file.
24585         * lib/ceill.c: New file.
24586         * lib/cosl.c: New file.
24587         * lib/expl.c: New file.
24588         * lib/floorl.c: New file.
24589         * lib/frexpl.c: New file.
24590         * lib/ldexpl.c: New file.
24591         * lib/logl.c: New file.
24592         * lib/sincosl.c: New file.
24593         * lib/sinl.c: New file.
24594         * lib/sqrtl.c: New file.
24595         * lib/tanl.c: New file.
24596         * lib/trigl.c: New file.
24597         * lib/trigl.h: New file.
24598
24599 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
24600
24601         * m4/mathl.m4: New file.
24602
24603 2003-02-18  Bruno Haible  <bruno@clisp.org>
24604
24605         * MODULES.html.sh (func_all_modules): Add mathl.
24606
24607 2003-02-17  Bruno Haible  <bruno@clisp.org>
24608
24609         * modules/mkdtemp: New module.
24610         * MODULES.html.sh (func_all_modules): Add it.
24611
24612 2003-02-17  Bruno Haible  <bruno@clisp.org>
24613
24614         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
24615
24616 2003-02-17  Bruno Haible  <bruno@clisp.org>
24617
24618         * lib/mkdtemp.h: New file, from GNU gettext.
24619         * lib/mkdtemp.c: New file, from GNU gettext.
24620
24621 2003-02-02  Jim Meyering  <jim@meyering.net>
24622
24623         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
24624         e.g. glibc-2.2.93.
24625
24626 2003-01-31  Bruno Haible  <bruno@clisp.org>
24627
24628         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
24629         'rpl_rename'.
24630         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
24631         'rpl_strnlen'.
24632         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
24633         'rpl_strtod'.
24634         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
24635         'rpl_utime'.
24636
24637 2003-01-31  Bruno Haible  <bruno@clisp.org>
24638
24639         * lib/rename.c: #undef rename before defining rpl_rename.
24640         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
24641
24642 2003-01-30  Bruno Haible  <bruno@clisp.org>
24643
24644         * modules/vasnprintf, modules/vasprintf: New modules.
24645         * MODULES.html.sh (func_all_modules): Add them.
24646
24647 2003-01-30  Bruno Haible  <bruno@clisp.org>
24648
24649         * m4/signed.m4: New file, from GNU gettext.
24650         * m4/longdouble.m4: New file, from GNU gettext.
24651         * m4/wchar_t.m4: New file, from GNU gettext.
24652         * m4/wint_t.m4: New file, from GNU gettext.
24653         * m4/vasnprintf.m4: New file.
24654         * m4/vasprintf.m4: New file.
24655
24656 2003-01-30  Bruno Haible  <bruno@clisp.org>
24657
24658         * lib/printf-args.h: New file, from GNU gettext.
24659         * lib/printf-args.c: New file, from GNU gettext.
24660         * lib/printf-parse.h: New file, from GNU gettext.
24661         * lib/printf-parse.c: New file, from GNU gettext.
24662         * lib/vasnprintf.h: New file, from GNU gettext.
24663         * lib/vasnprintf.c: New file, from GNU gettext.
24664         * lib/asnprintf.c: New file, from GNU gettext.
24665         * lib/vasprintf.h: New file, from GNU gettext with modifications.
24666         * lib/vasprintf.c: New file, from GNU gettext.
24667         * lib/asprintf.c: New file, from GNU gettext.
24668
24669 2003-01-29  Bruno Haible  <bruno@clisp.org>
24670
24671         * modules/stpncpy: New module.
24672         * MODULES.html.sh (func_all_modules): Add it.
24673
24674 2003-01-29  Bruno Haible  <bruno@clisp.org>
24675
24676         * m4/stpncpy.m4: New file.
24677
24678 2003-01-29  Bruno Haible  <bruno@clisp.org>
24679
24680         * lib/stpncpy.h: New file, from GNU gettext with modifications.
24681         * lib/stpncpy.c: New file, from GNU gettext with modifications.
24682
24683 2003-01-28  Bruno Haible  <bruno@clisp.org>
24684
24685         * modules/c-ctype: New module.
24686         * MODULES.html.sh (func_all_modules): Add it.
24687
24688 2003-01-28  Bruno Haible  <bruno@clisp.org>
24689
24690         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
24691         Paul Eggert.
24692         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
24693         Paul Eggert.
24694
24695 2003-01-27  Bruno Haible  <bruno@clisp.org>
24696
24697         * modules/xsetenv: New module.
24698         * MODULES.html.sh (func_all_modules): Add it.
24699
24700 2003-01-27  Bruno Haible  <bruno@clisp.org>
24701
24702         * lib/xsetenv.h: New file, from GNU gettext.
24703         * lib/xsetenv.c: New file, from GNU gettext.
24704
24705 2003-01-23  Jim Meyering  <jim@meyering.net>
24706
24707         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
24708         from working on systems without dirfd (at least Irix and OSF1/Tru64).
24709
24710 2003-01-23  Bruno Haible  <bruno@clisp.org>
24711
24712         * modules/minmax: New module.
24713         * MODULES.html.sh (func_all_modules): Add it.
24714
24715 2003-01-23  Bruno Haible  <bruno@clisp.org>
24716
24717         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
24718         Eggert.
24719
24720 2003-01-22  Bruno Haible  <bruno@clisp.org>
24721
24722         * modules/exit: New module.
24723         * MODULES.html.sh (func_all_modules): Add it.
24724
24725 2003-01-22  Bruno Haible  <bruno@clisp.org>
24726
24727         * lib/exit.h: New file, from GNU gettext.
24728
24729 2003-01-19  Bruno Haible  <bruno@clisp.org>
24730
24731         * gnulib-tool: Recognize option --extract-maintainer.
24732         (func_get_maintainer): New function.
24733         * modules/*: Add Maintainer entry.
24734
24735 2003-01-16  Jim Meyering  <jim@meyering.net>
24736
24737         * m4/regex.m4: The `regex' struct is both input and output.
24738         Initialize it before each use.  Patch by Tim Waugh.
24739
24740 2003-01-16  Bruno Haible  <bruno@clisp.org>
24741
24742         * MODULES.html.sh: Add a table of contents. Add the module name as
24743         leftmost column. Add hyperlinks.
24744
24745 2003-01-15  Bruno Haible  <bruno@clisp.org>
24746
24747         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
24748
24749 2003-01-15  Bruno Haible  <bruno@clisp.org>
24750
24751         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
24752         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
24753         suffix.
24754
24755 2003-01-15  Bruno Haible  <bruno@clisp.org>
24756
24757         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
24758
24759 2003-01-15  Bruno Haible  <bruno@clisp.org>
24760
24761         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
24762         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
24763
24764 2003-01-14  Jim Meyering  <jim@meyering.net>
24765
24766         * lib/same.c (same_name): Tweak a comment.
24767
24768 2003-01-14  Bruno Haible  <bruno@clisp.org>
24769
24770         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
24771         when a string comparison is sufficient.
24772
24773 2003-01-14  Bruno Haible  <bruno@clisp.org>
24774
24775         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
24776         'unsigned int'.
24777
24778 2003-01-14  Bruno Haible  <bruno@clisp.org>
24779
24780         * lib/hash-pjw.c: Add comment about low quality of this function.
24781
24782 2003-01-13  Bruno Haible  <bruno@clisp.org>
24783
24784         * modules/stpcpy: Distribute lib/stpcpy.h.
24785         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
24786
24787 2003-01-13  Bruno Haible  <bruno@clisp.org>
24788
24789         * modules/*: Add a description.
24790         * modules/strpbrk: Fix Makefile.am snippet.
24791         * modules/strtoimax: Fix dependencies.
24792         * modules/strtoumax: Likewise.
24793
24794 2003-01-13  Bruno Haible  <bruno@clisp.org>
24795
24796         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
24797         * modules/alloca (Makefile.am): All object files depend on alloca.h.
24798         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
24799
24800 2003-01-13  Bruno Haible  <bruno@clisp.org>
24801
24802         * gnulib-tool (func_create_testdir): Store config/* files in the main
24803         directory.
24804         * config.rpath: Move to ...
24805         * config/config.rpath: ... here.
24806         * modules/gettext: Contains config/config.rpath, not config.rpath.
24807         * modules/iconv: Likewise.
24808
24809 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24810
24811         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24812         to avoid collisions with libcurses and libreadline.
24813
24814         * m4/getstr.m4: Remove.
24815         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
24816
24817 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24818
24819         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24820         to avoid collisions with libcurses and libreadline.
24821
24822         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
24823         * lib/getstr.h, getstr.c: Remove.
24824         * lib/getline.c: Include "getline.h", to check interface.
24825         Move body of old getstr.c here: this defines MIN_CHUNK and
24826         declares getdelim2, which is renamed from getstr.
24827         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
24828
24829         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
24830         All uses changed.
24831         * lib/linebuffer.h: Likewise.
24832         (readline): Remove backward-compatibility macro.
24833
24834 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24835
24836         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24837         to avoid collisions with libcurses and libreadline.
24838         * getstr: Remove.
24839         * MODULES.html.sh: Remove getstr.
24840         * modules/getline: Depend on unlocked-io, not getstr.
24841
24842 2003-01-12  Jim Meyering  <jim@meyering.net>
24843
24844         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
24845
24846 2003-01-10  Bruno Haible  <bruno@clisp.org>
24847
24848         * modules/alloca: Change Makefile.am requirements. Simplify Include
24849         requirements. Add lib/alloca_.h to file list.
24850
24851 2003-01-10  Bruno Haible  <bruno@clisp.org>
24852
24853         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
24854
24855 2003-01-10  Bruno Haible  <bruno@clisp.org>
24856
24857         * lib/alloca_.h: New file.
24858         * lib/getdate.y: Unconditionally include alloca.h.
24859         * lib/makepath.c: Likewise.
24860         * lib/setenv.c: Likewise.
24861         * lib/userspec.c: Likewise.
24862
24863 2003-01-09  Karl Berry  <karl@gnu.org>
24864
24865         * MODULES.html.sh: include `dirname $0` in PATH, to find
24866         gnulib-tool.
24867
24868 2003-01-09  Bruno Haible  <bruno@clisp.org>
24869
24870         * modules/stdbool: Change configure.ac, Makefile.am requirements.
24871         Simplify Include requirements. Add lib/stdbool.h.in to file list.
24872
24873 2003-01-09  Bruno Haible  <bruno@clisp.org>
24874
24875         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
24876
24877 2003-01-09  Bruno Haible  <bruno@clisp.org>
24878
24879         * lib/stdbool.h.in: New file.
24880
24881 2003-01-09  Bruno Haible  <bruno@clisp.org>
24882
24883         * gnulib-tool (func_all_modules): Ignore files ending in ~.
24884         * MODULES.html.sh: Likewise.
24885
24886 2003-01-08  Jim Meyering  <jim@meyering.net>
24887
24888         * lib/full-write.c: Undefine and define-away `const' after inclusion
24889         of errno.h, not before.  Suggestion from Bruno Haible.
24890
24891 2003-01-08  Bruno Haible  <bruno@clisp.org>
24892
24893         * modules/full-read: Depend on full-write.
24894
24895 2003-01-08  Bruno Haible  <bruno@clisp.org>
24896
24897         * lib/safe-read.c: Include specification header first, to ensure its
24898         selfcontainedness.
24899         * lib/full-write.c: Likewise.
24900
24901 2003-01-07  Jim Meyering  <jim@meyering.net>
24902
24903         * lib/full-write.c: Rework so that it may serve to define full_read,
24904         too.
24905         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
24906
24907 2003-01-07  Bruno Haible  <bruno@clisp.org>
24908
24909         * lib/strtoimax.c: Include <stdint.h> as an alternative to
24910         <inttypes.h>.
24911         * lib/xstrtol.h: Likewise.
24912         * lib/xstrtoimax.c: Likewise.
24913         * lib/xstrtoumax.c: Likewise.
24914         * lib/human.h: Likewise.
24915
24916         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
24917         on systems that have <inttypes.h> but not <stdint.h>.
24918
24919 2003-01-07  Bruno Haible  <bruno@clisp.org>
24920
24921         * MODULES.html.sh: Add copyright notice.
24922         (missed_files): Omit CVS directory entries.
24923         (func_module): Make it work with sed-3.02.
24924         * MODULES.txt: Remove file.
24925
24926 2003-01-06  Jim Meyering  <jim@meyering.net>
24927
24928         * lib/version-etc.c: Update year in translatable copyright string.
24929
24930 2003-01-03  Karl Berry  <karl@gnu.org>
24931
24932         * config/config.{guess,sub}: update from prep.
24933
24934 2003-01-02  Karl Berry  <karl@gnu.org>
24935
24936         * doc/COPYING.DOC: belatedly updated to 1.2.
24937
24938 2003-01-01  Karl Berry  <karl@gnu.org>
24939
24940         * gnulib-tool (func_verify_module): report module name $module in
24941         error message, not $1.
24942         * gnulib-tool (create-testdir): don't complain if destdir couldn't
24943         be created, only if it doesn't exist.
24944         * gnulib-tool (last_checkin_date): don't expand the $Date here.
24945
24946 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24947
24948         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
24949
24950 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24951
24952         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
24953         memcmp if strcoll doesn't work.
24954
24955 2002-12-31  Bruno Haible  <bruno@clisp.org>
24956
24957         * lib/utime.c (utime_null): No need to call ftruncate if the file was
24958         nonempty.
24959
24960 2002-12-31  Bruno Haible  <bruno@clisp.org>
24961
24962         * lib/memcoll.c (STRCOLL): New macro.
24963         (memcoll): Use it.
24964
24965 2002-12-31  Bruno Haible  <bruno@clisp.org>
24966
24967         * lib/localcharset.h: New file.
24968         * lib/localcharset.c: Include it.
24969         * lib/unicodeio.c: Likewise.
24970
24971 2002-12-31  Bruno Haible  <bruno@clisp.org>
24972
24973         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
24974         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
24975
24976 2002-12-31  Bruno Haible  <bruno@clisp.org>
24977
24978         * lib/getline.h: Include <stddef.h>, for size_t.
24979
24980         * lib/unicodeio.h: Include <stddef.h>, for size_t.
24981         * lib/unicodeio.c: Don't include <stddef.h>.
24982
24983 2002-12-31  Bruno Haible  <bruno@clisp.org>
24984
24985         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
24986         HAVE_TM_ZONE.
24987
24988 2002-12-24  Karl Berry  <karl@gnu.org>
24989
24990         * config/config.guess: update from prep.
24991
24992 2002-12-24  Bruno Haible  <bruno@clisp.org>
24993
24994         General infrasructure.
24995         * m4/README: Rewritten.
24996         * m4/onceonly.m4: New file.
24997         * m4/onceonly_2_57.m4: New file.
24998
24999         Module atexit.
25000         * m4/atexit.m4: New file.
25001
25002         Module strtod.
25003         * m4/strtod.m4: New file.
25004
25005         Module strtol.
25006         * m4/strtol.m4: New file.
25007
25008         Module strtoul.
25009         * m4/strtoul.m4: New file.
25010
25011         Module memchr.
25012         * m4/memchr.m4: New file.
25013
25014         Module memcmp.
25015         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
25016         (jm_FUNC_MEMCMP): Invoke it.
25017
25018         Module memcpy.
25019         * m4/memcpy.m4: New file.
25020
25021         Module memmove.
25022         * m4/memmove.m4: New file.
25023
25024         Module memset.
25025         * m4/memset.m4: New file.
25026
25027         Module strcspn.
25028         * m4/strcspn.m4: New file.
25029
25030         Module strpbrk.
25031         * m4/strpbrk.m4: New file.
25032
25033         Module strstr.
25034         * m4/strstr.m4: New file.
25035
25036         Module strerror.
25037         * m4/strerror.m4: New file.
25038
25039         Module mktime.
25040         * m4/mktime.m4: Renamed from jm-mktime.m4.
25041         (gl_PREREQ_MKTIME): New macro.
25042         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
25043
25044         Module malloc.
25045         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
25046         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
25047         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
25048
25049         Module realloc.
25050         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
25051         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
25052         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
25053
25054         Module strftime.
25055         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
25056         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
25057         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
25058         gl_TM_GMTOFF.
25059         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
25060
25061         Module xalloc.
25062         * m4/xalloc.m4: New file.
25063
25064         Module alloca.
25065         * m4/alloca.m4: New file.
25066
25067         Module putenv.
25068         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
25069         (jm_FUNC_PUTENV): Invoke it.
25070
25071         Module setenv.
25072         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
25073         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
25074         when invoked twice.
25075         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
25076         gt_FUNC_SETENV.
25077
25078         Module memrchr.
25079         * m4/memrchr.m4: New file.
25080
25081         Module stpcpy.
25082         * m4/stpcpy.m4: New file.
25083
25084         Module strcase.
25085         * m4/strcase.m4: New file.
25086
25087         Module strdup.
25088         * m4/strdup.m4: New file.
25089
25090         Module strnlen.
25091         * m4/strnlen.m4: New file.
25092
25093         Module strndup.
25094         * m4/strndup.m4: New file.
25095
25096         Module xstrtod.
25097         * m4/xstrtod.m4: New file.
25098
25099         Module xstrtol.
25100         * m4/xstrtol.m4: New file.
25101
25102         Module getdate.
25103         * m4/getdate.m4: New file.
25104
25105         Module unlocked-io.
25106         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
25107         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
25108         * m4/jm-glibc-io.m4n: Remove file.
25109
25110         Module long-options.
25111         * m4/long-options.m4: New file.
25112
25113         Module md5.
25114         * m4/md5.m4: New file.
25115
25116         Module sha.
25117         * m4/sha.m4: New file.
25118
25119         Module getstr.
25120         * m4/getstr.m4: New file.
25121
25122         Module getline.
25123         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
25124         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
25125         <sys/types.h>, for size_t. Use the function name gnu_getline, not
25126         simply getline. Infoke gl_PREREQ_GETLINE.
25127
25128         Module obstack.
25129         * m4/obstack.m4: New file.
25130
25131         Module hash.
25132         * m4/hash.m4: New file.
25133
25134         Module readtokens.
25135         * m4/readtokens.m4: New file.
25136
25137         Module strverscmp.
25138         * m4/strverscmp.m4: New file.
25139
25140         Module stdbool.
25141         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
25142         OSF/1.
25143
25144         Module strtoll.
25145         * m4/strtoll.m4: New file.
25146
25147         Module strtoull.
25148         * m4/strtoull.m4: New file.
25149
25150         Module strtoimax.
25151         * m4/strtoimax.m4: New file.
25152
25153         Module strtoumax.
25154         * m4/strtoumax.m4: New file.
25155
25156         Module xstrtoimax.
25157         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
25158         jm_AC_PREREQ_XSTRTOIMAX.
25159         Moved the strtol prerequisites to strtol.m4.
25160         Moved the strtoll prerequisites to strtoll.m4.
25161         Moved the strtoimax prerequisites to strtoimax.m4.
25162
25163         Module xstrtoumax.
25164         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
25165         jm_AC_PREREQ_XSTRTOUMAX.
25166         Moved the strtoul prerequisites to strtoul.m4.
25167         Moved the strtoull prerequisites to strtoull.m4.
25168         Moved the strtoumax prerequisites to strtoumax.m4.
25169
25170         Module chown.
25171         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
25172         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
25173
25174         Module dup2.
25175         * m4/dup2.m4: New file.
25176
25177         Module ftruncate.
25178         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
25179         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
25180
25181         Module getgroups.
25182         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
25183         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
25184
25185         Module gettimeofday.
25186         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
25187         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
25188         gl_PREREQ_GETTIMEOFDAY.
25189
25190         Module mkdir.
25191         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
25192         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
25193
25194         Module mkstemp.
25195         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
25196         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
25197         jm_AC_TYPE_UINTMAX_T.
25198         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
25199
25200         Module stat.
25201         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
25202         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
25203
25204         Module lstat.
25205         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
25206         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
25207
25208         Module timespec.
25209         * m4/timespec.m4 (gl_TIMESPEC): New macro.
25210         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
25211         * m4/st_mtim.m4: Indentation.
25212
25213         Module nanosleep.
25214         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
25215         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
25216         gl_PREREQ_NANOSLEEP.
25217
25218         Module regex.
25219         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
25220         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
25221         (gl_REGEX): New macro.
25222
25223         Module rename.
25224         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
25225         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
25226
25227         Module rmdir.
25228         * m4/rmdir.m4: New file.
25229
25230         Module utime.
25231         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
25232         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
25233         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
25234
25235         Module dirname.
25236         * m4/dirname.m4: New file.
25237
25238         Module getopt.
25239         * m4/getopt.m4: New file.
25240
25241         Module unistd-safer.
25242         * m4/unistd-safer.m4: New file.
25243
25244         Module fnmatch.
25245         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
25246         declaration.
25247         (gl_PREREQ_FNMATCH_EXTRA): New macro.
25248         (gl_FUNC_FNMATCH_POSIX): New macro.
25249         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
25250         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
25251         simply fnmatch.
25252
25253         Module exclude.
25254         * m4/exclude.m4: New file.
25255
25256         Module human.
25257         * m4/human.m4: New file.
25258
25259         Module acl.
25260         * m4/acl.m4: Nop.
25261
25262         Module backupfile.
25263         * m4/backupfile.m4: New file.
25264         * m4/d-ino.m4: Indentation.
25265
25266         Module fsusage.
25267         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
25268         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
25269         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
25270
25271         Module dirfd.
25272         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
25273         requirements.
25274
25275         Module euidaccess.
25276         * m4/euidaccess.m4: New file.
25277
25278         Module file-type.
25279         * m4/file-type.m4: New file.
25280
25281         Module fileblocks.
25282         * m4/fileblocks.m4: New file.
25283
25284         Module filemode.
25285         * m4/filemode.m4: New file.
25286
25287         Module isdir.
25288         * m4/isdir.m4: New file.
25289
25290         Module lchown.
25291         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
25292         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
25293
25294         Module makepath.
25295         * m4/makepath.m4: New file.
25296
25297         Module modechange.
25298         * m4/modechange.m4: New file.
25299
25300         Module mountlist.
25301         * m4/mountlist.m4: New file.
25302         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
25303         Indentation.
25304
25305         Module path-concat.
25306         * m4/path-concat.m4: New file.
25307
25308         Module pathmax.
25309         * m4/pathmax.m4: New file.
25310
25311         Module same.
25312         * m4/same.m4: New file.
25313
25314         Module save-cwd.
25315         * m4/save-cwd.m4: New file.
25316
25317         Module savedir.
25318         * m4/savedir.m4: New file.
25319
25320         Module xgetcwd.
25321         * m4/xgetcwd.m4: New file.
25322         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
25323
25324         Module xreadlink.
25325         * m4/xreadlink.m4: New file.
25326
25327         Module safe-read.
25328         * m4/safe-read.m4: New file.
25329
25330         Module safe-write.
25331         * m4/safe-write.m4: New file.
25332
25333         Module closeout.
25334         * m4/closeout.m4: New file.
25335
25336         Module stdio-safer.
25337         * m4/stdio-safer.m4: New file.
25338
25339         Module getpass.
25340         * m4/getpass.m4: New file.
25341
25342         Module getugroups.
25343         * m4/getugroups.m4: New file.
25344
25345         Module group-member.
25346         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
25347         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
25348
25349         Module idcache.
25350         * m4/idcache.m4: New file.
25351
25352         Module userspec.
25353         * m4/userspec.m4: New file.
25354
25355         Module gettime.
25356         * m4/clock_time.m4: New file.
25357         * m4/gettime.m4: New file.
25358
25359         Module settime.
25360         * m4/settime.m4: New file.
25361
25362         Module posixtm.
25363         * m4/posixtm.m4: New file.
25364
25365         Module gethostname.
25366         * m4/gethostname.m4: New file.
25367
25368         Module canon-host.
25369         * m4/canon-host.m4: New file.
25370
25371         Module gettext.
25372         * m4/codeset.m4: New file, from gettext-0.11.5.
25373         * m4/gettext.m4: New file, from gettext-0.11.5.
25374         * m4/glibc21.m4: New file, from gettext-0.11.5.
25375         * m4/iconv.m4: New file, from gettext-0.11.5.
25376         * m4/intdiv0.m4: New file, from gettext-0.11.5.
25377         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
25378         * m4/inttypes.m4: New file, from gettext-0.11.5.
25379         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
25380         * m4/isc-posix.m4: New file, from gettext-0.11.5.
25381         * m4/lcmessage.m4: New file, from gettext-0.11.5.
25382         * m4/lib-ld.m4: New file, from gettext-0.11.5.
25383         * m4/lib-link.m4: New file, from gettext-0.11.5.
25384         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
25385         * m4/progtest.m4: New file, from gettext-0.11.5.
25386         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
25387         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
25388         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
25389
25390         Module localcharset.
25391         * m4/localcharset.m4: New file.
25392
25393         Module hard-locale.
25394         * m4/hard-locale.m4: New file.
25395
25396         Module mbswidth.
25397         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
25398         onceonly macros.
25399         * m4/mbrtowc.m4: Add comment.
25400
25401         Module memcasecmp.
25402         * m4/memcasecmp.m4: New file.
25403
25404         Module memcoll.
25405         * m4/memcoll.m4: New file.
25406
25407         Module unicodeio.
25408         * m4/unicodeio.m4: New file.
25409
25410         Module rpmatch.
25411         * m4/rpmatch.m4: New file.
25412
25413         Module yesno.
25414         * m4/yesno.m4: New file.
25415
25416         Module exitfail.
25417         * m4/exitfail.m4: New file.
25418
25419         Module c-stack.
25420         * m4/c-stack.m4 (gl_C_STACK): New macro.
25421         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
25422
25423         Module error.
25424         * m4/error.m4 (gl_ERROR): New macro.
25425         (jm_PREREQ_ERROR): Use onceonly macros.
25426
25427         Module fatal.
25428         * m4/fatal.m4: New file.
25429
25430         Module getloadavg.
25431         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
25432         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
25433
25434         Module getpagesize.
25435         * m4/getpagesize.m4: New file.
25436
25437         Module getusershell.
25438         * m4/getusershell.m4: New file.
25439
25440         Module physmem.
25441         * m4/physmem.m4: New file.
25442
25443         Module posixver.
25444         * m4/posixver.m4: New file.
25445
25446         Module quotearg.
25447         * m4/quotearg.m4: New file.
25448
25449         Module quote.
25450         * m4/quote.m4: New file.
25451
25452         Module readutmp.
25453         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
25454
25455         Module sig2str.
25456         * m4/sig2str.m4: New file.
25457
25458         Other.
25459         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
25460         ulonglong.m4.
25461         * m4/intmax_t.m4: New file.
25462         * m4/d-type.m4: Indentation.
25463         * m4/jm-macros.m4: Update.
25464         * m4/prereq.m4 (jm_PREREQ): Update.
25465         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
25466         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
25467         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
25468         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
25469         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
25470         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
25471         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
25472         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
25473         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
25474         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
25475         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
25476         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
25477         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
25478         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
25479         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
25480         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
25481         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
25482         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
25483         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
25484
25485 2002-12-24  Bruno Haible  <bruno@clisp.org>
25486
25487         * MODULES.txt: Update according to m4/ changes.
25488
25489         Module gettext.
25490         * config.rpath: New file, from gettext-0.11.5.
25491
25492         * modules/*: New module descriptions.
25493         * gnulib-tool: New file.
25494         * MODULES.html.sh: New file.
25495
25496 2002-12-21  Karl Berry  <karl@gnu.org>
25497
25498         * doc/fdl.texi: update to version 1.2.
25499
25500 2002-12-19  Karl Berry  <karl@gnu.org>
25501
25502         * config/config.guess: update from prep.
25503
25504 2002-12-18  Bruno Haible  <bruno@clisp.org>
25505
25506         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
25507         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
25508
25509 2002-12-17  Bruno Haible  <bruno@clisp.org>
25510
25511         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
25512         stdlib.h, string.h.
25513
25514 2002-12-17  Bruno Haible  <bruno@clisp.org>
25515
25516         * lib/canon-host.c (strdup): Remove unused declaration.
25517
25518         * lib/fsusage.c: Include full_read.h.
25519         (get_fs_usage): Use full_read instead of safe_read.
25520
25521         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
25522
25523 2002-12-12  Karl Berry  <karl@gnu.org>
25524
25525         * config/config.guess: update from prep.
25526
25527 2002-12-11  Bruno Haible  <bruno@clisp.org>
25528
25529         * m4/setenv.m4: New file, from gettext-0.11.5.
25530
25531 2002-12-11  Bruno Haible  <bruno@clisp.org>
25532
25533         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
25534         not unsetenv().
25535         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
25536         modifications:
25537
25538         2002-12-11  Bruno Haible  <bruno@clisp.org>
25539
25540                 * setenv.c (alloca): Fall back to malloc.
25541                 (freea): New macro.
25542                 (setenv): Use freea() to free memory allocated with alloca().
25543
25544         2002-11-13  Bruno Haible  <bruno@clisp.org>
25545
25546                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
25547                 function declarations.
25548                 * unsetenv.c (unsetenv): Likewise.
25549
25550         2002-03-04  Bruno Haible  <bruno@clisp.org>
25551
25552                 Portability to AIX 4.3.3.
25553                 * unsetenv.c: New file, extracted from setenv.c.
25554                 * setenv.c: Move the unsetenv() function to unsetenv.c.
25555
25556         2001-12-20  Bruno Haible  <bruno@clisp.org>
25557
25558                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
25559                 use malloc instead. For SunOS 4.
25560
25561         2001-12-11  Bruno Haible  <bruno@clisp.org>
25562
25563                 * setenv.c: Declare alloca.
25564                 (compar_fn_t): New typedef.
25565                 (KNOWN_VALUE, STORE_VALUE): Use it.
25566
25567         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
25568         setenv.h.
25569
25570 2002-12-10  Paul Eggert  <eggert@twinsun.com>
25571
25572         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
25573         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
25574         Choose values that are less likely to collide with system fnmatch
25575         options.
25576         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
25577         defined (e.g., a pure POSIX system).
25578         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
25579         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
25580
25581 2002-12-06  Paul Eggert  <eggert@twinsun.com>
25582
25583         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
25584         a pain in practice to deal with generated m4 files.  This change
25585         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
25586
25587         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
25588         and jm-glibc-io.m4, as they are no longer a special case.
25589         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
25590         kludge and the auto-generation stuff.  Check only whether the
25591         functions are declared, not whether they exist, since older hosts
25592         that don't declare the functions can't use the optimization anyway.
25593
25594 2002-12-06  Jim Meyering  <jim@meyering.net>
25595
25596         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
25597
25598         Merge in changes from libc's misc/error.c, in preparation
25599         for the merge of gnulib's changes back into libc.
25600
25601         * lib/error.c (_): Define only if not already defined.
25602         Move definition to follow all #include directives.
25603         Include unlocked-io.h only if !_LIBC.
25604         [_LIBC]: Include <libio/libioP.h>.
25605         [USE_IN_LIBIO]: Include <libio/iolibio.h>
25606         (fflush): Tweak definition to use INTUSE.
25607         (putc): Define.
25608
25609 2002-12-05  Paul Eggert  <eggert@twinsun.com>
25610
25611         * lib/alloca.c [defined emacs]: Include "lisp.h".
25612         (xalloc_die) [defined emacs]: New macro.
25613         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
25614         [! defined emacs]: Include <xalloc.h>.
25615         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
25616         (pointer): Typedef to POINTER_TYPE *.
25617         (malloc): Remove decl; we now always use xmalloc.
25618         (alloca): Use old-style definition, since Emacs needs this.
25619         Check for arithmetic overflow when computing combined size.
25620
25621 2002-12-04  Paul Eggert  <eggert@twinsun.com>
25622
25623         Do not generate unlocked-io.h automatically, since it's easier to
25624         maintain it by hand.
25625
25626         * lib/unlocked-io.h: New file, from GNU diffutils,
25627         but with proper copyright notice and attribution.
25628         * lib/gen-uio: Remove.
25629         * lib/Makefile.am: Add copyright notice.
25630         (libfetish_a_SOURCES): Add unlocked-io.h.
25631         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
25632         (DISTCLEANFILES, io_functions): Remove macros.
25633         (EXTRA_DIST): Remove gen_uio.
25634         (unlocked-io.h): Remove rule.
25635
25636 2002-12-04  Jim Meyering  <jim@meyering.net>
25637
25638         Reflect the fact that stat.c and lstat.c are no longer generated.
25639         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
25640         (DISTCLEANFILES): Likewise.
25641         (EXTRA_DIST): Likewise.
25642         (all_local): Don't depend on stat.c or lstat.c.
25643         (stat.c, lstat.c): Remove rules.
25644         (EXTRA_DIST): Remove xstat.in.
25645
25646         * lib/xstat.in: Remove file.  Contents moved into stat.c.
25647         * lib/stat.c: New file.  Contents mostly from xstat.in.
25648         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
25649         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
25650
25651         * lib/safe-read.c: Rework so that it may serve to define safe_write,
25652         too.
25653         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
25654
25655 2002-12-03  Jim Meyering  <jim@meyering.net>
25656
25657         * lib/safe-read.c, safe-write.c: Change variable names and comments,
25658         but not semantics, to minimize the differences between these two files.
25659         (safe_read): Change comment to mention SAFE_READ_ERROR.
25660
25661         * lib/safe-read.c (IS_EINTR): Define.
25662         (safe_read): Use IS_EINTR in place of in-function cpp directives.
25663
25664 2002-12-02  Jim Meyering  <jim@meyering.net>
25665
25666         * lib/safe-read.c (EINTR): Define.
25667         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
25668         (INT_MAX): Provide fallback.
25669         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
25670
25671         * lib/safe-read.h (SAFE_READ_ERROR): Define.
25672
25673 2002-12-02  Bruno Haible  <bruno@clisp.org>
25674
25675         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
25676         Define, taken from safe-read.c.
25677         (INT_MAX): Provide fallback.
25678         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
25679         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
25680
25681         * lib/safe-read.c (EINTR): Remove definition.
25682         (safe_read): Don't use EINTR if it is absent.
25683
25684 2002-12-01  Jim Meyering  <jim@meyering.net>
25685
25686         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
25687         zero.
25688         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
25689
25690 2002-11-27  Paul Eggert  <eggert@twinsun.com>
25691
25692         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
25693         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
25694         with `if (! (value < limit)) abort ();', for readability.
25695
25696 2002-11-26  Karl Berry  <karl@gnu.org>
25697
25698         * lib/strdup.c: copy from libc again, with jim's ok.
25699         * lib/.cppi-disable: re-add strdup.c
25700
25701 2002-11-25  Karl Berry  <karl@gnu.org>
25702
25703         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
25704         instead of "strtol.c".
25705
25706 2002-11-25  Karl Berry  <karl@gnu.org>
25707
25708         * config/install-sh: update from automake for variable quoting, $0 in
25709         error msgs, etc.
25710
25711         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
25712         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
25713         entry.
25714
25715 2002-11-25  Jim Meyering  <jim@meyering.net>
25716
25717         * lib/mktime.c: Sync from libc, now that it has the latest fix.
25718
25719 2002-11-24  Karl Berry  <karl@gnu.org>
25720
25721         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
25722         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
25723
25724 2002-11-24  Jim Meyering  <jim@meyering.net>
25725
25726         Update from coreutils:
25727
25728         * lib/mktime.c: Merge in changes from libc.
25729
25730         Avoid a link-time failure on some Linux systems.
25731         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
25732         (otherwise).
25733         (__mon_yday): Declare with the STATIC attribute.
25734         (__mktime_internal): Likewise.
25735         Based on a report from Greg Schafer.
25736
25737 2002-11-23  Jim Meyering  <jim@meyering.net>
25738
25739         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
25740         Use `unsigned', not `int', as type of index.
25741
25742         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
25743
25744         * lib/fsusage.c: Remove unneeded parentheses around operands of
25745         `defined'.
25746
25747 2002-11-22  Paul Eggert  <eggert@twinsun.com>
25748
25749         * lib/quotearg.h: Allow multiple inclusion by surrounding with
25750         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
25751         so that we can be included first.
25752         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
25753         * lib/quotearg.c: Include quotearg.h immediately after config.h.
25754         No need to include stddef.h or sys/types.h any more.
25755         Surround local include files with "", not "<>".
25756         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
25757         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
25758         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
25759         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
25760         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
25761         (ISPRINT): Remove; no longer needed now that we assume C89.
25762
25763         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
25764         Preserve errno.
25765
25766         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
25767         quotearg_char): Use SIZE_MAX rather than
25768         (size_t) -1 when we are talking about "infinity".
25769
25770         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
25771
25772 2002-11-22  Paul Eggert  <eggert@twinsun.com>
25773
25774         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
25775         hint that one should use `if (! x) abort ();' rather than `assert
25776         (x);', and anyway it's one less thing to worry about configuring.
25777         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
25778         hash_rehash, hash_insert): Use abort rather than assert.
25779
25780 2002-11-22  Bruno Haible  <bruno@clisp.org>
25781
25782         * lib/safe-read.h: Assume C89. Add comments.
25783         (safe_read): Change return type to size_t.
25784         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
25785         byte counts > SSIZE_MAX correctly.
25786         * lib/safe-write.h: New file.
25787         * lib/safe-write.c: New file.
25788         * lib/full-read.h: New file.
25789         * lib/full-read.c: New file.
25790         * lib/full-write.h: Assume C89. Add comments.
25791         * lib/full-write.c: Include safe-write.h.
25792         (full_write): Rewritten to use safe_write.
25793         Suggested by Jim Meyering and Paul Eggert.
25794
25795 2002-11-21  Jim Meyering  <jim@meyering.net>
25796
25797         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
25798
25799         Merge in changes from the coreutils.
25800
25801         2002-09-25  Paul Eggert  <eggert@twinsun.com>
25802         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
25803         <stdint.h>.
25804         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
25805         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
25806         int.  Work more efficiently if X is the same width as uintmax_t.
25807         Do not compare X to -1, to avoid bogus compiler warning.
25808         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
25809         Don't assume that f_frsize and f_bsize are the same type.
25810
25811         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
25812         warning on FreeBSD.
25813
25814         * lib/makepath.c (make_path): Restore umask *before* creating the final
25815         component.
25816         (make_path): Minor reformatting.
25817
25818         * lib/xmalloc.c: Adjust to work with new autoconf macros,
25819         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
25820         HAVE_MALLOC/HAVE_REALLOC.
25821
25822         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
25823         dummy ones.  At least on GNU/Linux systems, `auto' means something
25824         else.
25825         From Michael Stone.
25826
25827 2002-11-21  Bruno Haible  <bruno@clisp.org>
25828
25829         Remove case insensitive option matching.
25830         * lib/argmatch.h (argcasematch): Remove declaration.
25831         (ARGCASEMATCH): Remove macro.
25832         (__xargmatch_internal): Remove case_sensitive argument.
25833         (XARGMATCH): Update.
25834         (XARGCASEMATCH): Remove macro.
25835         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
25836         case_sensitive argument.
25837         (argcasematch): Remove function.
25838         (__xargmatch_internal): Remove case_sensitive argument.
25839         (main): Use XARGMATCH instead of XARGCASEMATCH.
25840
25841         * lib/xmalloc.c: Change compile-time error message. Add comment about
25842         required autoconf version.
25843
25844 2002-11-20  Paul Eggert  <eggert@twinsun.com>
25845
25846         Merge argmatch cleanups from Bison.  Assume C89.
25847
25848         * lib/argmatch.c: Include config.h here, not in argmatch.h.
25849         Include stdlib.h, for EXIT_FAILURE.
25850         Always include <string.h>, since we assume C89.
25851         (EXIT_FAILURE): Remove pre-C89 bug workaround.
25852         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
25853         Include <stddef.h> instead, since it's all we need for size_t.
25854         (PARAMS): Remove.  All uses removed.
25855         (ARRAY_CARDINALITY): Do not bother to #undef.
25856         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
25857         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25858         Remove unnecessary parentheses.
25859         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25860         Insert necessary parentheses.
25861         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
25862         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
25863
25864 2002-11-19  Bruno Haible  <bruno@clisp.org>
25865
25866         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
25867         * lib/mbswidth.h: Include <stddef.h>, for size_t.
25868
25869         * lib/mbswidth.h (PARAMS): Remove macro.
25870         (mbswidth, mbsnwidth): Use ANSI C function declarations.
25871         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
25872
25873         * lib/gcd.h (PARAMS): Remove macro.
25874         (gcd): Use ANSI C function declarations.
25875         * lib/gcd.c (gcd): Likewise.
25876
25877 2002-11-15  Bruno Haible  <bruno@clisp.org>
25878
25879         * lib/strcspn.c: Include <stddef.h>.
25880         (strcspn): Use ANSI C function declaration. Change return type to
25881         size_t. Use NULL.
25882         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
25883         (strpbrk): Use NULL.
25884         * lib/strpbrk.h (PARAMS): Remove macro.
25885         (strpbrk): Use ANSI C function declaration.
25886         * lib/strstr.c: Don't include <sys/types.h>.
25887         * lib/strstr.h (PARAMS): Remove macro.
25888         (strstr): Use ANSI C function declarations.
25889
25890 2002-11-14  Karl Berry  <karl@gnu.org>
25891
25892         * config/mkinstalldirs: `do' on separate line, instead of
25893         `for var; do'.
25894
25895 2002-11-06  Bruno Haible  <bruno@clisp.org>
25896
25897         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
25898         * lib/gcd.c (gcd): Likewise.
25899
25900 2002-11-05  Bruno Haible  <bruno@clisp.org>
25901
25902         * lib/gcd.h: New file, from gettext-0.11.5.
25903         * lib/gcd.c: New file, from gettext-0.11.5.
25904
25905 2002-11-05  Bruno Haible  <bruno@clisp.org>
25906
25907         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25908         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25909         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25910         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25911
25912         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
25913         <libintl.h>.
25914         * lib/makepath.c: Include gettext.h instead of <locale.h> and
25915         <libintl.h>.
25916
25917         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
25918         * lib/human.c: Include gettext.h instead of <libintl.h>.
25919         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
25920         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
25921         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
25922         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
25923         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
25924         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
25925         (textdomain): Remove definition.
25926         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
25927
25928         * lib/long-options.c: Remove include of <libintl.h> and definition of
25929         _.
25930         * lib/same.c: Remove include of <libintl.h> and definition of _.
25931
25932 2002-11-04  Owen Taylor  <otaylor@redhat.com>
25933
25934         * lib/config.charset: A few additions for Solaris.
25935
25936 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25937
25938         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
25939         * lib/localcharset.c (locale_charset): Declare as extern "C".
25940
25941 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25942
25943         * lib/config.charset: msdos in uk_UA uses CP1125.
25944
25945 2002-11-04  Bruno Haible  <bruno@clisp.org>
25946
25947         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
25948         * lib/strcase.h: New file, from GNU gettext-0.11.5.
25949         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
25950         * lib/strstr.h: New file, from GNU gettext-0.11.5.
25951         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
25952
25953 2002-11-04  Bruno Haible  <bruno@clisp.org>
25954
25955         * lib/localcharset.c (locale_charset): Don't return an empty string.
25956
25957 2002-11-04  Bruno Haible  <bruno@clisp.org>
25958
25959         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
25960         aliases.
25961
25962 2002-11-04  Bruno Haible  <bruno@clisp.org>
25963
25964         * lib/config.charset: Update for newest glibc. Add canonical names
25965         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
25966
25967 2002-11-04  Bruno Haible  <bruno@clisp.org>
25968
25969         * lib/config.charset: Add support for NetBSD.
25970
25971 2002-11-04  Bruno Haible  <bruno@clisp.org>
25972
25973         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
25974
25975 2002-11-01  Bruno Haible  <bruno@clisp.org>
25976
25977         * configure.in: Add AC_CONFIG_AUX_DIR call.
25978         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
25979         test/Makefile.
25980         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
25981
25982 2002-09-28  Karl Berry  <karl@gnu.org>
25983
25984         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
25985         installed automake until the next release, since changes have been
25986         made.
25987
25988 2002-09-25  Karl Berry  <karl@gnu.org>
25989
25990         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
25991         * lib/getopt*: copy from libc/posix.
25992         * lib/gettext.h: copy from gettext.
25993         * lib/.cppi-disable: add strdup.c, gettext.h.
25994
25995 2002-09-25  Karl Berry  <karl@gnu.org>
25996
25997         * config/srclist.txt: enable gettext.h check.
25998         * config/config.{guess,sub}: update from prep.
25999         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
26000                 from automake 1.6.3.
26001         See srclist*.
26002
26003 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
26004
26005         * regex.c (PATFETCH): Remove the translating fetch.
26006         (PATFETCH_RAW): Rename to PATFETCH.
26007         (set_image_of_range): New fun.
26008         (SET_RANGE_TABLE_WORK_AREA): Use it.
26009         (regex_compile): Don't translate the pattern chars so eagerly.
26010         Only do it when inserting an `exactn' bytecode or when handling
26011         a char-range.
26012         (mutually_exclusive_p): Avoid empty statement.
26013
26014 2002-07-06  Jim Meyering  <meyering@lucent.com>
26015
26016         * m4/README: Don't mention Makefile.am.in.
26017         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
26018
26019 2002-07-01  Jim Meyering  <meyering@lucent.com>
26020
26021         * lib/c-stack.c: Include sys/time.h.
26022         From Volker Borchert.
26023
26024 2002-06-26  Paul Eggert  <eggert@twinsun.com>
26025
26026         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
26027
26028 2002-06-26  Paul Eggert  <eggert@twinsun.com>
26029
26030         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
26031         New macro.  Use it uniformly instead of
26032         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
26033         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
26034         reported by Vin Shelton.
26035
26036 2002-06-22  Paul Eggert  <eggert@twinsun.com>
26037
26038         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
26039         Do not assume SA_SIGINFO behavior.
26040         Bug reported by Jim Meyering on NetBSD 1.5.2.
26041
26042 2002-06-22  Jim Meyering  <meyering@lucent.com>
26043
26044         * m4/c-stack.m4: New file, from diffutils-2.8.2.
26045         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
26046
26047         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
26048         now that configure.ac uses AC_GNU_SOURCE.
26049         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
26050         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
26051
26052         Update to latest tools.  Suggestions from Paul Eggert.
26053         * m4/stdbool.m4: New file, from diffutils-2.8.2.
26054         * m4/gnu-source.m4: Update from diffutils-2.8.2.
26055         * m4/fnmatch.m4: Likewise.
26056         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
26057         to AC_HEADER_STDBOOL
26058
26059 2002-06-22  Jim Meyering  <meyering@lucent.com>
26060
26061         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
26062         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
26063
26064 2002-06-22  Jim Meyering  <meyering@lucent.com>
26065
26066         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
26067
26068         * lib/exitfail.c, exitfail.h: Likewise.
26069         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
26070
26071         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
26072         of fnmatch.h.
26073         (EXTRA_DIST): Add fnmatch_loop.c.
26074         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
26075
26076         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
26077         * lib/fnmatch.c: Update from diffutils-2.8.2.
26078         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
26079         * lib/fnmatch.h: Remove file.
26080
26081 2002-06-21  Jim Meyering  <meyering@lucent.com>
26082
26083         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
26084         * m4/mbrtowc.m4: Likewise.
26085
26086         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
26087         * m4/mbswidth.m4: Reflect name change:
26088         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
26089         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
26090
26091         * m4/lib-link.m4: Update from gettext-0.11.2.
26092         * m4/gettext.m4: Likewise.
26093
26094         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
26095         From Alfred M. Szmidt.
26096
26097 2002-06-18  Paul Eggert  <eggert@twinsun.com>
26098
26099         * lib/file-type.h: Report an error if neither S_ISREG nor
26100         S_IFREG is defined, instead of using a test specific to glibc
26101         2.2.  This should be safe, since POSIX requires S_ISREG and
26102         Unix Version 7 had S_IFREG.  We don't need to check for
26103         <sys/types.h> since we don't use any symbols that it defines.
26104
26105 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
26106
26107         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
26108         $@-t, so that each temporary file name is unique and valid in the first
26109         8 characters, for operation under DOS.
26110
26111 2002-06-15  Paul Eggert  <eggert@twinsun.com>
26112
26113         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
26114
26115 2002-06-15  Jim Meyering  <meyering@lucent.com>
26116
26117         Work even with DJGPP 2.03, which lacks support for symlinks.
26118         From Richard Dawe.
26119         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
26120         is defined.
26121         * lib/lchown.c (S_ISLNK): Likewise.
26122
26123 2002-06-15  Jim Meyering  <meyering@lucent.com>
26124
26125         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
26126         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
26127         have been included before this file.
26128
26129 2002-06-14  Jim Meyering  <meyering@lucent.com>
26130
26131         * lib/file-type.h: Use the version from diffutils-2.8.2.
26132         * lib/file-type.c: Likewise.
26133
26134 2002-06-07  Jim Meyering  <meyering@lucent.com>
26135
26136         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
26137         They're needed at least for NetBSD 1.5.2.
26138         ($statxfs_includes): Include those same headers.
26139         ($statxfs_includes): Include sys/vfs.h if available.
26140         ($statxfs_includes): Likewise for sys/statvfs.h.
26141         Check for the following members in both structs statfs and statvfs:
26142         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
26143
26144 2002-06-01  Jim Meyering  <meyering@lucent.com>
26145
26146         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
26147         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
26148
26149 2002-05-28  Jim Meyering  <meyering@lucent.com>
26150
26151         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
26152         Reported by Volker Borchert.
26153
26154 2002-05-27  Jim Meyering  <meyering@lucent.com>
26155
26156         Fix a problem seen only on nonconforming systems whereby ls.c's
26157         use of localtime, and then of gettimeofday would cause trouble:
26158         the localtime call used to initialize rpl_gettimeofday's save
26159         mechanism would clobber ls's current local time information so
26160         that in any long listing the first file would always be listed
26161         with date 1970-01-01.  Analysis by Volker Borchert.
26162
26163         * lib/gettimeofday.c (localtime): Undefine.
26164         (rpl_localtime): New function.
26165
26166 2002-05-27  Jim Meyering  <meyering@lucent.com>
26167
26168         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
26169         localtime.
26170
26171         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
26172         use the replacement function; it wouldn't resolve at link time.
26173         Reported by Volker Borchert.
26174
26175 2002-05-22  Jim Meyering  <meyering@lucent.com>
26176
26177         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
26178         file-type.h.
26179         * lib/file-type.h: New file.
26180         * lib/file-type.c (file_type): New file/function.  Extracted from
26181         diffutils.
26182
26183 2002-04-30  Jim Meyering  <meyering@lucent.com>
26184
26185         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
26186
26187 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26188
26189         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
26190
26191 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26192
26193         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
26194         Do not check for alloca.h (no longer used) or stdbool.h (was never
26195         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
26196
26197 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26198
26199         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
26200
26201 2002-04-29  Jim Meyering  <meyering@lucent.com>
26202
26203         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
26204         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
26205         Use AC_FUNC_STRNLEN here instead.
26206
26207         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
26208         With autoconf-2.53a, it's part of AC_PROG_CC.
26209
26210 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26211
26212         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
26213         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
26214
26215 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26216
26217         * lib/sig2str.h, lib/sig2str.c: New files.
26218         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
26219
26220 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26221
26222         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
26223         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
26224         of 127, since 64 is the largest conceivable number for ancient
26225         nonstandard hosts.
26226         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
26227
26228 2002-04-28  Jim Meyering  <meyering@lucent.com>
26229
26230         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
26231
26232 2002-04-24  Jim Meyering  <meyering@lucent.com>
26233
26234         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
26235         (jm_PREREQ): Use it.
26236
26237         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
26238         mach/mach.h fcntl.h.
26239         Check for this function: setlocale.
26240
26241 2002-04-24  Jim Meyering  <meyering@lucent.com>
26242
26243         * lib/gettext.h: New file, from Gettext.
26244         * lib/Makefile.am (INCLUDES): Remove -I../intl.
26245         (libfetish_a_SOURCES): Add gettext.h.
26246
26247 2002-04-16  Jim Meyering  <meyering@lucent.com>
26248
26249         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
26250         ut_pid, ut_id, ut_exit.
26251
26252 2002-04-16  Jim Meyering  <meyering@lucent.com>
26253
26254         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
26255         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
26256         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
26257
26258 2002-04-12  Jim Meyering  <meyering@lucent.com>
26259
26260         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
26261         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
26262         existence of the getmntinfo function.  Needed for Darwin 5.3.
26263
26264         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
26265         This is necessary at least on Darwin 5.3.
26266
26267         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
26268         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
26269         strnlen.o in the library, and that makes some versions of ranlib
26270         object.
26271
26272 2002-04-12  Jim Meyering  <meyering@lucent.com>
26273
26274         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
26275
26276 2002-04-09  Jim Meyering  <meyering@lucent.com>
26277
26278         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
26279         to be more precise.  Rather than saying we're checking whether the
26280         function `works', say what we're testing.
26281         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
26282         Reported by Bruno Haible.
26283
26284 2002-03-10  Jim Meyering  <meyering@lucent.com>
26285
26286         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
26287         Suggestion from Santiago Vila.
26288
26289 2002-03-08  Jim Meyering  <meyering@lucent.com>
26290
26291         * lib/rename.c: Mention that this wrapper is needed also on
26292         mips-dec-ultrix4.4 systems.
26293
26294 2002-03-02  Jim Meyering  <meyering@lucent.com>
26295
26296         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
26297         not HAVE_CLOCK_SETTIME.
26298
26299 2002-02-27  Paul Eggert  <eggert@twinsun.com>
26300
26301         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
26302         Check for clock_settime.
26303
26304 2002-02-27  Paul Eggert  <eggert@twinsun.com>
26305
26306         * lib/nanosleep.h: Rename to....
26307         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
26308
26309         * lib/gettime.c: New file.
26310         * lib/settime.c: New file.
26311         * lib/stime.c: Remove.
26312
26313         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
26314         timespec.h.  Remove nanosleep.h.
26315
26316 2002-02-25  Paul Eggert  <eggert@twinsun.com>
26317
26318         * m4/acl.m4: New file.
26319         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
26320         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
26321
26322 2002-02-25  Paul Eggert  <eggert@twinsun.com>
26323
26324         * lib/acl.c, lib/acl.h: New files.
26325         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
26326
26327 2002-02-24  Jim Meyering  <meyering@lucent.com>
26328
26329         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
26330         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
26331         cause trouble.  Reported by Nelson Beebe.
26332
26333 2002-02-23  Paul Eggert  <eggert@twinsun.com>
26334
26335         * lib/path-concat.c (xpath_concat): Reorder code to pacify
26336         compilers that don't know that xalloc_die never returns.
26337
26338 2002-02-20  Jim Meyering  <meyering@lucent.com>
26339
26340         * lib/getdate.c: Regenerate using bison-1.33.
26341
26342 2002-02-17  Jim Meyering  <meyering@lucent.com>
26343
26344         * config/config.guess (main): Don't use `head -1'; it's no longer
26345         portable. Use `sed 1q' instead.
26346
26347 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
26348
26349         * m4/codeset.m4: Upgrade to gettext-0.11.
26350         * m4/gettext.m4: Upgrade to gettext-0.11.
26351         * m4/glibc21.m4: Upgrade to gettext-0.11.
26352         * m4/iconv.m4: Upgrade to gettext-0.11.
26353         * m4/isc-posix.m4: Upgrade to gettext-0.11.
26354         * m4/lcmessage.m4: Upgrade to gettext-0.11.
26355         * m4/lib-ld.m4: New file, from gettext-0.11.
26356         * m4/lib-link.m4: New file, from gettext-0.11.
26357         * m4/lib-prefix.m4: New file, from gettext-0.11.
26358         * m4/progtest.m4: Upgrade to gettext-0.11.
26359
26360 2002-02-15  Paul Eggert  <eggert@twinsun.com>
26361
26362         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
26363         (jm_PREREQ): Use it.
26364
26365 2002-02-15  Paul Eggert  <eggert@twinsun.com>
26366
26367         * lib/posixver.c, lib/posixver.h: New files.
26368         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
26369
26370 2002-02-02  Paul Eggert  <eggert@twinsun.com>
26371             Bruno Haible  <bruno@clisp.org>
26372
26373         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
26374         (fwrite_success_callback): New declaration.
26375         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
26376         print_unicode_char. Call failure callback instead of error.
26377         (fwrite_success_callback): New function.
26378         (exit_failure_callback): New function.
26379         (fallback_failure_callback): New function.
26380         (print_unicode_char): Call unicode_to_mb.
26381
26382 2002-01-26  Jim Meyering  <meyering@lucent.com>
26383
26384         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
26385         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
26386
26387 2002-01-26  Jim Meyering  <meyering@lucent.com>
26388
26389         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
26390
26391 2002-01-22  Paul Eggert  <eggert@twinsun.com>
26392
26393         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
26394
26395 2002-01-22  Jim Meyering  <meyering@lucent.com>
26396
26397         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
26398         Otherwise, some versions of automake would omit the rule that makes
26399         Makefile from Makefile.in.
26400
26401 2002-01-21  Paul Eggert  <eggert@twinsun.com>
26402
26403         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
26404         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
26405         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
26406         (memcoll): Set errno to zero if there is no error.
26407
26408         * lib/quotearg.c (quotearg_buffer_restyled):
26409         Fix bug with quoting buffers containing NUL when backslashing escapes.
26410         This bug was exposed by the other changes in this patch.
26411         (quotearg_n_options): New arg ARGSIZE.
26412         All callers changed.
26413         (quoting_options_from_style): New function.
26414         (quotearg_n_style): Use it.
26415         (quotearg_n_style_mem): New function.
26416
26417         * lib/quotearg.h (quotearg_n_style_mem): New function.
26418
26419 2002-01-19  Jim Meyering  <meyering@lucent.com>
26420
26421         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
26422         Remove useless quotes: DF_PROG="df".
26423         * m4/strnlen.m4: New file.
26424
26425 2002-01-16  Paul Eggert  <eggert@twinsun.com>
26426
26427         * lib/backupfile.c (ISDIGIT): Comment fix.
26428         * lib/getdate.y (ISDIGIT): Likewise.
26429         * lib/posixtm.c (ISDIGIT, year): Likewise.
26430         * lib/strverscmp.c (ISDIGIT): Likewise.
26431         * lib/userspec.c (ISDIGIT): Likewise.
26432
26433 2002-01-16  Jim Meyering  <meyering@lucent.com>
26434
26435         * lib/getdate.y: Add three semicolons, each just before a closing
26436         brace. Bison (as of version 1.31) no longer papers over that mistake.
26437
26438 2002-01-05  Jim Meyering  <meyering@lucent.com>
26439
26440         * lib/version-etc.c (version_etc_copyright): Update copyright year.
26441
26442 2001-12-19  Paul Eggert  <eggert@twinsun.com>
26443
26444         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
26445         not silently exit merely because the output buffer happens to
26446         have nothing pending.
26447
26448 2001-12-18  Paul Eggert  <eggert@twinsun.com>
26449
26450         See the big note in ../ChangeLog.
26451         * lib/human.c (suffixes): Prefer K to k for 1024.
26452         (generate_suffix_backwards): New function.
26453         (human_readable_inexact): Use it.
26454         * lib/xstrtol.c (__xstrtol): If there is no number but there
26455         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
26456         Accept 'K' as well as 'k'.
26457
26458 2001-12-15  Jim Meyering  <meyering@lucent.com>
26459
26460         * lib/regex.h (__restrict_arr): Update from libc.
26461
26462         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
26463         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
26464         (STREQ): Define.
26465
26466 2001-12-14  Jim Meyering  <meyering@lucent.com>
26467
26468         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
26469         Suggestion from Bruno Haible.
26470
26471 2001-12-10  Jim Meyering  <meyering@lucent.com>
26472
26473         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
26474         xrealloc, Instead, include "xalloc.h".
26475         (initbuffer): Don't cast xmalloc return value to char*.
26476         (readline): Reword comment.
26477         Don't cast xrealloc return value to char*
26478         Return NULL, not 0.
26479
26480 2001-12-09  Jim Meyering  <meyering@lucent.com>
26481
26482         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
26483         about `signed and unsigned type in conditional expression'.
26484         * lib/posixtm.c (posix_time_parse): Likewise.
26485
26486         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
26487
26488         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
26489         to avoid a pedantic warning.
26490
26491         * lib/getstr.c: Don't include assert.h.
26492         (getstr): Remove warning-evoking assertions.
26493         Return -1 if offset parameter is out of bounds.
26494         Change the type of a local from int to size_t.
26495
26496         * lib/strftime.c (my_strftime_localtime_r): Include this function
26497         definition in the `#if ! HAVE_TM_GMTOFF' block.
26498
26499         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
26500         Include xalloc.h instead.
26501
26502 2001-12-02  Jim Meyering  <meyering@lucent.com>
26503
26504         * lib/tempname.c: Don't declare getenv, thus reverting the change of
26505         2001-11-18.  It's no longer necessary, now that stdlib.h is always
26506         included.
26507
26508         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
26509         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
26510
26511 2001-11-30  Akim Demaille  <akim@epita.fr>
26512
26513         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
26514         before being defined.
26515
26516 2001-11-27  Paul Eggert  <eggert@twinsun.com>
26517
26518         * lib/quotearg.h (quotearg_n, quotearg_n_style):
26519         First arg is int, not unsigned.
26520         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
26521         (SIZE_MAX, UINT_MAX): New macros.
26522         (quotearg_n_options): Abort if N is negative.
26523         Avoid overflow check on hosts where size_t is 64 bits and int
26524         is 32 bits, as overflow is impossible there.
26525         Fix off-by-one typo that caused unnecessary reallocation.
26526
26527 2001-11-27  Jim Meyering  <meyering@lucent.com>
26528
26529         * lib/tempname.c: Merge with version from libc.
26530         * lib/regex.c: Likewise.
26531
26532         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
26533         systems for which STDC_HEADERS is 0, it was not included, resulting in
26534         a warning about an integer-to-pointer conversion problem with getenv.
26535         Reported by Volker Borchert.
26536
26537 2001-11-26  Jim Meyering  <meyering@lucent.com>
26538
26539         * lib/gtod.h: Remove file.
26540         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
26541         * lib/gettimeofday.c: Don't include gtod.h.
26542         (GTOD_init): Remove function.
26543         (rpl_gettimeofday): Do its job here instead, rather than aborting.
26544         Suggestion from Volker Borchert.
26545
26546 2001-11-23  Jim Meyering  <meyering@lucent.com>
26547
26548         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
26549         it.
26550         * lib/hash.c (struct hash_table): Define it here instead.
26551
26552 2001-11-22  Jim Meyering  <meyering@lucent.com>
26553
26554         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
26555
26556 2001-11-20  Jim Meyering  <meyering@lucent.com>
26557
26558         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
26559         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
26560
26561 2001-11-19  Jim Meyering  <meyering@lucent.com>
26562
26563         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
26564         directory.  Use "conftestXXXXXX" as the template.
26565         Suggestion from Paul Eggert.
26566
26567         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
26568         immediately, so the test doesn't mistakenly hit the max-open-files
26569         limit.
26570
26571 2001-11-18  Paul Eggert  <eggert@twinsun.com>
26572
26573         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
26574         (TEMPORARIES): New macro.
26575         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
26576         removes an artificial limitation (e.g. HP-UX 10.20, where
26577         TMP_MAX is 17576).
26578
26579 2001-11-18  Jim Meyering  <meyering@lucent.com>
26580
26581         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
26582
26583 2001-11-18  Jim Meyering  <meyering@lucent.com>
26584
26585         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
26586         on SunOS 4.
26587
26588         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
26589         files will be created before anything else.
26590
26591 2001-11-17  Paul Eggert  <eggert@twinsun.com>
26592
26593         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
26594         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
26595
26596 2001-11-17  Jim Meyering  <meyering@lucent.com>
26597
26598         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
26599         Prompted by a report from Bob Proulx.
26600
26601         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
26602         Instead, require UTILS_FUNC_MKSTEMP.
26603
26604 2001-11-17  Jim Meyering  <meyering@lucent.com>
26605
26606         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
26607         Now, that's done as part of AC_FUNC_STRTOD.
26608
26609 2001-11-17  Jim Meyering  <meyering@lucent.com>
26610
26611         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
26612         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
26613         rather than group writable.  Patch by Juan F. Codagnone.
26614
26615         * lib/readtokens.c: Remove explicit declarations of xmalloc and
26616         xrealloc, Instead, include "xalloc.h".
26617
26618         * lib/mountlist.c: Include unlocked-io.h after all system headers.
26619         Remove explicit declarations of xmalloc, xrealloc,
26620         and xstrdup.  Instead, include "xalloc.h".
26621
26622         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
26623         unlocked-io.h.
26624         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
26625         Likewise.
26626         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
26627
26628         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
26629         Reported by Padraig Brady.
26630
26631         * lib/mkstemp.c: #undef mkstemp.
26632         Include config.h.
26633         (rpl_mkstemp): Rename from mkstemp.
26634         Protoize.
26635
26636 2001-11-16  Jim Meyering  <meyering@lucent.com>
26637
26638         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
26639         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
26640         determine the amount of total physical memory, use pstat_getstatic.
26641         HPUX-11 doesn't define _SC_PHYS_PAGES.
26642         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
26643         If sysconf couldn't be used to determine the amount of available
26644         physical memory, use both pstat_getstatic and pstat_getdynamic.
26645         Based on a patch from Bob Proulx.
26646
26647 2001-11-10  Jim Meyering  <meyering@lucent.com>
26648
26649         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
26650         (jm_PREREQ): Use it.
26651
26652 2001-11-09  Jim Meyering  <meyering@lucent.com>
26653
26654         * m4/jm-macros.m4: Require autoconf-2.52f.
26655         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
26656         Use these AC_-prefixed names, not the AM_-prefixed ones.
26657
26658         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
26659
26660 2001-11-05  Jim Meyering  <meyering@lucent.com>
26661
26662         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
26663
26664 2001-11-04  Jim Meyering  <meyering@lucent.com>
26665
26666         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
26667         $DEFS.
26668
26669 2001-11-03  Jim Meyering  <meyering@lucent.com>
26670
26671         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
26672         of AC_DEFUN.
26673
26674         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
26675         know the name of the variable in the macro definition.
26676
26677 2001-11-03  Jim Meyering  <meyering@lucent.com>
26678
26679         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
26680         in argmatch_to_argument call.
26681
26682         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
26683         argument.
26684
26685         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
26686         e.g., a fault due to an attempt to free a NULL pointer.
26687
26688 2001-11-01  Jim Meyering  <meyering@lucent.com>
26689
26690         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
26691         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
26692
26693 2001-11-01  Jim Meyering  <meyering@lucent.com>
26694
26695         * lib/dirfd.c, lib/dirfd.h: New files.
26696         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
26697
26698         * lib/hash.c (hash_print) [TESTING]: Clean up.
26699
26700 2001-10-22  Paul Eggert  <eggert@twinsun.com>
26701
26702         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
26703         to avoid a warning if -Wall.
26704
26705 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
26706
26707         * README: New file
26708         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
26709         (per RMS's instructions, this is now the canonical source)
26710         * lgpl/, gpl/: New directories.
26711
26712 2001-10-21  Paul Eggert  <eggert@twinsun.com>
26713
26714         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
26715
26716 2001-10-21  Jim Meyering  <meyering@lucent.com>
26717
26718         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
26719         this code would end up calling gettext even in packages built
26720         with --disable-nls.
26721         * lib/getopt.c (_): Likewise.
26722         * lib/regex.c (_): Likewise.
26723
26724 2001-10-20  Paul Eggert  <eggert@twinsun.com>
26725
26726         * m4/error.m4 (jm_PREREQ_ERROR):
26727         Do not invoke AC_CHECK_FUNCS with strerror_r, as
26728         AC_FUNC_STRERROR_R does that.
26729         Check for strerror declaration.
26730
26731         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
26732         are supposed to have them these days.
26733         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
26734         Merge changes from latest Autoconf CVS.
26735         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
26736         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
26737         POSIX decided to standardize on the int flavor of strerror_r.
26738
26739 2001-10-20  Paul Eggert  <eggert@twinsun.com>
26740
26741         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
26742         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
26743         Use strerror_r that is only a macro, even if it is not a function.
26744         (strerror): Check for HAVE_DECL_STRERROR before declaring.
26745         (private_strerror): Use prototypes, not old-style function definition.
26746         (print_errno_message): New function.
26747         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
26748         char*-flavored one.
26749         (error_tail, error, error_at_line): Use it.
26750
26751 2001-10-11  Jim Meyering  <meyering@lucent.com>
26752
26753         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
26754         and quote_n (1, ... to avoid clobbering a buffer.
26755
26756 2001-10-05  Jim Meyering  <meyering@lucent.com>
26757
26758         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
26759         hash-pjw.h.
26760         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
26761         * lib/hash-pjw.h: New file.
26762
26763 2001-09-30  Jim Meyering  <meyering@lucent.com>
26764
26765         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
26766         `struct fsstat' has the `f_fstypename' member.
26767         Use that to define FS_TYPE, which is now used to make
26768         the getfsstat link test tighter.
26769
26770 2001-09-30  Jim Meyering  <meyering@lucent.com>
26771
26772         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
26773         Include <sys/ucred.h>, for Apple Darwin.
26774         Include sys/mount.h and sys/fs_types.h only if available.
26775         (FS_TYPE): Define.
26776         (read_filesystem_list): Use FS_TYPE.
26777
26778 2001-09-29  Paul Eggert  <eggert@twinsun.com>
26779
26780         * lib/exclude.c (excluded_filename): 0 -> false, since it's
26781         a boolean context.
26782
26783 2001-09-29  Jim Meyering  <meyering@lucent.com>
26784
26785         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26786         [one-argument getmntent function]): Include stdio.h before mntent.h.
26787         SunOS 4.1.x needs it for the declaration of `FILE'.
26788         Patch by Volker Borchert.
26789
26790         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26791         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
26792         sys/fs_types.h, and make the link-test for getfsstat guard #include
26793         directives with appropriate #if HAVE_*_H tests so that we can
26794         detect getfsstat on Apple Darwin1.3.7 systems.
26795         Reported by Nelson Beebe.
26796         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
26797
26798 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26799
26800         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26801         #defines strtoimax.  Also treat the other strto* functions
26802         like strtoimax.
26803
26804         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
26805         Check for strtoul and strtoumax,
26806         as those declarations are made even in the signed case.
26807         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
26808         Likewise, for strtol and strtoimax.
26809
26810 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26811
26812         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26813         #defines strtoimax.  Also treat the other strto* functions
26814         like strtoimax.
26815
26816         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
26817         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
26818         (strtoimax, strtoumax): Do not declare if already defined as a macro.
26819
26820 2001-09-26  Jim Meyering  <meyering@lucent.com>
26821
26822         Most macros in unlocked-io.h had the wrong number of arguments.
26823         * lib/gen-uio: New script.
26824         (USE_UNLOCKED_IO): Define to 1 if not already defined.
26825         * lib/unlocked-io.hin: Remove file.
26826         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
26827         rather than trying to embed it here.
26828         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
26829         Reported by Padraig Brady.
26830
26831 2001-09-25  Volker Borchert  <bt@teknon.de>
26832
26833         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
26834         `result'.
26835
26836 2001-09-24  Jim Meyering  <meyering@lucent.com>
26837
26838         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
26839
26840 2001-09-23  Jim Meyering  <meyering@lucent.com>
26841
26842         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
26843         instead of the mere test for existence of mntent.h.  The latter
26844         would get a false-positive on AIX 3.4 systems.
26845         In the outer getmntent if-block, don't die if neither of the getmntent
26846         tests succeeds.  Instead, just fall through and continue with the
26847         remaining tests.
26848
26849 2001-09-23  Jim Meyering  <meyering@lucent.com>
26850
26851         * lib/mountlist.c: Remove useless parentheses in #if directives.
26852         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
26853         the deprecated MOUNTED symbol is no longer defined in mntent.h.
26854
26855 2001-09-22  Jim Meyering  <meyering@lucent.com>
26856
26857         * m4/gettext.m4: New file.  From gettext.
26858         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
26859         * m4/progtest.m4: Likewise
26860         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
26861         * m4/glibc21.m4: Likewise.
26862
26863         * m4/libintl.m4: Remove.  No longer used.
26864
26865 2001-09-22  Jim Meyering  <meyering@lucent.com>
26866
26867         * lib/localcharset.c: Update from latest gettext.
26868         * lib/config.charset: Likewise.
26869
26870 2001-09-20  Jim Meyering  <meyering@lucent.com>
26871
26872         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
26873         strtoimax.
26874         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
26875         strtoumax.
26876
26877 2001-09-20  Jim Meyering  <meyering@lucent.com>
26878
26879         * lib/xstrtol.c (strtoimax): Guard declaration with
26880         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
26881         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
26882         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
26883         (strtoumax): Likewise, for completeness (it wasn't necessary).
26884
26885 2001-09-17  Paul Eggert  <eggert@twinsun.com>
26886
26887         * lib/strtoimax.c (HAVE_LONG_LONG):
26888         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
26889         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
26890         to work around bug in IBM C compiler.
26891
26892 2001-09-17  Jim Meyering  <meyering@lucent.com>
26893
26894         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
26895         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
26896         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
26897         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
26898         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
26899         whenever the right hand side need not be expanded by the shell.
26900
26901 2001-09-16  Paul Eggert  <eggert@twinsun.com>
26902
26903         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
26904         library.  It's not correct, as some older glibcs are buggy.
26905         fnmatch wasn't fixed until glibc 2.2.
26906
26907         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
26908         special shell magic here.
26909
26910 2001-09-16  Jim Meyering  <meyering@lucent.com>
26911
26912         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
26913         * m4/jm-macros.m4: Require it.
26914
26915 2001-09-16  Jim Meyering  <meyering@lucent.com>
26916
26917         * lib/mkdir.c: New file.
26918
26919 2001-09-15  Jim Meyering  <meyering@lucent.com>
26920
26921         * m4/jm-macros.m4: Check for help2man.
26922
26923 2001-09-11  Jim Meyering  <meyering@lucent.com>
26924
26925         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
26926         The body, by Paul Eggert, was moved here from configure.in.
26927         * m4/jm-macros.m4: Require UTILS_HOST_OS.
26928
26929 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26930
26931         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
26932         (jm_PREREQ): Use it.
26933
26934 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26935
26936         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
26937         Use ssize_t, not int, to store result of readlink.
26938         Check for ssize_t overflow as well as size_t overflow,
26939         as POSIX says the result of readlink is implementation-defined
26940         when ssize_t overflows.
26941         Remove unnecessary cast to char*.
26942         Use free+malloc instead of realloc, as the storage doesn't need
26943         to be preserved and it's clearer and can be more efficient that way.
26944         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
26945         * lib/xreadlink.h (xreadlink): Update prototype.
26946
26947 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26948
26949         * lib/xgetcwd.c: Revert some of the previous change; intead,
26950         fix the HAVE_GETCWD_NULL code to behave more like the
26951         !HAVE_GETCWD_NULL code used to.
26952
26953         Include "xalloc.h".
26954         (xgetcwd): Do not return NULL when memory is exhausted; instead,
26955         invoke xalloc_die.
26956
26957 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26958
26959         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
26960         sys/param.h, as pathmax.h includes them.
26961
26962 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26963
26964         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
26965         (jm_PREREQ_XGETCWD): New macro.
26966
26967         * m4/getcwd.m4: New file.
26968
26969 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26970
26971         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
26972         like the HAVE_GETCWD_NULL code.
26973         Include pathmax.h if not HAVE_GETCWD.
26974         Do not include xalloc.h.
26975         (INITIAL_BUFFER_SIZE): New symbol.
26976         Do not use xmalloc / xrealloc, since the caller is responsible for
26977         handling errors.  Preserve errno around `free' during failure.
26978         Do not overrun buffer when using getwd.
26979
26980 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26981
26982         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
26983         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
26984         getcwd (NULL, 0).
26985
26986 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26987
26988         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
26989         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
26990         spotted by Jim Meyering.
26991
26992 2001-09-03  Jim Meyering  <meyering@lucent.com>
26993
26994         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
26995         failure.
26996
26997 2001-09-02  Jim Meyering  <meyering@lucent.com>
26998
26999         * lib/error.c: Update from GNU libc.
27000
27001 2001-09-01  Jim Meyering  <meyering@lucent.com>
27002
27003         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
27004         Used by df.
27005
27006 2001-09-01  Jim Meyering  <meyering@lucent.com>
27007
27008         * lib/xreadlink.c: New file.
27009         * lib/xreadlink.h: New file.
27010         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
27011         xreadlink.h.
27012
27013         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
27014         doesn't conflict with sparc Solaris 7's definition in
27015         /usr/include/sys/int_types.h.
27016
27017         * lib/exclude.c: Use `""', not `<>' to #include non-system header
27018         files.
27019         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
27020         and strncasecmp as r-values.  Unixware didn't have declarations.
27021
27022 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27023
27024         * lib/xstrtol.h: Add copyright notice.
27025         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
27026         LONGINT_INVALID_SUFFIX_CHAR.
27027
27028 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27029
27030         * lib/xstrtol.c (strtoimax): New decl.
27031
27032 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27033
27034         * lib/xgetcwd.c: Don't include pathmax.h.
27035         Include stdlib.h and unistd.h if available.
27036         Include xalloc.h.
27037         (xmalloc, xstrdup, free): Remove decls.
27038         (xgetcwd): Don't assume sizes fit in unsigned.
27039         Check for overflow when computing sizes.
27040         Simplify reallocation code.
27041
27042 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27043
27044         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
27045         a directory's st_size can have an arbitrary value, so the old
27046         usage could waste an arbitrary amount of memory.  All uses
27047         changed.
27048         * lib/savedir.h: Update prototype.
27049
27050 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27051
27052         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
27053
27054         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
27055         old strtoimax.c.
27056
27057         Also, make the following further changes to make this file's
27058         configuration more similar to that of strtol.c:
27059         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
27060         (strtoumax, uintmax_t, strtoull, strtol): Remove.
27061         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
27062         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
27063         changed to signed values.
27064
27065         And make the following changes as well:
27066         Fix copyright notice, as 1999 was missing.
27067         (verify): New macro.
27068         (strtoimax): Check sizes at compile-time, not run-time.
27069         Prefer strtol to strtoll if both work.
27070         (main): Remove; it was not that useful and was a pain to maintain.
27071
27072         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
27073
27074 2001-08-31  Jim Meyering  <meyering@lucent.com>
27075
27076         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
27077         Use an initial, malloc'd, buffer of length 128 rather than
27078         a statically allocated one of length 1024.
27079
27080 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27081
27082         Simplify code, partly by assuming autoconf 2.52 semantics.
27083
27084         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
27085
27086         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
27087         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
27088         All uses removed.
27089         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
27090         Move AC_REQUIRE to next-to-top level, to avoid confusion.
27091         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
27092         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
27093         jm_AC_HEADER_INTTYPES_H.
27094         * m4/jm-macros.m4 (jm_MACROS): Likewise.
27095
27096         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
27097
27098         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
27099         Quote first arg of AC_DEFUN.
27100         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
27101         since they are needed to parse the include file even if we need
27102         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
27103         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
27104         but with opposite signedness.
27105
27106 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27107
27108         Merge 'exclude' changes from tar 1.13.22.
27109         This fixes one or two unlikely storage allocation overflow bugs,
27110         but doesn't change user-visible behavior otherwise.
27111
27112 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27113
27114         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
27115         (jm_PREREQ_EXCLUDE): New macro.
27116
27117 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27118
27119         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
27120         tm to be declared.
27121
27122 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27123
27124         * lib/hash.c: Remove '2001' from copyright notice.
27125
27126 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27127
27128         * lib/full-write.h: New file.
27129         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
27130         * lib/full-write.c: Correct credits, as cccp.c no longer
27131         exists and anyway it was so heavily changed from the old cccp
27132         code as to be unrecognizable.  Include full-write.h.
27133         (full_write) Return size_t, with short writes meaning failure.
27134         All callers changed.  This fixes a bug with large buffers
27135         on 64-bit hosts.
27136         * lib/utime.c: Include full-write.h.
27137
27138 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27139
27140         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
27141         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
27142         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
27143         Include if available.
27144         (<xalloc.h>): Include
27145         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
27146         (verify): New macro.  Use it to verify that EXCLUDE macros do not
27147         collide with FNM macros.
27148         (struct patopts): New struct.
27149         (struct exclude): Use it, as exclude patterns now come with options.
27150         (new_exclude): Support above changes.
27151         (new_exclude, add_exclude_file):
27152         Initial size must now be a power of two to simplify overflow checking.
27153         (free_exclude, fnmatch_no_wildcards): New function.
27154         (excluded_filename): No longer requires options arg, as the options
27155         are determined by add_exclude.  Now returns bool, not int.
27156         (excluded_filename, add_exclude):
27157         Add support for the fancy new exclusion options.
27158         (add_exclude, add_exclude_file): Now takes int options arg.
27159         Check for arithmetic overflow when computing sizes.
27160         (add_exclude_file): xrealloc might modify errno, so don't
27161         realloc until after errno might be used.
27162
27163         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
27164         New macros.
27165         (free_exclude): New decl.
27166         (add_exclude, add_exclude_file): Now takes int options arg.
27167         (excluded_filename): No longer requires options arg, as the options
27168         are determined by add_exclude.  Now returns bool, not int.
27169
27170 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27171
27172         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
27173
27174 2001-08-27  Jim Meyering  <meyering@lucent.com>
27175
27176         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
27177
27178         * lib/version-etc.c (N_): Remove definition.
27179         Revert most of last change.
27180         Instead, simply don't mark the `Copyright...' string for translation.
27181         Based on advice from Paul Eggert.
27182
27183         * lib/strtoxmax.c: Tweak comment.
27184
27185 2001-08-26  Jim Meyering  <meyering@lucent.com>
27186
27187         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
27188
27189         * m4/xstrtoimax.m4: New file.
27190         * m4/xstrtoumax.m4: Add comments explaining why we
27191         AC_REPLACE_FUNCS(strtol).
27192
27193 2001-08-26  Jim Meyering  <meyering@lucent.com>
27194
27195         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
27196         of copyright with `%s' so translators don't get an untranslated
27197         message in 2002.
27198         (COPYRIGHT_YEAR): Define.
27199         (version_etc): Use fprintf rather than fputs.
27200         Suggestion from Ulrich Drepper.
27201
27202         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
27203
27204         * lib/strtoll.c: New file, from GNU libc.
27205         * lib/xstrtoimax.c: New file.
27206
27207         * lib/xstrtol.h: Add xstrtoimax.
27208         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
27209         * lib/strtoimax.c: New file.  Likewise, but first define
27210         STRTOUXMAX_SIGNED.
27211
27212         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
27213         ...
27214         * lib/strtoxmax.c: ... then renamed to this.
27215
27216 2001-08-18  Paul Eggert  <eggert@twinsun.com>
27217
27218         * m4/inttypes.m4: Add AC_PREREQ(2.13).
27219         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
27220         (jm_AC_TYPE_INTMAX_T): New macro.
27221         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
27222
27223         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
27224
27225         * m4/longlong.m4: Renamed from ulonglong.m4.
27226         * m4/inttypes.m4: Renamed from inttypes_h.m4.
27227         * m4/uintmax_t.m4: Removed.
27228
27229 2001-08-13  Paul Eggert  <eggert@twinsun.com>
27230
27231         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
27232         Port to Solaris 8, where 'sed' requires a space after the 'r'
27233         command, and where sh dislikes "$/".  Clean up the spacing a bit.
27234         Redirect output to $tmp just once.
27235
27236 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
27237
27238         * lib/addext.c (<errno.h>): Include.
27239         (errno): Declare if not defined.
27240         (addext): Work correctly when pathconf returns -1 and leaves
27241         errno alone because there is no limit.  Also, work even if
27242         pathconf returns a value greater than SIZE_MAX.
27243
27244 2001-08-12  Jim Meyering  <meyering@lucent.com>
27245
27246         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
27247         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
27248         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
27249         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
27250         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
27251         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
27252         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
27253         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
27254         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
27255         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
27256         utime.m4, utimes.m4, xstrtoumax.m4:
27257         Quote the first argument in each use of AC_DEFUN.
27258
27259 2001-08-12  Jim Meyering  <meyering@lucent.com>
27260
27261         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
27262         Simply `return getcwd (NULL, 0);'.
27263         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
27264         Use 1300 as initial value for length, not PATH_MAX.
27265
27266         * lib/pathmax.h: Clean up cpp syntax.
27267
27268 2001-08-12  Jim Meyering  <meyering@lucent.com>
27269
27270         * lib/gettimeofday.c: New file.
27271         * lib/gtod.h: New file.
27272         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
27273
27274 2001-08-05  Jim Meyering  <meyering@lucent.com>
27275
27276         * m4/jm-macros.m4: Require autoconf-2.52.
27277
27278 2001-08-04  Jim Meyering  <meyering@lucent.com>
27279
27280         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
27281         stmt, to get in sync with glibc.
27282
27283 2001-08-03  Paul Eggert  <eggert@twinsun.com>
27284
27285         The following changes are from gettext 0.10.39 as maintained by
27286         Bruno Haible.
27287
27288         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
27289         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
27290         with inverted sense.  All uses changed.
27291
27292         * lib/mbswidth.c: Don't include <limits.h>.
27293         Include <stdlib.h> and <string.h> unconditionally.
27294         (iswcntrl, mbsinit, ISCNTRL): New macros.
27295         (mbsnwidth): Use K&R style function declarations.
27296         Don't bother checking for MB_LEN_MAX == 1, since the compiler
27297         can optimize it when MB_CUR_MAX == 1.
27298         The width of control characters is zero, not 1.
27299
27300 2001-08-03  Paul Eggert  <eggert@twinsun.com>
27301
27302         The following changes are from gettext 0.10.39 as maintained by
27303         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
27304
27305         * m4/codeset.m4: Upgrade to serial AM1.
27306         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
27307         all uses changed.  Quote first arg of AC_DEFUN.
27308         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
27309
27310         * m4/iconv.m4: Upgrade to serial AM2.
27311         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
27312         Add --with-libconv-prefix.
27313         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
27314         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
27315         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
27316         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
27317         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
27318
27319         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
27320         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
27321         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
27322         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
27323         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
27324         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
27325         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
27326         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
27327         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
27328
27329         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
27330         string.h any more.
27331
27332         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
27333         not the default value.
27334
27335         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
27336         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
27337         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
27338         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
27339         Also check for iswcntrl, used for wcwidth fallback.
27340         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
27341         to Autoconf 2.13.
27342
27343 2001-08-03  Jim Meyering  <meyering@lucent.com>
27344
27345         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
27346         as it was in the original.  Reported by Paul Eggert.
27347
27348 2001-07-16  Jim Meyering  <meyering@lucent.com>
27349
27350         * m4/gettimeofday.m4: New file.
27351         Prompted by a report from Bernhard Baehr.
27352
27353 2001-07-15  Jim Meyering  <meyering@lucent.com>
27354
27355         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
27356         stuff. Now it's in ../Makefile.cfg.
27357
27358 2001-07-15  Jim Meyering  <meyering@lucent.com>
27359
27360         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
27361         (BUILT_SOURCES): Add unlocked-io.h.
27362         (io_functions): Define.
27363         (unlocked-io.h): New rule.
27364         (DISTCLEANFILES): Add unlocked-io.h.
27365         (all-local): Depend on unlocked-io.h, to ensure it is created.
27366
27367         * lib/unlocked-io.hin: New file
27368
27369         * lib/regex.c: Update from glibc.
27370
27371 2001-07-05  Jim Meyering  <meyering@lucent.com>
27372
27373         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
27374         recommendation.
27375         (libfetish_a_SOURCES): Put all .h files here instead.
27376         Remove a thus-exposed (better checks in automake) duplicate and
27377         two unnecessary .h files.
27378
27379 2001-07-04  Jim Meyering  <meyering@lucent.com>
27380
27381         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
27382         that generates jm-glibc-io.m4 so that it doesn't trigger any make
27383         distcheck failure.
27384
27385 2001-07-02  Jim Meyering  <meyering@lucent.com>
27386
27387         The following changes were prompted by suggestions from Bruno Haible.
27388
27389         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
27390         is now generated.
27391         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
27392         definition of EXTRA_DIST.
27393         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
27394         ensure that the generated file is created/updated whenever the list
27395         of $(unlocked_functions) is changed.
27396         (jm-glibc-io.m4): New rule.
27397         (unlocked-io.h): New rule -- currently unused.
27398
27399 2001-06-24  Jim Meyering  <meyering@lucent.com>
27400
27401         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
27402         unmatched right bracket, rather than kludging it with an extra,
27403         falsely-matching quote in a comment.  Patch by Akim Demaille.
27404
27405 2001-06-11  Jim Meyering  <meyering@lucent.com>
27406
27407         * lib/regex.c: Update from GNU libc.
27408
27409 2001-05-27  Jim Meyering  <meyering@lucent.com>
27410
27411         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
27412         Check for ut_type in struct utmp.
27413
27414 2001-05-27  Jim Meyering  <meyering@lucent.com>
27415
27416         * lib/readutmp.h (UT_TYPE): Define.
27417
27418 2001-05-24  Jim Meyering  <meyering@lucent.com>
27419
27420         * lib/argmatch.c: Include "quote.h".
27421         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
27422         quote function.  Reported by Göran Uddeborg.
27423
27424 2001-05-22  Jim Meyering  <meyering@lucent.com>
27425
27426         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
27427         now that we use the package-supplied version unconditionally.
27428         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
27429
27430 2001-05-21  Jim Meyering  <meyering@lucent.com>
27431
27432         * m4/regex.m4: Change a couple backticks to single quotes to avoid
27433         shell syntax errors.
27434
27435 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
27436
27437         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
27438
27439 2001-05-20  Paul Eggert  <eggert@twinsun.com>
27440
27441         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
27442         Don't bother to check library strftime, since
27443         we'll be using our own my_strftime function anyway.
27444         Define my_strftime instead of strftime.
27445
27446 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
27447
27448         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
27449         which is not yet declared.
27450
27451 2001-05-15  Jim Meyering  <meyering@lucent.com>
27452
27453         * m4/regex.m4: Use proper quoting so brackets appear in the test
27454         program.
27455         Reported by, and with help from, Bruno Haible.
27456
27457 2001-05-13  Jim Meyering  <meyering@lucent.com>
27458
27459         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
27460         undefined.
27461
27462 2001-05-11  Paul Eggert  <eggert@twinsun.com>
27463
27464         dirname code cleanup.  base_name now behaves more compatibly
27465         with POSIX basename when given file names that have trailing
27466         slashes, and similarly for dir_name.  Add new primitives
27467         base_len and dir_len.  Put the directory-name-related decls
27468         into dirname.h.
27469
27470         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
27471         * lib/backupfile.c (base_name): Likewise.
27472         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
27473         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
27474         * lib/makepath.c (strip_trailing_slashes): Likewise.
27475         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
27476         ISSLASH): Likewise.
27477         * lib/rename.c (strip_trailing_slashes): Likewise.
27478         * lib/same.c (base_name): Likewise.
27479         * lib/stripslash.c (ISSLASH): Likewise.
27480
27481         * lib/addext.c: Include <dirname.h> after size_t is defined.
27482         * lib/backupfile.c: Likewise.
27483
27484         * lib/addext.c (addext): Use base_len to trim redundant
27485         trailing slashes instead of doing it ourselves.
27486         But do not trim the last slash if it is not redundant.
27487
27488         * lib/backupfile.c (find_backup_file_name,
27489         max_backup_version): Use base_len instead of rolling it ourselves.
27490         Handle the case of "" and (on DOS) "C:" correctly.
27491
27492         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
27493         needed. Include <string.h>, <dirname.h>.
27494         (base_name): Allow file names ending in slashes, other than names
27495         that are all slashes.  In this case, return the basename followed
27496         by the slashes.  This is more general, and can be used in places
27497         where the original base_name purposely had an assertion failure.
27498         (base_len): New function.
27499
27500         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
27501         Do not include <assert.h>; no longer needed.
27502         Include xalloc.h.
27503         (memrchr): Remove decl.
27504         (dir_name_r): Remove.
27505         (dir_len): Renamed from dirlen.  All callers changed.
27506         Rewrite in terms of base_name, for simplicity and consistency.
27507         (dir_name): Never return NULL.  All callers changed.
27508         Do not include <stdlib.h> in test program; no longer needed.
27509         return 0; is fine for test program.
27510
27511         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
27512         New macros.
27513         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
27514
27515         * lib/path-concat.c (path_concat): Use base_len to compute
27516         base length, not strlen; this means we cannot rely on memcpy
27517         to null-terminate.
27518
27519         * lib/same.c (STREQ): Remove.
27520         (same_name): Handle the case where the basename ends in trailing '/'.
27521
27522         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
27523         a slash was stripped.  Do not strip the last slash after a
27524         file system prefix.
27525
27526 2001-05-11  Paul Eggert  <eggert@twinsun.com>
27527
27528         * lib/Makefile.am (libfetish_a_SOURCES):
27529         Add strftime.c, since we now compile it on all hosts.
27530
27531         * lib/strftime.c (my_strftime):
27532         Define to nstrftime if emacs, but only if my_strftime is not defined.
27533         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
27534         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
27535         Add one more extra argument: a nanoseconds value.
27536         All uses changed.
27537         (ns): New macro.
27538         (my_strftime function): Add %N format.
27539         (emacs_strftimeu): Renamed from emacs_strftime,
27540         with extra ut argument.
27541
27542 2001-05-09  Paul Eggert  <eggert@twinsun.com>
27543
27544         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
27545
27546 2001-04-21  Jim Meyering  <meyering@lucent.com>
27547
27548         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
27549         doesn't interfere.
27550
27551 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
27552
27553         * m4/ftruncate.m4: Check for chsize.
27554         Link with ftruncate.o unconditionally if ftruncate is missing.
27555         This was required when cross-compiling to i586-mingw32msvc.
27556
27557 2001-04-08  Jim Meyering  <meyering@lucent.com>
27558
27559         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
27560         recomputed; that's necessary when the offset spans a DST transition.
27561         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
27562
27563 2001-04-02  Jim Meyering  <meyering@lucent.com>
27564
27565         * lib/regex.h, regex.c: Update from GNU libc.
27566
27567 2001-03-24  Jim Meyering  <meyering@lucent.com>
27568
27569         * m4/jm-macros.m4: Require autoconf-2.49d.
27570
27571 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
27572
27573         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
27574
27575 2001-03-19  Paul Eggert  <eggert@twinsun.com>
27576
27577         * lib/version-etc.c (version_etc_copyright): Update to 2001.
27578
27579 2001-03-17  Jim Meyering  <meyering@lucent.com>
27580
27581         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
27582         now that the version in autoconf is equivalent.
27583         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
27584
27585         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
27586         Suggestion from Akim Demaille.
27587
27588         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
27589         (jm_PREREQ_TEMPNAME): New function.
27590
27591 2001-03-16  Paul Eggert  <eggert@twinsun.com>
27592
27593         * lib/tempname.c (uint64_t): Define to uintmax_t if
27594         not defined, and if UINT64_MAX is not defined.
27595         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
27596         Reported by John David Anglin.
27597
27598 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
27599
27600         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
27601         resolve alias if codeset is empty.
27602         * lib/config.charset (BeOS): Use wildcard syntax.
27603
27604 2001-03-13  Jim Meyering  <meyering@lucent.com>
27605
27606         * lib/path-concat.c (path_concat)
27607         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
27608         concatenating e.g., `C:' and `foo'.
27609         From Bruno Haible.
27610
27611 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
27612
27613         * lib/localcharset.c (locale_charset): Don't use
27614         setlocale(LC_CTYPE,NULL). Don't return NULL.
27615         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
27616
27617 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
27618
27619         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
27620         support for DOS/DJGPP.
27621
27622 2001-03-01  Paul Eggert  <eggert@twinsun.com>
27623
27624         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
27625         lacks mkstemp.  Compile our own tempname.c if we compile our own
27626         mkstemp.c, as mkstemp relies on tempname.
27627
27628 2001-03-01  Jim Meyering  <meyering@lucent.com>
27629
27630         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
27631         AH_VERBATIM really does output its argument verbatim.
27632
27633 2001-02-28  Paul Eggert  <eggert@twinsun.com>
27634
27635         * lib/Makefile.am (libfetish_a_SOURCES):
27636         Add dup-safer.c, fopen-safer.c.
27637         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
27638
27639         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
27640         * lib/unistd-safer.h: New files.
27641
27642 2001-02-25  Paul Eggert  <eggert@twinsun.com>
27643
27644         The mkstemp replacement is taken from glibc 2.2.2, with some
27645         portability fixes for use outside glibc, as follows:
27646
27647         * lib/tempname.c (struct_stat64): New macro.
27648         (direxists, __gen_tempname): Use it.
27649         This avoids a portability problem with Solaris 8.
27650
27651         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
27652         (<stddef.h>, <stdint.h>, <string.h>):
27653         Include only if STDC_HEADERS || _LIBC.
27654         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
27655         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
27656         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
27657         (__set_errno): Define this macro if <errno.h> doesn't.
27658         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
27659         Define these macros if <stdio.h> doesn't.
27660         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
27661         Define these macros if <sys/stat.h>
27662         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
27663         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
27664         __xstat64): Define if not _LIBC.
27665         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
27666         (__gen_tempname): Invoke gettimeofday only if
27667         HAVE_GETTIMEOFDAY || _LIBC;
27668         otherwise, fall back on plain "time".
27669         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
27670
27671         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
27672
27673         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
27674
27675 2001-02-18  Paul Eggert  <eggert@twinsun.com>
27676
27677         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
27678
27679 2001-02-17  Paul Eggert  <eggert@twinsun.com>
27680
27681         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
27682         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
27683         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
27684         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
27685
27686 2001-02-17  Paul Eggert  <eggert@twinsun.com>
27687
27688         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
27689         Remove workaround macros for hosts that have mbrtowc but not
27690         mbstate_t, as we now insist on proper declarations for both
27691         before using mbrtowc.
27692
27693 2001-02-17  Jim Meyering  <meyering@lucent.com>
27694
27695         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
27696         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
27697         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
27698         UnixWare 7.1.1.
27699
27700         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
27701         rather than AC_CACHE_VAL.
27702
27703 2001-02-17  Jim Meyering  <meyering@lucent.com>
27704
27705         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
27706         around included file name.
27707
27708         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
27709
27710         * lib/strftime.c: Update from GNU libc (the only changes were to
27711         comments).
27712
27713 2001-02-17  Jim Meyering  <meyering@lucent.com>
27714
27715         * lib/regex.c: Update from libc.
27716
27717 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
27718
27719         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
27720         clash.
27721
27722 2001-02-16  Paul Eggert  <eggert@twinsun.com>
27723
27724         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
27725         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
27726         Reported by Mark Hounschell via Paul Eggert.
27727
27728 2001-02-07  Jim Meyering  <meyering@lucent.com>
27729
27730         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
27731
27732 2001-02-05  Jim Meyering  <meyering@lucent.com>
27733
27734         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
27735         it includes the patch required for `large file' support with at least
27736         HP-UX's 10.20 /bin/cc.
27737
27738 2001-02-03  Jim Meyering  <meyering@lucent.com>
27739
27740         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
27741         AS_IF, now that it works once again (mysteriously).
27742         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
27743
27744 2001-01-30  Jim Meyering  <meyering@lucent.com>
27745
27746         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
27747         * m4/chown.m4: Rename conftestchown to conftest.chown.
27748         * m4/rename.m4: s/conftestdir/conftest.d1/ and
27749         s/conftestdir2/conftest.d2/.
27750         * m4/utimes.m4: s/conftestdata/conftest.data/
27751         Inspired by Pavel Roskin's change in autoconf.
27752
27753 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
27754
27755         * lib/config.charset: Update for FreeBSD 4.2.
27756
27757 2001-01-27  Jim Meyering  <meyering@lucent.com>
27758
27759         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
27760         a use of AS_IF.
27761         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
27762
27763 2001-01-26  Jim Meyering  <meyering@lucent.com>
27764
27765         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
27766         quotearg.c includes it.
27767
27768 2001-01-26  Jim Meyering  <meyering@lucent.com>
27769
27770         * lib/quotearg.c: Include stddef.h.
27771         * lib/quote.c: Include stddef.h.
27772         Reported by Axel Kittenberger.
27773
27774         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
27775         line in double quotes so that it evokes a better diagnostic.
27776         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
27777         Reported by Axel Kittenberger.
27778
27779 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
27780
27781         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
27782         as if it was a `charset'.
27783
27784 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27785
27786         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
27787         has const.
27788
27789 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27790
27791         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
27792         to avoid a warning.  Add back 'const' to inptr.
27793
27794 2001-01-20  Jim Meyering  <meyering@lucent.com>
27795
27796         Be sure that headers are checked before used in code compiled
27797         for the type checks.
27798         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
27799         In place of that, invoke jm_CHECK_ALL_TYPES.
27800         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
27801         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
27802         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
27803         The check for ssize_t was mistakenly run before the test for unistd.h.
27804
27805         The configure-time check for stdbool.h was missing.
27806         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
27807         (jm_PREREQ_HASH): New function.
27808
27809 2001-01-17  Jim Meyering  <meyering@lucent.com>
27810
27811         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
27812         for autoconf-2.49c.
27813         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
27814
27815 2001-01-16  Jim Meyering  <meyering@lucent.com>
27816
27817         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
27818         From Bruno Haible.
27819
27820 2001-01-14  Jim Meyering  <meyering@lucent.com>
27821
27822         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
27823         foo and bar.  Create conftestdir/ in the script, not in the C code.
27824         Remove directories in the script, not in the C code.
27825         Remove conftestdir{,2} before trying to create the directory.
27826         Make the entire configure script fail if the mkdir fails.
27827
27828 2001-01-14  Jim Meyering  <meyering@lucent.com>
27829
27830         * lib/rename.c: New file.  From Volker Borchert.
27831         Include stdlib.h, string.h or strings.h, and xalloc.h.
27832         Use strip_trailing_slashes rather than open-coding it.
27833
27834 2001-01-03  Paul Eggert  <eggert@twinsun.com>
27835
27836         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
27837
27838 2001-01-03  Jim Meyering  <meyering@lucent.com>
27839
27840         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
27841         of local `inptr' to avoid warning with some system declarations of
27842         iconv.
27843
27844 2001-01-02  Volker Borchert  <bt@teknon.de>
27845
27846         * m4/rename.m4: New file.
27847         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
27848
27849 2001-01-01  Jim Meyering  <meyering@lucent.com>
27850
27851         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
27852         even on systems with utmpx.h.  It's necessary for the declaration of
27853         utmp's ut_user member.  Reported by Andreas Jaeger.
27854
27855         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
27856         available. They are required for the declarations of getgrgid and
27857         getpwuid resp.
27858         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
27859         Reported by Andreas Jaeger.
27860
27861 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
27862
27863         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
27864         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
27865         so `make install' also works in VPATH builds.
27866
27867 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
27868
27869         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
27870         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
27871         can be used in subdirectories.
27872
27873 2000-12-29  Paul Eggert  <eggert@twinsun.com>
27874
27875         * lib/modechange.c: Do not assume that mode_t uses the
27876         traditional octal encoding.  E.g. "chmod 1 FOO" should set
27877         the other-execute bit of FOO even if S_IXOTH != 1.
27878
27879         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
27880         WOTH, XOTH, ALLM): New macros.
27881         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
27882          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
27883         Use them.
27884         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
27885         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
27886         (mode_compile):
27887         No need to use uintmax_t; unsigned long is long enough.
27888         Don't bother to get suffix since we don't use it.
27889
27890 2000-12-26  Jim Meyering  <meyering@lucent.com>
27891
27892         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
27893         better with autoheader.
27894
27895 2000-12-24  Jim Meyering  <meyering@lucent.com>
27896
27897         * lib/hash.c (is_prime): Return explicit boolean values.
27898         (hash_get_first): Return NULL to appease Irix5.6's 89.
27899         Reported by Nelson Beebe.
27900
27901 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
27902
27903         * lib/localcharset.c (locale_charset): Add support for Win32.
27904
27905 2000-12-18  Paul Eggert  <eggert@twinsun.com>
27906
27907         * lib/physmem.h, lib/physmem.c: New files.
27908
27909         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
27910         (noinst_HEADERS): Add physmem.h.
27911
27912         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
27913         't' for compatibility with Solaris 8 sort.
27914
27915 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
27916
27917         * lib/config.charset: Add support for BeOS.
27918
27919 2000-12-17  Jim Meyering  <meyering@lucent.com>
27920
27921         * m4/dos.m4 (jm_AC_DOS): New file and macro.
27922         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
27923
27924 2000-12-16  Jim Meyering  <meyering@lucent.com>
27925
27926         This bug had a serious impact on chown: `chown N:M FILE' (for integer
27927         N and M) would have treated it like `chown N:N FILE'.
27928
27929         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
27930
27931 2000-12-16  Jim Meyering  <meyering@lucent.com>
27932
27933         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
27934         SHELLS_FILE to a file name that's useful on djgpp systems.
27935         Include stdlib.h.
27936         (ADDITIONAL_DEFAULT_SHELLS): Define.
27937         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
27938         Based mostly on a patch from Prashant TR.
27939
27940 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
27941
27942         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
27943         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
27944         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
27945
27946 2000-12-08  Andreas Schwab  <schwab@suse.de>
27947
27948         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
27949         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
27950
27951 2000-12-07  Jim Meyering  <meyering@lucent.com>
27952
27953         * lib/stripslash.c (ISSLASH): Define.
27954         (strip_trailing_slashes): Use ISSLASH rather than comparing against
27955         `/'.
27956         From Prashant TR.
27957
27958         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
27959         (dir_name_r): Declare this function as static.
27960         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
27961         manifest itself on a name containing a mix of slashes and
27962         backslashes.
27963         Make this function work with names starting with a DOS-style
27964         drive letter and colon prefix.
27965         (dir_name): Append `.' if necessary.
27966         Based mostly on patches from Prashant TR and Eli Zaretskii.
27967
27968         * lib/dirname.h (dir_name_r): Remove prototype.
27969
27970 2000-12-06  Paul Eggert  <eggert@twinsun.com>
27971
27972         * m4/off_t-format.m4: Remove this file.
27973         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
27974
27975 2000-12-06  Jim Meyering  <meyering@lucent.com>
27976
27977         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
27978         replacement strtoull, we may well need the replacement strtoul, too.
27979         Check for declarations of strtoul and strtoull.
27980         Check for strtol.  Mainly as a cue to cause automake to include
27981         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
27982         Check for limits.h -- strtol.c needs it.
27983
27984 2000-12-05  Jim Meyering  <meyering@lucent.com>
27985
27986         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
27987
27988 2000-12-04  Jim Meyering  <meyering@lucent.com>
27989
27990         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
27991         Also include memory.h, stdlib.h, unistd.h if appropriate.
27992         Reported by Andreas Jaeger (conflicting declaration of malloc).
27993
27994 2000-12-02  Jim Meyering  <meyering@lucent.com>
27995
27996         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
27997         * m4/jm-macros.m4 (jm_MACROS): require it.
27998
27999 2000-12-02  Jim Meyering  <meyering@lucent.com>
28000
28001         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
28002
28003 2000-12-01  Paul Eggert  <eggert@twinsun.com>
28004
28005         * lib/memrchr.c: Include <config.h> before any system include file.
28006
28007 2000-11-30  Jim Meyering  <meyering@lucent.com>
28008
28009         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
28010
28011 2000-11-30  Jim Meyering  <meyering@lucent.com>
28012
28013         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
28014
28015 2000-11-29  Paul Eggert  <eggert@twinsun.com>
28016
28017         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
28018
28019 2000-11-26  Jim Meyering  <meyering@lucent.com>
28020
28021         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
28022
28023 2000-11-22  Paul Eggert  <eggert@twinsun.com>
28024
28025         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
28026         size of (size_t) -1; it's not portable.
28027
28028 2000-11-17  Jim Meyering  <meyering@lucent.com>
28029
28030         * lib/strstr.c: Update from GNU libc.
28031
28032 2000-11-17  Akim Demaille  <akim@epita.fr>
28033
28034         * lib/obstack.h: Formatting changes.
28035         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
28036         prevent type checking.
28037         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
28038         cast the value to (void *): assigning a `foo *' to a `void *'
28039         variable is valid.
28040         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
28041
28042 2000-11-16  Jim Meyering  <meyering@lucent.com>
28043
28044         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
28045
28046 2000-11-11  Jim Meyering  <meyering@lucent.com>
28047
28048         * lib/error.c: Add a couple #includes, merging from GNU libc version.
28049
28050 2000-11-10  Jim Meyering  <meyering@lucent.com>
28051
28052         * lib/obstack.h: Update from GNU libc.
28053         * lib/obstack.c: Likewise.
28054
28055 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
28056
28057         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
28058
28059 2000-11-06  Paul Eggert  <eggert@twinsun.com>
28060
28061         * lib/getusershell.c (setusershell): Use rewind rather than
28062         fseek/fseeko, to avoid configuration hassles with fseeko.
28063         Don't bother opening SHELLS_FILE if shellstream is NULL;
28064         it's not necessary.
28065
28066 2000-11-05  Jim Meyering  <meyering@lucent.com>
28067
28068         * lib/makepath.h (make_dir): Declare.
28069         * lib/makepath.c (make_dir): Remove `static' attribute.
28070         Tweak a comment.
28071
28072 2000-11-04  Jim Meyering  <meyering@lucent.com>
28073
28074         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
28075
28076 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
28077
28078         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
28079         last one in a bucket, advance to the next bucket.
28080
28081 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
28082
28083         * lib/fnmatch.c: Do not comment out all the code if we are using
28084         the GNU C library, because in some cases we are replacing buggy
28085         code in the GNU C library itself.
28086
28087 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
28088
28089         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
28090         (regex_compile): Catch bogus \(\1\).
28091
28092 2000-10-30  Paul Eggert  <eggert@twinsun.com>
28093
28094         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
28095         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
28096         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
28097
28098 2000-10-30  Paul Eggert  <eggert@twinsun.com>
28099
28100         * lib/error.h, getline.h, modechange.h:
28101         Remove "2000" from Copyright line, as the file hasn't been
28102         changed this year other than in the copyright notice.
28103
28104         * lib/xalloc.h: Add "2000" to Copyright line, as this file
28105         was changed this year.
28106
28107 2000-10-29  Jim Meyering  <meyering@lucent.com>
28108
28109         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
28110         renaming.
28111         * m4/ls-mntd-fs.m4: Likewise
28112
28113 2000-10-29  Jim Meyering  <meyering@lucent.com>
28114
28115         * lib/xstat.in: Fix grammar in comment.
28116
28117 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
28118
28119         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
28120         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
28121         doesn't define __restrict_arr.
28122
28123 2000-10-28  Jim Meyering  <meyering@lucent.com>
28124
28125         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
28126         (jm_PREREQ_MEMCHR): New function.
28127
28128 2000-10-28  Jim Meyering  <meyering@lucent.com>
28129
28130         * lib/memchr.c: Update from libc.
28131         Adjust for portability:
28132         [HAVE_STDLIB_H]: Include stdlib.h.
28133         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
28134         Undef __memchr, too.
28135         [!weak_alias]: Define __memchr to memchr.
28136
28137         * lib/regex.c: Update from libc.
28138         * lib/regex.h: Likewise.
28139         * lib/getopt1.c: Likewise.
28140         * lib/memcmp.c: Likewise.
28141
28142         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
28143         Avoid using fseek, when possible -- it's broken by design.
28144         Patch by Ulrich Drepper.
28145
28146 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
28147
28148         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
28149         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
28150         Giving in to popular pressure to shut up the compiler with casts.
28151
28152 2000-10-26  Jim Meyering  <meyering@lucent.com>
28153
28154         * lib/strftime.c: Update from libc.
28155
28156 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
28157
28158         * regex.c: More `unsigned char' -> `re_char' changes.
28159         Also change several `int' into `re_wchar_t'.
28160         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
28161         (PUSH_FAILURE_POINTER): Don't cast any more.
28162         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
28163         We want GCC to complain, since this piece of code makes
28164         re_match non-reentrant, which *should* be fixed.
28165         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
28166         (EXTEND_BUFFER): Use RETALLOC.
28167         (SET_LIST_BIT): Don't cast.
28168         (re_wchar_t): New type.
28169         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
28170         that those two functions will always properly return.
28171         (IMMEDIATE_QUIT_CHECK): Cast to void.
28172         (analyse_first): Use recursion rather than an explicit stack.
28173         (re_compile_fastmap): Can't fail anymore.
28174         (re_search_2): Don't check re_compile_fastmap for failure.
28175         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
28176         Now also sets the new value (passed in a new argument).
28177         (re_match_2_internal): Use it.
28178         Also, use a new var `reg' of type size_t when looping through regs
28179         rather than reuse the inappropriate `mcnt'.
28180
28181 2000-10-25  Jim Meyering  <meyering@lucent.com>
28182
28183         * lib/obstack.c: Update from libc.
28184
28185 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
28186
28187         * regex.c (regex_compile): Change the way of handling a range from
28188         a char less than 256 to a char not less than 256.
28189
28190 2000-10-24  Andrew Innes  <andrewi@gnu.org>
28191
28192         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
28193         NT-Emacs only.
28194         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
28195         so that re_search functions only quit when callers expect them to.
28196
28197 2000-10-23  Jim Meyering  <meyering@lucent.com>
28198
28199         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
28200         wrong.  That set_locale call must not have any side effects.
28201         From Paul Eggert.
28202
28203 2000-10-22  Jim Meyering  <meyering@lucent.com>
28204
28205         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
28206         [CYCLIC]: Remove now-unused definition.
28207
28208         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
28209         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
28210         Suggestion from Ulrich Drepper.
28211
28212 2000-10-21  Jim Meyering  <meyering@lucent.com>
28213
28214         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
28215         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
28216         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
28217
28218 2000-10-21  Jim Meyering  <meyering@lucent.com>
28219
28220         * lib/dirname.c (memrchr): Declare if necessary.
28221         (dir_name): Remove the restriction that there be no
28222         trailing slashes.  Now, this code skips past them, effectively
28223         ignoring them.
28224         [TEST_DIRNAME] (main): New unit tests.
28225
28226         * lib/memrchr.c: New file from GNU libc.
28227         Undef __memrchr, too.
28228         [!weak_alias]: Define __memrchr to memrchr.
28229         Guard weak_alias use with `#ifdef weak_alias'.
28230
28231 2000-10-21  Jim Meyering  <meyering@lucent.com>
28232
28233         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
28234         (dir_name): Use dir_name_r.
28235         * lib/dirname.h (dir_name_r): Declare it.
28236
28237 2000-10-17  Jim Meyering  <meyering@lucent.com>
28238
28239         * lib/quote.h (PARAMS): Define and use.
28240         Reported by Akim Demaille.
28241
28242         * lib/getopt.c: Update from libc.
28243
28244 2000-10-16  Jim Meyering  <meyering@lucent.com>
28245
28246         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
28247         setlocale.
28248         From Jan Fedak.
28249
28250 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
28251
28252         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
28253
28254 2000-09-25  Jim Meyering  <meyering@lucent.com>
28255
28256         * lib/md5.h (rol): Define (from GnuPG).
28257
28258         * lib/sha.c: Give credit (GnuPG) where due.
28259         (M): Use rol rather than open-coding it.
28260         Add a FIXME comment.
28261
28262 2000-09-21  Jim Meyering  <meyering@lucent.com>
28263
28264         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
28265         Reported by Michael Stone.
28266
28267 2000-09-20  Jim Meyering  <meyering@lucent.com>
28268
28269         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
28270         (noinst_HEADERS): Add sha.h.
28271         Based on code from Scott G. Miller and from GnuPG.
28272
28273 2000-09-18  Jim Meyering  <meyering@lucent.com>
28274
28275         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
28276         LIBS. Otherwise, everyone ends up linking with -lelf for some
28277         configurations.
28278         Reported by Mike Stone.
28279
28280 2000-09-15  Jim Meyering  <meyering@lucent.com>
28281
28282         * lib/regex.c: Update from libc.
28283
28284 2000-09-10  Jim Meyering  <meyering@lucent.com>
28285
28286         * lib/getopt.c (_getopt_internal): Update from glibc.
28287
28288 2000-09-09  Jim Meyering  <meyering@lucent.com>
28289
28290         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
28291         think it should be used as a general replacement for isascii.
28292         * lib/fnmatch.c: Likewise.
28293         * lib/mbswidth.c: Likewise
28294         * lib/regex.c: Likewise.
28295
28296         Don't use atoi.
28297         * lib/userspec.c: Include sys/param.h and limits.h.
28298         Include xstrtol.h.
28299         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
28300         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
28301         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
28302         UID, GID.  Check range.
28303
28304 2000-09-06  Jim Meyering  <meyering@lucent.com>
28305
28306         * lib/getopt.c (_getopt_internal): Update from glibc.
28307
28308 2000-08-30  Jim Meyering  <meyering@lucent.com>
28309
28310         * lib/strftime.c: Merge in changes from GNU libc.
28311
28312 2000-08-26  Jim Meyering  <meyering@lucent.com>
28313
28314         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
28315         * m4/fpending.m4: New file.
28316
28317 2000-08-26  Jim Meyering  <meyering@lucent.com>
28318
28319         * lib/closeout.c: Include "__fpending.h".
28320         (close_stdout_status): Return right away if there's nothing to flush.
28321
28322         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
28323         * lib/__fpending.c: New file.
28324         * lib/__fpending.h: New file.
28325
28326 2000-08-20  Jim Meyering  <meyering@lucent.com>
28327
28328         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
28329         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
28330         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
28331
28332 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
28333
28334         Improve fileutils installation on systems where running
28335         programs (like install) can't be unlinked.
28336         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
28337         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
28338
28339 2000-08-07  Paul Eggert  <eggert@twinsun.com>
28340
28341         Standardize on "memory exhausted" instead of "Memory exhausted"
28342         or "virtual memory exhausted".
28343         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
28344         "virtual memory exhausted".
28345         * lib/same.c (same_name): Invoke xalloc_die instead of printing
28346         our own message.
28347         * lib/userspec.c (parse_user_spec): Likewise.
28348         * lib/bumpalloc.h: comment fix
28349         * lib/same.c, userspec.c: Include xalloc.h.
28350
28351         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
28352         not char *const and pointing to a constant array.
28353         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
28354         (xrealloc): Comment fix.
28355
28356         * lib/userspec.c (parse_user_spec):
28357         Don't translate a message until just before returning,
28358         to avoid unnecessary translation.
28359
28360 2000-08-07  Jim Meyering  <meyering@lucent.com>
28361
28362         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
28363         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
28364         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
28365         getgroups.c, gethostname.c, getopt.h, group-member.c,
28366         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
28367         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
28368         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
28369         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
28370         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
28371         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
28372         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
28373         yesno.c: Back out Copyright date changes for each file with no change
28374         this year.  This eases coordination with other programs using the same
28375         source code modules.  From Paul Eggert.
28376
28377 2000-08-06  Paul Eggert  <eggert@twinsun.com>
28378
28379         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
28380         not char, for compatibility with glibc 2.1.3 strftime.c.
28381
28382 2000-08-03  Greg McGary  <greg@mcgary.org>
28383
28384         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
28385         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
28386         (EXTEND_BUFFER): Use them.
28387
28388 2000-08-01  Jim Meyering  <meyering@lucent.com>
28389
28390         * lib/dirname.c (ISSLASH): Define.
28391         (BACKSLASH_IS_PATH_SEPARATOR): Define.
28392         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
28393         both `\' and `/' may be use as path separators.
28394         Based on a patch from Prashant TR.
28395
28396 2000-07-31  Paul Eggert  <eggert@twinsun.com>
28397
28398         * lib/quotearg.c (quotearg_n_options): Don't make the initial
28399         slot vector a constant, since it might get modified.
28400
28401 2000-07-31  Jim Meyering  <meyering@lucent.com>
28402
28403         * lib/xmalloc.c: Use `virtual memory exhausted', not
28404         `Memory exhausted'.
28405         * lib/obstack.c (print_and_abort): Likewise.
28406
28407 2000-07-30  Paul Eggert  <eggert@twinsun.com>
28408
28409         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
28410         buffer, so that the caller can always quote one small
28411         component of a "memory exhausted" message in slot 0.
28412         From a suggestion by Jim Meyering.
28413
28414 2000-07-30  Jim Meyering  <meyering@lucent.com>
28415
28416         * lib/makepath.c (make_path): Quote the other instance, too.
28417
28418         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
28419         (STATIC_BUF_SIZE): Define.
28420         (quotearg_n_options): Use only statically allocated storage when
28421         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
28422         than STATIC_BUF_SIZE.
28423
28424 2000-07-29  Jim Meyering  <meyering@lucent.com>
28425
28426         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
28427         * lib/dirname.c (dir_name): Likewise.
28428
28429         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
28430         `/'.
28431
28432         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
28433         (dir_name): Assert that there are no trailing slashes.
28434
28435 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
28436
28437         * lib/mbswidth.h (mbswidth): Add a flags argument.
28438         (mbswidth): New declaration.
28439         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
28440         * lib/mbswidth.c (mbswidth): Add a flags argument.
28441         (mbsnwidth): New function.
28442
28443 2000-07-24  Jim Meyering  <meyering@lucent.com>
28444
28445         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
28446
28447 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28448
28449         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
28450
28451 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28452
28453         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
28454         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
28455         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
28456         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
28457         invoke multibyte primitives.
28458
28459 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28460
28461         * lib/quotearg.c:
28462         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
28463         so that mbstate_t is always defined.
28464
28465         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
28466         be 1 in at least one GCC installation, and this configuration
28467         error is likely to be common.  Ignoring MB_LEN_MAX hurts
28468         performance on hosts that have mbrtowc but have only unibyte
28469         locales, but I assume these hosts are rare.
28470
28471 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28472
28473         * lib/mbswidth.c (_XOPEN_SOURCE):
28474         Don't define; this causes problems on Solaris 7.
28475         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
28476
28477 2000-07-23  Jim Meyering  <meyering@lucent.com>
28478
28479         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
28480         too: getgrgid, getpwuid, getuid.
28481
28482 2000-07-23  Jim Meyering  <meyering@lucent.com>
28483
28484         * lib/basename.c (base_name): Add an assertion.
28485
28486 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
28487
28488         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
28489         shadow its mbsinit function.
28490
28491 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
28492
28493         * lib/mbswidth.h: New file.
28494         * lib/mbswidth.c: New file.
28495         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
28496         (noinst_HEADERS): Add mbswidth.h.
28497
28498 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
28499
28500         * lib/config.charset: Add support for FreeBSD. Improve support for
28501         HP-UX and IRIX 6.
28502
28503 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
28504
28505         * m4/mbswidth.m4: New file.
28506         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
28507
28508 2000-07-15  Jim Meyering  <meyering@lucent.com>
28509
28510         * lib/makepath.c: Include quote.h.
28511         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
28512         corresponding argument in a `quote (...)' call.
28513         Give better diagnostics.
28514
28515         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
28516         (noinst_HEADERS): Add quote.h.
28517
28518         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
28519         from tar's src/misc.c.
28520         * lib/quote.h: New file.  Prototypes for same.
28521
28522 2000-07-14  Paul Eggert  <eggert@twinsun.com>
28523
28524         From a suggestion by Bruno Haible.
28525         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
28526         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
28527         to decide whether to define the BeOS workaround macro;
28528         this adjusts to the change to AC_MBSTATE_T.
28529
28530 2000-07-14  Jim Meyering  <meyering@lucent.com>
28531
28532         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
28533         jm_AC_TYPE_UINTMAX_T.
28534
28535 2000-07-13  Paul Eggert  <eggert@twinsun.com>
28536
28537         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
28538
28539         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
28540         quotearg_buffer_restyled): Add support for
28541         clocale_quoting_style.  Undo previous change to
28542         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
28543         and "{RIGHT QUOTATION MARK}" msgids.
28544
28545 2000-07-10  Paul Eggert  <eggert@twinsun.com>
28546
28547         From a suggestion by Bruno Haible.
28548         * m4/mbstate_t.m4 (AC_MBSTATE_T):
28549         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
28550         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
28551         and mbstate_t, to a single-part test that simply defines mbstate_t.
28552         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
28553         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
28554
28555 2000-07-10  Jim Meyering  <meyering@lucent.com>
28556
28557         * m4/strerror_r.m4: Mirror the correction made in autoconf.
28558
28559         * m4/gnu-source.m4: Output to confdefs.h directly.
28560         Suggestion from Akim Demaille.
28561
28562 2000-07-09  Paul Eggert  <eggert@twinsun.com>
28563
28564         The old behavior of quoting `like this' doesn't look good with
28565         newer, ISO-style fonts.  See:
28566         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
28567
28568         Instead, quote "like this" by default.  Let the translator
28569         tailor the locale-specific quoting behavior by providing
28570         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
28571
28572         * lib/quotearg.c (N_): New macro.
28573         (gettext_default): New function.
28574         (quotearg_buffer_restyled): Use
28575         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
28576         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
28577
28578 2000-07-09  Jim Meyering  <meyering@lucent.com>
28579
28580         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
28581         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
28582
28583         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
28584         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
28585
28586 2000-07-09  Jim Meyering  <meyering@lucent.com>
28587
28588         * lib/Most files: Update copyright dates to include 2000.
28589
28590 2000-07-08  Jim Meyering  <meyering@lucent.com>
28591
28592         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
28593         if not defined.
28594         (xgethostname): Remove now-unnecessary #ifdef.
28595         Move declaration of `err' into loop where it's used.
28596
28597 2000-07-05  Paul Eggert  <eggert@twinsun.com>
28598         and Bruno Haible  <haible@clisp.cons.org>
28599
28600         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
28601         only if the test for an object-type mbstate_t fails.  This
28602         prevents us from mistakenly reporting that mbstate_t is a
28603         system object type after we "#define mbstate_t int" to work
28604         around its lack.
28605
28606 2000-07-05  Paul Eggert  <eggert@twinsun.com>
28607         and Bruno Haible  <haible@clisp.cons.org>
28608
28609         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
28610
28611 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28612
28613         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
28614         to strerror_r.
28615         Include <ctype.h> for use of isalpha.
28616
28617 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28618
28619         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
28620         by allocating a larger buffer. Test the gethostname return value for
28621         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
28622         returns an error and ENAMETOOLONG isn't defined.
28623
28624 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28625
28626         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
28627         dimension.
28628
28629 2000-07-04  Jim Meyering  <meyering@lucent.com>
28630
28631         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
28632         of the deprecated AC_CHECKING.
28633
28634 2000-07-04  Jim Meyering  <meyering@lucent.com>
28635
28636         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
28637         Reported by Bruno Haible.
28638
28639 2000-07-04  Jim Meyering  <meyering@lucent.com>
28640
28641         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
28642         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
28643         lacks mbrtowc.
28644
28645 2000-07-03  Paul Eggert  <eggert@twinsun.com>
28646
28647         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
28648         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
28649
28650 2000-07-03  Paul Eggert  <eggert@twinsun.com>
28651         and Bruno Haible  <haible@clisp.cons.org>
28652
28653         * lib/quotearg.c (mbrtowc):
28654         Assign to *pwc, and return 1 only if result is nonzero.
28655         (iswprint): Use ISPRINT when substituting our own mbrtowc.
28656
28657 2000-07-03  Jim Meyering  <meyering@lucent.com>
28658
28659         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
28660
28661 2000-07-03  Jim Meyering  <meyering@lucent.com>
28662
28663         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
28664         This is necessary to get a definition of e.g., UTMP_FILE on
28665         HP-UX 10.20.
28666         From Bob Proulx.
28667
28668 2000-07-02  Jim Meyering  <meyering@lucent.com>
28669
28670         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
28671
28672         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
28673         AC_LIBOBJ(function_name).
28674         * m4/chown.m4: Likewise.
28675         * m4/fnmatch.m4: Likewise.
28676         * m4/ftruncate.m4: Likewise.
28677         * m4/getgroups.m4: Likewise.
28678         * m4/getline.m4: Likewise.
28679         * m4/group-member.m4: Likewise.
28680         * m4/jm-macros.m4: Likewise.
28681         * m4/lstat.m4: Likewise.
28682         * m4/malloc.m4: Likewise.
28683         * m4/memcmp.m4: Likewise.
28684         * m4/nanosleep.m4: Likewise.
28685         * m4/putenv.m4: Likewise.
28686         * m4/realloc.m4: Likewise.
28687         * m4/regex.m4: Likewise.
28688         * m4/stat.m4: Likewise.
28689         * m4/strftime.m4: Likewise.
28690
28691 2000-07-02  Jim Meyering  <meyering@lucent.com>
28692
28693         * lib/quotearg.c (mbstate_t): Don't define here.
28694
28695 2000-07-02  Jim Meyering  <meyering@lucent.com>
28696
28697         * lib/nanosleep.c (SIGCONT): Define if not already defined.
28698
28699 2000-07-01  Jim Meyering  <meyering@lucent.com>
28700
28701         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
28702
28703 2000-07-01  Jim Meyering  <meyering@lucent.com>
28704
28705         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
28706         problem.
28707
28708 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
28709
28710         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
28711         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
28712
28713 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
28714
28715         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
28716         per change in ../m4/ls-mntd-fs.m4.
28717         (read_filesystem_list): Ignore symbolic links.
28718
28719 2000-06-29  Jim Meyering  <meyering@lucent.com>
28720
28721         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
28722         for declaration of strcmp.
28723
28724         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
28725
28726         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
28727         Avoid warning by casting result to `char *' to remove `const'.
28728
28729 2000-06-28  Jim Meyering  <meyering@lucent.com>
28730
28731         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
28732         included by quotearg.c, for which we perform this test.  From
28733         Bruno Haible.
28734
28735 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
28736
28737         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
28738         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
28739         <utmpx.h> exists, put readutmp.o into LIBOBJS.
28740
28741 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
28742
28743         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
28744
28745 2000-06-26  Paul Eggert  <eggert@twinsun.com>
28746
28747         savedir now sets errno on failure and invokes xmalloc to get memory.
28748         Fix a couple of other minor bugs while we're at it.
28749
28750         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
28751         (NAMLEN): Remove macro.
28752         (malloc, realloc): Remove decls.
28753         (stpcpy): Likewise.
28754         ("xalloc.h"): Include.
28755         (NAME_SIZE_DEFAULT): New macro.
28756         (savedir): Use xmalloc / xrealloc to allocate memory.
28757         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
28758         Skip "" directory entries.
28759         Use strlen to calculate directory entry length, since the old method
28760         is rarely used these days and isn't worth supporting.
28761         Don't use a pointer after freeing it.
28762         Check for integer overflow when calculating allocation size.
28763         Use memcpy to copy entries, instead of stpcpy.
28764         Set errno properly when returning NULL.
28765         Check for readdir error.
28766
28767 2000-06-26  Jim Meyering  <meyering@lucent.com>
28768
28769         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
28770
28771 2000-06-25  Jim Meyering  <meyering@lucent.com>
28772
28773         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
28774         Linux header bug when _XOPEN_SOURCE is defined to 500.
28775
28776 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28777
28778         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
28779         deficiency.
28780
28781 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28782
28783         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
28784         Include xalloc.h.
28785         Don't include <stdlib.h>.  Don't declare malloc, realloc.
28786
28787 2000-06-24  Jim Meyering  <meyering@lucent.com>
28788
28789         * m4/strerror_r.m4: Revive this file -- to try out an experimental
28790         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
28791         for which strerror does return char*, but which lacks a conveniently
28792         accessible declaration of the function.  If the compile-test says
28793         strerror_r doesn't work, then resort to a `run'-test that works on
28794         BeOS and segfaults on DEC Unix.
28795
28796 2000-06-24  Jim Meyering  <meyering@lucent.com>
28797
28798         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
28799
28800 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28801
28802         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
28803         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
28804
28805 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28806
28807         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
28808         (mbrtowc, mbstate_t): Define substitutes if
28809         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
28810         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
28811         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
28812
28813 2000-06-23  Jim Meyering  <meyering@lucent.com>
28814
28815         * m4/afs.m4: Add missing AC_MSG_RESULT.
28816         Reported by Bruno Haible.
28817
28818         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
28819         Suggestion from Bruno Haible.
28820
28821 2000-06-23  Jim Meyering  <meyering@lucent.com>
28822
28823         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
28824
28825 2000-06-21  Jim Meyering  <meyering@lucent.com>
28826
28827         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
28828
28829 2000-06-21  Jim Meyering  <meyering@lucent.com>
28830
28831         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
28832         (noinst_HEADERS): Add getstr.h.
28833
28834         * lib/getline.c (getstr): Move into a separate file.
28835         * lib/getstr.c (getstr): New file, extracted from getline.c, with
28836         the following changes: new parameter, delim2; both delim[12]
28837         parameters have type `int', not `char'.  The latter would lose
28838         with 8-bit delimiters.
28839         * lib/getstr.h: New file.
28840
28841 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28842
28843         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
28844         than 1024, return a memory chunk of least possible size, instead
28845         of size PATH_MAX + 2. In the loop, increment the size proportionally.
28846         Use free/xmalloc instead of xrealloc to avoid copying for very long
28847         paths.
28848
28849 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28850
28851         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
28852         the empty string.
28853
28854 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28855
28856         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
28857         address, not strdup.  Include <stdlib.h> and don't declare free().
28858
28859 2000-06-19  Jim Meyering  <meyering@lucent.com>
28860
28861         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
28862
28863 2000-06-18  Jim Meyering  <meyering@lucent.com>
28864
28865         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
28866
28867         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
28868         `checking whether...' message to be consistent with that of the
28869         lstat test.
28870
28871 2000-06-18  Jim Meyering  <meyering@lucent.com>
28872
28873         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
28874         Besides, these days every porting target provides a mkdir function.
28875
28876         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
28877         needed. (this snippet comes from src/system.h).
28878
28879 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
28880
28881         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
28882
28883 2000-06-15  Paul Eggert  <eggert@twinsun.com>
28884
28885         * lib/human.c (adjust_value): New function.
28886         (human_readable_inexact): Apply rounding style even when
28887         printing approximate values.
28888
28889 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28890
28891         * lib/human.c (human_readable_inexact): Allow an input block
28892         size that is not a multiple of the output block size, and vice versa.
28893         Reported by Piergiorgio Sartor.
28894
28895 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28896
28897         * lib/getdate.y (get_date): Apply relative times after time
28898         zone indicator, not before.  Reported by Todd A. Jacobs.
28899
28900 2000-06-13  Jim Meyering  <meyering@lucent.com>
28901
28902         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
28903
28904         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
28905
28906 2000-06-12  Paul Eggert  <eggert@twinsun.com>
28907
28908         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
28909
28910 2000-06-12  Jim Meyering  <meyering@lucent.com>
28911
28912         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
28913         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
28914         optional argument.
28915         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
28916         the optional argument, `lib'.
28917
28918 2000-06-08  Jim Meyering  <meyering@lucent.com>
28919
28920         * m4/largefile.m4: Remove file (now that it's part of autoconf).
28921
28922 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28923
28924         Rewrite largefile configuration so that we don't need to run
28925         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
28926         AC_CANONICAL_HOST in configure.in -- jmm]
28927
28928         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
28929         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
28930         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
28931         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
28932         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
28933         All uses changed.
28934         Instead of inspecting the output of getconf, try to compile the
28935         test program without and with the macro definition.
28936         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
28937         for getconf.  Instead, check for the needed flags by compiling
28938         test programs.
28939
28940 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28941
28942         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
28943
28944 2000-06-04  Jim Meyering  <meyering@lucent.com>
28945
28946         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
28947         SunOS 4.1.4 for which gid_t is an unsigned type.
28948
28949 2000-06-03  Jim Meyering  <meyering@lucent.com>
28950
28951         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
28952         now that autoconf requires that.
28953
28954         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
28955         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
28956         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
28957
28958 2000-06-03  Jim Meyering  <meyering@lucent.com>
28959
28960         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
28961
28962 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28963
28964         * m4/glibc21.m4: New file.
28965         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
28966
28967 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28968
28969         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
28970         newer, don't install charset.alias.
28971         * lib/config.charset: Change the Linux/glibc rules so they become empty
28972         on glibc-2.1 or newer.
28973
28974 2000-06-02  Jim Meyering  <meyering@lucent.com>
28975
28976         * lib/mountlist.c: Back out last change.  Instead, do this...
28977         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
28978         me_dummy member using the same `ignore'-testing code.
28979         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
28980         fs_type strings.
28981         From Mark D. Roth.
28982
28983 2000-05-29  Jim Meyering  <meyering@lucent.com>
28984
28985         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
28986         mounts with the `ignore' attribute.  Based on a patch from
28987         Mark D. Roth.
28988
28989 2000-05-28  Jim Meyering  <meyering@lucent.com>
28990
28991         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
28992         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28993         * m4/stat.m4: Likewise.
28994         * m4/lstat.m4: Likewise.
28995         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
28996
28997         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
28998         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
28999
29000 2000-05-26  Jim Meyering  <meyering@lucent.com>
29001
29002         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
29003
29004 2000-05-24  Jim Meyering  <meyering@lucent.com>
29005
29006         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
29007         autoconf requires that.
29008         * m4/lib-check.m4: Likewise.
29009         * m4/jm-macros.m4: Likewise.
29010         * m4/strftime.m4: Likewise.
29011
29012         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
29013         AC_CHECK_DECLS, now that autoconf requires that.
29014
29015 2000-05-22  Jim Meyering  <meyering@lucent.com>
29016
29017         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29018         * m4/lstat.m4: Likewise.
29019
29020 2000-05-22  Jim Meyering  <meyering@lucent.com>
29021
29022         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
29023
29024 2000-05-20  Jim Meyering  <meyering@lucent.com>
29025
29026         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
29027         (jm_PREREQ): Use it.
29028
29029 2000-05-18  Jim Meyering  <meyering@lucent.com>
29030
29031         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
29032         back, too, since it may have been modified by allocate_entry.
29033         (hash_delete): Rewrite to use neither the assignment operator
29034         nor the comma operator in an if-expression.
29035
29036 2000-05-15  Paul Eggert  <eggert@twinsun.com>
29037
29038         * lib/closeout.c:
29039         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
29040         Remove; no longer needed.
29041         "quotearg.h": Add include.
29042         (file_name): Do not bother to explicitly initialize to NULL; it's less
29043         efficient on some hosts.
29044         (close_stdout_status): Remove test as to whether stdout was already
29045         closed; it breaks for the case "echo x | sort >&-".
29046         Quote file name colons.
29047         Do not assume that _("write error") lacks format strings.
29048
29049 2000-05-15  Jim Meyering  <meyering@lucent.com>
29050
29051         * lib/version-etc.c (version_etc_copyright): Update the copyright
29052         string used in all --version output.
29053
29054 2000-05-14  Jim Meyering  <meyering@lucent.com>
29055
29056         * lib/closeout.c (close_stdout_set_file_name): New function.
29057         (close_stdout_status): Use new file-scoped global.
29058         Return right away if fstat says the stdout file descriptor is invalid.
29059         * lib/closeout.h (close_stdout_set_file_name): Declare.
29060
29061 2000-05-10  Jim Meyering  <meyering@lucent.com>
29062
29063         * lib/closeout.c [default_exit_status]: New file-scoped variable.
29064         (close_stdout_set_status): New function.
29065         * lib/closeout.h (close_stdout_set_status): Declare.
29066
29067 2000-05-09  Jim Meyering  <meyering@lucent.com>
29068
29069         * m4/gettext.m4: Rename this...
29070         * m4/libintl.m4: ...to this.
29071
29072 2000-05-08  Jim Meyering  <meyering@lucent.com>
29073
29074         * lib/long-options.c: Don't include closeout.h.
29075         (parse_long_options): Don't call close_stdout for --version.
29076
29077 2000-05-06  Paul Eggert  <eggert@twinsun.com>
29078
29079         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
29080         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
29081         2.1.3 bug.  This avoids a clash when files like regex.c define
29082         _GNU_SOURCE.
29083
29084 2000-05-06  Jim Meyering  <meyering@lucent.com>
29085
29086         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
29087         (AC_REPLACE_FUNCS): Add strnlen.
29088
29089         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
29090         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
29091
29092         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
29093         AC_SEARCH_LIBS call for nanosleep.
29094         (LIB_NANOSLEEP): Set and AC_SUBST.
29095
29096 2000-05-06  Jim Meyering  <meyering@lucent.com>
29097
29098         * lib/strnlen.c: Undefine __strnlen and strnlen.
29099         [!weak_alias]: Define __strnlen to strnlen.
29100
29101         * lib/atexit.c: New file, from libiberty.
29102
29103 2000-05-06  Jim Meyering  <meyering@lucent.com>
29104
29105         * lib/closeout.c (close_stdout_status): Also check for errors on the
29106         stderr stream.
29107
29108 2000-05-05  Jim Meyering  <meyering@lucent.com>
29109
29110         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
29111         AC_SEARCH_LIBS call for clock_gettime.
29112         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
29113
29114         * m4/search-libs.m4: Update from autoconf.
29115
29116         su doesn't work on Solaris 2.6.
29117         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
29118         <shadow.h>.  Reported by Dragos Harabor.
29119
29120 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
29121
29122         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
29123         memcpy instead of xmalloc, xrealloc, path_concat.
29124         (locale_charset): Treat empty environment variables as absent.
29125         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
29126
29127 2000-05-04  Jim Meyering  <meyering@lucent.com>
29128
29129         * lib/getopt.c: Update from glibc.
29130         * lib/obstack.c: Likewise.
29131         * lib/obstack.h: Likewise.
29132         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
29133         file
29134
29135         * lib/regex.h: Likewise.
29136         * lib/strndup.c: Likewise.
29137         * lib/strnlen.c: New file, from glibc.
29138
29139 2000-05-03  Jim Meyering  <meyering@lucent.com>
29140
29141         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
29142
29143 2000-05-02  Paul Eggert  <eggert@twinsun.com>
29144
29145         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
29146         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
29147         compile-time test, rather than inspecting host and OS, to
29148         decide whether to define _LARGEFILE_SOURCE.
29149
29150 2000-05-01  Jim Meyering  <meyering@lucent.com>
29151
29152         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
29153
29154         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
29155         Based on a patch from Bruno Haible.
29156
29157 2000-05-01  Jim Meyering  <meyering@lucent.com>
29158
29159         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
29160
29161 2000-04-29  Jim Meyering  <meyering@lucent.com>
29162
29163         * lib/path-concat.c: Declare strdup only if it's not defined.
29164         * lib/canon-host.c: Likewise.
29165
29166 2000-04-28  Jim Meyering  <meyering@lucent.com>
29167
29168         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
29169         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
29170         is included first, then limits.h is included by locale.h by libintl.h.
29171         From John David Anglin.
29172
29173 2000-04-25  Jim Meyering  <meyering@lucent.com>
29174
29175         * lib/makepath.c (S_IRWXUGO): Define.
29176         (make_path): Always perform explicit chmod if MODE specifies any
29177         of the `special' permission bits.  Prompted by a bug report against
29178         install from Mate Wierdl and Joost van Baal.
29179
29180 2000-04-18  Jim Meyering  <meyering@lucent.com>
29181
29182         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
29183         (jm_PREREQ): Use it.
29184
29185 2000-04-18  Jim Meyering  <meyering@lucent.com>
29186
29187         * lib/README: New file.
29188
29189         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
29190         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
29191
29192 2000-04-17  Jim Meyering  <meyering@lucent.com>
29193
29194         Get it right :-)
29195         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
29196         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
29197         Suggestion from Akim Demaille.
29198
29199 2000-04-17  Jim Meyering  <meyering@lucent.com>
29200
29201         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
29202         the definition of it to rpl_strftime also defined-away the system's
29203         declaration.
29204
29205 2000-04-15  Jim Meyering  <meyering@lucent.com>
29206
29207         Use `C' to denote so-called `contiguous' files, the same way
29208         that tar does.
29209         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
29210         (ftypelet): Use S_ISCTG.
29211         From Michael Deutschmann.
29212
29213 2000-04-14  Jim Meyering  <meyering@lucent.com>
29214
29215         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
29216         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
29217         clobbered.
29218
29219 2000-04-14  Jim Meyering  <meyering@lucent.com>
29220
29221         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
29222
29223 2000-04-13  Jim Meyering  <meyering@lucent.com>
29224
29225         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
29226         AH_VERBATIM to insert required #ifndef into config.h.in.
29227         Suggestion from Akim Demaille.
29228
29229 2000-04-12  Jim Meyering  <meyering@lucent.com>
29230
29231         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
29232         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
29233         Christian Krackowizer.
29234
29235         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
29236         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
29237         (AC_SYS_LARGEFILE): Require.
29238         (AM_C_PROTOTYPES): Require.
29239
29240 2000-04-08  Jim Meyering  <meyering@lucent.com>
29241
29242         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
29243         names don't conflict.  Reported by Eli Zaretskii.
29244
29245 2000-04-07  Jim Meyering  <meyering@lucent.com>
29246
29247         * lib/putenv.c: Move inclusion of errno.h so it follows that of
29248         sys/types.h, to work around system header problems on AIX 3.2.5.
29249         From Bruno Haible.
29250
29251 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
29252
29253         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
29254         bug.  Deal with the different error behavior of Irix iconv.
29255
29256 2000-04-05  Paul Eggert  <eggert@twinsun.com>
29257
29258         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
29259         IRIX if the installer said otherwise.
29260
29261 2000-04-05  Jim Meyering  <meyering@lucent.com>
29262
29263         Portability tweaks required for ultrix4.3.
29264         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
29265         (jm_CHECK_DECLS): Add getutent to the list of functions.
29266         (_jm_DECL_HEADERS): Add utmpx.h.
29267         From John David Anglin.
29268
29269         * m4/strftime.m4: Back out the 2000-04-02 change.
29270         Instead of that change, simply undefine putenv in the test program.
29271
29272 2000-04-05  Jim Meyering  <meyering@lucent.com>
29273
29274         Portability tweaks required for ultrix4.3.
29275         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
29276         getutent.
29277         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
29278         * lib/canon-host.c: Declare strdup.
29279         * lib/path-concat.c: Likewise.
29280         From John David Anglin.
29281
29282 2000-04-04  Jim Meyering  <meyering@lucent.com>
29283
29284         Be more DOS 8.3-friendly.
29285         * lib/ref-add.sin: Renamed from ref-add.sed.in.
29286         * lib/ref-del.sin: Renamed from ref-del.sed.in.
29287         * lib/Makefile.am: Reflect renaming.
29288         Reported by Eli Zaretskii.
29289
29290         Use a temporary file name that won't clash with `charset.alias'
29291         in the DOS 8.3 name space.
29292         * lib/Makefile.am (charset_tmp): Define.
29293         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
29294         (uninstall-local): Likewise.
29295         Reported by Eli Zaretskii.
29296
29297 2000-04-03  Jim Meyering  <meyering@lucent.com>
29298
29299         * m4/gettext.m4: Fix typo in comment.
29300
29301         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
29302         textutils/configure.in).  Suggestion from Paul Eggert.
29303         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
29304
29305 2000-04-02  Paul Eggert  <eggert@twinsun.com>
29306
29307         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
29308         variable in the shell rather than using putenv, which isn't
29309         portable.  This avoids the configure-time inter-test dependency
29310         on the potentially-renamed putenv function.
29311
29312 2000-03-30  Paul Eggert  <eggert@twinsun.com>
29313
29314         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
29315         before checking struct stat.st_blksize, so that
29316         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
29317
29318 2000-03-29  Paul Eggert  <eggert@twinsun.com>
29319
29320         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
29321         since strftime.c uses HAVE_STRFTIME to decide whether to use
29322         the underlying strftime.
29323
29324 2000-03-29  Paul Eggert  <eggert@twinsun.com>
29325
29326         * lib/time/strftime.c (my_strftime): Make sure we call the system
29327         strftime, not ourselves, when invoking the underlying strftime.
29328
29329 2000-03-24  Jim Meyering  <meyering@lucent.com>
29330
29331         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
29332         (charset_alias): Define.
29333         (install-exec-local): Factor out common code.
29334         (uninstall-local): Split lines longer than 80.
29335         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
29336         (SUFFIXES): Define.
29337         (.sed.in.sed): New rule.  Don't redirect directly to $@.
29338         (CLEANFILES): Add ref-add.sed and ref-del.sed.
29339
29340 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
29341
29342         * lib/config.charset: Output a line containing "Packages using this
29343         file".
29344         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
29345         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
29346         ref-del.sed): New rules.
29347
29348 2000-03-17  Jim Meyering  <meyering@lucent.com>
29349
29350         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
29351         Otherwise, include <strings.h>
29352
29353 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
29354
29355         * lib/unicodeio.c (utf8_wctomb): New function.
29356         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
29357         format instead of in UCS-4 with platform dependent endianness.
29358
29359 2000-03-10  Jim Meyering  <meyering@lucent.com>
29360
29361         * m4/lib-check.m4: Look for getspnam in -lgen, too.
29362         From Marco Franzen.
29363
29364 2000-03-07  Paul Eggert  <eggert@twinsun.com>
29365
29366         * lib/savedir.c (savedir): Work even if directory size is
29367         negative; this can happen with some screwy NFS configurations.
29368
29369 2000-03-06  Jim Meyering  <meyering@lucent.com>
29370
29371         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
29372         if it's NULL (because we ran out of memory).  From Bruno Haible.
29373
29374 2000-03-05  Jim Meyering  <meyering@lucent.com>
29375
29376         * lib/localcharset.c ("path-concat.h"): Include.
29377         (get_charset_aliases): Use path_concat instead of ANSI string
29378         concatenation.
29379
29380         * lib/unicodeio.h (PARAMS): Define.
29381         Use it to guard prototype.
29382
29383 2000-03-04  Jim Meyering  <meyering@lucent.com>
29384
29385         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
29386         for lib/localcharset.c.
29387
29388 2000-03-04  Jim Meyering  <meyering@lucent.com>
29389
29390         * lib/Makefile.am (install-exec-local): Create $(libdir) before
29391         installing into it.
29392         (uninstall-local): Uncomment this rule so `make distcheck' works
29393         once again.
29394
29395         * lib/unicodeio.c (<errno.h>): Include it.
29396         (errno): Declare if not defined.
29397
29398         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
29399
29400         * lib/config.charset: New version, incorporating remarks from a linux
29401         i18n mailing list.  From Bruno Haible.
29402
29403 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
29404
29405         * m4/codeset.m4: New file.
29406         * m4/iconv.m4: New file.
29407         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
29408
29409 2000-03-03  Jim Meyering  <meyering@lucent.com>
29410
29411         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
29412
29413 2000-03-02  Jim Meyering  <meyering@lucent.com>
29414
29415         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
29416         the messages come out on separate lines.
29417
29418         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
29419         rather than jm_CHECK_DECLARATIONS.
29420         * m4/decl.m4: Remove now-unused file.
29421
29422         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
29423         geteuid.
29424
29425 2000-03-02  Jim Meyering  <meyering@lucent.com>
29426
29427         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
29428
29429 2000-03-01  Jim Meyering  <meyering@lucent.com>
29430
29431         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
29432         * lib/unicodeio.c: Likewise.
29433
29434 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
29435
29436         * lib/config.charset: New file.
29437         * lib/localcharset.c: New file.
29438         * lib/unicodeio.h, lib/unicodeio.c: New files.
29439         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
29440         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
29441         (noinst_HEADERS): Add unicodeio.h.
29442         (all-local, install-exec-local, charset.alias): New targets.
29443
29444 2000-02-28  Paul Eggert  <eggert@twinsun.com>
29445
29446         * lib/quotearg.c (ALERT_CHAR): New macro.
29447         (quotearg_buffer_restyled): Use it.
29448
29449 2000-02-27  Jim Meyering  <meyering@lucent.com>
29450
29451         * m4/check-decl.m4: Add getenv to the list.
29452
29453 2000-02-27  Jim Meyering  <meyering@lucent.com>
29454
29455         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
29456         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
29457
29458         * lib/backupfile.c: Guard inclusion of stdlib.h with
29459         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
29460         Declare malloc if needed.
29461
29462         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
29463         `#ifndef HAVE_DECL..'
29464         now that autoconf always defines the HAVE_DECL_ symbols.
29465         * lib/human.c: Likewise.
29466         * lib/same.c: Likewise.
29467         * lib/strtoumax.c: Likewise.
29468
29469         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
29470         declaration check was not run.
29471         * lib/hash.c: Likewise.
29472         * lib/human.c: Likewise.
29473         * lib/same.c: Likewise.
29474         * lib/strtoumax.c: Likewise.
29475
29476         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
29477         `.', then first look up the entire `.'-containing string as a login
29478         name.
29479
29480 2000-02-23  Jim Meyering  <meyering@lucent.com>
29481
29482         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
29483         in place of my hack.
29484
29485 2000-02-18  Paul Eggert  <eggert@twinsun.com>
29486
29487         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
29488         (textint): New typedef.
29489         (parser_control): Member year changed from int to textint.
29490         All uses changed.
29491         (YYSTYPE): Removed; replaced by %union with int and textint members.
29492         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
29493         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
29494         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
29495         (tSNUMBER, tUNUMBER): Now of type <textintval>.
29496         (date, number, to_year): Use width of number in digits, not its value,
29497         to determine whether it's a 2-digit year, or a 2-digit time.
29498         (yylex): Store number of digits of numeric tokens.
29499         Reported by John Kendall.
29500
29501         (parser_control): Changed from struct parser_control to typedef (for
29502         consistency).  All uses changed.
29503
29504         (tID): Removed; not used.
29505         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
29506
29507 2000-02-14  Paul Eggert  <eggert@twinsun.com>
29508
29509         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
29510         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
29511
29512 2000-02-12  Jim Meyering  <meyering@lucent.com>
29513
29514         * lib/userspec.c (ISDIGIT): Define it.
29515         (isdigit): Remove definition.
29516         (is_number): Use ISDIGIT, not isdigit.
29517         <libintl.h>: Include.
29518         (_ and N_): Define.
29519         (parse_user_spec): Mark translatable strings.
29520
29521 2000-02-10  Jim Meyering  <meyering@lucent.com>
29522
29523         With these changes, nanosleep.[ch] are finally enough like the other
29524         lib/* replacement files to compile on a few more losing systems.
29525
29526         * lib/nanosleep.h: Don't include config.h.
29527         Remove prototype from declaration of nanosleep.
29528         (PARAMS): Remove now-unneeded definition.
29529         * lib/nanosleep.c: #undef nanosleep.
29530         (rpl_nanosleep): Rename from nanosleep.
29531
29532 2000-02-10  Jim Meyering  <meyering@lucent.com>
29533
29534         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
29535         gnu_nanosleep to rpl_nanosleep.
29536
29537 2000-02-09  Jim Meyering  <meyering@lucent.com>
29538
29539         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
29540         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
29541
29542 2000-02-08  Akim Demaille  <akim@epita.fr>
29543
29544         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
29545         `[' and `]' and remove uses of `changequote'.
29546         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
29547         (AC_SYS_LARGEFILE): Likewise.
29548         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
29549         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
29550         of changequote.
29551         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
29552         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
29553         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
29554         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
29555
29556 2000-02-05  Jim Meyering  <meyering@lucent.com>
29557
29558         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
29559         Remove explicit use of AC_HEADER_TIME.  It is required by
29560         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
29561         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
29562         in autoconf whereby the expansion of the latter ended up preceding
29563         the expansion of its prerequisite, AC_HEADER_TIME.
29564         Reported by Volker Borchert.
29565
29566 2000-02-03  Jim Meyering  <meyering@lucent.com>
29567
29568         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
29569
29570 2000-02-03  Jim Meyering  <meyering@lucent.com>
29571
29572         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
29573         rather than with `#if HAVE_UTMPNAME'.
29574
29575 2000-02-02  Jim Meyering  <meyering@lucent.com>
29576
29577         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
29578         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
29579         Reported by Eli Zaretskii.
29580
29581 2000-02-01  Jim Meyering  <meyering@lucent.com>
29582
29583         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
29584
29585 2000-01-31  Jim Meyering  <meyering@lucent.com>
29586
29587         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
29588         functions.  Add the time.h and sys/time.h headers along with the
29589         AC_REQUIRE'ment of AC_HEADER_TIME.
29590
29591 2000-01-31  Jim Meyering  <meyering@lucent.com>
29592
29593         * lib/nanosleep.h (nanosleep): Guard declaration with
29594         `#if ! HAVE_DECL_NANOSLEEP'.
29595         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
29596         the declaration in that vendor's sys/timers.h.
29597         Reported by Christian Krackowizer.
29598
29599         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
29600         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
29601         (ISPRINT): Likewise.
29602         Reported by Tom Tromey.
29603
29604 2000-01-30  Jim Meyering  <meyering@lucent.com>
29605
29606         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
29607
29608         * m4/prereq.m4 (utmp_includes): Define.
29609         Check for ut_user and ut_name members in both struct utmpx
29610         and struct utmp.
29611
29612 2000-01-30  Jim Meyering  <meyering@lucent.com>
29613
29614         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
29615         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
29616         header files where only utmpx.ut_user is declared.
29617
29618         * lib/readutmp.h (UT_USER): Define.
29619
29620 2000-01-29  Jim Meyering  <meyering@lucent.com>
29621
29622         * m4/lib-check.m4: New file containing library-related checks from
29623         fileutils and sh-utils (textutils had none).
29624
29625 2000-01-28  Jim Meyering  <meyering@lucent.com>
29626
29627         * m4/perl.m4: Change format of warning message to look more like that
29628         from the missing script.  Suggestion from François Pinard.
29629
29630 2000-01-25  Jim Meyering  <meyering@lucent.com>
29631
29632         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
29633         well as time.h in the compile check.
29634         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
29635         Fix typo in cross-compiling case: s/yes/no/.
29636
29637 2000-01-23  Jim Meyering  <meyering@lucent.com>
29638
29639         * m4/jm-macros.m4: Move df-related tests here from
29640         fileutils/configure.in
29641
29642         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
29643         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
29644
29645         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
29646         s/space/ac_fsusage_space/.
29647         (jm_FILE_SYSTEM_USAGE): Take two parameters.
29648
29649         * m4/ftruncate.m4: New file (derived from part of
29650         fileutils/configure.in).
29651         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
29652         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
29653
29654         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
29655         AC_SUBST these here, rather than just in sh-util/configure.in, so
29656         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
29657         all the same.
29658         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
29659         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
29660         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
29661         (AC_SUBST(POW_LIBM)): Likewise.
29662         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
29663
29664 2000-01-23  Jim Meyering  <meyering@lucent.com>
29665
29666         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
29667         obstack.c.
29668
29669 2000-01-22  Jim Meyering  <meyering@lucent.com>
29670
29671         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
29672
29673         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
29674
29675         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
29676         configure.in
29677         (AC_CHECK_HEADERS): Likewise for sh-utils.
29678         (AC_CHECK_HEADERS): Likewise for textutils.
29679         Merge the three lists of headers.
29680
29681         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
29682         from fileutils' configure.in.
29683
29684         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
29685         code. Moved tests into their own function (_jm_DECL_HEADERS) in
29686         check-decl.m4.
29687
29688         * m4/check-decl.m4: Use #if rather than #ifdef.
29689         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
29690         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
29691         (_jm_DECL_HEADERS): Define new function.
29692         (jm_CHECK_DECLARATIONS): Require it.
29693
29694 2000-01-22  Jim Meyering  <meyering@lucent.com>
29695
29696         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
29697         [! HAVE_DECL_STRTOULL]: Declare strtoull.
29698         Required for some AIX systems.  Reported by Christian Krackowizer.
29699         [TESTING] (main): New function.
29700
29701         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
29702         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
29703         letters.
29704
29705         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
29706         iswprint.
29707
29708         * lib/strverscmp.c (ISDIGIT): Define.
29709         (strverscmp): Use ISDIGIT, not isdigit.
29710
29711 2000-01-19  Jim Meyering  <meyering@lucent.com>
29712
29713         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
29714         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
29715         defines `struct timespec' in <sys/time.h>
29716
29717         * m4/c-bs-a.m4: Remove uses of changequote altogether.
29718         Thanks to Akim for explaining.
29719
29720 2000-01-17  Paul Eggert  <eggert@twinsun.com>
29721
29722         * lib/nanosleep.c (nanosleep):
29723         Don't use SA_INTERRUPT to decide whether to call sigaction, as
29724         POSIX.1 doesn't require SA_INTERRUPT and some systems
29725         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
29726         it's been part of POSIX.1 since day 1 (in 1988).
29727
29728 2000-01-17  Jim Meyering  <meyering@lucent.com>
29729
29730         * lib/interlock: Remove unused file.  Reported by François Pinard.
29731
29732 2000-01-16  Paul Eggert  <eggert@twinsun.com>
29733
29734         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
29735         alert, backslash, formfeed, and vertical tab unnecessarily in
29736         shell quoting style.
29737
29738 2000-01-16  Jim Meyering  <meyering@lucent.com>
29739
29740         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
29741         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
29742         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
29743         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
29744
29745 2000-01-16  Jim Meyering  <meyering@lucent.com>
29746
29747         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
29748         because the latter didn't work.
29749
29750 2000-01-15  Jim Meyering  <meyering@lucent.com>
29751
29752         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
29753         (AC_REPLACE_FUNCS): Add memcpy and memset.
29754         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
29755         Add strpbrk.
29756         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
29757
29758 2000-01-12  Jim Meyering  <meyering@lucent.com>
29759
29760         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
29761         (jm_PREREQ): Use it.
29762         (jm_PREREQ_READUTMP): New macro.
29763         (jm_PREREQ): Use it.
29764
29765 2000-01-11  Paul Eggert  <eggert@twinsun.com>
29766
29767         Quote multibyte characters correctly.
29768         * m4/c-bs-a.m4: New file.
29769         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
29770         (jm_PREREQ): Use it.
29771
29772 2000-01-11  Paul Eggert  <eggert@twinsun.com>
29773
29774         * m4/uintmax_t.m4: Port to autoconf 2.13.
29775
29776 2000-01-08  Jim Meyering  <meyering@ascend.com>
29777
29778         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
29779         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
29780
29781 2000-01-04  Jim Meyering  <meyering@ascend.com>
29782
29783         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
29784         jm_STRUCT_DIRENT_D_TYPE.
29785         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
29786         jm_STRUCT_DIRENT_D_INO.
29787         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
29788         jm_STRUCT_UTIMBUF.
29789         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
29790         renamings.
29791         * m4/utime.m4: Likewise.
29792
29793         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
29794         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
29795
29796 2000-01-03  Paul Eggert  <eggert@twinsun.com>
29797
29798         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
29799         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
29800
29801 2000-01-02  Jim Meyering  <meyering@ascend.com>
29802
29803         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
29804         remember if this is necessary.
29805
29806 1999-12-26  Jim Meyering  <meyering@ascend.com>
29807
29808         * m4/jm-macros.m4: Use it here.
29809         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
29810
29811 1999-12-23  Jim Meyering  <meyering@ascend.com>
29812
29813         * m4/jm-macros.m4: Check for clock_gettime (moved from
29814         fileutils/configure.in)
29815         Check for gettimeofday.
29816
29817 1999-12-20  Jim Meyering  <meyering@ascend.com>
29818
29819         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
29820         autoconf-2.14a-1999-12-20.
29821
29822 1999-12-19  Jim Meyering  <meyering@ascend.com>
29823
29824         * m4/lstat-slash.m4: New file.
29825         * m4/jm-macros.m4: Use the new macro:
29826         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29827
29828 1999-12-07  Jim Meyering  <meyering@ascend.com>
29829
29830         * m4/perl.m4: Require that File::Compare be available, too.
29831         Too many systems seem to lack it.
29832
29833         * m4/strftime.m4: Add checks for most of the cpp macros tested in
29834         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
29835
29836 1999-11-18  Paul Eggert  <eggert@twinsun.com>
29837
29838         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
29839         problem with the QNX 4.25 shell, which doesn't propagate exit
29840         status of failed commands inside shell assignments.
29841
29842 1999-11-17  Jim Meyering  <meyering@ascend.com>
29843
29844         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
29845
29846 1999-11-07  Jim Meyering  <meyering@ascend.com>
29847
29848         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
29849
29850 1999-11-06  Jim Meyering  <meyering@ascend.com>
29851
29852         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
29853         * m4/jm-macros.m4 (jm_MACROS): Use it here.
29854
29855 1999-11-05  Jim Meyering  <meyering@ascend.com>
29856
29857         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
29858         configure.in of textutils, fileutils, and sh-utils into this one
29859         (shared between those packages) file.
29860         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
29861         AC_STRUCT_ST_BLKSIZE.
29862
29863 1999-11-03  Jim Meyering  <meyering@ascend.com>
29864
29865         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
29866         of AC_CHECK_TYPE checks includes unistd.h.
29867         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
29868         Suggestion from Akim Demaille.
29869
29870 1999-10-30  Jim Meyering  <meyering@ascend.com>
29871
29872         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
29873         m4-quoted string.
29874         * m4/ls-mntd-fs.m4: Likewise.
29875         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
29876         * m4/jm-winsz1.m4: Likewise.
29877
29878         * m4/const.m4: Remove file, since the fix made it into the experimental
29879         version of autoconf.
29880         * m4/mktime.m4: Likewise.
29881
29882         * m4/check-type.m4: Remove file, now that the latest version of
29883         AC_CHECK_TYPE takes a third arg to specify additional #includes.
29884
29885         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
29886         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
29887         AC_CHECK_TYPE.
29888
29889 1999-10-04  Jim Meyering  <meyering@ascend.com>
29890
29891         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
29892
29893 1999-09-22  Paul Eggert  <eggert@twinsun.com>
29894
29895         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
29896         2.95.1 bug with HP-UX 10.20.
29897
29898 1999-09-17  Jim Meyering  <meyering@ascend.com>
29899
29900         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
29901         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
29902         due to missing strdup (against sh-utils-2.0).
29903
29904 1999-08-29  Jim Meyering  <meyering@ascend.com>
29905
29906         * m4/jm-macros.m4: Require jm_BISON.
29907         * m4/bison.m4: New file.
29908
29909 1999-08-17  Paul Eggert  <eggert@twinsun.com>
29910
29911         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
29912         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
29913
29914 1999-08-05  Jim Meyering  <meyering@ascend.com>
29915
29916         * m4/getline.m4: Rename test file from conftestdata to conftest.data
29917         to avoid conflicts with `conftest' on 8+3 filesystems.
29918         Suggestion from Eli Zaretskii.
29919
29920 1999-08-04  Jim Meyering  <meyering@ascend.com>
29921
29922         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
29923         fileutils and sh-utils (textutils's getline test was inadequate).
29924         (AM_FUNC_GETLINE): Run this test.
29925         (AC_CHECK_FUNCS): Check for getdelim.
29926         Reported by Bob Proulx.
29927
29928 1999-08-02  Jim Meyering  <meyering@ascend.com>
29929
29930         * m4/jm-macros.m4: Add a comment.
29931
29932 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29933
29934         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
29935         <inttypes.h> defines strtoumax as a macro (and not as a
29936         function).
29937
29938 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29939
29940         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
29941         that we can shift, multiply and divide unsigned long long
29942         values; Ultrix cc can't do it.
29943
29944 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29945
29946         * m4/mktime.m4: New file, which is a preview of what should appear
29947         in the next public autoconf release.
29948
29949 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29950
29951         * m4/lfs.m4: Remove this file.
29952         * m4/largefile.m4: New file.  It contains the old contents of
29953         lfs.m4, except that all names with prefix AC_LFS have been
29954         changed to use the prefix AC_SYS_LARGEFILE instead, to be
29955         compatible with future autoconf versions.  Also, some minor m4
29956         quoting problems have been fixed.
29957
29958 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29959
29960         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
29961         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
29962         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
29963         and simplify the shell code.
29964
29965 1999-08-01  Jim Meyering  <meyering@ascend.com>
29966
29967         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
29968         m4.
29969
29970 1999-07-20  Jim Meyering  <meyering@ascend.com>
29971
29972         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
29973
29974 1999-07-15  Jim Meyering  <meyering@ascend.com>
29975
29976         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
29977
29978 1999-05-22  Jim Meyering  <meyering@ascend.com>
29979
29980         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
29981
29982 1999-05-20  Jim Meyering  <meyering@ascend.com>
29983
29984         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
29985         Add a colon after each `then' in case $4 is empty.
29986
29987 1999-05-16  Jim Meyering  <meyering@ascend.com>
29988
29989         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
29990
29991 1999-05-10  Jim Meyering  <meyering@ascend.com>
29992
29993         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
29994
29995         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
29996         AC_FUNC_MKTIME.
29997
29998 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
29999
30000         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
30001
30002 1999-05-04  Paul Eggert  <eggert@twinsun.com>
30003
30004         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
30005         not CPPFLAGS, so that linking works correctly in IRIX.
30006
30007 1999-04-30  Paul Eggert  <eggert@twinsun.com>
30008
30009         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
30010
30011 1999-04-20  Paul Eggert  <eggert@twinsun.com>
30012
30013         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
30014         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
30015         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
30016         jm_AC_TYPE_UNSIGNED_LONG_LONG.
30017         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
30018
30019         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
30020
30021 1999-04-20  Jim Meyering  <meyering@ascend.com>
30022
30023         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
30024         AC_REPLACE xstroull if necessary.  From Paul Eggert.
30025         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
30026
30027 1999-04-18  Jim Meyering  <meyering@ascend.com>
30028
30029         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
30030         * m4/jm-macros.m4: Use it.
30031
30032 1999-04-06  Jim Meyering  <meyering@ascend.com>
30033
30034         * m4/strftime.m4: Remove test for %f.
30035
30036 1999-03-29  Jim Meyering  <meyering@ascend.com>
30037
30038         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
30039         superset of the AC_TYPE_* checks in the textutils, fileutils,
30040         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
30041         AC_TYPE_PID_T.
30042
30043 1999-03-28  Jim Meyering  <meyering@ascend.com>
30044
30045         * m4/jm-macros.m4: Define GNU_PACKAGE here.
30046         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
30047         replaced e.g., in the *.sh files of the sh-utils.
30048
30049 1999-03-20  Jim Meyering  <meyering@ascend.com>
30050
30051         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
30052         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
30053         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
30054
30055 1999-03-19  Jim Meyering  <meyering@ascend.com>
30056
30057         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
30058
30059 1999-03-12  Jim Meyering  <meyering@ascend.com>
30060
30061         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
30062
30063 1999-03-07  Jim Meyering  <meyering@ascend.com>
30064
30065         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
30066         declared.
30067
30068 1999-02-17  Jim Meyering  <meyering@ascend.com>
30069
30070         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
30071         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
30072
30073 1999-02-07  Jim Meyering  <meyering@ascend.com>
30074
30075         * m4/group-member.m4: New file -- extracted from sh-utils'
30076         configure.in.
30077
30078         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
30079         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
30080
30081 1999-02-06  Jim Meyering  <meyering@ascend.com>
30082
30083         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
30084         * m4/fnmatch.m4: Likewise.
30085         * m4/getgroups.m4: Likewise.
30086         * m4/lstat.m4: Likewise.
30087         * m4/malloc.m4: Likewise.
30088         * m4/putenv.m4: Likewise.
30089         * m4/realloc.m4: Likewise.
30090         * m4/regex.m4: Likewise.
30091         * m4/stat.m4: Likewise.
30092         * m4/strftime.m4: Likewise.
30093         Suggestion from Alain Magloire.
30094
30095         * m4/chown.m4: Use `.$ac_objext', not `.o'.
30096         * m4/fnmatch.m4: Likewise.
30097         * m4/getgroups.m4: Likewise.
30098         * m4/getline.m4: Likewise.
30099         * m4/lstat.m4: Likewise.
30100         * m4/malloc.m4: Likewise.
30101         * m4/memcmp.m4: Likewise.
30102         * m4/putenv.m4: Likewise.
30103         * m4/realloc.m4: Likewise.
30104         * m4/regex.m4: Likewise.
30105         * m4/stat.m4: Likewise.
30106         * m4/strftime.m4: Likewise.
30107         Suggestion from Alain Magloire.
30108
30109         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
30110         an argument.
30111
30112         * m4/regex.m4: Add a run-time Test for proper operation of
30113         re_compile_pattern.
30114
30115 1999-01-31  Jim Meyering  <meyering@ascend.com>
30116
30117         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
30118
30119 1999-01-30  Jim Meyering  <meyering@ascend.com>
30120
30121         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
30122
30123         * m4/jm-mktime.m4: Make this a wrapper around the official
30124         AM_FUNC_MKTIME rather than my private copy, now that the official one
30125         is up to date.
30126         * m4/mktime.m4: Remove file.
30127
30128         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
30129         * m4/uptime.m4: Likewise.
30130         * m4/uintmax_t.m4: Likewise.
30131
30132 1999-01-28  Jim Meyering  <meyering@ascend.com>
30133
30134         * m4/jm-macros.m4: Use jm_AFS.
30135         * m4/afs.m4: New file (from fileutils' configure.in).
30136
30137         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
30138         * m4/chown.m4: Likewise.
30139         * m4/d-ino.m4: Likewise.
30140         * m4/d-type.m4: Likewise.
30141         * m4/fnmatch.m4: Likewise.
30142         * m4/getgroups.m4: Likewise.
30143         * m4/gettext.m4: Likewise.
30144         * m4/jm-mktime.m4: Likewise.
30145         * m4/jm-winsz2.m4: Likewise.
30146         * m4/lcmessage.m4: Likewise.
30147         * m4/ls-mntd-fs.m4: Likewise.
30148         * m4/malloc.m4: Likewise.
30149         * m4/memcmp.m4: Likewise.
30150         * m4/putenv.m4: Likewise.
30151         * m4/realloc.m4: Likewise.
30152         * m4/st_mtim.m4: Likewise.
30153         * m4/strftime.m4: Likewise.
30154
30155 1999-01-16  Jim Meyering  <meyering@ascend.com>
30156
30157         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
30158         (ARGMATCH_DIE_DECL): Define.
30159
30160 1999-01-12  Jim Meyering  <meyering@ascend.com>
30161
30162         * m4/Makefile.am.in: Rewrite to avoid using fmt.
30163         Reported by Lars Hecking.
30164
30165 1999-01-10  Jim Meyering  <meyering@ascend.com>
30166
30167         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
30168         gross kludge.
30169         * m4/inttypes_h.m4: Likewise.
30170         * m4/lstat.m4: Likewise.
30171         * m4/malloc.m4: Likewise.
30172         * m4/readdir.m4: Likewise.
30173         * m4/realloc.m4: Likewise.
30174         * m4/st_dm_mode.m4: Likewise.
30175         * m4/stat.m4: Likewise.
30176         * m4/utimbuf.m4: Likewise.
30177         * m4/utimes.m4: Likewise.
30178
30179         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
30180         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
30181         comments in config.h.in are meaningful.
30182
30183         * m4/jm-macros.m4: Require autoconf-2.13 here.
30184
30185         * m4/regex.m4: By default, don't use the included regex.c on systems
30186         with glibc 2.  Suggestion from Uli Drepper.
30187
30188 1999-01-02  Jim Meyering  <meyering@ascend.com>
30189
30190         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
30191
30192 1998-12-18  Jim Meyering  <meyering@ascend.com>
30193
30194         * m4/Makefile.am.in (Makefile.am): Simplify rule.
30195         Based on a suggestion from Lars Hecking.
30196
30197 1998-11-16  Paul Eggert  <eggert@twinsun.com>
30198
30199         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
30200
30201 1998-11-16  Jim Meyering  <meyering@ascend.com>
30202
30203         * m4/lfs.m4: Double-quote the `uname...` expression.
30204
30205 1998-11-14  Jim Meyering  <meyering@ascend.com>
30206
30207         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
30208         * m4/stat.m4: Likewise.
30209
30210 1998-11-03  Jim Meyering  <meyering@ascend.com>
30211
30212         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
30213         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
30214
30215 1998-10-18  Jim Meyering  <meyering@ascend.com>
30216
30217         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
30218
30219 1998-10-17  Jim Meyering  <meyering@ascend.com>
30220
30221         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
30222         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
30223         calls for those previously hard-coded headers.  Instead, take a new
30224         parameter.
30225         (jm_CHECK_DECLARATIONS): Reflect interface change.
30226         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
30227         (jm_CHECK_DECL_LOCALTIME_R): New macro.
30228
30229         * m4/mktime.m4: Test for spring-forward gap before long-running test.
30230
30231 1998-10-14  Jim Meyering  <meyering@ascend.com>
30232
30233         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
30234         instead of "TZ=America/Vancouver".  From Paul Eggert.
30235
30236 1998-10-11  Jim Meyering  <meyering@ascend.com>
30237
30238         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
30239         This adds a test for a recently added compatibility fix for mktime.c.
30240         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
30241
30242 1998-09-27  Jim Meyering  <meyering@ascend.com>
30243
30244         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
30245
30246         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
30247         ../configure.in, including a change from Gordon Matzigkeit to allow
30248         cross-compiling for the Hurd.
30249
30250         * m4/glibc.m4: New file/macro to test for the GNU C Library
30251         versions 1 and 2.  From Gordon Matzigkeit.
30252         Indent.
30253
30254 1998-09-21  Jim Meyering  <meyering@ascend.com>
30255
30256         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
30257
30258 1998-08-18  Paul Eggert  <eggert@twinsun.com>
30259
30260         Port nanosecond-resolution times to UnixWare 2.1.2 and
30261         pedantic Solaris 2.6.
30262
30263         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
30264         AC_STRUCT_ST_MTIM.
30265         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
30266         Generate name of ns member, instead of just 1 or undef.
30267         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
30268
30269 1998-08-15  Jim Meyering  <meyering@ascend.com>
30270
30271         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
30272         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
30273         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
30274         instead of jm_TYPE_SSIZE_T.
30275
30276 1998-08-12  Jim Meyering  <meyering@ascend.com>
30277
30278         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
30279
30280 1998-08-02  Jim Meyering  <meyering@ascend.com>
30281
30282         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
30283         in acconfig.h manually.
30284
30285 1998-07-31  Paul Eggert  <eggert@twinsun.com>
30286
30287         * m4/st_mtim.m4: New file.
30288
30289 1998-07-28  Jim Meyering  <meyering@ascend.com>
30290
30291         * m4/utimes.m4: Undef stat.
30292
30293 1998-07-25  Jim Meyering  <meyering@ascend.com>
30294
30295         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
30296         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
30297
30298 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
30299
30300         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
30301         uid and gid actually remain unchanged.
30302
30303 1998-07-07  Jim Meyering  <meyering@ascend.com>
30304
30305         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
30306
30307 1998-07-04  Jim Meyering  <meyering@ascend.com>
30308
30309         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
30310         to prove that this macro can be used in packages without regex.c.
30311
30312 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
30313
30314         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
30315         is to be used.
30316
30317 1998-07-03  Jim Meyering  <meyering@ascend.com>
30318
30319         * m4/gettext.m4: Add -lintl if it's found to be necessary.
30320
30321         * m4/gettext.m4: New file -- from gettext-0.10.35.
30322         * m4/lcmessage.m4: Likewise.
30323         * m4/progtest.m4: Likewise.
30324
30325         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
30326         * m4/jm-macros.m4: Require the new macro.
30327
30328 1998-06-29  Jim Meyering  <meyering@ascend.com>
30329
30330         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
30331         for the definition of NGROUPS (used in a system header included
30332         by sys/mount.h).
30333
30334 1998-06-28  Jim Meyering  <meyering@ascend.com>
30335
30336         * m4/ls-mntd-fs.m4: New file.
30337         * m4/fstypename.m4: New file.
30338
30339         * m4/jm-macros.m4: Require the new macro.
30340         * m4/jm-glibc-io.m4: New file.
30341
30342 1998-05-19  Jim Meyering  <meyering@ascend.com>
30343
30344         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
30345         * m4/lchown.m4: New file.
30346
30347         * m4/Makefile.am.in: New file.
30348         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
30349
30350 1998-05-14  Jim Meyering  <meyering@ascend.com>
30351
30352         * m4/Makefile.am (EXTRA_DIST): Add them.
30353         * m4/jm-macros.m4: New file.
30354         * m4/utimbuf.m4: New file.
30355
30356 1998-05-12  Jim Meyering  <meyering@ascend.com>
30357
30358         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
30359
30360 1998-05-11  Jim Meyering  <meyering@ascend.com>
30361
30362         * m4/isc-posix.m4: New file.
30363
30364 1998-05-10  Jim Meyering  <meyering@ascend.com>