* lib/count-one-bits.h: Add comments. (From Bruno Haible.)
[gnulib.git] / ChangeLog
1 2007-08-14  Ben Pfaff  <blp@gnu.org>
2
3         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
4
5 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
6
7         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
8         given the changes below.
9         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
10         even on hosts that have padding bits beyond the supported 64.
11
12 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
13
14         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
15         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
16         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
17         depends on it.
18         (xstrtol_error): Remove.
19         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
20         but with a different signature.
21         (ATTRIBUTE_NORETURN, __attribute__): New macros.
22         * lib/xstrtol-error.c: Include exitfail.h.
23         (xstrtol_fatal): New function, with a different signature from the
24         old xstrtol_error, so that the caller need not worry about passing
25         in an exit status, or about storage management of the option argument.
26         (xstrtol_error): Now a static function.  Redo signature to
27         implement xstrtol_fatal.  Output the correct number of hyphens in
28         front of the option so that the caller need not worry about
29         storage management.
30         (N_): New macro.
31         (_): Remove; not used now.
32         * modules/xstrtol: Depend on getopt.
33         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
34         of old STRTOL_FATAL_ERROR macro.
35         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
36         of test program.
37         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
38         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
39
40 2007-08-08  Eric Blake  <ebb9@byu.net>
41
42         * lib/xstrtol-error.c: Add missing include.
43
44         Move xstrtol messages into gnulib domain, when --pobase is used.
45         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
46         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
47         * modules/xstrtol (Files): Distribute new file.
48         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
49         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
50         * tests/test-xstrtol.c: ...into new file.
51         * tests/test-xstrtoul.c: Also test xstrtoul.
52         * tests/test-xstrtoimax.c: Also test xstrtoimax.
53         * tests/test-xstrtoumax.c: Also test xstrtoumax.
54         * tests/test-xstrtol.sh: Drive the tests.
55         * tests/test-xstrtoimax.sh: Likewise.
56         * tests/test-xstrtoumax.sh: Likewise.
57         * modules/xstrtol-tests: New module.
58         * modules/xstrtoimax-tests: Likewise.
59         * modules/xstrtoumax-tests: Likewise.
60
61 2007-08-08  Jim Meyering  <jim@meyering.net>
62
63         New function: mfile_name_concat.
64         * lib/filenamecat.c (mfile_name_concat): New function, just like
65         file_name_concat, but return NULL upon failure rather than exiting
66         with a diagnostic.
67         * lib/filenamecat.h: Declare it.
68
69 2007-08-07  Bruno Haible  <bruno@clisp.org>
70
71         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
72         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
73         warning from gcc.
74         Reported by Eric Blake.
75
76 2007-08-07  Simon Josefsson  <simon@josefsson.org>
77
78         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
79         * modules/crypto/arcfour (License): Likewise.
80         * modules/crypto/des-tests (License): Likewise.
81         * modules/crypto/gc-arctwo-tests (License): Likewise.
82         * modules/crypto/gc-des-tests (License): Likewise.
83         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
84         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
85         * modules/crypto/gc-md2-tests (License): Likewise.
86         * modules/crypto/gc-md4-tests (License): Likewise.
87         * modules/crypto/gc-md5-tests (License): Likewise.
88         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
89         * modules/crypto/gc-rijndael-tests (License): Likewise.
90         * modules/crypto/gc-sha1-tests (License): Likewise.
91         * modules/crypto/gc-tests (License): Likewise.
92         * modules/crypto/hmac-md5 (License): Likewise.
93         * modules/crypto/hmac-sha1 (License): Likewise.
94         * modules/crypto/md2-tests (License): Likewise.
95         * modules/crypto/md4-tests (License): Likewise.
96         * modules/crypto/md5 (License): Likewise.
97         * modules/crypto/rijndael (License): Likewise.
98         * modules/crypto/sha1 (License): Likewise.
99         * modules/memxor (License): Likewise.
100
101 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
102         and Bruno Haible  <bruno@clisp.org>
103
104         * NEWS: Describe interface changes to human, xstrtol.
105         * lib/human.h: Include <xstrtol.h>.
106         (human_options): Return enum strtol_error, not int.  Remove
107         bool arg; take int * instead.
108         * lib/human.c: Don't include "gettext.h".
109         (_): Remove; no longer used.
110         Don't include <xstrtol.h>, since human.h does it.
111         (human_options): Adjust to abovementioned interface changes.
112         Do not report error to stderr; that's now the caller's
113         responsibility.
114         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
115         interface change.
116         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
117         Str, Argument_type_string.  All uses changed.  Put " argument"
118         in diagnostics to make them clearer.  Change wording of suffix
119         message for clarity.
120         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
121         Argument_type_string.
122         (STRTOL_FATAL_WARN): Remove; no longer used.
123         * modules/human (Depends-on): Remove gettext-h.
124
125 2007-08-06  Simon Josefsson  <simon@josefsson.org>
126
127         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
128
129 2007-07-31  Bruno Haible  <bruno@clisp.org>
130
131         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
132         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
133         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
134
135 2007-07-31  Bruno Haible  <bruno@clisp.org>
136
137         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
138         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
139
140 2007-07-30  Bruno Haible  <bruno@clisp.org>
141
142         * modules/base64 (License): Use the synonymous term "LGPLv2+".
143         * modules/c-ctype (License): Likewise.
144         * modules/c-strcase (License): Likewise.
145         * modules/check-version (License): Likewise.
146         * modules/iconv (License): Likewise.
147         * modules/iconv_open (License): Likewise.
148         * modules/read-file (License): Likewise.
149         * modules/striconv (License): Likewise.
150         * modules/strverscmp (License): Likewise.
151         * modules/vasprintf (License): Likewise.
152         * modules/crypto/des (License): Likewise.
153         * modules/crypto/gc (License): Likewise.
154         * modules/crypto/gc-arcfour (License): Likewise.
155         * modules/crypto/gc-arctwo (License): Likewise.
156         * modules/crypto/gc-des (License): Likewise.
157         * modules/crypto/gc-hmac-md5 (License): Likewise.
158         * modules/crypto/gc-hmac-sha1 (License): Likewise.
159         * modules/crypto/gc-md2 (License): Likewise.
160         * modules/crypto/gc-md4 (License): Likewise.
161         * modules/crypto/gc-md5 (License): Likewise.
162         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
163         * modules/crypto/gc-random (License): Likewise.
164         * modules/crypto/gc-rijndael (License): Likewise.
165         * modules/crypto/gc-sha1 (License): Likewise.
166         * modules/crypto/md2 (License): Likewise.
167         * modules/crypto/md4 (License): Likewise.
168
169 2007-07-30  Jim Meyering  <jim@meyering.net>
170
171         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
172         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
173         it has valid stat data.  This bug would cause du not to count the
174         sizes of inaccessible directories.
175         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
176         in <http://bugzilla.redhat.com/250077>.
177
178 2007-07-25  Peter O'Gorman  <peter@pogma.com>
179             Bruno Haible  <bruno@clisp.org>
180
181         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
182         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
183         #include_next, gives a diagnostic about it, but reports no error in
184         the exit code.
185         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
186
187 2007-07-24  Ben Pfaff  <blp@gnu.org>
188
189         Improve name: "count-one-bits" is better than "popcount".
190         * MODULES.html.sh: Update name.
191         * lib/popcount.h: Renamed lib/count-one-bits.h.
192         (popcount): Renamed count_one_bits.
193         (popcountl): Renamed count_one_bits_l.
194         (popcountll): Renamed count_one_bits_ll.
195         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
196         * modules/popcount: Renamed module/count-one-bits.
197         * modules/popcount-tests: Renamed module/count-one-bits-tests.
198         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
199
200 2007-07-23  Ben Pfaff  <blp@gnu.org>
201
202         * lib/popcount.h (popcount32): Reduce size of constants, to allow
203         better code generation, and add U to large constants to avoid
204         warnings, in non-GCC case.
205         Suggested by Bruno Haible.
206
207 2007-07-23  Ben Pfaff  <blp@gnu.org>
208
209         * lib/popcount.h: Use verify_true instead of if...abort.
210         * modules/popcount: Depend on verify module.
211         Suggested by Jim Meyering.
212
213 2007-07-23  Bruno Haible  <bruno@clisp.org>
214
215         * gnulib-tool (func_import): Create a .cvsignore file also when the
216         directory is not yet in CVS but the toplevel directory is. When
217         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
218         Reported by Karl Berry.
219
220 2007-07-22  Ben Pfaff  <blp@gnu.org>
221
222         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
223         case.
224         Suggested by Eric Blake.
225
226 2007-07-22  Ben Pfaff  <blp@gnu.org>
227
228         New module: popcount.
229         * MODULES.html.sh: Add popcount.
230         * modules/popcount: New file.
231         * modules/popcount-tests: New file.
232         * tests/test-popcount.c: New file.
233         * lib/popcount.h: New file.
234         * m4/popcount.m4: New file.
235
236 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
237
238         * build-aux/announce-gen: Update to GPLv3.
239
240         * build-aux/config.guess: Update from config.
241
242 2007-07-21  Bruno Haible  <bruno@clisp.org>
243
244         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
245         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
246
247 2007-07-20  Jim Meyering  <jim@meyering.net>
248
249         * check-module: Diagnose a self-dependency.
250
251 2007-07-19  Bruno Haible  <bruno@clisp.org>
252
253         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
254         empty.
255         Reported by Eric Blake.
256
257 2007-07-18  Bruno Haible  <bruno@clisp.org>
258
259         * gnulib-tool: New options --po-base, --po-domain.
260         (func_usage): Document them.
261         (pobase, po_domain): New variables.
262         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
263         DEFAULT_TEXT_DOMAIN.
264         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
265         (func_import): Consider pobase and po_domain. Create a po/ directory.
266         (func_create_testdir): Set pobase and po_domain to empty.
267         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
268         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
269
270 2007-07-18  Bruno Haible  <bruno@clisp.org>
271
272         * gnulib-tool (func_get_automake_snippet): Synthesize also an
273         EXTRA_DIST augmentation for files in build-aux/.
274
275 2007-07-16  Bruno Haible  <bruno@clisp.org>
276
277         * modules/lseek (License): Use the synonymous term "LGPLv2+".
278         * modules/getdelim (License): Likewise.
279
280 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
281
282         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
283         * modules/d-type (License): Likewise.
284         * modules/extensions (License): Likewise.
285         * modules/fnmatch (License): Likewise.
286         * modules/fseeko (License): Likewise.
287         * modules/getaddrinfo (License): Likewise.
288         * modules/getline (License): Likewise.
289         * modules/getlogin_r (License): Likewise.
290         * modules/getpass (License): Likewise.
291         * modules/gettimeofday (License): Likewise.
292         * modules/glob (License): Likewise.
293         * modules/inet_ntop (License): Likewise.
294         * modules/malloc (License): Likewise.
295         * modules/malloca (License): Likewise.
296         * modules/memmem (License): Likewise.
297         * modules/mempcpy (License): Likewise.
298         * modules/memset (License): Likewise.
299         * modules/minmax (License): Likewise.
300         * modules/mktime (License): Likewise.
301         * modules/netinet_in (License): Likewise.
302         * modules/pathmax (License): Likewise.
303         * modules/poll (License): Likewise.
304         * modules/regex (License): Likewise.
305         * modules/snprintf (License): Likewise.
306         * modules/stdbool (License): Likewise.
307         * modules/stdint (License): Likewise.
308         * modules/stdio (License): Likewise.
309         * modules/strcase (License): Likewise.
310         * modules/strcasestr (License): Likewise.
311         * modules/strdup (License): Likewise.
312         * modules/string (License): Likewise.
313         * modules/strndup (License): Likewise.
314         * modules/strnlen (License): Likewise.
315         * modules/strpbrk (License): Likewise.
316         * modules/strptime (License): Likewise.
317         * modules/strsep (License): Likewise.
318         * modules/sys_select (License): Likewise.
319         * modules/sys_socket (License): Likewise.
320         * modules/sys_stat (License): Likewise.
321         * modules/sys_time (License): Likewise.
322         * modules/time (License): Likewise.
323         * modules/time_r (License): Likewise.
324         * modules/timegm (License): Likewise.
325         * modules/unistd (License): Likewise.
326         * modules/vsnprintf (License): Likewise.
327         * modules/wctype (License): Likewise.
328
329 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
330
331         * modules/argz (License): LGPLv2+.
332
333 2007-07-15  Karl Berry  <karl@gnu.org>
334
335         * doc/gnulib.texi: revise node structure per new fdl.texi.
336
337 2007-07-14  Bruno Haible  <bruno@clisp.org>
338
339         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
340         the output file.
341         * lib/uniname/uninames.h: Regenerated.
342
343 2007-07-14  Karl Berry  <karl@gnu.org>
344
345         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
346         omitting sectioning and index commands.
347
348 2007-07-13  Bruno Haible  <bruno@clisp.org>
349
350         New gnulib-tool option --more-symlinks.
351         * gnulib-tool (func_usage): Document --more-symlinks.
352         (do_copyrights): New variable.
353         Recognize option --more-symlinks.
354         (func_import): Don't add a copyright notice transform to
355         sed_transform_lib_file if do_copyrights is empty.
356
357 2007-07-13  Bruno Haible  <bruno@clisp.org>
358
359         * lib/vasnprintf.c (decimal_point_char): Define also if
360         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
361         && !NEED_PRINTF_DIRECTIVE_A.
362         Reported by Clemens Koller <clemens.koller@anagramm.de> via
363         Gary V. Vaughan <gary@gnu.org>.
364
365 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
366
367         * lib/inttypes_.h: Undo previous change, since it was fixed
368         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
369
370 2007-07-13  Bruno Haible  <bruno@clisp.org>
371
372         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
373         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
374
375 2007-07-13  Jim Meyering  <jim@meyering.net>
376
377         df: Don't fail for Tru64's "file-on-file mount".
378         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
379         so we fall through and use statfs instead.  Details here:
380         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
381         Reported by Albert Chin.
382
383 2007-07-13  Bruno Haible  <bruno@clisp.org>
384
385         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
386         * modules/configmake (License): Likewise.
387         * modules/gettext (License): Likewise.
388         * modules/gettext-h (License): Likewise.
389         * modules/include_next (License): Likewise.
390         * modules/link-warning (License): Likewise.
391         * modules/localcharset (License): Likewise.
392         * modules/localename (License): Likewise.
393         * modules/lock (License): Likewise.
394         * modules/relocatable-lib-lgpl (License): Likewise.
395         * modules/size_max (License): Likewise.
396         * modules/vasnprintf (License): Likewise.
397         * modules/wchar (License): Likewise.
398         * modules/xsize (License): Likewise.
399
400 2007-07-13  Bruno Haible  <bruno@clisp.org>
401
402         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
403         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
404
405 2007-07-12  Bruno Haible  <bruno@clisp.org>
406
407         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
408         in the modules files.
409
410 2007-07-11  Karl Berry  <karl@gnu.org>
411
412         * MODULES.html.sh (func_module): use
413          sed -e '\|^'"${includefile}"'$|d'
414          instead of /.../d, to avoid errors on $includefile's containing /.
415
416 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
417
418         * gnulib-tool (func_import): Avoid duplication of --avoid
419         statements
420         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
421         names to `_' in variable names.
422
423 2007-07-10  Eric Blake  <ebb9@byu.net>
424
425         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
426         * NEWS: Document this change.
427
428 2007-07-08  Bruno Haible  <bruno@clisp.org>
429
430         Update to Unicode 5.0.
431         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
432         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
433         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
434         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
435         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
436         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
437         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
438         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
439         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
440         U+10A3F, U+1D242..U+1D244.
441         (nonspacing_table_ind): Update.
442         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
443         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
444
445 2007-07-08  Bruno Haible  <bruno@clisp.org>
446
447         Update to Unicode 5.0.
448         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
449         code transform. Extend the name index field of unicode_name_to_code and
450         unicode_code_to_name from 16 to 24 bits.
451         * lib/uniname/uniname.c (unicode_character_name,
452         unicode_name_character): Add the range 0x12xxx to the code transform.
453         * lib/uniname/uninames.h: Regenerated.
454         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
455
456 2007-07-07  Bruno Haible  <bruno@clisp.org>
457
458         * modules/wcwidth-tests: New file.
459         * tests/test-wcwidth.c: New file.
460
461         Work around MacOS X wcwidth() bug.
462         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
463         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
464         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
465         original wcwidth in non-UTF-8 locales.
466         * modules/wcwidth (Depends-on): Add localcharset, streq,
467         uniwidth/width.
468         * doc/functions/wcwidth.texi: Update.
469
470 2007-07-07  Bruno Haible  <bruno@clisp.org>
471
472         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
473         (wcwidth): New declaration.
474         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
475         macros.
476         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
477         here. Prepare for creating <wchar.h> unconditionally.
478         * modules/wchar (Depends-on): Add link-warning.
479         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
480         REPLACE_WCWIDTH, and GL_LINK_WARNING.
481         * lib/wcwidth.h: Remove file.
482         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
483         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
484         * modules/wcwidth (Files): Remove lib/wcwidth.h.
485         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
486         (Include): Replace wcwidth.h with <wchar.h>.
487         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
488         * lib/mbchar.h: Don't include wcwidth.h.
489         * lib/mbswidth.c: Likewise.
490         * NEWS: Mention the change.
491
492 2007-07-07  Bruno Haible  <bruno@clisp.org>
493
494         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
495         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
496         definition with an external declaration.
497         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
498         defined as a function. Remove AC_C_INLINE requirement.
499         * modules/wcwidth (Files): Add lib/wcwidth.c.
500         (Makefile.am): Remove redundant statement.
501
502 2007-07-07  Bruno Haible  <bruno@clisp.org>
503
504         * MODULES.html.sh (Unicode string functions): Add the new modules.
505
506         * tests/uniwidth/test-u32-strwidth.c: New file.
507         * modules/uniwidth/u32-strwidth-tests: New file.
508
509         * lib/uniwidth/u32-strwidth.c: New file.
510         * modules/uniwidth/u32-strwidth: New file.
511
512         * tests/uniwidth/test-u16-strwidth.c: New file.
513         * modules/uniwidth/u16-strwidth-tests: New file.
514
515         * lib/uniwidth/u16-strwidth.c: New file.
516         * modules/uniwidth/u16-strwidth: New file.
517
518         * tests/uniwidth/test-u8-strwidth.c: New file.
519         * modules/uniwidth/u8-strwidth-tests: New file.
520
521         * lib/uniwidth/u8-strwidth.c: New file.
522         * modules/uniwidth/u8-strwidth: New file.
523
524         * tests/uniwidth/test-u32-width.c: New file.
525         * modules/uniwidth/u32-width-tests: New file.
526
527         * lib/uniwidth/u32-width.c: New file.
528         * modules/uniwidth/u32-width: New file.
529
530         * tests/uniwidth/test-u16-width.c: New file.
531         * modules/uniwidth/u16-width-tests: New file.
532
533         * lib/uniwidth/u16-width.c: New file.
534         * modules/uniwidth/u16-width: New file.
535
536         * tests/uniwidth/test-u8-width.c: New file.
537         * modules/uniwidth/u8-width-tests: New file.
538
539         * lib/uniwidth/u8-width.c: New file.
540         * modules/uniwidth/u8-width: New file.
541
542         * tests/uniwidth/test-uc_width.c: New file.
543         * modules/uniwidth/width-tests: New file.
544
545         * lib/uniwidth/width.c: New file, from GNU libiconv.
546         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
547         * modules/uniwidth/width: New file.
548
549         * lib/uniwidth.h: New file, from GNU libiconv.
550         * modules/uniwidth/base: New file.
551
552 2007-07-07  Bruno Haible  <bruno@clisp.org>
553
554         * lib/uniname.h: New file, from GNU gettext.
555         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
556         * lib/uniname/uninames.h: New file, from GNU gettext.
557         * lib/uniname/uniname.c: New file, from GNU gettext.
558         * tests/uniname/test-uninames.sh: New file.
559         * tests/uniname/test-uninames.c: New file, from GNU gettext.
560         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
561         * modules/uniname/base: New file.
562         * modules/uniname/uniname: New file.
563         * modules/uniname/uniname-tests: New file.
564         * MODULES.html.sh (Unicode string functions): Add the new modules.
565
566 2007-07-06  Bruno Haible  <bruno@clisp.org>
567
568         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
569
570 2007-07-06  Bruno Haible  <bruno@clisp.org>
571
572         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
573         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
574         includes <cygwin/sys_time.h> which includes <sys/select.h> which
575         include <sys/time.h>.
576         Reported by Eric Blake.
577
578 2007-07-06  Eric Blake  <ebb9@byu.net>
579
580         Fix testing canonicalize on cygwin.
581         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
582         Revert patch from 2007-06-19.
583         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
584         canonicalize module is also in use.
585         * tests/test-canonicalize.c: New file.
586         * tests/test-canonicalize.sh: Likewise.
587         * modules/canonicalize-tests: Likewise.
588
589 2007-07-06  Jim Meyering  <jim@meyering.net>
590
591         * lib/getugroups.c (getugroups): Detect getgrent failure.
592         Adjust comment to reflect reality: this function may return -1.
593
594 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
595
596         * build-aux/bootstrap (TP_URL,get_translations): Update to use
597         the new TP address.
598         (usage): Fix typo
599         (gnulib_mk): New variable.
600
601 2007-07-05  Jim Meyering  <jim@meyering.net>
602
603         Don't let endgrent clobber errno, no matter how improbable.
604         * lib/getugroups.c (getugroups): Save and restore errno around
605         endgrent call.
606
607         Close the group DB even when failing with 2^31 or more members.
608         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
609
610 2007-07-04  Jim Meyering  <jim@meyering.net>
611
612         * lib/getugroups.h: New file.
613         * lib/getugroups.c: Include "getugroups.h".
614         Remove uses of "register" keyword.
615         Move local variable, "cp", down into scope where used.
616         Give "username" parameter the "const" attribute.
617         * modules/getugroups (Files): Add lib/getugroups.h
618
619 2007-07-04  Karl Berry  <karl@gnu.org>
620
621         * MODULES.html.sh (func_all_modules): Complete rename of
622         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
623
624 2007-07-02  Bruno Haible  <bruno@clisp.org>
625
626         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
627         mode, when inttypes.h comes from gnulib.
628         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
629
630 2007-07-02  Simon Josefsson  <simon@josefsson.org>
631
632         * NEWS: Mention lgpl module name change.
633
634         * modules/lgpl-2.1: Renamed from lgpl.
635
636         * NEWS: Mention gpl module name change.
637
638         * modules/gpl-3.0: New file, based on gpl-2.0.
639
640         * modules/gpl-2.0: Renamed from gpl.
641
642         * modules/gpl: Fix filename, doc/gpl.texi is now found at
643         doc/gpl-2.0.texi.
644
645 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
646
647         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
648         #define __STDC_LIMIT_MACROS temporarily while including
649         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
650         Problem reported by Joel E. Denny in
651         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
652
653 2007-07-01  Bruno Haible  <bruno@clisp.org>
654
655         * lib/unistdio.h: New file.
656         * lib/unistdio/u-asnprintf.h: New file.
657         * lib/unistdio/u-asprintf.h: New file.
658         * lib/unistdio/u-printf-args.c: New file.
659         * lib/unistdio/u-printf-args.h: New file.
660         * lib/unistdio/u-printf-parse.h: New file.
661         * lib/unistdio/u-snprintf.h: New file.
662         * lib/unistdio/u-sprintf.h: New file.
663         * lib/unistdio/u-vasprintf.h: New file.
664         * lib/unistdio/u-vsnprintf.h: New file.
665         * lib/unistdio/u-vsprintf.h: New file.
666         * lib/unistdio/ulc-asnprintf.c: New file.
667         * lib/unistdio/ulc-asprintf.c: New file.
668         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
669         * lib/unistdio/ulc-printf-parse.c: New file.
670         * lib/unistdio/ulc-snprintf.c: New file.
671         * lib/unistdio/ulc-sprintf.c: New file.
672         * lib/unistdio/ulc-vasnprintf.c: New file.
673         * lib/unistdio/ulc-vasprintf.c: New file.
674         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
675         * lib/unistdio/ulc-vsnprintf.c: New file.
676         * lib/unistdio/ulc-vsprintf.c: New file.
677         * lib/unistdio/u8-asnprintf.c: New file.
678         * lib/unistdio/u8-asprintf.c: New file.
679         * lib/unistdio/u8-printf-parse.c: New file.
680         * lib/unistdio/u8-snprintf.c: New file.
681         * lib/unistdio/u8-sprintf.c: New file.
682         * lib/unistdio/u8-vasnprintf.c: New file.
683         * lib/unistdio/u8-vasprintf.c: New file.
684         * lib/unistdio/u8-vsnprintf.c: New file.
685         * lib/unistdio/u8-vsprintf.c: New file.
686         * lib/unistdio/u8-u8-asnprintf.c: New file.
687         * lib/unistdio/u8-u8-asprintf.c: New file.
688         * lib/unistdio/u8-u8-snprintf.c: New file.
689         * lib/unistdio/u8-u8-sprintf.c: New file.
690         * lib/unistdio/u8-u8-vasnprintf.c: New file.
691         * lib/unistdio/u8-u8-vasprintf.c: New file.
692         * lib/unistdio/u8-u8-vsnprintf.c: New file.
693         * lib/unistdio/u8-u8-vsprintf.c: New file.
694         * lib/unistdio/u16-asnprintf.c: New file.
695         * lib/unistdio/u16-asprintf.c: New file.
696         * lib/unistdio/u16-printf-parse.c: New file.
697         * lib/unistdio/u16-snprintf.c: New file.
698         * lib/unistdio/u16-sprintf.c: New file.
699         * lib/unistdio/u16-vasnprintf.c: New file.
700         * lib/unistdio/u16-vasprintf.c: New file.
701         * lib/unistdio/u16-vsnprintf.c: New file.
702         * lib/unistdio/u16-vsprintf.c: New file.
703         * lib/unistdio/u16-u16-asnprintf.c: New file.
704         * lib/unistdio/u16-u16-asprintf.c: New file.
705         * lib/unistdio/u16-u16-snprintf.c: New file.
706         * lib/unistdio/u16-u16-sprintf.c: New file.
707         * lib/unistdio/u16-u16-vasnprintf.c: New file.
708         * lib/unistdio/u16-u16-vasprintf.c: New file.
709         * lib/unistdio/u16-u16-vsnprintf.c: New file.
710         * lib/unistdio/u16-u16-vsprintf.c: New file.
711         * lib/unistdio/u32-asnprintf.c: New file.
712         * lib/unistdio/u32-asprintf.c: New file.
713         * lib/unistdio/u32-printf-parse.c: New file.
714         * lib/unistdio/u32-snprintf.c: New file.
715         * lib/unistdio/u32-sprintf.c: New file.
716         * lib/unistdio/u32-vasnprintf.c: New file.
717         * lib/unistdio/u32-vasprintf.c: New file.
718         * lib/unistdio/u32-vsnprintf.c: New file.
719         * lib/unistdio/u32-vsprintf.c: New file.
720         * lib/unistdio/u32-u32-asnprintf.c: New file.
721         * lib/unistdio/u32-u32-asprintf.c: New file.
722         * lib/unistdio/u32-u32-snprintf.c: New file.
723         * lib/unistdio/u32-u32-sprintf.c: New file.
724         * lib/unistdio/u32-u32-vasnprintf.c: New file.
725         * lib/unistdio/u32-u32-vasprintf.c: New file.
726         * lib/unistdio/u32-u32-vsnprintf.c: New file.
727         * lib/unistdio/u32-u32-vsprintf.c: New file.
728         * tests/unistdio/test-ulc-asnprintf1.c: New file.
729         * tests/unistdio/test-ulc-asnprintf1.h: New file.
730         * tests/unistdio/test-ulc-printf1.h: New file.
731         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
732         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
733         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
734         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
735         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
736         * tests/unistdio/test-ulc-vasprintf1.c: New file.
737         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
738         * tests/unistdio/test-ulc-vsprintf1.c: New file.
739         * tests/unistdio/test-u8-asnprintf1.c: New file.
740         * tests/unistdio/test-u8-asnprintf1.h: New file.
741         * tests/unistdio/test-u8-printf1.h: New file.
742         * tests/unistdio/test-u8-vasnprintf1.c: New file.
743         * tests/unistdio/test-u8-vasnprintf2.c: New file.
744         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
745         * tests/unistdio/test-u8-vasnprintf3.c: New file.
746         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
747         * tests/unistdio/test-u8-vasprintf1.c: New file.
748         * tests/unistdio/test-u8-vsnprintf1.c: New file.
749         * tests/unistdio/test-u8-vsprintf1.c: New file.
750         * tests/unistdio/test-u16-asnprintf1.c: New file.
751         * tests/unistdio/test-u16-asnprintf1.h: New file.
752         * tests/unistdio/test-u16-printf1.h: New file.
753         * tests/unistdio/test-u16-vasnprintf1.c: New file.
754         * tests/unistdio/test-u16-vasnprintf2.c: New file.
755         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
756         * tests/unistdio/test-u16-vasnprintf3.c: New file.
757         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
758         * tests/unistdio/test-u16-vasprintf1.c: New file.
759         * tests/unistdio/test-u16-vsnprintf1.c: New file.
760         * tests/unistdio/test-u16-vsprintf1.c: New file.
761         * tests/unistdio/test-u32-asnprintf1.c: New file.
762         * tests/unistdio/test-u32-asnprintf1.h: New file.
763         * tests/unistdio/test-u32-printf1.h: New file.
764         * tests/unistdio/test-u32-vasnprintf1.c: New file.
765         * tests/unistdio/test-u32-vasnprintf2.c: New file.
766         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
767         * tests/unistdio/test-u32-vasnprintf3.c: New file.
768         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
769         * tests/unistdio/test-u32-vasprintf1.c: New file.
770         * tests/unistdio/test-u32-vsnprintf1.c: New file.
771         * tests/unistdio/test-u32-vsprintf1.c: New file.
772         * modules/unistdio/base: New file.
773         * modules/unistdio/u-printf-args: New file.
774         * modules/unistdio/ulc-asnprintf: New file.
775         * modules/unistdio/ulc-asprintf: New file.
776         * modules/unistdio/ulc-fprintf: New file.
777         * modules/unistdio/ulc-printf-parse: New file.
778         * modules/unistdio/ulc-snprintf: New file.
779         * modules/unistdio/ulc-sprintf: New file.
780         * modules/unistdio/ulc-vasnprintf: New file.
781         * modules/unistdio/ulc-vasprintf: New file.
782         * modules/unistdio/ulc-vfprintf: New file.
783         * modules/unistdio/ulc-vsnprintf: New file.
784         * modules/unistdio/ulc-vsprintf: New file.
785         * modules/unistdio/u8-asnprintf: New file.
786         * modules/unistdio/u8-asprintf: New file.
787         * modules/unistdio/u8-printf-parse: New file.
788         * modules/unistdio/u8-snprintf: New file.
789         * modules/unistdio/u8-sprintf: New file.
790         * modules/unistdio/u8-vasnprintf: New file.
791         * modules/unistdio/u8-vasprintf: New file.
792         * modules/unistdio/u8-vsnprintf: New file.
793         * modules/unistdio/u8-vsprintf: New file.
794         * modules/unistdio/u8-u8-asnprintf: New file.
795         * modules/unistdio/u8-u8-asprintf: New file.
796         * modules/unistdio/u8-u8-snprintf: New file.
797         * modules/unistdio/u8-u8-sprintf: New file.
798         * modules/unistdio/u8-u8-vasnprintf: New file.
799         * modules/unistdio/u8-u8-vasprintf: New file.
800         * modules/unistdio/u8-u8-vsnprintf: New file.
801         * modules/unistdio/u8-u8-vsprintf: New file.
802         * modules/unistdio/u16-asnprintf: New file.
803         * modules/unistdio/u16-asprintf: New file.
804         * modules/unistdio/u16-printf-parse: New file.
805         * modules/unistdio/u16-snprintf: New file.
806         * modules/unistdio/u16-sprintf: New file.
807         * modules/unistdio/u16-vasnprintf: New file.
808         * modules/unistdio/u16-vasprintf: New file.
809         * modules/unistdio/u16-vsnprintf: New file.
810         * modules/unistdio/u16-vsprintf: New file.
811         * modules/unistdio/u16-u16-asnprintf: New file.
812         * modules/unistdio/u16-u16-asprintf: New file.
813         * modules/unistdio/u16-u16-snprintf: New file.
814         * modules/unistdio/u16-u16-sprintf: New file.
815         * modules/unistdio/u16-u16-vasnprintf: New file.
816         * modules/unistdio/u16-u16-vasprintf: New file.
817         * modules/unistdio/u16-u16-vsnprintf: New file.
818         * modules/unistdio/u16-u16-vsprintf: New file.
819         * modules/unistdio/u32-asnprintf: New file.
820         * modules/unistdio/u32-asprintf: New file.
821         * modules/unistdio/u32-printf-parse: New file.
822         * modules/unistdio/u32-snprintf: New file.
823         * modules/unistdio/u32-sprintf: New file.
824         * modules/unistdio/u32-vasnprintf: New file.
825         * modules/unistdio/u32-vasprintf: New file.
826         * modules/unistdio/u32-vsnprintf: New file.
827         * modules/unistdio/u32-vsprintf: New file.
828         * modules/unistdio/u32-u32-asnprintf: New file.
829         * modules/unistdio/u32-u32-asprintf: New file.
830         * modules/unistdio/u32-u32-snprintf: New file.
831         * modules/unistdio/u32-u32-sprintf: New file.
832         * modules/unistdio/u32-u32-vasnprintf: New file.
833         * modules/unistdio/u32-u32-vasprintf: New file.
834         * modules/unistdio/u32-u32-vsnprintf: New file.
835         * modules/unistdio/u32-u32-vsprintf: New file.
836         * modules/unistdio/ulc-asnprintf-tests: New file.
837         * modules/unistdio/ulc-vasnprintf-tests: New file.
838         * modules/unistdio/ulc-vasprintf-tests: New file.
839         * modules/unistdio/ulc-vsnprintf-tests: New file.
840         * modules/unistdio/ulc-vsprintf-tests: New file.
841         * modules/unistdio/u8-asnprintf-tests: New file.
842         * modules/unistdio/u8-vasnprintf-tests: New file.
843         * modules/unistdio/u8-vasprintf-tests: New file.
844         * modules/unistdio/u8-vsnprintf-tests: New file.
845         * modules/unistdio/u8-vsprintf-tests: New file.
846         * modules/unistdio/u16-asnprintf-tests: New file.
847         * modules/unistdio/u16-vasnprintf-tests: New file.
848         * modules/unistdio/u16-vasprintf-tests: New file.
849         * modules/unistdio/u16-vsnprintf-tests: New file.
850         * modules/unistdio/u16-vsprintf-tests: New file.
851         * modules/unistdio/u32-asnprintf-tests: New file.
852         * modules/unistdio/u32-vasnprintf-tests: New file.
853         * modules/unistdio/u32-vasprintf-tests: New file.
854         * modules/unistdio/u32-vsnprintf-tests: New file.
855         * modules/unistdio/u32-vsprintf-tests: New file.
856         * MODULES.html.sh (Unicode string functions): Add the new modules.
857
858 2007-07-01  Bruno Haible  <bruno@clisp.org>
859
860         * lib/sprintf.c (sprintf): Limit the available length estimation,
861         to avoid address wraparound.
862         * lib/vsprintf.c (vsprintf): Likewise.
863         * modules/sprintf-posix (Dependencies): Add stdint.
864         * modules/vsprintf-posix (Dependencies): Likewise.
865
866 2007-07-01  Bruno Haible  <bruno@clisp.org>
867
868         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
869         Windows PATH as well. Conservative double-quoting. Comments.
870
871 2007-07-01  Bruno Haible  <bruno@clisp.org>
872             Eric Blake  <ebb9@byu.net>
873             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
874
875         * gnulib-tool (self_abspathname): Fix algorithm to cope with
876         empty components in $PATH, denoting '.'.
877
878 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
879
880         * gnulib-tool: Fix indentation.
881         (func_create_megatestdir): Likewise.
882         Report by Bruno Haible.
883
884 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
885
886         Sync from Automake.
887         * build-aux/gnupload: Fix shell portability issues with for loops.
888         Report by Karl Berry.
889
890 2007-06-29  Simon Josefsson  <simon@josefsson.org>
891
892         * build-aux/maint.mk (POURL): Use translationproject.org.
893
894 2007-06-27  Simon Josefsson  <simon@josefsson.org>
895             Bruno Haible  <bruno@clisp.org>
896
897         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
898         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
899         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
900         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
901         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
902
903 2007-06-27  Bruno Haible  <bruno@clisp.org>
904
905         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
906         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
907
908 2007-06-26  Karl Berry  <karl@gnu.org>
909
910         * MODULES.html.sh: remove xreadlink-with-size.
911
912 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
913
914         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
915         method that I hope also handles the double-include problem noted
916         by Bruno Haible in
917         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
918
919 2007-06-23  Bruno Haible  <bruno@clisp.org>
920
921         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
922         Don't let the 'mostlyclean' target fail if the last subdirectory could
923         not be removed.
924         Reported by Karl Berry.
925
926 2007-06-23  Bruno Haible  <bruno@clisp.org>
927
928         * gnulib-tool (echo): Add a speedier workaround for ksh.
929         * tests/test-echo.sh: Likewise.
930
931 2007-06-23  Bruno Haible  <bruno@clisp.org>
932
933         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
934         * tests/test-echo.sh: Likewise.
935
936 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
937
938         * gnulib-tool (IFS): Initialize early, so we don't set it to
939         empty later.
940         (self_abspathname): Rewrite algorithm to set it, reindent.
941         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
942         (func_create_megatestdir): Merge some sed scripts.
943
944 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
945
946         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
947         exposed by Sun Studio 11 cc on Solaris 8.
948
949 2007-06-22  Bruno Haible  <bruno@clisp.org>
950
951         * gnulib-tool (echo): Ensure the echo primitive does not interpret
952         backslashes.
953         * tests/test-echo.sh: New file.
954
955 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
956
957         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
958         simplify `sed_replace_build_aux' scripts, they are portable but
959         echoing them with `echo' is not.
960         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
961
962 2007-06-21  Karl Berry  <karl@gnu.org>
963
964         * config/srclist.txt: guess we can't handle the licenses via
965         srclist at the moment.
966
967 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
968
969         * MODULES.html.sh: Add include_next.
970         * modules/include_next: New file.
971
972 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
973
974         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
975         INCLUDE_NEXT.
976         (gl_CHECK_NEXT_HEADERS): New macro.
977         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
978         the obsolescent gl_ABSOLUTE_HEADER.
979         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
980         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
981         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
982         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
983         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
984         * m4/math_h.m4 (gl_MATH_H): Likewise.
985         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
986         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
987         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
988         * m4/stdint.m4 (gl_STDINT_H): Likewise.
989         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
990         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
991         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
992         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
993         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
994         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
995         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
996         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
997         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
998         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
999         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
1000         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1001         * m4/inttypes.m4 (gl_INTTYPES_H): Define
1002         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
1003         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
1004         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
1005         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
1006         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
1007         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
1008         * lib/float_.h: Likewise.
1009         * lib/inttypes_.h: Likewise.
1010         * lib/math_.h: Likewise.
1011         * lib/search_.h: Likewise.
1012         * lib/signal_.h: Likewise.
1013         * lib/stdint_.h: Likewise.
1014         * lib/stdio_.h: Likewise.
1015         * lib/stdlib_.h: Likewise.
1016         * lib/string_.h: Likewise.
1017         * lib/sys_stat_.h: Likewise.
1018         * lib/sys_time_.h: Likewise.
1019         * lib/time_.h: Likewise.
1020         * lib/unistd_.h: Likewise.
1021         * lib/wchar_.h: Likewise.
1022         * lib/wctype_.h: Likewise.
1023         * lib/dirent_.h: Likewise.
1024         * lib/iconv_.h: Likewise.
1025         * lib/locale_.h: Likewise.
1026         * lib/netinet_in_.h: Likewise.
1027         * lib/sys_select_.h: Likewise.
1028         * lib/sys_socket_.h: Likewise.
1029         * lib/sysexits_.h: Likewise.
1030         * modules/fcntl (Depends-on): Depend on include_next, not
1031         absolute_header.
1032         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
1033         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
1034         * modules/fchdir: Likewise.
1035         * modules/float: Likewise.
1036         * modules/iconv_open: Likewise.
1037         * modules/inttypes: Likewise.
1038         * modules/locale: Likewise.
1039         * modules/math: Likewise.
1040         * modules/netinet_in: Likewise.
1041         * modules/search: Likewise.
1042         * modules/signal: Likewise.
1043         * modules/stdint: Likewise.
1044         * modules/stdio: Likewise.
1045         * modules/stdlib: Likewise.
1046         * modules/string: Likewise.
1047         * modules/sys_select: Likewise.
1048         * modules/sys_socket: Likewise.
1049         * modules/sys_stat: Likewise.
1050         * modules/sys_time: Likewise.
1051         * modules/sysexits: Likewise.
1052         * modules/time: Likewise.
1053         * modules/unistd: Likewise.
1054         * modules/wchar: Likewise.
1055         * modules/wctype: Likewise.
1056         * modules/sys_stat: Change maintainer to "all".
1057         * modules/unistd: Likewise.
1058
1059 2007-06-20  Karl Berry  <karl@gnu.org>
1060
1061         * config/srclist.txt: track www changes in license files.
1062
1063 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
1064
1065         * build-aux/bootstrap: Remove stray dot.
1066         Make sure build_aux settings are honored when linking
1067         gnulib_extra_files.
1068
1069 2007-06-19  Eric Blake  <ebb9@byu.net>
1070
1071         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
1072         Allow compilation on cygwin.
1073
1074 2007-06-19  Jim Meyering  <jim@meyering.net>
1075
1076         xreadlink-with-size: Remove module.  No longer used.
1077         Ex-callers now use xreadlink or mreadlink-with-size.
1078         * modules/xreadlink-with-size: Remove module.
1079         * lib/xreadlink-with-size.c: Remove file.
1080         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
1081         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
1082         just before the function definition *is* accurate.
1083
1084         Eliminate one way canonicalize_filename_mode could exit.
1085         * lib/canonicalize.c (canonicalize_filename_mode):
1086         Use mreadlink_with_size, not xreadlink_with_size.
1087
1088 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
1089
1090         Detect porting problems to FreeBSD/arm, which has time_t wider than
1091         long int.  Original problem reported for GNU diff by Xin Li in
1092         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
1093         * modules/getdate (Depends-on): Add intprops, verify.
1094         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
1095         is an integer type no wider than long int.
1096
1097 2007-06-18  Jim Meyering  <jim@meyering.net>
1098
1099         New module: mreadlink-with-size.
1100         * MODULES.html.sh: Add mreadlink-with-size.
1101         * modules/mreadlink-with-size: New module
1102         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
1103         not xreadlink-with-size.
1104         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
1105
1106 2007-06-16  Bruno Haible  <bruno@clisp.org>
1107
1108         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
1109         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
1110         Reported by Gary V. Vaughan <gary@gnu.org>.
1111
1112 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
1113
1114         Revamp lchown so that it lives in unistd.h where it belongs.
1115         * lib/lchown.h: Remove.
1116         * lib/dirchownmod.c: Don't include lib/lchown.h.
1117         * lib/fchownat.c: Likewise.
1118         * lib/openat.c: Likewise.
1119         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
1120         does not follow symlinks.
1121         (EOPNOTSUPP): Define if not defined.
1122         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
1123         is defined to 0.
1124         (lchown): New decl.
1125         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
1126         Do not check for lchown decl.
1127         Set REPLACE_LCHOWN.
1128         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
1129         REPLACE_LCHOWN.
1130         * modules/chown: Make it clear it follows symlinks.
1131         * modules/lchown: Make it clear it doesn't follow symlinks.
1132         (Files): Remove lib/lchown.h
1133         (Depends-on): Add unistd.
1134         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
1135         (Include): Include <unistd.h>, not "lchown.h".
1136         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
1137         REPLACE_LCHOWN.
1138
1139 2007-06-15  Jim Meyering  <jim@meyering.net>
1140
1141         Change license (GPL to LGPL) of fsusage and dependents.
1142         * modules/fsusage (License): Change to LGPL.
1143         * modules/full-read (License): Likewise.
1144         * modules/full-write (License): Likewise.
1145         * modules/safe-read (License): Likewise.
1146         * modules/safe-write (License): Likewise.
1147
1148 2007-06-14  Ben Pfaff  <blp@gnu.org>
1149
1150         Missing part of allocsa -> malloca transition.
1151         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
1152         gl_MALLOCA.
1153
1154 2007-06-12  Bruno Haible  <bruno@clisp.org>
1155
1156         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
1157         to ia64, x86_64, i386.
1158         Reported by Eric Blake.
1159
1160 2007-06-12  Bruno Haible  <bruno@clisp.org>
1161
1162         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
1163         cross-compiling to x86_64.
1164
1165 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
1166
1167         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
1168         glitch reported by Ralf Wildenhues in
1169         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
1170
1171         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
1172         Vin Shelton.
1173
1174 2007-06-11  Bruno Haible  <bruno@clisp.org>
1175
1176         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
1177         replacement string.
1178         Reported by Eric Blake.
1179
1180 2007-06-10  Bruno Haible  <bruno@clisp.org>
1181
1182         Prepare vasnprintf code for use with Unicode strings.
1183         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
1184         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
1185         TYPE_U32_STRING.
1186         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
1187         a_u32_string variants.
1188         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1189         * lib/printf-args.c: Don't include config.h and the specification
1190         header if PRINTF_FETCHARGS is already defined.
1191         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1192         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
1193         TYPE_U16_STRING, TYPE_U32_STRING.
1194         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
1195         u16_directive, u16_directives, u32_directive, u32_directives): New
1196         types.
1197         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
1198         New declarations.
1199         * lib/printf-parse.c: Don't include config.h and the specification
1200         header if PRINTF_PARSE is already defined. Eliminate the set of
1201         parameters for WIDE_CHAR_VERSION; the user of this file must provide
1202         them now. Include c-ctype.h.
1203         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
1204         directive and CHAR_T_ONLY_ASCII.
1205         * lib/vasnprintf.c: Don't include config.h and the specification header
1206         if VASNPRINTF is already defined.
1207         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
1208         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
1209         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
1210         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
1211         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
1212         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
1213         code accordingly.
1214         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
1215         pad_ourselves also in this case, with the 'c' and 's' directives, and
1216         with a different notion of "width".
1217         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
1218
1219 2007-06-10  Bruno Haible  <bruno@clisp.org>
1220
1221         * modules/unistr/u32-mbsnlen: New file.
1222         * lib/unistr/u32-mbsnlen.c: New file.
1223
1224         * modules/unistr/u16-mbsnlen: New file.
1225         * lib/unistr/u16-mbsnlen.c: New file.
1226
1227         * modules/unistr/u8-mbsnlen: New file.
1228         * lib/unistr/u8-mbsnlen.c: New file.
1229
1230         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
1231         declarations.
1232
1233 2007-06-10  Bruno Haible  <bruno@clisp.org>
1234
1235         * lib/string_.h (mbsnlen): New declaration.
1236         * lib/mbsnlen.c: New file.
1237         * m4/mbsnlen.m4: New file.
1238         * modules/mbsnlen: New file.
1239         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
1240         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
1241         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
1242
1243 2007-06-10  Bruno Haible  <bruno@clisp.org>
1244
1245         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
1246
1247 2007-06-10  Bruno Haible  <bruno@clisp.org>
1248
1249         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
1250         * lib/mbuiter.h: Likewise.
1251
1252 2007-06-10  Bruno Haible  <bruno@clisp.org>
1253
1254         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
1255         declaration.
1256
1257 2007-06-10  Karl Berry  <karl@gnu.org>
1258
1259         * config/srclist.txt: remove gettext entries, Bruno prefers
1260         to update individually.
1261
1262 2007-06-10  Bruno Haible  <bruno@clisp.org>
1263
1264         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
1265         'maxlen'. Ensure only length + width bytes are allocated, not
1266         length + 1 + width.
1267
1268 2007-06-09  Bruno Haible  <bruno@clisp.org>
1269
1270         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
1271         (CHAR_T): Remove macro.
1272         (VASNPRINTF): Update.
1273
1274 2007-06-09  Bruno Haible  <bruno@clisp.org>
1275
1276         * MODULES.html.sh (Unicode string functions): Add the new modules.
1277
1278         * modules/uniconv/u32-conv-to-enc: New file.
1279         * lib/uniconv/u32-conv-to-enc.c: New file.
1280         * modules/uniconv/u32-conv-to-enc-tests: New file.
1281         * tests/uniconv/test-u32-conv-to-enc.c: New file.
1282
1283         * modules/uniconv/u16-conv-to-enc: New file.
1284         * lib/uniconv/u16-conv-to-enc.c: New file.
1285         * lib/uniconv/u-conv-to-enc.h: New file.
1286         * modules/uniconv/u16-conv-to-enc-tests: New file.
1287         * tests/uniconv/test-u16-conv-to-enc.c: New file.
1288
1289         * modules/uniconv/u8-conv-to-enc: New file.
1290         * lib/uniconv/u8-conv-to-enc.c: New file.
1291         * modules/uniconv/u8-conv-to-enc-tests: New file.
1292         * tests/uniconv/test-u8-conv-to-enc.c: New file.
1293
1294         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
1295         u32_conv_to_encoding): New declarations.
1296
1297 2007-06-09  Bruno Haible  <bruno@clisp.org>
1298
1299         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
1300
1301 2007-06-09  Bruno Haible  <bruno@clisp.org>
1302
1303         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
1304         * modules/malloca: Renamed from modules/allocsa, updated.
1305         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
1306         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
1307         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
1308         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
1309         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
1310         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
1311         * modules/xmalloca: Renamed from modules/xallocsa, updated.
1312         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
1313         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
1314         * modules/c-strcasestr (Depends-on): Update.
1315         * lib/c-strcasestr.c: Update.
1316         * modules/c-strstr (Depends-on): Update.
1317         * lib/c-strstr.c: Update.
1318         * modules/canonicalize-lgpl (Depends-on): Update.
1319         * lib/canonicalize-lgpl.c: Update.
1320         * modules/clean-temp (Depends-on): Update.
1321         * lib/clean-temp.c: Update.
1322         * modules/csharpcomp (Depends-on): Update.
1323         * lib/csharpcomp.c: Update.
1324         * modules/csharpexec (Depends-on): Update.
1325         * lib/csharpexec.c: Update.
1326         * modules/javacomp (Depends-on): Update.
1327         * lib/javacomp.c: Update.
1328         * modules/javaexec (Depends-on): Update.
1329         * lib/javaexec.c: Update.
1330         * modules/mbscasestr (Depends-on): Update.
1331         * lib/mbscasestr.c: Update.
1332         * modules/mbsstr (Depends-on): Update.
1333         * lib/mbsstr.c: Update.
1334         * modules/setenv (Depends-on): Update.
1335         * lib/setenv.c: Update.
1336         * modules/strcasestr (Depends-on): Update.
1337         * lib/strcasestr.c: Update.
1338         * modules/striconveha (Depends-on): Update.
1339         * lib/striconveha.c: Update.
1340         * modules/relocatable-prog-wrapper (Files): Update.
1341         * lib/relocwrapper.c: Update.
1342         * build-aux/install-reloc: Update.
1343         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
1344
1345 2007-06-08  Bruno Haible  <bruno@clisp.org>
1346
1347         Port to uClibc.
1348         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
1349         * lib/fpurge.c (fpurge): Likewise.
1350         * lib/freading.c (freading): Likewise.
1351         * lib/fseeko.c (rpl_fseeko): Likewise.
1352         * lib/fseterr.c (fseterr): Likewise.
1353         * lib/fwriting.c (fwriting): Likewise.
1354         * tests/test-fflush.c (main): Avoid a failure on uClibc.
1355
1356 2007-06-08  Bruno Haible  <bruno@clisp.org>
1357
1358         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
1359         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
1360         * modules/gettext (Files): Add m4/intlmacosx.m4.
1361
1362 2007-06-07  Bruno Haible  <bruno@clisp.org>
1363
1364         * modules/localename-tests: New file.
1365         * tests/test-localename.c: New file.
1366
1367         New module 'localename'.
1368         * lib/localename.h: New file.
1369         * lib/localename.c: New file, from GNU gettext.
1370         * m4/localename.m4: New file.
1371         * modules/localename: New file.
1372
1373 2007-06-07  Bruno Haible  <bruno@clisp.org>
1374
1375         Work around the lack of <wchar.h> on some builds of uClibc.
1376         * doc/headers/wchar.texi: Update.
1377         * lib/wchar_.h: Include <wchar.h> only if it exists.
1378         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
1379         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
1380         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
1381         doesn't exist.
1382         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
1383         * modules/mbfile (Depends-on): Add wchar.
1384         * modules/mbiter (Depends-on): Likewise.
1385         * modules/mbuiter (Depends-on): Likewise.
1386         Reported by Simon Josefsson.
1387
1388 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
1389
1390         Work around problem reported by Steven M. Schweda in
1391         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
1392         Tru64 5.1B with the Compaq compiler environment installed declares
1393         an 'isblank' function but does not define it in the C library.
1394         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
1395         * lib/regex_internal.h (isblank): Likewise.
1396         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
1397         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1398
1399 2007-06-05  Bruno Haible  <bruno@clisp.org>
1400
1401         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
1402         ia64.
1403         * modules/printf-safe: New file.
1404         * modules/fprintf-posix (Depends-on): Add printf-safe.
1405         * modules/printf-posix (Depends-on): Likewise.
1406         * modules/snprintf-posix (Depends-on): Likewise.
1407         * modules/sprintf-posix (Depends-on): Likewise.
1408         * modules/vasnprintf-posix (Depends-on): Likewise.
1409         * modules/vasprintf-posix (Depends-on): Likewise.
1410         * modules/vfprintf-posix (Depends-on): Likewise.
1411         * modules/vprintf-posix (Depends-on): Likewise.
1412         * modules/vsnprintf-posix (Depends-on): Likewise.
1413         * modules/vsprintf-posix (Depends-on): Likewise.
1414         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1415         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1416         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1417         "no" on i386, x86_64, ia64.
1418         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1419         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1420         on i386, x86_64, ia64.
1421         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1422         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1423         on i386, x86_64, ia64.
1424         * tests/test-vasnprintf-posix.c: Include float.h.
1425         (LDBL80_WORDS): New macro.
1426         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1427         on i386, x86_64, ia64.
1428         * tests/test-vasprintf-posix.c: Include float.h.
1429         (LDBL80_WORDS): New macro.
1430         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1431         on i386, x86_64, ia64.
1432         * tests/test-snprintf-posix.c: Include float.h.
1433         * tests/test-sprintf-posix.c: Likewise.
1434         * tests/test-vsnprintf-posix.c: Likewise.
1435         * tests/test-vsprintf-posix.c: Likewise.
1436
1437 2007-06-05  Bruno Haible  <bruno@clisp.org>
1438
1439         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1440         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1441         non-IEEE numbers on i386, x86_64, ia64.
1442         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1443         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1444         * tests/test-isnanl.h: Include float.h.
1445         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1446
1447 2007-06-05  Bruno Haible  <bruno@clisp.org>
1448
1449         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1450         also the %a / %A. Handle the %a / %A code before this extra handling.
1451
1452 2007-06-05  Bruno Haible  <bruno@clisp.org>
1453
1454         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1455         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1456
1457 2007-06-05  Bruno Haible  <bruno@clisp.org>
1458
1459         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1460         typo in variable name.
1461
1462 2007-06-05  Eric Blake  <ebb9@byu.net>
1463
1464         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1465         Reported by Simon Josefsson.
1466
1467 2007-06-04  Bruno Haible  <bruno@clisp.org>
1468
1469         Avoid test failures on some PowerPC platforms.
1470         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1471         Define differently for PowerPC.
1472         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1473         Reported by Gary V. Vaughan <gary@gnu.org>.
1474
1475 2007-06-02  Bruno Haible  <bruno@clisp.org>
1476
1477         Fix test-stdint failure on FreeBSD/ia64.
1478         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1479         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1480         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1481         * doc/headers/stdint.texi: Update.
1482
1483 2007-06-01  Bruno Haible  <bruno@clisp.org>
1484
1485         * tests/test-binary-io.c (main): Pass a third argument to open().
1486         Reported by Gary V. Vaughan <gary@gnu.org>.
1487
1488 2007-06-01  Bruno Haible  <bruno@clisp.org>
1489
1490         * doc/functions/frexpl.texi: Update for mingw.
1491
1492 2007-06-01  Bruno Haible  <bruno@clisp.org>
1493
1494         * tests/test-lseek.c (main): Disable test of errno for invalid third
1495         argument.
1496         * doc/functions/lseek.texi: Update.
1497         Reported by Gary V. Vaughan <gary@gnu.org>.
1498
1499 2007-05-28  Bruno Haible  <bruno@clisp.org>
1500
1501         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1502
1503 2007-05-31  Eric Blake  <ebb9@byu.net>
1504
1505         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1506         cross compiling.
1507
1508 2007-05-30  Eric Blake  <ebb9@byu.net>
1509         and Bruno Haible  <bruno@clisp.org>
1510
1511         Work around mingw test failures exposed by m4-1.4.9b.
1512         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1513         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1514         moment.
1515
1516 2007-05-30  Bruno Haible  <bruno@clisp.org>
1517
1518         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1519         assuming that they are closed. Needed on HP-UX 11.
1520
1521 2007-05-29  Bruno Haible  <bruno@clisp.org>
1522
1523         Fix a problem with #include_next.
1524         * lib/dirent_.h: Split the double-inclusion guard.
1525         * lib/fcntl_.h: Likewise.
1526         * lib/float_.h: Likewise.
1527         * lib/iconv_.h: Likewise.
1528         * lib/inttypes_.h: Likewise.
1529         * lib/locale_.h: Likewise.
1530         * lib/math_.h: Likewise.
1531         * lib/netinet_in_.h: Likewise.
1532         * lib/search_.h: Likewise.
1533         * lib/signal_.h: Likewise.
1534         * lib/stdint_.h: Likewise.
1535         * lib/stdio_.h: Likewise.
1536         * lib/stdlib_.h: Likewise.
1537         * lib/string_.h: Likewise.
1538         * lib/sys_select_.h: Likewise.
1539         * lib/sys_socket_.h: Likewise.
1540         * lib/sys_stat_.h: Likewise.
1541         * lib/sys_time_.h: Likewise.
1542         * lib/sysexits_.h: Likewise.
1543         * lib/time_.h: Likewise.
1544         * lib/unistd_.h: Likewise.
1545         * lib/wchar_.h: Likewise.
1546         * lib/wctype_.h: Likewise.
1547
1548 2007-05-29  Bruno Haible  <bruno@clisp.org>
1549
1550         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1551         for the moment.
1552
1553 2007-05-29  Bruno Haible  <bruno@clisp.org>
1554
1555         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1556         invocation.
1557         Reported by Eric Blake.
1558
1559 2007-05-29  Bruno Haible  <bruno@clisp.org>
1560
1561         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1562         compiling case.
1563
1564 2007-05-29  Eric Blake  <ebb9@byu.net>
1565             Bruno Haible  <bruno@clisp.org>
1566
1567         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1568         cross compiles.
1569
1570 2007-05-28  Eric Blake  <ebb9@byu.net>
1571
1572         * modules/closein-tests (test_closein_LDADD): Support test on
1573         cygwin with libtool.
1574
1575 2007-05-28  Bruno Haible  <bruno@clisp.org>
1576
1577         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1578         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1579         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1580         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1581         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1582         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1583         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1584         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1585         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1586
1587 2007-05-28  Eric Blake  <ebb9@byu.net>
1588
1589         Unconditionally include <config.h> in unit tests.
1590         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
1591         * tests/test-allocsa.c, tests/test-arcfour.c,
1592         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
1593         tests/test-array_list.c, tests/test-array_oset.c,
1594         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
1595         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
1596         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
1597         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
1598         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
1599         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
1600         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
1601         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
1602         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
1603         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
1604         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
1605         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
1606         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
1607         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
1608         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
1609         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
1610         test-md5.c, test-memmem.c, test-printf-posix.c,
1611         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
1612         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
1613         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
1614         test-strcasestr.c, test-striconv.c, test-striconveh.c,
1615         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
1616         test-vasnprintf-posix2.c, test-vasnprintf.c,
1617         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
1618         test-vfprintf-posix.c, test-vprintf-posix.c,
1619         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
1620         test-xvasprintf.c: Likewise.
1621
1622 2007-05-28  Bruno Haible  <bruno@clisp.org>
1623
1624         * gnulib-tool (func_import): Remember the --with-tests command-line
1625         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
1626         Reported by Eric Blake.
1627
1628 2007-05-28  Bruno Haible  <bruno@clisp.org>
1629
1630         * modules/ftell-tests: New file.
1631         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
1632         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
1633
1634         * lib/ftell.c: New file.
1635         * modules/ftell: New file.
1636         * m4/ftell.m4: New file.
1637         * doc/functions/ftell.texi: Update.
1638         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
1639         REPLACE_FTELL.
1640         * lib/stdio_.h (rpl_ftell): New declaration.
1641         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
1642         REPLACE_FTELL.
1643
1644 2007-05-28  Eric Blake  <ebb9@byu.net>
1645
1646         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
1647
1648 2007-05-28  Bruno Haible  <bruno@clisp.org>
1649
1650         * modules/fseek-tests: New file.
1651         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
1652         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
1653
1654         * lib/fseek.c: New file.
1655         * modules/fseek: New file.
1656         * m4/fseek.m4: New file.
1657         * doc/functions/fseek.texi: Update.
1658         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
1659         REPLACE_FSEEK.
1660         * lib/stdio_.h (rpl_fseek): New declaration.
1661         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
1662         REPLACE_FSEEK.
1663
1664 2007-05-28  Bruno Haible  <bruno@clisp.org>
1665
1666         * lib/stdio_.h (fflush): More comments.
1667
1668 2007-05-28  Bruno Haible  <bruno@clisp.org>
1669
1670         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
1671         runtime test.
1672
1673 2007-05-28  Eric Blake  <ebb9@byu.net>
1674
1675         Improve lseek module.
1676         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
1677         * lib/unistd_.h (lseek): Scale back link warning message.
1678         * tests/test-lseek.c: Beef up test.
1679         * tests/test-lseek.sh: Exercise more facets of lseek.
1680         Reported by Bruno Haible.
1681
1682 2007-05-28  Bruno Haible  <bruno@clisp.org>
1683
1684         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
1685         to define.
1686
1687 2007-05-27  Bruno Haible  <bruno@clisp.org>
1688
1689         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
1690
1691 2007-05-27  Bruno Haible  <bruno@clisp.org>
1692
1693         * modules/openmp: New file.
1694         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
1695         Noah Misch.
1696
1697 2007-05-26  Bruno Haible  <bruno@clisp.org>
1698
1699         * modules/chdir-long (Depends-on): Add fchdir.
1700         * modules/chdir-safer (Depends-on): Likewise.
1701         * modules/fts (Depends-on): Likewise.
1702         * modules/fts-lgpl (Depends-on): Likewise.
1703         * modules/openat (Depends-on): Likewise.
1704         * modules/savewd (Depends-on): Likewise.
1705
1706 2007-05-24  Eric Blake  <ebb9@byu.net>
1707
1708         Fix lseek on mingw.
1709         * modules/lseek: New module.
1710         * m4/lseek.m4: New file.
1711         * lib/lseek.c: New file.
1712         * modules/lseek-tests: New file.
1713         * tests/test-lseek.c: New file.
1714         * tests/test-lseek.sh: New file.
1715         * MODULES.html.sh: Document lseek module.
1716         * modules/fflush (Depends-on): Add lseek, fseeko.
1717         * modules/fseeko (Depends-on): Likewise.
1718         * modules/ftello (Depends-on): Likewise.
1719         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
1720         broken.
1721         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
1722         broken.
1723         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
1724         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
1725         * lib/ftello.c (rpl_ftello): Likewise.
1726         * tests/test-fseeko.c (main): Test this.
1727         * tests/test-fseeko.sh: Likewise.
1728         * tests/test-ftello.c (main): Likewise.
1729         * tests/test-ftello.sh: Likewise.
1730         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
1731         implies replacing fseek.
1732         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
1733         HAVE_FTELLO.
1734         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
1735         * modules/unistd (Makefile.am): Likewise.
1736         * lib/unistd_.h (lseek): Declare a replacement.
1737         * doc/functions/lseek.texi (lseek): Document this fix.
1738         * doc/functions/fseek.texi (fseek): Likewise.
1739         * doc/functions/ftell.texi (ftell): Likewise.
1740
1741 2007-05-24  Bruno Haible  <bruno@clisp.org>
1742
1743         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
1744         in the printed representation of a NaN.
1745         * tests/test-vasprintf-posix.c (test_function): Likewise.
1746         * tests/test-snprintf-posix.h (test_function): Likewise.
1747         * tests/test-sprintf-posix.h (test_function): Likewise.
1748         Reported by Eric Blake.
1749
1750 2007-05-23  Eric Blake  <ebb9@byu.net>
1751
1752         Fix fseeko/ftello on cygwin 1.5.24.
1753         * doc/functions/fseeko.texi (fseeko): Document the fix.
1754         * doc/functions/ftello.texi (ftello): Document the fix.
1755         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
1756         * doc/functions/stdout.text (stdout): New file.
1757         * doc/functions/stderr.text (stderr): New file.
1758         * doc/gnulib.texi (Function Substitutes): Use new files.
1759         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
1760         prior to 1.7.0.
1761         * tests/test-ftello.c (main): Likewise for ftello.
1762         * tests/test-fseeko.sh: New file.
1763         * tests/test-ftello.sh: New file.
1764         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
1765         with seekable stdin.
1766         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
1767         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
1768         (gl_REPLACE_FSEEKO): New macro.
1769         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
1770         * modules/fseeko (Files): Distribute fseeko.c.
1771         * modules/ftello (Files): Distribute ftello.c.
1772         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
1773         mode.
1774         * lib/ftello.c (rpl_ftello): New file.
1775         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
1776         fseeko, ftello.
1777         (gl_STDIN_LARGE_OFFSET): New macro.
1778         * modules/stdio (Makefile.am): Perform the replacement.
1779         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
1780
1781 2007-05-23  Bruno Haible  <bruno@clisp.org>
1782
1783         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
1784         GNULIB_POSIXCHECK is defined.
1785
1786 2007-05-21  Bruno Haible  <bruno@clisp.org>
1787
1788         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
1789         Check also the output for NaN arguments. When cross-compiling, guess
1790         no on IRIX.
1791         * lib/vasnprintf.c: Update comments.
1792         * tests/test-vasnprintf-posix.c (strisnan): New function.
1793         (test_function): Use it.
1794         * tests/test-vasprintf-posix.c (strisnan): New function.
1795         (test_function): Use it.
1796         * tests/test-snprintf-posix.h (strisnan): New function.
1797         (test_function): Use it.
1798         * tests/test-sprintf-posix.h (strisnan): New function.
1799         (test_function): Use it.
1800         Reported by Eric Blake.
1801
1802 2007-05-20  Bruno Haible  <bruno@clisp.org>
1803
1804         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
1805         numbers that fails on BeOS.
1806         * doc/functions/frexpl.texi: Update.
1807
1808 2007-05-20  Jim Meyering  <jim@meyering.net>
1809
1810         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
1811         forced upon us by glibc-2.6.
1812
1813 2007-05-20  Bruno Haible  <bruno@clisp.org>
1814
1815         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
1816         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
1817         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
1818         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
1819         NEED_PRINTF_INFINITE.
1820         (is_infinitel): New function.
1821         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
1822         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
1823         gl_PREREQ_VASNPRINTF_INFINITE.
1824         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
1825         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1826         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
1827         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
1828         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
1829         gl_PREREQ_VASNPRINTF_INFINITE.
1830         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1831         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1832         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1833         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1834         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1835         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1836         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1837         * doc/functions/fprintf.texi: Update.
1838         * doc/functions/printf.texi: Update.
1839         * doc/functions/snprintf.texi: Update.
1840         * doc/functions/sprintf.texi: Update.
1841         * doc/functions/vfprintf.texi: Update.
1842         * doc/functions/vprintf.texi: Update.
1843         * doc/functions/vsnprintf.texi: Update.
1844         * doc/functions/vsprintf.texi: Update.
1845
1846 2007-05-20  Bruno Haible  <bruno@clisp.org>
1847
1848         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
1849         was not found in libc.
1850         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
1851
1852 2007-05-20  Bruno Haible  <bruno@clisp.org>
1853
1854         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1855         printed as "-nan" instead of "nan".
1856         * tests/test-vasprintf-posix.c (test_function): Likewise.
1857         * tests/test-snprintf-posix.h (test_function): Likewise.
1858         * tests/test-sprintf-posix.h (test_function): Likewise.
1859         Needed for HP-UX 11.
1860
1861 2007-05-20  Jim Meyering  <jim@meyering.net>
1862
1863         Fix buggy test for the fchownat-deref bug.
1864         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
1865         symlink required for the run-test.  Without it, this test would
1866         always declare that fchownat doesn't work, and client code would
1867         unnecessarily use the replacement function with fixed libc.
1868         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
1869         Reported by Greg Schafer.
1870
1871 2007-05-19  Bruno Haible  <bruno@clisp.org>
1872
1873         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
1874         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
1875         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
1876         Needed for IRIX 6.5 and Solaris 2.5.1.
1877
1878 2007-05-19  Bruno Haible  <bruno@clisp.org>
1879
1880         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
1881         (test_function): Skip tests involving -0.0 on platforms where
1882         -0.0 = 0.0.
1883         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
1884         (test_function): Skip tests involving -0.0 on platforms where
1885         -0.0 = 0.0.
1886         * tests/test-snprintf-posix.h (have_minus_zero): New function.
1887         (test_function): Skip tests involving -0.0 on platforms where
1888         -0.0 = 0.0.
1889         * tests/test-sprintf-posix.h (have_minus_zero): New function.
1890         (test_function): Skip tests involving -0.0 on platforms where
1891         -0.0 = 0.0.
1892         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
1893         tests.
1894         * tests/test-printf-posix.h (test_function): Likewise.
1895         * tests/test-printf-posix.output: Remove all -0.0 related results.
1896         Needed for IRIX 6.5.
1897
1898 2007-05-19  Bruno Haible  <bruno@clisp.org>
1899
1900         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1901         printed as "nan0x7fffffff" instead of "nan".
1902         * tests/test-vasprintf-posix.c (test_function): Likewise.
1903         * tests/test-snprintf-posix.h (test_function): Likewise.
1904         * tests/test-sprintf-posix.h (test_function): Likewise.
1905         * tests/test-fprintf-posix.h (NaN): Remove macro.
1906         (test_function): Remove all NaN related tests.
1907         * tests/test-printf-posix.h (NaN): Remove macro.
1908         (test_function): Remove all NaN related tests.
1909         * tests/test-printf-posix.output: Remove all NaN related results.
1910         Needed for IRIX 6.5.
1911
1912 2007-05-19  Bruno Haible  <bruno@clisp.org>
1913
1914         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
1915         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
1916
1917 2007-05-19  Bruno Haible  <bruno@clisp.org>
1918
1919         * lib/float_.h: New file.
1920         * m4/float_h.m4: New file.
1921         * modules/float: New file.
1922         * modules/isnanl (Dependencies): Add float.
1923         * modules/isnanl-nolibm (Dependencies): Likewise.
1924         * modules/mathl (Dependencies): Likewise.
1925         * modules/printf-frexpl (Dependencies): Likewise.
1926         * modules/signbit (Dependencies): Likewise.
1927         * modules/vasnprintf (Dependencies): Likewise.
1928         * doc/headers/float.texi: Update.
1929
1930 2007-05-19  Jim Meyering  <jim@meyering.net>
1931
1932         * lib/utimens.c (gl_futimens): Rename from futimens,
1933         now that glibc-2.6 declares futimens.
1934         * lib/utimens.h: Likewise.
1935
1936 2007-05-19  Bruno Haible  <bruno@clisp.org>
1937
1938         Avoid test failures on mingw.
1939         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
1940         * tests/test-printf-posix.sh: Likewise.
1941         * tests/test-vfprintf-posix.sh: Likewise.
1942         * tests/test-vprintf-posix.sh: Likewise.
1943
1944 2007-05-19  Bruno Haible  <bruno@clisp.org>
1945
1946         Fix *printf result for NaN, Inf, -0.0 on mingw.
1947         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
1948         * lib/vasnprintf.c: Include math.h and isnan.h.
1949         (is_infinite_or_zero): New function.
1950         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
1951         values in the %f, %F, %e, %E, %g, %G directives.
1952         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
1953         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1954         gl_PRINTF_INFINITE and test its result. Invoke
1955         gl_PREREQ_VASNPRINTF_INFINITE.
1956         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1957         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1958         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1959         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1960         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1961         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1962         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1963         * doc/functions/fprintf.texi: Update.
1964         * doc/functions/printf.texi: Update.
1965         * doc/functions/snprintf.texi: Update.
1966         * doc/functions/sprintf.texi: Update.
1967         * doc/functions/vfprintf.texi: Update.
1968         * doc/functions/vprintf.texi: Update.
1969         * doc/functions/vsnprintf.texi: Update.
1970         * doc/functions/vsprintf.texi: Update.
1971
1972 2007-05-19  Bruno Haible  <bruno@clisp.org>
1973
1974         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
1975         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
1976         Instead of multiplying with 10^k, set extra_zeroes to k.
1977         (scale10_round_long_double): Remove function.
1978
1979 2007-05-18  Bruno Haible  <bruno@clisp.org>
1980
1981         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
1982         introduced on 2007-05-06.
1983
1984 2007-05-18  Bruno Haible  <bruno@clisp.org>
1985
1986         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
1987         %g directives.
1988         * tests/test-vasprintf-posix.c (test_function): Likewise.
1989         * tests/test-snprintf-posix.h (test_function): Likewise.
1990         * tests/test-sprintf-posix.h (test_function): Likewise.
1991
1992 2007-05-18  Bruno Haible  <bruno@clisp.org>
1993
1994         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
1995         (strmatch): New function.
1996         (test_function): Test the %f directive on numbers of various exponents.
1997         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
1998         (strmatch): New function.
1999         (test_function): Test the %f directive on numbers of various exponents.
2000         * tests/test-snprintf-posix.h (strmatch): New function.
2001         (test_function): Test the %f directive on numbers of various exponents.
2002         * tests/test-sprintf-posix.h (strmatch): New function.
2003         (test_function): Test the %f directive on numbers of various exponents.
2004         * tests/test-snprintf-posix.c (SIZEOF): New macro.
2005         * tests/test-sprintf-posix.c (SIZEOF): New macro.
2006         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
2007         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
2008
2009 2007-05-18  Bruno Haible  <bruno@clisp.org>
2010
2011         Add support for 'long double' number output.
2012         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
2013         * lib/vasnprintf.c: Include math.h and float+.h.
2014         (mp_limb_t): New type.
2015         (GMP_LIMB_BITS): New macro.
2016         (mp_twolimb_t): New type.
2017         (GMP_TWOLIMB_BITS): New macro.
2018         (mpn_t): New type.
2019         (multiply, divide, convert_to_decimal, decode_long_double,
2020         scale10_round_long_double, scale10_round_decimal_long_double,
2021         floorlog10l): New functions.
2022         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
2023         for the %f, %F, %e, %E, %g, %G directives.
2024         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
2025         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2026         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
2027         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
2028         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2029         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2030         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2031         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2032         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2033         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2034         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2035         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
2036         * modules/snprintf-posix (Depends-on): Likewise.
2037         * modules/sprintf-posix (Depends-on): Likewise.
2038         * modules/vasnprintf-posix (Depends-on): Likewise.
2039         * modules/vasprintf-posix (Depends-on): Likewise.
2040         * modules/vfprintf-posix (Depends-on): Likewise.
2041         * modules/vsnprintf-posix (Depends-on): Likewise.
2042         * modules/vsprintf-posix (Depends-on): Likewise.
2043         * modules/vasnprintf (Files): Add lib/float+.h.
2044         * doc/functions/fprintf.texi: Update.
2045         * doc/functions/printf.texi: Update.
2046         * doc/functions/snprintf.texi: Update.
2047         * doc/functions/sprintf.texi: Update.
2048         * doc/functions/vfprintf.texi: Update.
2049         * doc/functions/vprintf.texi: Update.
2050         * doc/functions/vsnprintf.texi: Update.
2051         * doc/functions/vsprintf.texi: Update.
2052
2053 2007-05-18  Bruno Haible  <bruno@clisp.org>
2054
2055         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
2056
2057 2007-05-18  Bruno Haible  <bruno@clisp.org>
2058
2059         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
2060         for printing 64-bit integers. Needed for mingw.
2061
2062 2007-05-18  Bruno Haible  <bruno@clisp.org>
2063
2064         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
2065         gl_FUNC_FREXPL_WORKS.
2066         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
2067
2068 2007-05-18  Bruno Haible  <bruno@clisp.org>
2069
2070         * modules/frexpl-nolibm-tests: New file.
2071
2072         * modules/frexpl-nolibm: New file.
2073         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
2074
2075 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
2076
2077         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
2078         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2079         GCC 4.2, which otherwise issues a lot of warnings.
2080         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
2081         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
2082         Likewise.
2083         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
2084         * modules/iconv_open (iconv.h): Likewise.
2085         * modules/locale (locale.h): Likewise.
2086         * modules/netinet_in (netinet/in.h): Likewise.
2087         * modules/sys_select (sys_select.h): Likewise.
2088         * modules/sys_socket (sys/socket.h): Likewise.
2089         * modules/sys_stat (sys/stat.h): Likewise.
2090         * modules/sysexits (sysexits.h): Likewise.
2091         * modules/unistd (unistd.h): Likewise.
2092
2093 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2094
2095         * modules/closein-tests (Makefile.am): Distribute
2096         `test-closein.sh'.
2097
2098 2007-05-17  Bruno Haible  <bruno@clisp.org>
2099
2100         * tests/test-printf-posix.output: Renamed from
2101         tests/test-fprintf-posix.out.
2102         * modules/fprintf-posix-tests: Update.
2103         * modules/printf-posix-tests: Update.
2104         * modules/vfprintf-posix-tests: Update.
2105         * modules/vprintf-posix-tests: Update.
2106         * tests/test-fprintf-posix.sh: Update.
2107         * tests/test-printf-posix.sh: Update.
2108         * tests/test-vfprintf-posix.sh: Update.
2109         * tests/test-vprintf-posix.sh: Update.
2110         Reported by Ralf Wildenhues.
2111
2112 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
2113
2114         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
2115         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2116         GCC 4.2, which otherwise issues a lot of warnings.
2117         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
2118         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
2119         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
2120         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
2121         it should no longer be needed.
2122         * lib/string_.h: Likewise.
2123         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
2124         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
2125         * modules/inttypes (inttypes.h): Likewise.
2126         * modules/math (math.h): Likewise.
2127         * modules/search (search.h): Likewise.
2128         * modules/signal (signal.h): Likewise.
2129         * modules/stdint (stdint.h): Likewise.
2130         * modules/stdio (stdio.h): Likewise.
2131         * modules/stdlib (stdlib.h): Likewise.
2132         * modules/string (string.h): Likewise.
2133         * modules/sys_time (sys/time.h): Likewise.
2134         * modules/time (time.h): Likewise.
2135         * modules/wchar (wchar.h): Likewise.
2136         * modules/wctype (wtype.h): Likewise.
2137
2138 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
2139
2140         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
2141
2142 2007-05-13  Bruno Haible  <bruno@clisp.org>
2143
2144         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
2145         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
2146         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
2147         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2148         (gl_PREREQ_STRTOK_R): Don't require it here.
2149
2150 2007-05-13  Bruno Haible  <bruno@clisp.org>
2151
2152         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
2153         when used in C++ mode.
2154
2155 2007-05-12  Bruno Haible  <bruno@clisp.org>
2156
2157         * lib/linebuffer.h: Tweak doc.
2158         * lib/linebuffer.c: Likewise.
2159
2160 2007-05-12  James Youngman  <jay@gnu.org>
2161
2162         * lib/linebuffer.c (readlinebuffer_delim): New function,
2163         like readlinebuffer, but use a caller-specified delimiter.
2164         (readlinebuffer): Just call readlinebuffer_delim with '\n'
2165         as the delimiter.
2166         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
2167
2168 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
2169
2170         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
2171         * modules/openat (Files): Remove openat-die.c.
2172         (Depends-on): Add openat-die.
2173         * modules/openat-die: New module.
2174
2175 2007-05-06  Bruno Haible  <bruno@clisp.org>
2176
2177         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
2178         Update with info about Cygwin.
2179         * doc/functions/fprintf.texi: Update.
2180         * doc/functions/printf.texi: Update.
2181         * doc/functions/snprintf.texi: Update.
2182         * doc/functions/sprintf.texi: Update.
2183         * doc/functions/vfprintf.texi: Update.
2184         * doc/functions/vprintf.texi: Update.
2185         * doc/functions/vsnprintf.texi: Update.
2186         * doc/functions/vsprintf.texi: Update.
2187         Reported by Eric Blake.
2188
2189 2007-05-06  Bruno Haible  <bruno@clisp.org>
2190
2191         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
2192         padding ourselves for the floating-point directives.
2193         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
2194         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
2195         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2196         gl_PRINTF_FLAG_ZERO and test its result. Invoke
2197         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
2198         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2199         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2200         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2201         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2202         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2203         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2204         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2205         * tests/test-snprintf-posix.h (test_function): Also check the width
2206         and some flags in the %f directive.
2207         * tests/test-sprintf-posix.h (test_function): Likewise.
2208         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2209         * tests/test-vasprintf-posix.c (test_function): Likewise.
2210         * doc/functions/fprintf.texi: Update.
2211         * doc/functions/printf.texi: Update.
2212         * doc/functions/snprintf.texi: Update.
2213         * doc/functions/sprintf.texi: Update.
2214         * doc/functions/vfprintf.texi: Update.
2215         * doc/functions/vprintf.texi: Update.
2216         * doc/functions/vsnprintf.texi: Update.
2217         * doc/functions/vsprintf.texi: Update.
2218
2219 2007-05-06  Bruno Haible  <bruno@clisp.org>
2220
2221         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
2222         pass the ' flag character to sprintf or snprintf.
2223         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
2224         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
2225         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2226         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
2227         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
2228         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2229         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2230         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2231         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2232         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2233         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2234         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2235         * tests/test-snprintf-posix.h (test_function): Also check the grouping
2236         flag.
2237         * tests/test-sprintf-posix.h (test_function): Likewise.
2238         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2239         * tests/test-vasprintf-posix.c (test_function): Likewise.
2240         * doc/functions/fprintf.texi: Update.
2241         * doc/functions/printf.texi: Update.
2242         * doc/functions/snprintf.texi: Update.
2243         * doc/functions/sprintf.texi: Update.
2244         * doc/functions/vfprintf.texi: Update.
2245         * doc/functions/vprintf.texi: Update.
2246         * doc/functions/vsnprintf.texi: Update.
2247         * doc/functions/vsprintf.texi: Update.
2248
2249 2007-05-01  Bruno Haible  <bruno@clisp.org>
2250
2251         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
2252
2253 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
2254
2255         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
2256         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
2257
2258 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
2259
2260         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
2261         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
2262         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
2263
2264 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
2265
2266         * lib/argp-help.c (struct hol_entry): New member `ord'.
2267         (HOL_ENTRY_PTRCMP): Use ord for comparison
2268         (hol_sort): Initialize ord.
2269
2270 2007-05-01  Bruno Haible  <bruno@clisp.org>
2271
2272         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
2273         Reported by Eric Blake.
2274         * doc/gnulib.texi (Function Substitutes): Update.
2275
2276 2007-05-01  Bruno Haible  <bruno@clisp.org>
2277
2278         * doc/functions.texi: Remove file, now redundant through
2279         doc/functions/*.texi.
2280
2281 2007-05-01  Bruno Haible  <bruno@clisp.org>
2282
2283         * modules/argp (Depends-on): Add sleep.
2284
2285 2007-05-01  Bruno Haible  <bruno@clisp.org>
2286
2287         * modules/sleep-tests: New file.
2288         * tests/test-sleep.c: New file.
2289
2290         * modules/sleep: New file.
2291         * lib/sleep.c: New file.
2292         * m4/sleep.m4: New file.
2293         * lib/unistd_.h (sleep): New declaration.
2294         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
2295         HAVE_SLEEP.
2296         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
2297         * doc/functions/sleep.texi: Document the sleep module.
2298
2299 2007-05-01  Bruno Haible  <bruno@clisp.org>
2300
2301         * lib/sigprocmask.h: Remove file.
2302         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
2303         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
2304         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
2305         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
2306         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
2307         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
2308         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
2309         HAVE_SIGSET_T as a shell variable.
2310         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
2311         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
2312         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
2313         (Depends-on): Add signal. Remove verify.
2314         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
2315         (Include): Mention <signal.h> instead of sigprocmask.h.
2316         * NEWS: Mention the change.
2317         * lib/fatal-signal.c: Don't include sigprocmask.h.
2318
2319 2007-05-01  Bruno Haible  <bruno@clisp.org>
2320
2321         * modules/signal: New file.
2322         * lib/signal_.h: New file.
2323         * m4/signal_h.m4: New file.
2324
2325 2007-05-01  Bruno Haible  <bruno@clisp.org>
2326
2327         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
2328         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
2329         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
2330         HAVE_WCTYPE_CTMP_BUG into wctype.h.
2331
2332 2007-05-01  Bruno Haible  <bruno@clisp.org>
2333
2334         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
2335         configure time.
2336         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
2337         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
2338         * modules/sys_stat (Makefile.am): Substitute their values into
2339         sys/stat.h.
2340
2341 2007-05-01  Bruno Haible  <bruno@clisp.org>
2342
2343         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
2344         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
2345         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
2346
2347 2007-05-01  Bruno Haible  <bruno@clisp.org>
2348
2349         * doc/header/assert.texi: Undo last change: don't mention the gnulib
2350         'assert' module here.
2351
2352 2007-05-01  Bruno Haible  <bruno@clisp.org>
2353
2354         * doc/functions/*.texi: New files.
2355         * doc/functions/google-ranking.txt: New file.
2356         * doc/gnulib.texi (Function Substitutes): New chapter.
2357         (ctime, inet_ntoa): Remove sections.
2358         * doc/ctime.texi: Remove file.
2359         * doc/inet_ntoa.texi: Remove file.
2360         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
2361         dependencies.
2362         (%.info): New rule, specifying a --reference-limit.
2363
2364 2007-05-01  Bruno Haible  <bruno@clisp.org>
2365
2366         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
2367
2368 2007-05-01  Bruno Haible  <bruno@clisp.org>
2369
2370         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
2371         the portability of 'mkdir' to mingw systems.
2372
2373 2007-05-01  Bruno Haible  <bruno@clisp.org>
2374
2375         * doc/headers/google-ranking.txt: New file.
2376
2377 2007-04-30  Eric Blake  <ebb9@byu.net>
2378
2379         Prefer fseeko to fseek.
2380         * modules/getpass (Depends-on): Add fseeko.
2381         * lib/getpass.c (getpass): Use fseeko, not fseek.
2382
2383 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
2384
2385         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
2386         assumes the sorting is stable, while most qsort implementations
2387         are not.  Use argument addresses to ensure they never compare as
2388         equal.
2389
2390         * tests/test-argp-2.sh (usage-indent test): Fix output
2391         (func_compare): Restore diff options
2392         * tests/test-argp.c: Restore #include "progname.h"
2393
2394 2007-04-29  Bruno Haible  <bruno@clisp.org>
2395
2396         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
2397         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2398         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
2399         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2400         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
2401         (configure.ac): Define CHECK_SNPRINTF_POSIX.
2402         (TESTS, check_PROGRAMS): Add test-snprintf.
2403         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2404         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2405         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2406         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2407         assertions that fail on HP-UX, OSF/1, or IRIX.
2408         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2409
2410 2007-04-29  Bruno Haible  <bruno@clisp.org>
2411
2412         * MODULES.html.sh (posix_functions): Remove 'contents'.
2413
2414 2007-04-29  Karl Berry  <karl@gnu.org>
2415
2416         * config/srclist.txt (gendocs_template_min): new entry.
2417
2418 2007-04-29  Bruno Haible  <bruno@clisp.org>
2419
2420         Work around fpurge bug on BSD systems.
2421         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2422         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2423         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2424         fpurge to rpl_fpurge if the system already has this function.
2425         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2426         the case where the system already has this function. Correct invariants
2427         on BSD systems.
2428         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2429         BSD systems.
2430
2431 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2432
2433         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2434         proposed by Sven Verdoolaege.
2435
2436         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2437         options.
2438         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2439         (usage and help tests): Update
2440
2441 2007-04-29  Bruno Haible  <bruno@clisp.org>
2442
2443         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2444         Print more information in case of failure. Disable a test on BeOS.
2445
2446 2007-04-29  Bruno Haible  <bruno@clisp.org>
2447
2448         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2449         This helps debugging on systems on which no gdb is available.
2450
2451 2007-04-29  Bruno Haible  <bruno@clisp.org>
2452
2453         * lib/freading.h: Improve comments.
2454         * lib/fwriting.h: Likewise.
2455         * tests/test-freading.c (main): Don't check freading immediately after
2456         repositioning. Needed for glibc.
2457
2458 2007-04-29  Bruno Haible  <bruno@clisp.org>
2459
2460         * lib/freading.c (freading): Trivial simplification.
2461
2462 2007-04-28  Bruno Haible  <bruno@clisp.org>
2463
2464         * tests/test-fwriting.c (main): Also test the interaction between
2465         fflush and fwriting.
2466         * modules/fwriting-tests (Depends-on): Add fflush.
2467
2468         * tests/test-freading.c (main): Also test the interaction between
2469         fflush and freading.
2470         * modules/freading-tests (Depends-on): Add fflush.
2471
2472 2007-04-28  Bruno Haible  <bruno@clisp.org>
2473
2474         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2475         fseeko and ftello.
2476         Suggested by Eric Blake.
2477
2478 2007-04-28  Jim Meyering  <jim@meyering.net>
2479
2480         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2481         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2482         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2483
2484 2007-04-27  Eric Blake  <ebb9@byu.net>
2485
2486         * doc/headers/assert.texi (assert.h): Document assert module use.
2487
2488 2007-04-27  Bruno Haible  <bruno@clisp.org>
2489
2490         * doc/headers/*.texi: New files.
2491         * doc/gnulib.texi (Header File Substitutes): New chapter.
2492         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2493         dependencies.
2494         (standards.info ,standards.html, standards.dvi): Update dependencies.
2495         (mostlyclean, clean): New targets.
2496
2497 2007-04-27  Bruno Haible  <bruno@clisp.org>
2498
2499         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2500         * modules/sysexits (Files, Makefile.am): Update.
2501
2502         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2503         * modules/sys_socket (Files, Makefile.am): Update.
2504
2505         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2506         * modules/sys_stat (Files, Makefile.am): Update.
2507
2508 2007-04-27  Eric Blake  <ebb9@byu.net>
2509
2510         * lib/freading.h: Improve comments.
2511         * lib/fwriting.h: Likewise.
2512         * lib/fflush.c: Likewise.
2513
2514         Fix closein for mingw.
2515         * modules/closein-tests: Add tests for closein.
2516         * tests/test-closein.c: New file.
2517         * tests/test-closein.sh: Likewise.
2518         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2519         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2520
2521 2007-04-27  Bruno Haible  <bruno@clisp.org>
2522
2523         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2524         version is < 6.
2525         * lib/math_.h [__DECC]: Likewise.
2526         * lib/stdio_.h [__DECC]: Likewise.
2527         * lib/stdlib_.h [__DECC]: Likewise.
2528         * lib/string_.h [__DECC]: Likewise.
2529         * lib/time_.h [__DECC]: Likewise.
2530         * lib/wchar_.h [__DECC]: Likewise.
2531         * lib/wctype_.h [__DECC]: Likewise.
2532
2533 2007-04-27  Bruno Haible  <bruno@clisp.org>
2534
2535         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2536
2537 2007-04-27  Bruno Haible  <bruno@clisp.org>
2538
2539         * lib/fflush.c: Add comments.
2540         * modules/fpurge-tests (Depends-on): Add fflush.
2541         * modules/freadable-tests (Depends-on): Likewise.
2542         * modules/fwritable-tests (Depends-on): Likewise.
2543
2544 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2545
2546         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2547         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2548         Report by Bruno Haible <bruno@clisp.org>.
2549
2550 2007-04-26  Eric Blake  <ebb9@byu.net>
2551
2552         Fix fflush on mingw.
2553         * modules/fflush (Depends-on): Add freading.
2554         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2555         but unread data.
2556
2557 2007-04-26  Eric Blake  <ebb9@byu.net>
2558         and Bruno Haible  <bruno@clisp.org>
2559
2560         Implement freading and fwriting.
2561         * lib/freading.c: New file.
2562         * lib/freading.h: Likewise.
2563         * m4/freading.m4: Likewise.
2564         * modules/freading: Likewise.
2565         * modules/freading-tests: Likewise.
2566         * tests/test-freading.c: Likewise.
2567         * lib/fwriting.c: New file.
2568         * lib/fwriting.h: Likewise.
2569         * m4/fwriting.m4: Likewise.
2570         * modules/fwriting: Likewise.
2571         * modules/fwriting-tests: Likewise.
2572         * tests/test-fwriting.c: Likewise.
2573         * MODULES.html.sh (File stream based Input/Output): Mention them.
2574
2575 2007-04-26  Bruno Haible  <bruno@clisp.org>
2576
2577         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2578         'long' when we assume it.
2579         Suggested by Eric Blake.
2580
2581 2007-04-26  Bruno Haible  <bruno@clisp.org>
2582
2583         Ensure fseeko, ftello are declared on glibc systems.
2584         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
2585         * modules/fseeko (configure.ac-early): Likewise.
2586         * modules/ftello (configure.ac-early): Likewise.
2587         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
2588         AC_FUNC_FSEEKO for this.
2589         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
2590         (gl_CHECK_FSEEKO): Remove macro.
2591
2592 2007-04-26  Bruno Haible  <bruno@clisp.org>
2593
2594         * tests/test-fflush.c (main): Also check the ftell result after
2595         fflush and fseek/fseeko.
2596         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
2597         file descriptor position cache in the stream.
2598         * lib/fseeko.c (rpl_fseeko): Likewise.
2599
2600 2007-04-26  Bruno Haible  <bruno@clisp.org>
2601
2602         * modules/fflush-tests (Depends-on): Add fseeko.
2603
2604 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
2605             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2606
2607         * lib/argz_.h: ensure error_t definition is obtained in same
2608         mechanism system argz.h would have.
2609         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
2610         argz facilities are known bad.  Err on the side of caution if
2611         cross-compiling.
2612
2613 2007-04-25  Eric Blake  <ebb9@byu.net>
2614
2615         * lib/fpurge.c (includes): Use stdlib.h for free.
2616         * tests/test-fflush.c (main): Also test fflush-fseeko.
2617
2618 2007-04-25  Bruno Haible  <bruno@clisp.org>
2619
2620         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
2621         * lib/fseeko.c: New file.
2622         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
2623         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
2624         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
2625         gl_FUNC_FSEEKO.
2626         (gl_FUNC_FSEEKO): Invoke it.
2627         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
2628         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
2629         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
2630
2631 2007-04-25  Bruno Haible  <bruno@clisp.org>
2632
2633         * modules/fflush (Depends-on): Add ftello.
2634
2635 2007-04-25  Bruno Haible  <bruno@clisp.org>
2636
2637         * modules/ftello-tests: New file.
2638         * tests/test-ftello.c: New file.
2639
2640         * modules/ftello: New file.
2641         * m4/ftello.m4: New file.
2642         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
2643         HAVE_FTELLO.
2644         * lib/stdio_.h (ftello): New declaration.
2645         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
2646         HAVE_FTELLO.
2647
2648 2007-04-25  Bruno Haible  <bruno@clisp.org>
2649
2650         * modules/fseeko-tests: New file.
2651         * tests/test-fseeko.c: New file.
2652
2653         * modules/fseeko: New file.
2654         * m4/fseeko.m4: New file.
2655         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
2656         HAVE_FSEEKO.
2657         * lib/stdio_.h (fseeko): New declaration.
2658         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
2659         HAVE_FSEEKO.
2660
2661 2007-04-25  Bruno Haible  <bruno@clisp.org>
2662
2663         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
2664
2665 2007-04-25  Bruno Haible  <bruno@clisp.org>
2666
2667         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
2668         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
2669         * tests/test-unistd.c: Likewise.
2670         * tests/test-fcntl.c: Likewise.
2671
2672 2007-04-23  Eric Blake  <ebb9@byu.net>
2673
2674         * lib/fflush.c: Fix missing include.
2675         Reported by Bruno Haible.
2676
2677 2007-04-23  Bruno Haible  <bruno@clisp.org>
2678
2679         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
2680         Reported by Eric Blake.
2681
2682 2007-04-23  Bruno Haible  <bruno@clisp.org>
2683
2684         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
2685
2686 2007-04-23  Bruno Haible  <bruno@clisp.org>
2687
2688         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
2689
2690 2007-04-23  Bruno Haible  <bruno@clisp.org>
2691
2692         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
2693         Needed on HP-UX 11.
2694
2695 2007-04-16  Eric Blake  <ebb9@byu.net>
2696
2697         Make fflush rely on fpurge.
2698         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
2699         open coding all variants.
2700         * modules/fflush (Depends-on): Add fpurge and unistd.
2701         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
2702         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
2703
2704         Fix --with-tests compilation on cygwin.
2705         * modules/argmatch-tests (Makefile.am): List gnulib library first
2706         in LDADD.
2707         * modules/argp-tests (Makefile.am): Likewise.
2708         * modules/array-list-tests (Makefile.am): Likewise.
2709         * modules/array-oset-tests (Makefile.am): Likewise.
2710         * modules/avltree-list-tests (Makefile.am): Likewise.
2711         * modules/avltree-oset-tests (Makefile.am): Likewise.
2712         * modules/avltreehash-list-tests (Makefile.am): Likewise.
2713         * modules/carray-list-tests (Makefile.am): Likewise.
2714         * modules/dirname-tests (Makefile.am): Likewise.
2715         * modules/frexp-tests (Makefile.am): Likewise.
2716         * modules/isnanl-tests (Makefile.am): Likewise.
2717         * modules/linked-list-tests (Makefile.am): Likewise.
2718         * modules/linkedhash-list-tests (Makefile.am): Likewise.
2719         * modules/lock-tests (Makefile.am): Likewise.
2720         * modules/rbtree-list-tests (Makefile.am): Likewise.
2721         * modules/rbtree-oset-tests (Makefile.am): Likewise.
2722         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
2723         * modules/tls-tests (Makefile.am): Likewise.
2724         * modules/tsearch-tests (Makefile.am): Likewise.
2725         * modules/xvasprintf-tests (Makefile.am): Likewise.
2726
2727         Fix fpurge for cygwin.
2728         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
2729         value.
2730         * modules/fpurge-tests (Depends-on): Clean up trash.
2731
2732 2007-04-16  Simon Josefsson  <simon@josefsson.org>
2733
2734         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
2735
2736         * m4/autobuild.m4: Re-indent.
2737
2738 2007-04-13  Bruno Haible  <bruno@clisp.org>
2739
2740         * modules/fpurge-tests: New file.
2741         * tests/test-fpurge.c: New file.
2742
2743         * modules/fpurge: New file.
2744         * lib/fpurge.h: New file.
2745         * lib/fpurge.c: New file.
2746         * m4/fpurge.m4: New file.
2747
2748 2007-04-13  Bruno Haible  <bruno@clisp.org>
2749
2750         * modules/fbufmode-tests: New file.
2751         * tests/test-fbufmode.c: New file.
2752
2753         * modules/fbufmode: New file.
2754         * lib/fbufmode.h: New file.
2755         * lib/fbufmode.c: New file.
2756         * m4/fbufmode.m4: New file.
2757
2758 2007-04-13  Bruno Haible  <bruno@clisp.org>
2759
2760         * modules/fwritable-tests: New file.
2761         * tests/test-fwritable.c: New file.
2762
2763         * modules/fwritable: New file.
2764         * lib/fwritable.h: New file.
2765         * lib/fwritable.c: New file.
2766         * m4/fwritable.m4: New file.
2767
2768 2007-04-13  Bruno Haible  <bruno@clisp.org>
2769
2770         * modules/freadable-tests: New file.
2771         * tests/test-freadable.c: New file.
2772
2773         * modules/freadable: New file.
2774         * lib/freadable.h: New file.
2775         * lib/freadable.c: New file.
2776         * m4/freadable.m4: New file.
2777
2778 2007-04-13  Bruno Haible  <bruno@clisp.org>
2779
2780         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
2781         MOSTLYCLEANFILES.
2782
2783 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
2784
2785         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
2786         gzip bootstrap.conf to avoid dragging in i18n machinery.
2787         (gnulib_tool_option): Use it.
2788
2789 2007-04-13  Bruno Haible  <bruno@clisp.org>
2790
2791         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
2792         %F directives.
2793         * tests/test-vasprintf-posix.c (test_function): Likewise.
2794         * tests/test-snprintf-posix.h (test_function): Likewise.
2795         * tests/test-sprintf-posix.h (test_function): Likewise.
2796         * tests/test-fprintf-posix.h (test_function): Likewise.
2797         * tests/test-printf-posix.h (test_function): Likewise.
2798         * tests/test-fprintf-posix.out: Likewise.
2799
2800 2007-04-13  Bruno Haible  <bruno@clisp.org>
2801
2802         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
2803         * modules/tls-tests (configure.ac): Likewise.
2804         Reported by Arto C. Nirkko <anirkko@insel.ch>.
2805
2806 2007-04-13  Bruno Haible  <bruno@clisp.org>
2807
2808         * lib/tls.c (glthread_tls_get): Fix return type.
2809         Patch by Arto C. Nirkko <anirkko@insel.ch>.
2810
2811 2007-04-12  Eric Blake  <ebb9@byu.net>
2812
2813         * modules/gettime (Depends-on): Remove gettime.
2814         Reported by Dmitry V. Levin.
2815
2816 2007-04-12  Bruno Haible  <bruno@clisp.org>
2817
2818         * modules/fflush (Include): Mention <stdio.h>.
2819         * modules/strtoimax (Include): Mention <inttypes.h>.
2820         * modules/strtoumax (Include): Likewise.
2821
2822 2007-04-12  Eric Blake  <ebb9@byu.net>
2823
2824         * .cvsignore: New file.
2825         * .gitignore: Likewise.
2826
2827 2007-04-12  Bruno Haible  <bruno@clisp.org>
2828
2829         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
2830         not before, since $(LDADD) often contains libgnu.a.
2831         * modules/striconv-tests (test_striconv_LDADD): Likewise.
2832         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
2833         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
2834         Needed on Cygwin.
2835
2836 2007-04-12  Eric Blake  <ebb9@byu.net>
2837
2838         Work around glibc's failure to flush stdin on fclose.
2839         * lib/closein.c (close_stdin): Flush stdin before closing.
2840
2841         Work around glibc's failure to reset seekable stdin on exit.
2842         * modules/closein: New module.
2843         * lib/closein.c: New file.
2844         * lib/closein.h: Likewise.
2845         * m4/closein.m4: Likewise.
2846         * MODULES.html.sh (File stream based Input/Output): Document it.
2847
2848 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2849
2850         * gnulib-tool: Rename generated 'autobuild' script to
2851         'do-autobuild' in --create-megatestdir output.
2852
2853         * doc/gnulib.texi (Build robot for gnulib): Fix.
2854
2855 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2856
2857         * modules/sysexits (Depends-on): Add absolute-header.
2858
2859 2007-04-12  Eric Blake  <ebb9@byu.net>
2860
2861         No need to preserve errno on success.
2862         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
2863         Reported by Bruno Haible.
2864
2865 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2866
2867         * MODULES.html.sh (Support for maintaining and releasing
2868         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
2869
2870 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2871
2872         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
2873
2874 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2875
2876         * modules/autobuild: New module.
2877
2878         * m4/autobuild.m4: New file.
2879
2880 2007-04-11  Bruno Haible  <bruno@clisp.org>
2881
2882         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
2883         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
2884         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
2885         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
2886         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2887         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2888         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2889         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2890         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2891         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2892         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
2893         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2894         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2895         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
2896         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2897         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2898         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
2899         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2900         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2901         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
2902         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2903         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2904         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
2905         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2906         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2907         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
2908         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2909         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2910         Reported by Eric Blake.
2911
2912 2007-04-11  Bruno Haible  <bruno@clisp.org>
2913
2914         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
2915
2916 2007-04-10  Bruno Haible  <bruno@clisp.org>
2917
2918         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
2919         for NaN and Infinity. Needed on FreeBSD 6.1.
2920         * tests/test-vasnprintf-posix.c (test_function): Undo last change
2921         regarding results for "%010a" of Infinity and NaN.
2922         * tests/test-vasprintf-posix.c (test_function): Likewise.
2923         * tests/test-snprintf-posix.h (test_function): Likewise.
2924         * tests/test-sprintf-posix.h (test_function): Likewise.
2925         * tests/test-fprintf-posix.h (test_function): Likewise.
2926         * tests/test-printf-posix.h (test_function): Likewise.
2927         * tests/test-fprintf-posix.out: Likewise.
2928
2929 2007-04-10  Bruno Haible  <bruno@clisp.org>
2930
2931         * modules/locale-tests: New file.
2932         * tests/test-locale.c: New file.
2933
2934         * modules/locale: New file.
2935         * lib/locale_.h: New file.
2936         * m4/locale_h.m4: New file.
2937
2938 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
2939             Bruno Haible  <bruno@clisp.org>
2940
2941         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
2942         be determined, test for availability of the copysignf, copysign,
2943         copysignl functions.
2944         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
2945         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
2946         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
2947
2948 2007-04-09  Eric Blake  <ebb9@byu.net>
2949
2950         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
2951         * modules/stdio (Makefile.am): Support fflush.
2952         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
2953         * modules/fflush: New file.
2954         * lib/fflush.c: Likewise.
2955         * m4/fflush.m4: Likewise.
2956         * modules/fflush-tests: New test.
2957         * tests/test-fflush.c: Likewise.
2958         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
2959
2960 2007-04-06  Bruno Haible  <bruno@clisp.org>
2961
2962         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
2963         (VASNPRINTF): Use signbit for faster determination whether to print a
2964         minus sign.
2965         * modules/vasnprintf (Files): Remove lib/float+.h.
2966         * modules/fprintf-posix (Depends-on): Add signbit.
2967         * modules/snprintf-posix (Depends-on): Likewise.
2968         * modules/sprintf-posix (Depends-on): Likewise.
2969         * modules/vasnprintf-posix (Depends-on): Likewise.
2970         * modules/vasprintf-posix (Depends-on): Likewise.
2971         * modules/vfprintf-posix (Depends-on): Likewise.
2972         * modules/vsnprintf-posix (Depends-on): Likewise.
2973         * modules/vsprintf-posix (Depends-on): Likewise.
2974
2975 2007-04-06  Bruno Haible  <bruno@clisp.org>
2976
2977         * tests/test-frexp.c (main): Test also the sign bit of zero results.
2978         * tests/test-frexpl.c (main): Likewise.
2979         * tests/test-ldexpl.c (main): Likewise.
2980         * modules/frexp-tests (Depends-on): Add signbit.
2981         * modules/frexpl-tests (Depdends-on): Likewise.
2982         * modules/ldexpl-tests (Depdends-on): Likewise.
2983
2984 2007-04-06  Bruno Haible  <bruno@clisp.org>
2985
2986         * modules/signbit-tests: New file.
2987         * tests/test-signbit.c: New file.
2988
2989         * modules/signbit: New file.
2990         * lib/signbitf.c: New file.
2991         * lib/signbitd.c: New file.
2992         * lib/signbitl.c: New file.
2993         * m4/signbit.m4: New file.
2994         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
2995         (signbit): New macro.
2996         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
2997         REPLACE_SIGNBIT.
2998         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
2999         REPLACE_FREXPL into math.h.
3000
3001 2007-04-06  Bruno Haible  <bruno@clisp.org>
3002
3003         * modules/isnanf-nolibm-tests: New file.
3004         * tests/test-isnanf.c: New file.
3005
3006         * modules/isnanf-nolibm: New file.
3007         * lib/isnanf.h: New file.
3008         * lib/isnanf.c: New file.
3009         * lib/isnan.c: Consider the USE_FLOAT macro.
3010         * m4/isnanf.m4: New file.
3011
3012 2007-04-06  Bruno Haible  <bruno@clisp.org>
3013
3014         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
3015         (Link): New section.
3016
3017         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
3018
3019 2007-04-06  Bruno Haible  <bruno@clisp.org>
3020
3021         Assume the 'long double' type.
3022         * m4/longdouble.m4: Remove file.
3023         * config/srclist.txt: Don't mention longdouble.m4.
3024         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
3025         * lib/float+.h: Likewise.
3026         * lib/frexp.c: Likewise.
3027         * lib/printf-args.h: Likewise.
3028         * lib/printf-args.c: Likewise.
3029         * lib/printf-frexp.c: Likewise.
3030         * lib/printf-parse.c: Likewise.
3031         * lib/vasnprintf.c: Likewise.
3032         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
3033         * m4/intl.m4: Likewise.
3034         * m4/isnanl.m4: Likewise.
3035         * m4/printf.m4: Likewise.
3036         * m4/printf-frexpl.m4: Likewise.
3037         * m4/vasnprintf.m4: Likewise.
3038         * modules/allocsa (Files): Remove m4/longdouble.m4.
3039         * modules/gettext (Files): Likewise.
3040         * modules/relocatable-prog-wrapper (Files): Likewise.
3041         * modules/vasnprintf (Files): Likewise.
3042         * modules/isnanl (Files): Likewise.
3043         (Include): Simplify.
3044         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
3045         (Include): Simplify.
3046         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
3047         (Include): Simplify.
3048         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
3049         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3050         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
3051         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3052         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3053         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3054         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
3055         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3056         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3057         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3058         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
3059         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3060         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
3061         * tests/test-isnanl.c: Likewise.
3062         * tests/test-snprintf-posix.h: Likewise.
3063         * tests/test-sprintf-posix.h: Likewise.
3064         * tests/test-vasnprintf-posix.c: Likewise.
3065         * tests/test-vasnprintf-posix2.c: Likewise.
3066         * tests/test-vasprintf-posix.c: Likewise.
3067
3068 2007-04-06  Bruno Haible  <bruno@clisp.org>
3069
3070         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
3071         * lib/math_.h [__DECC]: Include the overridden include file through
3072         #include_next, outside the double-inclusion guard.
3073         * lib/stdio_.h [__DECC]: Likewise.
3074         * lib/stdlib_.h [__DECC]: Likewise.
3075         * lib/string_.h [__DECC]: Likewise.
3076         * lib/time_.h [__DECC]: Likewise.
3077         * lib/wchar_.h [__DECC]: Likewise.
3078         * lib/wctype_.h [__DECC]: Likewise.
3079         * lib/inttypes_.h [__DECC]: Likewise.
3080         Reported by Albert Chin <china@thewrittenword.com> in
3081         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
3082
3083 2007-04-04  Eric Blake  <ebb9@byu.net>
3084
3085         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
3086         1.5.x.
3087
3088 2007-04-04  Bruno Haible  <bruno@clisp.org>
3089
3090         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
3091         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
3092
3093 2007-04-04  Bruno Haible  <bruno@clisp.org>
3094
3095         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
3096         results for "%010a" of Infinity and NaN.
3097         * tests/test-vasprintf-posix.c (test_function): Likewise.
3098         * tests/test-snprintf-posix.h (test_function): Likewise.
3099         * tests/test-sprintf-posix.h (test_function): Likewise.
3100         * tests/test-fprintf-posix.h (test_function): Remove these tests.
3101         * tests/test-printf-posix.h (test_function): Likewise.
3102         * tests/test-fprintf-posix.out: Update.
3103         Needed for FreeBSD 6.1.
3104
3105 2007-04-04  Bruno Haible  <bruno@clisp.org>
3106
3107         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
3108         directly used by the gnulib modules nor by gnulib-tool.
3109
3110 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
3111
3112         * DEPENDENCIES: Give overall description of version dependency
3113         desirability.  Use more-typical names for apps.
3114         Add shell, coreutils, diffutils, grep, tar, gzip.
3115
3116 2007-04-04  Simon Josefsson  <simon@josefsson.org>
3117
3118         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
3119
3120 2007-04-04  Karl Berry  <karl@gnu.org>
3121
3122         * MODULES.html.sh (func_module): missing '.
3123
3124 2007-04-03  Bruno Haible  <bruno@clisp.org>
3125
3126         * modules/argmatch-tests (Makefile.am): New variable
3127         test_argmatch_LDADD.
3128         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
3129         * modules/array-list-tests (Makefile.am): New variable
3130         test_array_list_LDADD.
3131         * modules/array-oset-tests (Makefile.am): New variable
3132         test_array_oset_LDADD.
3133         * modules/avltree-list-tests (Makefile.am): New variable
3134         test_avltree_list_LDADD.
3135         * modules/avltree-oset-tests (Makefile.am): New variable
3136         test_avltree_oset_LDADD.
3137         * modules/avltreehash-list-tests (Makefile.am): New variable
3138         test_avltreehash_list_LDADD.
3139         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
3140         test_canonicalize_lgpl_LDADD.
3141         * modules/carray-list-tests (Makefile.am): New variable
3142         test_carray_list_LDADD.
3143         * modules/dirname-tests (Makefile.am): New variable
3144         test_dirname_LDADD.
3145         * modules/linked-list-tests (Makefile.am): New variable
3146         test_linked_list_LDADD.
3147         * modules/linkedhash-list-tests (Makefile.am): New variable
3148         test_linkedhash_list_LDADD.
3149         * modules/rbtree-list-tests (Makefile.am): New variable
3150         test_rbtree_list_LDADD.
3151         * modules/rbtree-oset-tests (Makefile.am): New variable
3152         test_rbtree_oset_LDADD.
3153         * modules/rbtreehash-list-tests (Makefile.am): New variable
3154         test_rbtreehash_list_LDADD.
3155         * modules/xvasprintf-tests (Makefile.am): New variable
3156         test_xvasprintf_LDADD.
3157         Reported by Eric Blake.
3158
3159 2007-04-03  Eric Blake  <ebb9@byu.net>
3160
3161         * DEPENDENCIES: Weaken m4 requirements.
3162
3163 2007-04-03  Bruno Haible  <bruno@clisp.org>
3164
3165         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
3166         * modules/isnanl-tests (configure.ac): Likewise.
3167
3168 2007-04-03  Ben Pfaff  <blp@gnu.org>
3169
3170         * modules/iconv_open: Add $(srcdir)/ to source directory
3171         references in Makefile fragments that call gperf, to fix VPATH
3172         builds.
3173
3174 2007-04-03  Bruno Haible  <bruno@clisp.org>
3175
3176         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
3177         * lib/ldexpl.c: Undo last change.
3178
3179 2007-04-03  Bruno Haible  <bruno@clisp.org>
3180
3181         * modules/printf-frexpl (Depends-on): Undo last change.
3182         (Files): Add m4/ldexpl.m4.
3183
3184 2007-04-03  Bruno Haible  <bruno@clisp.org>
3185
3186         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
3187         * modules/isnanl (Link): New section.
3188
3189         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
3190         * modules/frexp (Link): New section.
3191
3192         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
3193         * modules/frexpl (Link): New section.
3194
3195         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
3196         * modules/ldexpl (Link): New section.
3197
3198 2007-04-03  Bruno Haible  <bruno@clisp.org>
3199
3200         * modules/TEMPLATE-EXTENDED: New file.
3201         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
3202
3203 2007-04-03  Bruno Haible  <bruno@clisp.org>
3204
3205         * DEPENDENCIES: New file.
3206         Suggested by Simon Josefsson.
3207
3208 2007-04-03  Bruno Haible  <bruno@clisp.org>
3209
3210         * doc/gnulib.texi: Escape @.
3211
3212 2007-04-03  James Youngman  <jay@gnu.org>
3213         and Paul Eggert  <eggert@cs.ucla.edu>
3214
3215         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
3216         birthtime on all systems that have birthtime, not just those which
3217         use st_birthtimensec rather than st_birthtim.  Putting zero in
3218         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
3219         that the birth time is not available for files on an NFS mount.
3220
3221 2007-04-03  Simon Josefsson  <simon@josefsson.org>
3222
3223         * modules/memxor: Move back from crypto/, suggested by Bruno.
3224         * modules/crypto/hmac-sha1: Fix memxor dependency.
3225
3226         * modules/crypto/gc: Moved from ../.
3227
3228 2007-04-02  Eric Blake  <ebb9@byu.net>
3229
3230         * lib/ldexpl.c (includes): Avoid libm.
3231
3232         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
3233
3234 2007-04-02  Bruno Haible  <bruno@clisp.org>
3235
3236         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
3237         on IRIX.
3238
3239 2007-04-02  Bruno Haible  <bruno@clisp.org>
3240
3241         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
3242         x86 or x86_64 platforms running MacOS X.
3243         Reported by Ryan Schmidt <@ryandesign.com>.
3244
3245 2007-04-02  Bruno Haible  <bruno@clisp.org>
3246
3247         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
3248         i386.
3249
3250 2007-04-01  Simon Josefsson  <simon@josefsson.org>
3251
3252         * modules/crypto/arcfour: Moved from ../.
3253         * modules/crypto/arcfour-tests: Moved from ../.
3254         * modules/crypto/arctwo: Moved from ../.
3255         * modules/crypto/arctwo-tests: Moved from ../.
3256         * modules/crypto/des: Moved from ../.
3257         * modules/crypto/des-tests: Moved from ../.
3258         * modules/crypto/gc-arcfour: Moved from ../.
3259         * modules/crypto/gc-arcfour-tests: Moved from ../.
3260         * modules/crypto/gc-arctwo: Moved from ../.
3261         * modules/crypto/gc-arctwo-tests: Moved from ../.
3262         * modules/crypto/gc-des: Moved from ../.
3263         * modules/crypto/gc-des-tests: Moved from ../.
3264         * modules/crypto/gc-hmac-md5: Moved from ../.
3265         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
3266         * modules/crypto/gc-hmac-sha1: Moved from ../.
3267         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
3268         * modules/crypto/gc-md2: Moved from ../.
3269         * modules/crypto/gc-md2-tests: Moved from ../.
3270         * modules/crypto/gc-md4: Moved from ../.
3271         * modules/crypto/gc-md4-tests: Moved from ../.
3272         * modules/crypto/gc-md5: Moved from ../.
3273         * modules/crypto/gc-md5-tests: Moved from ../.
3274         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
3275         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
3276         * modules/crypto/gc-random: Moved from ../.
3277         * modules/crypto/gc-rijndael: Moved from ../.
3278         * modules/crypto/gc-rijndael-tests: Moved from ../.
3279         * modules/crypto/gc-sha1: Moved from ../.
3280         * modules/crypto/gc-sha1-tests: Moved from ../.
3281         * modules/crypto/gc-tests: Moved from ../.
3282         * modules/crypto/hmac-md5: Moved from ../.
3283         * modules/crypto/hmac-md5-tests: Moved from ../.
3284         * modules/crypto/hmac-sha1: Moved from ../.
3285         * modules/crypto/hmac-sha1-tests: Moved from ../.
3286         * modules/crypto/md2: Moved from ../.
3287         * modules/crypto/md2-tests: Moved from ../.
3288         * modules/crypto/md4: Moved from ../.
3289         * modules/crypto/md4-tests: Moved from ../.
3290         * modules/crypto/md5: Moved from ../.
3291         * modules/crypto/md5-tests: Moved from ../.
3292         * modules/crypto/memxor: Moved from ../.
3293         * modules/crypto/rijndael: Moved from ../.
3294         * modules/crypto/rijndael-tests: Moved from ../.
3295         * modules/crypto/sha1: Moved from ../.
3296
3297 2007-03-30  James Youngman  <jay@gnu.org>
3298
3299         * tests/test-stat-time.c (prepare_test): use chmod() rather than
3300         rename() to change the ctime of a file (because ctime is unaffected
3301         by rename on jfs2 on AIX 5.1).
3302         (main): Start by doing cleanup, in case a previous run failed leaving
3303         test files behind.
3304
3305 2007-03-31  Bruno Haible  <bruno@clisp.org>
3306
3307         Support old proprietary implementations of iconv.
3308         * modules/iconv_open: New file.
3309         * lib/iconv_.h: New file.
3310         * m4/iconv_h.m4: New file.
3311         * lib/iconv_open.c: New file.
3312         * lib/iconv_open-aix.gperf: New file.
3313         * lib/iconv_open-hpux.gperf: New file.
3314         * lib/iconv_open-irix.gperf: New file.
3315         * lib/iconv_open-osf.gperf: New file.
3316         * m4/iconv_open.m4: New file.
3317         * modules/linebreak (Depends-on): Add iconv_open.
3318         * modules/striconv (Depends-on): Likewise.
3319         * modules/striconveh (Depends-on): Likewise.
3320         * modules/unicodeio (Depends-on): Likewise.
3321         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
3322         (iconv_t)(-1).
3323         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
3324         conversion if cd is (iconv_t)(-1).
3325         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
3326         is not possible.
3327
3328 2007-03-31  Bruno Haible  <bruno@clisp.org>
3329
3330         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3331         work on Solaris either. Protect also second use of "autodetect_jp".
3332
3333 2007-03-31  Bruno Haible  <bruno@clisp.org>
3334
3335         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
3336         the function is not present.
3337
3338 2007-03-31  Bruno Haible  <bruno@clisp.org>
3339
3340         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
3341         the function is not present.
3342
3343 2007-03-31  Bruno Haible  <bruno@clisp.org>
3344
3345         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
3346         a bug in HP-UX iconv_open().
3347
3348 2007-03-31  Bruno Haible  <bruno@clisp.org>
3349
3350         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
3351         (Mathematics <math.h>): New section, add fpieee.
3352         (Input/output <stdio.h>): Add fseterr.
3353         (Mathematics <math.h>): New section, add printf-frexp.
3354         (Container data structures): Add sublist.
3355         (Core language properties): Add fpucw, inline.
3356         (Functions for greatest-width integer types <inttypes.h>): Add
3357         imaxabs, imaxdiv, inttypes.
3358         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
3359         isnanl-nolibm, ldexp.
3360         (Mathematics <math.h>): New section, add printf-frexpl.
3361         (Support for systems lacking POSIX:2001): Add fprintf-posix,
3362         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
3363         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
3364         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
3365         (Unicode string functions): Add unistr/u*-mbtoucr.
3366         (Java): Add javacomp-script, javaexec-script.
3367         (C#): Add csharpcomp-script, csharpexec-script.
3368         (Support for building libraries and executables): Add havelib,
3369         relocatable-*.
3370         (Support for maintaining and releasing projects): Renamed from
3371         'Support for maintaining and release projects'. Add announce-gen.
3372
3373 2007-03-31  Bruno Haible  <bruno@clisp.org>
3374
3375         * README: Talk primarily about git.
3376         (git and CVS): Renamed from CVS.
3377         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
3378         gnulib is available through git.
3379         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
3380
3381 2007-03-30  Bruno Haible  <bruno@clisp.org>
3382
3383         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
3384         * lib/poll_.h: Likewise.
3385         * lib/stat_.h: Likewise.
3386         * lib/sys_time_.h: Likewise.
3387         * lib/sysexit_.h: Likewise.
3388         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
3389         * lib/stdbool_.h: Likewise.
3390         * lib/byteswap_.h: Add double-inclusion guard.
3391
3392 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
3393
3394         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
3395
3396 2007-03-30  Karl Berry  <karl@gnu.org>
3397
3398         * config/srclist-update: double space after USA in the license
3399         substitution, since that's how it's usually (?) written.
3400
3401 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3402
3403         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3404         reported by Bruno Haible.
3405
3406 2007-03-29  Bruno Haible  <bruno@clisp.org>
3407
3408         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3409         a bug in AIX iconv().
3410
3411 2007-03-29  Bruno Haible  <bruno@clisp.org>
3412
3413         * modules/ldexpl-tests: New file.
3414         * tests/test-ldexpl.c: New file.
3415
3416 2007-03-29  Bruno Haible  <bruno@clisp.org>
3417
3418         * lib/ldexpl.c: Include fpucw.h.
3419         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3420         multiplication.
3421         * modules/ldexpl (Depends-on): Add fpucw.
3422
3423 2007-03-29  Bruno Haible  <bruno@clisp.org>
3424
3425         * modules/ldexpl: New file.
3426         * m4/ldexpl.m4: New file.
3427         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3428         set.
3429         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3430         REPLACE_LDEXPL.
3431         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3432         REPLACE_LDEXPL.
3433         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3434         gl_FUNC_LDEXPL_WORKS.
3435         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3436         * modules/mathl (Files): Remove lib/ldexpl.c.
3437         (Depends-on): Add ldexpl.
3438
3439 2007-03-29  Bruno Haible  <bruno@clisp.org>
3440
3441         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3442
3443 2007-03-29  Bruno Haible  <bruno@clisp.org>
3444
3445         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3446         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3447         and possibly also HP-UX.
3448         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3449         work on AIX, IRIX, HP-UX, OSF/1.
3450         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3451         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3452         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3453         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3454         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3455         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3456
3457 2007-03-29  Bruno Haible  <bruno@clisp.org>
3458
3459         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3460
3461 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3462
3463         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3464         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3465
3466 2007-03-29  Eric Blake  <ebb9@byu.net>
3467
3468         * lib/acl-internal.h: Remove redundant include.
3469         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3470         Cygwin when a file is locked.
3471
3472 2007-03-29  Bruno Haible  <bruno@clisp.org>
3473
3474         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3475         file.
3476         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3477
3478 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3479
3480         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3481         try to remove a parent directory if the child couldn't be removed
3482         (except for the first rmdir, which could fail because the child
3483         doesn't exist).  Problem reported by Jeff Blaine in
3484         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3485
3486 2007-03-28  Bruno Haible  <bruno@clisp.org>
3487
3488         * lib/striconveh.c (utf8conv_carefully): New function.
3489         (mem_cd_iconveh_internal): Invoke it.
3490
3491 2007-03-28  Bruno Haible  <bruno@clisp.org>
3492
3493         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3494         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3495         input.
3496         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3497         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3498         unistr/u8-uctomb.
3499
3500 2007-03-28  Bruno Haible  <bruno@clisp.org>
3501
3502         * modules/unistr/u8-mbtoucr: New file.
3503         * lib/unistr/u8-mbtoucr.c: New file.
3504         * modules/unistr/u16-mbtoucr: New file.
3505         * lib/unistr/u16-mbtoucr.c: New file.
3506         * modules/unistr/u16-mbtoucr: New file.
3507         * lib/unistr/u16-mbtoucr.c: New file.
3508         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3509
3510 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3511             Bruno Haible  <bruno@clisp.org>
3512
3513         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3514         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3515         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3516
3517         * m4/stdio_h.m4: Add stubs for vasprintf too.
3518
3519         * modules/stdio: Support vasprintf in sed command.
3520
3521         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3522         vasprintf.h.  Add stdio module indicator.
3523
3524         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3525         vasprintf.h.
3526
3527         * lib/vasprintf.h: File removed.
3528
3529         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3530         * lib/vasprintf.c: Ditto.
3531         * lib/xvasprintf.c: Ditto.
3532         * tests/test-vasprintf-posix.c: Ditto.
3533         * tests/test-vasprintf.c: Ditto.
3534
3535 2007-03-27  Bruno Haible  <bruno@clisp.org>
3536
3537         Make vasnprintf multithread-safe.
3538         * lib/vasnprintf.c (decimal_point_char): New function.
3539         (VASNPRINTF): Use it.
3540         Suggested by Simon Josefsson.
3541
3542 2007-03-27  Eric Blake  <ebb9@byu.net>
3543
3544         Support sub-second birthtime on cygwin.
3545         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3546         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3547         (get_stat_birthtime): Also work with st_birthtim.
3548
3549 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3550
3551         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3552         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3553         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3554         (get_stat_birthtime_ns): Simplify compile-time tests.
3555         (get_stat_birthtime): Change the API to look like
3556         get_stat_mtime etc., except return a negative tv_nsec on error.
3557         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3558         Don't check for "spare" fields.
3559         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3560         or for struct stat.st_birthtime, as these tests aren't used.
3561         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3562
3563 2007-03-27  Bruno Haible  <bruno@clisp.org>
3564
3565         * lib/stat-time.h: Include <sys/stat.h>.
3566
3567 2007-03-27  James Youngman  <jay@gnu.org>
3568
3569         * lib/stat-time.h (get_stat_birthtime): New function for
3570           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3571         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3572           and its variants.
3573         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3574         * modules/stat-time-test: New file.
3575         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3576
3577 2007-03-26  Bruno Haible  <bruno@clisp.org>
3578
3579         Better support of signalling NaNs.
3580         * lib/atanl.c: Include isnanl.h.
3581         (atanl): Perform test for NaN at the beginning of the function and
3582         through a call to isnanl.
3583         * lib/cosl.c: Include isnanl.h.
3584         (cosl): Perform test for NaN at the beginning of the function and
3585         through a call to isnanl.
3586         * lib/ldexpl.c: Include isnanl.h.
3587         (ldexpl): Perform test for NaN through a call to isnanl.
3588         * lib/logl.c: Include isnanl.h.
3589         (logl): Perform test for NaN at the beginning of the function and
3590         through a call to isnanl.
3591         * lib/sinl.c: Include isnanl.h.
3592         (sinl): Perform test for NaN at the beginning of the function and
3593         through a call to isnanl.
3594         * lib/sqrtl.c: Include isnanl.h.
3595         (sqrtl): Perform test for NaN at the beginning of the function and
3596         through a call to isnanl.
3597         * lib/tanl.c: Include isnanl.h.
3598         (tanl): Perform test for NaN at the beginning of the function and
3599         through a call to isnanl.
3600         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
3601         * modules/mathl (Depends-on): Add isnanl.
3602
3603 2007-03-26  Eric Blake  <ebb9@byu.net>
3604
3605         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
3606         regression in logic sense of previous patch.
3607
3608 2007-03-26  Bruno Haible  <bruno@clisp.org>
3609
3610         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
3611         unportable shell command "if ! ...".
3612         Reported by Ralf Wildenhues.
3613
3614 2007-03-25  Bruno Haible  <bruno@clisp.org>
3615
3616         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
3617         <sysexits.h> file, and only add EX_CONFIG.
3618         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
3619         absolute file name and whether it is sufficient. Substitute also
3620         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
3621         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
3622         ABSOLUTE_SYSEXITS_H into sysexits.h.
3623
3624 2007-03-25  Bruno Haible  <bruno@clisp.org>
3625
3626         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
3627         hints is NULL.
3628
3629 2007-03-25  Bruno Haible  <bruno@clisp.org>
3630
3631         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
3632         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
3633
3634 2007-03-25  Bruno Haible  <bruno@clisp.org>
3635
3636         * lib/vasnprintf.c: Include langinfo.h.
3637         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
3638         multithread-safe.
3639         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
3640         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
3641         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
3642         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
3643         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
3644         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
3645         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
3646         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
3647         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
3648         Reported by Simon Josefsson.
3649
3650 2007-03-25  Bruno Haible  <bruno@clisp.org>
3651
3652         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
3653         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
3654         * modules/vasnprintf (Depends-on): Add stdint.
3655
3656 2007-03-25  Bruno Haible  <bruno@clisp.org>
3657
3658         * modules/fpieee: New file.
3659         * m4/fpieee.m4: New file.
3660         * modules/isnan-nolibm (Depends-on): Add fpieee.
3661         * modules/isnanl-nolibm (Depends-on): Add fpieee.
3662         * modules/isnanl (Depends-on): Add fpieee.
3663
3664 2007-03-25  Bruno Haible  <bruno@clisp.org>
3665
3666         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
3667
3668 2007-03-25  Bruno Haible  <bruno@clisp.org>
3669
3670         Avoid test failures on IRIX 6.5.
3671         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
3672         (main): Use it.
3673         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
3674         macros.
3675         (main): Use them.
3676
3677 2007-03-25  Bruno Haible  <bruno@clisp.org>
3678
3679         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
3680         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
3681         exists but doesn't work.
3682         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
3683         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
3684         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
3685         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
3686
3687 2007-03-25  Bruno Haible  <bruno@clisp.org>
3688
3689         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
3690         returns inf. Needed on IRIX 6.5.
3691
3692 2007-03-25  Bruno Haible  <bruno@clisp.org>
3693
3694         * tests/test-frexpl.c: Include isnanl-nolibm.h.
3695         (main): Use isnanl instead of x != x idiom.
3696         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
3697
3698         * tests/test-frexp.c: Include isnan.h.
3699         (main): Use isnan instead of x != x idiom.
3700         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
3701
3702 2007-03-25  Bruno Haible  <bruno@clisp.org>
3703
3704         * tests/test-frexp.c (NaN): New function/macro.
3705         (main): Use it instead of 0.0 / 0.0.
3706         * tests/test-isnan.c (NaN): New function/macro.
3707         (main): Use it instead of 0.0 / 0.0.
3708         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
3709         (test_function): Use it instead of 0.0 / 0.0.
3710         * tests/test-vasprintf-posix.c (NaN): New function/macro.
3711         (test_function): Use it instead of 0.0 / 0.0.
3712         * tests/test-snprintf-posix.h (NaN): New function/macro.
3713         (test_function): Use it instead of 0.0 / 0.0.
3714         * tests/test-sprintf-posix.h (NaN): New function/macro.
3715         (test_function): Use it instead of 0.0 / 0.0.
3716         * tests/test-fprintf-posix.h (NaN): New function/macro.
3717         (test_function): Use it instead of 0.0 / 0.0.
3718         * tests/test-printf-posix.h (NaN): New function/macro.
3719         (test_function): Use it instead of 0.0 / 0.0.
3720
3721         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
3722
3723 2007-03-25  Bruno Haible  <bruno@clisp.org>
3724
3725         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
3726
3727 2007-03-25  Bruno Haible  <bruno@clisp.org>
3728
3729         * lib/regexec.c (merge_state_with_log): Make static.
3730
3731 2007-03-25  Bruno Haible  <bruno@clisp.org>
3732
3733         * lib/trigl.c (kernel_rem_pio2): Make static.
3734
3735 2007-03-25  Bruno Haible  <bruno@clisp.org>
3736
3737         * lib/sincosl.c (sincosl_table): Make static.
3738
3739 2007-03-25  Bruno Haible  <bruno@clisp.org>
3740
3741         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
3742         if the compiler does not support C99.
3743
3744 2007-03-25  Bruno Haible  <bruno@clisp.org>
3745
3746         * modules/time (Makefile.am): Ensure all rule action lines start with a
3747         tab.
3748
3749 2007-03-24  Bruno Haible  <bruno@clisp.org>
3750
3751         * modules/tsearch-tests: New file.
3752         * tests/test-tsearch.sh: New file.
3753         * tests/test-tsearch.c: New file, mostly copied from glibc.
3754
3755         * modules/search-tests: New file.
3756         * tests/test-search.c: New file.
3757
3758         * modules/search: New file.
3759         * lib/search_.h: New file, incorporating lib/tsearch.h.
3760         * m4/search_h.m4: New file.
3761         * lib/tsearch.h: Remove file.
3762         * lib/tsearch.c: Include search.h instead of tsearch.h.
3763         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
3764         HAVE_TSEARCH.
3765         * modules/tsearch (Files): Remove lib/tsearch.h.
3766         (Depends-on): Add search.
3767         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
3768         (Include): Change tsearch.h into search.h.
3769
3770 2007-03-24  Bruno Haible  <bruno@clisp.org>
3771
3772         * modules/fpucw: New file.
3773         * lib/fpucw.h: New file.
3774         * lib/frexp.c: Include fpucw.h.
3775         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3776         (FUNC): Use them.
3777         * lib/printf-frexp.c: Include fpucw.h.
3778         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3779         (FUNC): Use them.
3780         * lib/vasnprintf.c: Include fpucw.h.
3781         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
3782         'long double' calculations.
3783         * tests/test-frexpl.c: Include fpucw.h.
3784         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3785         * tests/test-printf-frexpl.c: Include fpucw.h.
3786         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3787         * modules/frexpl (Depends-on): Add fpucw.
3788         * modules/printf-frexpl (Depends-on): Likewise.
3789         * modules/fprintf-posix (Depends-on): Likewise.
3790         * modules/snprintf-posix (Depends-on): Likewise.
3791         * modules/sprintf-posix (Depends-on): Likewise.
3792         * modules/vasnprintf-posix (Depends-on): Likewise.
3793         * modules/vasprintf-posix (Depends-on): Likewise.
3794         * modules/vfprintf-posix (Depends-on): Likewise.
3795         * modules/vsnprintf-posix (Depends-on): Likewise.
3796         * modules/vsprintf-posix (Depends-on): Likewise.
3797         * modules/frexpl-tests (Depends-on): Likewise.
3798         * modules/printf-frexpl-tests (Depends-on): Likewise.
3799
3800 2007-03-24  Bruno Haible  <bruno@clisp.org>
3801
3802         * lib/float+.h: New file.
3803         * lib/isnan.c: Include float+.h.
3804         (SIZE): New macro.
3805         (FUNC): Compare only SIZE bytes of the value.
3806         * lib/vasnprintf.c: Include float+.h.
3807         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
3808         SIZEOF_LDBL or SIZEOF_DBL bytes.
3809         * modules/isnan-nolibm (Files): Add lib/float+.h.
3810         * modules/isnanl-nolibm (Files): Add lib/float+.h.
3811         * modules/isnanl (Files): Add lib/float+.h.
3812         * modules/vasnprintf (Files): Add lib/float+.h.
3813
3814 2007-03-24  Bruno Haible  <bruno@clisp.org>
3815
3816         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
3817         include isnanl-nolibm.h.
3818
3819 2007-03-24  Bruno Haible  <bruno@clisp.org>
3820
3821         * tests/test-read-file.c (main): Don't produce spurious output for
3822         expected situations. Make the test fail if it encountered unexpected
3823         results.
3824
3825 2007-03-24  Bruno Haible  <bruno@clisp.org>
3826
3827         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
3828         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
3829
3830 2007-03-24  Bruno Haible  <bruno@clisp.org>
3831
3832         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
3833
3834 2007-03-24  Bruno Haible  <bruno@clisp.org>
3835
3836         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
3837         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
3838
3839         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
3840         * modules/utf8-ucs4: Turn into a symbolic link to module
3841         unistr/u8-mbtouc.
3842
3843         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
3844         utf8-ucs4-unsafe.
3845         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
3846         unistr/u8-mbtouc-unsafe.
3847
3848         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
3849         * modules/utf16-ucs4: Turn into a symbolic link to module
3850         unistr/u16-mbtouc.
3851
3852         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
3853         utf16-ucs4-unsafe.
3854         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
3855         unistr/u16-mbtouc-unsafe.
3856
3857         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
3858         * modules/ucs4-utf8: Turn into a symbolic link to module
3859         unistr/u8-ubtomb.
3860
3861         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
3862         * modules/ucs4-utf16: Turn into a symbolic link to module
3863         unistr/u16-ubtomb.
3864
3865 2007-03-24  Bruno Haible  <bruno@clisp.org>
3866
3867         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
3868         Enable the function only if HAVE_INLINE.
3869         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
3870         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3871         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
3872         Enable the function only if HAVE_INLINE.
3873         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
3874         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3875         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
3876         Enable the function only if HAVE_INLINE.
3877         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
3878         Enable the function only if HAVE_INLINE.
3879         * modules/utf8-ucs4: Update.
3880         * modules/utf8-ucs4-unsafe: Update.
3881         * modules/utf16-ucs4: Update.
3882         * modules/utf16-ucs4-unsafe: Update.
3883         * modules/ucs4-utf8: Update.
3884         * modules/ucs4-utf16: Update.
3885
3886 2007-03-24  Bruno Haible  <bruno@clisp.org>
3887
3888         * lib/utf8-ucs4.h: Remove file.
3889         * lib/utf8-ucs4-unsafe.h: Remove file.
3890         * lib/utf16-ucs4.h: Remove file.
3891         * lib/utf16-ucs4-unsafe.h: Remove file.
3892         * lib/ucs4-utf8.h: Remove file.
3893         * lib/ucs4-utf16.h: Remove file.
3894         * lib/unistr.h: Include their previous contents.
3895         * m4/utf-ucs4.m4: Remove file.
3896         * m4/ucs4-utf.m4: Remove file.
3897         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
3898         (Depends-on): Add unistr/base.
3899         (configure.ac): Remove gl_UTF_UCS4.
3900         (Makefile.am): Update.
3901         (Include): Change to unistr.h.
3902         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
3903         (Depends-on): Add unistr/base.
3904         (configure.ac): Remove gl_UTF_UCS4.
3905         (Makefile.am): Update.
3906         (Include): Change to unistr.h.
3907         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
3908         (Depends-on): Add unistr/base.
3909         (configure.ac): Remove gl_UTF_UCS4.
3910         (Makefile.am): Update.
3911         (Include): Change to unistr.h.
3912         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
3913         (Depends-on): Add unistr/base.
3914         (configure.ac): Remove gl_UTF_UCS4.
3915         (Makefile.am): Update.
3916         (Include): Change to unistr.h.
3917         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
3918         (Depends-on): Add unistr/base.
3919         (configure.ac): Remove gl_UCS4_UTF.
3920         (Makefile.am): Update.
3921         (Include): Change to unistr.h.
3922         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
3923         (Depends-on): Add unistr/base.
3924         (configure.ac): Remove gl_UCS4_UTF.
3925         (Makefile.am): Update.
3926         (Include): Change to unistr.h.
3927         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
3928         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
3929         utf8-ucs4-unsafe.h.
3930         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
3931         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
3932         utf16-ucs4-unsafe.h.
3933         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
3934         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
3935         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
3936         * lib/unistr/u8-strchr.c: Likewise.
3937         * lib/unistr/u8-strrchr.c: Likewise.
3938         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
3939         * lib/unistr/u16-strchr.c: Likewise.
3940         * lib/unistr/u16-strrchr.c: Likewise.
3941         * lib/striconveh.c: Update.
3942         * lib/linebreak.c: Update.
3943
3944 2007-03-24  Bruno Haible  <bruno@clisp.org>
3945
3946         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
3947         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
3948
3949 2007-03-22  Bruno Haible  <bruno@clisp.org>
3950
3951         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
3952
3953 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
3954
3955         * MODULES.html.sh (File system functions): New module write-any-file.
3956         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
3957         * m4/write-any-file.m4: New files.
3958
3959 2007-03-23  Eric Blake  <ebb9@byu.net>
3960
3961         * gnulib-tool: Rearrange space-tab sequences, since some editors
3962         like to eat them.
3963
3964 2007-03-23  Eric Blake  <ebb9@byu.net>
3965
3966         * lib/version-etc.c (version_etc_va): Update license wording to
3967         be more concise.  Recommended by Richard Stallman.
3968
3969 2007-03-22  Bruno Haible  <bruno@clisp.org>
3970
3971         * lib/poll.c (MSG_PEEK): New fallback definition.
3972
3973 2007-03-22  Bruno Haible  <bruno@clisp.org>
3974
3975         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
3976         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
3977         (main): Update.
3978         Fixes a compilation error on BeOS.
3979
3980 2007-03-22  Bruno Haible  <bruno@clisp.org>
3981
3982         * modules/frexpl-tests: New file.
3983         * tests/test-frexpl.c: New file.
3984
3985         * modules/frexpl: New file.
3986         * m4/frexpl.m4: New file.
3987         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
3988         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
3989         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
3990         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
3991         (Depends-on): Add frexpl. Remove isnanl-nolibm.
3992         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
3993
3994 2007-03-22  Bruno Haible  <bruno@clisp.org>
3995
3996         * lib/frexpl.c: Share code with lib/frexp.c.
3997         * modules/mathl (Files): Add lib/frexp.c.
3998         (Depends-on): Add isnanl-nolibm.
3999
4000 2007-03-22  Bruno Haible  <bruno@clisp.org>
4001
4002         * modules/printf-frexp (Files): Add m4/frexp.m4.
4003         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
4004         only if the found frexp function actually works.
4005
4006 2007-03-22  Bruno Haible  <bruno@clisp.org>
4007
4008         * lib/frexp.c: Remove older implementation that uses divisions.
4009
4010 2007-03-21  Bruno Haible  <bruno@clisp.org>
4011
4012         * modules/frexp-tests: New file.
4013         * tests/test-frexp.c: New file.
4014
4015         * modules/frexp: New file.
4016         * lib/frexp.c: New file.
4017         * m4/frexp.m4: New file.
4018         * lib/math_.h (frexp): New declaration.
4019         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
4020         REPLACE_FREXP.
4021         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
4022
4023 2007-03-21  Bruno Haible  <bruno@clisp.org>
4024
4025         * modules/isnanl-tests: New file.
4026         * tests/test-isnanl.c: New file.
4027
4028         * modules/isnanl: New file.
4029         * lib/isnanl.h: New file.
4030         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
4031         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
4032         gl_FUNC_ISNANL_WORKS.
4033         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
4034         New macros.
4035
4036 2007-03-21  Bruno Haible  <bruno@clisp.org>
4037
4038         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
4039         lib/isnanl.h.
4040         (Include): Update.
4041         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
4042         * lib/vasnprintf.c: Update.
4043         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
4044         tests/test-isnanl.h, remove tests/test-isnanl.c.
4045         (Makefile.am): Update.
4046         * tests/test-isnanl-nolibm.c: New file.
4047         * tests/test-isnanl.h: New file.
4048         * tests/test-isnanl.c: Remove file.
4049
4050 2007-03-21  Jim Meyering  <jim@meyering.net>
4051
4052         When trying to open ".", treat ESTALE like EACCES.
4053         * lib/savewd.c (savewd_save): Resort to forking not just upon
4054         failure with EACCES, but also when errno is ESTALE.
4055
4056 2007-03-20  Bruno Haible  <bruno@clisp.org>
4057
4058         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
4059         Needed on AIX 5.1. Reported by Matthew Woehlke.
4060
4061 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4062
4063         Suggestions by Bruno Haible:
4064         * lib/acl-internal.h: Include "gettext.h" rather than rolling
4065         our own.
4066         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
4067         * modules/acl (Depends-on): Add gettext.
4068
4069 2007-03-19  Bruno Haible  <bruno@clisp.org>
4070
4071         * modules/iconvme: Remove file.
4072         * lib/iconvme.h: Remove file.
4073         * lib/iconvme.c: Remove file.
4074         * m4/iconvme.m4: Remove file.
4075
4076 2007-03-19  Bruno Haible  <bruno@clisp.org>
4077
4078         * doc/relocatable-maint.texi: Break long shell script line.
4079         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4080
4081 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4082
4083         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
4084         handle file_has_acl.
4085         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
4086         * lib/acl.c: Move header inclusions and related macro defns into
4087         lib/acl-internal.h.
4088         (S_ISLNK): Remove defn, since that's now done for us.
4089         (file_has_acl): Move to lib/file-has-acl.c.
4090         Call acl_trivial if available.  This is the crucial part of the fix.
4091         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
4092         shared within the library.  Rewrite a bit, partly to make it compatible
4093         with the GNU coding style.
4094         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
4095         Remove unnecessary double-quotes.
4096         Don't test for acl_to_text; the build will catch that.
4097         Replace acl_entries if it doesn't exist and it is needed.
4098         Check for -lsec and acl_trivial (as used on Solaris 10).
4099         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
4100         lib/file-has-acl.c.
4101         (Depends-on): Add sys_stat, for S_ISLNK.
4102
4103 2007-03-19  Ben Pfaff  <blp@gnu.org>
4104
4105         * doc/gnulib.texi: Fix typos.
4106         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4107
4108 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4109
4110         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
4111         If size is zero here, buf must be zero.
4112
4113 2007-03-19  Simon Josefsson  <simon@josefsson.org>
4114
4115         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
4116         <bruno@clisp.org>.
4117
4118 2007-03-18  Bruno Haible  <bruno@clisp.org>
4119
4120         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
4121         Suggested by Eric Blake.
4122
4123 2007-03-18  Ben Pfaff  <blp@gnu.org>
4124
4125         * doc/relocatable.texi: Recommend using as prefix a directory
4126         that does not exist and will never be created.  Based on
4127         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
4128         and others.
4129
4130 2007-03-17  Bruno Haible  <bruno@clisp.org>
4131
4132         * lib/fchownat.c: Include lchown.h.
4133
4134 2007-03-17  Bruno Haible  <bruno@clisp.org>
4135
4136         Fix endless loop when the given allocated size was > INT_MAX.
4137         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
4138         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
4139         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
4140         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
4141         * lib/sprintf.c (sprintf): Likewise.
4142
4143 2007-03-17  Bruno Haible  <bruno@clisp.org>
4144
4145         * tests/test-argp-2.sh (func_compare): Output a context diff.
4146
4147 2007-03-17  Bruno Haible  <bruno@clisp.org>
4148
4149         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
4150         locale's decimal-point character.
4151
4152 2007-03-17  Bruno Haible  <bruno@clisp.org>
4153
4154         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
4155         before comparing it. Needed because on some platforms (e.g. x86) a
4156         'long double' occupies less bytes than sizeof (long double).
4157
4158 2007-03-17  Bruno Haible  <bruno@clisp.org>
4159
4160         * tests/test-crc.c (main): Make printf statements 64-bit clean.
4161         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
4162         * tests/test-getaddrinfo.c (simple): Likewise.
4163         * tests/test-read-file.c (main): Likewise.
4164
4165 2007-03-17  Bruno Haible  <bruno@clisp.org>
4166
4167         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
4168
4169 2007-03-17  Bruno Haible  <bruno@clisp.org>
4170
4171         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
4172         unused variable.
4173
4174 2007-03-17  Bruno Haible  <bruno@clisp.org>
4175
4176         * tests/test-c-strcasecmp.c: Include c-strcase.h.
4177         * tests/test-c-strncasecmp.c: Likewise.
4178
4179 2007-03-17  Bruno Haible  <bruno@clisp.org>
4180
4181         * modules/stdlib (Depends-on): Add unistd.
4182         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
4183         Needed for MacOS X 10.3.
4184
4185 2007-03-17  Bruno Haible  <bruno@clisp.org>
4186
4187         * lib/unistr/u-strdup.h: Include <stdlib.h>.
4188
4189 2007-03-17  Bruno Haible  <bruno@clisp.org>
4190
4191         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
4192
4193 2007-03-17  Bruno Haible  <bruno@clisp.org>
4194
4195         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
4196         to reflect files copied from gnulib (with or without modifications).
4197         Suggested by Jim Meyering.
4198
4199 2007-03-17  Eric Blake  <ebb9@byu.net>
4200
4201         * NEWS: Document stdlib change from 2007-02-18.
4202
4203 2007-03-17  Jim Meyering  <jim@meyering.net>
4204
4205         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
4206         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
4207         someone uses a name containing shell meta-characters.
4208         Reported by Alfred M. Szmidt.
4209
4210         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
4211
4212 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4213
4214         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
4215         and copy gettext configuration files only if configure.ac contains
4216         a use of AM_GNU_GETTEXT_VERSION.
4217
4218 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4219
4220         * build-aux/bootstrap (gnulib_name): New variable.
4221         (gnulib_tool_options): Use it.
4222
4223 2007-03-13  Simon Josefsson  <simon@josefsson.org>
4224
4225         * tests/test-des.c: Use new namespace.
4226
4227 2007-03-15  Bruno Haible  <bruno@clisp.org>
4228
4229         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
4230         Reported by James Youngman <jay@gnu.org>.
4231
4232 2007-03-15  Bruno Haible  <bruno@clisp.org>
4233
4234         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
4235         declared prototype. Needed with cc on OSF/1 5.1.
4236
4237 2007-03-15  Bruno Haible  <bruno@clisp.org>
4238
4239         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
4240         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
4241         (struct gl_list_implementation): Add dispose_fn argument to the
4242         'create_empty', 'create' methods.
4243         (struct gl_list_impl_base): Add field 'dispose_fn'.
4244         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
4245         argument.
4246         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
4247         dispose_fn argument.
4248         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
4249         dispose_fn on the dropped values.
4250         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
4251         dispose_fn argument.
4252         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
4253         dropped values.
4254         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
4255         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4256         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
4257         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4258         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
4259         argument.
4260         (gl_tree_list_free): Call dispose_fn on the dropped values.
4261         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
4262         the dropped values.
4263         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
4264         Add dispose_fn argument.
4265         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
4266         Call dispose_fn on the dropped values.
4267         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
4268         Add dispose_fn argument.
4269         (gl_sublist_create): Initialize the 'dispose_fn' field.
4270         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
4271         * tests/test-array_list.c (main): Update.
4272         * tests/test-carray_list.c (main): Update.
4273         * tests/test-avltree_list.c (main): Update.
4274         * tests/test-rbtree_list.c (main): Update.
4275         * tests/test-avltreehash_list.c (main): Update.
4276         * tests/test-rbtreehash_list.c (main): Update.
4277         * tests/test-linked_list.c (main): Update.
4278         * tests/test-linkedhash_list.c (main): Update.
4279         * tests/test-array_oset.c (main): Update.
4280
4281 2007-03-15  Bruno Haible  <bruno@clisp.org>
4282
4283         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
4284         (gl_oset_create_empty): Add dispose_fn argument.
4285         (struct gl_oset_implementation): Add dispose_fn argument to
4286         'create_empty' method.
4287         (struct gl_oset_impl_base): Add dispose_fn field.
4288         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
4289         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
4290         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
4291         values.
4292         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
4293         (gl_tree_oset_free): Call dispose_fn on the dropped values.
4294         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4295         dropped value.
4296         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4297         dropped value.
4298         * tests/test-array_oset.c (main): Update.
4299         * tests/test-avltree_oset.c (main): Update.
4300         * tests/test-rbtree_oset.c (main): Update.
4301         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
4302
4303 2007-03-13  Bruno Haible  <bruno@clisp.org>
4304
4305         * tests/test-stdbool.c (i): Update after last patch.
4306
4307 2007-03-12  Bruno Haible  <bruno@clisp.org>
4308
4309         * lib/quotearg.c: Include <wctype.h> early, before the definition of
4310         the iswprint macro. Needed on Solaris 2.5.1.
4311
4312 2007-03-12  Bruno Haible  <bruno@clisp.org>
4313
4314         * tests/test-printf-frexp.c (main): Declare x as volatile.
4315
4316 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4317
4318         * doc/gnulib.texi (Build robot for gnulib): New section.
4319
4320 2007-03-12  Jim Meyering  <jim@meyering.net>
4321
4322         * build-aux/bootstrap: New file.
4323         * build-aux/bootstrap.conf: New file, from coreutils.
4324
4325 2007-03-11  Bruno Haible  <bruno@clisp.org>
4326
4327         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
4328
4329 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4330
4331         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
4332         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
4333         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
4334
4335 2007-03-11  Bruno Haible  <bruno@clisp.org>
4336
4337         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
4338         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
4339
4340 2007-03-11  Bruno Haible  <bruno@clisp.org>
4341
4342         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
4343         formula. Needed for SunPRO C 5.0.
4344
4345 2007-03-11  Bruno Haible  <bruno@clisp.org>
4346
4347         * modules/long-options (Depends-on): Add getopt.
4348
4349 2007-03-11  Bruno Haible  <bruno@clisp.org>
4350
4351         * modules/modechange (Depends-on): Add stdbool.
4352
4353 2007-03-11  Bruno Haible  <bruno@clisp.org>
4354
4355         * modules/i-ring (Depends-on): Add stdbool.
4356
4357 2007-03-11  Bruno Haible  <bruno@clisp.org>
4358
4359         * modules/gc-des (Depends-on): Add stdbool.
4360
4361 2007-03-11  Bruno Haible  <bruno@clisp.org>
4362
4363         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
4364
4365 2007-03-11  Bruno Haible  <bruno@clisp.org>
4366
4367         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
4368
4369 2007-03-11  Bruno Haible  <bruno@clisp.org>
4370
4371         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
4372
4373 2007-03-11  Bruno Haible  <bruno@clisp.org>
4374
4375         * lib/vasnprintf.c (sprintf): Undefine.
4376
4377 2007-03-11  Bruno Haible  <bruno@clisp.org>
4378
4379         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
4380         initializers in SunPRO C and Compaq C compilers.
4381
4382 2007-03-11  Bruno Haible  <bruno@clisp.org>
4383
4384         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
4385         decrementing code ANSI C compliant.
4386
4387 2007-03-11  Bruno Haible  <bruno@clisp.org>
4388
4389         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
4390         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
4391
4392 2007-03-11  Bruno Haible  <bruno@clisp.org>
4393
4394         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
4395         <stdbool.h> substitute doesn't pass.
4396
4397 2007-03-11  Bruno Haible  <bruno@clisp.org>
4398
4399         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
4400
4401 2007-03-11  Bruno Haible  <bruno@clisp.org>
4402
4403         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4404         script, for submission to autobuild.josefsson.org.
4405
4406 2007-03-10  Bruno Haible  <bruno@clisp.org>
4407
4408         * modules/canonicalize-lgpl-tests: New file.
4409         * tests/test-canonicalize-lgpl.sh: New file.
4410         * tests/test-canonicalize-lgpl.c: New file.
4411
4412         * modules/c-strcase-tests: New file.
4413         * tests/test-c-strcase.sh: New file.
4414         * tests/test-c-strcasecmp.c: New file.
4415         * tests/test-c-strncasecmp.c: New file.
4416
4417         * modules/atexit-tests: New file.
4418         * tests/test-atexit.sh: New file.
4419         * tests/test-atexit.c: New file.
4420
4421 2007-03-10  Bruno Haible  <bruno@clisp.org>
4422
4423         * tests/test-binary-io.sh: Use temporary filenames that are not so
4424         likely to clash with those of other tests (in a parallel make).
4425         * tests/test-binary-io.c: Likewise.
4426
4427 2007-03-10  Bruno Haible  <bruno@clisp.org>
4428
4429         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4430         fallback; use #error instead.
4431         Suggested by Simon Josefsson.
4432
4433 2007-03-10  Bruno Haible  <bruno@clisp.org>
4434
4435         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4436         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4437         first and the last.
4438
4439 2007-03-10  Bruno Haible  <bruno@clisp.org>
4440
4441         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4442
4443 2007-03-10  Bruno Haible  <bruno@clisp.org>
4444
4445         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4446         "make distcheck".
4447         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4448         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4449         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4450
4451 2007-03-10  Bruno Haible  <bruno@clisp.org>
4452
4453         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4454         variable.
4455         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4456         variable.
4457
4458 2007-03-09  Eric Blake  <ebb9@byu.net>
4459         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4460
4461         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4462         types are not being provided by gnulib.
4463         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4464         types are supported.
4465
4466 2007-03-10  Bruno Haible  <bruno@clisp.org>
4467
4468         * lib/stdio_.h (__attribute__): New macro.
4469         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4470         vsprintf): Specify __attribute__ __format__ for GCC.
4471         Suggested by Eric Blake.
4472
4473 2007-03-09  Bruno Haible  <bruno@clisp.org>
4474
4475         * modules/printf-posix-tests: New file.
4476         * tests/test-printf-posix.sh: New file.
4477         * tests/test-printf-posix.c: New file.
4478
4479         * modules/printf-posix: New file.
4480         * lib/printf.c: New file.
4481         * m4/printf-posix-rpl.m4: New file.
4482         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4483         REPLACE_PRINTF.
4484         * lib/stdio_.h (printf): New declaration.
4485         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4486         ____strfmon____): New macros.
4487         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4488         REPLACE_PRINTF.
4489
4490 2007-03-09  Bruno Haible  <bruno@clisp.org>
4491
4492         * tests/test-vasnprintf-posix2.sh: New file.
4493         * tests/test-vasnprintf-posix2.c: New file.
4494         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4495         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4496         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4497
4498         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4499         a locale dependent decimal point, rather than always '.'.
4500
4501 2007-03-09  Eric Blake  <ebb9@byu.net>
4502
4503         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4504         spite of platforms like Tandem/NSK that define it to -1.
4505
4506 2007-03-08  Bruno Haible  <bruno@clisp.org>
4507
4508         * modules/vprintf-posix-tests: New file.
4509         * tests/test-vprintf-posix.sh: New file.
4510         * tests/test-vprintf-posix.c: New file.
4511         * tests/test-printf-posix.h: New file.
4512
4513         * modules/vprintf-posix: New file.
4514         * lib/vprintf.c: New file.
4515         * m4/vprintf-posix.m4: New file.
4516         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4517         REPLACE_VPRINTF.
4518         * lib/stdio_.h (vprintf): New declaration.
4519         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4520         REPLACE_VPRINTF.
4521
4522 2007-03-08  Bruno Haible  <bruno@clisp.org>
4523
4524         * modules/fprintf-posix-tests: New file.
4525         * tests/test-fprintf-posix.sh: New file.
4526         * tests/test-fprintf-posix.c: New file.
4527
4528         * modules/fprintf-posix: New file.
4529         * lib/fprintf.c: New file.
4530         * m4/fprintf-posix.m4: New file.
4531         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4532         REPLACE_FPRINTF.
4533         * lib/stdio_.h (fprintf): New declaration.
4534         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4535         REPLACE_FPRINTF.
4536
4537 2007-03-08  Bruno Haible  <bruno@clisp.org>
4538
4539         * modules/vfprintf-posix-tests: New file.
4540         * tests/test-vfprintf-posix.sh: New file.
4541         * tests/test-vfprintf-posix.c: New file.
4542         * tests/test-fprintf-posix.h: New file.
4543         * tests/test-fprintf-posix.out: New file.
4544
4545         * modules/vfprintf-posix: New file.
4546         * lib/vfprintf.c: New file.
4547         * m4/vfprintf-posix.m4: New file.
4548         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4549         REPLACE_VFPRINTF.
4550         * lib/stdio_.h (vfprintf): New declaration.
4551         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4552         REPLACE_VFPRINTF.
4553
4554 2007-03-08  Bruno Haible  <bruno@clisp.org>
4555
4556         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4557
4558 2007-03-08  Bruno Haible  <bruno@clisp.org>
4559
4560         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4561         instead of 'expr' invocations.
4562         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4563         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4564         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4565         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4566         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4567         Suggested by Paul Eggert.
4568
4569 2007-03-08  Bruno Haible  <bruno@clisp.org>
4570
4571         * modules/fseterr-tests: New file.
4572         * tests/test-fseterr.c: New file.
4573
4574         * modules/fseterr: New file.
4575         * lib/fseterr.h: New file.
4576         * lib/fseterr.c: New file.
4577
4578 2007-03-08  Bruno Haible  <bruno@clisp.org>
4579
4580         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4581         * lib/getopt_.h: Likewise.
4582         * lib/mbswidth.h: Likewise.
4583         * lib/setenv.h: Likewise.
4584         * lib/vasnprintf.h: Likewise.
4585         * lib/vasprintf.h: Likewise.
4586         * lib/verror.h: Likewise.
4587         * lib/xsetenv.h: Likewise.
4588         * lib/xvasprintf.h: Likewise.
4589
4590 2007-03-08  Jim Meyering  <jim@meyering.net>
4591
4592         * users.txt: Add parted.
4593
4594         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
4595
4596 2007-03-07  Bruno Haible  <bruno@clisp.org>
4597
4598         * m4/printf.m4: Make the shell script snippets copy&pastable.
4599
4600 2007-03-02  Bruno Haible  <bruno@clisp.org>
4601
4602         * lib/netinet_in_.h: New file.
4603         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
4604         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
4605         * modules/netinet_in (Files): Add lib/netinet_in_.h.
4606         (Depends-on): Add absolute-header.
4607         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
4608         into netinet/in.h.
4609
4610 2007-03-03  Bruno Haible  <bruno@clisp.org>
4611
4612         * lib/sys_select_.h: New file.
4613         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
4614         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
4615         * modules/sys_select (Files): Add lib/sys_select_.h.
4616         (Depends-on): Add absolute-header.
4617         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
4618         into sys/select.h.
4619
4620 2007-03-02  Bruno Haible  <bruno@clisp.org>
4621
4622         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
4623         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
4624         values.
4625         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
4626         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
4627         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
4628         * modules/sys_socket (Depends-on): Add absolute-header.
4629         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
4630         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
4631         (Include): Remove requirement of inclusion of <sys/types.h>.
4632
4633 2007-03-02  Bruno Haible  <bruno@clisp.org>
4634
4635         * lib/byteswap_.h (bswap_32): Fix formula.
4636
4637 2007-03-06  Bruno Haible  <bruno@clisp.org>
4638
4639         * modules/sprintf-posix-tests: New file.
4640         * tests/test-sprintf-posix.c: New file.
4641
4642         * modules/sprintf-posix: New file.
4643         * lib/sprintf.c: New file.
4644         * m4/sprintf-posix.m4: New file.
4645         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
4646         REPLACE_SPRINTF.
4647         * lib/stdio_.h (sprintf): New declaration.
4648         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
4649         REPLACE_SPRINTF.
4650
4651 2007-03-06  Bruno Haible  <bruno@clisp.org>
4652
4653         * modules/vsprintf-posix-tests: New file.
4654         * tests/test-vsprintf-posix.c: New file.
4655         * tests/test-sprintf-posix.h: New file.
4656
4657         * modules/vsprintf-posix: New file.
4658         * lib/vsprintf.c: New file.
4659         * m4/vsprintf-posix.m4: New file.
4660         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
4661         REPLACE_VSPRINTF.
4662         * lib/stdio_.h (vsprintf): New declaration.
4663         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
4664         REPLACE_VSPRINTF.
4665
4666 2007-03-06  Bruno Haible  <bruno@clisp.org>
4667
4668         * modules/vsnprintf (Depend-on): Remove minmax.
4669
4670 2007-03-06  Bruno Haible  <bruno@clisp.org>
4671
4672         * modules/snprintf-posix-tests: New file.
4673         * tests/test-snprintf-posix.c: New file.
4674
4675         * modules/snprintf-posix: New file.
4676         * m4/snprintf-posix.m4: New file.
4677         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
4678         gl_FUNC_SNPRINTF.
4679         (gl_FUNC_SNPRINTF): Invoke it.
4680         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
4681         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
4682         is set.
4683         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
4684
4685 2007-03-06  Bruno Haible  <bruno@clisp.org>
4686
4687         * modules/vsnprintf-posix-tests: New file.
4688         * tests/test-vsnprintf-posix.c: New file.
4689         * tests/test-snprintf-posix.h: New file.
4690
4691         * modules/vsnprintf-posix: New file.
4692         * m4/vsnprintf-posix.m4: New file.
4693         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
4694         gl_FUNC_VSNPRINTF.
4695         (gl_FUNC_VSNPRINTF): Invoke it.
4696         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
4697         * lib/stdio_.h (vsnprintf): Define as a replacement if
4698         REPLACE_VSNPRINTF is set.
4699         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
4700
4701 2007-03-06  Bruno Haible  <bruno@clisp.org>
4702
4703         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
4704         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
4705
4706 2007-03-06  Bruno Haible  <bruno@clisp.org>
4707
4708         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
4709         (asinl): Declare also if HAVE_DECL_ASINL is set.
4710         (atanl): Declare also if HAVE_DECL_ATANL is set.
4711         (ceill): Declare also if HAVE_DECL_CEILL is set.
4712         (cosl): Declare also if HAVE_DECL_COSL is set.
4713         (expl): Declare also if HAVE_DECL_EXPL is set.
4714         (floorl): Declare also if HAVE_DECL_FLOORL is set.
4715         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
4716         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
4717         (logl): Declare also if HAVE_DECL_LOGL is set.
4718         (sinl): Declare also if HAVE_DECL_SINL is set.
4719         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
4720         (tanl): Declare also if HAVE_DECL_TANL is set.
4721         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
4722         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
4723         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
4724         declaration of frexpl, ldexpl.
4725         * modules/printf-frexpl (Depends-on): Add math.
4726         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
4727
4728 2007-03-05  Bruno Haible  <bruno@clisp.org>
4729
4730         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
4731         frexpl and ldexpl are declared.
4732         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
4733
4734 2007-03-05  Bruno Haible  <bruno@clisp.org>
4735
4736         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
4737         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
4738
4739 2007-03-05  Bruno Haible  <bruno@clisp.org>
4740
4741         * lib/stdio_.h: Include <stddef.h>.
4742
4743 2007-03-05  Bruno Haible  <bruno@clisp.org>
4744
4745         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
4746
4747 2007-03-05  Bruno Haible  <bruno@clisp.org>
4748
4749         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
4750         NetBSD 4, from Ralf Wildenhues.
4751
4752 2007-03-04  Bruno Haible  <bruno@clisp.org>
4753
4754         * lib/vasprintf.h: Update #if logic for the case when the functions
4755         exist but are overridden.
4756
4757 2007-03-04  Bruno Haible  <bruno@clisp.org>
4758
4759         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
4760         implementations: glibc-2.4 and MacOS X 10.3.
4761         * tests/test-vasnprintf-posix.c (test_function): Test also the case
4762         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
4763         * tests/test-vasprintf-posix.c (test_function): Likewise.
4764
4765 2007-03-04  Bruno Haible  <bruno@clisp.org>
4766
4767         * modules/vasprintf-posix-tests: New file.
4768         * tests/test-vasprintf-posix.c: New file.
4769
4770         * modules/vasprintf-posix: New file.
4771         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
4772         defined.
4773         * m4/vasprintf-posix.m4: New file.
4774         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
4775         gl_FUNC_VASPRINTF.
4776         (gl_FUNC_VASPRINTF): Invoke it.
4777         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
4778         here.
4779         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
4780
4781 2007-03-04  Bruno Haible  <bruno@clisp.org>
4782
4783         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
4784         REPLACE_GETTIMEOFDAY.
4785         * modules/sys_time (Makefile.am): Likewise.
4786         * m4/sys_time_h.m4: Likewise.
4787         * m4/gettimeofday.m4: Likewise.
4788
4789 2007-03-04  Bruno Haible  <bruno@clisp.org>
4790
4791         * modules/vasnprintf-posix-tests: New file.
4792         * tests/test-vasnprintf-posix.c: New file.
4793
4794         * modules/vasnprintf-posix: New file.
4795         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
4796         printf-frexpl.h.
4797         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
4798         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
4799         REPLACE_VASNPRINTF is defined.
4800         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
4801         gl_FUNC_VASNPRINTF.
4802         (gl_FUNC_VASNPRINTF): Invoke it.
4803         * m4/vasnprintf-posix.m4: New file.
4804         * m4/printf.m4: New file.
4805
4806 2007-03-04  Bruno Haible  <bruno@clisp.org>
4807
4808         Compile progreloc.c only if --enable-relocatable is specified.
4809         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
4810         if --enable-relocatable was specified.
4811         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
4812         lib_SOURCES.
4813
4814 2007-03-04  Jim Meyering  <jim@meyering.net>
4815
4816         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
4817         Use it consistently, rather than enumerating errno constants.
4818
4819 2007-03-04  Bruno Haible  <bruno@clisp.org>
4820
4821         * modules/xvasprintf-tests: New file.
4822         * tests/test-xvasprintf.c: New file.
4823
4824         * modules/vasprintf-tests: New file.
4825         * tests/test-vasprintf.c: New file.
4826
4827         * modules/vasnprintf-tests: New file.
4828         * tests/test-vasnprintf.c: New file.
4829
4830         * modules/vsnprintf-tests: New file.
4831         * tests/test-vsnprintf.c: New file.
4832
4833         * modules/snprintf-tests: New file.
4834         * tests/test-snprintf.c: New file.
4835
4836 2007-03-04  Bruno Haible  <bruno@clisp.org>
4837
4838         Compile relocatable.c only if --enable-relocatable is specified.
4839         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
4840         gl_RELOCATABLE_LIBRARY.
4841         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
4842         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
4843         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
4844         gl_RELOCATABLE_LIBRARY.
4845         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
4846         (Makefile.am): Remove lib_SOURCES.
4847         * modules/relocatable-lib-lgpl (configure.ac): Invoke
4848         gl_RELOCATABLE_LIBRARY.
4849         (Makefile.am): Remove lib_SOURCES.
4850         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
4851         always.
4852         * modules/relocatable-prog-wrapper (configure.ac): Invoke
4853         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
4854
4855 2007-03-04  Bruno Haible  <bruno@clisp.org>
4856
4857         * modules/argmatch-tests: New file.
4858         * tests/test-argmatch.c: New file.
4859
4860         * tests/test-allocsa.c (main): Halve the number of loop runs.
4861
4862         * modules/alloca-opt-tests: New file.
4863         * tests/test-alloca-opt.c: New file.
4864
4865 2007-03-04  Jim Meyering  <jim@meyering.net>
4866
4867         Work around difference between Linux ACLs and Solaris 10 ZFS.
4868         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
4869         for EINVAL.
4870
4871 2007-03-03  Bruno Haible  <bruno@clisp.org>
4872
4873         * modules/relocatable-prog (Depends-on): Add back progreloc's
4874         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
4875
4876 2007-03-03  Bruno Haible  <bruno@clisp.org>
4877
4878         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
4879         * modules/relocatable-lib: New file.
4880
4881 2007-03-03  Bruno Haible  <bruno@clisp.org>
4882
4883         * modules/relocatable-prog: Renamed from modules/relocatable.
4884         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
4885
4886 2007-03-03  Bruno Haible  <bruno@clisp.org>
4887
4888         * modules/relocatable-script (Files): Add doc/relocatable.texi,
4889         m4/relocatable-lib.m4.
4890         (Depends-on): Remove 'relocatable'.
4891         (configure.ac): Add gl_RELOCATABLE_NOP.
4892
4893 2007-03-03  Bruno Haible  <bruno@clisp.org>
4894
4895         * modules/relocatable-prog-wrapper: New file.
4896         * modules/relocatable (Depends-on): Add it. Remove all other
4897         dependencies except progname.
4898         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
4899
4900         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
4901         (gl_FUNC_STRERROR): Nop.
4902         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
4903
4904         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
4905         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
4906
4907         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
4908         (gl_FUNC_READLINK): Update.
4909
4910         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
4911
4912 2007-03-03  Bruno Haible  <bruno@clisp.org>
4913
4914         * lib/xreadlink.c: Include <unistd.h> unconditionally.
4915         * modules/xreadlink (Depends-on): Add unistd.
4916         * modules/xreadlink-with-size (Depends-on): Likewise.
4917
4918 2007-03-03  Bruno Haible  <bruno@clisp.org>
4919
4920         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
4921         extracted from gt_FUNC_SETENV.
4922         (gt_FUNC_SETENV): Remove macro.
4923         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
4924         remove gt_FUNC_SETENV.
4925
4926 2007-03-03  Bruno Haible  <bruno@clisp.org>
4927
4928         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
4929         ENABLE_RELOCATABLE here.
4930         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
4931
4932 2007-03-03  Bruno Haible  <bruno@clisp.org>
4933
4934         * modules/rbtreehash-list-tests (Depends-on): Add progname.
4935         * tests/test-rbtreehash_list.c: Include progname.h.
4936         (main): Call set_program_name.
4937
4938         * modules/rbtree-oset-tests (Depends-on): Add progname.
4939         * tests/test-rbtree_oset.c: Include progname.h.
4940         (main): Call set_program_name.
4941
4942         * modules/rbtree-list-tests (Depends-on): Add progname.
4943         * tests/test-rbtree_list.c: Include progname.h.
4944         (main): Call set_program_name.
4945
4946         * modules/linked-list-tests (Depends-on): Add progname.
4947         * tests/test-linked_list.c: Include progname.h.
4948         (main): Call set_program_name.
4949
4950 2007-03-03  Bruno Haible  <bruno@clisp.org>
4951
4952         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
4953         All uses of __restrict changed to _Restrict_.
4954         * lib/glob_.h (__restrict): Remove macro.
4955
4956 2007-03-02  Bruno Haible  <bruno@clisp.org>
4957
4958         * modules/gettext (configure.ac): Require gettext infrastructure
4959         from version 0.16.1.
4960
4961 2007-03-02  Bruno Haible  <bruno@clisp.org>
4962
4963         * modules/linkedhash-list-tests (Depends-on): Add progname.
4964         * tests/test-linkedhash_list.c: Include progname.h.
4965         (main): Call set_program_name.
4966
4967         * modules/carray-list-tests (Depends-on): Add progname.
4968         * tests/test-carray_list.c: Include progname.h.
4969         (main): Call set_program_name.
4970
4971         * modules/avltreehash-list-tests (Depends-on): Add progname.
4972         * tests/test-avltreehash_list.c: Include progname.h.
4973         (main): Call set_program_name.
4974
4975         * modules/avltree-oset-tests (Depends-on): Add progname.
4976         * tests/test-avltree_oset.c: Include progname.h.
4977         (main): Call set_program_name.
4978
4979         * modules/avltree-list-tests (Depends-on): Add progname.
4980         * tests/test-avltree_list.c: Include progname.h.
4981         (main): Call set_program_name.
4982
4983         * modules/array-oset-tests (Depends-on): Add progname.
4984         * tests/test-array_oset.c: Include progname.h.
4985         (main): Call set_program_name.
4986
4987         * modules/array-list-tests (Depends-on): Add progname.
4988         * tests/test-array_list.c: Include progname.h.
4989         (main): Call set_program_name.
4990
4991         * modules/argp-tests (Depends-on): Add progname.
4992         * tests/test-argp.c: Include argp.h first. Include progname.h.
4993         (main): Call set_program_name.
4994
4995 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
4996
4997         * doc/gnulib-tool.texi (Initial import): Reword description of
4998         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
4999         limited effect even if defined after the first system include.
5000
5001 2007-03-01  Bruno Haible  <bruno@clisp.org>
5002
5003         * build-aux/config.libpath: Update to libtool-1.5.22.
5004         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
5005
5006 2007-03-01  Bruno Haible  <bruno@clisp.org>
5007
5008         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
5009         foo_CFLAGS.
5010         Reported by Ralf Wildenhues.
5011
5012 2007-03-01  Bruno Haible  <bruno@clisp.org>
5013
5014         * build-aux/install-reloc: Remove object files left over by some
5015         compilers.
5016         Reported by Ralf Wildenhues.
5017
5018 2007-03-01  Bruno Haible  <bruno@clisp.org>
5019
5020         * build-aux/install-reloc: Break long lines.
5021
5022 2007-03-01  Bruno Haible  <bruno@clisp.org>
5023
5024         * doc/relocatable.texi: Document that it may not work on OpenBSD.
5025         Reported by Ralf Wildenhues.
5026
5027 2007-03-01  Bruno Haible  <bruno@clisp.org>
5028
5029         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
5030         include ordering constraints.
5031
5032 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5033
5034         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
5035         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
5036         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
5037         as another example.
5038         * lib/time_.h: Fix misspelling.
5039         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5040         Require gl_HEADER_TIME_H_DEFAULTS.
5041         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
5042         * m4/time_r.m4 (gl_TIME_R): Likewise.
5043         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
5044
5045 2007-03-01  Bruno Haible  <bruno@clisp.org>
5046
5047         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
5048         * m4/utimens.m4 (gl_UTIMENS): Likewise.
5049
5050 2007-03-01  Jim Meyering  <jim@meyering.net>
5051
5052         * modules/xreadlink (Maintainer): Add my name.
5053         * modules/xreadlink-with-size (Depends-on): Alphabetize.
5054
5055 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
5056             Bruno Haible  <bruno@clisp.org>
5057
5058         * build-aux/install-reloc: Compile also c-ctype.c.
5059         * build-aux/relocatable.sh.in: New file.
5060         * doc/relocatable.texi: New file.
5061         * doc/relocatable-maint.texi: New file.
5062         * doc/gnulib.texi: Include relocatable-maint.texi.
5063         * lib/progreloc.c: Include unistd.h unconditionally.
5064         * lib/relocwrapper.c: Include unistd.h unconditionally.
5065         Include c-ctype.h.
5066         (add_dotbin): Use c_tolower.
5067         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
5068         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
5069         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
5070         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
5071         to m4/relocatable-lib.m4.
5072         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
5073         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
5074         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
5075         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
5076         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
5077         * modules/relocatable: New file.
5078         * modules/relocatable-lib: New file.
5079         * modules/relocatable-script: New file.
5080
5081 2007-02-28  Bruno Haible  <bruno@clisp.org>
5082
5083         Import --enable-relocatable infrastructure.
5084         * build-aux/config.libpath: New file, from GNU gettext.
5085         * build-aux/install-reloc: New file, from GNU gettext.
5086         * build-aux/reloc-ldflags: New file, from GNU gettext.
5087         * lib/relocatable.h: New file, from GNU gettext.
5088         * lib/relocatable.c: New file, from GNU gettext.
5089         * lib/relocwrapper.c: New file, from GNU gettext.
5090         * m4/relocatable.m4: New file, from GNU gettext.
5091
5092 2007-02-28  Bruno Haible  <bruno@clisp.org>
5093
5094         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
5095
5096         * modules/xreadlink: New file, from GNU gettext with modifications.
5097         * lib/xreadlink.c: New file, from GNU gettext.
5098         * lib/xreadlink.h: Add comments.
5099         (xreadlink): New declaration.
5100
5101         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
5102         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
5103         lib/xreadlink-with-size.c.
5104         (configure.ac): Remove gl_XREADLINK invocation.
5105         (Makefile.am): Augment lib_SOURCES.
5106         * m4/xreadlink.m4: Remove file.
5107         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
5108         (xreadlink_with_size): Renamed from xreadink.
5109         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
5110         * modules/canonicalize (Depends-on): Replace xreadlink with
5111         xreadlink-with-size.
5112         * lib/canonicalize.c (canonicalize_filename_mode): Update.
5113
5114 2007-02-25  Jim Meyering  <jim@meyering.net>
5115
5116         * build-aux/announce-gen: When complaining about excess arguments,
5117         list them.
5118
5119 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
5120
5121         * README: Document signed integer overflow situation more
5122         accurately.
5123
5124 2007-02-25  Bruno Haible  <bruno@clisp.org>
5125
5126         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
5127         'a' or 'A' conversion.
5128
5129 2007-02-25  Bruno Haible  <bruno@clisp.org>
5130
5131         * modules/filename: Renamed from modules/pathname.
5132         (Files): Replace lib/pathname.h with lib/filename.h. Replace
5133         lib/concatpath.c with lib/concat-filename.c.
5134         (Makefile.am): Update.
5135         (Include): Replace pathname.h with filename.h.
5136         * lib/filename.h: Renamed from lib/pathname.h.
5137         (concatenated_filename): Renamed from concatenated_pathname.
5138         * lib/concat-filename.c: Renamed from lib/concatpath.c.
5139         (concatenated_filename): Renamed from concatenated_pathname.
5140         * lib/findprog.c: Include filename.h instead of pathname.h.
5141         (find_in_path): Update.
5142         * lib/javacomp.c: Include filename.h instead of pathname.h.
5143         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
5144         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
5145         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
5146         is_oldgcj_14_13_usable, is_javac_usable): Update.
5147         * lib/javaexec.c: Include filename.h instead of pathname.h.
5148         (execute_java_class): Update.
5149         * modules/findprog: Update.
5150         * modules/javacomp: Update.
5151         * modules/javaexec: Update.
5152         * MODULES.html.sh (File system functions): Add 'filename', remove
5153         'pathname'.
5154
5155 2007-02-25  Bruno Haible  <bruno@clisp.org>
5156
5157         * modules/printf-frexpl-tests: New file.
5158         * tests/test-printf-frexpl.c: New file.
5159
5160         * modules/printf-frexpl: New file.
5161         * lib/printf-frexpl.h: New file.
5162         * lib/printf-frexpl.c: New file.
5163         * m4/printf-frexpl.m4: New file.
5164
5165 2007-02-25  Bruno Haible  <bruno@clisp.org>
5166
5167         * modules/printf-frexp-tests: New file.
5168         * tests/test-printf-frexp.c: New file.
5169
5170         * modules/printf-frexp: New file.
5171         * lib/printf-frexp.h: New file.
5172         * lib/printf-frexp.c: New file.
5173         * m4/printf-frexp.m4: New file.
5174
5175 2007-02-25  Bruno Haible  <bruno@clisp.org>
5176
5177         Assume automake >= 1.10 for the tests.
5178         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
5179         * modules/arctwo-tests: Likewise.
5180         * modules/argp-tests: Likewise.
5181         * modules/avltree-list-tests: Likewise.
5182         * modules/avltree-oset-tests: Likewise.
5183         * modules/avltreehash-list-tests: Likewise.
5184         * modules/carray-list-tests: Likewise.
5185         * modules/crc-tests: Likewise.
5186         * modules/des-tests: Likewise.
5187         * modules/gc-arcfour-tests: Likewise.
5188         * modules/gc-arctwo-tests: Likewise.
5189         * modules/gc-des-tests: Likewise.
5190         * modules/gc-hmac-md5-tests: Likewise.
5191         * modules/gc-hmac-sha1-tests: Likewise.
5192         * modules/gc-md2-tests: Likewise.
5193         * modules/gc-md4-tests: Likewise.
5194         * modules/gc-md5-tests: Likewise.
5195         * modules/gc-pbkdf2-sha1-tests: Likewise.
5196         * modules/gc-rijndael-tests: Likewise.
5197         * modules/gc-sha1-tests: Likewise.
5198         * modules/gc-tests: Likewise.
5199         * modules/getaddrinfo-tests: Likewise.
5200         * modules/hmac-md5-tests: Likewise.
5201         * modules/hmac-sha1-tests: Likewise.
5202         * modules/linked-list-tests: Likewise.
5203         * modules/linkedhash-list-tests: Likewise.
5204         * modules/lock-tests: Likewise.
5205         * modules/md2-tests: Likewise.
5206         * modules/md4-tests: Likewise.
5207         * modules/md5-tests: Likewise.
5208         * modules/rbtree-list-tests: Likewise.
5209         * modules/rbtree-oset-tests: Likewise.
5210         * modules/rbtreehash-list-tests: Likewise.
5211         * modules/read-file-tests: Likewise.
5212         * modules/rijndael-tests: Likewise.
5213         * modules/stdint-tests: Likewise.
5214         * modules/tls-tests: Likewise.
5215
5216 2007-02-24  Bruno Haible  <bruno@clisp.org>
5217
5218         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
5219         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
5220         function; instead check whether isnan with a double argument links.
5221         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
5222         function; instead check whether isnan with a 'long double' argument
5223         links.
5224         Reported by Eric Blake <ebb9@byu.net>.
5225
5226 2007-02-24  Bruno Haible  <bruno@clisp.org>
5227
5228         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
5229         defined.
5230         * lib/isnanl.c: Remove all code. Just include isnan.c.
5231         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
5232
5233 2007-02-25  Jim Meyering  <jim@meyering.net>
5234
5235         Avoid conflicting types for 'unsetenv' on FreeBSD.
5236         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
5237         conflicting with FreeBSD's (5.0 and 6.1) function declaration
5238         in stdlib.h.
5239
5240 2007-02-24  Bruno Haible  <bruno@clisp.org>
5241
5242         * modules/isnanl-nolibm-tests: New file.
5243         * tests/test-isnanl.c: New file.
5244
5245         * modules/isnanl-nolibm: New file.
5246         * lib/isnanl.h: New file.
5247         * lib/isnanl.c: New file.
5248         * m4/isnanl.m4: New file.
5249
5250 2007-02-24  Bruno Haible  <bruno@clisp.org>
5251
5252         * modules/isnan-nolibm-tests: New file.
5253         * tests/test-isnan.c: New file.
5254
5255         * modules/isnan-nolibm: New file.
5256         * lib/isnan.h: New file.
5257         * lib/isnan.c: New file.
5258         * m4/isnan.m4: New file.
5259
5260 2007-02-24  Bruno Haible  <bruno@clisp.org>
5261
5262         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
5263         assume that an exponent fits in 20 bits.
5264
5265 2007-02-24  Jim Meyering  <jim@meyering.net>
5266
5267         * m4/regex.m4: Update the description of the configure-time option,
5268         --without-included-regex, to state accurately what the defaults are,
5269         and perhaps to give people an idea why using this option is risky.
5270
5271 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
5272
5273         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
5274         loops on small arguments.  This attempts to avoid the problem
5275         Bruno Haible reported for AIX 4.3.2 in
5276         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
5277
5278 2007-02-23  Bruno Haible  <bruno@clisp.org>
5279
5280         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
5281         Needed for help2man.
5282
5283 2007-02-23  Karl Berry  <karl@gnu.org>
5284
5285         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
5286         exists, foo.h should be cvs-ignored, not committed.
5287
5288 2007-02-23  Eric Blake  <ebb9@byu.net>
5289
5290         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
5291         * lib/stat-time.h (includes): Likewise.
5292         * lib/utimecmp.c (includes): Likewise.
5293         * lib/utimens.h (includes): Likewise.
5294         * lib/getdate.y (includes): Also include "timespec.h" for use
5295         internal to the module.
5296         * modules/utimens (Depends-on): Revert yesterday's patch.
5297         * modules/nanosleep (Depends-on): Add missing dependency.
5298
5299 2007-02-22  Bruno Haible  <bruno@clisp.org>
5300
5301         * lib/glob.c: Don't include getlogin_r.h.
5302
5303 2007-02-22  Jim Meyering  <jim@meyering.net>
5304
5305         * modules/utimens (Depends-on): Add timespec, required for
5306         utimens.h's inclusion of timespec.h.
5307
5308 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
5309
5310         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
5311         long unreadable paths in GNU/Linux.  Problem reported by Andreas
5312         Schwab in
5313         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
5314         I'll try to think of a better way to fix the Solaris problem.
5315
5316         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
5317         like glibc; on Solaris 10, it fails with errno == EINVAL.
5318         POSIX says the behavior is unspecified if the first argument is NULL,
5319         so play it safe and never pass NULL to the system getcwd.
5320
5321 2007-02-21  Jim Meyering  <jim@meyering.net>
5322
5323         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
5324         of gettimeofday.  It would conflict with the one now always
5325         provided via sys_time_.h.  Reported by Matthew Woehlke, as
5326         an IRIX 6.5 build failure.
5327
5328 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
5329
5330         Minor fixups to port to Solaris 10 with Sun C 5.8.
5331         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
5332         * modules/getcwd (Depends-on): Add dirfd.
5333         * lib/putenv.c (putenv): #undef it.
5334         (rpl_putenv): New decl.
5335         (malloc, free): Include <stdlib.h> rather than prototyping separately.
5336
5337 2007-02-20  Bruno Haible  <bruno@clisp.org>
5338
5339         * modules/stdio-tests: New file.
5340         * tests/test-stdio.c: New file.
5341
5342         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
5343         (Depends-on): Add stdio.
5344         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5345         (Include): Use <stdio.h> instead of vsnprintf.h.
5346         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5347         HAVE_DECL_VSNPRINTF.
5348         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
5349
5350         * modules/snprintf (Files): Remove lib/snprintf.h.
5351         (Depends-on): Add stdio.
5352         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5353         (Include): Use <stdio.h> instead of snprintf.h.
5354         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5355         HAVE_DECL_SNPRINTF.
5356         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
5357         * lib/getaddrinfo.c: Likewise.
5358
5359         * modules/stdio: New file.
5360         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
5361         * lib/snprintf.h: Remove file.
5362         * lib/vsnprintf.h: Remove file.
5363         * lib/.cppi-disable: Remove snprintf.h.
5364         * m4/stdio_h.m4: New file.
5365         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
5366
5367 2007-02-20  Jim Meyering  <jim@meyering.net>
5368
5369         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
5370         used by e.g., mingw.  From Bruno Haible.
5371
5372 2007-02-19  Bruno Haible  <bruno@clisp.org>
5373
5374         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
5375         warnings.
5376         Reported by Ben Pfaff <blp@cs.stanford.edu>.
5377
5378 2007-02-19  Bruno Haible  <bruno@clisp.org>
5379
5380         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
5381         from mingw users.
5382
5383 2007-02-19  Bruno Haible  <bruno@clisp.org>
5384
5385         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
5386         warnings.
5387         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
5388
5389 2007-02-19  Jim Meyering  <jim@meyering.net>
5390
5391         Don't use FD after a successful "fdopendir (fd)".
5392         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
5393         Reset it by calling dirfd on the just-obtained DIR*.
5394
5395         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
5396         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
5397
5398 2007-02-18  Bruno Haible  <bruno@clisp.org>
5399
5400         * lib/readlink.c: Include <unistd.h>.
5401         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
5402         HAVE_READLINK.
5403         * modules/readlink (Depends-on): Add unistd.
5404         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5405         (Include): Add <unistd.h>.
5406
5407         * lib/getlogin_r.h: Remove file.
5408         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5409         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5410         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5411         HAVE_DECL_GETLOGIN_R.
5412         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5413         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5414         (Include): Use <unistd.h> instead of getlogin_r.h.
5415
5416         * lib/getcwd.h: Remove file.
5417         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5418         * lib/xgetcwd.c: Likewise.
5419         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5420         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5421         * modules/getcwd (Files): Remove lib/getcwd.h.
5422         (Depends-on): Add unistd.
5423         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5424         (Include): Use <unistd.h> instad of getcwd.h.
5425
5426         * lib/ftruncate.c: Include <unistd.h> first.
5427         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5428         Set HAVE_FTRUNCATE.
5429         * modules/ftruncate (Depends-on): Add unistd.
5430         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5431
5432         * lib/fchdir.c: Include <unistd.h> first.
5433         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5434         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5435         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5436         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5437         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5438
5439         * lib/dup2.c: Include <unistd.h> first.
5440         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5441         HAVE_DUP2.
5442         * modules/dup2 (Depends-on): Add unistd.
5443         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5444
5445         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5446         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5447         REPLACE_CHOWN. Don't define chown as a macro here.
5448         * modules/chown (Depends-on): Add unistd.
5449         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5450
5451         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5452         Add definition for GL_LINK_WARNING.
5453         (chown, dup2): New declarations.
5454         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5455         link warning.
5456         (ftruncate): New declaration.
5457         (getcwd): New declaration, taken from old getcwd.h.
5458         (getlogin_r): New declaration, taken from old getlogin_r.h.
5459         (readlink): New declaration.
5460         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5461         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5462         (gl_PREREQ_UNISTD): Remove macro.
5463         (gl_UNISTD_MODULE_INDICATOR): New macro.
5464         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5465         many new variables. Don't set UNISTD_H.
5466         * modules/unistd (Description): Change.
5467         (Depends-on): Add link-warning.
5468         (configure.ac): Update.
5469         (Makefile.am): Create unistd.h always. Substitute many new variables
5470         into it.
5471
5472 2007-02-18  Bruno Haible  <bruno@clisp.org>
5473
5474         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5475         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5476         HAVE_GETSUBOPT.
5477         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5478         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5479         * lib/getsubopt.h: Remove file.
5480         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5481         (Depends-on): Add stdlib.
5482         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5483         (Includes): Use <stdlib.h> instead of getsubopt.h.
5484         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5485         Set HAVE_GETSUBOPT.
5486         * lib/getsubopt.c: Don't include getsubopt.h.
5487
5488 2007-02-18  Bruno Haible  <bruno@clisp.org>
5489
5490         * modules/fchdir (Depends-on): Add dup2.
5491
5492 2007-02-18  Bruno Haible  <bruno@clisp.org>
5493
5494         * lib/stdlib_.h: Handle glibc's special invocation convention
5495         specially.
5496
5497 2007-02-18  Bruno Haible  <bruno@clisp.org>
5498
5499         * modules/stdlib-tests: New file.
5500         * tests/test-stdlib.c: New file.
5501
5502         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5503         (Depends-on): Add stdlib.
5504         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5505         (Includes): Use <stdlib.h> instead of mkstemp.h.
5506         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5507         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5508         * lib/mkstemp.c: Don't include mkstemp.h.
5509         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5510         * lib/stdlib--.h: Don't include mkstemp.h.
5511
5512         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5513         (Depends-on): Add stdlib.
5514         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5515         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5516         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5517         HAVE_MKDTEMP.
5518         * lib/mkdtemp.c: Don't include mkdtemp.h.
5519         * lib/clean-temp.c: Don't include mkdtemp.h.
5520
5521         * modules/exit (Files): Remove lib/exit.h.
5522         (Depends-on): Add stdlib.
5523         (Makefile.am): Remove lib_SOURCES.
5524         (Include): Use <stdlib.h> instead of exit.h.
5525         * lib/argmatch.c: Don't include exit.h.
5526         * lib/execute.c: Likewise.
5527         * lib/pagealign_alloc.c: Likewise.
5528         * lib/pipe.c: Likewise.
5529         * lib/wait-process.c: Likewise.
5530         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5531         * lib/exitfail.c: Likewise.
5532         * lib/savewd.c: Likewise.
5533         * lib/xsetenv.c: Likewise.
5534
5535         * modules/stdlib: New file.
5536         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5537         and extra comments about mkstemp().
5538         * lib/exit.h: Remove file.
5539         * lib/mkdtemp.h: Remove file.
5540         * lib/mkstemp.h: Remove file.
5541         * m4/stdlib_h.m4: New file.
5542         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5543
5544 2007-02-18  Bruno Haible  <bruno@clisp.org>
5545
5546         * modules/math-tests: New file.
5547         * tests/test-math.c: New file.
5548
5549         * modules/math: New file.
5550         * modules/mathl (Files): Remove lib/mathl.h.
5551         (Depends-on): Add math.
5552         (Makefile.am): Don't mention mathl.h.
5553         (Include): Use <math.h> instead of mathl.h.
5554         * lib/math_.h: New file.
5555         * lib/mathl.h: Remove file.
5556         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5557         mathl.h.
5558         * lib/asinl.c: Likewise.
5559         * lib/atanl.c: Likewise.
5560         * lib/ceill.c: Likewise.
5561         * lib/cosl.c: Likewise.
5562         * lib/expl.c: Likewise.
5563         * lib/floorl.c: Likewise.
5564         * lib/frexpl.c: Likewise.
5565         * lib/ldexpl.c: Likewise.
5566         * lib/logl.c: Likewise.
5567         * lib/sincosl.c: Likewise.
5568         * lib/sinl.c: Likewise.
5569         * lib/sqrtl.c: Likewise.
5570         * lib/tanl.c: Likewise.
5571         * lib/trigl.c: Likewise.
5572         * m4/math_h.m4: New file.
5573         * MODULES.html.sh (Mathematics): Add math.
5574
5575 2007-02-17  Bruno Haible  <bruno@clisp.org>
5576
5577         * modules/wctype-tests: New file.
5578         * tests/test-wctype.c: New file.
5579
5580         * modules/wchar-tests: New file.
5581         * tests/test-wchar.c: New file.
5582
5583         * modules/unistd-tests: New file.
5584         * tests/test-unistd.c: New file.
5585
5586         * modules/time-tests: New file.
5587         * tests/test-time.c: New file.
5588
5589         * modules/sysexits-tests: New file.
5590         * tests/test-sysexits.c: New file.
5591
5592         * modules/sys_time-tests: New file.
5593         * tests/test-sys_time.c: New file.
5594
5595         * modules/sys_stat-tests: New file.
5596         * tests/test-sys_stat.c: New file.
5597
5598         * modules/sys_socket-tests: New file.
5599         * tests/test-sys_socket.c: New file.
5600
5601         * modules/sys_select-tests: New file.
5602         * tests/test-sys_select.c: New file.
5603
5604         * modules/string-tests: New file.
5605         * tests/test-string.c: New file.
5606
5607         * modules/stdbool-tests: New file.
5608         * tests/test-stdbool.c: New file.
5609
5610         * modules/netinet_in-tests: New file.
5611         * tests/test-netinet_in.c: New file.
5612
5613         * modules/inttypes-tests: New file.
5614         * tests/test-inttypes.c: New file.
5615
5616         * modules/fcntl-tests: New file.
5617         * tests/test-fcntl.c: New file.
5618
5619         * modules/byteswap-tests: New file.
5620         * tests/test-byteswap.c: New file.
5621
5622         * modules/arpa_inet-tests: New file.
5623         * tests/test-arpa_inet.c: New file.
5624
5625 2007-02-17  Bruno Haible  <bruno@clisp.org>
5626
5627         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
5628         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
5629         if the corresponding module is not enabled. Emit link warnings if
5630         the function is used nevertheless.
5631         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
5632         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
5633         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
5634         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
5635         * modules/inttypes (Depends-on): Add link-warning.
5636         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5637         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
5638         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
5639         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
5640         * modules/imaxdiv (configure.ac): Likewise.
5641         * modules/strtoimax (configure.ac): Likewise.
5642         * modules/strtoumax (configure.ac): Likewise.
5643
5644 2007-02-17  Bruno Haible  <bruno@clisp.org>
5645
5646         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
5647         gl_STRING_MODULE_INDICATOR_DEFAULTS.
5648         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
5649         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
5650
5651 2007-02-17  Bruno Haible  <bruno@clisp.org>
5652
5653         * modules/link-warning: New file.
5654         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
5655         * lib/string_.h (GL_LINK_WARNING): Remove definition.
5656         * modules/string (Depends-on): Add link-warning.
5657         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5658         string.h.
5659         * MODULES.html.sh (Support for building libraries and executables): Add
5660         link-warning.
5661
5662 2007-02-17  Bruno Haible  <bruno@clisp.org>
5663
5664         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
5665         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
5666         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
5667         long lines.
5668
5669 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
5670             Bruno Haible  <bruno@clisp.org>
5671
5672         * modules/tmpfile: New file.
5673         * lib/tmpfile.c: New file.
5674         * m4/tmpfile.m4: New file.
5675         * MODULES.html.sh (func_all_modules): New section "Input/output".
5676
5677 2007-02-15  Bruno Haible  <bruno@clisp.org>
5678
5679         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
5680         (supports_delete_on_close): New function.
5681         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
5682
5683 2007-02-14  Bruno Haible  <bruno@clisp.org>
5684
5685         * modules/mbspcasecmp-tests: New file.
5686         * tests/test-mbspcasecmp.sh: New file.
5687         * tests/test-mbspcasecmp.c: New file.
5688
5689         New module mbspcasecmp.
5690         * modules/mbspcasecmp: New file.
5691         * lib/mbspcasecmp.c: New file.
5692         * lib/string_.h (strncasecmp): Change warning message.
5693         (mbspcasecmp): New declaration.
5694         * m4/mbspcasecmp.m4: New file.
5695         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5696         GNULIB_MBSPCASECMP.
5697         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
5698         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
5699
5700 2007-02-14  Bruno Haible  <bruno@clisp.org>
5701
5702         * modules/mbsncasecmp-tests: New file.
5703         * tests/test-mbsncasecmp.sh: New file.
5704         * tests/test-mbsncasecmp.c: New file.
5705
5706         New module mbsncasecmp.
5707         * modules/mbsncasecmp: New file.
5708         * lib/mbsncasecmp.c: New file.
5709         * lib/string_.h (mbsncasecmp): New declaration.
5710         * m4/mbsncasecmp.m4: New file.
5711         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5712         GNULIB_MBSNCASECMP.
5713         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
5714         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
5715
5716 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
5717
5718         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
5719         Verify that it doesn't overlap with our flags.
5720         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
5721         do not have the desired effect in multibyte locales; instead, use
5722         mbscasecmp.
5723         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
5724         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
5725         we don't require GNU fnmatch ourselves (if our users require it, they
5726         should do so explicitly).
5727
5728         Fix regex code so it doesn't rely on strcasecmp.
5729         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
5730         Otherwise, include gnulib's langinfo.h.
5731         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
5732         undesirable behavior in non-C locales.  Instead, rely on localecharset.
5733         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
5734         * modules/regex (FILES): Remove m4/codeset.m4.
5735         (Depends-on): Add localcharset.  Remove strcase.
5736
5737 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5738
5739         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
5740         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
5741
5742 2007-02-13  Bruno Haible  <bruno@clisp.org>
5743
5744         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
5745         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5746
5747 2007-02-12  Bruno Haible  <bruno@clisp.org>
5748
5749         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5750         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
5751         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
5752         time warning rather than a link error.
5753
5754 2007-02-12  Bruno Haible  <bruno@clisp.org>
5755
5756         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
5757         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
5758         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5759
5760 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5761
5762         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
5763         args, not 2.
5764
5765 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5766
5767         New module 'time', so that apps can include <time.h> as per
5768         POSIX and GNU instead of separate include files like time_r.h
5769         and timegm.h.  This implementation tries out a simpler approach
5770         for replacing decls in standard include files (as compared to
5771         the string module), somewhat as an experiment.
5772
5773         * config/srclist.txt: Comment out mktime.c for now.
5774         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
5775         since it doesn't apply any more.  Use generic wording instead.
5776         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
5777         'time'.
5778         * lib/time_.h, m4/time_h.m4, modules/time: New files.
5779         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
5780         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
5781         Don't include <sys/types.h>; no longer needed since we assume C89.
5782         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
5783         * lib/strftime.c: Likewise.
5784         * lib/time_r.c: Likewise.
5785         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
5786         * lib/nanosleep.c: Include <time.h> first, to check interface.
5787         * lib/strptime.c: Likewise.
5788         * lib/time_r.c: Likewise.
5789         * lib/timegm.c: Likewise.
5790         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
5791         needed.
5792         * lib/timegm.c: Don't include timegm.h; no longer needed.
5793         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
5794         time.h now handles any problems in that area.
5795         (struct timespec, nanosleep): Remove; time.h now arranges for these.
5796         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
5797         that time.h defines struct timespec.
5798         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
5799         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
5800         handles that.
5801         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
5802         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
5803         needed.  Set REPLACE_LOCALTIME.
5804         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
5805         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
5806         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
5807         nanosleep; time_h.m4 now does that.  Don't require
5808         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
5809         module handles this now.
5810         * modules/getdate (Depends-on): Remove timespec.  Add time.
5811         * modules/nanosleep (Depends-on): Likewise.
5812         * modules/stat-time (Depends-on): Likewise.
5813         * modules/nanosleep (Include): Include time.h, not timespec.h.
5814         * modules/strptime (Files): Remove lib/strptime.h.
5815         (Depends-on): Add extensions, time.
5816         (Include): Include time.h, not strptime.h.
5817         * modules/time_r (Files): Remove lib/time_r.h.
5818         (Depends-on): Add time.
5819         (Include): Include time.h, not time_r.h.
5820         * modules/timegm: Likewise.
5821         * modules/timespec (Description): Now does timespec-related decls
5822         of our own, instead of struct timespec itself.
5823         (Depends-on): Add time; remove extensions.
5824         (Maintainer): Add self.
5825         * modules/utimecmp (Depends-on): Add time; remove timespec.
5826         * modules/utimens (Depends-on): Likewise.
5827         * modules/xnanosleep (Depends-on): Likewise.
5828
5829 2007-02-11  Bruno Haible  <bruno@clisp.org>
5830
5831         * lib/c-strstr.c: Include allocsa.h.
5832         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5833         * lib/c-strcasestr.c: Include allocsa.h.
5834         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5835         * lib/strcasestr.c: Include allocsa.h.
5836         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5837         * lib/mbsstr.c: Include allocsa.h.
5838         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5839         allocsa/freesa instead of malloc/free.
5840         * lib/mbscasestr.c: Include allocsa.h.
5841         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5842         allocsa/freesa instead of malloc/free.
5843         * modules/c-strstr (Depends-on): Add allocsa.
5844         * modules/c-strcasestr (Depends-on): Likewise.
5845         * modules/strcasestr (Depends-on): Likewise.
5846         * modules/mbsstr (Depends-on): Likewise.
5847         * modules/mbscasestr (Depends-on): Likewise.
5848
5849 2007-02-11  Bruno Haible  <bruno@clisp.org>
5850
5851         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
5852
5853         * modules/mbsspn-tests: New file.
5854         * tests/test-mbsspn.sh: New file.
5855         * tests/test-mbsspn.c: New file.
5856
5857 2007-02-11  Bruno Haible  <bruno@clisp.org>
5858
5859         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
5860
5861         * modules/mbspbrk-tests: New file.
5862         * tests/test-mbspbrk.sh: New file.
5863         * tests/test-mbspbrk.c: New file.
5864
5865 2007-02-11  Bruno Haible  <bruno@clisp.org>
5866
5867         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
5868         unneeded cast.
5869
5870         * modules/mbscspn-tests: New file.
5871         * tests/test-mbscspn.sh: New file.
5872         * tests/test-mbscspn.c: New file.
5873
5874 2007-02-11  Bruno Haible  <bruno@clisp.org>
5875
5876         * modules/mbscasecmp-tests: New file.
5877         * tests/test-mbscasecmp.sh: New file.
5878         * tests/test-mbscasecmp.c: New file.
5879
5880 2007-02-11  Bruno Haible  <bruno@clisp.org>
5881
5882         Ensure O(n) worst-case complexity of mbscasestr.
5883         * lib/mbscasestr.c: Include stdbool.h.
5884         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5885         functions.
5886         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
5887         the bookkeeping indicates that it's worth it.
5888         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
5889
5890         * modules/mbscasestr-tests: New file.
5891         * tests/test-mbscasestr1.c: New file.
5892         * tests/test-mbscasestr2.sh: New file.
5893         * tests/test-mbscasestr2.c: New file.
5894         * tests/test-mbscasestr3.sh: New file.
5895         * tests/test-mbscasestr3.c: New file.
5896         * tests/test-mbscasestr4.sh: New file.
5897         * tests/test-mbscasestr4.c: New file.
5898         * m4/locale-tr.m4: New file.
5899
5900 2007-02-11  Bruno Haible  <bruno@clisp.org>
5901
5902         Ensure O(n) worst-case complexity of mbsstr.
5903         * lib/mbsstr.c: Include stdbool.h.
5904         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5905         functions.
5906         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
5907         bookkeeping indicates that it's worth it.
5908         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
5909
5910         * modules/mbsstr-tests: New file.
5911         * tests/test-mbsstr1.c: New file.
5912         * tests/test-mbsstr2.sh: New file.
5913         * tests/test-mbsstr2.c: New file.
5914         * tests/test-mbsstr3.sh: New file.
5915         * tests/test-mbsstr3.c: New file.
5916         * m4/locale-fr.m4: New file.
5917
5918 2007-02-11  Bruno Haible  <bruno@clisp.org>
5919
5920         * lib/mbsrchr.c (mbsrchr): Fix bug.
5921
5922         * modules/mbsrchr-tests: New file.
5923         * tests/test-mbsrchr.sh: New file.
5924         * tests/test-mbsrchr.c: New file.
5925
5926 2007-02-11  Bruno Haible  <bruno@clisp.org>
5927
5928         * lib/mbschr.c (mbschr): Fix bug.
5929
5930         * modules/mbschr-tests: New file.
5931         * tests/test-mbschr.sh: New file.
5932         * tests/test-mbschr.c: New file.
5933         * m4/locale-zh.m4: New file.
5934
5935 2007-02-11  Bruno Haible  <bruno@clisp.org>
5936
5937         Support for copying multibyte string iterators.
5938         * lib/mbiter.h: Include <string.h>.
5939         (mbiter_multi_copy): New function.
5940         (mbi_copy): New macro.
5941         * lib/mbuiter.h: Include <string.h>.
5942         (mbuiter_multi_copy): New function.
5943         (mbui_copy): New macro.
5944
5945 2007-02-11  Bruno Haible  <bruno@clisp.org>
5946
5947         New module mbslen.
5948         * modules/mbslen: New file.
5949         * lib/mbslen.c: New file.
5950         * lib/string_.h (mbslen): New declaration.
5951         * m4/mbslen.m4: New file.
5952         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5953         GNULIB_MBSLEN.
5954         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
5955         * MODULES.html.sh (Internationalization functions): Add mbslen.
5956
5957 2007-02-11  Bruno Haible  <bruno@clisp.org>
5958
5959         Ensure O(n) worst-case complexity of strcasestr substitute.
5960         * lib/strcasestr.c: Include stdbool.h.
5961         (knuth_morris_pratt): New function.
5962         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5963         bookkeeping indicates that it's worth it.
5964         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
5965
5966         * modules/strcasestr-tests: New file.
5967         * tests/test-strcasestr.c: New file.
5968
5969 2007-02-11  Bruno Haible  <bruno@clisp.org>
5970
5971         Ensure O(n) worst-case complexity of c_strcasestr.
5972         * lib/c-strcasestr.c: Include stdbool.h, string.h.
5973         (knuth_morris_pratt): New function.
5974         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
5975         the bookkeeping indicates that it's worth it.
5976         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
5977
5978         * modules/c-strcasestr-tests: New file.
5979         * tests/test-c-strcasestr.c: New file.
5980
5981 2007-02-11  Bruno Haible  <bruno@clisp.org>
5982
5983         Ensure O(n) worst-case complexity of c_strstr.
5984         * lib/c-strstr.c: Include stdbool.h, string.h.
5985         (knuth_morris_pratt): New function.
5986         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5987         bookkeeping indicates that it's worth it.
5988         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
5989
5990         * lib/c-strstr.c: Complete rewrite for maintainability.
5991
5992         * modules/c-strstr-tests: New file.
5993         * tests/test-c-strstr.c: New file.
5994
5995 2007-02-11  Bruno Haible  <bruno@clisp.org>
5996
5997         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
5998         5.2.1 and earlier, whereby \055 was treated just like the range
5999         delimiter '-'.
6000         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
6001
6002 2007-02-08  Bruno Haible  <bruno@clisp.org>
6003
6004         * modules/regex (Depends-on): Add stdbool.
6005         Reported by Dalibor Topic <robilad@kaffe.org>.
6006
6007 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6008
6009         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
6010         Prefer returning from main to exiting from it.
6011         Remove unnecessary parens after sizeof.
6012
6013 2007-02-05  Bruno Haible  <bruno@clisp.org>
6014
6015         New module mbssep.
6016         * modules/mbssep: New file.
6017         * lib/mbssep.c: New file.
6018         * lib/string_.h (strsep): Add a conditional link warning.
6019         (mbssep): New declaration.
6020         * m4/mbssep.m4: New file.
6021         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6022         GNULIB_MBSSEP.
6023         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
6024         * MODULES.html.sh (Internationalization functions): Add mbssep.
6025
6026 2007-02-05  Bruno Haible  <bruno@clisp.org>
6027
6028         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
6029         Optimize search in case of 1 delimiter.
6030
6031 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6032
6033         * lib/acl.h: Include sys/types.h before sys/acl.h.
6034
6035 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6036
6037         Merge upstream fix for glibc bugzilla #3957:
6038
6039         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
6040
6041         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
6042         bit for RE_HAT_LISTS_NOT_NEWLINE.
6043         (build_charclass_op): Remove bogus comment.
6044
6045 2007-02-05  Simon Josefsson  <simon@josefsson.org>
6046
6047         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
6048
6049 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6050
6051         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
6052         * lib/memmem.c [!defined _LIBC]: Include config.h.
6053
6054 2007-02-04  Bruno Haible  <bruno@clisp.org>
6055
6056         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
6057         warning message.
6058
6059 2007-02-04  Bruno Haible  <bruno@clisp.org>
6060
6061         New module mbstok_r.
6062         * modules/mbstok_r: New file.
6063         * lib/mbstok_r.c: New file.
6064         * lib/string_.h (strtok_r): Change argument names to match the
6065         comments. Add a conditional link warning.
6066         (mbstok_r): New declaration.
6067         * m4/mbstok_r.m4: New file.
6068         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6069         GNULIB_MBSTOK_R.
6070         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
6071         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
6072
6073 2007-02-04  Bruno Haible  <bruno@clisp.org>
6074
6075         New module mbsspn.
6076         * modules/mbsspn: New file.
6077         * lib/mbsspn.c: New file.
6078         * lib/string_.h (strspn): Add a conditional link warning.
6079         (mbsspn): New declaration.
6080         * m4/mbsspn.m4: New file.
6081         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6082         GNULIB_MBSSPN.
6083         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
6084         * MODULES.html.sh (Internationalization functions): Add mbsspn.
6085
6086 2007-02-04  Bruno Haible  <bruno@clisp.org>
6087
6088         New module mbspbrk.
6089         * modules/mbspbrk: New file.
6090         * lib/mbspbrk.c: New file.
6091         * lib/string_.h (strpbrk): Add a conditional link warning.
6092         (mbspbrk): New declaration.
6093         * m4/mbspbrk.m4: New file.
6094         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6095         GNULIB_MBSPBRK.
6096         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
6097         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
6098
6099 2007-02-04  Bruno Haible  <bruno@clisp.org>
6100
6101         New module mbscspn.
6102         * modules/mbscspn: New file.
6103         * lib/mbscspn.c: New file.
6104         * lib/string_.h (strcspn): Add a conditional link warning.
6105         (mbscspn): New declaration.
6106         * m4/mbscspn.m4: New file.
6107         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6108         GNULIB_MBSCSPN.
6109         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
6110         * MODULES.html.sh (Internationalization functions): Add mbscspn.
6111
6112 2007-02-04  Bruno Haible  <bruno@clisp.org>
6113
6114         New module mbscasestr, reduced goal of strcasestr.
6115         * modules/mbscasestr: New file.
6116         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
6117         (mbscasestr): Renamed from strcasestr.
6118         * lib/strcasestr.c: Don't include mbuiter.h.
6119         (strcasestr): Remove support for multibyte locales.
6120         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
6121         Change the conditional link warning.
6122         (mbscasestr): New declaration.
6123         * m4/mbscasestr.m4: New file.
6124         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
6125         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
6126         REPLACE_STRCASESTR.
6127         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
6128         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6129         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6130         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
6131         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
6132         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6133         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
6134         (Depends-on): Remove mbuiter.
6135         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
6136
6137 2007-02-04  Bruno Haible  <bruno@clisp.org>
6138
6139         Simplify handling of strncasecmp.
6140         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
6141         the conditional link warning.
6142         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6143         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
6144         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
6145         * modules/strcase (configure.ac): Don't invoke
6146         gl_STRING_MODULE_INDICATOR.
6147         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
6148
6149 2007-02-04  Bruno Haible  <bruno@clisp.org>
6150
6151         New module mbscasecmp, reduced goal of strcasecmp.
6152         * modules/mbscasecmp: New file.
6153         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
6154         (mbscasecmp): Renamed from strcasecmp.
6155         * lib/strcasecmp.c: Don't include mbuiter.h.
6156         (strcasecmp): Remove support for multibyte locales.
6157         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
6158         Change the conditional link warning.
6159         (mbscasecmp): New declaration.
6160         * m4/mbscasecmp.m4: New file.
6161         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
6162         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
6163         REPLACE_STRCASECMP.
6164         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
6165         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6166         GNULIB_MBSCASECMP.
6167         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
6168         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
6169         * modules/strcase (Files): Remove m4/mbrtowc.m4.
6170         (Depends-on): Remove mbuiter.
6171         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
6172
6173 2007-02-04  Bruno Haible  <bruno@clisp.org>
6174
6175         New module mbsstr. Remove module strstr.
6176         * modules/mbsstr: New file.
6177         * modules/strstr: Remove file.
6178         * lib/mbsstr.c: Renamed from lib/strstr.c.
6179         (mbsstr): Renamed from strstr.
6180         * lib/string_.h (strstr): Remove declaration. Change the conditional
6181         link warning.
6182         (mbsstr): New declaration.
6183         * m4/mbsstr.m4: New file.
6184         * m4/strstr.m4: Remove file.
6185         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
6186         REPLACE_STRSTR.
6187         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
6188         Don't initialize GNULIB_STRSTR.
6189         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
6190         substitute GNULIB_STRSTR and REPLACE_STRSTR.
6191         * MODULES.html.sh (Internationalization functions): Add mbsstr.
6192         (Support for systems lacking ANSI C 89): Remove strstr.
6193
6194 2007-02-04  Bruno Haible  <bruno@clisp.org>
6195
6196         New module mbsrchr.
6197         * modules/mbsrchr: New file.
6198         * lib/mbsrchr.c: New file.
6199         * lib/string_.h (strrchr): Add a conditional link warning.
6200         (mbsrchr): New declaration.
6201         * m4/mbsrchr.m4: New file.
6202         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6203         GNULIB_MBSRCHR.
6204         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
6205         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
6206
6207 2007-02-04  Bruno Haible  <bruno@clisp.org>
6208
6209         New module mbschr.
6210         * modules/mbschr: New file.
6211         * lib/mbschr.c: New file.
6212         * lib/string_.h (strchr): Add a conditional link warning.
6213         (mbschr): New declaration.
6214         * m4/mbschr.m4: New file.
6215         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6216         GNULIB_MBSCHR.
6217         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
6218         * MODULES.html.sh (Internationalization functions): Add mbschr.
6219
6220 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6221
6222         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
6223
6224         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
6225
6226 2007-02-04  Bruno Haible  <bruno@clisp.org>
6227
6228         New module description section 'configure.ac-early'.
6229         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
6230         (func_get_autoconf_early_snippet): New function.
6231         (func_import, func_create_testdir): Use it. Remove special cases for
6232         modules 'extensions' and 'lock'.
6233         * modules/extensions (configure.ac-early): Require
6234         gl_USE_SYSTEM_EXTENSIONS.
6235         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
6236
6237 2007-02-04  Bruno Haible  <bruno@clisp.org>
6238
6239         Make use of gcj-4.3's -fsource and -ftarget option.
6240         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
6241         and if so try the options -fsource and -ftarget.
6242         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
6243         source_version, ftarget_option, target_version arguments.
6244         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
6245         (is_envjavac_oldgcj_14_14_usable): Renamed from
6246         is_envjavac_gcj_14_14_usable.
6247         (is_envjavac_oldgcj_14_13_usable): Renamed from
6248         is_envjavac_gcj_14_13_usable.
6249         (is_gcj_present): Update.
6250         (is_gcj_43, is_gcj43_usable): New functions.
6251         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
6252         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
6253         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
6254         try the options -fsource and -ftarget.
6255
6256 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
6257
6258         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
6259         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
6260         larger value.
6261
6262 2007-02-03  Jim Meyering  <jim@meyering.net>
6263
6264         Give tools a better chance to allocate space for very large buffers.
6265         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
6266
6267         Make pwd and readlink work also when run with an unreadable parent dir
6268         on systems with openat support.
6269         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
6270         provided getcwd function, even when we have openat support.
6271         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
6272
6273 2007-02-02  Bruno Haible  <bruno@clisp.org>
6274
6275         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6276         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
6277         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
6278         portability problems if one of these functions is only used on specific
6279         platforms.
6280         Reported by Paul Eggert.
6281
6282 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
6283
6284         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
6285         is causing more trouble than it's curing.
6286         * lib/regex_internal.h (__mempcpy): Remove.
6287         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
6288         (and make the code a tad smaller to boot).
6289         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
6290
6291 2007-02-02  Jim Meyering  <jim@meyering.net>
6292
6293         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
6294         section, not in the Makefile.am: one.
6295
6296 2007-02-02  Eric Blake  <ebb9@byu.net>
6297
6298         * lib/strchrnul.c: Always include config.h first.
6299
6300         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
6301         gnulib strstr is not necessary here.
6302
6303 2007-02-02  Simon Josefsson  <simon@josefsson.org>
6304
6305         * m4/socklen.m4: Fix typo.
6306
6307 2007-02-02  Eric Blake  <ebb9@byu.net>
6308
6309         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
6310         * modules/netinet_in (Makefile.am): Likewise.
6311
6312 2007-02-01  Bruno Haible  <bruno@clisp.org>
6313
6314         * lib/string_.h (GL_LINK_WARNING): New macro.
6315         (strcasecmp, strstr, strcasestr): If provided by the system,
6316         conditionally define as a macro that leads to a warning instead of to
6317         an error.
6318         (strncasecmp): Conditionally define as a macro that leads to a warning.
6319
6320 2007-02-01  Karl Berry  <karl@gnu.org>
6321
6322         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
6323
6324 2007-02-01  Bruno Haible  <bruno@clisp.org>
6325
6326         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
6327         renamings.
6328
6329 2007-02-01  Eric Blake  <ebb9@byu.net>
6330
6331         * modules/regex (Depends-on): Revert dependence on mempcpy.
6332         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
6333         module's definition of mempcpy.
6334         Reported by Paul Eggert.
6335
6336 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
6337
6338         * lib/string_.h: If the gnulib module XYZ is not present, undefine
6339         the symbol XYZ before redefining it.  This fixes a problem with
6340         programs that don't use XYZ, when compiled on systems that define
6341         XYZ to something else.
6342
6343 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
6344
6345         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
6346         occurs when "mkdir -m foo" creates a setgid directory that is (1)
6347         writeable to group or other and (2) is intended to have a special
6348         mode bit that is set or cleared.  In such a case, the directory
6349         should be neither group- nor other-writeable until the special
6350         mode bits are right.
6351
6352 2007-01-31  Eric Blake  <ebb9@byu.net>
6353
6354         * modules/mountlist (Depends-on): Add strstr.
6355
6356         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
6357         bug.
6358         * modules/string (Makefile.am): Remove redundant replacement.
6359         * modules/regex (Depends-on): Add mempcpy.
6360
6361 2007-01-31  Bruno Haible  <bruno@clisp.org>
6362
6363         New module description field 'Link'.
6364         * gnulib-tool (func_usage): Document --extract-link-directive.
6365         (sed_extract_prog): Recognize 'Link' directive.
6366         (func_get_link_directive): New function.
6367         (func_import): Show summary of link directives.
6368         Handle --extract-link-directive option.
6369         * modules/acl (Link): New section.
6370         * modules/clock-time (Link): New section.
6371         * modules/euidaccess (Link): New section.
6372         * modules/gettext (Link): New section.
6373         * modules/iconv (Link): New section.
6374         * modules/lock (Link): New section.
6375         * modules/nanosleep (Link): New section.
6376         * modules/readline (Link): New section.
6377
6378 2007-01-27  Bruno Haible  <bruno@clisp.org>
6379
6380         Enforce the use of gnulib modules for unportable <string.h> functions.
6381         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
6382         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
6383         (gl_HEADER_STRING_H_BODY): Require it.
6384         * lib/string_.h: If the gnulib module XYZ is not present, redefine
6385         the symbol XYZ to one that gives a link error.
6386         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
6387         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
6388         * modules/mempcpy (configure.ac): Likewise.
6389         * modules/memrchr (configure.ac): Likewise.
6390         * modules/stpcpy (configure.ac): Likewise.
6391         * modules/stpncpy (configure.ac): Likewise.
6392         * modules/strcase (configure.ac): Likewise.
6393         * modules/strcasestr (configure.ac): Likewise.
6394         * modules/strchrnul (configure.ac): Likewise.
6395         * modules/strdup (configure.ac): Likewise.
6396         * modules/strndup (configure.ac): Likewise.
6397         * modules/strnlen (configure.ac): Likewise.
6398         * modules/strpbrk (configure.ac): Likewise.
6399         * modules/strsep (configure.ac): Likewise.
6400         * modules/strstr (configure.ac): Likewise.
6401         * modules/strtok_r (configure.ac): Likewise.
6402
6403 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6404
6405         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6406
6407 2007-01-30  Jim Meyering  <jim@meyering.net>
6408
6409         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6410
6411 2007-01-29  Bruno Haible  <bruno@clisp.org>
6412
6413         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6414         * lib/execute.c: Likewise.
6415         * lib/pipe.c: Likewise.
6416         * lib/printf-args.h: Likewise.
6417         * lib/printf-args.c: Likewise.
6418         * lib/printf-parse.c: Likewise.
6419         * lib/vasnprintf.c: Likewise.
6420
6421 2007-01-29  Eric Blake  <ebb9@byu.net>
6422
6423         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6424         declaration.
6425
6426 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6427
6428         * lib/strptime.h (strptime): Use 'restrict' for args where
6429         POSIX requires this.
6430         * lib/strptime.c (strptime): Likewise.
6431         Change license notice from LGPL to GPL, since gnulib-tool will
6432         change this as needed.
6433         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6434         defined.
6435         Include "strptime.h" first, to check interface.
6436         Do not #undef _LIBC and _NL_CURRENT.
6437         Do not include <stdlib.h>; no longer needed.
6438         Include "time_r.h" and declare ptime_locale_status
6439         only if _LIBC is not defined.
6440         (__P): Remove unused macro.
6441         (match_string): Bring back glibc version, but use it only if _LIBC
6442         is defined.
6443         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6444         Remove unnecessary assertion and abort() call.
6445         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6446         * m4/strptime.m4: Fix serial number comment.
6447         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6448         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6449         (Depends-on): Add time_r.
6450
6451 2007-01-29  Bruno Haible  <bruno@clisp.org>
6452
6453         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6454         strptime.
6455         * modules/strptime (Depends-on): Add stdbool.
6456         * lib/strptime.h: Include <time.h> always. Add comments.
6457
6458 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6459
6460         * modules/strptime: New file.
6461         * lib/strptime.h: New file.
6462         * lib/strptime.c: New file.
6463         * m4/strptime.m4: New file.
6464
6465 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6466
6467         * MODULES.html.sh: New module mpsort.
6468         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6469
6470         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6471         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6472         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6473         All uses changed.
6474         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6475         All uses changed.
6476         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6477         to _Restrict_.
6478         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6479         the parameter matches the prototype.
6480
6481 2007-01-28  Jim Meyering  <jim@meyering.net>
6482
6483         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6484         sys/time.h here, reverting that part of the previous patch:
6485         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6486
6487 2007-01-28  Bruno Haible  <bruno@clisp.org>
6488
6489         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6490         value of $(SYS_TIME_H).
6491         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6492         remove it conditionally, too. [added by Jim Meyering]
6493         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6494         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6495         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6496         GETTIMEOFDAY_REPLACEMENT to 1.
6497
6498 2007-01-28  Bruno Haible  <bruno@clisp.org>
6499
6500         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6501         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6502         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6503         Set UNISTD_H instead of UNISTD_H2.
6504         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6505
6506 2007-01-28  Bruno Haible  <bruno@clisp.org>
6507
6508         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6509         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6510
6511 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6512
6513         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6514         (func_create_testdir): Ensure C locale for `grep' and `tr'
6515         character ranges.
6516         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6517         ACLOCAL_AMFLAGS parsing state machine.
6518
6519 2007-01-27  Bruno Haible  <bruno@clisp.org>
6520
6521         * modules/unistr/base: Update.
6522
6523 2007-01-27  Bruno Haible  <bruno@clisp.org>
6524
6525         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6526         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6527         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6528         modules/unistr/u32-mbtouc.
6529         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6530         * lib/unistr.h: Update.
6531         * lib/linebreak.c: Update.
6532         * modules/unistr/u32-mbtouc: Renamed from
6533         modules/unistr/u32-mbtouc-safe.
6534         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6535         * lib/unistr.h: Update.
6536         * lib/unistr/u32-to-u8.c: Update.
6537         * lib/unistr/u32-to-u16.c: Update.
6538
6539 2007-01-27  Bruno Haible  <bruno@clisp.org>
6540
6541         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6542         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6543         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6544         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6545         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6546         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6547         modules/unistr/u16-mbtouc.
6548         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6549         * lib/unistr.h: Update.
6550         * lib/linebreak.c: Update.
6551         * modules/linebreak: Update.
6552         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6553         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6554         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6555         * modules/unistr/u16-mbtouc: Renamed from
6556         modules/unistr/u16-mbtouc-safe.
6557         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6558         * lib/unistr.h: Update.
6559         * lib/unistr/u16-to-u8.c: Update.
6560         * modules/unistr/u16-to-u8: Update.
6561         * lib/unistr/u16-to-u32.c: Update.
6562         * modules/unistr/u16-to-u32: Update.
6563
6564 2007-01-27  Bruno Haible  <bruno@clisp.org>
6565
6566         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6567         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6568         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6569         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6570         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6571         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6572         modules/unistr/u8-mbtouc.
6573         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6574         * lib/unistr.h: Update.
6575         * lib/striconveh.c: Update.
6576         * modules/striconveh: Update.
6577         * lib/linebreak.c: Update.
6578         * modules/linebreak: Update.
6579         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6580         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6581         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6582         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6583         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6584         * lib/unistr.h: Update.
6585         * lib/striconveh.c: Update.
6586         * modules/striconveh: Update.
6587         * lib/unistr/u8-to-u16.c: Update.
6588         * modules/unistr/u8-to-u16: Update.
6589         * lib/unistr/u8-to-u32.c: Update.
6590         * modules/unistr/u8-to-u32: Update.
6591
6592 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6593
6594         Sync from Libtool.
6595         * lib/argz.c: Do not include strings.h nor memory.h, include
6596         string.h unconditionally.  Patch by Simon Josefsson.
6597
6598 2007-01-27  Bruno Haible  <bruno@clisp.org>
6599
6600         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
6601         from gl_HEADER_STRING_H_BODY.
6602         (gl_HEADER_STRING_H_BODY): Require it.
6603         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
6604         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
6605         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
6606         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
6607         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
6608         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
6609         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
6610         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
6611         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
6612         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
6613         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
6614         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
6615         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
6616         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
6617         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6618
6619 2007-01-27  Bruno Haible  <bruno@clisp.org>
6620
6621         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
6622         check_PROGRAMS into noinst_PROGRAMS.
6623         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
6624         check_PROGRAMS in this case.
6625         (func_import): Set for_test to false.
6626         (func_create_testdir): Set for_test to true.
6627
6628 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6629             Bruno Haible  <bruno@clisp.org>
6630
6631         * modules/strcasestr (Files): Remove lib/strcasestr.h.
6632         (Depends-on): Add string.
6633         (Includes): Use <string.h> instead of strcasestr.h.
6634         * modules/string (Makefile.am): Also substitute the value of
6635         REPLACE_STRCASESTR.
6636         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
6637         assume strcasestr is declared in <string.h> not <strings.h>. Also
6638         set REPLACE_STRCASESTR.
6639         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
6640         REPLACE_STRCASESTR.
6641         * lib/strcasestr.h: Remove file.
6642         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
6643         * lib/string_.h (strcasestr): New declaration.
6644
6645 2007-01-27  Bruno Haible  <bruno@clisp.org>
6646
6647         * lib/string_.h: Use 'extern'.
6648
6649 2007-01-27  Jim Meyering  <jim@meyering.net>
6650
6651         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
6652         of set-but-not-used local, "q".
6653
6654         * lib/mempcpy.c: Include <config.h> before <string.h>.
6655         This fixes a compilation error on HP-UX, due to the system's
6656         "restrict"-using mempcpy prototype.
6657
6658 2007-01-26  Bruno Haible  <bruno@clisp.org>
6659
6660         Small optimization.
6661         * lib/javacomp.c: Include c-strstr.h.
6662          (is_envjavac_gcj): Use c_strstr instead of strstr.
6663         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
6664
6665 2007-01-26  Bruno Haible  <bruno@clisp.org>
6666
6667         * MODULES.html.sh (Unicode string functions): Add the new modules.
6668
6669         * modules/uniconv/u32-strconv-to-locale: New file.
6670         * lib/uniconv/u32-strconv-to-locale.c: New file.
6671
6672         * modules/uniconv/u16-strconv-to-locale: New file.
6673         * lib/uniconv/u16-strconv-to-locale.c: New file.
6674
6675         * modules/uniconv/u8-strconv-to-locale: New file.
6676         * lib/uniconv/u8-strconv-to-locale.c: New file.
6677
6678         * modules/uniconv/u32-strconv-from-locale: New file.
6679         * lib/uniconv/u32-strconv-from-locale.c: New file.
6680
6681         * modules/uniconv/u16-strconv-from-locale: New file.
6682         * lib/uniconv/u16-strconv-from-locale.c: New file.
6683
6684         * modules/uniconv/u8-strconv-from-locale: New file.
6685         * lib/uniconv/u8-strconv-from-locale.c: New file.
6686
6687         * modules/uniconv/u32-strconv-to-enc: New file.
6688         * lib/uniconv/u32-strconv-to-enc.c: New file.
6689         * modules/uniconv/u32-strconv-to-enc-tests: New file.
6690         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
6691
6692         * modules/uniconv/u16-strconv-to-enc: New file.
6693         * lib/uniconv/u16-strconv-to-enc.c: New file.
6694         * lib/uniconv/u-strconv-to-enc.h: New file.
6695         * modules/uniconv/u16-strconv-to-enc-tests: New file.
6696         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
6697
6698         * modules/uniconv/u8-strconv-to-enc: New file.
6699         * lib/uniconv/u8-strconv-to-enc.c: New file.
6700         * modules/uniconv/u8-strconv-to-enc-tests: New file.
6701         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
6702
6703         * modules/uniconv/u32-strconv-from-enc: New file.
6704         * lib/uniconv/u32-strconv-from-enc.c: New file.
6705         * modules/uniconv/u32-strconv-from-enc-tests: New file.
6706         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
6707
6708         * modules/uniconv/u16-strconv-from-enc: New file.
6709         * lib/uniconv/u16-strconv-from-enc.c: New file.
6710         * modules/uniconv/u16-strconv-from-enc-tests: New file.
6711         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
6712
6713         * modules/uniconv/u8-strconv-from-enc: New file.
6714         * lib/uniconv/u8-strconv-from-enc.c: New file.
6715         * lib/uniconv/u-strconv-from-enc.h: New file.
6716         * modules/uniconv/u8-strconv-from-enc-tests: New file.
6717         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
6718
6719         * modules/uniconv/u32-conv-from-enc: New file.
6720         * lib/uniconv/u32-conv-from-enc.c: New file.
6721         * modules/uniconv/u32-conv-from-enc-tests: New file.
6722         * tests/uniconv/test-u32-conv-from-enc.c: New file.
6723
6724         * modules/uniconv/u16-conv-from-enc: New file.
6725         * lib/uniconv/u16-conv-from-enc.c: New file.
6726         * lib/uniconv/u-conv-from-enc.h: New file.
6727         * modules/uniconv/u16-conv-from-enc-tests: New file.
6728         * tests/uniconv/test-u16-conv-from-enc.c: New file.
6729
6730         * modules/uniconv/u8-conv-from-enc: New file.
6731         * lib/uniconv/u8-conv-from-enc.c: New file.
6732         * modules/uniconv/u8-conv-from-enc-tests: New file.
6733         * tests/uniconv/test-u8-conv-from-enc.c: New file.
6734
6735         * modules/uniconv/base: New file.
6736         * lib/uniconv.h: New file.
6737
6738 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
6739
6740         * doc/gnulib-tool.texi (Initial import): Update to match current
6741         behavior with strdup module.
6742         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
6743         * lib/memmem.h: Remove; all uses removed.  This is now done
6744         by <string.h>.
6745         * lib/mempcpy.h: Likewise.
6746         * lib/memrchr.h: Likewise.
6747         * lib/stpcpy.h: Likewise.
6748         * lib/stpncpy.h: Likewise.
6749         * lib/strcase.h: Likewise.
6750         * lib/strchrnul.h: Likewise.
6751         * lib/strdup.h: Likewise.
6752         * lib/strndup.h: Likewise.
6753         * lib/strnlen.h: Likewise.
6754         * lib/strpbrk.h: Likewise.
6755         * lib/strsep.h: Likewise.
6756         * lib/strstr.h: Likewise.
6757         * lib/strtok_r.h: Likewise.
6758         * lib/string_.h: New file.
6759         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
6760         Rely on <string.h> instead.
6761         * lib/canon-host.c: Likewise.
6762         * lib/chdir-long.c: Likewise.
6763         * lib/concatpath.c: Likewise.
6764         * lib/exclude.c: Likewise.
6765         * lib/fchdir.c: Likewise.
6766         * lib/getaddrinfo.c: Likewise.
6767         * lib/getcwd.c: Likewise.
6768         * lib/getsubopt.c: Likewise.
6769         * lib/glob.c: Likewise.
6770         * lib/hard-locale.c: Likewise.
6771         * lib/iconvme.c: Likewise.
6772         * lib/javacomp.c: Likewise.
6773         * lib/mempcpy.c: Likewise.
6774         * lib/memrchr.c: Likewise.
6775         * lib/regex_internal.h: Likewise.
6776         * lib/stpncpy.c: Likewise.
6777         * lib/strcasecmp.c: Likewise.
6778         * lib/strchrnul.c: Likewise.
6779         * lib/strdup.c: Likewise.
6780         * lib/striconv.c: Likewise.
6781         * lib/striconveh.c: Likewise.
6782         * lib/striconveha.c: Likewise.
6783         * lib/strncasecmp.c: Likewise.
6784         * lib/strndup.c: Likewise.
6785         * lib/strnlen.c: Likewise.
6786         * lib/strsep.c: Likewise.
6787         * lib/strstr.c: Likewise.
6788         * lib/strtok_r.c: Likewise.
6789         * lib/userspec.c: Likewise.
6790         * lib/w32spawn.h: Likewise.
6791         * lib/xstrndup.c: Likewise.
6792         * lib/mountlist.c (strstr): Remove decl.
6793         * m4/string_h.m4: New file.
6794         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
6795         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
6796         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
6797         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
6798         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
6799         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
6800         Set REPLACE_STRCASECMP if necessary.
6801         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
6802         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
6803         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
6804         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
6805         HAVE_DECL_STRDUP if necessary.
6806         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
6807         since gl_FUNC_STRNDUP does that now.
6808         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
6809         Check for decl here...
6810         (gl_PREREQ_STRNLEN): ... not here.
6811         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
6812         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
6813         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
6814         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
6815         necessary.
6816         * modules/string: New file.
6817         * modules/memmem (Files): Remove special-purpose include file.
6818         (Depends-on): Add string.
6819         (Include): Include <string.h>, not the removed file.
6820         * modules/mempcpy: Likewise.
6821         * modules/memrchr: Likewise.
6822         * modules/stpcpy: Likewise.
6823         * modules/stpncpy: Likewise.
6824         * modules/strcase: Likewise.
6825         * modules/strchrnul: Likewise.
6826         * modules/strdup: Likewise.
6827         * modules/strndup: Likewise.
6828         * modules/strnlen: Likewise.
6829         * modules/strpbrk: Likewise.
6830         * modules/strsep: Likewise.
6831         * modules/strstr: Likewise.
6832         * modules/strtok_r: Likewise.
6833         * tests/test-dirname.c: Don't include "strdup.h", since
6834         <string.h> now suffices.
6835         * tests/test-memmem.c: Don't include "memmem.h", since
6836         <string.h> now suffices.
6837
6838 2007-01-25  Bruno Haible  <bruno@clisp.org>
6839
6840         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
6841         *resultp is 0.
6842
6843         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
6844         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
6845         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
6846         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
6847
6848         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
6849         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
6850         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
6851         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
6852         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
6853         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
6854
6855 2007-01-24  Bruno Haible  <bruno@clisp.org>
6856
6857         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
6858         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
6859         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
6860         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
6861         gl_FUNC_FTS_CORE.
6862         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
6863         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
6864         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
6865         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
6866         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
6867         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
6868         gl_FUNC_FCHOWNAT.
6869         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
6870         gl_FUNC_STRFTIME.
6871         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
6872         Reported by Ralf Wildenhues.
6873
6874 2007-01-24  Bruno Haible  <bruno@clisp.org>
6875
6876         Drop AC_REQUIRE calls that are redundant with the module dependencies.
6877         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
6878         gl_GETADDRINFO.
6879         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
6880         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
6881         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
6882
6883 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
6884
6885         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
6886         Don't use 'exit'; just return from 'main'.
6887         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
6888
6889         * lib/fnmatch_.h: Readjust white space and comments to match
6890         glibc, to avoid spurious diffs.
6891
6892 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6893
6894         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
6895         2004-12-01 change by Jakub Jelinek, since this code won't compile
6896         if !LIBC.  Problem reported by Bob Proulx.
6897
6898 2007-01-23  Bruno Haible  <bruno@clisp.org>
6899
6900         * lib/striconveh.c: Include c-strcaseeq.h.
6901         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
6902         * modules/striconveh (Depends-on): Add c-strcaseeq.
6903
6904 2007-01-23  Bruno Haible  <bruno@clisp.org>
6905
6906         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
6907
6908         * modules/c-strcaseeq: New file.
6909         * lib/c-strcaseeq.h: New file.
6910
6911         * modules/streq: New file.
6912         * lib/streq.h: New file.
6913
6914 2007-01-23  Bruno Haible  <bruno@clisp.org>
6915
6916         * modules/striconveha-tests: New file.
6917         * tests/test-striconveha.c: New file.
6918
6919         * lib/striconveha.h: Include <stdbool.h>.
6920         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
6921         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
6922         (mem_iconveha_notranslit): Renamed from mem_iconveha.
6923         (mem_iconveha): New function.
6924         (str_iconveha_notranslit): Renamed from str_iconveha.
6925         (str_iconveha): New function.
6926         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
6927         c-strcase.
6928
6929 2007-01-23  Bruno Haible  <bruno@clisp.org>
6930
6931         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
6932         encodings without forgiving before trying any encoding with handler.
6933         (str_iconveha): Try all encodings without forgiving before trying any
6934         encoding with handler.
6935
6936 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6937
6938         Import the following changes from libc.
6939
6940         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
6941
6942         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
6943
6944         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
6945
6946         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
6947         normal_bracket label.
6948
6949         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
6950
6951         [BZ #361]
6952         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
6953         to normal_bracket after fetching the next character.
6954
6955 2007-01-22  Bruno Haible  <bruno@clisp.org>
6956
6957         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
6958         argument.
6959         * lib/striconveh.c (iconv_carefully_1): New function.
6960         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
6961         argument.
6962         (str_cd_iconveh): Update.
6963         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
6964         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
6965         * tests/test-striconveh.c (MAGIC): New macro.
6966         (new_offsets): New function.
6967         (main): Test call with and without offsets.
6968
6969 2007-01-22  Bruno Haible  <bruno@clisp.org>
6970
6971         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
6972         * modules/sys_select (Makefile.am): Likewise.
6973         * modules/sys_socket (Makefile.am): Likewise.
6974         * modules/sys_time (Makefile.am): Likewise.
6975
6976 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
6977
6978         * modules/gettimeofday (License): Change from GPL to LGPL, since
6979         gettimeofday is a library function.
6980
6981 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6982
6983         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
6984
6985 2007-01-21  Bruno Haible  <bruno@clisp.org>
6986
6987         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
6988
6989 2007-01-21  Bruno Haible  <bruno@clisp.org>
6990
6991         * modules/striconveha: New file.
6992         * lib/striconveha.h: New file.
6993         * lib/striconveha.c: New file.
6994         * MODULES.html.sh (Internationalization functions): Add striconveha.
6995         * lib/striconv.c (str_iconv): Optimize the case of an empty input
6996         string.
6997         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
6998
6999 2007-01-21  Bruno Haible  <bruno@clisp.org>
7000
7001         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
7002         * lib/striconveh.c (str_iconveh): Likewise.
7003
7004 2007-01-21  Bruno Haible  <bruno@clisp.org>
7005
7006         * lib/striconveh.h (mem_iconveh): New declaration.
7007         * lib/striconveh.c (mem_iconveh): New function.
7008         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
7009
7010 2007-01-21  Bruno Haible  <bruno@clisp.org>
7011
7012         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
7013
7014         * lib/striconveh.h (mem_cd_iconveh): Change specification.
7015         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
7016         original result buffer.
7017         (str_cd_iconveh): Update.
7018         * tests/test-striconveh.c (main): Update.
7019
7020         * lib/striconv.h (mem_cd_iconv): Change specification.
7021         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
7022         result buffer.
7023         (str_cd_iconv): Update.
7024         * tests/test-striconv.c (main): Update.
7025
7026 2007-01-21  Bruno Haible  <bruno@clisp.org>
7027
7028         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
7029
7030 2007-01-20  Jim Meyering  <jim@meyering.net>
7031
7032         * lib/userspec.c (parse_with_separator): If a user or group string
7033         starts with "+", skip the corresponding name-to-ID look-up, since
7034         such a look-up must fail: user and group names may not include "+".
7035
7036 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
7037
7038         * lib/poll.c: Include sys/time.h and time.h unconditionally,
7039         since we now assume the sys_time module.
7040         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
7041         check for sys/time.h; no longer needed.
7042         * modules/poll (Depends-on): Depend on sys_time.
7043
7044 2007-01-18  Bruno Haible  <bruno@clisp.org>
7045
7046         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
7047         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7048
7049         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
7050         gettimeofday.
7051
7052         * tests/test-gettimeofday.c: Include <time.h>.
7053         (dummy): Remove variable.
7054
7055         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
7056         gl_HEADER_SYS_TIME_H.
7057         (gl_HEADER_SYS_TIME_H): New macro.
7058
7059         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
7060         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7061         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
7062         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
7063         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7064         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
7065         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
7066         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7067         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
7068         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
7069         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7070
7071         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
7072         last change; it caused a compilation error when cross-compiling to
7073         Cygwin.
7074
7075 2007-01-18  Jim Meyering  <jim@meyering.net>
7076
7077         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
7078         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
7079         than the race-prone "test -d sys || mkdir sys".
7080         (configure.ac): Use AC_PROG_MKDIR_P.
7081         * modules/sys_select: Likewise.
7082         * modules/sys_socket: Likewise.
7083         * modules/sys_time: Likewise.
7084
7085 2007-01-18  Eric Blake  <ebb9@byu.net>
7086
7087         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
7088         replace gettimeofday.
7089         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
7090         name, to avoid infinite recursion.
7091
7092 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
7093
7094         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
7095         module sys_time.
7096         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
7097         assume timespec.h defines struct timeval.
7098         * lib/settime.c: Likewise.
7099         * lib/utimens.c: Likewise.
7100         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
7101         since we now assume the gettimeofday module.
7102         * lib/tempname.c (__gen_tempname): Likewise.
7103         * lib/gettimeofday.h: Remove.
7104         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
7105         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
7106         Include <time.h>, for 'time()'.
7107         (localtime_buffer_addr): Also use this workaround if
7108         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
7109         to simplify the uses.  All uses changed.
7110         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
7111         that #undef is inside {}, and 'const' follows type name consistently.
7112         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
7113         (gettimeofday): Do not use the maximum possible value for
7114         tv->tv_usec, since that might break usages other than ls.c.
7115         Instead, we'll leave ls.c alone.  This undoes today's patch
7116         by Bruno.  Add a compile-time warning for 1s-clock resolution;
7117         we've never observed the problem but might as well keep the
7118         canary.
7119         * lib/nanosleep.c: Include timespec.h first, for interface check.
7120         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
7121         now assume the sys_time module.
7122         * lib/tempname.c: Likewise.
7123         * lib/timespec.h: Likewise.
7124         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
7125         needed.
7126         * lib/strftime.c: Likewise.
7127         * lib/timespec.h: Likewise.
7128         * lib/posixtm.c: Include posixtm.h first, for interface check.
7129         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
7130         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
7131         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
7132         * lib/sys_time_.h: New file.
7133         * lib/timespec.h (struct timespec): Use long int, not long.
7134         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
7135         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
7136         Remove obsolescent call to AC_HEADER_TIME.
7137         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
7138         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7139         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7140         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
7141         Likewise.
7142         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
7143         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
7144         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
7145         into the sys_time module.  Check for gettimeofday just once.
7146         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
7147         for gettimeofday signature to just check the signature.  Merely
7148         compile it, since linking doesn't test signature.  Improve test for
7149         whether gettimeofday.o is actually needed.
7150         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
7151         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
7152         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
7153         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7154         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
7155         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
7156         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
7157         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
7158         than worrying about sys/time.h.
7159         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
7160         Don't bother worrying about TIME_WITH_SYS_TIME.
7161         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
7162         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
7163         * m4/sys_time_h.m4: New file.
7164         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
7165         Don't include sys/time.h.  Return from main rather than exiting.
7166         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
7167         all uses changed.
7168         * modules/gethrxtime (Depends-on): Add sys_time.
7169         * modules/gettime (Depends-on): Likewise.
7170         * modules/gettimeofday (Depends-on): Likewise.
7171         * modules/nanosleep (Depends-on): Likewise.
7172         * modules/settime (Depends-on): Likewise.
7173         * modules/tempname (Depends-on): Likewise.
7174         * modules/utimens (Depends-on): Likewise.
7175         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
7176         (Include:) Change back to <sys/time.h>.
7177         (Maintainer:) Add self.
7178         * modules/sys_time: New file.
7179         * modules/tempname (Depends-on): Add gettimeofday.
7180         * tests/test-gettimeofday.c: Include <sys/time.h>
7181         rather than gettimeofday.h.
7182
7183 2007-01-17  Bruno Haible  <bruno@clisp.org>
7184
7185         * gnulib-tool (func_get_license): Revert last patch. Instead, let
7186         the license default to GPL.
7187         (func_create_testdir): Don't complain if a module is LGPL and its
7188         tests module depends on GPLed modules.
7189
7190 2007-01-17  Bruno Haible  <bruno@clisp.org>
7191
7192         * lib/gettimeofday.c (gettimeofday): Add code for the case
7193         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
7194         maximum possible value for tv->tv_usec, rather than the minimum one.
7195
7196 2005-10-08  Martin Lambers  <marlam@marlam.de>
7197 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7198 2007-01-16  Bruno Haible  <bruno@clisp.org>
7199
7200         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
7201         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
7202         gl_FUNC_GETTIMEOFDAY.
7203         (Include): Add gettimeofday.h.
7204         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
7205         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
7206         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
7207         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
7208         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
7209         * lib/gettimeofday.h: New file.
7210         * lib/gettimeofday.c: Include <sys/timeb.h>.
7211         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
7212         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7213         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
7214         fall back on time().
7215
7216         * tests/test-gettimeofday.c: New file.
7217         * modules/gettimeofday-tests: New file.
7218
7219 2007-01-16  Eric Blake  <ebb9@byu.net>
7220
7221         * modules/fnmatch (Depends-on): Depend on wchar.
7222         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
7223         * m4/fnmatch.m4: Likewise.
7224         * modules/mbchar (Makefile.am): Assume <wchar.h>.
7225         * m4/mbchar.m4: Likewise.
7226         * modules/mbswidth (Depends-on): Depend on wchar.
7227         * lib/mbswidth.c: Assume <wchar.h>.
7228         * m4/mbswidth.m4: Likewise.
7229         * modules/quotearg (Depends-on): Depend on wchar.
7230         * lib/quotearg.c: Assume <wchar.h>.
7231         * m4/quotearg.m4: Likewise.
7232         * modules/regex (Depends-on): Depend on wchar.
7233         * lib/regex_internal.h: Assume <wchar.h>.
7234         * m4/regex.m4: Likewise.
7235         * modules/stdint (Depends-on): Depend on wchar.
7236         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
7237         * m4/stdint.m4: Likewise.
7238         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
7239         * modules/strftime (Depends-on): Depend on wchar.
7240         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
7241         * modules/strtol (Depends-on): Depend on wchar.
7242         * lib/strtol.c: Assume <wchar.h>.
7243         * modules/wcwidth (Depends-on): Depend on wchar.
7244         * lib/wcwidth.h: Assume <wchar.h>.
7245         * m4/wcwidth.m4: Likewise.
7246
7247 2007-01-16  Bruno Haible  <bruno@clisp.org>
7248
7249         * modules/csharpexec-script: New, created from...
7250         * modules/csharpexec: ... this.
7251
7252 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
7253
7254         * modules/javaexec-script: New, created from...
7255         * modules/javaexec: ... this.
7256
7257 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7258
7259         * modules/poll (Dependencies): Add sys_select.
7260
7261 2007-01-15  Jim Meyering  <jim@meyering.net>
7262
7263         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
7264         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
7265         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
7266         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
7267
7268 2007-01-15  Bruno Haible  <bruno@clisp.org>
7269
7270         * modules/striconveh: New file.
7271         * lib/striconveh.h: New file.
7272         * lib/striconveh.c: New file.
7273         * MODULES.html.sh (Internationalization functions): Add striconveh.
7274
7275         * modules/striconveh-tests: New file.
7276         * tests/test-striconveh.c: New file.
7277
7278 2007-01-15  Bruno Haible  <bruno@clisp.org>
7279
7280         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
7281         not from GNU libiconv or GNU libc.
7282
7283 2007-01-15  Bruno Haible  <bruno@clisp.org>
7284
7285         * doc/gnulib-intro.texi (Copyright): Explain the different license
7286         terms for module descriptions, autoconf macros, tests, documentation.
7287
7288 2007-01-14  Bruno Haible  <bruno@clisp.org>
7289
7290         * modules/striconv-tests: New file.
7291         * tests/test-striconv.c: New file.
7292
7293 2007-01-14  Bruno Haible  <bruno@clisp.org>
7294
7295         * modules/iconv-tests: New file.
7296         * tests/test-iconv.c: New file.
7297
7298 2007-01-14  Bruno Haible  <bruno@clisp.org>
7299
7300         * gnulib-tool (func_get_license): For test modules, use the license of
7301         the main module.
7302
7303 2007-01-14  Bruno Haible  <bruno@clisp.org>
7304
7305         * modules/iconv (Include): Clarify that <iconv.h> can only be included
7306         if iconv is found to exist.
7307
7308 2007-01-14  Bruno Haible  <bruno@clisp.org>
7309
7310         * modules/c-ctype-tests: New file.
7311         * tests/test-c-ctype.c: New file.
7312
7313 2007-01-14  Bruno Haible  <bruno@clisp.org>
7314
7315         * modules/binary-io-tests: New file.
7316         * tests/test-binary-io.sh: New file.
7317         * tests/test-binary-io.c: New file.
7318
7319 2007-01-14  Bruno Haible  <bruno@clisp.org>
7320
7321         * modules/array-oset-tests: New file.
7322         * tests/test-array_oset.c: New file.
7323
7324 2007-01-14  Bruno Haible  <bruno@clisp.org>
7325
7326         * modules/array-list-tests: New file.
7327         * tests/test-array_list.c: New file.
7328
7329 2007-01-14  Bruno Haible  <bruno@clisp.org>
7330
7331         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
7332         and make.
7333         Reported by Simon Josefsson in
7334         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
7335
7336 2007-01-14  Bruno Haible  <bruno@clisp.org>
7337
7338         * modules/allocsa-tests: New file.
7339         * tests/test-allocsa.c: New file.
7340
7341 2007-01-14  Bruno Haible  <bruno@clisp.org>
7342
7343         * modules/fchdir (Depends-on): Add absolute-header.
7344         * modules/unistd (Depends-on): Likewise.
7345
7346 2006-12-30  Bruno Haible  <bruno@clisp.org>
7347
7348         * modules/fchdir: New file.
7349         * modules/unistd (Files): Add lib/unistd_.h.
7350         (Makefile.am): Generate unistd.h from unistd_.h.
7351         * lib/fchdir.c: New file.
7352         * lib/dirent_.h: New file.
7353         * lib/unistd_.h: New file.
7354         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
7355         * m4/fchdir.m4: New file.
7356         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
7357         (gl_HEADER_UNISTD): Invoke it.
7358         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
7359         function.
7360         * lib/backupfile.c (opendir, closedir): Undefine.
7361         * lib/chown.c (open, close): Undefine.
7362         * lib/clean-temp.c (open, close): Undefine.
7363         * lib/copy-file.c (open, close): Undefine.
7364         * lib/execute.c (open, close): Undefine.
7365         * lib/fsusage.c (open, close): Undefine.
7366         * lib/gc-gnulib.c (open, close): Undefine.
7367         * lib/getcwd.c (opendir, closedir): Undefine.
7368         * lib/glob.c (opendir, closedir): Undefine.
7369         * lib/javacomp.c (open, close): Undefine.
7370         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
7371         * lib/openat-proc.c (open, close): Undefine.
7372         * lib/pagealign_alloc.c (open, close): Undefine.
7373         * lib/pipe.c (open, close): Undefine.
7374         * lib/progreloc.c (open, close): Undefine.
7375         * lib/savedir.c (opendir, closedir): Undefine.
7376         * lib/utime.c (open, close): Undefine.
7377         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
7378
7379 2007-01-10  Bruno Haible  <bruno@clisp.org>
7380
7381         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
7382
7383 2007-01-12  Eric Blake  <ebb9@byu.net>
7384
7385         Provide a robust <wchar.h>.  Further simplifications are now
7386         possible in other modules, but not included here.
7387         * modules/wchar: New module.
7388         * m4/wchar.m4: New file.
7389         * lib/wchar_.h: Likewise.
7390         * modules/mbchar (Depends-on): Depend on wchar, as the first use
7391         of the new module.
7392         * MODULES.html.sh (Extended multibyte and wide character utilities):
7393         New section.
7394
7395 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
7396
7397         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
7398         to a reasonable default for memory allocation.
7399         (xreadlink): Don't allocate a huge buffer, to work around a buggy
7400         file system that reports garbage st_size values for symlinks.
7401         Problem reported by Liyang Hu.
7402
7403 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7404
7405         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7406         Emacs .#* auto-save files).
7407
7408 2007-01-11  Bruno Haible  <bruno@clisp.org>
7409
7410         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7411         directory.
7412
7413 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7414
7415         Use @...@ consistently in lib/wctype_.h.
7416         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7417         on it being set to 1 or 0.
7418         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7419         go back to AC_SUBSTing it.
7420         * modules/wctype (Makefile.am): Undo previous change.
7421
7422 2007-01-10  Eric Blake  <ebb9@byu.net>
7423
7424         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7425         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7426         * modules/wctype (Makefile.am): Likewise.
7427         Reported by Chris McGuire.
7428
7429 2007-01-10  Jim Meyering  <jim@meyering.net>
7430
7431         fts.c: a small readability/maintainability improvement
7432         * lib/fts.c (fts_read): Make this code slightly more readable and
7433         maintainable by hoisting the "sp->fts_cur = p" assignments to
7434         immediately follow the statements that set P.  Derived from
7435         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7436
7437 2007-01-10  Eric Blake  <ebb9@byu.net>
7438
7439         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7440         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7441         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7442         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7443         Reported by Chris McGuire.
7444
7445 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7446
7447         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7448         in sed script.
7449
7450 2007-01-09  Bruno Haible  <bruno@clisp.org>
7451
7452         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7453         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7454         variables.
7455         (func_module): Use them.
7456
7457 2007-01-09  Bruno Haible  <bruno@clisp.org>
7458
7459         * modules/unistr/base: New file.
7460         * lib/unistr.h: New file.
7461
7462         * modules/unistr/u8-to-u16: New file.
7463         * lib/unistr/u8-to-u16.c: New file.
7464
7465         * modules/unistr/u8-to-u32: New file.
7466         * lib/unistr/u8-to-u32.c: New file.
7467
7468         * modules/unistr/u16-to-u8: New file.
7469         * lib/unistr/u16-to-u8.c: New file.
7470
7471         * modules/unistr/u16-to-u32: New file.
7472         * lib/unistr/u16-to-u32.c: New file.
7473
7474         * modules/unistr/u32-to-u8: New file.
7475         * lib/unistr/u32-to-u8.c: New file.
7476
7477         * modules/unistr/u32-to-u16: New file.
7478         * lib/unistr/u32-to-u16.c: New file.
7479
7480         * modules/unistr/u8-check: New file.
7481         * modules/unistr/u16-check: New file.
7482         * modules/unistr/u32-check: New file.
7483         * lib/unistr/u8-check.c: New file.
7484         * lib/unistr/u16-check.c: New file.
7485         * lib/unistr/u32-check.c: New file.
7486
7487         * modules/unistr/u8-chr: New file.
7488         * modules/unistr/u16-chr: New file.
7489         * modules/unistr/u32-chr: New file.
7490         * lib/unistr/u8-chr.c: New file.
7491         * lib/unistr/u16-chr.c: New file.
7492         * lib/unistr/u32-chr.c: New file.
7493
7494         * modules/unistr/u8-cmp: New file.
7495         * modules/unistr/u16-cmp: New file.
7496         * modules/unistr/u32-cmp: New file.
7497         * lib/unistr/u8-cmp.c: New file.
7498         * lib/unistr/u16-cmp.c: New file.
7499         * lib/unistr/u32-cmp.c: New file.
7500
7501         * modules/unistr/u8-cpy: New file.
7502         * modules/unistr/u16-cpy: New file.
7503         * modules/unistr/u32-cpy: New file.
7504         * lib/unistr/u8-cpy.c: New file.
7505         * lib/unistr/u16-cpy.c: New file.
7506         * lib/unistr/u32-cpy.c: New file.
7507         * lib/unistr/u-cpy.h: New file.
7508
7509         * modules/unistr/u8-cpy-alloc: New file.
7510         * modules/unistr/u16-cpy-alloc: New file.
7511         * modules/unistr/u32-cpy-alloc: New file.
7512         * lib/unistr/u8-cpy-alloc.c: New file.
7513         * lib/unistr/u16-cpy-alloc.c: New file.
7514         * lib/unistr/u32-cpy-alloc.c: New file.
7515         * lib/unistr/u-cpy-alloc.h: New file.
7516
7517         * modules/unistr/u8-endswith: New file.
7518         * modules/unistr/u16-endswith: New file.
7519         * modules/unistr/u32-endswith: New file.
7520         * lib/unistr/u8-endswith.c: New file.
7521         * lib/unistr/u16-endswith.c: New file.
7522         * lib/unistr/u32-endswith.c: New file.
7523         * lib/unistr/u-endswith.h: New file.
7524
7525         * modules/unistr/u8-mblen: New file.
7526         * modules/unistr/u16-mblen: New file.
7527         * modules/unistr/u32-mblen: New file.
7528         * lib/unistr/u8-mblen.c: New file.
7529         * lib/unistr/u16-mblen.c: New file.
7530         * lib/unistr/u32-mblen.c: New file.
7531
7532         * modules/unistr/u8-mbtouc: New file.
7533         * modules/unistr/u16-mbtouc: New file.
7534         * modules/unistr/u32-mbtouc: New file.
7535         * lib/unistr/u8-mbtouc.c: New file.
7536         * lib/unistr/u16-mbtouc.c: New file.
7537         * lib/unistr/u32-mbtouc.c: New file.
7538
7539         * modules/unistr/u8-mbtouc-safe: New file.
7540         * modules/unistr/u16-mbtouc-safe: New file.
7541         * modules/unistr/u32-mbtouc-safe: New file.
7542         * lib/unistr/u8-mbtouc-safe.c: New file.
7543         * lib/unistr/u16-mbtouc-safe.c: New file.
7544         * lib/unistr/u32-mbtouc-safe.c: New file.
7545
7546         * modules/unistr/u8-move: New file.
7547         * modules/unistr/u16-move: New file.
7548         * modules/unistr/u32-move: New file.
7549         * lib/unistr/u8-move.c: New file.
7550         * lib/unistr/u16-move.c: New file.
7551         * lib/unistr/u32-move.c: New file.
7552         * lib/unistr/u-move.h: New file.
7553
7554         * modules/unistr/u8-next: New file.
7555         * modules/unistr/u16-next: New file.
7556         * modules/unistr/u32-next: New file.
7557         * lib/unistr/u8-next.c: New file.
7558         * lib/unistr/u16-next.c: New file.
7559         * lib/unistr/u32-next.c: New file.
7560
7561         * modules/unistr/u8-prev: New file.
7562         * modules/unistr/u16-prev: New file.
7563         * modules/unistr/u32-prev: New file.
7564         * lib/unistr/u8-prev.c: New file.
7565         * lib/unistr/u16-prev.c: New file.
7566         * lib/unistr/u32-prev.c: New file.
7567
7568         * modules/unistr/u8-set: New file.
7569         * modules/unistr/u16-set: New file.
7570         * modules/unistr/u32-set: New file.
7571         * lib/unistr/u8-set.c: New file.
7572         * lib/unistr/u16-set.c: New file.
7573         * lib/unistr/u32-set.c: New file.
7574         * lib/unistr/u-set.h: New file.
7575
7576         * modules/unistr/u8-startswith: New file.
7577         * modules/unistr/u16-startswith: New file.
7578         * modules/unistr/u32-startswith: New file.
7579         * lib/unistr/u8-startswith.c: New file.
7580         * lib/unistr/u16-startswith.c: New file.
7581         * lib/unistr/u32-startswith.c: New file.
7582         * lib/unistr/u-startswith.h: New file.
7583
7584         * modules/unistr/u8-stpcpy: New file.
7585         * modules/unistr/u16-stpcpy: New file.
7586         * modules/unistr/u32-stpcpy: New file.
7587         * lib/unistr/u8-stpcpy.c: New file.
7588         * lib/unistr/u16-stpcpy.c: New file.
7589         * lib/unistr/u32-stpcpy.c: New file.
7590         * lib/unistr/u-stpcpy.h: New file.
7591
7592         * modules/unistr/u8-stpncpy: New file.
7593         * modules/unistr/u16-stpncpy: New file.
7594         * modules/unistr/u32-stpncpy: New file.
7595         * lib/unistr/u8-stpncpy.c: New file.
7596         * lib/unistr/u16-stpncpy.c: New file.
7597         * lib/unistr/u32-stpncpy.c: New file.
7598         * lib/unistr/u-stpncpy.h: New file.
7599
7600         * modules/unistr/u8-strcat: New file.
7601         * modules/unistr/u16-strcat: New file.
7602         * modules/unistr/u32-strcat: New file.
7603         * lib/unistr/u8-strcat.c: New file.
7604         * lib/unistr/u16-strcat.c: New file.
7605         * lib/unistr/u32-strcat.c: New file.
7606         * lib/unistr/u-strcat.h: New file.
7607
7608         * modules/unistr/u8-strchr: New file.
7609         * modules/unistr/u16-strchr: New file.
7610         * modules/unistr/u32-strchr: New file.
7611         * lib/unistr/u8-strchr.c: New file.
7612         * lib/unistr/u16-strchr.c: New file.
7613         * lib/unistr/u32-strchr.c: New file.
7614
7615         * modules/unistr/u8-strcmp: New file.
7616         * modules/unistr/u16-strcmp: New file.
7617         * modules/unistr/u32-strcmp: New file.
7618         * lib/unistr/u8-strcmp.c: New file.
7619         * lib/unistr/u16-strcmp.c: New file.
7620         * lib/unistr/u32-strcmp.c: New file.
7621
7622         * modules/unistr/u8-strcpy: New file.
7623         * modules/unistr/u16-strcpy: New file.
7624         * modules/unistr/u32-strcpy: New file.
7625         * lib/unistr/u8-strcpy.c: New file.
7626         * lib/unistr/u16-strcpy.c: New file.
7627         * lib/unistr/u32-strcpy.c: New file.
7628         * lib/unistr/u-strcpy.h: New file.
7629
7630         * modules/unistr/u8-strcspn: New file.
7631         * modules/unistr/u16-strcspn: New file.
7632         * modules/unistr/u32-strcspn: New file.
7633         * lib/unistr/u8-strcspn.c: New file.
7634         * lib/unistr/u16-strcspn.c: New file.
7635         * lib/unistr/u32-strcspn.c: New file.
7636         * lib/unistr/u-strcspn.h: New file.
7637
7638         * modules/unistr/u8-strdup: New file.
7639         * modules/unistr/u16-strdup: New file.
7640         * modules/unistr/u32-strdup: New file.
7641         * lib/unistr/u8-strdup.c: New file.
7642         * lib/unistr/u16-strdup.c: New file.
7643         * lib/unistr/u32-strdup.c: New file.
7644         * lib/unistr/u-strdup.h: New file.
7645
7646         * modules/unistr/u8-strlen: New file.
7647         * modules/unistr/u16-strlen: New file.
7648         * modules/unistr/u32-strlen: New file.
7649         * lib/unistr/u8-strlen.c: New file.
7650         * lib/unistr/u16-strlen.c: New file.
7651         * lib/unistr/u32-strlen.c: New file.
7652         * lib/unistr/u-strlen.h: New file.
7653
7654         * modules/unistr/u8-strmblen: New file.
7655         * modules/unistr/u16-strmblen: New file.
7656         * modules/unistr/u32-strmblen: New file.
7657         * lib/unistr/u8-strmblen.c: New file.
7658         * lib/unistr/u16-strmblen.c: New file.
7659         * lib/unistr/u32-strmblen.c: New file.
7660
7661         * modules/unistr/u8-strmbtouc: New file.
7662         * modules/unistr/u16-strmbtouc: New file.
7663         * modules/unistr/u32-strmbtouc: New file.
7664         * lib/unistr/u8-strmbtouc.c: New file.
7665         * lib/unistr/u16-strmbtouc.c: New file.
7666         * lib/unistr/u32-strmbtouc.c: New file.
7667
7668         * modules/unistr/u8-strncat: New file.
7669         * modules/unistr/u16-strncat: New file.
7670         * modules/unistr/u32-strncat: New file.
7671         * lib/unistr/u8-strncat.c: New file.
7672         * lib/unistr/u16-strncat.c: New file.
7673         * lib/unistr/u32-strncat.c: New file.
7674         * lib/unistr/u-strncat.h: New file.
7675
7676         * modules/unistr/u8-strncmp: New file.
7677         * modules/unistr/u16-strncmp: New file.
7678         * modules/unistr/u32-strncmp: New file.
7679         * lib/unistr/u8-strncmp.c: New file.
7680         * lib/unistr/u16-strncmp.c: New file.
7681         * lib/unistr/u32-strncmp.c: New file.
7682
7683         * modules/unistr/u8-strncpy: New file.
7684         * modules/unistr/u16-strncpy: New file.
7685         * modules/unistr/u32-strncpy: New file.
7686         * lib/unistr/u8-strncpy.c: New file.
7687         * lib/unistr/u16-strncpy.c: New file.
7688         * lib/unistr/u32-strncpy.c: New file.
7689         * lib/unistr/u-strncpy.h: New file.
7690
7691         * modules/unistr/u8-strnlen: New file.
7692         * modules/unistr/u16-strnlen: New file.
7693         * modules/unistr/u32-strnlen: New file.
7694         * lib/unistr/u8-strnlen.c: New file.
7695         * lib/unistr/u16-strnlen.c: New file.
7696         * lib/unistr/u32-strnlen.c: New file.
7697         * lib/unistr/u-strnlen.h: New file.
7698
7699         * modules/unistr/u8-strpbrk: New file.
7700         * modules/unistr/u16-strpbrk: New file.
7701         * modules/unistr/u32-strpbrk: New file.
7702         * lib/unistr/u8-strpbrk.c: New file.
7703         * lib/unistr/u16-strpbrk.c: New file.
7704         * lib/unistr/u32-strpbrk.c: New file.
7705         * lib/unistr/u-strpbrk.h: New file.
7706
7707         * modules/unistr/u8-strrchr: New file.
7708         * modules/unistr/u16-strrchr: New file.
7709         * modules/unistr/u32-strrchr: New file.
7710         * lib/unistr/u8-strrchr.c: New file.
7711         * lib/unistr/u16-strrchr.c: New file.
7712         * lib/unistr/u32-strrchr.c: New file.
7713
7714         * modules/unistr/u8-strspn: New file.
7715         * modules/unistr/u16-strspn: New file.
7716         * modules/unistr/u32-strspn: New file.
7717         * lib/unistr/u8-strspn.c: New file.
7718         * lib/unistr/u16-strspn.c: New file.
7719         * lib/unistr/u32-strspn.c: New file.
7720         * lib/unistr/u-strspn.h: New file.
7721
7722         * modules/unistr/u8-strstr: New file.
7723         * modules/unistr/u16-strstr: New file.
7724         * modules/unistr/u32-strstr: New file.
7725         * lib/unistr/u8-strstr.c: New file.
7726         * lib/unistr/u16-strstr.c: New file.
7727         * lib/unistr/u32-strstr.c: New file.
7728         * lib/unistr/u-strstr.h: New file.
7729
7730         * modules/unistr/u8-strtok: New file.
7731         * modules/unistr/u16-strtok: New file.
7732         * modules/unistr/u32-strtok: New file.
7733         * lib/unistr/u8-strtok.c: New file.
7734         * lib/unistr/u16-strtok.c: New file.
7735         * lib/unistr/u32-strtok.c: New file.
7736         * lib/unistr/u-strtok.h: New file.
7737
7738         * modules/unistr/u8-uctomb: New file.
7739         * modules/unistr/u16-uctomb: New file.
7740         * modules/unistr/u32-uctomb: New file.
7741         * lib/unistr/u8-uctomb.c: New file.
7742         * lib/unistr/u16-uctomb.c: New file.
7743         * lib/unistr/u32-uctomb.c: New file.
7744
7745         * MODULES.html.sh (Unicode string functions): Add the new modules.
7746
7747 2007-01-08  Bruno Haible  <bruno@clisp.org>
7748
7749         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
7750         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
7751         subdirectories.
7752
7753 2007-01-08  Karl Berry  <karl@gnu.org>
7754
7755         * doc/error.texi: mention that main() fns must set program_name
7756         when progname is used.
7757
7758 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
7759
7760         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
7761         WCTYPE_H is empty, for the benefit of builds from non-distclean
7762         directories.  Problem reported by Eric Blake in
7763         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
7764
7765 2007-01-08  Bruno Haible  <bruno@clisp.org>
7766
7767         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
7768         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
7769         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
7770         PROVIDE_CANONICALIZE_FILENAME_MODE.
7771         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
7772
7773 2007-01-08  Bruno Haible  <bruno@clisp.org>
7774
7775         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
7776         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
7777         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
7778         * lib/fts.c: Likewise.
7779         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
7780
7781 2006-12-25  Bruno Haible  <bruno@clisp.org>
7782
7783         * modules/utf8-ucs4-safe: New file.
7784         * lib/utf8-ucs4-safe.h: New file.
7785         * lib/unistr/utf8-ucs4-safe.c: New file.
7786
7787         * modules/utf16-ucs4-safe: New file.
7788         * lib/utf16-ucs4-safe.h: New file.
7789         * lib/unistr/utf16-ucs4-safe.c: New file.
7790
7791         * MODULES.html.sh (Unicode string functions): Add the new modules.
7792
7793 2007-01-08  Bruno Haible  <bruno@clisp.org>
7794
7795         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
7796         (Depends-on): Add unitypes.
7797         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7798         (u8_mbtouc_aux): Move out to separate file.
7799         (u8_mbtouc): Use ucs4_t, uint8_t types.
7800         * lib/unistr/utf8-ucs4.c: New file.
7801
7802         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
7803         (Depends-on): Add unitypes.
7804         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7805         (u16_mbtouc_aux): Move out to separate file.
7806         (u16_mbtouc): Use ucs4_t, uint16_t types.
7807         * lib/unistr/utf16-ucs4.c: New file.
7808
7809         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
7810         (Depends-on): Add unitypes.
7811         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
7812         (u8_uctomb_aux): Move out to separate file.
7813         (u8_uctomb): Use ucs4_t, uint8_t types.
7814         * lib/unistr/ucs4-utf8.c: New file.
7815
7816         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
7817         (Depends-on): Add unitypes.
7818         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
7819         (u16_uctomb_aux): Move out to separate file.
7820         (u16_uctomb): Use ucs4_t, uint16_t types.
7821         * lib/unistr/ucs4-utf16.c: New file.
7822
7823 2006-12-25  Bruno Haible  <bruno@clisp.org>
7824
7825         * modules/unitypes: New file.
7826         * lib/unitypes.h: New file.
7827         * MODULES.html.sh (func_all_modules): New section "Unicode string
7828         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
7829         this section. Add unitypes.
7830
7831 2007-01-08  Bruno Haible  <bruno@clisp.org>
7832
7833         Avoid variable names that conflict with those from libtool.
7834         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
7835         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
7836         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
7837         library_names_spec to acl_library_names_spec, hardcode_* to
7838         acl_hardcode_*.
7839         Reported by Ralf Wildenhues.
7840
7841 2007-01-08  Bruno Haible  <bruno@clisp.org>
7842
7843         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
7844         definition.
7845         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
7846         definition.
7847         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
7848         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
7849         definition.
7850         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
7851         definition.
7852         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
7853         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
7854         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
7855         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
7856         definition.
7857         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
7858         definition.
7859         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
7860         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
7861         GC_USE_<algorithm>.
7862         * lib/gc-libgcrypt.c: Likewise.
7863         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
7864         * modules/gc-arctwo (configure.ac): Likewise.
7865         * modules/gc-des (configure.ac): Likewise.
7866         * modules/gc-hmac-md5 (configure.ac): Likewise.
7867         * modules/gc-hmac-sha1 (configure.ac): Likewise.
7868         * modules/gc-md2 (configure.ac): Likewise.
7869         * modules/gc-md4 (configure.ac): Likewise.
7870         * modules/gc-md5 (configure.ac): Likewise.
7871         * modules/gc-random (configure.ac): Likewise.
7872         * modules/gc-rijndael (configure.ac): Likewise.
7873         * modules/gc-sha1 (configure.ac): Likewise.
7874
7875 2007-01-08  Bruno Haible  <bruno@clisp.org>
7876
7877         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
7878         macro definition.
7879         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
7880         definition.
7881         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
7882         definition.
7883         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
7884         * modules/fcntl-safer (configure.ac): Likewise.
7885         * modules/fopen-safer (configure.ac): Likewise.
7886         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
7887         GNULIB_FWRITEERROR macro definition.
7888
7889 2007-01-08  Bruno Haible  <bruno@clisp.org>
7890
7891         * m4/gnulib-common.m4: New file.
7892         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
7893         (func_get_filelist): Add m4/gnulib-common.m4.
7894
7895 2007-01-08  Bruno Haible  <bruno@clisp.org>
7896
7897         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
7898         command.
7899
7900 2007-01-08  Jim Meyering  <jim@meyering.net>
7901
7902         Use a more robust test for a "can't happen" condition.
7903         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
7904         narrowed the st_size value.  Presuming the "can't happen" condition
7905         is true, that narrowing could conceivably convert an invalid st_size
7906         value into a valid one.  Instead, use a change based on Matthew
7907         Woehlke's original patch.
7908
7909         Slight readability improvement: use an assert-like macro
7910         in place of literal "abort ()" uses.
7911         * lib/fts.c (fts_assert): Define.
7912         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
7913         Use this macro instead of a bare 'abort'.
7914
7915 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
7916
7917         Don't worry about using IRIX 5.3's wctype.h broken definitions;
7918         simply work around them.
7919         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
7920         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
7921         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
7922         declaring.
7923         Don't bother to define as macros, since the standard doesn't require it.
7924         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
7925         longer worry about IRIX 5.3.
7926         (HAVE_WCTYPE_CTMP_BUG): Remove.
7927
7928 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
7929
7930         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
7931         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
7932         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
7933         Problems reported by Georg Schwarz for IRIX 5.3.
7934
7935         * gnulib-tool (autoconf_minversion): Take the maximum version number
7936         found, not the minimum.  Problem reported by James Youngman.
7937
7938 2007-01-03  Karl Berry  <karl@gnu.org>
7939
7940         * doc/error.texi: new file, explaining interaction with progname.
7941         * doc/gnulib.texi: include it.  Update copyright.
7942
7943 2007-01-03  Simon Josefsson  <simon@josefsson.org>
7944
7945         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
7946         AC_CANONICAL_HOST, to improve autobuild outputs.
7947
7948 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
7949             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
7950
7951         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
7952         sockets, server sockets, and other file descriptors.  Count errors
7953         to compute the return value.  Reorder the code a bit to be easier
7954         to follow.  Don't set event bits that were not requested (except
7955         POLLERR and POLLHUP).
7956
7957 2007-01-01  Bruno Haible  <bruno@clisp.org>
7958
7959         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
7960
7961 2007-01-03  Jim Meyering  <jim@meyering.net>
7962
7963         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
7964
7965 2007-01-02  Bruno Haible  <bruno@clisp.org>
7966
7967         * modules/settime (Include): Require timespec.h.
7968         * modules/nanosleep (Include): Likewise.
7969
7970 2007-01-01  Bruno Haible  <bruno@clisp.org>
7971
7972         * gnulib-tool (func_emit_copyright_notice): Bump year.
7973         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
7974
7975 2007-01-01  Bruno Haible  <bruno@clisp.org>
7976
7977         Improve support for OpenBSD.
7978         * build-aux/config.rpath (libname_spec): Export.
7979         (library_names_spec): New variable. Export.
7980         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
7981         library_names_spec from the config.rpath output. Locate shared library
7982         through the name pattern in library_names_spec.
7983
7984 2007-01-01  Eric Blake  <ebb9@byu.net>
7985
7986         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
7987
7988 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
7989
7990         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
7991         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
7992         assume the C locale, and avoid an "eval" that could cause trouble.
7993         Problem with SORT reported by Bob Proulx.
7994
7995         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
7996         Define.  Trivial patch from Henning Nielsen Lund, originally
7997         sent to bug-grep@gnu.org today.
7998
7999 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
8000
8001         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
8002         struct stat.  Problem reported by Henning Nielsen Lund.
8003         * lib/acl.c: Include acl.h first, to check interface.  Don't
8004         bother to include sys/types.h and sys/stat.h again.
8005
8006 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
8007
8008         Import the following change from libc; problem reported by
8009         Sven Verdoolaege.
8010
8011         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
8012
8013         [BZ #1373]
8014         * lib/argp.h: Remove __NTH for __argp_usage inline function.
8015
8016 2006-12-28  Jim Meyering  <jim@meyering.net>
8017
8018         * build-aux/announce-gen: Do not assume that the package
8019         builds any of tar.gz, tar.bz2, and .xdelta files.
8020         Suggestion from Simon Josefsson.
8021
8022 2006-12-28  Simon Josefsson  <simon@josefsson.org>
8023
8024         * modules/announce-gen: New file.
8025
8026 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
8027
8028         * lib/mbchar.h: Just include <wctype.h>; the wctype module
8029         handles its gotchas now.
8030         * lib/mbswidth.c: Likewise.
8031         * lib/wcwidth.h: Likewise.
8032         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
8033         and iswcntrl; the wctype module does this stuff now.
8034         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8035         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
8036         * modules/mbchar (Depends-on): Add wctype.
8037         * modules/mbswidth (Depends-on): Likewise.
8038         * modules/wcwidth (Depends-on): Likewise.
8039
8040 2006-12-27  Eric Blake  <ebb9@byu.net>
8041
8042         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
8043         module uses more than what <wctype.h> is required to provide.
8044
8045 2006-12-26  Eric Blake  <ebb9@byu.net>
8046
8047         * gnulib-tool (sed_extract_prog): Avoid space-tab.
8048
8049 2006-12-26  Eric Blake  <ebb9@byu.net>
8050
8051         * modules/absolute-header: New module.
8052         * modules/fcntl (Depends-on): Depend on it.
8053         * modules/inttypes (Depends-on): Likewise.
8054         * modules/stdint (Depends-on): Likewise.
8055         * modules/sys_stat (Depends-on): Likewise.
8056         * modules/wctype (Depends-on): Likewise.
8057         * MODULES.html.sh (Support for building libraries and
8058         executables): Document it.
8059
8060 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
8061
8062         * gnulib-tool (SED): Remove, undoing previous change.
8063         The problem was that it broke coreutils on Solaris, because
8064         "sed --posix" leaked into a makefile.
8065         (sed): New alias, if 'alias' and GNU sed.
8066
8067 2006-12-24  Jim Meyering  <jim@meyering.net>
8068
8069         Work around an fchownat bug in glibc-2.4:
8070         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
8071         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
8072         in spite of the -P option.
8073         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
8074         New macros.
8075         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
8076         * modules/openat (Files): Add lib/fchownat.c.
8077         * lib/openat.c (fchownat): Don't define here.  Move to...
8078         * lib/fchownat.c: ...this new file.
8079
8080 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
8081
8082         Fix bug reported by Bruno Haible in
8083         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
8084         where quotearg.c didn't compile on Mac OS X 10.2 because it
8085         lacks <wchar.h> and wint_t.
8086         * lib/wctype_.h (__wctype_wint_t): New type.
8087         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
8088         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
8089         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
8090         Arg is now of type __wctype_wint_t, not wint_t.
8091         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
8092         substitute HAVE_WINT_T.
8093         * modules/wctype (Files): Add m4/wint_t.m4.
8094         (wctype.h): Substitute HAVE_WINT_T.
8095
8096 2006-12-23  Bruno Haible  <bruno@clisp.org>
8097
8098         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
8099
8100 2006-12-23  Bruno Haible  <bruno@clisp.org>
8101
8102         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
8103         S_ISLNK.
8104         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
8105         mingw.
8106
8107 2006-12-22  Bruno Haible  <bruno@clisp.org>
8108
8109         * lib/copy-file.c: Include acl.h.
8110         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
8111         Close the file descriptors only after being done with copy_acl.
8112         * modules/copy-file (Depends-on): Add acl.
8113
8114 2006-12-22  Bruno Haible  <bruno@clisp.org>
8115
8116         * gnulib-tool (SED): New variable.
8117         Use $SED instead of sed everywhere.
8118
8119 2006-12-22  Bruno Haible  <bruno@clisp.org>
8120
8121         * modules/no-c++: New file.
8122         * m4/no-c++.m4: New file.
8123         * MODULES.html.sh (Support for building libraries and executables):
8124         Add no-c++.
8125
8126 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
8127
8128         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8129         Include <limits.h>, and use its INT_MAX to rewrite the
8130         j loop so that it does not overflow 'int'.  Problem reported by
8131         Ralf Wildenhues in
8132         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
8133         Play it safe by shifting left by 1 rather than multiplying by 2,
8134         as GCC is less likely to optimize this away when the value
8135         is signed (when it assumes overflow leads to undefined behavior).
8136         Also, don't assume time_t uses two's complement.
8137
8138 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
8139
8140         * MODULES.html.sh: New module wctype.
8141         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
8142         * lib/fnmatch.c: Don't bother to include <wchar.h> before
8143         <wctype.h>, since the new wctype module should fix this.
8144         * lib/quotearg.c: Include <wctype.h> unconditionally, since
8145         the wctype module should arrange for it.
8146         * lib/regex_internal.h: Likewise.
8147         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
8148         since the wctype module should handle this now.
8149         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
8150         * modules/fnmatch (Depends-on): Add wctype.
8151         * modules/quotearg (Depends-on): Likewise.
8152         * modules/regex (Depends-on): Likewise.
8153
8154 2006-12-19  Bruno Haible  <bruno@clisp.org>
8155
8156         * lib/strdup.h [C++]: Wrap definitions in extern "C".
8157         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
8158
8159 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8160
8161         * modules/savewd (Depends-on): Fix dependency on fcntl.
8162
8163 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8164
8165         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
8166         conforms to C99, rather than relying on the user's environment
8167         setting of STDINT_H.
8168
8169 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8170         and Eric Blake  <ebb9@byu.net>
8171
8172         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
8173         This is more consistent with the other defines here.
8174         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
8175         Port to z/OS.  Problem reported by Paul Gilmartin.
8176         Change local vars to use gl_ prefix rather than ac_.
8177         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
8178         with other defines.
8179         * modules/double-slash-root: New module.
8180         * modules/dirname (Files): Remove m4/double-slash-root.m4.
8181         (Depends-on): Add double-slash-root.
8182         * MODULES.html.sh (File system functions): Mention new module.
8183
8184 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
8185
8186         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
8187         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
8188         This is for the benefit of gzip, which doesn't do i18n.
8189
8190 2006-12-12  Jim Meyering  <jim@meyering.net>
8191
8192         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
8193         Reported by Andreas Schwab <schwab@suse.de>.
8194
8195 2006-12-12  Bruno Haible  <bruno@clisp.org>
8196
8197         Merge these changes.
8198         2006-09-05  Bruno Haible  <bruno@clisp.org>
8199         * lib/iconvme.c (iconv_string): No need to save and restore errno when
8200         iconv_alloc succeeded.
8201         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
8202         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
8203         test for " && dest " at the end - dest is always != NULL there. Call
8204         iconv with 4xNULL arguments initially, to reset the state. Call iconv
8205         with 2xNULL arguments, also to flush the state storage. Handle the
8206         IRIX iconv behaviour. Realloc the final result, to throw away unused
8207         memory.
8208
8209 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
8210
8211         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
8212         and fchmodat unconditionally, since glibc 2.4 has them.
8213         Problem reported by Arkadiusz Miskiewicz.
8214
8215 2006-12-10  Bruno Haible  <bruno@clisp.org>
8216
8217         * gnulib-tool (func_import): Show the include files only for those
8218         modules that are copied and specified.
8219         Reported by Karl Berry.
8220
8221 2006-12-08  Jim Meyering  <jim@meyering.net>
8222
8223         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
8224         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
8225
8226         * build-aux/announce-gen: Add two new options, both optional:
8227         --bootstrap-tools=TOOL_LIST
8228               a comma-separated list of tools, e.g.,
8229               autoconf,automake,bison,gnulib
8230         --gnulib-snapshot-date=DATE
8231               if gnulib is in the bootstrap tool list,
8232               then report this as the snapshot date.
8233               If not specified, use the current date/time.
8234               If you specify a date here, be sure it's UTC.
8235
8236 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8237
8238         * tests/test-argp-2.sh: Fix test to match actual output.
8239         (func_compare): Fix sed script to be portable.
8240
8241 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
8242
8243         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
8244         workaround for this case.  It is not autoconfigured now; offhand
8245         it's hard to see how to autoconfigure it.
8246
8247 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
8248
8249         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
8250         a directory that is about to be chowned.  Such a directory's
8251         initial file permissions should permit the owner only and this
8252         should not be changed until after the chown, since the group and
8253         other bits would be incorrect if they granted permission before
8254         the chown.
8255
8256         Fix porting problem for iswctype reported by Georg Schwarz in:
8257         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
8258         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
8259         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
8260         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
8261         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
8262
8263 2006-12-03  Jim Meyering  <jim@meyering.net>
8264
8265         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
8266         p->fts_statp may not yet be defined.
8267         (fts_read): Instead, set it in the caller, once p->fts_statp is
8268         sure to be defined, and corresponds to a top-level directory.
8269         This bug made du -x fail.  Here's the coreutils test case:
8270         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
8271         Reported by Mike Frysinger.
8272
8273 2006-12-01  Jim Meyering  <jim@meyering.net>
8274
8275         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
8276         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
8277         Reported by Simon Josefsson.
8278
8279 2006-11-30  Jim Meyering  <jim@meyering.net>
8280
8281         * m4/warning.m4: Use the all-permissive copyright notice
8282         recommended by RMS (rather than LGPL).
8283         * m4/vararrays.m4: Likewise.
8284         * m4/flexmember.m4: Likewise.
8285
8286 2006-11-29  Bruno Haible  <bruno@clisp.org>
8287
8288         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8289         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
8290         using +=.
8291         Reported by Simon Josefsson <simon@josefsson.org>.
8292
8293 2006-11-28  James Youngman <jay@gnu.org>
8294
8295         * README: Advise users that they might find the bug-gnulib@gnu.org
8296         and autotools-announce@gnu.org mailing lists useful.
8297
8298 2006-11-28  Bruno Haible  <bruno@clisp.org>
8299
8300         * m4/ptrdiff_max.m4: Remove file.
8301
8302 2006-11-21  Bruno Haible  <bruno@clisp.org>
8303
8304         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
8305         _AC_COMPUTE_INT.
8306         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8307         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
8308         _AC_COMPUTE_INT.
8309         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8310         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
8311         _AC_COMPUTE_INT.
8312         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8313
8314 2006-11-28  Jim Meyering  <jim@meyering.net>
8315
8316         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
8317         warning from "gcc -Wshadow" about shadowing the builtin.
8318
8319 2006-11-27  Bruno Haible  <bruno@clisp.org>
8320
8321         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
8322         _AC_COMPUTE_INT.
8323         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8324
8325 2006-11-27  Bruno Haible  <bruno@clisp.org>
8326             Paul Eggert  <eggert@cs.ucla.edu>
8327
8328         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
8329
8330 2006-11-26  Bruno Haible  <bruno@clisp.org>
8331
8332         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8333         noinst_LTLIBRARIES.
8334
8335 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
8336             Bruno Haible  <bruno@clisp.org>
8337
8338         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
8339         if compiling with "gcc -ansi".
8340
8341 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
8342
8343         Fix some incompatibilities with gcc -ansi -pedantic.
8344         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
8345         if compiling pedantically with GCC, unless it's C99 or later.
8346         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
8347         it mishandles gcc -ansi -pedantic as well.
8348         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
8349         if gcc -pedantic.
8350         * lib/regexec.c (check_node_accept_bytes): Don't use auto
8351         initializers for struct if -pedantic, unless it's C99 or later.
8352
8353 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
8354
8355         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
8356         Don't close an fd more than once. Identical atimes indicate
8357         success, not failure.
8358
8359 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
8360
8361         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
8362
8363 2006-11-23  Jim Meyering  <jim@meyering.net>
8364
8365         * build-aux/announce-gen: New file.  From coreutils.
8366
8367 2006-11-22  Jim Meyering  <jim@meyering.net>
8368
8369         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
8370         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
8371         (fts_read): Use a temporary to narrow the overused st_size member
8372         before using it in a switch statement.  Reported by Matthew Woehlke.
8373
8374         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
8375         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
8376
8377 2006-11-20  Bruno Haible  <bruno@clisp.org>
8378
8379         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
8380         changequote instead of pairs of brackets.
8381         Reported by Andreas Schwab <schwab@suse.de>.
8382
8383 2006-11-21  Jim Meyering  <jim@meyering.net>
8384
8385         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
8386         so as to remain compatible with older compilers.
8387         Patch from Michael Deutschmann.
8388
8389 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8390
8391         * MODULES.html.sh (File system functions): Add openat.
8392
8393         * lib/openat.h (rpl_fstatat): New macro, if
8394         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
8395         (fstatat): Define to rpl_fstatat under the same conditions,
8396         unless COMPILING_FSTATAT.
8397         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
8398         seems to have the bug.
8399         * lib/fstatat.c: New file.
8400         * modules/openat (Files): Add it.
8401
8402 2006-11-20  Bruno Haible  <bruno@clisp.org>
8403
8404         * Makefile: New file.
8405
8406 2006-11-20  Jim Meyering  <jim@meyering.net>
8407
8408         The beginnings of syntax-related checks for gnulib.
8409         * lib/Makefile: New file.
8410         * lib/t-idcache: New script.  Ensure that the two halves of
8411         idcache.c stay in sync.
8412
8413         * lib/idcache.c: Adjust comments in user- and group- portions to
8414         be more accurate, and to be consistent with one another.
8415
8416 2006-11-20  Jim Meyering  <jim@meyering.net>
8417
8418         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8419         continue using the flexible array member (thus, this module performs
8420         half as many malloc calls), with the addition that...
8421         (getgroup, getuser): Consistently record a non-match via an empty
8422         "name" string, and map an empty string match to a NULL return value.
8423         * modules/idcache (Depends-on): Re-add flexmember.
8424
8425         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8426         (getuidbyname, getgroup, getgidbyname): Likewise.
8427
8428         Use cleaner syntax: NULL rather than 0.
8429         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8430
8431 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8432
8433         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8434         It mishandled the case where the group was missing.
8435         Problem reported by Greg Schafer.
8436         * modules/idcache: Likewise.
8437
8438 2006-11-18  Jim Meyering  <jim@meyering.net>
8439
8440         * check-module (%exempt_header): Add exception for some
8441         conditionally-included headers.
8442
8443         * modules/i-ring (Depends-on): Add verify.
8444         (License): Change to LGPL.
8445
8446 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8447
8448         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8449         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8450         and inttostr.h.  Use snprintf rather than uinttostr, so that
8451         LGPLed code doesn't depend on GPLed.
8452
8453 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8454
8455         * modules/inline (License): Change from GPL to LGPL.
8456
8457 2006-11-17  Jim Meyering  <jim@meyering.net>
8458
8459         * modules/d-type (License): Switch to LGPL.
8460
8461 2006-11-15  Bruno Haible  <bruno@clisp.org>
8462
8463         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8464
8465 2006-11-15  Eric Blake  <ebb9@byu.net>
8466
8467         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8468         the module dependency.
8469
8470 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8471             Bruno Haible  <bruno@clisp.org>
8472
8473         * gnulib-tool (func_create_testdir): Add license consistency check.
8474
8475 2006-11-15  Eric Blake  <ebb9@byu.net>
8476
8477         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8478         random "(cached)" in configure output.
8479
8480 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8481
8482         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8483         test for conforming inttypes.h is both announced and cached.
8484
8485         * MODULES.html.sh (seen_modules, seen_files): New variables.
8486         (func_module): Rewrite to use a few less gnulib-tool and sed
8487         invocations.  Avoid a couple of quadratic algorithms for ...
8488         (missed_modules, missed_files): ... these, with ...
8489         (func_append, func_tmpdir): ... these new functions, from
8490         gnulib-tool.  Analogously, install traps for cleanup.
8491
8492         * tests/test-gc.c (main): Remove unused variables.
8493         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8494
8495 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8496
8497         * modules/inttostr (License): Change to LGPL.
8498
8499 2006-11-14  Eric Blake  <ebb9@byu.net>
8500
8501         * modules/tempname (License): Change to LGPL.
8502
8503 2006-11-14  Eric Blake  <ebb9@byu.net>
8504
8505         * doc/functions.texi (Function Portability): *printf functions on
8506         Cygwin now understand all POSIX size specifiers.
8507
8508 2006-11-14  Bruno Haible  <bruno@clisp.org>
8509
8510         * modules/c-ctype (License): Change to LGPL.
8511
8512 2006-11-12  Bruno Haible  <bruno@clisp.org>
8513
8514         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8515         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8516         for GNOME libraries, for which the include files are installed in
8517         subdirectories of $prefix/include.
8518
8519 2006-11-12  Bruno Haible  <bruno@clisp.org>
8520
8521         * m4/lib-link.m4: Require at least autoconf-2.54.
8522         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8523         name to underscores for the --with option.
8524
8525 2006-11-13  Bruno Haible  <bruno@clisp.org>
8526
8527         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8528         the tests directory.
8529         Reported by Ralf Wildenhues.
8530
8531 2006-11-13  Bruno Haible  <bruno@clisp.org>
8532
8533         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8534         (func_emit_initmacro_end): Undo the override here.
8535         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8536         Works around the famous automake error in coreutils.
8537
8538 2006-11-13  Eric Blake  <ebb9@byu.net>
8539
8540         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8541         element, not its node.
8542
8543 2006-11-12  Bruno Haible  <bruno@clisp.org>
8544
8545         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8546         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8547
8548 2006-11-12  Bruno Haible  <bruno@clisp.org>
8549
8550         * gnulib-tool: New option --local-symlink.
8551         (func_usage): Document it.
8552         (lsymbolic): New variable.
8553         (func_import, func_create_testdir): If --symlink was not specified,
8554         test whether --local-symlink was specified and the file comes from
8555         the local_gnulib_dir.
8556
8557 2006-11-12  Bruno Haible  <bruno@clisp.org>
8558
8559         * gnulib-tool (func_ln): New function.
8560         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8561
8562 2006-11-12  Bruno Haible  <bruno@clisp.org>
8563
8564         Finish support for source files in subdirectories.
8565         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8566         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8567         AUTOMAKE_OPTIONS.
8568         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8569
8570 2006-11-12  Bruno Haible  <bruno@clisp.org>
8571
8572         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8573         EXTRA_lib_SOURCES augmentation.
8574         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8575
8576 2006-11-12  Jim Meyering  <jim@meyering.net>
8577
8578         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8579         file descriptors.  This also averts a failure on systems with
8580         native openat support when a traversed directory lacks "x" access.
8581         * lib/fts_.h: Include "i-ring.h"
8582         (struct FTS) [fts_fd_ring]: New member.
8583         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8584         (FCHDIR): Add parentheses.
8585         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
8586         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
8587         When descending, rather than simply closing the previous
8588         fts_cwd_fd value, push that file descriptor onto the ring.
8589         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
8590         (fts_open): Initialize the new fd_ring member.
8591         (fts_close): Clear the ring.
8592         (fts_safe_changedir): When possible, use our new fd_ring to skip
8593         the diropen and fstat and dev/ino comparison that would normally
8594         accompany a virtual `chdir ("..")'.
8595
8596         * modules/fts (Depends-on): Add i-ring.
8597         * modules/i-ring: New module.
8598         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
8599         * m4/i-ring.m4: New file.
8600
8601 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8602
8603         * gnulib-tool (func_create_testdir): Fix replacement of
8604         `build-aux' in configure.ac.  Run autotools in gltests
8605         subdirectory.
8606         (func_create_testdir, func_create_megatestdir, test): There is
8607         no need for '--force' in most autotool invocations in a new
8608         tree.  Actually fail the whole test if any of the tools, or the
8609         configure or make stages fail.
8610
8611         Sync from Automake.
8612         * build-aux/gnupload: Revert last change.  Add pointer to upload
8613         instructions of the GNU Maintenance Instructions.
8614         Suggestion by Karl Berry.
8615
8616 2006-11-10  Jim Meyering  <jim@meyering.net>
8617
8618         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
8619
8620 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8621
8622         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
8623         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
8624         (bind_textdomain_codeset) [! ENABLE_NLS]:
8625         Evaluate all the arguments.  That way, callers get compatible behavior
8626         if the arguments have side effects.  Also, it avoids some GCC
8627         diagnostics in some cases; Joel E. Denny reported problems when Bison
8628         was configured with --enable-gcc-warnigs.
8629
8630 2006-11-10  Jim Meyering  <jim@meyering.net>
8631
8632         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
8633         relevant options in CFLAGS (like -O, -fno-inline) are taken into
8634         account.
8635
8636 2006-11-10  Jim Meyering  <jim@meyering.net>
8637
8638         * modules/inline: New file/module.
8639         * modules/xalloc (Files): Remove m4/inline.m4.
8640         (Depends-on): Add inline, instead.
8641         * modules/oset: Likewise.
8642         * modules/list: Likewise.
8643
8644 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8645
8646         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
8647         Problem reported by Matthew Woehlke.
8648
8649 2006-11-09  Bruno Haible  <bruno@clisp.org>
8650
8651         * lib/tempname.c (gen_tempname): Remove variant that invokes
8652         __gen_tempname.
8653         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
8654         __gen_tempname.
8655
8656 2006-11-08  Bruno Haible  <bruno@clisp.org>
8657
8658         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
8659         to 'yes' instead of 'cross-compiling'.
8660
8661 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
8662
8663         * lib/quotearg.h (quotearg_free): New decl.
8664         * lib/quotearg.c (quotearg_free): New function.
8665         (slot0, nslots, slotvec0, slotvec):
8666         Now file-scope so that quotearg_free can get at them.
8667
8668 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8669
8670         Sync from Automake.
8671         * build-aux/gnupload: Add missing 'gnu' to example URL.
8672         Report by Karl Berry.
8673
8674 2006-11-08  Bruno Haible  <bruno@clisp.org>
8675
8676         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
8677         Suggested by Paul Eggert.
8678
8679 2006-11-08  Jim Meyering  <jim@meyering.net>
8680
8681         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
8682         It's already included if !_LIBC.
8683         (fts_safe_changedir): Add a comment.
8684
8685 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8686
8687         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
8688         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
8689         Matthew Woehlke.
8690
8691         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
8692         definitions up, to avoid colliding with change below.
8693         (static_inline) [HAVE_INLINE]: New macro.
8694         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
8695         Provide extern decls when !HAVE_INLINE.  Do not define unless
8696         static_inline is defined, either by us or by xmalloc.c.  Use
8697         static_inline rather than static inline.
8698         (XCALLOC): Optimize sizeof(T) = 1 case.
8699         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
8700
8701 2006-11-07  Bruno Haible  <bruno@clisp.org>
8702
8703         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
8704         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
8705         AC_C_INLINE.
8706         * modules/xalloc (Files): Add m4/inline.m4.
8707
8708 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8709
8710         * README: Fix typo.
8711         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
8712         (Miscellanous Notes): ...from this.
8713
8714 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8715
8716         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
8717         Mention that offsetof should be used instead of sizeof.
8718         From Bruno Haible.
8719
8720 2006-11-07  Bruno Haible  <bruno@clisp.org>
8721
8722         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
8723
8724 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8725
8726         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8727         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
8728         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8729         (gl_tree_add_before, gl_tree_add_after):
8730         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
8731         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
8732         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
8733         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
8734         (gl_linked_add_after, gl_linked_add_at): Likewise.
8735         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
8736         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8737         (gl_tree_add_before, gl_tree_add_after): Likewise.
8738         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
8739         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
8740         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
8741
8742 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8743
8744         * lib/gl_oset.h: Use C comment style, not C++ comment style.
8745
8746 2006-11-06  Bruno Haible  <bruno@clisp.org>
8747
8748         * m4/inline.m4: New file.
8749         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
8750         * modules/list (Files): Add m4/inline.m4.
8751         * modules/oset (Files): Likewise.
8752
8753 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8754
8755         * lib/idcache.c: Include <stddef.h>, for offsetof.
8756         (struct userid.name): Change from char * to a flexible array member.
8757         All uses changed.
8758         * modules/idcache (Depends-on): Add flexmember.
8759
8760         * MODULES.html.sh (Core language properties): New module flexmember.
8761         * modules/flexmember, m4/flexmember.m4: New files.
8762
8763         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
8764         inline functions that are identical with the old xnmalloc_inline,
8765         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
8766         that we can avoid some unnecessary integer multiplications and
8767         divisions in the common case where the element size is known at
8768         compile time.
8769         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
8770         needed.
8771         (xnboundedmalloc): Remove.
8772         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
8773         arguments, for consistency with rest of this header.
8774         (xcharalloc): Rewrite using XNMALLOC.
8775         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
8776         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
8777         versions have been moved to lib/xalloc.h and renamed to be the
8778         non-*_inline versions.
8779         (xmalloc, xrealloc): Implement without reference to the xnmalloc
8780         and xnrealloc functions, since those functions are now inline and
8781         now call us.
8782         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
8783         renaming described above.
8784         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
8785         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
8786         captures the dependency in AC_C_INLINE.
8787
8788         New module canonicalize-lgpl, proposed by Charles Wilson in
8789         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
8790         with a few small changes afterwards.
8791         * MODULES.html.sh (File system functions): New module
8792         canonicalize-lgpl.
8793         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
8794         and canonicalize_file_name.
8795         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
8796         * modules/canonicalize-lgpl: New files.
8797
8798 2006-11-05  Bruno Haible  <bruno@clisp.org>
8799
8800         * gnulib-tool (func_import, func_create_testdir): Create directories
8801         also for files in subdirectories of lib/.
8802
8803 2006-11-05  Bruno Haible  <bruno@clisp.org>
8804
8805         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
8806         ANSI C compliant.
8807
8808 2006-11-03  Bruno Haible  <bruno@clisp.org>
8809
8810         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8811         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
8812         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
8813         (xnboundedmalloc): New inline function.
8814         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
8815         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
8816         xmalloc.
8817         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
8818         xmalloc.
8819         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
8820         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
8821         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
8822         xmalloc.
8823         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8824         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
8825         xmalloc.
8826         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
8827         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8828         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
8829         xmalloc.
8830         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8831         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
8832         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8833         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
8834         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
8835         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
8836         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
8837
8838 2006-11-03  Bruno Haible  <bruno@clisp.org>
8839
8840         * lib/c-ctype.h [C++]: Define functions without name mangling.
8841         * lib/fwriteerror.h [C++]: Likewise.
8842         * lib/gcd.h [C++]: Likewise.
8843         * lib/linebreak.h [C++]: Likewise.
8844
8845 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
8846
8847         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
8848         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
8849         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
8850         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8851         Check for functions and headers just once.
8852         Check for declaration of canonicalize_file_name.
8853         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
8854
8855 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8856
8857         * gnulib-tool (func_import): Fix typo in actioncmd.
8858
8859 2006-11-02  Bruno Haible  <bruno@clisp.org>
8860
8861         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
8862         newline sequence in the Makefile.am snippet as a space, like "make"
8863         does.
8864         Reported by Roger Persson <perrog@gmail.com>.
8865
8866 2006-11-01  Bruno Haible  <bruno@clisp.org>
8867
8868         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
8869         already declared in <string.h>.
8870         * lib/strcase.h (strncasecmp): Don't declare it if yes.
8871
8872 2006-11-01  Bruno Haible  <bruno@clisp.org>
8873
8874         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
8875         * lib/strcase.h: Include <string.h>.
8876         (strcasecmp): Define to rpl_strcasecmp here.
8877
8878 2006-11-01  Bruno Haible  <bruno@clisp.org>
8879
8880         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
8881
8882 2006-11-01  Eric Blake  <ebb9@byu.net>
8883
8884         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
8885
8886         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
8887
8888 2006-10-29  Bruno Haible  <bruno@clisp.org>
8889
8890         Make it compile in C++ mode.
8891         * lib/full-write.c (full_rw): Add a cast.
8892
8893 2006-11-01  Bruno Haible  <bruno@clisp.org>
8894
8895         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
8896         be POSIX compliant.
8897         Reported by Roger Persson <perrog@gmail.com>.
8898
8899 2006-11-01  Eric Blake  <ebb9@byu.net>
8900
8901         * lib/getopt_.h: Fix comments.
8902
8903 2006-10-31  Eric Blake  <ebb9@byu.net>
8904
8905         * modules/tmpdir (Depends-on): Add sys_stat.
8906         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
8907         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
8908         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
8909         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
8910         tempname.
8911
8912 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
8913
8914         Avoid some C++ diagnostics reported by Bruno Haible.
8915         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
8916         xmalloc.
8917         (quotearg_alloc): Use xcharalloc rather than xmalloc.
8918         (struct slotvec): Move to top level.
8919         (quotearg_n_options): Rewrite to avoid xmalloc.
8920         * lib/xalloc.h (xcharalloc): New function.
8921         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
8922         [defined __cplusplus]: Add function template that provides result
8923         type propagation.  This part of the change is from Bruno Haible.
8924
8925 2006-10-29  Bruno Haible  <bruno@clisp.org>
8926
8927         Make it compile in C++ mode.
8928         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
8929         * lib/strnlen1.c (strnlen1): Cast memchr result.
8930         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
8931         * lib/clean-temp.c (string_equals, string_hash): Add casts.
8932         (create_temp_dir): Rename local variable 'template'.
8933         (compile_csharp_using_sscli): Add cast.
8934         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
8935         * lib/findprog.c (find_in_path): Likewise.
8936         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
8937         * lib/wait-process.c (register_slave_subprocess): Likewise.
8938
8939 2006-10-22  Bruno Haible  <bruno@clisp.org>
8940
8941         * modules/tsearch: New file.
8942         * lib/tsearch.h: New file.
8943         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
8944         * m4/tsearch.m4: New file.
8945         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
8946
8947 2006-10-29  Eric Blake  <ebb9@byu.net>
8948
8949         * lib/arcfour.c: Assume config.h.
8950         * lib/arctwo.c: Likewise.
8951         * lib/base64.c: Likewise.
8952         * lib/check-version.c: Likewise.
8953         * lib/crc.c: Likewise.
8954         * lib/des.c: Likewise.
8955         * lib/gc-gnulib.c: Likewise.
8956         * lib/gc-libgcrypt.c: Likewise.
8957         * lib/gc-pbkdf2-sha1.c: Likewise.
8958         * lib/getaddrinfo.c: Likewise.
8959         * lib/getdelim.c: Likewise.
8960         * lib/getline.c: Likewise.
8961         * lib/hmac-md5.c: Likewise.
8962         * lib/hmac-sha1.c: Likewise.
8963         * lib/iconvme.c: Likewise.
8964         * lib/md2.c: Likewise.
8965         * lib/md4.c: Likewise.
8966         * lib/memxor.c: Likewise.
8967         * lib/read-file.c: Likewise.
8968         * lib/readline.c: Likewise.
8969         * lib/rijndael-alg-fst.c: Likewise.
8970         * lib/rijndael-api-fst.c: Likewise.
8971         * lib/xgetdomainname.c: Likewise.
8972
8973 2006-10-28  Eric Blake  <ebb9@byu.net>
8974
8975         * lib/xstrndup.c: Assume config.h.
8976
8977 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8978
8979         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
8980         stat-macros.h is now for our own macros, whereas stat_h is for
8981         macros in the <sys/stat.h> name space.
8982         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
8983         (STAT_MACROS_H): Remove.
8984         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
8985         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
8986         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
8987         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
8988         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
8989         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
8990         Move these macros to ...
8991         * lib/stat_.h: here.  Don't include stat-macros.h.
8992         * lib/canonicalize.c: Don't include stat-macros.h.
8993         * lib/chown.c: Likewise.
8994         * lib/euidaccess.c: Likewise.
8995         * lib/file-type.c: Likewise.
8996         * lib/filemode.c: Likewise.
8997         * lib/glob.c: Likewise.
8998         * lib/isapipe.c: Likewise.
8999         * lib/lchown.c: Likewise.
9000         * lib/lstat.c: Likewise.
9001         * lib/mkdir-p.c: Likewise.
9002         * lib/rmdir.c: Likewise.
9003         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
9004         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
9005         unless mkdir isn't declared, to speed up 'configure'.
9006         Always create sys/stat.h, since it's unlikely any real sys/stat.h
9007         would define all the S_* symbols.
9008         * modules/canonicalize (Depends-on):
9009         Depend on sys_stat, not stat-macros.
9010         * modules/chown: Likewise.
9011         * modules/euidaccess: Likewise.
9012         * modules/filemode: Likewise.
9013         * modules/file-type: Likewise.
9014         * modules/glob: Likewise.
9015         * modules/isapipe: Likewise.
9016         * modules/lchown: Likewise.
9017         * modules/lstat: Likewise.
9018         * modules/mkancesdirs: Likewise.
9019         * modules/rmdir: Likewise.
9020         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
9021         * modules/modechange: Likewise.
9022         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
9023         (configure.ac): Remove gl_STAT_MACROS.
9024         * modules/sys_stat (Depends-on): Remove stat-macros.
9025
9026 2006-10-27  Bruno Haible  <bruno@clisp.org>
9027
9028         * m4/signed.m4: Remove file.
9029         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
9030         invocation.
9031         * modules/vasnprintf (Files): Remove m4/signed.m4.
9032
9033 2006-10-27  Bruno Haible  <bruno@clisp.org>
9034
9035         Update to GNU gettext 0.16.
9036         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
9037         m4/inttypes-h.m4, m4/signed.m4.
9038         * m4/gettext.m4: Update to GNU gettext 0.16.
9039         * m4/intl.m4: New file, from GNU gettext.
9040         * m4/intldir.m4: New file, from GNU gettext.
9041         * config/srclist.txt: Update
9042
9043 2006-10-27  Eric Blake  <ebb9@byu.net>
9044
9045         * MODULES.html.sh: Document tempname.
9046         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
9047         dependencies.
9048         (Files): Move lib/tempname.c...
9049         * modules/tempname: ...to this new module.
9050         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
9051         (gl_PREREQ_TEMPNAME): Move...
9052         * m4/tempname.m4: ...to this new file.
9053         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
9054         * modules/sys_stat (Depends-on): Add stat-macros.
9055         * lib/stat_.h (includes): Pick up stat macros.
9056         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
9057         if stat macros are broken.
9058         * lib/tempname.c (includes): No need to include "stat-macros.h".
9059         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
9060         (direxists, __path_search) [!_LIBC]: Don't compile these in
9061         gnulib; the tmpdir module covers that.
9062         * lib/tempname.h: New file.
9063
9064 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
9065
9066         * COPYING: Explain how gnulib-tool converts licence headers.
9067         Almost all wording by Eric Blake.
9068
9069 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
9070
9071         * lib/mbchar.h (is_basic_table): Make read-only.
9072         * lib/mbchar.c (is_basic_table): Likewise.
9073         Reported by John Darrington.
9074
9075 2006-10-25  Bruno Haible  <bruno@clisp.org>
9076
9077         * lib/progname.h (set_program_name): Undefine before defining.
9078
9079 2006-10-25  Bruno Haible  <bruno@clisp.org>
9080
9081         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
9082         false for non-gcc C++ compilers.
9083         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
9084
9085 2006-10-24  Bruno Haible  <bruno@clisp.org>
9086
9087         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
9088         iconv implementations like Irix iconv.
9089
9090 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9091
9092         * modules/vararrays: New file.
9093         * m4/vararrays.m4: New file, taken from diffutils.
9094         * MODULES.html.sh: New module vararrays.
9095
9096 2006-10-24  Karl Berry  <karl@gnu.org>
9097
9098         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
9099         Don't call GNU Unix.
9100
9101 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9102
9103         * users.txt: Add Libtool.
9104
9105         Sync from Libtool:
9106
9107         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9108
9109         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
9110         to gnulib's policy of including config.h unconditionally.
9111
9112 2006-10-24  Bruno Haible  <bruno@clisp.org>
9113
9114         * modules/wcwidth (Files): Add m4/wint_t.m4.
9115         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
9116         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
9117
9118 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9119
9120         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
9121         to pacify GCC with some -W flags enabled.  Problem reported by
9122         Bruno Haible.
9123
9124 2006-10-24  Jim Meyering  <jim@meyering.net>
9125
9126         * MODULES.html.sh: Remove uinttostr.  It's not a module.
9127         Reported by Karl Berry.
9128
9129 2006-10-23  Bruno Haible  <bruno@clisp.org>
9130
9131         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
9132
9133 2006-10-24  Bruno Haible  <bruno@clisp.org>
9134
9135         * lib/gl_list.h: Use C comment style, not C++ comment style.
9136
9137 2006-10-23  Eric Blake  <ebb9@byu.net>
9138
9139         * lib/getaddrinfo.c (includes): Add missing include.
9140
9141 2006-10-23  Bruno Haible  <bruno@clisp.org>
9142             Paul Eggert  <eggert@cs.ucla.edu>
9143
9144         Ability to rename obstack_free.
9145         * lib/obstack.h (__obstack_free): New macro. Declare instead of
9146         obstack_free.
9147         (obstack_free): Invoke the __obstack_free macro.
9148         * lib/obstack.c (obstack_free): Use __obstack_free macro.
9149
9150 2006-10-23  Bruno Haible  <bruno@clisp.org>
9151             Paul Eggert  <eggert@cs.ucla.edu>
9152
9153         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
9154         __argc, __argv from the declaration. (They are defined as macros on
9155         mingw.)
9156
9157 2006-10-22  Bruno Haible  <bruno@clisp.org>
9158
9159         * doc/gnulib-intro.texi: New file.
9160         * doc/gnulib.texi: Include it.
9161
9162 2006-10-21  Bruno Haible  <bruno@clisp.org>
9163
9164         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
9165         "Introduction", "Miscellanous Notes", "Particular Modules".
9166
9167 2006-10-21  Bruno Haible  <bruno@clisp.org>
9168
9169         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9170         Change mostlyclean-local rule to avoid sh syntax error from bash
9171         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
9172
9173 2006-10-23  Jim Meyering  <jim@meyering.net>
9174
9175         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
9176         in place of snprintf.
9177
9178         * modules/inttostr (Files): Add lib/uinttostr.c.
9179         * lib/uinttostr.c (inttostr): New file/function.
9180         * lib/inttostr.h (uinttostr): Declare.
9181         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
9182         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
9183         Add uinttostr.
9184         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
9185
9186 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9187
9188         * lib/canonicalize.c (ELOOP): Define if not already defined.
9189         Problem reported by Bruno Haible in
9190         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
9191
9192 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9193
9194         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
9195         Problem reported by Perry Smith and Ville Laurikari.
9196
9197         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
9198         uses.
9199
9200 2006-10-19  Bruno Haible  <bruno@clisp.org>
9201
9202         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
9203         for mingw.
9204
9205 2006-10-19  Bruno Haible  <bruno@clisp.org>
9206
9207         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
9208         Needed for mingw.
9209
9210 2006-10-19  Bruno Haible  <bruno@clisp.org>
9211
9212         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
9213
9214 2006-10-19  Bruno Haible  <bruno@clisp.org>
9215
9216         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
9217         it.
9218
9219 2006-10-19  Bruno Haible  <bruno@clisp.org>
9220
9221         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
9222         invocation.
9223
9224 2006-10-19  Bruno Haible  <bruno@clisp.org>
9225
9226         * gnulib-tool (func_create_testdir): Don't include ftruncate and
9227         mountlist by default.
9228
9229 2006-10-16  Bruno Haible  <bruno@clisp.org>
9230
9231         * lib/c-strstr.c: Include c-strstr.h.
9232
9233 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9234
9235         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
9236         in a slash.
9237
9238 2006-10-18  Bruno Haible  <bruno@clisp.org>
9239
9240         * lib/lock.h [C++]: Wrap definitions in extern "C".
9241
9242 2006-10-18  Bruno Haible  <bruno@clisp.org>
9243
9244         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
9245         gl_LIBOBJS list.
9246
9247 2006-10-18  Bruno Haible  <bruno@clisp.org>
9248
9249         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
9250
9251 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
9252
9253         * lib/xstrtol.h: Include gettext.h.
9254         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
9255         Problem reported by Eric Blake.
9256         * modules/xstrtol (Depends-on): Add gettext-h.
9257
9258 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
9259
9260         * lib/strftime.c (advance): New macro.
9261         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
9262         incomplete type, so you can't add 0 to it.  Problem and patch
9263         reported by Eelco Dolstra for dietlibc.
9264
9265 2006-10-18  Jim Meyering  <jim@meyering.net>
9266
9267         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
9268         type for a local, and rename it: s/up/user_proc/.
9269
9270 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
9271
9272         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
9273         READ_UTMP_USER_PROCESS.
9274         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
9275
9276 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
9277
9278         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
9279         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
9280
9281 2006-10-17  Eric Blake  <ebb9@byu.net>
9282
9283         * lib/sigprocmask.c (sigprocmask): Fix typo.
9284
9285         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
9286
9287         * modules/clean-temp (Makefile.am): Don't add to make output...
9288         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
9289         config.h.
9290
9291 2006-10-17  Bruno Haible  <bruno@clisp.org>
9292
9293         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
9294         differently if DEFAULT_TEXT_DOMAIN is set.
9295
9296 2006-10-16  Bruno Haible  <bruno@clisp.org>
9297
9298         * lib/clean-temp.c: Include fwriteerror.h.
9299
9300 2006-10-16  Bruno Haible  <bruno@clisp.org>
9301
9302         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
9303
9304 2006-10-16  Bruno Haible  <bruno@clisp.org>
9305
9306         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
9307         * lib/sigprocmask.h: Include <sys/types.h>.
9308         (sigset_t): Use the system's definition if present.
9309
9310 2006-10-17  Eric Blake  <ebb9@byu.net>
9311
9312         * lib/xvasprintf.c (includes): Assume config.h.
9313         * lib/xasprintf.c (includes): Likewise.
9314
9315 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
9316
9317         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
9318         at least as wide as intmax_t.
9319
9320 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
9321
9322         (Imported from Automake.)
9323         * build-aux/gnupload: Update to version 1.1 of directive file.
9324
9325 2006-10-16  Eric Blake  <ebb9@byu.net>
9326
9327         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
9328         match Automake 1.10a.
9329
9330 2006-10-14  Bruno Haible  <bruno@clisp.org>
9331
9332         * modules/sigprocmask: New file.
9333         * lib/sigprocmask.h: New file.
9334         * lib/sigprocmask.c: New file.
9335         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
9336         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
9337         request sigprocmask.o.
9338         (gl_PREREQ_SIGPROCMASK): New macro.
9339         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
9340         (Depends-on): Add sigprocmask.
9341         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
9342         gt_SIGNALBLOCKING. Test for 'raise' only once.
9343         * lib/fatal-signal.c: Include sigprocmask.h.
9344         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
9345         unblock_fatal_signals): Define always.
9346         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
9347         sigprocmask.
9348
9349 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9350
9351         Sync from Automake.
9352         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
9353         which incorrectly sets the mode of an existing destination
9354         directory.  In some cases the unpatched install-sh could do the
9355         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
9356         system.  We hope this is rare in practice, but it's clearly worth
9357         fixing.  Problem reported by Alex Unleashed in
9358         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
9359         Also, don't bother to check for -m bugs unless we're using -m;
9360         suggested by Stepan Kasal.
9361
9362 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9363
9364         Sync from Automake.
9365         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
9366         `-c' flag, so they appear at the same position as in %FASTDEP%
9367         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
9368         which ignores unknown options only after the first non-option.
9369         Bug report against M4 by Nelson H. F. Beebe.
9370
9371 2006-10-13  Jim Meyering  <jim@meyering.net>
9372
9373         Fix a bug in yesterday's change.
9374         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
9375         p->fts_statp->st_dev would be used uninitialized.
9376         Ensures that we always call fts_stat on the very first entry.
9377         Miklos Szeredi reported that find -xdev stopped working.
9378
9379 2006-10-12  Bruno Haible  <bruno@clisp.org>
9380
9381         * gnulib-tool (func_get_automake_snippet): Append an automatically
9382         computed EXTRA_DIST augmentation.
9383         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
9384         * modules/alloca-opt (Makefile.am): Likewise.
9385         * modules/allocsa (Makefile.am): Likewise.
9386         * modules/arcfour (Makefile.am): Likewise.
9387         * modules/arctwo (Makefile.am): Likewise.
9388         * modules/argmatch (Makefile.am): Likewise.
9389         * modules/argz (Makefile.am): Likewise.
9390         * modules/atexit (Makefile.am): Likewise.
9391         * modules/backupfile (Makefile.am): Likewise.
9392         * modules/byteswap (Makefile.am): Likewise.
9393         * modules/c-strtod (Makefile.am): Likewise.
9394         * modules/c-strtold (Makefile.am): Likewise.
9395         * modules/calloc (Makefile.am): Likewise.
9396         * modules/canon-host (Makefile.am): Likewise.
9397         * modules/canonicalize (Makefile.am): Likewise.
9398         * modules/chdir-long (Makefile.am): Likewise.
9399         * modules/chdir-safer (Makefile.am): Likewise.
9400         * modules/check-version (Makefile.am): Likewise.
9401         * modules/chown (Makefile.am): Likewise.
9402         * modules/cloexec (Makefile.am): Likewise.
9403         * modules/close-stream (Makefile.am): Likewise.
9404         * modules/closeout (Makefile.am): Likewise.
9405         * modules/crc (Makefile.am): Likewise.
9406         * modules/csharpexec (Makefile.am): Likewise.
9407         * modules/cycle-check (Makefile.am): Likewise.
9408         * modules/des (Makefile.am): Likewise.
9409         * modules/dev-ino (Makefile.am): Likewise.
9410         * modules/dirfd (Makefile.am): Likewise.
9411         * modules/dirname (Makefile.am): Likewise.
9412         * modules/dup2 (Makefile.am): Likewise.
9413         * modules/eealloc (Makefile.am): Likewise.
9414         * modules/error (Makefile.am): Likewise.
9415         * modules/euidaccess (Makefile.am): Likewise.
9416         * modules/exclude (Makefile.am): Likewise.
9417         * modules/exitfail (Makefile.am): Likewise.
9418         * modules/fcntl-safer (Makefile.am): Likewise.
9419         * modules/fcntl (Makefile.am): Likewise.
9420         * modules/file-type (Makefile.am): Likewise.
9421         * modules/fileblocks (Makefile.am): Likewise.
9422         * modules/filemode (Makefile.am): Likewise.
9423         * modules/filenamecat (Makefile.am): Likewise.
9424         * modules/fnmatch (Makefile.am): Likewise.
9425         * modules/fopen-safer (Makefile.am): Likewise.
9426         * modules/fpending (Makefile.am): Likewise.
9427         * modules/fprintftime (Makefile.am): Likewise.
9428         * modules/free (Makefile.am): Likewise.
9429         * modules/fsusage (Makefile.am): Likewise.
9430         * modules/ftruncate (Makefile.am): Likewise.
9431         * modules/fts (Makefile.am): Likewise.
9432         * modules/gc-arcfour (Makefile.am): Likewise.
9433         * modules/gc-des (Makefile.am): Likewise.
9434         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9435         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9436         * modules/gc-md4 (Makefile.am): Likewise.
9437         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9438         * modules/gc-sha1 (Makefile.am): Likewise.
9439         * modules/gc (Makefile.am): Likewise.
9440         * modules/getaddrinfo (Makefile.am): Likewise.
9441         * modules/getcwd (Makefile.am): Likewise.
9442         * modules/getdelim (Makefile.am): Likewise.
9443         * modules/getdomainname (Makefile.am): Likewise.
9444         * modules/getgroups (Makefile.am): Likewise.
9445         * modules/gethostname (Makefile.am): Likewise.
9446         * modules/gethrxtime (Makefile.am): Likewise.
9447         * modules/getline (Makefile.am): Likewise.
9448         * modules/getloadavg (Makefile.am): Likewise.
9449         * modules/getlogin_r (Makefile.am): Likewise.
9450         * modules/getndelim2 (Makefile.am): Likewise.
9451         * modules/getopt (Makefile.am): Likewise.
9452         * modules/getpagesize (Makefile.am): Likewise.
9453         * modules/getpass-gnu (Makefile.am): Likewise.
9454         * modules/getpass (Makefile.am): Likewise.
9455         * modules/getsubopt (Makefile.am): Likewise.
9456         * modules/gettime (Makefile.am): Likewise.
9457         * modules/gettimeofday (Makefile.am): Likewise.
9458         * modules/getugroups (Makefile.am): Likewise.
9459         * modules/getusershell (Makefile.am): Likewise.
9460         * modules/glob (Makefile.am): Likewise.
9461         * modules/group-member (Makefile.am): Likewise.
9462         * modules/hard-locale (Makefile.am): Likewise.
9463         * modules/hash (Makefile.am): Likewise.
9464         * modules/hmac-md5 (Makefile.am): Likewise.
9465         * modules/hmac-sha1 (Makefile.am): Likewise.
9466         * modules/human (Makefile.am): Likewise.
9467         * modules/idcache (Makefile.am): Likewise.
9468         * modules/imaxabs (Makefile.am): Likewise.
9469         * modules/imaxdiv (Makefile.am): Likewise.
9470         * modules/inet_ntop (Makefile.am): Likewise.
9471         * modules/inet_pton (Makefile.am): Likewise.
9472         * modules/intprops (Makefile.am): Likewise.
9473         * modules/inttostr (Makefile.am): Likewise.
9474         * modules/inttypes (Makefile.am): Likewise.
9475         * modules/isapipe (Makefile.am): Likewise.
9476         * modules/javaversion (Makefile.am): Likewise.
9477         * modules/lchmod (Makefile.am): Likewise.
9478         * modules/lchown (Makefile.am): Likewise.
9479         * modules/localcharset (Makefile.am): Likewise.
9480         * modules/long-options (Makefile.am): Likewise.
9481         * modules/lstat (Makefile.am): Likewise.
9482         * modules/malloc (Makefile.am): Likewise.
9483         * modules/mathl (Makefile.am): Likewise.
9484         * modules/mbchar (Makefile.am): Likewise.
9485         * modules/md2 (Makefile.am): Likewise.
9486         * modules/md4 (Makefile.am): Likewise.
9487         * modules/md5 (Makefile.am): Likewise.
9488         * modules/memcasecmp (Makefile.am): Likewise.
9489         * modules/memchr (Makefile.am): Likewise.
9490         * modules/memcmp (Makefile.am): Likewise.
9491         * modules/memcoll (Makefile.am): Likewise.
9492         * modules/memcpy (Makefile.am): Likewise.
9493         * modules/memmem (Makefile.am): Likewise.
9494         * modules/memmove (Makefile.am): Likewise.
9495         * modules/mempcpy (Makefile.am): Likewise.
9496         * modules/memrchr (Makefile.am): Likewise.
9497         * modules/memset (Makefile.am): Likewise.
9498         * modules/memxor (Makefile.am): Likewise.
9499         * modules/mkancesdirs (Makefile.am): Likewise.
9500         * modules/mkdir-p (Makefile.am): Likewise.
9501         * modules/mkdir (Makefile.am): Likewise.
9502         * modules/mkdtemp (Makefile.am): Likewise.
9503         * modules/mkstemp (Makefile.am): Likewise.
9504         * modules/mktime (Makefile.am): Likewise.
9505         * modules/modechange (Makefile.am): Likewise.
9506         * modules/mountlist (Makefile.am): Likewise.
9507         * modules/nanosleep (Makefile.am): Likewise.
9508         * modules/obstack (Makefile.am): Likewise.
9509         * modules/openat (Makefile.am): Likewise.
9510         * modules/pagealign_alloc (Makefile.am): Likewise.
9511         * modules/pathmax (Makefile.am): Likewise.
9512         * modules/physmem (Makefile.am): Likewise.
9513         * modules/poll (Makefile.am): Likewise.
9514         * modules/posixtm (Makefile.am): Likewise.
9515         * modules/posixver (Makefile.am): Likewise.
9516         * modules/putenv (Makefile.am): Likewise.
9517         * modules/quote (Makefile.am): Likewise.
9518         * modules/quotearg (Makefile.am): Likewise.
9519         * modules/raise (Makefile.am): Likewise.
9520         * modules/read-file (Makefile.am): Likewise.
9521         * modules/readline (Makefile.am): Likewise.
9522         * modules/readlink (Makefile.am): Likewise.
9523         * modules/readtokens (Makefile.am): Likewise.
9524         * modules/readutmp (Makefile.am): Likewise.
9525         * modules/realloc (Makefile.am): Likewise.
9526         * modules/regex (Makefile.am): Likewise.
9527         * modules/rename-dest-slash (Makefile.am): Likewise.
9528         * modules/rename (Makefile.am): Likewise.
9529         * modules/rijndael (Makefile.am): Likewise.
9530         * modules/rmdir (Makefile.am): Likewise.
9531         * modules/rpmatch (Makefile.am): Likewise.
9532         * modules/safe-read (Makefile.am): Likewise.
9533         * modules/safe-write (Makefile.am): Likewise.
9534         * modules/same-inode (Makefile.am): Likewise.
9535         * modules/same (Makefile.am): Likewise.
9536         * modules/save-cwd (Makefile.am): Likewise.
9537         * modules/savedir (Makefile.am): Likewise.
9538         * modules/setenv (Makefile.am): Likewise.
9539         * modules/settime (Makefile.am): Likewise.
9540         * modules/sha1 (Makefile.am): Likewise.
9541         * modules/sig2str (Makefile.am): Likewise.
9542         * modules/snprintf (Makefile.am): Likewise.
9543         * modules/stat-macros (Makefile.am): Likewise.
9544         * modules/stat-time (Makefile.am): Likewise.
9545         * modules/stdbool (Makefile.am): Likewise.
9546         * modules/stdint (Makefile.am): Likewise.
9547         * modules/stdlib-safer (Makefile.am): Likewise.
9548         * modules/stpcpy (Makefile.am): Likewise.
9549         * modules/stpncpy (Makefile.am): Likewise.
9550         * modules/strcase (Makefile.am): Likewise.
9551         * modules/strcasestr (Makefile.am): Likewise.
9552         * modules/strchrnul (Makefile.am): Likewise.
9553         * modules/strcspn (Makefile.am): Likewise.
9554         * modules/strdup (Makefile.am): Likewise.
9555         * modules/strerror (Makefile.am): Likewise.
9556         * modules/strftime (Makefile.am): Likewise.
9557         * modules/strndup (Makefile.am): Likewise.
9558         * modules/strnlen (Makefile.am): Likewise.
9559         * modules/strpbrk (Makefile.am): Likewise.
9560         * modules/strsep (Makefile.am): Likewise.
9561         * modules/strstr (Makefile.am): Likewise.
9562         * modules/strtod (Makefile.am): Likewise.
9563         * modules/strtoimax (Makefile.am): Likewise.
9564         * modules/strtok_r (Makefile.am): Likewise.
9565         * modules/strtol (Makefile.am): Likewise.
9566         * modules/strtoll (Makefile.am): Likewise.
9567         * modules/strtoul (Makefile.am): Likewise.
9568         * modules/strtoull (Makefile.am): Likewise.
9569         * modules/strtoumax (Makefile.am): Likewise.
9570         * modules/strverscmp (Makefile.am): Likewise.
9571         * modules/sys_socket (Makefile.am): Likewise.
9572         * modules/sys_stat (Makefile.am): Likewise.
9573         * modules/sysexits (Makefile.am): Likewise.
9574         * modules/time_r (Makefile.am): Likewise.
9575         * modules/timegm (Makefile.am): Likewise.
9576         * modules/timespec (Makefile.am): Likewise.
9577         * modules/tmpfile-safer (Makefile.am): Likewise.
9578         * modules/trim (Makefile.am): Likewise.
9579         * modules/unistd-safer (Makefile.am): Likewise.
9580         * modules/unlinkdir (Makefile.am): Likewise.
9581         * modules/unlocked-io (Makefile.am): Likewise.
9582         * modules/userspec (Makefile.am): Likewise.
9583         * modules/utime (Makefile.am): Likewise.
9584         * modules/utimecmp (Makefile.am): Likewise.
9585         * modules/utimens (Makefile.am): Likewise.
9586         * modules/vasnprintf (Makefile.am): Likewise.
9587         * modules/vasprintf (Makefile.am): Likewise.
9588         * modules/vsnprintf (Makefile.am): Likewise.
9589         * modules/xalloc (Makefile.am): Likewise.
9590         * modules/xgetcwd (Makefile.am): Likewise.
9591         * modules/xnanosleep (Makefile.am): Likewise.
9592         * modules/xreadlink (Makefile.am): Likewise.
9593         * modules/xstrtod (Makefile.am): Likewise.
9594         * modules/xstrtol (Makefile.am): Likewise.
9595         * modules/xstrtold (Makefile.am): Likewise.
9596         * modules/yesno (Makefile.am): Likewise.
9597         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
9598
9599 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9600
9601         * modules/error (Makefile.am): Distribute files through
9602         EXTRA_DIST, not lib_SOURCES.
9603
9604 2006-10-12  Eric Blake  <ebb9@byu.net>
9605
9606         * modules/error (Makefile.am): Distribute files in /lib.
9607         * modules/obstack (Makefile.am): Likewise.
9608
9609 2006-10-12  Bruno Haible  <bruno@clisp.org>
9610
9611         * modules/acl (Makefile.am): Distribute all files in lib/ through
9612         EXTRA_DIST.
9613         * modules/arcfour (Makefile.am): Likewise.
9614         * modules/arctwo (Makefile.am): Likewise.
9615         * modules/argmatch (Makefile.am): Likewise.
9616         * modules/argz (Makefile.am): Likewise.
9617         * modules/atexit (Makefile.am): Likewise.
9618         * modules/backupfile (Makefile.am): Likewise.
9619         * modules/c-strtod (Makefile.am): Likewise.
9620         * modules/c-strtold (Makefile.am): Likewise.
9621         * modules/calloc (Makefile.am): Likewise.
9622         * modules/canon-host (Makefile.am): Likewise.
9623         * modules/canonicalize (Makefile.am): Likewise.
9624         * modules/chdir-long (Makefile.am): Likewise.
9625         * modules/chdir-safer (Makefile.am): Likewise.
9626         * modules/check-version (Makefile.am): Likewise.
9627         * modules/chown (Makefile.am): Likewise.
9628         * modules/cloexec (Makefile.am): Likewise.
9629         * modules/close-stream (Makefile.am): Likewise.
9630         * modules/closeout (Makefile.am): Likewise.
9631         * modules/crc (Makefile.am): Likewise.
9632         * modules/cycle-check (Makefile.am): Likewise.
9633         * modules/des (Makefile.am): Likewise.
9634         * modules/dirfd (Makefile.am): Likewise.
9635         * modules/dirname (Makefile.am): Likewise.
9636         * modules/dup2 (Makefile.am): Likewise.
9637         * modules/euidaccess (Makefile.am): Likewise.
9638         * modules/exclude (Makefile.am): Likewise.
9639         * modules/exitfail (Makefile.am): Likewise.
9640         * modules/fcntl-safer (Makefile.am): Likewise.
9641         * modules/file-type (Makefile.am): Likewise.
9642         * modules/fileblocks (Makefile.am): Likewise.
9643         * modules/filemode (Makefile.am): Likewise.
9644         * modules/filenamecat (Makefile.am): Likewise.
9645         * modules/fnmatch (Makefile.am): Likewise.
9646         * modules/fopen-safer (Makefile.am): Likewise.
9647         * modules/fpending (Makefile.am): Likewise.
9648         * modules/fprintftime (Makefile.am): Likewise.
9649         * modules/free (Makefile.am): Likewise.
9650         * modules/fsusage (Makefile.am): Likewise.
9651         * modules/ftruncate (Makefile.am): Likewise.
9652         * modules/fts (Makefile.am): Likewise.
9653         * modules/gc (Makefile.am): Likewise.
9654         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9655         * modules/getaddrinfo (Makefile.am): Likewise.
9656         * modules/getcwd (Makefile.am): Likewise.
9657         * modules/getdelim (Makefile.am): Likewise.
9658         * modules/getdomainname (Makefile.am): Likewise.
9659         * modules/getgroups (Makefile.am): Likewise.
9660         * modules/gethostname (Makefile.am): Likewise.
9661         * modules/gethrxtime (Makefile.am): Likewise.
9662         * modules/getline (Makefile.am): Likewise.
9663         * modules/getloadavg (Makefile.am): Likewise.
9664         * modules/getlogin_r (Makefile.am): Likewise.
9665         * modules/getopt (Makefile.am): Likewise.
9666         * modules/getpass (Makefile.am): Likewise.
9667         * modules/getpass-gnu (Makefile.am): Likewise.
9668         * modules/getsubopt (Makefile.am): Likewise.
9669         * modules/gettime (Makefile.am): Likewise.
9670         * modules/gettimeofday (Makefile.am): Likewise.
9671         * modules/getugroups (Makefile.am): Likewise.
9672         * modules/getusershell (Makefile.am): Likewise.
9673         * modules/glob (Makefile.am): Likewise.
9674         * modules/group-member (Makefile.am): Likewise.
9675         * modules/hard-locale (Makefile.am): Likewise.
9676         * modules/hash (Makefile.am): Likewise.
9677         * modules/hmac-md5 (Makefile.am): Likewise.
9678         * modules/hmac-sha1 (Makefile.am): Likewise.
9679         * modules/human (Makefile.am): Likewise.
9680         * modules/idcache (Makefile.am): Likewise.
9681         * modules/imaxabs (Makefile.am): Likewise.
9682         * modules/imaxdiv (Makefile.am): Likewise.
9683         * modules/inet_ntop (Makefile.am): Likewise.
9684         * modules/inet_pton (Makefile.am): Likewise.
9685         * modules/inttostr (Makefile.am): Likewise.
9686         * modules/isapipe (Makefile.am): Likewise.
9687         * modules/lchown (Makefile.am): Likewise.
9688         * modules/long-options (Makefile.am): Likewise.
9689         * modules/lstat (Makefile.am): Likewise.
9690         * modules/malloc (Makefile.am): Likewise.
9691         * modules/mathl (Makefile.am): Likewise.
9692         * modules/mbchar (Makefile.am): Likewise.
9693         * modules/md2 (Makefile.am): Likewise.
9694         * modules/md4 (Makefile.am): Likewise.
9695         * modules/md5 (Makefile.am): Likewise.
9696         * modules/memcasecmp (Makefile.am): Likewise.
9697         * modules/memchr (Makefile.am): Likewise.
9698         * modules/memcmp (Makefile.am): Likewise.
9699         * modules/memcoll (Makefile.am): Likewise.
9700         * modules/memcpy (Makefile.am): Likewise.
9701         * modules/memmem (Makefile.am): Likewise.
9702         * modules/memmove (Makefile.am): Likewise.
9703         * modules/mempcpy (Makefile.am): Likewise.
9704         * modules/memrchr (Makefile.am): Likewise.
9705         * modules/memset (Makefile.am): Likewise.
9706         * modules/memxor (Makefile.am): Likewise.
9707         * modules/mkancesdirs (Makefile.am): Likewise.
9708         * modules/mkdir (Makefile.am): Likewise.
9709         * modules/mkdir-p (Makefile.am): Likewise.
9710         * modules/mkdtemp (Makefile.am): Likewise.
9711         * modules/mkstemp (Makefile.am): Likewise.
9712         * modules/mktime (Makefile.am): Likewise.
9713         * modules/modechange (Makefile.am): Likewise.
9714         * modules/mountlist (Makefile.am): Likewise.
9715         * modules/nanosleep (Makefile.am): Likewise.
9716         * modules/openat (Makefile.am): Likewise.
9717         * modules/pagealign_alloc (Makefile.am): Likewise.
9718         * modules/physmem (Makefile.am): Likewise.
9719         * modules/poll (Makefile.am): Likewise.
9720         * modules/posixtm (Makefile.am): Likewise.
9721         * modules/posixver (Makefile.am): Likewise.
9722         * modules/putenv (Makefile.am): Likewise.
9723         * modules/quote (Makefile.am): Likewise.
9724         * modules/quotearg (Makefile.am): Likewise.
9725         * modules/raise (Makefile.am): Likewise.
9726         * modules/read-file (Makefile.am): Likewise.
9727         * modules/readline (Makefile.am): Likewise.
9728         * modules/readlink (Makefile.am): Likewise.
9729         * modules/readtokens (Makefile.am): Likewise.
9730         * modules/readutmp (Makefile.am): Likewise.
9731         * modules/realloc (Makefile.am): Likewise.
9732         * modules/regex (Makefile.am): Likewise.
9733         * modules/rename (Makefile.am): Likewise.
9734         * modules/rename-dest-slash (Makefile.am): Likewise.
9735         * modules/rijndael (Makefile.am): Likewise.
9736         * modules/rmdir (Makefile.am): Likewise.
9737         * modules/rpmatch (Makefile.am): Likewise.
9738         * modules/safe-read (Makefile.am): Likewise.
9739         * modules/safe-write (Makefile.am): Likewise.
9740         * modules/same (Makefile.am): Likewise.
9741         * modules/save-cwd (Makefile.am): Likewise.
9742         * modules/savedir (Makefile.am): Likewise.
9743         * modules/setenv (Makefile.am): Likewise.
9744         * modules/settime (Makefile.am): Likewise.
9745         * modules/sha1 (Makefile.am): Likewise.
9746         * modules/sig2str (Makefile.am): Likewise.
9747         * modules/snprintf (Makefile.am): Likewise.
9748         * modules/stdlib-safer (Makefile.am): Likewise.
9749         * modules/stpcpy (Makefile.am): Likewise.
9750         * modules/stpncpy (Makefile.am): Likewise.
9751         * modules/strcase (Makefile.am): Likewise.
9752         * modules/strcasestr (Makefile.am): Likewise.
9753         * modules/strchrnul (Makefile.am): Likewise.
9754         * modules/strcspn (Makefile.am): Likewise.
9755         * modules/strdup (Makefile.am): Likewise.
9756         * modules/strerror (Makefile.am): Likewise.
9757         * modules/strftime (Makefile.am): Likewise.
9758         * modules/strndup (Makefile.am): Likewise.
9759         * modules/strnlen (Makefile.am): Likewise.
9760         * modules/strpbrk (Makefile.am): Likewise.
9761         * modules/strsep (Makefile.am): Likewise.
9762         * modules/strstr (Makefile.am): Likewise.
9763         * modules/strtod (Makefile.am): Likewise.
9764         * modules/strtoimax (Makefile.am): Likewise.
9765         * modules/strtok_r (Makefile.am): Likewise.
9766         * modules/strtol (Makefile.am): Likewise.
9767         * modules/strtoll (Makefile.am): Likewise.
9768         * modules/strtoul (Makefile.am): Likewise.
9769         * modules/strtoull (Makefile.am): Likewise.
9770         * modules/strtoumax (Makefile.am): Likewise.
9771         * modules/strverscmp (Makefile.am): Likewise.
9772         * modules/time_r (Makefile.am): Likewise.
9773         * modules/timegm (Makefile.am): Likewise.
9774         * modules/tmpfile-safer (Makefile.am): Likewise.
9775         * modules/unistd-safer (Makefile.am): Likewise.
9776         * modules/unlinkdir (Makefile.am): Likewise.
9777         * modules/userspec (Makefile.am): Likewise.
9778         * modules/utime (Makefile.am): Likewise.
9779         * modules/utimecmp (Makefile.am): Likewise.
9780         * modules/utimens (Makefile.am): Likewise.
9781         * modules/vasnprintf (Makefile.am): Likewise.
9782         * modules/vasprintf (Makefile.am): Likewise.
9783         * modules/vsnprintf (Makefile.am): Likewise.
9784         * modules/xalloc (Makefile.am): Likewise.
9785         * modules/xgetcwd (Makefile.am): Likewise.
9786         * modules/xnanosleep (Makefile.am): Likewise.
9787         * modules/xreadlink (Makefile.am): Likewise.
9788         * modules/xstrtod (Makefile.am): Likewise.
9789         * modules/xstrtol (Makefile.am): Likewise.
9790         * modules/xstrtold (Makefile.am): Likewise.
9791         * modules/yesno (Makefile.am): Likewise.
9792
9793 2006-10-12  Jim Meyering  <jim@meyering.net>
9794
9795         * m4/getloadavg.m4: Revert the change below.
9796
9797         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
9798         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
9799         fail with a symlink, which is what coreutils' ./bootstrap now
9800         creates by default.
9801
9802 2006-10-12  Bruno Haible  <bruno@clisp.org>
9803
9804         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
9805         mingw.
9806         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
9807         MSVC and mingw explicitly.
9808
9809 2006-10-11  Simon Josefsson  <jas@extundo.com>
9810             Bruno Haible  <bruno@clisp.org>
9811
9812         Add support for multiple gnulib-tool invocations in the scope of a
9813         single configure.ac file.
9814         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
9815         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
9816         with the same contents as the _LIBADD variable.
9817         (func_emit_initmacro_start, func_emit_initmacro_end,
9818         func_emit_initmacro_done): New functions.
9819         (func_import, func_create_testdir): Invoke them. Allow the identifiers
9820         gl_LIBOBJS and gl_LTLIBOBJS.
9821
9822 2006-10-11  Bruno Haible  <bruno@clisp.org>
9823
9824         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
9825         (func_create_testdir): Don't create po/Makefile.am, don't invoke
9826         autoreconf. Instead, invoke autopoint explicitly but move back the
9827         *.m4 files from gnulib.
9828
9829 2006-10-11  Bruno Haible  <bruno@clisp.org>
9830
9831         * gnulib-tool (func_usage): Make module names after --create-testdir
9832         optional.
9833         (func_create_testdir): If no module was specified, use nearly all
9834         modules.
9835
9836 2006-10-12  Jim Meyering  <jim@meyering.net>
9837
9838         Big performance improvement for fts-based tools that use FTS_NOSTAT.
9839         Avoid spurious inode-mismatch problems on non-POSIX file systems.
9840         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
9841         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
9842         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
9843         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
9844         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
9845         (fts_set_stat_required): New function.
9846         (fts_open): Defer the calls to fts_stat, if possible or requested.
9847         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
9848         into fts_stat itself.
9849         (fts_read): Perform any required (deferred) fts_stat call.
9850         (fts_build): Likewise, for the directory we're about to open and read.
9851         In the readdir loop, carefully decide whether each entry will require
9852         an eventual call to fts_stat, using dirent.d_type info if available.
9853         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
9854         a command line argument into this function.  Update all callers.
9855         Map a return value of FTS_DOT to FTS_D for a command line argument.
9856         * modules/fts (Depends-on): Add d-type.  Alphabetize.
9857         Thanks to Miklos Szeredi for his tenacity and for the initial
9858         bug report about "find" failing on a FUSE-based file system.
9859
9860         * lib/fts.c (fts_open): Use consistent indentation.
9861
9862 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9863
9864         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
9865         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
9866         reported by Jim Meyering.  All uses of cache variables renamed
9867         to match Autoconf's.
9868         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
9869         the other one.
9870
9871         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
9872         Fix misspelling in diagnostic.
9873
9874 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9875
9876         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
9877         defined.  Problem reported by Matthew Woehlke.
9878
9879         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
9880         Add support for Tandem NonStop R series.
9881         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
9882         Use new macro.
9883
9884         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
9885         (has_trailing_slash): Omit size arg; all callers changed.
9886         Omit 'inline', since it doesn't help performance and we'd
9887         need to configure it.
9888         Don't count //, ///, etc. as having a trailing slash.
9889         As a side effect, this removes a C99ism reported by Matthew Woehlke.
9890         (rpl_rename_dest_slash): On failure, use rename's errno rather
9891         than (in some cases) an incorrect or junk errno.
9892         Simplify code by removing need to compute length; this does
9893         cause it to make two passes instead of one over the file name,
9894         but it's worth it.
9895
9896         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
9897         change, since Autoconf's version may no longer be appropriate now
9898         that we are using CVS Autoconf's version.  Add support for Tandem.
9899
9900 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9901             Bruno Haible  <bruno@clisp.org>
9902
9903         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
9904         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
9905         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
9906         gl_AC_TYPE_LONG_LONG.
9907
9908         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
9909         instead of HAVE_LONG_LONG.
9910         * lib/printf-args.c (printf_fetchargs): Likewise.
9911         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
9912         * lib/vasnprintf.c (VASNPRINTF): Likewise.
9913         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
9914         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
9915         gl_AC_TYPE_LONG_LONG.
9916
9917 2006-10-11  Bruno Haible  <bruno@clisp.org>
9918
9919         * m4/longlong.m4: Add comments.
9920         * m4/ulonglong.m4: Likewise.
9921
9922 2006-10-10  Bruno Haible  <bruno@clisp.org>
9923
9924         Make it possible to #define stpcpy, strdup to aliases.
9925         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
9926         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
9927
9928 2006-10-10  Bruno Haible  <bruno@clisp.org>
9929
9930         Make it possible to #define gcd to an alias.
9931         * lib/gcd.c: Include config.h.
9932
9933 2006-10-10  Bruno Haible  <bruno@clisp.org>
9934
9935         Make it possible to #define c_isascii to an alias.
9936         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
9937         defined. Undefine the macros before defining them, to avoid gcc
9938         warnings.
9939         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
9940         define NO_C_CTYPE_MACROS early.
9941
9942 2006-10-10  Bruno Haible  <bruno@clisp.org>
9943
9944         Make it possible to #define set_program_name to an alias.
9945         * lib/progname.c: Don't undefine set_program_name; instead, undefine
9946         ENABLE_RELOCATABLE early.
9947
9948 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9949
9950         Port to Tandem NSK OSS, which has 64-bit signed int but at most
9951         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
9952         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
9953         More generally, don't assume that 64-bit signed int is available
9954         if unsigned int is, and vice versa.
9955         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
9956         unsigned symbols, not on their signed counterparts.
9957         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
9958         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
9959         (UINT64_C, UINTMAX_C):
9960         Likewise.
9961         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
9962         unsigned counterparts.
9963         (Have_long_long, Unsigned): New macros.
9964         (Int): Renamed from INT.
9965         (strtoimax): Use the new macros.
9966         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
9967         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
9968         * modules/inttypes (inttypes.h): Substitute
9969         HAVE_UNSIGNED_LONG_LONG_INT.
9970         * modules/stdint (stdint.h): Likewise.
9971         (Files): Add m4/ulonglong.m4.
9972
9973 2006-10-10  Bruno Haible  <bruno@clisp.org>
9974
9975         Fix a gcc -Wshadow warning.
9976         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
9977         to 'bucket'.
9978         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
9979         gl_linked_indexof_from_to): Likewise.
9980         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
9981         Likewise.
9982         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
9983         Likewise.
9984         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
9985         Reported by Eric Blake.
9986
9987 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
9988
9989         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
9990         for NetBSD.  Problem reported by Bruno Haible.
9991
9992 2006-10-09  Jim Meyering  <jim@meyering.net>
9993
9994         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
9995         Patch from Bruno Haible.
9996
9997 2006-10-09  Jim Meyering  <jim@meyering.net>
9998
9999         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
10000         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
10001         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
10002
10003 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
10004
10005         Don't include <config.h> twice; this doesn't work in some cases,
10006         e.g., when config.h has "#define intmax_t long long int" and
10007         we include <config.h>, <inttypes.h>, <config.h> in that order.
10008         Problem reported by Matthew Woehlke in:
10009         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
10010         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
10011         * lib/fts-cycle.c: Don't include config.h.
10012         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
10013         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
10014         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
10015         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
10016         inttypes.h.
10017         * lib/xstrtoumax.c: Likewise.
10018         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
10019         __strtol and the like, so that this module is more like its siblings.
10020         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
10021         Remove; no longer needed now that we assume gnulib inttypes.h.
10022
10023 2006-10-08  Bruno Haible  <bruno@clisp.org>
10024
10025         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
10026         option.
10027
10028 2006-10-07  Jim Meyering  <jim@meyering.net>
10029
10030         * modules/inttypes (inttypes.h): Revert what seems to have been
10031         an inadvertent part of today's change: use "|", not "/" in the
10032         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
10033
10034 2006-10-07  Bruno Haible  <bruno@clisp.org>
10035
10036         * modules/sublist: New file.
10037
10038 2006-10-07  Bruno Haible  <bruno@clisp.org>
10039
10040         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
10041         * modules/argz (argz.h): Likewise.
10042         * modules/arpa_inet (arpa/inet.h): Likewise.
10043         * modules/byteswap (byteswap.h): Likewise.
10044         * modules/configmake (configmake.h): Likewise.
10045         * modules/fcntl (fcntl.h): Likewise.
10046         * modules/fnmatch (fnmatch.h): Likewise.
10047         * modules/getopt (getopt.h): Likewise.
10048         * modules/glob (glob.h): Likewise.
10049         * modules/inttypes (inttypes.h): Likewise.
10050         * modules/netinet_in (netinet/in.h): Likewise.
10051         * modules/poll (poll.h): Likewise.
10052         * modules/stdbool (stdbool.h): Likewise.
10053         * modules/stdint (stdint.h): Likewise.
10054         * modules/sys_select (sys/select.h): Likewise.
10055         * modules/sys_socket (sys/socket.h): Likewise.
10056         * modules/sys_stat (sys/stat.h): Likewise.
10057         * modules/sysexits (sysexits.h): Likewise.
10058         * modules/unistd (unistd.h): Likewise.
10059         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10060         Add a "DO NOT EDIT" comment to the generated file.
10061         (func_import): Likewise for gnulib-comp.m4.
10062
10063 2006-10-07  Bruno Haible  <bruno@clisp.org>
10064
10065         * lib/gl_sublist.h: New file.
10066         * lib/gl_sublist.c: New file.
10067
10068 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10069
10070         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
10071         name (relative to the original working directory) and the file
10072         name component (relative to the temporary working directory).  All
10073         callers changed.
10074         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
10075         * lib/mkdir-p.c (make_dir_parents): Likewise.
10076         * lib/mkdir-p.h (make_dir_parents): Likewise.
10077
10078 2006-10-06  Eric Blake  <ebb9@byu.net>
10079
10080         Define several macros for use by the clean-temp module.
10081         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
10082         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
10083         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
10084
10085         * lib/clean-temp.h (close_stream_temp): New declaration.
10086         * lib/clean-temp.c (includes): Pull in headers according to what
10087         other modules are in use.
10088         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
10089
10090 2006-10-06  Bruno Haible  <bruno@clisp.org>
10091
10092         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
10093         instead of fopen, fwriteerror.
10094
10095 2006-10-06  Bruno Haible  <bruno@clisp.org>
10096
10097         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
10098         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
10099         int.
10100         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
10101         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
10102         Return an error indicator.
10103         Suggested by Eric Blake.
10104
10105 2006-10-06  Bruno Haible  <bruno@clisp.org>
10106
10107         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
10108         Reported by Eric Blake.
10109
10110 2006-10-06  Bruno Haible  <bruno@clisp.org>
10111
10112         * modules/closeout (Description): Mention stderr too.
10113
10114 2006-10-06  Bruno Haible  <bruno@clisp.org>
10115         and Paul Eggert  <eggert@cs.ucla.edu>
10116
10117         * lib/closeout.c (close_stdout): Also close stderr.
10118         * lib/closeout.h: Update comment.
10119
10120 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10121
10122         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
10123         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
10124         * lib/dirchownmod.c: Include lchown.h.
10125         * lib/lchown.c: Don't include files that lchown.h now includes.
10126         Don't declare chown, since lchown.h now does that.
10127         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
10128         (lchown): Define to rpl_chown if lchown is declared but
10129         does not exist.  Declare using a prototype if lchown is not
10130         declared.  Add a copyright notice.
10131         * lib/mkstemp.h: Include <unistd.h>.
10132         * lib/openat.c: Include lchown.h.
10133
10134         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
10135         we now test for that separately.
10136         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
10137         rather than O_NOFOLLOW, when testing whether it's possible to
10138         avoid a race condition reliably.
10139         * lib/savewd.c (savewd_chdir): Likewise.
10140
10141         Remove macros that are no longer needed now that stdint.h is
10142         reliable.
10143         * lib/fsusage.c (UINTMAX_MAX): Remove.
10144         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
10145         * lib/utimecmp.c (SIZE_MAX): Remove.
10146
10147         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
10148
10149         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
10150         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
10151         O_NOATIME works.
10152
10153 2006-10-05  Bruno Haible  <bruno@clisp.org>
10154
10155         * lib/gl_list.h (gl_sortedlist_search_from_to,
10156         gl_sortedlist_indexof_from_to): New declarations.
10157         (gl_list_implementation): New fields sortedlist_search_from_to,
10158         sortedlist_indexof_from_to.
10159         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
10160         inline functions.
10161         * lib/gl_list.c (gl_sortedlist_search_from_to,
10162         gl_sortedlist_indexof_from_to): New functions.
10163         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
10164         function.
10165         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
10166         (gl_array_sortedlist_search_from_to): New function.
10167         (gl_array_list_implementation): Update.
10168         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
10169         function.
10170         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
10171         (gl_carray_sortedlist_search_from_to): New function.
10172         (gl_carray_list_implementation): Update.
10173         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
10174         gl_linked_sortedlist_indexof_from_to): New functions.
10175         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10176         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10177         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
10178         gl_tree_sortedlist_indexof_from_to): New functions.
10179         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10180         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10181         Update.
10182         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10183         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
10184         Update.
10185
10186 2006-10-05  Bruno Haible  <bruno@clisp.org>
10187
10188         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
10189         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
10190         (struct gl_list_implementation): Add fields search_from_to,
10191         indexof_from_to. Remove fields search, indexof.
10192         (gl_list_search): Use the search_from_to method.
10193         (gl_list_search_from, gl_list_search_from_to): New functions.
10194         (gl_list_indexof): Use the indexof_from_to method.
10195         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10196         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
10197         (gl_list_search_from, gl_list_search_from_to): New functions.
10198         (gl_list_indexof): Use the indexof_from_to method.
10199         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10200         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
10201         gl_array_indexof. Add start_index, end_index arguments.
10202         (gl_array_search_from_to): Renamed from gl_array_search. Add
10203         start_index, end_index arguments.
10204         (gl_array_remove, gl_array_list_implementation): Update.
10205         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
10206         gl_carray_indexof. Add start_index, end_index arguments.
10207         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
10208         start_index, end_index arguments.
10209         (gl_carray_remove, gl_carray_list_implementation): Update.
10210         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
10211         gl_linked_search. Add start_index, end_index arguments.
10212         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
10213         start_index, end_index arguments.
10214         (gl_linked_remove): Update.
10215         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10216         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10217         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
10218         field to 'size_t'.
10219         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
10220         gl_tree_search. Add start_index, end_index arguments.
10221         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10222         start_index, end_index arguments.
10223         (gl_tree_remove): Update.
10224         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10225         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10226         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
10227         function.
10228         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
10229         gl_tree_search. Add start_index, end_index arguments.
10230         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10231         start_index, end_index arguments.
10232         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10233         Update.
10234         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
10235
10236 2006-10-05  Bruno Haible  <bruno@clisp.org>
10237
10238         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
10239
10240         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
10241         fwriteerror_temp): New declarations.
10242         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
10243         (descriptors): New variable.
10244         (cleanup): First, close the descriptors.
10245         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
10246         fclose_temp, fwriteerror_temp): New functions.
10247
10248 2006-10-04  Jim Meyering  <jim@meyering.net>
10249
10250         * lib/fts.c (fts_open): Tiny comment change.
10251
10252 2006-10-04  Bruno Haible  <bruno@clisp.org>
10253
10254         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
10255         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
10256         gl_LOCK_BODY.
10257         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
10258         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
10259         gl_LOCK_EARLY_BODY.
10260         (gl_LOCK): Require gl_LOCK_BODY.
10261
10262 2006-10-04  Bruno Haible  <bruno@clisp.org>
10263
10264         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
10265         (gl_oset_search_atleast): New declaration.
10266         (struct gl_oset_implementation): Add field 'search_atleast'.
10267         (gl_oset_search_atleast): New inline function.
10268         * lib/gl_oset.c (gl_oset_search_atleast): New function.
10269         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
10270         (gl_array_oset_implementation): Update.
10271         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
10272         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
10273         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
10274
10275 2006-10-04  Bruno Haible  <bruno@clisp.org>
10276
10277         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
10278
10279 2006-10-03  Bruno Haible  <bruno@clisp.org>
10280
10281         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
10282         from gl_avltreehash_list_implementation.
10283
10284 2006-10-03  Bruno Haible  <bruno@clisp.org>
10285
10286         * lib/gl_oset.c (gl_oset_add): Fix return type.
10287
10288 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
10289
10290         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
10291
10292 2006-10-02  Eric Blake  <ebb9@byu.net>
10293
10294         * modules/strnlen (Depends-on): Add extensions.
10295
10296 2006-10-02  Eric Blake  <ebb9@byu.net>
10297
10298         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
10299         definition in 2.60+.
10300
10301 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
10302
10303         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
10304         checks.
10305
10306 2006-10-02  Bruno Haible  <bruno@clisp.org>
10307
10308         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
10309         to the AUTOMAKE_OPTIONS.
10310         Reported by Jim Meyering.
10311
10312 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10313
10314         Work around bug in Solaris 10 /proc file system:
10315         /proc/self/fd/NNN/.. isn't the parent directory of
10316         the directory whose file descriptor is NNN.  This needs to
10317         be worked around at run time, not compile time, since a
10318         program might be built on Solaris 8, where things work, and
10319         run on Solaris 10.
10320         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
10321         to use the following interface instead:
10322         (OPENAT_BUFFER_SIZE): New macro.
10323         (openat_proc_name): New function.
10324         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
10325         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
10326         Likewise.
10327         * lib/openat-proc.c: New file.
10328         * modules/openat (Files): Add lib/openat-proc.c.
10329         (Depends-on): Add same-inode, stdbool.
10330         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
10331
10332 2006-09-29  Bruno Haible  <bruno@clisp.org>
10333
10334         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
10335         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
10336         argument. Set stdout_closed before testing for ferror, not after.
10337         (fwriteerror, fwriteerror_no_ebadf): New functions.
10338
10339 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10340
10341         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
10342
10343 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
10344
10345         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
10346         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
10347
10348 2006-09-28  Jim Meyering  <jim@meyering.net>
10349
10350         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
10351         Include <unistd.h>.
10352
10353 2006-09-28  Bruno Haible  <bruno@clisp.org>
10354
10355         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
10356         * modules/linkedhash-list (Depends-on): Likewise.
10357         * modules/rbtreehash-list (Depends-on): Likewise.
10358
10359 2006-09-28  Bruno Haible  <bruno@clisp.org>
10360
10361         * lib/strndup.h: Simplify the redefinition of strndup.
10362         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
10363         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
10364
10365 2006-09-28  Bruno Haible  <bruno@clisp.org>
10366
10367         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
10368         * lib/gl_linkedhash_list.c: Likewise.
10369         * lib/gl_rbtreehash_list.c: Likewise.
10370
10371 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10372
10373         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
10374         getaddrinfo.
10375
10376         * lib/__fpending.h: Don't include <stdio_ext.h> unless
10377         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
10378         it causes <stdio_ext.h> to cause a compile-time error.
10379         Problem reported by Nelson H. F. Beebe.
10380         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
10381         of HAVE_DECL___PENDING.
10382
10383         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
10384         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
10385         declaration.
10386
10387 2006-09-27  Jim Meyering  <jim@meyering.net>
10388
10389         This file could end up with a definition for a function
10390         named __strndup, rather than rpl_strndup on a system with
10391         incomplete weak_alias support.
10392         * lib/strndup.c (strndup): Rename from __strndup.
10393         Remove #defines that used to map __strndup to strndup.
10394         Don't use K&R prototypes.
10395         Remove LIBC-related code, since this file is not sync'd with glibc.
10396         * lib/strndup.h: Revamp, accordingly.
10397         * m4/strndup.m4: Modernize.
10398
10399 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10400
10401         * modules/savewd (Depends-on): Add 'raise'.
10402         * lib/savewd.c: Include <signal.h>, for 'raise'.
10403
10404 2006-09-26  Jim Meyering  <jim@meyering.net>
10405
10406         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10407         when we detect Darwin 8.7.0's acl_get_file bug.
10408         Rearrange to perform the new (below) run-test while $LIBS
10409         contains any acl-related library.  Set USE_ACL at the end.
10410         (gl_ACL_GET_FILE): New function.
10411
10412 2006-09-26  Eric Blake  <ebb9@byu.net>
10413
10414         * lib/verror.c: Include <config.h> unconditionally.
10415
10416 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10417
10418         * modules/clock-time (Maintainer): Add self.
10419         * modules/getlogin_r (Depends-on): Add extensions.
10420
10421 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10422
10423         * modules/clock-time: New module.
10424         * modules/nanosleep (Depends-on): Add clock-time.
10425         * modules/gethrxtime (Depends-on): Likewise.
10426         * modules/gettime (Depends-on): Likewise.
10427         * modules/settime (Depends-on): Likewise.
10428
10429         * modules/fts-lgpl: Depend on openat.
10430         * modules/mkancesdirs: Depend on savewd.
10431         * modules/mkdir-p: Likewise.
10432
10433 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10434
10435         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10436
10437         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10438         `gl_have_arbitrary_file_name_length_limit' to
10439         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10440         actually works between configure runs.
10441
10442 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10443             Bruno Haible  <bruno@clisp.org>
10444
10445         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10446
10447 2006-09-25  Jim Meyering  <jim@meyering.net>
10448
10449         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10450         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10451
10452 2006-09-25  Eric Blake  <ebb9@byu.net>
10453
10454         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10455         exec's in 2006-09-18 patch when shuffling fds.
10456
10457 2006-09-25  Bruno Haible  <bruno@clisp.org>
10458
10459         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10460         Reported by Jim Meyering.
10461
10462 2006-09-24  Jim Meyering  <jim@meyering.net>
10463
10464         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10465         compare a pointer against a literal "0".  That caused failures with
10466         at least HP-UX's hpcc.
10467
10468 2006-09-22  Simon Josefsson  <jas@extundo.com>
10469
10470         * modules/gc-sha1:
10471         * modules/gc-md4:
10472         * modules/gc-hmac-sha1:
10473         * modules/gc-hmac-md5:
10474         * modules/gc-des:
10475         * modules/gc-arcfour: Distribute more files.
10476
10477 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10478
10479         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10480         (gl_linked_iterator_from_to): Initialize struct completely.
10481         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10482         (gl_tree_iterator_from_to): Likewise
10483         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10484         * lib/gl_array_list.c [lint] (gl_array_iterator)
10485         (gl_array_iterator_from_to): Likewise.
10486         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10487         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10488         (gl_carray_iterator_from_to): Likewise.
10489
10490         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10491         * lib/md4.c (md4_process_block): Remove unused variable.
10492         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10493         parentheses for clarity.
10494
10495 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10496
10497         * modules/bison-i18n (Depends-on): Add gettext.
10498
10499 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10500
10501         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10502         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10503         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10504         also add missing comma that caused broken test.
10505         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10506         stdlib.h, for `abort'.
10507         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10508         variables.
10509         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10510         include unistd.h if present, for `rmdir'.
10511         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10512         variables.
10513         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10514         in the process include standard headers for prototypes.
10515         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10516         gets declared on GNU/Linux.
10517         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10518         unistd.h, for `rmdir'.
10519         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10520
10521         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10522         always true.
10523         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10524
10525         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10526
10527 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10528
10529         * gnulib-tool (func_version): Create output all at once.  This
10530         may help avoid triggering unnecessary SIGPIPEs, and at any
10531         rate it doesn't hurt.
10532
10533 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10534             Bruno Haible  <bruno@clisp.org>
10535
10536         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10537         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10538         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10539
10540         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10541         (gl_FUNC_VASPRINTF): Invoke it.
10542
10543 2006-09-22  Bruno Haible  <bruno@clisp.org>
10544
10545         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10546         getloadavg.c as first argument.
10547
10548 2006-09-22  Bruno Haible  <bruno@clisp.org>
10549
10550         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10551         at the beginning of the gl_INIT macro.
10552         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10553         gl_GETLOADAVG.
10554
10555 2006-09-22  Bruno Haible  <bruno@clisp.org>
10556
10557         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10558         module.
10559         Suggested by Ralf Wildenhues.
10560
10561 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10562
10563         Import this patch from libc:
10564
10565         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10566
10567         * lib/regex_internal.c (re_string_reconstruct): Handle
10568         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10569         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10570         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10571         re_string_context_at.
10572
10573         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10574         now requires it.
10575         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10576         gl_REGEX now does it for us.
10577         (gl_REGEX): Add test taken from
10578         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10579
10580         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10581         Check that large offsets work.  Modernize Autoconf usages.
10582         Prefer "yes" to mean a good thing rather than a bad.
10583         Don't put "#define mkstemp" in config.h, as this might interfere
10584         with standard system headers that "#define mkstemp mkstemp64".
10585
10586         * modules/mkstemp (Depends-on): Add extensions, so that
10587         mkstemp is visible on some platforms.
10588         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
10589         (Include): Change to "mkstemp.h" from <stdlib.h>.
10590         (Files): Add mkstemp.h.
10591
10592         * lib/mkstemp.h: New file, since some standard headers
10593         #define mkstemp.
10594         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
10595         Include "mkstemp.h".
10596         Make the _LIBC code resemble glibc original more,
10597         e.g., use K&R style.
10598         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
10599         (mkstemp): Remove, since mkstemp.h does this for us.
10600         * lib/stdlib--.h: Include mkstemp.h.
10601
10602         Import this patch from libc:
10603
10604         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10605
10606         * lib/tempname.c (__gen_tempname): Change attempts_min
10607         into a macro.  Use preprocessor to decide how to initialize
10608         attempts [Coverity CID 67].
10609
10610 2006-09-20  Bruno Haible  <bruno@clisp.org>
10611
10612         * lib/mkdtemp.c: Import from libc.
10613         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10614                 * sysdeps/posix/tempname.c (__gen_tempname): Change
10615                 attempts_min into a macro.  Use preprocessor to decide how to
10616                 initialize attempts [Coverity CID 67].
10617         2001-11-27  Paul Eggert  <eggert@twinsun.com>
10618                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
10619                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
10620
10621 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10622
10623         * gnulib-tool (func_exit): New function, to allow to pass the
10624         exit status portably through the trap.  Use everywhere.
10625         (--help, --version): Signal a write error.
10626         (trap): catch SIGPIPE, for write errors.
10627         Exit at the end of the trap, with the correct exit status.
10628
10629 2006-09-19  Karl Berry  <karl@gnu.org>
10630
10631         * doc/gnulib.texi: note about the license texinfo files.
10632
10633 2006-09-19  Eric Blake  <ebb9@byu.net>
10634
10635         * gnulib-tool: Avoid space-tab.
10636
10637 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10638
10639         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
10640         that prevented coreutils 6.1 from building.  Problem reported
10641         by Petter Reinholdtsen.
10642
10643 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10644
10645         * gnulib-tool (avoidlist): Fix typo that broke options like
10646         --avoid=lock that are used by coreutils bootstrap.
10647
10648 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
10649
10650         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
10651         more systematically.
10652
10653 2006-09-18  Jim Meyering  <jim@meyering.net>
10654
10655         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
10656
10657 2006-09-18  Bruno Haible  <bruno@clisp.org>
10658
10659         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
10660
10661 2006-09-18  Bruno Haible  <bruno@clisp.org>
10662
10663         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
10664         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
10665         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
10666         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
10667         * m4/gettext.m4: Require autoconf >= 2.52.
10668         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
10669         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
10670         of gl_cv_header_inttypes_h.
10671
10672 2006-09-18  Bruno Haible  <bruno@clisp.org>
10673
10674         * lib/javaversion.c: Include configmake.h.
10675
10676 2006-09-18  Bruno Haible  <bruno@clisp.org>
10677
10678         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
10679         avoid that the while loops be executed in a subshell.
10680
10681 2006-09-18  Bruno Haible  <bruno@clisp.org>
10682
10683         * MODULES.html.sh (func_module): Break long lines.
10684         Suggested by Bruce Korb <bkorb@gnu.org>.
10685
10686 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10687
10688         Speed up by a factor of 1.12.
10689         * gnulib-tool (nl): New variable.
10690         (func_import): Rewrite include directive extraction to only read each
10691         directive once.
10692
10693 2006-09-17  Bruno Haible  <bruno@clisp.org>
10694
10695         * modules/javaversion (Makefile.am): Remove DEFS setting.
10696         (Depends-on): Add configmake, for PKGDATADIR definition.
10697
10698 2006-09-17  Bruno Haible  <bruno@clisp.org>
10699
10700         * gnulib-tool (func_create_testdir): Rewrite all files at once.
10701
10702 2006-09-17  Bruno Haible  <bruno@clisp.org>
10703
10704         * gnulib-tool (func_append): New function, stolen from libtool.m4.
10705         (func_modules_transitive_closure, func_modules_add_dummy,
10706         func_modules_to_filelist, func_import, func_create_testdir,
10707         func_create_megatestdir, ...): Use it wherever possible.
10708         Suggested by Ralf Wildenhues.
10709
10710 2006-09-16  Karl Berry  <karl@gnu.org>
10711
10712         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
10713         to avoid sectioning errors.
10714         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
10715         [ifinfo]: blank line after @center-ed titles.
10716         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
10717         Spell FSF address consistently with others.
10718         (These changes approved by rms.)
10719
10720 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10721
10722         Speed up by a factor of 1.61.
10723         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
10724         already checked module names again.
10725
10726 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10727
10728         Speed up by a factor of 1.13.
10729         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
10730         for new_files, and the input to func_add_or_update.
10731
10732 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10733
10734         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
10735         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
10736
10737 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10738
10739         * modules/mkancesdirs (Depends-on): Add fcntl.
10740         * modules/savewd: New file.
10741         * MODULES.html.sh (File system functions): Add savewd.
10742
10743         * modules/configmake (Makefile.am): Add support for the
10744         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
10745
10746 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10747
10748         * m4/savewd.m4: New file.
10749
10750 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10751
10752         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
10753         (dirchownmod): New arg FD.  All callers changed.
10754         Use FD rather than opening the directory ourself, as opening is
10755         now the caller's responsibility.
10756         * lib/dirchownmod.h: Likewise.
10757         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
10758         hosts that require <sys/types.h> before <sys/stat.h>.  Include
10759         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
10760         (test_dir): Remove.
10761         (mkancesdirs): Return length of prefix of FILE that has already
10762         been made, or -2 if there is a child doing the work.  Redo
10763         algorithm so that it is O(N) rather than O(N**2).  Optimize away
10764         ".", and treat ".." specially since it might stray back into
10765         already-created areas.  Use a subprocess if necessary.  New arg
10766         WD; all users changed.  MAKE_DIR function should now return 1
10767         if it creates a directory that is not readable.  Return -2 if
10768         a child process is spun off.
10769         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
10770         Adjust signature to match code.
10771         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
10772         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
10773         all users changed.
10774         * lib/savewd.c, lib/savewd.h: New files.
10775
10776 2006-09-15  Jim Meyering  <jim@meyering.net>
10777
10778         * modules/rename-dest-slash: New module.
10779         * MODULES.html.sh (posix_compat): Add it here.
10780
10781         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
10782
10783 2006-09-15  Jim Meyering  <jim@meyering.net>
10784
10785         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
10786         file.
10787
10788         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
10789
10790 2006-09-15  Jim Meyering  <jim@meyering.net>
10791
10792         * lib/rename-dest-slash.c (has_trailing_slash): Use
10793         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
10794         (rpl_rename_dest_slash): Perform the cheaper trailing slash
10795         test before testing whether SRC is a directory.
10796         Suggestions from Bruno Haible.
10797
10798         Avoid a warning about an unused variable.
10799         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
10800         into the #ifdef block where it's used.
10801
10802         * lib/rename-dest-slash.c: New file.
10803
10804 2006-09-14  Bruno Haible  <bruno@clisp.org>
10805
10806         * lib/allocsa.c: Include <config.h> unconditionally.
10807         * lib/asnprintf.c: Likewise.
10808         * lib/asprintf.c: Likewise.
10809         * lib/c-strcasecmp.c: Likewise.
10810         * lib/c-strcasestr.c: Likewise.
10811         * lib/c-strncasecmp.c: Likewise.
10812         * lib/c-strstr.c: Likewise.
10813         * lib/classpath.c: Likewise.
10814         * lib/clean-temp.c: Likewise.
10815         * lib/concatpath.c: Likewise.
10816         * lib/copy-file.c: Likewise.
10817         * lib/csharpcomp.c: Likewise.
10818         * lib/csharpexec.c: Likewise.
10819         * lib/execute.c: Likewise.
10820         * lib/fatal-signal.c: Likewise.
10821         * lib/findprog.c: Likewise.
10822         * lib/fwriteerror.c: Likewise.
10823         * lib/gl_array_list.c: Likewise.
10824         * lib/gl_array_oset.c: Likewise.
10825         * lib/gl_avltree_list.c: Likewise.
10826         * lib/gl_avltree_oset.c: Likewise.
10827         * lib/gl_avltreehash_list.c: Likewise.
10828         * lib/gl_carray_list.c: Likewise.
10829         * lib/gl_linked_list.c: Likewise.
10830         * lib/gl_linkedhash_list.c: Likewise.
10831         * lib/gl_list.c: Likewise.
10832         * lib/gl_oset.c: Likewise.
10833         * lib/gl_rbtree_list.c: Likewise.
10834         * lib/gl_rbtree_oset.c: Likewise.
10835         * lib/gl_rbtreehash_list.c: Likewise.
10836         * lib/imaxabs.c: Likewise.
10837         * lib/imaxdiv.c: Likewise.
10838         * lib/javacomp.c: Likewise.
10839         * lib/javaexec.c: Likewise.
10840         * lib/javaversion.c: Likewise.
10841         * lib/linebreak.c: Likewise.
10842         * lib/localcharset.c: Likewise.
10843         * lib/lock.c: Likewise.
10844         * lib/mbchar.c: Likewise.
10845         * lib/mbswidth.c: Likewise.
10846         * lib/mkdtemp.c: Likewise.
10847         * lib/pipe.c: Likewise.
10848         * lib/printf-args.c: Likewise.
10849         * lib/printf-parse.c: Likewise.
10850         * lib/progname.c: Likewise.
10851         * lib/progreloc.c: Likewise.
10852         * lib/readlink.c: Likewise.
10853         * lib/sh-quote.c: Likewise.
10854         * lib/stpcpy.c: Likewise.
10855         * lib/stpncpy.c: Likewise.
10856         * lib/strcasecmp.c: Likewise.
10857         * lib/strcasestr.c: Likewise.
10858         * lib/strcspn.c: Likewise.
10859         * lib/striconv.c: Likewise.
10860         * lib/strncasecmp.c: Likewise.
10861         * lib/strnlen1.c: Likewise.
10862         * lib/strstr.c: Likewise.
10863         * lib/strtok_r.c: Likewise.
10864         * lib/tls.c: Likewise.
10865         * lib/tmpdir.c: Likewise.
10866         * lib/unicodeio.c: Likewise.
10867         * lib/unsetenv.c: Likewise.
10868         * lib/vasnprintf.c: Likewise.
10869         * lib/vasprintf.c: Likewise.
10870         * lib/wait-process.c: Likewise.
10871         * lib/xallocsa.c: Likewise.
10872         * lib/xsetenv.c: Likewise.
10873         * lib/xstriconv.c: Likewise.
10874
10875 2006-09-13  Simon Josefsson  <jas@extundo.com>
10876
10877         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
10878         that internally, suggested by Ralf Wildenhues
10879         <Ralf.Wildenhues@gmx.de>.
10880
10881 2006-09-13  Simon Josefsson  <jas@extundo.com>
10882
10883         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
10884         @LIBOBJS@.
10885         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10886
10887 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
10888
10889         * lib/_fpending.c: Include <config.h> unconditionally, since we no
10890         longer worry about uses that don't define HAVE_CONFIG_H.
10891         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
10892         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
10893         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
10894         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
10895         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
10896         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
10897         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
10898         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
10899         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
10900         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
10901         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
10902         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
10903         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
10904         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
10905         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
10906         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
10907         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
10908         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
10909         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
10910         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
10911         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
10912         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
10913         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
10914         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
10915         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
10916         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
10917         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
10918         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
10919         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
10920         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
10921         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
10922         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
10923         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
10924         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
10925         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
10926         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
10927         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
10928         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
10929         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
10930         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
10931         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
10932         Likewise.
10933
10934 2006-09-13  Eric Blake  <ebb9@byu.net>
10935
10936         * lib/getopt.c: Fix typo in last commit.
10937
10938 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
10939
10940         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
10941         dgettext.
10942
10943 2006-09-12  Jim Meyering  <jim@meyering.net>
10944
10945         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
10946         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
10947         Reported by Nelson H. F. Beebe.
10948
10949 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
10950
10951         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
10952         program_invocation_name and program_invocation_short_name are
10953         initialized.
10954         * lib/argp-namefrob.h: Move declarations of program_invocation_name
10955         and program_invocation_short_name to argp.h, so they are visible
10956         to user programs.
10957         * lib/argp.h: Likewise
10958
10959 2006-09-10  Bruno Haible  <bruno@clisp.org>
10960
10961         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
10962         m4/inttypes_h.m4, m4/uintmax_t.m4.
10963
10964 2006-09-10  Bruno Haible  <bruno@clisp.org>
10965
10966         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
10967         gl_AC_TYPE_UINTMAX_T.
10968
10969 2006-09-10  Bruno Haible  <bruno@clisp.org>
10970
10971         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
10972
10973 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
10974
10975         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
10976         convention.  Text proposed by Bruno Haible.
10977         (struct argp_option): Document the use of N_() wrappers.
10978
10979         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
10980         '\v', and translate the two parts separately, instead of feeding
10981         the whole string to gettext.  This allows to exclude
10982         '\v' from the strings visible to the translator by writing doc
10983         strings as N_("..") "\v" N_("..").
10984
10985 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
10986
10987         * config/srclist.txt: Undo latest change; the bug was fixed.
10988
10989 2006-09-09  Bruno Haible  <bruno@clisp.org>
10990
10991         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
10992         assignments if building a library without libtool.
10993         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
10994         in func_emit_lib_Makefile_am.
10995         (func_import): When building a static library libfoo.a, arrange to
10996         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
10997         (func_create_testdir): Likewise.
10998         * modules/gc (configure.ac, Makefile.am): If building statically,
10999         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
11000         * modules/iconvme (configure.ac, Makefile.am): Likewise.
11001         * modules/striconv (configure.ac, Makefile.am): Likewise.
11002         Based on a suggestion by Ralf Wildenhues.
11003
11004 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11005
11006         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
11007         Check for unistd.h too, since Autoconf doesn't assume POSIX.
11008         Also:
11009
11010         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11011         Add year_2050_test to catch glibc bug 2821
11012         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11013
11014         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11015         Prefer #ifdef to #if.
11016
11017         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
11018         Return from 'main' instead of calling 'exit'.
11019
11020 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11021
11022         * lib/mktime.c (guess_time_tm): Fix bug where mktime
11023         returned the maximum time_t value rather than (time_t) -1.
11024         Problem originally reported by William Bardwell
11025         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11026
11027         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11028         Moved to here ...
11029         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11030         ... from here.
11031
11032 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11033
11034         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
11035         2821 is fixed.
11036
11037 2006-09-08  Jim Meyering  <jim@meyering.net>
11038
11039         Don't make generated files read-only.  That would bother too many
11040         people.  However, do retain the ability to work when targets are
11041         read-only: remove the destination and temporary files before writing
11042         them (when generated via sed or echo), or by using the -f option for
11043         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
11044         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11045         * modules/byteswap, modules/configmake, modules/fcntl:
11046         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11047         * modules/localcharset, modules/netinet_in, modules/poll:
11048         * modules/stdbool, modules/stdint, modules/sys_select:
11049         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11050
11051 2006-09-08  Jim Meyering  <jim@meyering.net>
11052
11053         Avoid new build failure on FreeBSD 6.0.
11054         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
11055         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
11056         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
11057
11058 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11059
11060         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
11061
11062 2006-09-07  Jim Meyering  <jim@meyering.net>
11063
11064         Fix global typo in last change: use chmod u-w, not chmod u-x.
11065         Spotted by Paul Eggert and Bruce Korb.
11066         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11067         * modules/byteswap, modules/configmake, modules/fcntl:
11068         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11069         * modules/localcharset, modules/netinet_in, modules/poll:
11070         * modules/stdbool, modules/stdint, modules/sys_select:
11071         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11072
11073 2006-09-06  Jim Meyering  <jim@meyering.net>
11074
11075         Make generated files be read-only.
11076         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
11077         Ensure that each generated file is now read-only.
11078         * modules/argz: Likewise.
11079         * modules/arpa_inet: Likewise.
11080         * modules/byteswap: Likewise.
11081         * modules/configmake: Likewise.
11082         * modules/fcntl: Likewise.
11083         * modules/fnmatch: Likewise.
11084         * modules/getopt: Likewise.
11085         * modules/glob: Likewise.
11086         * modules/inttypes: Likewise.
11087         * modules/netinet_in: Likewise.
11088         * modules/poll: Likewise.
11089         * modules/stdbool: Likewise.
11090         * modules/stdint: Likewise.
11091         * modules/sys_select: Likewise.
11092         * modules/sys_socket: Likewise.
11093         * modules/sys_stat: Likewise.
11094         * modules/sysexits: Likewise.
11095         * modules/localcharset: Same as above, but continue using temporary
11096         file named "t-$@" (why different?) rather than the "$@-t" used
11097         everywhere else.
11098
11099         * modules/sysexits (Makefile.am): Replace literal occurrences
11100         of "sysexit.h" more readable, and more consistent, "$@".
11101
11102 2006-09-06  Bruno Haible  <bruno@clisp.org>
11103
11104         * modules/striconv: New file.
11105         * modules/xstriconv: New file.
11106         * MODULES.html.sh (Internationalization functions): Add striconv,
11107         xstriconv.
11108
11109 2006-09-06  Bruno Haible  <bruno@clisp.org>
11110
11111         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
11112         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
11113         not using libtool correctly.
11114
11115 2006-09-06  Bruno Haible  <bruno@clisp.org>
11116
11117         * lib/striconv.h: New file.
11118         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
11119         iconvstring.c.
11120         * lib/xstriconv.h: New file.
11121         * lib/xstriconv.c: New file.
11122
11123 2006-09-06  Bruno Haible  <bruno@clisp.org>
11124
11125         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
11126         lib_..._LDFLAGS.
11127
11128 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11129
11130         * lib/argz_.h: Sync from Libtool.
11131
11132         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
11133                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11134
11135         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
11136
11137 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11138
11139         * modules/trim: New file.
11140
11141 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11142
11143         * lib/trim.h: New file.
11144         * lib/trim.c: New file.
11145
11146 2006-09-05  Bruno Haible  <bruno@clisp.org>
11147
11148         * MODULES.html.sh (String handling): Add trim.
11149
11150 2006-09-04  Karl Berry  <karl@gnu.org>
11151
11152         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
11153         until next release.
11154
11155 2006-09-03  Bruno Haible  <bruno@clisp.org>
11156
11157         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
11158         correctly.
11159
11160 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11161
11162         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
11163         not gl_GETLOADAVG.  Omit unneeded semicolons.
11164         Problems reported by Ralf Wildenhues in
11165         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11166         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
11167         at the end, which is the usual gnulib style.
11168
11169         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
11170         of doing all the work ourselves.
11171         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
11172         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
11173
11174 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11175
11176         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
11177         Problem reported by Ralf Wildenhues in
11178         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11179
11180         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
11181         HAVE_STRUCT_STATFS_F_FSTYPENAME.
11182
11183 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11184
11185         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
11186         yesterday's patch by changing test -n to test -z.
11187
11188 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11189
11190         * modules/getloadavg (Files): Add m4/getloadavg.m4.
11191         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
11192         the former is now obsolescent.
11193
11194         * modules/chdir-long (Depends-on): Add fcntl.
11195
11196 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11197
11198         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
11199         obsolescent, and programs should use gnulib instead.
11200         * m4/getloadavg.m4: New file, with contents taken from Autoconf
11201         but with prefixes changed.
11202
11203 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11204
11205         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
11206         or stdbool.h, because they might not exist while configuring.
11207
11208         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
11209         Don't include unistd.h or limits.h; not needed, since chdir-long.h
11210         does that for us.
11211         (O_DIRECTORY): Remove.
11212
11213 2006-08-31  Eric Blake  <ebb9@byu.net>
11214
11215         * gnulib-tool: Don't let emacs change spaces to TAB.
11216
11217 2006-08-31  Bruno Haible  <bruno@clisp.org>
11218
11219         * gnulib-tool: When calling func_import more than once, do it in a
11220         subshell.
11221         Reported by Eric Blake <ebb9@byu.net>.
11222
11223 2006-08-31  Bruno Haible  <bruno@clisp.org>
11224
11225         * gnulib-tool (nl): Remove variable.
11226         (sed_transform_lib_file): Use more robust test for config-h module.
11227         (func_import): Fix typo in 2006-08-25 patch.
11228
11229 2006-08-31  Bruno Haible  <bruno@clisp.org>
11230
11231         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
11232         specified, augment Makefile.am variables instead of assigning them.
11233
11234 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11235
11236         Work around a bug in both the Linux and SunOS 64-bit kernels:
11237         nanosleep mishandles sleeps for longer than 2**31 seconds.
11238         Problem reported by Frank v Waveren in
11239         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11240         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
11241         Check for nanosleep bug.
11242         (LIB_NANOSLEEP): Append clock_gettime library if needed.
11243
11244 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11245
11246         Work around a bug in both the Linux and SunOS 64-bit kernels:
11247         nanosleep mishandles sleeps for longer than 2**31 seconds.
11248         Problem reported by Frank v Waveren in
11249         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11250         * lib/nanosleep.c (BILLION): New constant.
11251         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
11252         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
11253         implementation.
11254
11255 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11256
11257         * modules/nanosleep (Depends-on): Add gettime.
11258
11259 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11260         and Simon Josefsson  <jas@extundo.com>
11261         and Oskar Liljeblad  <oskar@osk.mine.nu>
11262
11263         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
11264         * gnulib-tool (func_import): New license type 'unmodifiable license
11265         text'.
11266         * modules/fdl: Use it.  Longer description.
11267         * module/gpl, module/lgpl: New files.
11268
11269 2006-08-30  Jim Meyering  <jim@meyering.net>
11270
11271         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
11272         shadowing the parameter.
11273
11274 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11275
11276         Sync from Libtool:
11277
11278         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11279
11280         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
11281         sharing with gnulib.  Report by Eric Blake.
11282
11283 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11284
11285         * modules/isapipe: New file.
11286         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
11287
11288 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11289
11290         * modules/configmake (Makefile.am): Add a comment, and omit
11291         the CONFIGMAKE_ prefix from generated macro names.  Suggested
11292         by Bruno Haible.
11293
11294 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11295
11296         * m4/isapipe.m4: New file.
11297
11298 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11299
11300         * lib/isapipe.c, lib/isapipe.h: New files.
11301
11302 2006-08-29  Jim Meyering  <jim@meyering.net>
11303
11304         * modules/configmake (Makefile.am): Make configmake.h depend on
11305         Makefile.  Otherwise, a stale configmake.h could hang around.
11306
11307 2006-08-29  Eric Blake  <ebb9@byu.net>
11308
11309         * lib/error.c (error_at_line, print_errno_message): Match libc, after
11310         resolution of upstream bug 3044.
11311
11312 2006-08-29  Bruno Haible  <bruno@clisp.org>
11313
11314         * modules/localcharset (Depends-on): Add configmake.
11315         (Makefile.am): Remove setting of LIBDIR through DEFS.
11316
11317 2006-08-29  Bruno Haible  <bruno@clisp.org>
11318
11319         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
11320         defined.
11321
11322 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11323
11324         * modules/fcntl: New file.
11325         * modules/chdir-safer (Depends-on): Add fcntl.
11326         * modules/fts: Likewise.
11327         * modules/mkdir-p: Likewise.
11328
11329         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
11330         This undoes the most recent change, since we're now addressing the
11331         problem in a different way.
11332
11333         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
11334         into output, since the output might be called Makefile.am even
11335         if $makefile_name is something different.
11336         (func_import): Use $makefile_am rather than
11337         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
11338         empty.
11339
11340         * modules/inttypes (Files): Add m4/inttypes-h.m4.
11341
11342 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11343
11344         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
11345         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
11346         recent change to stdint.m4, since we're now addressing the problem in a
11347         different way.
11348
11349 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11350
11351         * m4/fcntl_h.m4: New file.
11352
11353 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11354
11355         * lib/fcntl_.h: New file.
11356         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
11357         the fcntl module.
11358         * lib/dirchownmod.c: Likewise.
11359         * lib/fts.c: Likewise.
11360
11361         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
11362         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
11363         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
11364         just before including <inttypes.h>, to avoid circular inclusion.
11365
11366 2006-08-28  Jim Meyering  <jim@meyering.net>
11367
11368         * doc/visibility.texi: Actually read and correct the grammar of the
11369         sentence affected by yesterday's change.
11370
11371 2006-08-28  Eric Blake  <ebb9@byu.net>
11372
11373         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
11374         needs wrapper.
11375
11376 2006-08-28  Eric Blake  <ebb9@byu.net>
11377
11378         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
11379
11380 2006-08-28  Eric Blake  <ebb9@byu.net>
11381
11382         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
11383
11384 2006-08-28  Bruno Haible  <bruno@clisp.org>
11385
11386         * modules/c-strstr: New file, from GNU gettext.
11387         * MODULES.html.sh (String handling): Add c-strstr.
11388
11389 2006-08-28  Bruno Haible  <bruno@clisp.org>
11390
11391         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
11392         macros.
11393         Reported by Eric Blake.
11394
11395 2006-08-28  Bruno Haible  <bruno@clisp.org>
11396
11397         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
11398         (VASNPRINTF): Return a string of length > INT_MAX without failing.
11399         * lib/vasprintf.c: Include errno.h, limits.h.
11400         (EOVERFLOW): New fallback definition.
11401         (vasprintf): Test here whether the string length is > INT_MAX.
11402         * lib/vsnprintf.c: Include errno.h, limits.h.
11403         (EOVERFLOW): New fallback definition.
11404         (vsnprintf): Fix bug when generated string was too long for the buffer.
11405         Test here whether the string length is > INT_MAX.
11406
11407 2006-08-28  Bruno Haible  <bruno@clisp.org>
11408
11409         * lib/inttypes_.h (SCNX*): Remove definitions.
11410         Reported by Eric Blake.
11411
11412 2006-08-28  Bruno Haible  <bruno@clisp.org>
11413
11414         * lib/c-strstr.h: New file, from GNU gettext.
11415         * lib/c-strstr.c: New file, from GNU gettext.
11416
11417 2006-08-28  Bruno Haible  <bruno@clisp.org>
11418
11419         * gnulib-tool: Reorder some statements.
11420
11421 2006-08-28  Bruno Haible  <bruno@clisp.org>
11422
11423         * gnulib-tool: New option --makefile-name.
11424         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11425         $makefile_name.
11426         (func_import): Write $makefile_name to the cache file, and read it from
11427         there unless explicitly specified. Use $makefile_name as file name
11428         instead of Makefile.am. Adjust the recommendations accordingly.
11429
11430 2006-08-28  Bruno Haible  <bruno@clisp.org>
11431
11432         * gnulib-tool (func_verify_module): Check against misapplying patch.
11433
11434 2006-08-28  Bruno Haible  <bruno@clisp.org>
11435
11436         * gnulib-tool (func_relativize, func_relconcat): New functions.
11437         Give an error if --local-dir is given with --update.
11438         Remove trailing slashes from $local_gnulib_dir.
11439         (func_import): Store the relativized $local_gnulib_dir in
11440         gnulib-cache.m4, and read it from there if not specified explicitly.
11441
11442 2006-08-28  Bruno Haible  <bruno@clisp.org>
11443
11444         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11445         is the current directory. Respect also $local_gnulib_dir.
11446
11447 2006-08-28  Bruno Haible  <bruno@clisp.org>
11448             Simon Josefsson  <jas@extundo.com>
11449
11450         BeOS portability.
11451         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11452
11453 2006-08-27  Jim Meyering  <jim@meyering.net>
11454
11455         * doc/visibility.texi: Remove duplicate word: "pointer".
11456
11457 2006-08-26  Bruno Haible  <bruno@clisp.org>
11458
11459         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11460         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11461         (Makefile.am): Create inttypes.h from inttypes_.h.
11462         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11463
11464         * modules/imaxabs: New file.
11465
11466         * modules/imaxdiv: New file.
11467
11468 2006-08-26  Bruno Haible  <bruno@clisp.org>
11469
11470         * m4/inttypes.m4: New file.
11471         * m4/_inttypes_h.m4: Remove file.
11472         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11473         PRI_MACROS_BROKEN.
11474         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11475
11476         * m4/imaxabs.m4: New file.
11477
11478         * m4/imaxdiv.m4: New file.
11479
11480 2006-08-26  Bruno Haible  <bruno@clisp.org>
11481
11482         * lib/inttypes_.h: New file.
11483         * lib/inttypes.h: Remove file.
11484         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11485
11486         * lib/imaxabs.c: New file.
11487
11488         * lib/imaxdiv.c: New file.
11489
11490 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11491
11492         New config-h module, so that "make" output needn't be cluttered
11493         by -DHAVE_CONFIG_H.
11494         * MODULES.html.sh (Support for building libraries and executables):
11495         Add config-h.
11496         * modules/config-h: New file.
11497         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11498         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11499         the config-h module is used.
11500
11501         New configmake module, so that "make" output needn't be cluttered
11502         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11503         * MODULES.html.sh (Support for building libraries and executables):
11504         Add configmake.
11505         * modules/configmake: New file.
11506
11507 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11508
11509         * m4/config-h.m4: New file.
11510
11511 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11512
11513         * config/srclist.txt: Add elisp-comp.
11514
11515 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11516
11517         * MODULES.html.sh (Support for building libraries and executables):
11518         Add elisp-comp.
11519         * build-aux/elisp-comp: New file.
11520         * modules/elisp-comp: New file.
11521
11522 2006-08-24  Bruno Haible  <bruno@clisp.org>
11523
11524         * gnulib-tool (func_create_testdir): Use non-default values of
11525         sourcebase and m4base.
11526
11527 2006-08-24  Bruno Haible  <bruno@clisp.org>
11528
11529         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11530         HTML structure.
11531
11532 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11533
11534         * modules/openat (Depends-on): Add lchown.
11535
11536 2006-08-23  Bruno Haible  <bruno@clisp.org>
11537
11538         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11539         of gl_LOCK_EARLY instead of gl_LOCK.
11540
11541 2006-08-23  Bruno Haible  <bruno@clisp.org>
11542
11543         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11544         on OSF/1 to no.
11545         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11546
11547 2006-08-23  Bruno Haible  <bruno@clisp.org>
11548
11549         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11550         as unusable.
11551
11552         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11553         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11554         (gl_LOCK): New macro.
11555
11556 2006-08-22  Simon Josefsson  <jas@extundo.com>
11557
11558         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11559         to md5 module.
11560
11561 2006-08-22  Simon Josefsson  <jas@extundo.com>
11562
11563         * MODULES.html.sh: Add "Support for maintaining and release
11564         projects".
11565
11566         * build-aux/gnupload: New file, from coreutils.
11567
11568 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11569
11570         Avoid the need for AC_LIBSOURCES in m4 macros.
11571         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11572         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11573         * modules/check-version (EXTRA_DIST): Add check-version.h.
11574         * modules/crc (EXTRA_DIST): Add crc.h.
11575         * modules/des (EXTRA_DIST): Add des.h.
11576         * modules/gc (EXTRA_DIST): Add gc.h.
11577         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11578         * modules/getline (EXTRA_DIST): Add getline.h.
11579         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11580         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11581         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11582         * modules/md2 (EXTRA_DIST): Add md2.h.
11583         * modules/md4 (EXTRA_DIST): Add md4.h.
11584         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
11585         * modules/read-file (EXTRA_DIST): Add read-file.h.
11586         * modules/readline (EXTRA_DIST): Add readline.h.
11587         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
11588         rijndael-api-fst.h.
11589
11590 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11591
11592         * m4/rijndael.m4 (gl_ARCFOUR):
11593         * m4/arctwo.m4 (gl_ARCTWO):
11594         * m4/check-version.m4 (gl_CHECK_VERSION):
11595         * m4/crc.m4 (gl_CRC):
11596         * m4/des.m4 (gl_DES):
11597         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
11598         * m4/gc.m4 (gl_GC):
11599         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
11600         * m4/getline.m4 (gl_FUNC_GETLINE):
11601         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
11602         * m4/hmac-md5.m4 (gl_HMAC_MD5):
11603         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
11604         * m4/md2.m4 (gl_MD2):
11605         * m4/md4.m4 (gl_MD4):
11606         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
11607         * m4/read-file.m4 (gl_FUNC_READ_FILE):
11608         * m4/readline.m4 (gl_FUNC_READLINE):
11609         * m4/rijndael.m4 (gl_RIJNDAEL):
11610         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11611         to get the necessary .h files and whatnot.
11612
11613 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11614
11615         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
11616         gnulib rather than the other way around.
11617         * config/srclistvars.sh (COREUTILS): Remove.
11618
11619 2006-08-22  Jim Meyering  <jim@meyering.net>
11620
11621         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
11622
11623         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
11624
11625 2006-08-22  Eric Blake  <ebb9@byu.net>
11626
11627         * modules/regexprops-generic: New file.
11628         * MODULES.html.sh (Support for building documentation): List it.
11629
11630 2006-08-22  Eric Blake  <ebb9@byu.net>
11631
11632         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
11633         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
11634         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
11635         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
11636
11637 2006-08-22  Bruno Haible  <bruno@clisp.org>
11638
11639         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
11640         and lib_LTLIBRARIES like the other lib_* variables.
11641
11642 2006-08-22  Bruno Haible  <bruno@clisp.org>
11643
11644         * build-aux/x-to-1.in: New file, from GNU gettext.
11645
11646 2006-08-22  Bruno Haible  <bruno@clisp.org>
11647
11648         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
11649         <utmpx.h> exists.
11650
11651 2006-08-22  Bruno Haible  <bruno@clisp.org>
11652
11653         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
11654         <utmpx.h> exists.
11655
11656 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11657
11658         BeOS portability.
11659         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
11660         exist.
11661         Problem reported by Bruno Haible.
11662
11663 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11664
11665         Avoid the need for AC_LIBSOURCES in m4 macros.
11666         * modules/acl (EXTRA_DIST): Add acl.h.
11667         * modules/argmatch (Files): Add m4/argmatch.m4.
11668         (configure.ac): Add gl_ARGMATCH.
11669         (EXTRA_DIST): Renamed from lib_SOURCES, for
11670         consistency with the other modules.  Remove argmatch.c.
11671         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
11672         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
11673         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
11674         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
11675         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
11676         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
11677         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
11678         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
11679         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
11680         * modules/closeout (EXTRA_DIST): Add closeout.h.
11681         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
11682         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
11683         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
11684         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
11685         dirname.h; remove basename.c and stripslash.c.
11686         * modules/exclude (EXTRA_DIST): Add exclude.h.
11687         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
11688         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
11689         * modules/file-type (EXTRA_DIST): Add file-type.h.
11690         * modules/filemode (EXTRA_DIST): Add filemode.h.
11691         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
11692         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11693         * modules/fpending (EXTRA_DIST): Add __fpending.h.
11694         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
11695         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
11696         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
11697         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
11698         * modules/getdate (EXTRA_DIST): Add getdate.c.
11699         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
11700         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
11701         * modules/getpass (EXTRA_DIST): Add getpass.h.
11702         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
11703         * modules/group-member (EXTRA_DIST): Add group-member.h.
11704         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
11705         * modules/hash (EXTRA_DIST): Add hash.h.
11706         * modules/human (EXTRA_DIST): Add human.h.
11707         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
11708         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
11709         * modules/lchown (EXTRA_DIST): Add lchown.h.
11710         * modules/long-options (EXTRA_DIST): Add long-options.h.
11711         * modules/lstat (EXTRA_DIST): Add lstat.h.
11712         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
11713         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
11714         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
11715         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
11716         * modules/memxor (EXTRA_DIST): Add memxor.h.
11717         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
11718         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
11719         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
11720         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
11721         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
11722         * modules/physmem (EXTRA_DIST): Add physmem.h.
11723         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
11724         * modules/posixver (EXTRA_DIST): Add posixver.h.
11725         * modules/quote (EXTRA_DIST): Add quote.h.
11726         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
11727         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
11728         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
11729         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
11730         regex_internal.h regexec.c.
11731         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
11732         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
11733         * modules/same (EXTRA_DIST): Add same.h.
11734         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
11735         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
11736         * modules/savedir (EXTRA_DIST): Add savedir.h.
11737         * modules/sha1 (EXTRA_DIST): Add sha1.h.
11738         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
11739         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
11740         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
11741         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
11742         * modules/strdup (EXTRA_DIST): Add strdup.h.
11743         * modules/strftime (EXTRA_DIST): Add strftime.h.
11744         * modules/strndup (EXTRA_DIST): Add strndup.h.
11745         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
11746         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
11747         * modules/time_r (EXTRA_DIST): Add time_r.h.
11748         * modules/timespec (EXTRA_DIST): Add timespec.h.
11749         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11750         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
11751         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
11752         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
11753         * modules/userspec (EXTRA_DIST): Add userspec.h.
11754         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
11755         * modules/utimens (EXTRA_DIST): Add utimens.h.
11756         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
11757         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
11758         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
11759         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
11760         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
11761         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
11762         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
11763         * modules/yesno (EXTRA_DIST): Add yesno.h.
11764
11765 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11766
11767         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
11768
11769         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
11770         * m4/dev-ino.m4, same-inode.m4: Remove.
11771
11772         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
11773         * m4/acl.m4 (AC_FUNC_ACL):
11774         * m4/backupfile.m4 (gl_BACKUPFILE):
11775         * m4/c-strtod.m4 (gl_C99_STRTOLD):
11776         * m4/canon-host.m4 (gl_CANON_HOST):
11777         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
11778         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
11779         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
11780         * m4/cloexec.m4 (gl_CLOEXEC):
11781         * m4/close-stream.m4 (gl_CLOSE_STREAM):
11782         * m4/closeout.m4 (gl_CLOSEOUT):
11783         * m4/dirfd.m4 (gl_FUNC_DIRFD):
11784         * m4/dirname.m4 (gl_DIRNAME):
11785         * m4/exclude.m4 (gl_EXCLUDE):
11786         * m4/exitfail.m4 (gl_EXITFAIL):
11787         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
11788         * m4/file-type.m4 (gl_FILE_TYPE):
11789         * m4/filemode.m4 (gl_FILEMODE):
11790         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
11791         * m4/fpending.m4 (gl_FUNC_FPENDING):
11792         * m4/fprintftime.m4 (gl_FPRINTFTIME):
11793         * m4/fts.m4 (gl_FUNC_FTS):
11794         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
11795         * m4/getdate.m4 (gl_GETDATE):
11796         * m4/gethrxtime.m4 (gl_GETHRXTIME):
11797         * m4/getpagesize.m4 (gl_GETPAGESIZE):
11798         * m4/getpass.m4 (gl_FUNC_GETPASS):
11799         * m4/gettime.m4 (gl_GETTIME):
11800         * m4/getugroups.m4 (gl_GETUGROUPS):
11801         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
11802         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
11803         * m4/hard-locale.m4 (gl_HARD_LOCALE):
11804         * m4/hash.m4 (gl_HASH):
11805         * m4/idcache.m4 (gl_IDCACHE):
11806         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
11807         * m4/lchown.m4 (gl_FUNC_LCHOWN):
11808         * m4/long-options.m4 (gl_LONG_OPTIONS):
11809         * m4/lstat.m4 (gl_FUNC_LSTAT):
11810         * m4/md5.m4 (gl_MD5):
11811         * m4/memcasecmp.m4 (gl_MEMCASECMP):
11812         * m4/memcoll.m4 (gl_MEMCOLL):
11813         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
11814         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
11815         * m4/memxor.m4 (gl_MEMXOR):
11816         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
11817         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
11818         * m4/modechange.m4 (gl_MODECHANGE):
11819         * m4/mountlist.m4 (gl_MOUNTLIST):
11820         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
11821         * m4/openat.m4 (gl_FUNC_OPENAT):
11822         * m4/pathmax.m4 (gl_PATHMAX):
11823         * m4/physmem.m4 (gl_PHYSMEM):
11824         * m4/posixtm.m4 (gl_POSIXTM):
11825         * m4/posixver.m4 (gl_POSIXVER):
11826         * m4/quote.m4 (gl_QUOTE):
11827         * m4/quotearg.m4 (gl_QUOTEARG):
11828         * m4/readtokens.m4 (gl_READTOKENS):
11829         * m4/readutmp.m4 (gl_READUTMP):
11830         * m4/regex.m4 (gl_REGEX):
11831         * m4/safe-read.m4 (gl_SAFE_READ):
11832         * m4/safe-write.m4 (gl_SAFE_WRITE):
11833         * m4/same.m4 (gl_SAME):
11834         * m4/save-cwd.m4 (gl_SAVE_CWD):
11835         * m4/savedir.m4 (gl_SAVEDIR):
11836         * m4/settime.m4 (gl_SETTIME):
11837         * m4/sha1.m4 (gl_SHA1):
11838         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
11839         * m4/stat-macros.m4 (gl_STAT_MACROS):
11840         * m4/stat-time.m4 (gl_STAT_TIME):
11841         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
11842         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
11843         * m4/strdup.m4 (gl_FUNC_STRDUP):
11844         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
11845         * m4/strndup.m4 (gl_FUNC_STRNDUP):
11846         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
11847         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
11848         * m4/time_r.m4 (gl_TIME_R):
11849         * m4/timespec.m4 (gl_TIMESPEC):
11850         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
11851         * m4/unlinkdir.m4 (gl_UNLINKDIR):
11852         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
11853         * m4/userspec.m4 (gl_USERSPEC):
11854         * m4/utimecmp.m4 (gl_UTIMECMP):
11855         * m4/utimens.m4 (gl_UTIMENS):
11856         * m4/xalloc.m4 (gl_XALLOC):
11857         * m4/xgetcwd.m4 (gl_XGETCWD):
11858         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
11859         * m4/xreadlink.m4 (gl_XREADLINK):
11860         * m4/xstrtod.m4 (gl_XSTRTOD):
11861         * m4/yesno.m4 (gl_YESNO):
11862         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11863         to get the necessary .h files and whatnot.
11864
11865 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
11866             Bruno Haible  <bruno@clisp.org>
11867
11868         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
11869         /bin/sh understanding of '!' conditional negation.
11870
11871 2006-08-21  Jim Meyering  <jim@meyering.net>
11872
11873         * modules/openat (Depends-on): Really alphabetize.
11874
11875         * modules/acl (Depends-on): Add error and quote.
11876
11877         * check-module (find_included_lib_files): Add at-func.c to the
11878         ok-to-include-more-than-once white list.
11879
11880         * modules/openat (Depends-on): Add lstat.  Alphabetize.
11881
11882 2006-08-21  Bruno Haible  <bruno@clisp.org>
11883
11884         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
11885         Emit a pkgdata_DATA variable only if some snippets add contents to it.
11886         Reported by Martin Lambers <marlam@marlam.de>.
11887
11888 2006-08-21  Bruno Haible  <bruno@clisp.org>
11889
11890         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
11891         specify an installation location, don't emit a noinst_LIBRARIES or
11892         noinst_LTLIBRARIES assignment.
11893
11894 2006-08-21  Bruno Haible  <bruno@clisp.org>
11895
11896         BeOS portability.
11897         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
11898         BeOS has mbrtowc() but no <wctype.h>.
11899
11900 2006-08-21  Bruno Haible  <bruno@clisp.org>
11901
11902         BeOS portability.
11903         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
11904         exist.
11905
11906 2006-08-21  Bruno Haible  <bruno@clisp.org>
11907
11908         BeOS portability.
11909         * lib/mbchar.h: Include <wctype.h> only if it exists.
11910
11911 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11912
11913         Remove files that are no longer needed by their respective modules.
11914         * m4/obstack.m4: Remove.
11915         * m4/strerror_r.m4: Remove.
11916         * m4/uint32_t.m4: Remove.
11917         * m4/uintptr_t.m4: Remove.
11918         * m4/ullong_max.m4: Remove.
11919         * m4/xstrtoimax.m4: Remove.
11920         * m4/xstrtoumax.m4: Remove.
11921
11922         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
11923         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
11924         dependencies now capture this.
11925
11926         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
11927         Do not use AC_LIBSOURCES, since gnulib modules now do this.
11928         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
11929         * m4/human.m4 (gl_HUMAN): Likewise.
11930         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
11931         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
11932
11933         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
11934
11935         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
11936         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
11937         stdint.
11938         * m4/human.m4 (gl_HUMAN): Likewise.
11939         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
11940         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
11941         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11942         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11943         * m4/xstrtol (gl_XSTRTOL): Likewise.
11944
11945         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
11946         AC_TYPE_LONG_LONG_INT.
11947         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11948         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
11949         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
11950         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11951
11952         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
11953         on stdbool.
11954
11955         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
11956         (gl_PREREQ_XSTRTOUL): Remove.
11957
11958         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
11959
11960         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
11961         mode.
11962
11963 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11964
11965         Add and change modules to make it easier for coreutils to use
11966         gnulib-tool.
11967         * modules/backupfile (Files): Remove m4/d-ino.m4.
11968         (Depends-on): Add d-ino.
11969         * modules/cycle-check (Depends-on): Add stdint.
11970         (lib_SOURCES): Add cycle-check.h.
11971         * modules/d-ino: New module.
11972         * modules/d-type: New module.
11973         * modules/error (Files): Remove m4/strerror_r.m4.
11974         * modules/filemode (Files): Add m4/st_dm_mode.m4.
11975         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11976         m4/inttypes_h.m4, m4/uintmax_t.m4.
11977         (Depends-on): Add stdint.
11978         (lib_SOURCES): Add fsusage.h.
11979         * modules/getcwd (Files): Remove d-ino.m4.
11980         (Depends-on): Add d-ino.
11981         * modules/getndelim2 (Depends-on): Add stdint.
11982         * modules/glob (Files): Remove m4/d-type.m4.
11983         (Depends-on): Add d-type.
11984         * modules/host-os: New module.
11985         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
11986         m4/inttypes_h.m4, m4/uintmax_t.m4.
11987         * Depends-on: Add stdint.
11988         (lib_SOURCES): Add human.h.
11989         * modules/inttostr (Files): Remove m4/intmax_t.m4,
11990         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
11991         m4/uintmax_t.m4, m4/ulonglong.m4.
11992         (Depends-on): Add stdint.
11993         (EXTRA_DIST): Add inttostr.h.
11994         * modules/lchmod: New module.
11995         * modules/link-follow: New module.
11996         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
11997         (Depends-on): Add lchmod.
11998         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
11999         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
12000         (Depends-on): Add stdint.
12001         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
12002         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
12003         (Depends-on): Add stdint.
12004         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
12005         * modules/perl: New module.
12006         * modules/regex (Depends-on): Add stdint.
12007         * modules/rmdir-errno: New module.
12008         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12009         m4/intmax_t.m4.
12010         (Depends-on): Add stdint.
12011         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12012         m4/uintmax_t.m4.
12013         (Depends-on): Add stdint.
12014         * modules/unlink-busy: New module.
12015         * modules/utimecmp (Depends-on): Add stdint.
12016         * modules/uptime: New module.
12017         * modules/winsz-ioctl: New module.
12018         * modules/winsz-termios: New module.
12019         * modules/xnanosleep (Depends-on): Add nanosleep.
12020         * modules/ullong_max: Remove.
12021         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
12022         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
12023         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
12024         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
12025         (Depends-on): Add inttypes.
12026         (lib_SOURCES): Add xstrtol.h.
12027         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
12028         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
12029         * MODULES.html.sh: Move 'assert' into the assert section.
12030         Move 'dummy' into the linking section.
12031         Remove ullong_max.
12032         Add section for compatibility checks for POSIX:2001 functions,
12033         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
12034         winsz-ioctl, and winsz-termios into it.
12035         Add lchmod.
12036         Add top-level Misc section and put host-os, perl, and uptime
12037         into it.
12038
12039 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12040
12041         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
12042         now assume the stdint module.  Do not include inttypes.h.
12043         * lib/fsusage.h: Likewise.
12044         * lib/getndelim2.c: Likewise.
12045         * lib/human.h: Likewise.
12046         * lib/inttostr.h: Likewise.
12047         * lib/obstack.c: Likewise.
12048         * lib/regex_internal.h: Likewise.
12049         * lib/tempname.c: Likewise.
12050         * lib/utimecmp.c: Likewise.
12051         * lib/xstrtol.h: Likewise.
12052
12053         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
12054
12055         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
12056         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
12057         * lib/xtime.h: Likewise.
12058
12059 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12060
12061         * modules/openat (Files): Add lib/fchmodat.c.
12062         Fixes problem reported by Jay Youngman.
12063
12064 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12065
12066         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
12067         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
12068
12069 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
12070             Bruno Haible  <bruno@clisp.org>
12071
12072         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
12073         and is a script that invokes bison. Tighten the code. Add comments.
12074
12075 2006-08-18  Jim Meyering  <jim@meyering.net>
12076
12077         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
12078         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
12079         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
12080         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
12081
12082 2006-08-18  Bruno Haible  <bruno@clisp.org>
12083
12084         * modules/bison-i18n: New file.
12085         * MODULES.html.sh (Internationalization functions): Add it.
12086
12087 2006-08-18  Bruno Haible  <bruno@clisp.org>
12088
12089         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
12090         sys/statvfs.h. When getmntinfo was found, check its declaration and
12091         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
12092
12093 2006-08-18  Bruno Haible  <bruno@clisp.org>
12094
12095         * m4/bison-i18n.m4: New file, from bison.
12096
12097 2006-08-18  Bruno Haible  <bruno@clisp.org>
12098
12099         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
12100         (ME_DUMMY): Treat "kernfs" as a dummy.
12101         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
12102
12103 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12104
12105         Update from coreutils.
12106
12107         2006-08-15  Jim Meyering  <jim@meyering.net>
12108
12109         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
12110
12111         2006-01-17  Jim Meyering  <jim@meyering.net>
12112
12113         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
12114
12115         2006-01-11  Jim Meyering  <jim@meyering.net>
12116
12117         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
12118         Check for the lchmod function.
12119
12120 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12121
12122         Update from coreutils.
12123
12124         * lib/__fpending.h: Add copyright notice.
12125         * lib/fprintftime.h: Likewise.
12126         * lib/savedir.c: Use (C) in copyright notice.
12127         * lib/savedir.h: Likewise.
12128
12129         2006-08-15  Jim Meyering  <jim@meyering.net>
12130
12131         * lib/at-func.c: New file, with the logic of all emulated at-functions.
12132         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
12133         in support of the EXPECTED_ERRNO macro.
12134         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
12135         definitions.  Instead, define the appropriate symbols and include
12136         "at-func.c".
12137         * lib/mkdirat.c (mkdirat): Likewise.
12138         * lib/fchmodat.c (fchmodat): Likewise.
12139         (ENOSYS): Remove definition.
12140         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
12141         it.  Don't include "unistd--.h" -- it wasn't ever used.
12142
12143         2006-01-17  Jim Meyering  <jim@meyering.net>
12144
12145         Rewrite fts.c not to change the current working directory,
12146         by using openat, fstatat, fdopendir, etc..
12147
12148         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
12149         (HAVE_OPENAT_SUPPORT): Define.
12150         [_LIBC] (fchdir): Don't undef or define; no longer used.
12151         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
12152         Now, this `function' always succeeds, and consumes its file descriptor
12153         parameter -- so callers must not close such FDs.  Update callers.
12154         (diropen_fd, opendirat, cwd_advance_fd): New functions.
12155         (diropen): Add parameter, SP.  Adjust all callers.
12156         Implement using diropen_fd, rather than open.
12157         (fts_open): Initialize new member, fts_cwd_fd.
12158         Remove fts_rft-setting code.
12159         (fts_close): Close fts_cwd_fd, if necessary.
12160         (__opendir2): Define in terms of opendir or opendirat,
12161         depending on whether the FST_NOCHDIR flag is set.
12162         (fts_build): Since fts_safe_changedir consumes its FD, and since
12163         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
12164         and close the dup'd file descriptor upon failure.
12165         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
12166         (fts_safe_changedir): Tweak semantics to reflect that this function
12167         now calls cwd_advance_fd and hence consumes its FD argument.
12168         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
12169         [struct FTS] (fts_rft): Remove now-unused member.
12170         [struct FTS] (fts_cycle.state): Improve comment.
12171
12172         * lib/openat.c (openat_needs_fchdir): New function.
12173         * lib/openat.h (openat_needs_fchdir): Declare it.
12174
12175 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12176
12177         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
12178         Problem and fix reported by Pádraig Brady in
12179         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
12180
12181 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12182
12183         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
12184
12185 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12186
12187         * lib/memcoll.c (memcoll): Optimize for the common case where the
12188         arguments are bytewise equal.
12189
12190 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12191
12192         * doc/regexprops-generic.texi: Add a copyright notice.
12193
12194 2006-08-15  Bruno Haible  <bruno@clisp.org>
12195
12196         * modules/tmpdir (License): Change to LGPL.
12197
12198 2006-08-15  Bruno Haible  <bruno@clisp.org>
12199
12200         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
12201         module.
12202
12203 2006-08-14  Simon Josefsson  <jas@extundo.com>
12204
12205         * config/srclist.txt: Add gnupload.
12206
12207 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12208
12209         Change copyright notice from LGPL 2 to GPL 2, since that's the
12210         standard form used in the gnulib repository.
12211         * tests/test-lock.c: Likewise.
12212         * tests/test-stdint.c: Likewise.
12213         * tests/test-tls.c: Likewise.
12214
12215         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
12216         prelude-manager.  User shorter URLs for GNU projects, without '?'.
12217         Add copyright notice.
12218
12219         * check-module: Add copyright notice.  Output a copyright
12220         notice if "--version" is specified.
12221         * modules/COPYING: New file.
12222         * tests/test-getaddrinfo.c: Add copyright notice.
12223         * tests/test-verify.c: Likewise.
12224
12225 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12226
12227         Change copyright notice from LGPL 2 to GPL 2, since that's the
12228         standard form used in the gnulib repository.
12229         * lib/lock.c: LGPL -> GPL.
12230         * lib/lock.h: Likewise.
12231         * lib/strnlen1.c: Likewise.
12232         * lib/strnlen1.h: Likewise.
12233         * lib/tls.c: Likewise.
12234         * lib/tls.h: Likewise.
12235         * lib/tmpdir.c: Likewise.
12236
12237         * lib/TODO: Remove; this belongs only in coreutils.
12238
12239 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12240
12241         Add copyright notices to long-enough files that lack them, since
12242         otherwise the files aren't clearly free.  Use the same notice that
12243         getdate.texi already uses.
12244         * doc/alloca-opt.texi: Add copyright notice.
12245         * doc/alloca.texi: Likewise.
12246         * doc/ctime.texi: Likewise.
12247         * doc/functions.texi: Likewise.
12248         * doc/gcd.texi: Likewise.
12249         * doc/gnulib-tool.texi: Likewise.
12250         * doc/inet_ntoa.texi: Likewise.
12251         * doc/visibility.texi: Likewise.
12252
12253         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
12254         * doc/quote.texi: Add copyright notice.
12255
12256         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
12257         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
12258         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
12259         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
12260         is now obsolete, and give a pointer to the Sun list.
12261         Add copyright notice.
12262
12263 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12264
12265         * config/srclistvars.sh: Add copyright notice.
12266
12267 2006-08-14  Eric Blake  <ebb9@byu.net>
12268
12269         Import the following change from libc:
12270
12271         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
12272
12273         Upstream bug 2997.
12274         * lib/misc/error.c: Add space between program name and message if file
12275         name is missing.
12276
12277 2006-08-12  Karl Berry  <karl@gnu.org>
12278
12279         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
12280         remove, these originate in gnulib now.
12281
12282 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12283
12284         * doc/Makefile (standards.info standards.html standards.dvi):
12285         Also depend on make-stds.texi.
12286
12287 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12288
12289         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
12290         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
12291
12292         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
12293         in wchar_t.  Problem reported by Eric Blake.
12294
12295         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
12296         LEN is smaller than SIZE.  Suggested by Bruno Haible.
12297         Also, help the compiler to keep LEN in a register.
12298
12299 2006-08-11  Eric Blake  <ebb9@byu.net>
12300
12301         * users.txt: Sort.  Add tar.
12302
12303 2006-08-11  Bruno Haible  <bruno@clisp.org>
12304
12305         * users.txt: New file.
12306
12307 2006-08-11  Bruno Haible  <bruno@clisp.org>
12308
12309         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
12310         before <wchar.h>. Needed for OSF/1 and BSD/OS.
12311
12312 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12313
12314         * modules/snprintf (Depends-on): Remove minmax.
12315         (Maintainer): Add self and Bruno.
12316
12317 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12318
12319         * lib/.cppi-disable: Add snprintf.h, socket_.h.
12320         * lib/snprintf.c: Include <errno.h> and <limits.h>.
12321         (EOVERFLOW): Define if the system does not.
12322         Do not include "minmax.h"; it wasn't used.
12323         (snprintf): Don't assume size_t promotes to an unsigned type.
12324         Fix bug when generated string was too long for the buffer: the
12325         buffer's contents are supposed to be the initial prefix of the
12326         output.  Don't assume vasnprintf returns EOVERFLOW if the size
12327         exceeds INT_MAX; do the check ourselves.
12328
12329         Import the following changes from libc:
12330
12331         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
12332
12333         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
12334         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
12335         set wc to the byte which couldn't be converted.
12336         (re_string_reconstruct): Don't clear valid_raw_len before calling
12337         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
12338         tip_context using re_string_context_at.
12339
12340         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
12341
12342         * lib/posix/regex.h: g++ still cannot handled [restrict].
12343
12344         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
12345
12346         * lib/posix/regex.h: Remove special handling for VMS.
12347
12348 2006-08-10  Jim Meyering  <jim@meyering.net>
12349
12350         * modules/same-inode: New module.
12351         * modules/dev-ino: New module.
12352         * modules/cycle-check: Depend on these modules, rather than simply
12353         including their .h files.
12354         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
12355         required via m4/cycle-check.m4.
12356         * modules/same: Depend on new same-inode module, rather than
12357         including same-inode.h.
12358         * modules/chdir-safer: New file.
12359
12360         * modules/chown (Depends-on): Add stat-macros.
12361
12362 2006-08-10  Jim Meyering  <jim@meyering.net>
12363
12364         * m4/cycle-check.m4: New file.
12365         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
12366         * m4/dev-ino.m4, m4/same-inode.m4: New files.
12367
12368 2006-08-10  Eric Blake  <ebb9@byu.net>
12369
12370         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
12371         in from original proposal.
12372
12373 2006-08-10  Eric Blake  <ebb9@byu.net>
12374         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12375
12376         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
12377         namespace.
12378
12379 2006-08-10  Bruno Haible  <bruno@clisp.org>
12380
12381         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
12382         as well.
12383
12384 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12385
12386         Sync from coreutils.
12387
12388         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
12389
12390         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
12391         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
12392
12393 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12394
12395         * modules/restrict: Remove; no longer needed now that we assume
12396         Autoconf 2.59 or later.
12397         * MODULES.html.sh: Remove 'restrict'.
12398         * modules/argp (Depends-on): Remove 'restrict'.
12399         * modules/base64 (Depends-on): Likewise.
12400         * modules/gc (Depends-on): Likewise.
12401         * modules/getaddrinfo (Depends-on): Likewise.
12402         * modules/glob (Depends-on): Likewise.
12403         * modules/inet_ntop (Depends-on): Likewise.
12404         * modules/inet_pton (Depends-on): Likewise.
12405         * modules/memxor (Depends-on): Likewise.
12406         * modules/regex (Depends-on): Likewise.
12407         * modules/strtok_r (Depends-on): Likewise.
12408         * modules/time_r (Depends-on): Likewise.
12409
12410 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12411
12412         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12413         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12414         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12415         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12416         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12417         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12418         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12419         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12420
12421         Merge from coreutils.
12422         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12423         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12424         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12425         * m4/time_r.m4 (gl_TIME_R): Likewise.
12426
12427 2006-08-09  Karl Berry  <karl@gnu.org>
12428
12429         * config/srclist.txt: no more gettext-tools, per Bruno.
12430
12431 2006-08-08  Eric Blake  <ebb9@byu.net>
12432
12433         * modules/verror: New module.
12434         * MODULES.html.sh: Document it.
12435
12436 2006-08-08  Eric Blake  <ebb9@byu.net>
12437
12438         * lib/verror.h, lib/verror.c: New files.
12439
12440 2006-08-08  Eric Blake  <ebb9@byu.net>
12441
12442         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12443         verror_at_line output complies with GNU Coding Standards even when
12444         file is NULL.
12445
12446 2006-08-07  Bruno Haible  <bruno@clisp.org>
12447
12448         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12449         versions of AIX.
12450         Reported by Ralf Wildenhues.
12451
12452 2006-08-07  Bruno Haible  <bruno@clisp.org>
12453
12454         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12455         in an AC_DEFUN. Needed so that the autoconf snippets can use
12456         AC_REQUIRE.
12457
12458 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12459
12460         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12461         Initialize pkgdata_DATA.
12462         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12463         overriding it.
12464
12465 2006-08-06  Eric Blake  <ebb9@byu.net>
12466
12467         * lib/error.h: Fold in some upstream changes from glibc.
12468         * lib/error.c: Likewise.
12469
12470 2006-08-04  Bruno Haible  <bruno@clisp.org>
12471
12472         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12473         Make the mostlyclean-local rule depend on mostlyclean-generic.
12474         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12475
12476 2006-07-31  Bruno Haible  <bruno@clisp.org>
12477
12478         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12479         <stdlib.h>, <string.h>.
12480
12481 2006-07-30  Bruno Haible  <bruno@clisp.org>
12482
12483         * modules/readlink (License): Change to LGPL.
12484
12485 2006-07-30  Bruno Haible  <bruno@clisp.org>
12486
12487         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12488         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12489         set PKGDATADIR to point to it.
12490
12491 2006-07-30  Bruno Haible  <bruno@clisp.org>
12492
12493         * modules/csharpexec (configure.ac): Comment out macro invocation.
12494         * modules/javaexec (configure.ac): Likewise.
12495         * modules/javacomp-script (configure.ac): Likewise.
12496
12497         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12498
12499 2006-07-30  Bruno Haible  <bruno@clisp.org>
12500
12501         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12502         linked-list.
12503
12504 2006-07-30  Bruno Haible  <bruno@clisp.org>
12505
12506         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12507
12508 2006-07-30  Bruno Haible  <bruno@clisp.org>
12509
12510         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12511         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12512         get removed.
12513
12514 2006-07-29  Bruno Haible  <bruno@clisp.org>
12515
12516         Make it possible for gnulib-tool to work with locally modified or
12517         augmented gnulib repositories.
12518         * gnulib-tool (func_usage): Document --local-dir option.
12519         (local_gnulib_dir): New variable.
12520         Handle --local-dir option.
12521         (func_lookup_file): New function.
12522         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12523         (func_get_description, func_get_filelist, func_get_description,
12524         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12525         func_get_automake_snippet, func_get_include_directive,
12526         func_get_license, func_get_maintainer): Use func_lookup_file.
12527         (func_import, func_create_testdir): Use func_lookup_file.
12528
12529 2006-07-29  Bruno Haible  <bruno@clisp.org>
12530
12531         * modules/setenv (Depends-on): Add unistd.
12532
12533 2006-07-29  Bruno Haible  <bruno@clisp.org>
12534
12535         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12536
12537 2006-07-29  Bruno Haible  <bruno@clisp.org>
12538
12539         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12540
12541 2006-07-29  Bruno Haible  <bruno@clisp.org>
12542
12543         * gnulib-tool (import, update): If there is no Makefile.am, look at
12544         aclocal.m4, instead of bailing out.
12545
12546 2006-07-29  Bruno Haible  <bruno@clisp.org>
12547
12548         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12549         Categorize the options by when they are useful.
12550
12551 2006-07-29  Bruno Haible  <bruno@clisp.org>
12552
12553         * gnulib-tool (func_usage): Document option --no-libtool.
12554         Handle option --no-libtool.
12555         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12556         for changed semantics of $libtool variable.
12557         (func_import): Likewise. If libtool is not used, show this through
12558         an option --no-libtool.
12559         (func_create_testdir): Update.
12560
12561 2006-07-29  Bruno Haible  <bruno@clisp.org>
12562
12563         * gnulib-tool (func_import): Extend error message about missing
12564         --doc-base.
12565
12566 2006-07-29  Bruno Haible  <bruno@clisp.org>
12567
12568         * gnulib-tool (func_import): Don't create the $docbase directory if
12569         there is no file to store there.
12570
12571 2006-07-29  Bruno Haible  <bruno@clisp.org>
12572
12573         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12574         relevant, look for configure.ac there, not in the current directory.
12575         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12576
12577 2006-07-29  Bruno Haible  <bruno@clisp.org>
12578
12579         * gnulib-tool (SORT): New variable.
12580         (func_usage): Undocument --assume-autoconf option.
12581         Remove --assume-autoconf option handling.
12582         (autoconf_minversion): Determine from the contents of configure.ac.
12583         (func_import): Remove autoconf_minversion handling.
12584         Suggested by Eric Blake.
12585
12586 2006-07-29  Bruno Haible  <bruno@clisp.org>
12587
12588         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
12589
12590 2006-07-29  Bruno Haible  <bruno@clisp.org>
12591
12592         * config/srclist.txt (*setenv.[ch]): Remove rules.
12593
12594 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12595
12596         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
12597
12598 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12599
12600         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
12601         arpa/inet.h.
12602
12603 2006-07-28  Simon Josefsson  <jas@extundo.com>
12604
12605         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
12606         * modules/inet_pton (Depends-on): Likewise.
12607
12608 2006-07-28  Simon Josefsson  <jas@extundo.com>
12609
12610         * m4/netinet_in_h.m4: New file.
12611
12612 2006-07-28  Simon Josefsson  <jas@extundo.com>
12613
12614         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
12615         #include's.
12616
12617 2006-07-28  Simon Josefsson  <jas@extundo.com>
12618
12619         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
12620         #include's.
12621
12622 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
12623
12624         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
12625         setgid on directories only if they set these bits.
12626         * lib/modechange.h: Remove obsolete comment about masks.
12627
12628 2006-07-28  Eric Blake  <ebb9@byu.net>
12629
12630         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
12631         macro expansion.
12632
12633 2006-07-28  Bruno Haible  <bruno@clisp.org>
12634
12635         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
12636
12637 2006-07-28  Bruno Haible  <bruno@clisp.org>
12638
12639         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
12640
12641 2006-07-28  Bruno Haible  <bruno@clisp.org>
12642
12643         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
12644         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
12645         Define fallbacks.
12646         Avoids link error on FreeBSD 4.x.
12647         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12648
12649         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
12650         encoding.
12651         * lib/mbswidth.c (iswcntrl): Likewise.
12652
12653 2006-07-27  Bruno Haible  <bruno@clisp.org>
12654
12655         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
12656         test.
12657
12658 2006-07-27  Bruno Haible  <bruno@clisp.org>
12659
12660         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
12661         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
12662         defined.
12663
12664 2006-07-26  Eric Blake  <ebb9@byu.net>
12665
12666         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
12667
12668 2006-07-26  Eric Blake  <ebb9@byu.net>
12669
12670         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
12671         like mingw that lack mkstemp.
12672         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
12673         avoid compilation warning on mingw.
12674
12675 2006-07-26  Bruno Haible  <bruno@clisp.org>
12676
12677         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
12678         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
12679         INT_FAST*_MIN, INTPTR_MIN.
12680
12681 2006-07-25  Bruno Haible  <bruno@clisp.org>
12682
12683         * modules/version-etc (Depends-on): Add stdarg.
12684
12685 2006-07-25  Bruno Haible  <bruno@clisp.org>
12686
12687         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
12688         complex commands.
12689
12690 2006-07-25  Bruno Haible  <bruno@clisp.org>
12691
12692         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
12693         defined in <stdarg.h> or config.h.
12694
12695 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12696
12697         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
12698         (gl_STDIO_SAFER): Remove.
12699
12700 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12701
12702         * MODULES.html.sh (File stream based Input/Output):
12703         Add fopen-safer, tmpfile-safer; remove stdio-safer.
12704         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
12705         * modules/fopen-safer, modules/tmpfile-safer: New files.
12706         * modules/stdio-safer: Remove.
12707
12708 2006-07-24  Bruno Haible  <bruno@clisp.org>
12709
12710         * modules/tmpdir: New file.
12711         * MODULES.html.sh (File system functions): Add it.
12712
12713 2006-07-24  Bruno Haible  <bruno@clisp.org>
12714
12715         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
12716         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
12717
12718 2006-07-24  Bruno Haible  <bruno@clisp.org>
12719
12720         * modules/clean-temp: New file.
12721
12722 2006-07-24  Bruno Haible  <bruno@clisp.org>
12723
12724         * m4/tmpdir.m4: New file, from GNU gettext.
12725
12726 2006-07-24  Bruno Haible  <bruno@clisp.org>
12727
12728         * lib/tmpdir.h: New file, from GNU gettext.
12729         * lib/tmpdir.c: New file, from GNU gettext.
12730
12731 2006-07-24  Bruno Haible  <bruno@clisp.org>
12732
12733         * lib/clean-temp.h: New file, from GNU gettext.
12734         * lib/clean-temp.c: New file, from GNU gettext.
12735
12736 2006-07-23  Eric Blake  <ebb9@byu.net>
12737
12738         * modules/stdio-safer (Files): Add tmpfile-safer.c.
12739         (Depends-on): Add binary-io.
12740
12741 2006-07-23  Eric Blake  <ebb9@byu.net>
12742
12743         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
12744
12745 2006-07-23  Eric Blake  <ebb9@byu.net>
12746
12747         * lib/tmpfile-safer.c: New file.
12748         * lib/stdio-safer.h (fopen_safer): Add prototype.
12749         * lib/stdio--.h (tmpfile): Make safer.
12750
12751 2006-07-23  Bruno Haible  <bruno@clisp.org>
12752
12753         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
12754         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
12755         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
12756         gl_linked_remove_at): Use it.
12757
12758 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12759         and Simon Josefsson <jas@extundo.com>
12760
12761         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
12762
12763         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
12764
12765 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12766
12767         * modules/close-stream: New file.
12768         * modules/closeout (Description): Make it clear that it exits
12769         with a diagnostic on error.
12770         (Depends-on): Add close-stream.  Remove fpending, stdbool.
12771         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
12772
12773 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12774
12775         * m4/close-stream.m4: New file.
12776
12777 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12778
12779         * lib/close-stream.c, lib/close-stream.h: New files.
12780
12781 2006-07-22  Bruno Haible  <bruno@clisp.org>
12782
12783         Merge from GNU gettext 0.15.
12784
12785         2006-05-01  Bruno Haible  <bruno@clisp.org>
12786
12787                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
12788
12789         2006-07-22  Bruno Haible  <bruno@clisp.org>
12790
12791                 * modules/javaversion: New file.
12792                 * MODULES.html.sh (Java): Add javaversion.
12793
12794         2006-03-12  Bruno Haible  <bruno@clisp.org>
12795
12796                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
12797
12798         2005-12-04  Bruno Haible  <bruno@clisp.org>
12799
12800                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
12801                 (untested).
12802
12803         2006-06-21  Bruno Haible  <bruno@clisp.org>
12804
12805                 Avoid warnings from recent versions of mcs.
12806                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
12807                 -o, -L, -r any more. Use options documented since mcs-1.0
12808                 instead. Similarly for -g.
12809
12810         2005-12-04  Bruno Haible  <bruno@clisp.org>
12811
12812                 * build-aux/csharpcomp.sh.in: Suffix for resources is
12813                 .resources, not .resource.
12814
12815         2005-07-09  Bruno Haible  <bruno@clisp.org>
12816
12817                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
12818                 add a .dll suffix.
12819                 Reported by Mark Junker <mjscod@gmx.de>.
12820
12821         2006-07-22  Bruno Haible  <bruno@clisp.org>
12822
12823                 * modules/gettext: Upgrade to gettext-0.15.
12824                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
12825                 m4/visibility.m4.
12826                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
12827
12828 2006-07-22  Bruno Haible  <bruno@clisp.org>
12829
12830         Merge from GNU gettext 0.15.
12831
12832         2006-03-25  Bruno Haible  <bruno@clisp.org>
12833
12834                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
12835
12836         2006-07-21  Bruno Haible  <bruno@clisp.org>
12837
12838                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
12839                 "1.1".
12840
12841         2006-05-09  Bruno Haible  <bruno@clisp.org>
12842
12843                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
12844                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
12845                 for the conftestver execution.
12846
12847         2006-05-01  Bruno Haible  <bruno@clisp.org>
12848
12849                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
12850                 optional target-version argument. Verify that the compiler
12851                 groks source of the specified source-version, or add -source
12852                 option as necessary. Verify that the compiler produces
12853                 bytecode in the specified target-version, or add -target and
12854                 -source options as necessary. Make the result of the test
12855                 available as variable CONF_JAVAC. Also log error output in
12856                 config.log.
12857
12858         2006-03-11  Bruno Haible  <bruno@clisp.org>
12859
12860                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
12861
12862         2006-05-09  Bruno Haible  <bruno@clisp.org>
12863
12864                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
12865                 CLASSPATH_SEPARATOR to a semicolon.
12866
12867         2006-03-12  Bruno Haible  <bruno@clisp.org>
12868
12869                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
12870                 available as variable CONF_JAVA, for subsequent autoconf
12871                 tests. Also log error output in config.log.
12872
12873         2006-07-19  Bruno Haible  <bruno@clisp.org>
12874
12875                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
12876                 that getline works on glibc2 systems. Needed to avoid trouble
12877                 in relocatable.c.
12878                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
12879
12880         2005-12-04  Bruno Haible  <bruno@clisp.org>
12881
12882                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
12883                 launcher (untested).
12884
12885         2005-12-04  Bruno Haible  <bruno@clisp.org>
12886
12887                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
12888
12889         2006-07-22  Bruno Haible  <bruno@clisp.org>
12890
12891                 * gettext.m4: Update from GNU gettext-0.15.
12892                 * nls.m4: Likewise.
12893                 * po.m4: Likewise.
12894                 * inttypes-pri.m4: Likewise.
12895                 * inttypes-h.m4: Renamed from inttypes.m4.
12896                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
12897
12898 2006-07-22  Bruno Haible  <bruno@clisp.org>
12899
12900         Merge from GNU gettext 0.15.
12901
12902         2005-07-05  Bruno Haible  <bruno@clisp.org>
12903
12904                 * printf-args.c (printf_fetchargs): Work around broken
12905                 definition of wint_t on mingw.
12906
12907         2005-02-12  Bruno Haible  <bruno@clisp.org>
12908
12909                 * xallocsa.h: Add extern "C" for C++.
12910
12911         2006-05-17  Bruno Haible  <bruno@clisp.org>
12912
12913                 Cygwin portability.
12914                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
12915
12916         2006-04-30  Bruno Haible  <bruno@clisp.org>
12917
12918                 * progreloc.c: Include <mach-o/dyld.h> if available.
12919                 (find_executable): Use _NSGetExecutablePath when possible.
12920
12921         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
12922
12923                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
12924                 function.
12925
12926         2005-12-29  Bruno Haible  <bruno@clisp.org>
12927
12928                 * progreloc.c (set_program_name_and_installdir): Fix
12929                 compilation error.
12930
12931         2005-12-04  Bruno Haible  <bruno@clisp.org>
12932
12933                 Cygwin portability.
12934                 * progreloc.c: Include <windows.h> also on Cygwin.
12935                 (find_executable): Add support for Cygwin.
12936                 (set_program_name_and_installdir): Handle also platforms with
12937                 nonempty EXEEXT.
12938
12939         2006-07-11  Bruno Haible  <bruno@clisp.org>
12940
12941                 * javacomp.c: Fix a comment.
12942                 Reported by Jim Meyering.
12943
12944         2006-04-30  Bruno Haible  <bruno@clisp.org>
12945
12946                 * javacomp.h (compile_java_class): Add source_version,
12947                 target_version arguments.
12948                 * javacomp.c: Rewritten to choose only a compiler that
12949                 respects the specified source_version and target_version.
12950
12951         2006-06-27  Bruno Haible  <bruno@clisp.org>
12952
12953                 Assume correct S_ISDIR macro.
12954                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
12955
12956         2006-07-22  Bruno Haible  <bruno@clisp.org>
12957
12958                 * javaversion.h: New file, from GNU gettext.
12959                 * javaversion.c: New file, from GNU gettext.
12960                 * javaversion.java: New file, from GNU gettext.
12961                 * javaversion.class: New file, from GNU gettext.
12962
12963         2006-05-17  Bruno Haible  <bruno@clisp.org>
12964
12965                 Cygwin portability.
12966                 * javaexec.c (execute_java_class): Test for jview program
12967                 also on Cygwin.
12968
12969         2006-04-09  Bruno Haible  <bruno@clisp.org>
12970
12971                 * fatal-signal.c: Don't include string.h.
12972                 (at_fatal_signal): Use a copying loop instead of memcpy.
12973
12974         2005-12-04  Bruno Haible  <bruno@clisp.org>
12975
12976                 * csharpexec.c: Add support for 'clix' launcher (untested).
12977                 (execute_csharp_using_sscli): New function.
12978                 (execute_csharp_program): Call it.
12979
12980         2006-06-21  Bruno Haible  <bruno@clisp.org>
12981
12982                 Avoid warnings from recent versions of mcs.
12983                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
12984                 -o, -L, -r any more. Use options documented since mcs-1.0
12985                 instead. Similarly for -g.
12986
12987         2005-07-09  Bruno Haible  <bruno@clisp.org>
12988
12989                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
12990                 add a .dll suffix.
12991                 Reported by Mark Junker <mjscod@gmx.de>.
12992
12993         2006-06-17  Bruno Haible  <bruno@clisp.org>
12994
12995                 * config.charset: Update for NetBSD 3.0.
12996
12997         2006-05-17  Bruno Haible  <bruno@clisp.org>
12998
12999                 Cygwin portability.
13000                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
13001
13002         2006-05-16  Bruno Haible  <bruno@clisp.org>
13003
13004                 * localcharset.c [CYGWIN]: Include <windows.h>.
13005                 (get_charset_aliases): For Cygwin, return the same CPxxx
13006                 aliases list as under WIN32.
13007                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
13008                 the environment variables. Fall back to GetACP().
13009
13010         2006-04-05  Bruno Haible  <bruno@clisp.org>
13011
13012                 * config.charset: Update Juan Manuel Guerrero's address.
13013
13014         2005-02-12  Bruno Haible  <bruno@clisp.org>
13015
13016                 * allocsa.h: Add extern "C" for C++.
13017
13018         2005-02-10  Bruno Haible  <bruno@clisp.org>
13019
13020                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
13021                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
13022
13023         2006-07-22  Bruno Haible  <bruno@clisp.org>
13024
13025                 * gettext.h: Update to GNU gettext-0.15.
13026
13027 2006-07-22  Bruno Haible  <bruno@clisp.org>
13028
13029         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
13030         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
13031         lib-prefix.m4, longdouble.m4, ssize_t.m4.
13032
13033 2006-07-21  Eric Blake  <ebb9@byu.net>
13034
13035         * modules/stdlib-safer: New file.
13036         * MODULES.html.sh (File stream based Input/Output): Add
13037         stdlib-safer.
13038
13039 2006-07-21  Eric Blake  <ebb9@byu.net>
13040
13041         * lib/stdlib-safer.h: New file from coreutils, required by
13042         stdlib--.h.
13043
13044 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
13045
13046         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
13047
13048 2006-07-20  Bruno Haible  <bruno@clisp.org>
13049
13050         * gnulib-tool: Recognize new option --assume-autoconf.
13051         (autoconf_minversion): New variable.
13052         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
13053
13054 2006-07-20  Bruno Haible  <bruno@clisp.org>
13055
13056         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
13057
13058 2006-07-19  Derek R. Price  <derek@ximbiot.com>
13059
13060         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
13061         Reindent and repaginate.
13062
13063 2006-07-19  Derek Price  <derek@ximbiot.com>
13064
13065         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
13066         Correct grammar.
13067
13068 2006-07-17  Bruno Haible  <bruno@clisp.org>
13069
13070         * modules/list: New file.
13071         * modules/array-list: New file.
13072         * modules/carray-list, modules/carray-list-tests: New files.
13073         * modules/linked-list, modules/linked-list-tests: New files.
13074         * modules/avltree-list, modules/avltree-list-tests: New files.
13075         * modules/rbtree-list, modules/rbtree-list-tests: New files.
13076         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
13077         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
13078         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
13079         * modules/oset: New file.
13080         * modules/array-oset: New file.
13081         * modules/avltree-oset, modules/avltree-oset-tests: New files.
13082         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
13083         * tests/test-carray_list.c: New file.
13084         * tests/test-linked_list.c: New file.
13085         * tests/test-avltree_list.c: New file.
13086         * tests/test-rbtree_list.c: New file.
13087         * tests/test-linkedhash_list.c: New file.
13088         * tests/test-avltreehash_list.c: New file.
13089         * tests/test-rbtreehash_list.c: New file.
13090         * tests/test-avltree_oset.c: New file.
13091         * tests/test-rbtree_oset.c: New file.
13092         * MODULES.html.sh (Container data structures): New section.
13093
13094 2006-07-17  Bruno Haible  <bruno@clisp.org>
13095
13096         * m4/gl_list.m4: New file.
13097
13098 2006-07-17  Bruno Haible  <bruno@clisp.org>
13099
13100         * lib/gl_list.h: New file.
13101         * lib/gl_list.c: New file.
13102         * lib/gl_array_list.h: New file.
13103         * lib/gl_array_list.c: New file.
13104         * lib/gl_carray_list.h: New file.
13105         * lib/gl_carray_list.c: New file.
13106         * lib/gl_linked_list.h: New file.
13107         * lib/gl_linked_list.c: New file.
13108         * lib/gl_anylinked_list1.h: New file.
13109         * lib/gl_anylinked_list2.h: New file.
13110         * lib/gl_avltree_list.h: New file.
13111         * lib/gl_avltree_list.c: New file.
13112         * lib/gl_anyavltree_list1.h: New file.
13113         * lib/gl_anyavltree_list2.h: New file.
13114         * lib/gl_rbtree_list.h: New file.
13115         * lib/gl_rbtree_list.c: New file.
13116         * lib/gl_anyrbtree_list1.h: New file.
13117         * lib/gl_anyrbtree_list2.h: New file.
13118         * lib/gl_anytree_list1.h: New file.
13119         * lib/gl_anytree_list2.h: New file.
13120         * lib/gl_linkedhash_list.h: New file.
13121         * lib/gl_linkedhash_list.c: New file.
13122         * lib/gl_anyhash_list1.h: New file.
13123         * lib/gl_anyhash_list2.h: New file.
13124         * lib/gl_avltreehash_list.h: New file.
13125         * lib/gl_avltreehash_list.c: New file.
13126         * lib/gl_rbtreehash_list.h: New file.
13127         * lib/gl_rbtreehash_list.c: New file.
13128         * lib/gl_anytreehash_list1.h: New file.
13129         * lib/gl_anytreehash_list2.h: New file.
13130
13131         * lib/gl_oset.h: New file.
13132         * lib/gl_oset.c: New file.
13133         * lib/gl_array_oset.h: New file.
13134         * lib/gl_array_oset.c: New file.
13135         * lib/gl_avltree_oset.h: New file.
13136         * lib/gl_avltree_oset.c: New file.
13137         * lib/gl_rbtree_oset.h: New file.
13138         * lib/gl_rbtree_oset.c: New file.
13139         * lib/gl_anytree_oset.h: New file.
13140
13141 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13142
13143         * m4/mkancesdirs.m4: New file.
13144         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
13145         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
13146         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
13147         it.
13148
13149 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13150
13151         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
13152         * lib/mkancesdirs.h: New files.
13153         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
13154         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
13155         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
13156         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
13157         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
13158         callers changed.  Revamp internals significantly, by not
13159         attempting to create directories that are temporarily more
13160         permissive than the final results.  Do not attempt to use
13161         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
13162         This removes some race conditions, fixes some bugs, and simplifies
13163         things.  Use new dirchownmod function to do owner and mode changes.
13164         * lib/mkdir-p.h: Likewise.
13165         * lib/modechange.c (octal_to_mode): New function.
13166         (struct mode_change): New member mentioned.
13167         (make_node_op_equals): New arg mentioned.  All callers changed.
13168         (mode_compile): Keep track of which mode bits the user has explicitly
13169         mentioned.
13170         (mode_adjust): New arg DIR, so that we implement the X op correctly.
13171         New arg PMODE_BITS, to keep track of which mode bits the user
13172         mentioned; it treats S_ISUID and S_ISGID speciall.
13173         All callers changed.
13174         * lib/modechange.h: Likewise.
13175
13176 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13177
13178         * MODULES.html.sh: Add mkancestors.
13179         * modules/mkancesdirs: New module.
13180         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
13181         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
13182         The chdir-safer and afs files are now orphans; I'll remove them
13183         unless someone speaks up.
13184         Add lib/dirchownmod.c, lib/dirchownmod.h.
13185         (Depends-on): Remove alloca, chown, save-cwd, dirname.
13186         Add lchown, mkancesdirs.
13187         (Maintainer): Add self.
13188
13189 2006-07-15  Karl Berry  <karl@gnu.org>
13190
13191         * gnulib-tool: help message wording/arrangement.
13192
13193 2006-07-14  Simon Josefsson  <jas@extundo.com>
13194
13195         * doc/gnulib.texi (Libtool and Windows): New section.
13196
13197 2006-07-12  Simon Josefsson  <jas@extundo.com>
13198
13199         * modules/gendocs (License): Fix license, approved by Karl.
13200
13201 2006-07-12  Eric Blake  <ebb9@byu.net>
13202
13203         * MODULES.html.sh: Add gendocs.
13204
13205 2006-07-11  Eric Blake  <ebb9@byu.net>
13206
13207         * modules/fdl: New module, to install doc/fdl.texi.
13208         * MODULES.html.sh: Add new section for documentation modules.
13209         * gnulib-tool: Avoid space-tab.
13210         (--doc-base): New option, to manage files from doc.
13211
13212 2006-07-11  Eric Blake  <ebb9@byu.net>
13213
13214         * m4/absolute-header.m4: Fix comments to match recent change.
13215
13216 2006-07-11  Eric Blake  <ebb9@byu.net>
13217
13218         * gnulib-tool: List --doc-base before --tests-base.
13219
13220 2006-07-11  Derek R. Price  <derek@ximbiot.com>
13221
13222         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
13223
13224 2006-07-11  Bruno Haible  <bruno@clisp.org>
13225
13226         * README: Mention where to put documentation.
13227
13228 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13229
13230         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
13231
13232 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13233
13234         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
13235         to stdint.m4.
13236
13237 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13238
13239         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
13240         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
13241         "no/such/file/stdint.h" when there is no such file, so that
13242         the resulting C code can be parsed by dodgy compilers.
13243         Problems reported by Bob Proulx.
13244
13245 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13246
13247         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
13248         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13249         macros into the GNU _D_EXACT_NAMLEN.
13250         * lib/savedir.c:  Likewise.
13251         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
13252
13253 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13254         and Paul Eggert  <eggert@cs.ucla.edu>
13255
13256         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
13257         * m4/savedir.m4:
13258         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13259         macros into the GNU _D_EXACT_NAMLEN.
13260
13261 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13262
13263         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
13264         around the absolute name, to work around a problem with the HP-UX
13265         11.23 native C compiler, reported by Bob Proulx.
13266
13267 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13268
13269         * doc/maintain.texi, make-stds.texi: Sync from
13270         <http://savannah.gnu.org/projects/gnustandards>.
13271
13272 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13273
13274         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
13275
13276 2006-07-09  Jim Meyering  <jim@meyering.net>
13277
13278         * m4/glob.m4: Remove a doubled word in a comment.
13279
13280 2006-07-09  Jim Meyering  <jim@meyering.net>
13281
13282         * lib/argp-pv.c: Remove a doubled word in a comment.
13283         * lib/check-version.c (check_version): Likewise.
13284         * lib/javacomp.c (compile_java_class): Likewise.
13285
13286 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
13287
13288         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
13289         for the benefit of people using Autoconf 2.60.  If you want to
13290         support older Autoconf versions you can copy m4/onceonly_2_57.m4
13291         (or m4/onceonly.m4, if pre-2.57) manually.
13292
13293 2006-07-08  Jim Meyering  <jim@meyering.net>
13294
13295         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
13296         comment.
13297         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
13298         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
13299         comment.
13300
13301 2006-07-08  Jim Meyering  <jim@meyering.net>
13302
13303         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
13304
13305 2006-07-07  Simon Josefsson  <jas@extundo.com>
13306
13307         * tests/test-crc.c: Change expected crc value, the test vector
13308         were probably computed using the old broken crc.c?
13309
13310 2006-07-06  Simon Josefsson  <jas@extundo.com>
13311
13312         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
13313         now the canonical place for the M4 file).
13314
13315         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
13316         from the sys_socket dependency now.
13317
13318         * modules/inet_pton (Files): Ditto.
13319
13320         * modules/inet_ntop (Files): Ditto.
13321
13322 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13323
13324         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
13325         not gl_PREREQ_GETUSERSHELL.
13326
13327 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13328
13329         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
13330         with only one argument, for Autoconf 2.60.
13331         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
13332         expand to nothing, so add a shell command to avoid syntax error.
13333         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
13334
13335 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13336
13337         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
13338
13339 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13340
13341         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
13342         no longer needed.  Check for isblank decl.
13343         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
13344         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
13345         of existence.
13346
13347 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13348
13349         * lib/getloadavg.c: Use __VMS, not VMS.
13350         * lib/getopt.c: Likewise.
13351         * lib/getpagesize.h: Likewise.
13352         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
13353         and probably does not work.
13354
13355 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13356
13357         * lib/.cppi-disable: Add wcwidth.
13358         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
13359         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
13360         (ISGRAPH): Remove.  All uses changed to isgraph.
13361         (FOLD) [!defined _LIBC]: Remove special case.
13362         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
13363         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
13364         HAVE_ISBLANK.
13365         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
13366         case.
13367
13368 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13369
13370         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
13371         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
13372         brackets.  Other minor changes to suppress some compiler
13373         warnings.
13374
13375 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13376         and Paul Eggert  <eggert@cs.ucla.edu>
13377
13378         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
13379         of invoking obsolescent AC_HEADER_DIRENT macro.
13380         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
13381         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
13382         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
13383         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
13384         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
13385         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
13386         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
13387         * m4/readdir.m4: Remove; no longer needed.
13388
13389 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13390         and Paul Eggert  <eggert@cs.ucla.edu>
13391
13392         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
13393         Don't worry about this obsolete case any more.
13394         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
13395         directories.
13396         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
13397         worry about this obsolete case any more.
13398         * lib/fts.c: Likewise.
13399         * lib/getcwd.c: Likewise.
13400         * lib/glob.h: Likewise.
13401         * lib/savedir.c: Likewise.
13402
13403 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13404
13405         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13406         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13407         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13408         needed.
13409         All uses removed.
13410         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13411         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13412         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13413         needed.
13414         * m4/getdate.m4 (gl_GETDATE): Likewise.
13415         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13416         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13417         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13418         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13419         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13420         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13421         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13422         needed.
13423
13424 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13425
13426         * lib/memcasecmp.c: Include <limits.h>.
13427         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13428         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13429         Don't assume isdigit succeeds only on '0' through '9'.
13430
13431 2006-07-05  Eric Blake  <ebb9@byu.net>
13432
13433         * modules/getaddrinfo (Depends-on): Add snprintf.
13434
13435 2006-07-05  Eric Blake  <ebb9@byu.net>
13436
13437         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13438         to avoid 'header present but could not be compiled' on cygwin.
13439
13440 2006-07-05  Eric Blake  <ebb9@byu.net>
13441
13442         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13443         missing from netdb.h.
13444         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13445
13446 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13447
13448         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13449         no longer needed.
13450         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13451         * m4/getdate.m4 (gl_GETDATE): Likewise.
13452         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13453         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13454         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13455         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13456         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13457
13458 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13459
13460         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13461         All uses of is_space replaced by isspace.
13462         * lib/exit.h: Don't talk about STDC_HEADERS.
13463         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13464         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13465         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13466         replaced by isprint etc.
13467         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13468         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13469         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13470         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13471         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13472         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13473
13474 2006-07-05  Bruno Haible  <bruno@clisp.org>
13475
13476         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13477         the function exists, before testing against AIX.
13478         Reported by Martin Lambers <marlam@marlam.de>.
13479
13480 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13481
13482         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13483         From Mark D. Baushke.
13484
13485 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13486
13487         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13488         to the absolute name, not just one, to bypass Sun C 5.8's
13489         "warning: #include of /usr/include/... may be non-portable".
13490
13491 2006-07-04  Eric Blake  <ebb9@byu.net>
13492
13493         * modules/dirname-tests: New test module.
13494         * tests/test-dirname.c: New file, replacing dirname.c
13495         TEST_DIRNAME section that was recently deleted.
13496
13497 2006-07-04  Bruno Haible  <bruno@clisp.org>
13498
13499         Assume ANSI C header files and <ctype.h> functions.
13500         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13501         (mbsnwidth): Use isprint, iscntrl instead.
13502
13503 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13504
13505         Merge from coreutils.
13506         * MODULES.html.sh: Add xstrtold.
13507         * modules/xstrtold: New file.
13508         * modules/cycle-check (Files): Add lib/same-inode.h.
13509         * modules/dirname (Files): Add m4/double-slash-root.m4.
13510         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13511         * modules/mkdir-p (Files): Add lib/same-inode.h.
13512         * modules/same (Files): Add lib/same-inode.h.
13513
13514 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13515
13516         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13517         This is to keep the terminology clean; POSIX talks about
13518         "absolute pathnames", not "full pathnames", but the GNU
13519         Coding Standards say to use "path" for something else;
13520         so use "absolute" to keep both sides happy.
13521         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13522         Set gl_absolute_header, not gl_full_header_path.
13523         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13524         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13525         All uses changed.
13526
13527         Merge from coreutils.
13528
13529         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13530
13531         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13532         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13533         want to require the building of c-strtod.o.
13534         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13535         needs -lm directly.
13536         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13537
13538         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13539
13540         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13541         --as-needed option if available.  Problem reported by Albert Chin in
13542         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13543         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13544         cc merely issues a bunch of annoying warnings for --as-needed
13545         (this problem was reported by Bob Proulx).  Also, try linking with
13546         -lm to detect a bug in binutils 2.16 (this problem was reported
13547         by Ralf Wildenhues).
13548
13549         2006-06-18  Jim Meyering  <jim@meyering.net>
13550
13551         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13552         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13553         macro.
13554         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13555         also check for glibc-2.4's abort-inducing bug.
13556
13557         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13558         Low-probability clean-up should be to use rmdir to get rid of
13559         the just-created directory, not unlink.
13560
13561         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13562         configure fail, and request a bug report to inform us about it.
13563         Add a comment that, barring reports to the contrary, in 2007 we'll
13564         assume ftruncate is universally available.
13565
13566         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13567
13568         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13569
13570         2006-03-12  Jim Meyering  <jim@meyering.net>
13571
13572         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13573         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13574         * m4/same.m4 (gl_SAME): Likewise.
13575         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13576
13577         2006-03-11  Eric Blake  <ebb9@byu.net>
13578
13579         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13580         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13581         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13582         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13583
13584 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13585
13586         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
13587         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
13588         reported by Mark D. Baushke, one in
13589         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
13590
13591         Merge from coreutils.
13592
13593         * lib/.cppi-disable: Add stdint_.h.
13594         * lib/.cvsignore: Add stdint.h.
13595
13596         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13597
13598         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
13599         both double and long double versions.
13600         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
13601         * lib/xstrtold.c: New file.
13602         * lib/xstrtod.h (xstrtold): New decl.
13603
13604         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13605
13606         * lib/filemode.c (setst): Remove.
13607         (strmode): Rewrite to avoid setst.  This makes the code shorter,
13608         (arguably) clearer, and the generated code is a bit smaller on my
13609         Debian GNU/Linux stable x86 host.
13610
13611         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13612
13613         * lib/filemode.c: Include "filemode.h" first, to test the interface.
13614         Assume that filemode.h includes sys/types.h and sys/stat.h.
13615         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
13616         (ftypelet): Reorder to put common cases first, for efficiency.
13617         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
13618         to do 'M'.
13619         (strmode): Renamed from mode_string, and now stores 12 bytes instead
13620         of 10, for compatibility with FreeBSD.  All callers changed.
13621         (filemodestring): Now stores 12 bytes instead of 10, and sets file
13622         types that can't be deduced solely from st_mode.  First arg is now a
13623         const pointer.
13624         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
13625         (strmode): Renamed from mode_string.
13626         (filemodestring): New decl.
13627         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
13628         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
13629         needed.
13630         (S_ISPORT, S_ISWHT): New macros, if not already defined.
13631
13632         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13633
13634         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
13635         fsusage.h now does that.  Include fsusage.h first, to test interface.
13636         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
13637         at most one method (the old code could have generated decls that
13638         didn't conform to C89, not that this was ever exercised).
13639         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
13640
13641         2006-03-19  Jim Meyering  <jim@meyering.net>
13642
13643         Work even in a chroot where d_ino values for entries in "/"
13644         don't match the stat.st_ino values for the same names.
13645         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
13646         number, iterate through all entries again, using lstat instead.
13647         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
13648         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
13649
13650         * lib/getcwd.c (__getcwd): Clarify a comment.
13651         Use memcpy in place of a call to strcpy.
13652
13653         2006-03-12  Jim Meyering  <jim@meyering.net>
13654
13655         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
13656         matches that of the current directory (which we're about to chdir ".."
13657         out of), then save the dev-ino of the parent, instead.
13658
13659         * lib/same-inode.h (SAME_INODE): New file/macro.
13660         * lib/chdir-safer.c (SAME_INODE): Remove definition.
13661         Include "same-inode.h", instead.
13662         * lib/same.c: Likewise.
13663         * lib/cycle-check.h: Include "same-inode.h".
13664         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
13665         * lib/cycle-check.c (SAME_INODE): Remove definition.
13666         * lib/root-dev-ino.h: Include "same-inode.h".
13667
13668         2006-03-11  Eric Blake  <ebb9@byu.net>
13669
13670         * lib/same.c (same_name): s/base_name/last_component/
13671         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
13672         * lib/filenamecat.c (file_name_concat): Likewise.
13673
13674         2006-03-11  Eric Blake  <ebb9@byu.net>,
13675                     Paul Eggert  <eggert@cs.ucla.edu>
13676
13677         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
13678         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
13679         drive prefix.
13680         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
13681         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
13682         (last_component): New method.
13683         * lib/dirname.c (dir_len): Determine when drive letters need a
13684         subsequent slash.  Preserve // when it is special.
13685         (dir_name): Don't append dot when drive letter is absolute.
13686         [TEST_DIRNAME]: Move into a full-blown gnulib test.
13687         * lib/basename.c (base_name): New semantics - malloc the result.
13688         Preserve // when it is special.  Preserve relative files that look
13689         like drive letters.
13690         (base_len): Preserve // when it is special.
13691         (last_component): New method, similar to old base_name semantics.
13692         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
13693         base_name.  Strip redundant slashes from ///.
13694
13695 2006-07-03  Jim Meyering  <jim@meyering.net>
13696
13697         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
13698         macro is used before the first cycle_check call.
13699
13700 2006-07-03  Eric Blake  <ebb9@byu.net>
13701
13702         * modules/dirname (Depends-on): Add xstrndup.
13703
13704 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13705
13706         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
13707         test cases, so that config.log is a bit easier to follow.
13708
13709 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13710
13711         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
13712         both are 64 bits, since this seems to be the tradition, and this
13713         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
13714         we ever run into a host that prefers long long to long in this
13715         case, we'll need another configure-time test.  Problem reported by
13716         Jim Meyering.
13717
13718 2006-07-02  Eric Blake  <ebb9@byu.net>
13719
13720         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
13721
13722 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13723
13724         * modules/inttypes (Depends-on): No longer depends on stdint.
13725         * modules/stdint (Description): Say more about assumptions.
13726         Say that the fast types might differ.  Say macros are used.
13727         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
13728         (Makefile.am): Revise list of substituted symbols to match
13729         new stdint.m4.
13730         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
13731         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
13732         * tests/test-stdint.c (verify_same_types)
13733         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
13734         the code conforms to C99/C89.
13735         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
13736         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
13737
13738 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13739
13740         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
13741         but fix a bug, by requiring at least 64 bits.
13742         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
13743         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
13744         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
13745         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
13746
13747         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
13748         changes.  Make 2.59 a prerequisite.  Check and substitute for
13749         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
13750         inttypes.h.  Do not use special include files; just use the
13751         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
13752         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
13753         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
13754         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
13755         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
13756         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
13757         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
13758         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
13759         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
13760         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
13761         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
13762         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
13763         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
13764         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
13765         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
13766         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
13767         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
13768         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
13769         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
13770         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
13771         WINT_MAX.  Check for C99 conformance more strictly, by detecting
13772         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
13773         not check for things that C99 does not require, e.g., int8_t.  If
13774         a test isn't needed unless <stdint.h> isn't working, and is
13775         unlikely to be needed for any other reason, then don't do it
13776         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
13777         size_t, since we assume C89 freestanding at least.  Do not check
13778         for sig_atomic_t, wchar_t, or wint_t, since the code now does
13779         the right thing even if the types are not defined.  Instead use:
13780         (gl_STDINT_TYPE_PROPERTIES): New macro.
13781         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
13782         testing whether <sys/types.h> clashes, as Autoconf does this for
13783         us now.  All uses removed.
13784         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
13785         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
13786         (gl_CHECK_TYPE_SAME):
13787         Remove; no longer needed.
13788         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
13789         exists, since we'll return 0 anyway in that case.
13790         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
13791
13792 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13793
13794         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
13795         possible collision with system files.
13796         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
13797         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
13798         WCHAR_MIN and WCHAR_MAX in this case.
13799         (<stddef.h>): Do not include; no longer needed.
13800         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
13801         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
13802         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
13803         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
13804         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
13805         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
13806         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
13807         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
13808         !defined(__c99))]: Include in this case too, since it's harmless
13809         now.
13810         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
13811         dangerous to do so.
13812         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
13813         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
13814         (_STDINT_MIN, _STDINT_MAX): New macros.
13815         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
13816         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
13817         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
13818         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
13819         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
13820         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
13821         macros, not typedefs; this simplifies things quite a bit.
13822         Use long int for all types narrower than int64_t.
13823         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
13824         Define in terms of long long int or int64_t or long int,
13825         not int64_t or int32_t.  This saves some compile-time testing.
13826         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
13827         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
13828         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
13829         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
13830         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
13831         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
13832         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
13833         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
13834         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
13835         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
13836         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13837         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13838         undef any previous version and define our own version, for
13839         simplicity and consistency with the new macros for types.
13840         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13841         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13842         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
13843         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
13844         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
13845         @WINT_T_SUFFIX@ to keep things simple here.
13846         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
13847         Simplify by assuming typical 8/16/32/64 host, since we're
13848         already doing that elsewhere anyway.
13849         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
13850         and assume long long int is 64 bits if available.  This
13851         speeds up 'configure'.
13852
13853 2006-07-01  Eric Blake  <ebb9@byu.net>
13854
13855         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
13856         Reported by Andreas Buening.
13857
13858 2006-07-01  Eric Blake  <ebb9@byu.net>
13859
13860         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
13861
13862 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13863
13864         * lib/getaddrinfo.c: fixed typo
13865
13866 2006-06-29  Jim Meyering  <jim@meyering.net>
13867
13868         * modules/strftime (Maintainer): Add my name, since with the
13869         FPRINTFTIME changes strftime.c has forked from glibc.
13870
13871 2006-06-29  Eric Blake  <ebb9@byu.net>
13872
13873         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
13874
13875 2006-06-29  Eric Blake  <ebb9@byu.net>
13876
13877         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
13878
13879 2006-06-29  Eric Blake  <ebb9@byu.net>
13880
13881         * lib/stat_.h: New file.
13882
13883 2006-06-29  Eric Blake  <ebb9@byu.net>
13884
13885         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
13886         unused static function.
13887
13888 2006-06-29  Eric Blake  <ebb9@byu.net>
13889
13890         * doc/functions.texi (Function Portability): Document missing lstat
13891         on mingw.
13892
13893 2006-06-29  Eric Blake  <ebb9@byu.net>
13894
13895         * MODULES.html.sh: Add sys_stat.
13896         * modules/sys_stat: New module.
13897         * modules/mkstemp (Depends-on): Add sys_stat.
13898
13899 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13900
13901         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
13902
13903 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13904
13905         * m4/c-bs-a.m4: Removed.
13906
13907 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13908
13909         * lib/strftime.c: Assume strftime() exists.
13910
13911 2006-06-29  Derek Price  <derek@ximbiot.com>
13912
13913         * modules/c-bs-a: Removed - \a is C89.
13914         * MODULES.html.sh: Remove c-bs-a.
13915
13916 2006-06-29  Bruno Haible  <bruno@clisp.org>
13917
13918         * modules/wcwidth (License): Change to LGPL.
13919
13920 2006-06-28  Simon Josefsson  <jas@extundo.com>
13921
13922         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
13923         on _WIN32.
13924
13925         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
13926         getnameinfo.
13927
13928 2006-06-28  Simon Josefsson  <jas@extundo.com>
13929
13930         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
13931
13932 2006-06-28  Simon Josefsson  <jas@extundo.com>
13933
13934         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
13935         functions there.  It will succeed on Windows XP, but on Windows
13936         2000 and (presumably) earlier, it will fail, and use the internal
13937         re-implementation.
13938         (use_win32_p): New function.
13939         (getaddrinfo): Use strtoul on servname, to support numeric ports.
13940         Support AI_NUMERICSERV to disable getservbyname.
13941         (getnameinfo): New function, only supports
13942         NI_NUMERICHOST|NI_NUMERICSERV for now.
13943
13944         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
13945         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
13946         getnameinfo.
13947
13948 2006-06-28  Eric Blake  <ebb9@byu.net>
13949
13950         * modules/wcwidth: New file.
13951         * modules/mbchar (Depends-on): Add wcwidth.
13952         * modules/mbswidth (Depends-on): Add wcwidth.
13953         * MODULES.html.sh: Add wcwidth.
13954
13955 2006-06-28  Eric Blake  <ebb9@byu.net>
13956
13957         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
13958         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
13959
13960 2006-06-28  Eric Blake  <ebb9@byu.net>
13961
13962         * lib/xvasprintf.h: Fix comments.
13963
13964 2006-06-28  Eric Blake  <ebb9@byu.net>
13965
13966         * lib/mbchar.h (wcwidth): Include wcwidth.h.
13967         * lib/mbswidth.c (wcwidth): Move from here...
13968         * lib/wcwidth.h: ...to this new file.
13969
13970 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13971
13972         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
13973
13974         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
13975         it's obsolete.
13976         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
13977
13978 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13979
13980         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
13981         Autoconf 2.60 says this stuff was obsolete.
13982
13983 2006-06-28  Bruno Haible  <bruno@clisp.org>
13984
13985         * modules/wcwidth (Files): Add m4/wchar_t.m4.
13986
13987 2006-06-28  Bruno Haible  <bruno@clisp.org>
13988
13989         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
13990         gt_TYPE_WCHAR_T.
13991
13992 2006-06-28  Bruno Haible  <bruno@clisp.org>
13993
13994         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
13995         declaration for wcwidth.
13996         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
13997
13998 2006-06-28  Bruno Haible  <bruno@clisp.org>
13999
14000         * lib/mkdtemp.c [MINGW]: Include <io.h>.
14001         (mkdir): Define using _mkdir.
14002
14003 2006-06-28  Bruno Haible  <bruno@clisp.org>
14004
14005         * lib/getaddrinfo.h: Fix POSIX URL.
14006         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
14007         _WIN32.
14008         (use_win32_p): Make static.
14009         (getaddrinfo): Reject service name if it is empty or does not consist
14010         solely of decimal digits, or if its value is > 65535.
14011         (getnameinfo): Remove useless casts.
14012
14013 2006-06-27  Simon Josefsson  <jas@extundo.com>
14014
14015         * modules/sys_select: New file, suggested by Bruno Haible, Paul
14016         Eggert and Martin Lambers.
14017
14018 2006-06-27  Simon Josefsson  <jas@extundo.com>
14019
14020         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
14021         Eggert and Martin Lambers.
14022
14023 2006-06-27  Bruno Haible  <bruno@clisp.org>
14024
14025         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
14026         result to 0, not to empty.
14027         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
14028
14029 2006-06-27  Bruno Haible  <bruno@clisp.org>
14030
14031         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
14032
14033 2006-06-26  Simon Josefsson  <jas@extundo.com>
14034
14035         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
14036         present.
14037
14038 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
14039
14040         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
14041         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
14042         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
14043
14044 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
14045
14046         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
14047
14048 2006-06-26  Bruno Haible  <bruno@clisp.org>
14049
14050         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
14051
14052 2006-06-26  Bruno Haible  <bruno@clisp.org>
14053
14054         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
14055
14056 2006-06-26  Bruno Haible  <bruno@clisp.org>
14057
14058         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
14059         SGI C compiler in pre-C99 mode.
14060         Suggested by Mark D. Baushke and Larry Jones.
14061
14062 2006-06-26  Bruno Haible  <bruno@clisp.org>
14063
14064         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
14065         WCHAR_MAX.
14066         Reported by Mark D. Baushke and Larry Jones.
14067
14068 2006-06-26  Bruno Haible  <bruno@clisp.org>
14069
14070         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
14071         in pre-C99 mode.
14072         Suggested by Mark D. Baushke and Larry Jones.
14073
14074 2006-06-23  Simon Josefsson  <jas@extundo.com>
14075             Bruno Haible  <bruno@clisp.org>
14076
14077         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
14078         Emit mostlyclean-local rule.
14079         (func_emit_tests_Makefile_am): Likewise.
14080         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
14081
14082 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
14083
14084         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
14085
14086 2006-06-23  Bruno Haible  <bruno@clisp.org>
14087
14088         * tests/test-stdint.c: Update to match ISO C 99 Technical
14089         Corrigendum 1.
14090
14091 2006-06-23  Bruno Haible  <bruno@clisp.org>
14092
14093         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
14094
14095 2006-06-23  Bruno Haible  <bruno@clisp.org>
14096
14097         * lib/stdint_.h: Treat IRIX like OpenBSD.
14098
14099 2006-06-23  Bruno Haible  <bruno@clisp.org>
14100
14101         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
14102         ISO C 99 Technical Corrigendum 1.
14103
14104 2006-06-22  Simon Josefsson  <jas@extundo.com>
14105
14106         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
14107         MinGW.
14108
14109 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
14110
14111         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
14112         needed.  Some compiler complained about some of them.  Problem reported
14113         by Larry Jones in
14114         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
14115
14116 2006-06-21  Simon Josefsson  <jas@extundo.com>
14117
14118         * tests/test-getaddrinfo.c: New file.
14119
14120         * modules/getaddrinfo-tests: New file.
14121
14122         * MODULES.html.sh: Add inet_pton.
14123
14124         * modules/inet_pton: New file.
14125
14126 2006-06-21  Simon Josefsson  <jas@extundo.com>
14127
14128         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
14129         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
14130         of using the (limited) gnulib implementation on Windows XP.
14131
14132         * m4/inet_pton.m4: New file.
14133
14134 2006-06-21  Simon Josefsson  <jas@extundo.com>
14135
14136         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
14137         variable.
14138
14139         * lib/socket_.h: Don't define WINVER.
14140
14141         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
14142         slightly modified to work in gnulib.
14143
14144 2006-06-21  Simon Josefsson  <jas@extundo.com>
14145
14146         * doc/gnulib.texi (Windows sockets): Add.
14147
14148 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
14149
14150         * lib/read-file.c (fread_file): Start with buffer allocation of
14151         0 bytes rather than 1 byte; this simplifies the code.
14152         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
14153         code to free buffer and save/restore errno.
14154         (internal_read_file): Remove unused local.
14155
14156 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
14157
14158         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
14159         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
14160         Problem reported by Denis Excoffier in
14161         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
14162
14163 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
14164
14165         * modules/sys_socket, modules/socklen: Include sys/types since
14166         FreeBSD 4.x's sys/socket.h needs it.
14167
14168 2006-06-19  Simon Josefsson  <jas@extundo.com>
14169
14170         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
14171
14172 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
14173
14174         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
14175
14176 2006-06-19  Bruno Haible  <bruno@clisp.org>
14177
14178         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
14179         and FULL_PATH_INTTYPES_H in angle brackets.
14180         Reported by Mark D. Baushke <mdb@gnu.org>.
14181
14182 2006-06-17  Eric Blake  <ebb9@byu.net>
14183
14184         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
14185         errno.
14186
14187 2006-06-17  Bruno Haible  <bruno@clisp.org>
14188
14189         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
14190         <sys/inttypes.h>.
14191
14192 2006-06-17  Bruno Haible  <bruno@clisp.org>
14193
14194         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
14195         whether errno is declared. Assume <errno.h> declares errno.
14196
14197 2006-06-17  Bruno Haible  <bruno@clisp.org>
14198
14199         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
14200
14201 2006-06-17  Bruno Haible  <bruno@clisp.org>
14202
14203         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
14204         problem on Solaris 2.5.1.
14205
14206 2006-06-16  Eric Blake  <ebb9@byu.net>
14207
14208         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
14209         * lib/unicodeio.c [!defined errno]: Likewise.
14210         * lib/strtol.c [!defined errno]: Likewise.
14211         * lib/strtod.c [!defined errno]: Likewise.
14212
14213 2006-06-15  Eric Blake  <ebb9@byu.net>
14214
14215         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
14216
14217 2006-06-15  Eric Blake  <ebb9@byu.net>
14218
14219         * config/srclist.txt (ssize_t.m4): Lose sync.
14220
14221 2006-06-15  Bruno Haible  <bruno@clisp.org>
14222
14223         * modules/stdint (Files): Include m4/full-header-path.m4,
14224         m4/size_max.m4, m4/wchar_t.m4.
14225         (Makefile.am): Many more substitutions.
14226         * modules/stdint-tests: New file.
14227         * tests/test-stdint.c: New file.
14228
14229 2006-06-15  Bruno Haible  <bruno@clisp.org>
14230
14231         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
14232         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
14233         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
14234         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
14235         gl_CHECK_TYPE_SAME): New macros.
14236
14237 2006-06-15  Bruno Haible  <bruno@clisp.org>
14238
14239         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
14240
14241 2006-06-15  Bruno Haible  <bruno@clisp.org>
14242
14243         * lib/stdint_.h: Rewritten to be fully auto-configured.
14244         Fixes bug on HP-UX/IA64.
14245
14246 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
14247
14248         * lib/getdate.y (__attribute__): Don't define if already defined.
14249         Problem reported by Larry Jones.
14250         * lib/utimens.c (__attribute__): Likewise.
14251
14252 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
14253
14254         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
14255         reported by Andreas Schwab.
14256
14257 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14258             Bruno Haible  <bruno@clisp.org>
14259
14260         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
14261         check for the declaration of strnlen and a run test that exposes the
14262         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
14263         rpl_strndup.
14264
14265 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14266             Bruno Haible  <bruno@clisp.org>
14267
14268         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
14269
14270 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14271
14272         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
14273         compile test, for Tru64 4.0D.
14274
14275 2006-05-28  Karl Berry  <karl@gnu.org>
14276
14277         * config/srclist.txt (printf-args.c): lose sync.
14278
14279 2006-05-26  Martin Lambers  <marlam@marlam.de>
14280
14281         * lib/getpass.c: Updates the test for the native W32 API, and adds
14282         missing includes, thus fixing compilation warnings.
14283
14284 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14285
14286         * lib/exclude.c (exclude_fnmatch): New function.
14287         (excluded_file_name): Call exclude_fnmatch.
14288         * lib/exclude.h (excluded_file_name): New prototype
14289
14290 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
14291
14292         * lib/tempname.c (small_open, large_open): New macros.
14293         (__open, __open64) [!_LIBC]: Remove.
14294         (__gen_tempname): Use small_open and large_open instead of __open
14295         and __open64.  This fixes a portability bug on HP-UX 11.11i
14296         reported by Simon Wing-Tang in
14297         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
14298
14299 2006-05-24  Bruno Haible  <bruno@clisp.org>
14300
14301         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
14302         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
14303         Reported by Thorsten Maerz <torte@netztorte.de> via
14304         Aaron Stone <aaron@serendipity.cx>.
14305
14306 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14307
14308         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
14309         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
14310         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
14311         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
14312         not really conditional on the cache.
14313         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
14314
14315 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14316
14317         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
14318         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
14319         (my_usleep): Don't mishandle maximum value.
14320
14321 2006-05-19  Jim Meyering  <jim@meyering.net>
14322
14323         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
14324
14325 2006-05-17  Bruno Haible  <bruno@clisp.org>
14326
14327         Cygwin portability.
14328         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
14329
14330 2006-05-17  Bruno Haible  <bruno@clisp.org>
14331
14332         * lib/stdint_.h: Fix recognition of Cygwin.
14333
14334 2006-05-15  Bruno Haible  <bruno@clisp.org>
14335
14336         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
14337         on libtool patch by Ralf Wildenhues.
14338
14339 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
14340
14341         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
14342         test for C99 conformance; (bool) 0.5 is an integer constant
14343         expression, but (bool) -0.5 is not.  Problem reported by Fedor
14344         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
14345
14346 2006-05-11  Simon Josefsson  <jas@extundo.com>
14347
14348         * m4/xvasprintf.m4: Fix obvious typo.
14349
14350 2006-05-11  Jim Meyering  <jim@meyering.net>
14351
14352         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
14353         James Lemley.
14354
14355 2006-05-10  Simon Josefsson  <jas@extundo.com>
14356
14357         * lib/md4.c: Typo fix, update copyright years.
14358         (K1, K2): Don't use L because it turn computations into 64-bit on
14359         64-bit platforms.
14360
14361 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
14362
14363         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
14364         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
14365         unwanted sign propagation, e.g., on hosts with 64-bit int.
14366         There still are some problems with reeelly weird theoretical hosts
14367         (e.g., 33-bit int) but it's not worth worrying about now.
14368         * lib/sha1.c (rol): Likewise.
14369         (K1, K2, K3, K4): Remove unnecessary L suffix.
14370
14371 2006-05-10  Bruno Haible  <bruno@clisp.org>
14372
14373         * lib/des.c: Cast to avoid warnings.
14374
14375 2006-05-09  Bruno Haible  <bruno@clisp.org>
14376
14377         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
14378         (Depends-on): Depend also on xsize, stdarg.
14379         (configure.ac): Add gl_XVASPRINTF.
14380
14381 2006-05-09  Bruno Haible  <bruno@clisp.org>
14382
14383         * m4/xvasprintf.m4: New file.
14384
14385 2006-05-09  Bruno Haible  <bruno@clisp.org>
14386
14387         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
14388         (EOVERFLOW): Define fallback value.
14389         (xstrcat): New function.
14390         (xvasprintf): Recognize the special case of a string concatenation.
14391
14392 2006-05-08  Eric Blake  <ebb9@byu.net>
14393
14394         * gnulib-tool (func_version): Base copyright year on CVS date.
14395         (func_emit_copyright_notice): New function.
14396         (func_emit_lib_Makefile_am): Use it.
14397         (func_emit_tests_Makefile_am): Likewise.
14398         (func_import): Likewise.
14399
14400 2006-05-08  Bruno Haible  <bruno@clisp.org>
14401
14402         * modules/stdarg: New file.
14403         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14404
14405 2006-05-08  Bruno Haible  <bruno@clisp.org>
14406
14407         * m4/stdarg.m4: New file, from GNU gettext.
14408
14409 2006-05-08  Bruno Haible  <bruno@clisp.org>
14410
14411         * config/srclist.txt (build-aux/config.rpath): different from latest
14412         release.
14413
14414 2006-05-08  Bruno Haible  <bruno@clisp.org>
14415
14416         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14417
14418 2006-05-05  Jim Meyering  <jim@meyering.net>
14419
14420         * m4/warning.m4: New file, derived from bison's file by the same name.
14421
14422 2006-05-03  Bruno Haible  <bruno@clisp.org>
14423
14424         * lib/stdint_.h: Shorter URL.
14425         * lib/inttypes.h: Likewise.
14426
14427 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14428
14429         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14430
14431 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14432
14433         * lib/verify.h: Document the internals better.  Most of this change
14434         was written by Bruno Haible.
14435
14436 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14437
14438         * doc/verify.texi: New file, partly based on a proposal by
14439         Bruno Haible.
14440
14441 2006-05-02  Bruno Haible  <bruno@clisp.org>
14442
14443         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14444         test from here...
14445         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14446
14447 2006-04-29  Bruno Haible  <bruno@clisp.org>
14448
14449         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14450         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14451
14452 2006-04-29  Bruno Haible  <bruno@clisp.org>
14453
14454         * gnulib-tool: Make --update option actually work.
14455
14456 2006-04-29  Bruno Haible  <bruno@clisp.org>
14457
14458         * doc/gcd.texi: New file.
14459         * doc/gnulib.texi: Include it.
14460
14461 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14462
14463         * lib/getdate.y (get_date): When adding relative date, start with the
14464         initial time, not with the result of the first mktime call.
14465
14466 2006-04-25  Bruno Haible  <bruno@clisp.org>
14467
14468         * gnulib-tool (func_import): Output the include directives in three
14469         blocks, sorted separately.
14470         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14471
14472 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14473
14474         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14475         to define main with arguments, for C++.  Reported by Eric Blake.
14476         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14477         Prefer 'int main ()' to 'int main (void)', for C++.
14478         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14479         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14480         for 'main', for C99 and C++.
14481
14482 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14483
14484         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14485         Don't assume that exit status -1 is valid.
14486         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14487         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14488         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14489         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14490         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14491         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14492         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14493         functions can be used without declaring them, or that you can
14494         exit with status -1.
14495         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14496
14497 2006-04-24  Karl Berry  <karl@gnu.org>
14498
14499         * config/srclist.txt (longdouble.m4): sync lost.
14500
14501 2006-04-24  Eric Blake  <ebb9@byu.net>
14502
14503         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14504
14505 2006-04-24  Bruno Haible  <bruno@clisp.org>
14506
14507         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14508         poll() implementation in AIX.
14509         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14510
14511 2006-04-24  Bruno Haible  <bruno@clisp.org>
14512
14513         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14514         assigned exactly once.
14515
14516 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14517             Bruno Haible  <bruno@clisp.org>
14518
14519         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14520         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14521         for AM_CPPFLAGS.
14522
14523 2006-04-23  Bruno Haible  <bruno@clisp.org>
14524
14525         * modules/copy-file: Depend on unistd.
14526         * modules/execute: Likewise.
14527         * modules/fatal-signal: Likewise.
14528         * modules/findprog: Likewise.
14529         * modules/mkdtemp : Likewise.
14530         * modules/pipe: Likewise.
14531         * modules/wait-process: Likewise.
14532
14533 2006-04-23  Bruno Haible  <bruno@clisp.org>
14534
14535         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14536         condition was already detected.
14537         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14538
14539 2006-04-23  Bruno Haible  <bruno@clisp.org>
14540
14541         * lib/copy-file.c: Include <unistd.h> unconditionally.
14542         * lib/execute.c: Likewise.
14543         * lib/fatal-signal.c: Likewise.
14544         * lib/findprog.c: Likewise.
14545         * lib/mkdtemp.c: Likewise.
14546         * lib/pipe.h: Likewise.
14547         * lib/pipe.c: Likewise.
14548         * lib/wait-process.h: Likewise.
14549
14550 2006-04-23  Bruno Haible  <bruno@clisp.org>
14551
14552         * gnulib-tool (func_usage): Fix --import description. Document
14553         --update.
14554         (func_import): Create temporary file in a temporary directory, if
14555         --dry-run is specified. Silence errors from 'grep' when there are no
14556         m4 files in $m4dir.
14557         (func_create_testdir): Silence errors from 'grep' when there are no
14558         m4 files in $m4dir.
14559         Reported by Karl Berry <karl@freefriends.org>.
14560
14561 2006-04-20  Bruno Haible  <bruno@clisp.org>
14562
14563         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14564         one argument, so that the code will be portable to Autoconf 2.60.
14565         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14566         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14567         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14568
14569 2006-04-19  Derek Price  <derek@ximbiot.com>
14570             Eric Blake  <ebb9@byu.net>
14571
14572         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14573         rather than "/full/path.h".  Update comment to match.  Shorten &
14574         generalize m4_translit call via AS_TR_CPP.
14575
14576 2006-04-19  Derek Price  <derek@ximbiot.com>
14577             Eric Blake  <ebb9@byu.net>
14578
14579         * lib/inttypes.h: Correct grammar in comment.
14580
14581 2006-04-18  Derek Price  <derek@ximbiot.com>
14582             Paul Eggert  <eggert@cs.ucla.edu>
14583
14584         * modules/inttypes: New file.
14585         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
14586
14587 2006-04-18  Derek Price  <derek@ximbiot.com>
14588             Paul Eggert  <eggert@cs.ucla.edu>
14589
14590         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
14591         New files.
14592
14593 2006-04-18  Derek Price  <derek@ximbiot.com>
14594             Paul Eggert  <eggert@cs.ucla.edu>
14595
14596         * lib/inttypes.h: New file.
14597         * lib/strtoimax.c: Assume <inttypes.h>.
14598
14599 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
14600
14601         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
14602         isn't mounted.  Problem reported by Kir Kolyshkin.
14603
14604 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14605
14606         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
14607         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
14608         Derek R. Price.
14609         * lib/regex.h (RE_DUP_MAX): Update comment to match current
14610         implementation.
14611
14612 2006-04-12  Eric Blake  <ebb9@byu.net>
14613
14614         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
14615         is now done automatically by the corresponding Autoconf macro.
14616
14617 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14618
14619         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
14620         time_r.h.
14621
14622 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14623
14624         Merge regex changes from libc, removing some of our
14625         POSIX-conformance changes that were rejected and redoing them in a
14626         less-intrusive way.
14627
14628         * lib/regcomp.c (re_compile_internal, init_dfa):
14629         Length arg is now size_t, not Idx.  All uses changed.
14630         (peek_token): Forward decl now says internal_function.
14631         (__re_error_msgid, __re_error_msgid_idx):
14632         Now static rather than extern with attribute_hidden.
14633         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
14634         For some reason libc prefers K&R style defns for external functions.
14635         (regerror) [!defined _LIBC]: Likewise.
14636         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
14637         (seek_collating_symbol_entry, lookup_collation_sequence_value):
14638         (build_range_exp, build_collating_symbol):
14639         Use K&R-style defn.
14640         (re_compile_fastmap): Use '\0' to memset, not 0.
14641         (utf8_sb_map): Make the calculations more obvious.
14642         (init_dfa, parse_bracket_exp, build_charclass_op):
14643         Call calloc and cast result, as glibc does.
14644         (init_word_char, fetch_token, peek_token, peek_token_bracket):
14645         (build_range_exp, build_collating_symbol):
14646         Now internal functions.
14647
14648         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
14649
14650         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
14651         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
14652         Don't depend on VMS; depend on __VMS instead, for POSIX
14653         namespace cleanness.
14654         (regoff_t): Define to ssize_t, not long int.
14655
14656         Remove the REG_ macros named below.  Instead, make the old names
14657         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
14658         __USE_GNU_REGEX.
14659         (REG_BACKSLASH_ESCAPE_IN_LISTS):
14660         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
14661         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
14662         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
14663         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
14664         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
14665         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
14666         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
14667         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
14668         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
14669         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
14670         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
14671         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
14672         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
14673         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
14674         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
14675         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
14676         (REG_NREGS):
14677         Remove.  All uses replaced by the old RE_* names.
14678         (RE_BACKSLASH_ESCAPE_IN_LISTS):
14679         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
14680         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
14681         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
14682         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
14683         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
14684         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
14685         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
14686         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
14687         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
14688         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
14689         Don't bother having these macros be independent of each others'
14690         values, since they no longer exist in the POSIX name space.
14691
14692         Rename the following member names back to their old names,
14693         unless !__USE_GNU_REGEX.  All uses changed back.
14694         (buffer): Renamed from re_buffer.
14695         (allocated): Renamed from re_allocated.
14696         (used): Renamed from re_used.
14697         (syntax): Renamed from re_syntax.
14698         (fastmap): Renamed from re_fastmap.
14699         (translate): Renamed from re_translate.
14700         (can_be_null): Renamed from re_can_be_null.
14701         (regs_allocated): Renamed from re_regs_allocated.
14702         (fastmap_accurate): Renamed from re_fastmap_accurate.
14703         (no_sub): Renamed from re_no_sub.
14704         (not_bol): Renamed from re_not_bol.
14705         (not_eol): Renamed from re_not_eol.
14706         (newline_anchor): Renamed from re_newline_anchor.
14707         (num_regs): Renamed from rm_num_regs.
14708         (start): Renamed from rm_start.
14709         (end): Renamed from rm_end.
14710
14711         (free_state): Move up a bit.
14712
14713         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
14714         #define to be empty.
14715         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
14716         when that is what is intended.
14717         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
14718         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
14719         (MAX): New macro.
14720         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
14721         All uses changed back to re_malloc, etc.  It's now the caller's
14722         responsibility to check for overflow; all callers changed.
14723         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
14724         (re_x2nrealloc): Remove.
14725         (free_state): Remove decl.
14726
14727         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
14728         (re_set_registers, re_exec):
14729         Use K&R-style defn.
14730
14731         2006-01-31  Roland McGrath  <roland@redhat.com>
14732
14733         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
14734         Reported by Mike Frysinger <vapier@gentoo.org>.
14735
14736         2006-01-15  Andreas Jaeger  <aj@suse.de>
14737
14738         [BZ #1950]
14739         * lib/regex_internal.c (re_string_reconstruct): Adjust for
14740         build_wcs_upper_buffer change.
14741         (build_wcs_upper_buffer): Change return type.
14742
14743         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
14744
14745         * lib/regex_internal.h: Include <stdint.h> if available.
14746
14747         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
14748
14749         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
14750
14751         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
14752
14753         * lib/regcomp.c: Adjust for changed secondary hash function.
14754
14755         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
14756
14757         * lib/regex.h: Pretty printing.
14758         Clean up namespace a bit.
14759
14760         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
14761
14762         * lib/regexec.c (update_cur_sifted_state, check_arrival,
14763         check_arrival_add_next_nodes): Avoid using uninitialized variable.
14764
14765         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14766                     Ulrich Drepper  <drepper@redhat.com>
14767
14768         [BZ #1302]
14769         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
14770         changed.
14771         (bitset_word_t): Renamed from bitset_word.  All uses changed.
14772
14773         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
14774
14775         [BZ #281]
14776         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
14777         * lib/regcomp.c: Remove unnecessary uses of
14778         unsigned RE_TRANSLATE_TYPE.
14779         * lib/regex_internal.h: Likewise.
14780         * lib/regex_internal.c: Likewise.
14781         * lib/regexec.c: Likewise.
14782         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
14783
14784         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
14785
14786         * lib/regexec.c (find_recover_state): Remove unnecessary
14787         initialization.
14788         (transit_state_bkref): Make DFA a const pointer.
14789         (get_subexp): Likewise.
14790         (check_arrival): Likewise.
14791         (update_cur_sifted_state): Likewise.
14792         (re_search_internal): Likewise.
14793         (prune_impossible_nodes): Likewise.
14794         (acquire_init_state_context): Likewise.
14795         (proceed_next_node): Likewise.
14796         (set_regs): Likewise.
14797         (free_fail_stack_return): Likewise.
14798         (check_arrival_expand_ecl): Mark DFA parameter as const.
14799         (check_arrival_expand_ecl_sub): Likewise.
14800         (check_subexp_limits): Likewise.
14801         (sub_epsilon_src_nodes):  Likewise.
14802         (add_epsilon_src_nodes):  Likewise.
14803         (merge_state_array): Likewise.
14804         (update_regs): Likewise.
14805         (build_trtable): Likewise.
14806         (sift_states_backward): Mark MCTX parameter as const.
14807         (build_sifted_states): Likewise.
14808         (update_cur_sifted_state): Likewise.
14809         (sift_states_mkref): Likewise.
14810         (check_arrival_expand_ecl): Mark eclosure as const.
14811         (check_dst_limits_calc_pos_1): Likewise.
14812         * lib/regex_internal.h (re_match_context_t): Make dfa a const
14813         pointer.
14814
14815         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
14816
14817         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
14818         (transit_state_sb): Likewise.
14819         (transit_state_mb): Likewise.
14820         (sift_states_iter_mb): Likewise.
14821         (check_arrival_add_next_nodes): Likewise.
14822         (check_node_accept_bytes): Change first parameter to pointer-to-const.
14823         [_LIBC] (re_search_2_stub): Use mempcpy.
14824
14825         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
14826         mbrtowc for very simple UTF-8 case.
14827
14828         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
14829         a pointer-to-const.
14830         (re_acquire_state_context): Likewise.
14831         * lib/regex_internal.h: Adjust prototypes.
14832
14833         * lib/regex.c: Prevent using C++ compilers.
14834
14835         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
14836         (re_acquire_state_context): Likewise.
14837
14838 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14839
14840         * modules/regex (Depends-on): Add ssize_t.
14841
14842 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14843
14844         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
14845         translation table.
14846
14847 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14848
14849         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
14850
14851 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
14852             Bruno Haible  <bruno@clisp.org>
14853
14854         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
14855         <sys/types.h> and <inttypes.h>.
14856
14857 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14858
14859         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
14860         `__error_t_defined', so argp.h will not typedef the former.
14861
14862 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
14863
14864         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
14865         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
14866         glibc names.  Even if glibc is changed to conform to POSIX, the
14867         traditional names will be available anyway, since regex depends on
14868         the extensions module.  Also, fix a longstanding typo in the
14869         implementation of Spencer ERE test #75 from grep 2.3.  Problems
14870         reported by Emanuele Giaquinta.  Also, change sense of cached
14871         variable, so that the message makes sense.
14872
14873 2006-03-24  Simon Josefsson  <jas@extundo.com>
14874
14875         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
14876         including some doc fixes.
14877         (base64_encode_alloc): Fix +1 bug on allocation failures.
14878
14879 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14880
14881         * lib/base64.c (base64_encode): Do not read past end of array with
14882         unsanitized input on systems with CHAR_BIT > 8.
14883
14884 2006-03-24  Eric Blake  <ebb9@byu.net>
14885
14886         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
14887
14888 2006-03-22  Karl Berry  <karl@gnu.org>
14889
14890         * config/srclist.txt (*setenv.[ch]): get from coreutils.
14891         * config/srclistvars.sh (COREUTILS): new var.
14892
14893 2006-03-17  Jim Meyering  <jim@meyering.net>
14894
14895         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
14896         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
14897
14898 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14899
14900         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
14901         no longer needs it.  Instead, check that regoff_t is as least
14902         as wide as ptrdiff_t.
14903
14904         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
14905         so that our regex.h stays compatible with the installed regex.
14906         This is helpful for installers who configure --without-included-regex.
14907         Problem reported by Emanuele Giaquinta.
14908
14909 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14910
14911         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
14912         Typedef to long int, not to off_, as POSIX will likely change
14913         in that direction.
14914
14915 2006-03-15  Eric Blake  <ebb9@byu.net>
14916
14917         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
14918
14919 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
14920
14921         * lib/argp-help.c (validate_uparams): Fix typo
14922         * lib/argp-parse.c (argp_default_options): Consistently begin help
14923         messages with a lowercase letter.
14924
14925 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
14926
14927         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
14928         overrun buffers and shouldn't be used (much as gets shouldn't be
14929         used).
14930         * lib/time_r.c (asctime_r, ctime_r): Likewise.
14931
14932 2006-03-08  Simon Josefsson  <jas@extundo.com>
14933
14934         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
14935         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14936
14937 2006-03-08  Simon Josefsson  <jas@extundo.com>
14938
14939         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
14940         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14941
14942 2006-03-08  Simon Josefsson  <jas@extundo.com>
14943
14944         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
14945         signal that configure disabled the device.
14946
14947 2006-03-08  Simon Josefsson  <jas@extundo.com>
14948
14949         * build-aux/maint.mk: Fix refresh-po, to handle no translated
14950         languages.
14951
14952 2006-03-07  Simon Josefsson  <jas@extundo.com>
14953
14954         * modules/getopt (Depends-on): Add unistd.
14955
14956         * modules/unistd: New file.
14957
14958 2006-03-07  Simon Josefsson  <jas@extundo.com>
14959
14960         * modules/gc-random: New file.
14961
14962 2006-03-07  Simon Josefsson  <jas@extundo.com>
14963
14964         * m4/unistd_h.m4: New file.
14965
14966 2006-03-07  Simon Josefsson  <jas@extundo.com>
14967
14968         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
14969         test to be side-effect free by storing the result in the cache
14970         variable gl_cv_lib_readline, and moving the assignment of
14971         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
14972         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14973
14974 2006-03-07  Simon Josefsson  <jas@extundo.com>
14975
14976         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
14977         error on missing devices (the functions will return an error).
14978
14979         * m4/gc.m4: Move random stuff to gc-random.m4
14980
14981 2006-03-07  Simon Josefsson  <jas@extundo.com>
14982
14983         * lib/unistd_.h: New file.
14984
14985 2006-03-07  Simon Josefsson  <jas@extundo.com>
14986
14987         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
14988
14989 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14990
14991         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
14992         Problem reported by Juan Manuel Guerrero.
14993
14994 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14995
14996         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
14997         the unistd module.
14998         * lib/getlogin_r.c: Likewise.
14999         * lib/getlogin_r.h: Likewise.
15000         * lib/glob.c: Likewise.
15001         * lib/pagealign_alloc.c: Likewise.
15002         * lib/unistd_.h: Remove; no longer needed.
15003
15004 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15005
15006         * MODULES.html.sh (Support for systems lacking POSIX:2001):
15007         Add unistd.
15008         * modules/c-stack (Depends-on): Add unistd.
15009         * modules/getlogin_r: Likewise.
15010         * modules/glob: Likewise.
15011         * modules/pagealign_alloc: Likewise.
15012         * modules/unistd (Files): Remove lib/unistd_.h.
15013         (EXTRA_DIST): Remove.
15014         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
15015         need unistd_.h.
15016         (MOSTLYCLEANFILES): Remove unistd.h-t.
15017
15018 2006-03-03  Simon Josefsson  <jas@extundo.com>
15019
15020         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
15021
15022 2006-03-03  Simon Josefsson  <jas@extundo.com>
15023
15024         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
15025         libidn and bison.
15026
15027 2006-03-03  Simon Josefsson  <jas@extundo.com>
15028
15029         * build-aux/maint.mk: Add indent target.
15030
15031 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
15032
15033         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
15034         our replacement poll.h in any case, to avoid a differing
15035         declaration from a system header.  Seen on AIX.
15036
15037 2006-03-01  Simon Josefsson  <jas@extundo.com>
15038
15039         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
15040         <kasal@ucw.cz>.
15041
15042 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15043
15044         * modules/gettime (Depends-on): Add extensions module.
15045         * modules/nanosleep (Depends-on): Likewise.
15046         * modules/settime (Depends-on): Likewise.
15047
15048 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15049
15050         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
15051         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
15052         pedantically.
15053         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
15054         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
15055
15056         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
15057         not "==".  Reported by Ralf Wildenhues.
15058
15059 2006-03-01  Karl Berry  <karl@gnu.org>
15060
15061         * doc/Copyright/request-*: new files, synced from gnuorg.
15062
15063 2006-03-01  Karl Berry  <karl@gnu.org>
15064
15065         * config/srclist.txt (Copyright/*): new entries.
15066
15067 2006-02-28  Simon Josefsson  <jas@extundo.com>
15068
15069         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
15070
15071 2006-02-27  Simon Josefsson  <jas@extundo.com>
15072
15073         * lib/base64.h: Indent #define's.  From Jim Meyering
15074         <jim@meyering.net>.
15075
15076 2006-02-27  Jim Meyering  <jim@meyering.net>
15077
15078         Revert the change of 2006-02-24, so these files can continue
15079         to be sync'd from gettext.
15080         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
15081         of `config.h'.
15082
15083 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
15084
15085         * modules/intprops: New file.
15086         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
15087         Add intprops.
15088         * modules/getloadavg (Files): Remove lib/intprops.h.
15089         (Depends-on): Add intprops.
15090         * modules/human: Likewise.
15091         * modules/inttostr: Likewise.
15092         * modules/openat: Likewise.
15093         * modules/sig2str: Likewise.
15094         * modules/userspec: Likewise.
15095         * modules/utimecmp: Likewise.
15096         * modules/xnanosleep: Likewise.
15097         * modules/xstrtol: Likewise.
15098
15099 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
15100
15101         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
15102         * modules/lock-tests (TESTS): Use $(EXEEXT).
15103         * modules/tls-tests: Likewise.
15104         * modules/argp-tests: Likewise.
15105         (check_PROGRAMS): New var, replacing...
15106         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
15107
15108 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15109
15110         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
15111         `config.h'.
15112
15113 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
15114
15115         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
15116
15117 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15118
15119         Sync from coreutils.
15120         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
15121         gl_CHDIR_SAFER.
15122
15123 2006-02-22  Jim Meyering  <jim@meyering.net>
15124
15125         Sync from coreutils.
15126         * m4/chdir-safer.m4: New file.
15127
15128 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
15129
15130         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
15131         AT_FDCWD exceeds INT_MAX.
15132         * lib/openat.h (AT_FDCWD): Likewise.
15133
15134 2006-02-17  Eric Blake  <address@hidden>
15135
15136         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
15137
15138 2006-02-16  Simon Josefsson  <jas@extundo.com>
15139
15140         * modules/getaddrinfo (Depends-on): Add sys_socket.
15141
15142 2006-02-15  Simon Josefsson  <jas@extundo.com>
15143
15144         * build-aux/maint.mk: Add dsyntax-check rule.
15145
15146 2006-02-15  Eric Blake  <ebb9@byu.net>
15147
15148         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
15149         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
15150         'present but cannot compile' warnings on cygwin.
15151         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
15152         use ws2tcpip.h if sys/socket.h works.
15153         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
15154         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
15155
15156 2006-02-14  Simon Josefsson  <jas@extundo.com>
15157
15158         * modules/maintainer-makefile (Files): Rename.
15159
15160         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
15161         and (the local) Makefile.cfg to maint-cfg.mk.
15162
15163         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
15164         to the latter.
15165
15166         * modules/maintainer-makefile: New module.
15167
15168         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
15169         severaly stripped to make it possible to build it up from scratch
15170         with reliable tests.
15171
15172         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
15173         fixes to permit overriding the default actions when configure and
15174         makefile are not available.
15175
15176 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
15177
15178         Sync from coreutils.
15179         * modules/lstat (Depends-on): Don't depend on xalloc.
15180         (License): Change from GPL to LGPL, since this is now simply a
15181         replacement for a libc function.
15182
15183 2006-02-14  Jim Meyering  <jim@meyering.net>
15184
15185         Sync from coreutils.
15186
15187         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
15188         failure on deficient systems, and simplify gnulib lgpl dependencies.
15189         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
15190         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
15191
15192         * lib/xalloc-die.c: Remove unused definition of N_.
15193
15194 2006-02-14  Jim Meyering  <jim@meyering.net>
15195
15196         Sync from coreutils.
15197         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
15198         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
15199         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
15200         double-quote uses of that variable, to accommodate the rare case in
15201         which getmntent is available in none of the libraries checked.  This
15202         happens at least on FreeBSD 5.0.
15203
15204 2006-02-13  Simon Josefsson  <jas@extundo.com>
15205
15206         * gnulib-tool (Usage): Fix --import, from
15207         karl@freefriends.org (Karl Berry).
15208
15209 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15210
15211         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
15212
15213 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
15214
15215         * lib/argp-namefrob.h: Restore changes accidentally lost during the
15216         "autoupdate" on 2005-12-12.
15217
15218 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15219
15220         * modules/closeout (Depends-on): Remove atexit.
15221
15222 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15223
15224         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
15225         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
15226
15227 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
15228
15229         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
15230         __EXTENSIONS__ if this causes compilation to fail.  Problem
15231         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
15232         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
15233
15234 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
15235
15236         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
15237         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
15238         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
15239         All uses changed.
15240
15241 2006-01-26  Simon Josefsson  <jas@extundo.com>
15242
15243         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
15244         prototype is visible on mingw32.
15245
15246         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
15247         for mingw32.
15248
15249         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
15250         mingw32).
15251
15252 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
15253
15254         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
15255         attempt to open for write; this always fails, at least on POSIX
15256         hosts.  This reinstates the 2006-01-09 change, which was
15257         inadvertently removed.
15258
15259 2006-01-26  Bruno Haible  <bruno@clisp.org>
15260
15261         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
15262         Reported by Paul Eggert.
15263
15264 2006-01-26  Bruno Haible  <bruno@clisp.org>
15265             Paul Eggert  <eggert@cs.ucla.edu>
15266
15267         * lib/stdbool_.h (_Bool)
15268         [(! (defined __cplusplus || defined __BEOS__)
15269           && !defined __GNUC__
15270           && !(defined __HP_cc || defined __xlc__
15271                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
15272                || defined __sgi))]:
15273         #define to signed char in these cases too; this simplifies
15274         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
15275         etc., separately) and makes it more conservative.
15276
15277 2006-01-25  Simon Josefsson  <jas@extundo.com>
15278
15279         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
15280         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
15281         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
15282
15283 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
15284
15285         * lib/argp-namefrob.h: Bugfix. Remove stray #
15286
15287 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
15288
15289         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
15290         so that we test the test.
15291         Check for yet another HP-UX cc bug involving *bool |= bool.
15292
15293 2006-01-25  Karl Berry  <karl@gnu.org>
15294
15295         * config/srclist.txt (vasnprintf.c): sync lost.
15296
15297 2006-01-25  Jim Meyering  <jim@meyering.net>
15298
15299         Sync from the stable (b5) branch of coreutils:
15300
15301         * lib/fts.c (fts_children): Don't let close() clobber errno from
15302         failed fchdir().
15303
15304         * lib/fts.c (fts_stat): When following a symlink-to-directory,
15305         don't necessarily interpret stat-fails+lstat-succeeds as indicating
15306         a dangling symlink.  That can also happen at least for ELOOP.
15307         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
15308         FYI, this bug predates the inclusion of fts.c in coreutils.
15309
15310         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
15311         in their own block, so pre-c99 compilers don't object.
15312
15313         Avoid the double-free (first in fts_read, second in fts_close) that
15314         would occur when an `active' directory is made inaccessible (e.g.,
15315         via chmod a-x) during a traversal.
15316         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15317         before returning.  Reproduce this failure by
15318         mkdir -p a/b; cd a; chmod a-x . b
15319         Reported by Stavros Passas.
15320
15321 2006-01-25  Jim Meyering  <jim@meyering.net>
15322
15323         * lib/fileblocks.c: Remove more useless parentheses.
15324         * lib/readutmp.h: Likewise.
15325
15326 2006-01-25  Bruno Haible  <bruno@clisp.org>
15327
15328         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
15329         warnings.
15330         Reported by Paul Eggert.
15331
15332 2006-01-25  Bruno Haible  <bruno@clisp.org>
15333
15334         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
15335         rid of a trap command. For Solaris sh.
15336         Reported by Mark D. Baushke <mdb@gnu.org>.
15337
15338 2006-01-24  Simon Josefsson  <jas@extundo.com>
15339
15340         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
15341         Bruno.
15342
15343 2006-01-24  Karl Berry  <karl@gnu.org>
15344
15345         * config/srclist.txt (argp-namefrob.h): sync lost.
15346
15347 2006-01-24  Jim Meyering  <jim@meyering.net>
15348
15349         * modules/openat (Files): Add lib/intprops.h.
15350         From Mark D. Baushke.
15351
15352 2006-01-24  Jim Meyering  <jim@meyering.net>
15353
15354         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
15355         Reported by Mark D. Baushke.
15356
15357 2006-01-24  Jim Meyering  <jim@meyering.net>
15358
15359         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
15360
15361 2006-01-24  Bruno Haible  <bruno@clisp.org>
15362
15363         * modules/strnlen (Maintainer): Change from glibc to all.
15364
15365 2006-01-24  Bruno Haible  <bruno@clisp.org>
15366
15367         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
15368         Patch by Paul Eggert.
15369
15370 2006-01-24  Bruno Haible  <bruno@clisp.org>
15371
15372         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
15373         already has it.
15374         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
15375         2005-11-26.
15376
15377         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
15378         'signed char' to avoid problems with the built-in _Bool type.
15379         Reported by Paul Eggert on 2005-11-26.
15380
15381 2006-01-24  Bruno Haible  <bruno@clisp.org>
15382
15383         * gnulib-tool (func_import): Avoid constructing complicated sed
15384         expressions inside backquote.
15385         Report and solution by Mark D. Baushke <mdb@gnu.org>.
15386
15387 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
15388
15389         These changes imported from libc.
15390         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
15391         test and two separate function calls.
15392         * lib/strndup.c (__strndup): Add libc_hidden_def.
15393
15394 2006-01-23  Simon Josefsson  <jas@extundo.com>
15395
15396         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
15397         Remove the test_*_SOURCES variable: automake infers it by default.
15398         * modules/tls-tests: Likewise.
15399
15400 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15401
15402         Work around porting bugs reported by Dieter in
15403         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15404         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15405         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15406         Include "getopt.h" first, to check interface.
15407         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15408         !HAVE_DECL_GETENV.
15409         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15410         (__strndup): Revert to K&R-style function dfns, the glibc style.
15411         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15412         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15413         Include strnlen.h first, to get prototype properly.
15414         (strnlen): Renamed from __strnlen.
15415         Remove weak alias.
15416
15417 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15418
15419         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15420
15421 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15422
15423         * config/srclist.txt: Adjust to reflect glibc reorganization.
15424         This affects only comments.
15425
15426 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15427
15428          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15429          Reported by Bruce Korb <bkorb@gnu.org>.
15430
15431 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15432
15433         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15434         to pacify gcc -Wswitch-default.
15435
15436 2006-01-22  Bruno Haible  <bruno@clisp.org>
15437
15438         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15439         temporary buffer for sprintf, take into account the precision also
15440         for 'd', 'i', 'u', 'o', 'x', 'X'.
15441
15442 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15443
15444         * modules/argp-tests: New module
15445         * tests/test-argp.c: New file
15446         * tests/test-argp-2.sh: New file
15447
15448 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15449
15450         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15451         (__argp_base_name): Removed
15452         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15453         typo.
15454         (__argp_base_name): Provide macro definition or extern declaration
15455         depending on the configuration
15456
15457 2006-01-20  Simon Josefsson  <jas@extundo.com>
15458
15459         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15460
15461 2006-01-20  Simon Josefsson  <jas@extundo.com>
15462
15463         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15464
15465 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15466
15467         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15468         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15469         Suggested by Bruno Haible.
15470
15471 2006-01-20  Karl Berry  <karl@gnu.org>
15472
15473         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15474         until changes propagate, I guess.
15475
15476 2006-01-19  Simon Josefsson  <jas@extundo.com>
15477
15478         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15479
15480 2006-01-19  Simon Josefsson  <jas@extundo.com>
15481
15482         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15483
15484 2006-01-19  Simon Josefsson  <jas@extundo.com>
15485
15486         * gnulib-tool: Set check_PROGRAMS.
15487
15488         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15489         modules/des-tests, modules/gc-arcfour-tests,
15490         modules/gc-arctwo-tests, modules/gc-des-tests,
15491         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15492         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15493         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15494         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15495         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15496         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15497         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15498         test_*_SOURCES.
15499
15500 2006-01-18  Simon Josefsson  <jas@extundo.com>
15501
15502         * modules/socklen (Depends-on): Depend on sys_socket.
15503
15504 2006-01-18  Simon Josefsson  <jas@extundo.com>
15505
15506         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15507         modules/des-tests, modules/gc-arcfour-tests,
15508         modules/gc-arctwo-tests, modules/gc-des-tests,
15509         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15510         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15511         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15512         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15513         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15514         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15515         $(EXEEXT) to automake TESTS variable, for mingw32.
15516
15517 2006-01-17  Simon Josefsson  <jas@extundo.com>
15518
15519         * modules/socklen (Include): Need sys/socket.h.
15520
15521 2006-01-17  Bruno Haible  <bruno@clisp.org>
15522
15523         * modules/ssize_t (Include): Add <sys/types.h>.
15524
15525 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15526
15527         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15528         it's not portable and it doesn't work with cross-compiles.
15529         Problem reported by Bruno Haible.  Fix missing-$ typo in
15530         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15531         -zignore from being used with Sun's C compiler.
15532
15533 2006-01-12  Simon Josefsson  <jas@extundo.com>
15534
15535         * lib/base64.c: Fix warning, reported by Bruno Haible
15536         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15537
15538 2006-01-12  Bruno Haible  <bruno@clisp.org>
15539
15540         * modules/ldd: New file.
15541         * build-aux/ldd.sh.in: New file.
15542         * MODULES.html.sh (Support for building libraries and executables): Add
15543         ldd.
15544
15545 2006-01-12  Bruno Haible  <bruno@clisp.org>
15546
15547         * m4/ldd.m4: New file.
15548
15549 2006-01-12  Bruno Haible  <bruno@clisp.org>
15550
15551         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15552         endless loop while replacing $auxdir with build-aux.
15553
15554 2006-01-11  Simon Josefsson  <jas@extundo.com>
15555
15556         * lib/stdint_.h (SIZE_MAX): Add missing (.
15557
15558 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15559
15560         Sync from coreutils.
15561         * lib/md5.c: Fix commentary typos.
15562         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15563         * lib/md5.h (__attribute__): Remove; unused.
15564         * lib/sha1.c: Fix commentary to match md5 better.
15565         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15566         so that we don't need to worry about alignment.  All uses changed.
15567         This merges the 2005-10-28 md5 change into sha1.
15568
15569 2006-01-11  Jim Meyering  <jim@meyering.net>
15570
15571         Sync from coreutils.
15572         * lib/md5.c (OP): Fix spacing.
15573
15574 2006-01-11  Bruno Haible  <bruno@clisp.org>
15575
15576         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15577         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15578         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15579
15580 2006-01-11  Bruno Haible  <bruno@clisp.org>
15581
15582         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15583         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15584         the "early" section as well.
15585
15586 2006-01-11  Bruno Haible  <bruno@clisp.org>
15587
15588         Avoid "ar: no archive members specified" error on MacOS X.
15589         * gnulib-tool (func_modules_add_dummy): New function.
15590         (func_import, func_create_testdir): Invoke it.
15591
15592 2006-01-11  Bruno Haible  <bruno@clisp.org>
15593
15594         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
15595         with $auxdir in AC_CONFIG_FILES statements.
15596
15597 2006-01-11  Bruno Haible  <bruno@clisp.org>
15598
15599         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
15600         Initialize also noinst_HEADERS to empty.
15601
15602 2006-01-11  Bruno Haible  <bruno@clisp.org>
15603
15604         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
15605         variables.
15606         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
15607         autoreconf.
15608
15609 2006-01-11  Bruno Haible  <bruno@clisp.org>
15610
15611         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
15612         overridable by the user.
15613         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15614
15615 2006-01-10  Simon Josefsson  <jas@extundo.com>
15616
15617         * modules/sys_socket: New file.
15618
15619 2006-01-10  Simon Josefsson  <jas@extundo.com>
15620
15621         * m4/sys_socket_h.m4: New file.
15622
15623 2006-01-10  Simon Josefsson  <jas@extundo.com>
15624
15625         * lib/socket_.h: New file.
15626
15627 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15628
15629         * modules/readutmp (Maintainer): Add myself.
15630
15631 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15632
15633         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
15634         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
15635         People who are still concerned with buggy memcmp implementations
15636         can invoke gl_FUNC_MEMCMP themselves.
15637
15638 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15639
15640         * lib/regex_internal.h (BITSET_WORD_BITS):
15641         Work around a bug in 64-bit PGC (before version 6.1-2), where the
15642         preprocessor mishandles large unsigned values as if they were signed.
15643         Problem reported by Claudio Fontana in
15644         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
15645
15646 2006-01-10  Jim Meyering  <jim@meyering.net>
15647
15648         Avoid the double-free (first in fts_read, second in fts_close) that
15649         would occur when an `active' directory is made inaccessible (e.g.,
15650         via chmod a-x) during a traversal.
15651         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15652         before returning.  Reproduce this failure by
15653         mkdir -p a/b; cd a; chmod a-x . b
15654         Reported by Stavros Passas.
15655
15656         Sync from coreutils.
15657         * lib/sha1.c: Tweak grammar in a comment.
15658
15659 2006-01-10  Jim Meyering  <jim@meyering.net>
15660
15661         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
15662         Patch by Joerg Sonnenberger.
15663
15664 2006-01-10  Bruno Haible  <bruno@clisp.org>
15665
15666         * modules/readutmp: Depend on module free.
15667         * modules/strtok_r: Depend on module restrict.
15668
15669 2006-01-10  Bruno Haible  <bruno@clisp.org>
15670
15671         * modules/gettext (configure.ac): Add an invocation of
15672         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
15673
15674 2006-01-10  Bruno Haible  <bruno@clisp.org>
15675
15676         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
15677         Reported by Werner Lemberg <wl@gnu.org>.
15678
15679 2006-01-10  Bruno Haible  <bruno@clisp.org>
15680
15681         * lib/localcharset.c: Update from GNU gettext.
15682
15683 2006-01-10  Bruno Haible  <bruno@clisp.org>
15684
15685         * lib/argp.h (__const): Remove macro. Use const instead.
15686         * lib/argp-fmtstream.h (__const): Likewise.
15687         * lib/glob_.h (__const): Remove macro.
15688         * lib/glob-libc.h: Use const instead of __const.
15689
15690 2006-01-10  Bruno Haible  <bruno@clisp.org>
15691
15692         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
15693         variable.
15694         Needed to avoid an automake error regarding the 'gettext' module.
15695
15696 2006-01-09  Simon Josefsson  <jas@extundo.com>
15697
15698         * modules/inet_ntop (Depends-on): Add restrict.
15699
15700 2006-01-09  Simon Josefsson  <jas@extundo.com>
15701
15702         * modules/gc-rijndael-tests (License): Put under LGPL.
15703
15704         * modules/gc-des-tests (License): Likewise.
15705
15706         * modules/gc-arcfour-tests (License): Likewise.
15707
15708         * modules/gc-arctwo-tests (License): Likewise.
15709
15710         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
15711
15712         * modules/gc-hmac-sha1-tests (Files): Likewise.
15713
15714         * modules/gc-hmac-md5-tests (License): Likewise.
15715
15716         * modules/gc-sha1-tests (License): Likewise.
15717
15718         * modules/gc-md5-tests (License): Likewise.
15719
15720         * modules/gc-md4-tests (License): Likewise.
15721
15722         * modules/gc-md2-tests (License): Likewise.
15723
15724         * modules/gc-tests (License): Likewise.
15725
15726         * modules/des-tests (License): Likewise.
15727
15728         * modules/md4-tests (License): Likewise.
15729
15730         * modules/md2-tests (License): Likewise.
15731
15732 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15733
15734         Sync from coreutils:
15735
15736         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
15737         * modules/lib-ignore: New file.
15738         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
15739         chdir-safer.m4, lchmod.m4.
15740         * modules/openat: Add mkdirat.c, openat-priv.h.
15741
15742 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15743
15744         Sync from coreutils.
15745         * m4/lib-ignore.m4: New file.
15746         * m4/lchmod.m4: New file.
15747
15748 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15749
15750         Sync from coreutils.
15751         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
15752         for write access: POSIX says that must fail.
15753         * lib/fts.c (diropen): Likewise.
15754         * lib/save-cwd.c (save_cwd): Likewise.
15755         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
15756         well, for minor improvements on hosts that lack O_DIRECTORY.
15757         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
15758         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
15759         Fall back on chown if open failed with EACCES.
15760
15761         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
15762         Report an error at compile-time if only a 1-second nominal clock
15763         resolution is found.
15764
15765         * lib/lchmod.h: New file.
15766         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
15767         (make_dir_parents): Use lchown rather than chown, and
15768         lchmod rather than chmod.
15769
15770         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
15771         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
15772         "proc" reported by n0dalus.
15773
15774         * lib/mountlist.c: Include <limits.h>.
15775         (dev_from_mount_options)
15776         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
15777         New function.  It no longer assumes "dev=" has the System V meaning
15778         on Linux (since it doesn't).  It also parses "dev=" more carefully.
15779         (read_file_system_list)
15780         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
15781         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
15782         dev= in that case.
15783
15784         * lib/posixtm.h (PDS_PRE_2000): New macro.
15785         * lib/posixtm.c (year): Arg is now syntax_bits rather than
15786         allow_century.  All usages changed.  Reject dates outside the range
15787         1969-1999 if PDS_PRE_2000 is used.
15788
15789 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15790
15791         Sync from coreutils.
15792         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
15793         (Time of day items): Mention the possibility of leap seconds.
15794         Problem reported by Dr. David Alan Gilbert.
15795
15796 2006-01-09  Jim Meyering  <jim@meyering.net>
15797
15798         Sync from coreutils.
15799
15800         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
15801
15802         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
15803
15804         * lib/modechange.c (mode_compile): Reject an invalid mode string
15805         that starts with an octal digit.  From Andreas Gruenbacher.
15806
15807         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
15808         and dup to open_safer and dup_safer, respectively.
15809         (openat_permissive): Fix typo in comment.
15810
15811         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
15812         "gettext.h"; either no longer needed or are guaranteed by openat.h.
15813         (_): Remove; no longer needed.
15814         (openat): Renamed from rpl_openat; no need for rpl_openat
15815         since openat.h renames openat for us.
15816         Replace most of the body with a call to openat_permissive,
15817         to avoid duplicate code.
15818         Port to (probably hypothetical) environments were mode_t is
15819         wider than int.
15820         (openat_permissive): Require mode arg, so that we can check
15821         types better.  Put it just after flags.  Change cwd failure
15822         indicator from pointer-to-bool to pointer-to-errno-value.
15823         All callers changed.
15824         Invoke openat_save_fail and/or openat_restore_fail if
15825         cwd_errno is null, so that openat can call us.
15826         (openat_permissive, fdopendir, fstatat, unlinkat):
15827         Simplify errno handling to avoid some duplicate code,
15828         as it's OK to set errno on success.
15829         * lib/openat.h: Revamp code so that function macros depend on
15830         __OPENAT_PREFIX only, not also on AT_FDCWD.
15831         (openat_ro): Remove.  Caller changed to use openat_permissive.
15832         (openat_permissive): Now a macro, if not a function.
15833         (openat_restore_fail, openat_save_fail): Now always functions,
15834         since mkdirat needs them even if __OPENAT_PREFIX is defined.
15835
15836         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
15837         and openat.c.
15838         * lib/mkdirat.c: Include openat-priv.h.
15839         Remove definitions of macros defined therein.
15840         * lib/openat.c: Likewise.
15841
15842         * lib/mkdirat.c (mkdirat): New file and function.
15843         * lib/openat.h (mkdirat): Declare.
15844
15845         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
15846
15847         * lib/openat.h (openat_permissive): Declare.
15848         (openat_ro): Define.
15849
15850         * lib/openat.c (EXPECTED_ERRNO): New macro.
15851         (openat_permissive): New function -- used in remove.c rewrite.
15852         (all functions): Set errno just before returning, only if there
15853         was an actual failure.
15854         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
15855
15856         Emulate openat-family functions using Linux's procfs, if possible.
15857         Idea and some code based on Ulrich Drepper's glibc changes.
15858
15859         * lib/openat.c: (BUILD_PROC_NAME): New macro.
15860         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
15861         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
15862         before falling back on save_cwd and restore_cwd.
15863         (fdopendir, fstatat, unlinkat): Likewise.
15864
15865         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
15866         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
15867
15868         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
15869         as second argument to va_arg.  Otherwise, some versions of gcc
15870         warn that `if this code is reached, the program will abort'.
15871
15872 2006-01-09  Jim Meyering  <jim@meyering.net>
15873
15874         Sync from coreutils.
15875         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
15876         Require openat-priv.h.
15877
15878 2006-01-09  Bruno Haible  <bruno@clisp.org>
15879
15880         * modules/strnlen (Include): Use strnlen.h.
15881
15882 2006-01-09  Bruno Haible  <bruno@clisp.org>
15883
15884         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
15885
15886 2006-01-09  Bruno Haible  <bruno@clisp.org>
15887
15888         * lib/sysexit_.h (EX_OK): New macro.
15889         Suggested by Martin Lambers <marlam@marlam.de>.
15890
15891 2006-01-09  Bruno Haible  <bruno@clisp.org>
15892
15893         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
15894         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
15895
15896 2006-01-09  Bruno Haible  <bruno@clisp.org>
15897
15898         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
15899         numbers.
15900
15901 2006-01-09  Bruno Haible  <bruno@clisp.org>
15902
15903         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
15904         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
15905         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
15906         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
15907
15908 2006-01-09  Bruno Haible  <bruno@clisp.org>
15909
15910         * build-aux/javacomp.sh.in: New file, moved from lib/.
15911         * modules/javacomp-script (Files): Update.
15912         (configure.ac): Add AC_CONFIG_FILES invocation.
15913         (EXTRA_DIST): Remove variable.
15914
15915         * build-aux/javaexec.sh.in: New file, moved from lib/.
15916         * modules/javaexec (Files): Update.
15917         (configure.ac): Add AC_CONFIG_FILES invocation.
15918         (EXTRA_DIST): Remove javaexec.sh.in.
15919
15920         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
15921         * modules/csharpcomp-script (Files): Update.
15922         (configure.ac): Add AC_CONFIG_FILES invocation.
15923         (EXTRA_DIST): Remove variable.
15924
15925         * build-aux/csharpexec.sh.in: New file, moved from lib/.
15926         * modules/csharpexec (Files): Update.
15927         (configure.ac): Add AC_CONFIG_FILES invocation.
15928         (EXTRA_DIST): Remove csharpexec.sh.in.
15929
15930 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15931
15932         Sync from coreutils.
15933
15934         Add POSIX ACL support
15935         * lib/acl.h (copy_acl, set_acl): Add declarations.
15936         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
15937         systems other than Linux.
15938         (chmod_or_fchmod): New function: use fchmod when possible,
15939         and chmod otherwise.
15940         (file_has_acl): Add a POSIX ACL implementation, with a
15941         Linux-specific subcase.
15942         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
15943         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
15944         acls are unsupported.
15945         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
15946         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
15947         are unsupported.
15948
15949 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15950
15951         Sync from coreutils.
15952         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
15953
15954 2006-01-07  Bruno Haible  <bruno@clisp.org>
15955
15956         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
15957         gl_EARLY.
15958
15959 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15960
15961         * lib/strftime.c (tzname): Don't declare if it is already #defined.
15962         Problem reported for Mingw by Mark Junker.
15963
15964 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15965
15966         * README: Gnulib normally doesn't generate a tarball.
15967
15968 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
15969
15970         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
15971         long int, not int, for nanosecond counts, so that people who are
15972         used to POSIX struct timespec won't be surprised.  Reported by Jim
15973         Meyering.
15974
15975 2005-12-28  Bruno Haible  <bruno@clisp.org>
15976
15977         * build-aux/config.rpath: Update from GNU gettext.
15978
15979 2005-12-16  Jim Meyering  <jim@meyering.net>
15980
15981         * modules/fprintftime: New module.
15982         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
15983
15984 2005-12-16  Jim Meyering  <jim@meyering.net>
15985
15986         * m4/fprintftime.m4: New file.
15987
15988 2005-12-16  Jim Meyering  <jim@meyering.net>
15989
15990         * lib/fprintftime.c, lib/fprintftime.h: New files.
15991
15992 2005-12-15  Simon Josefsson  <jas@extundo.com>
15993
15994         * modules/socklen (configure.ac): Fix M4 macro name, to align with
15995         new m4/socklen.m4.
15996
15997 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
15998
15999         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
16000         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
16001
16002 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16003
16004         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
16005         * lib/argp-help.c (fill_in_uparams): Check if the constructed
16006         struct uparams is valid. Fall back to the default values if it is
16007         not.
16008
16009 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16010
16011         * modules/argp (Files): Add argp-pin.c
16012         (Depends-on): dirname
16013         (lib_SOURCES): Add argp-pin.c
16014
16015 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16016
16017         * m4/argp.m4:  Check if program_invocation_name and
16018         program_invocation_short_name are declared and define appropriate
16019         macros if they are not.
16020
16021 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16022
16023         * lib/argp-help.c (__argp_base_name): New function
16024         (__argp_short_program_name): Rewrite using __argp_base_name
16025         * lib/argp-namefrob.h: Define program_invocation_name and
16026         program_invocation_short_name if requested
16027         (__argp_base_name): Add prototype
16028         * lib/argp-parse.c (argp_def): Use gettext wrappers
16029         (argp_default_parser): Use __argp_base_name
16030         * lib/argp-pin.c: New file. Defines program_invocation_name and
16031         program_invocation_short_name on systems that lack them.
16032
16033 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16034
16035         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
16036         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16037         porting problem reported by Georg Schwarz in
16038         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16039
16040 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16041
16042         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
16043         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16044         porting problem reported by Georg Schwarz in
16045         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16046
16047 2005-12-05  Bruno Haible  <bruno@clisp.org>
16048
16049         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
16050         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
16051         Reported by Mark Junker <mjscod@gmx.de>.
16052
16053 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
16054
16055         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
16056         Use implementation from Albert Chin, with some
16057         comments/corrections by Stepan Kasal and myself.
16058
16059 2005-12-02  Bruno Haible  <bruno@clisp.org>
16060
16061         * gnulib-tool (func_import): Accept GPLed build tool modules when
16062         --lgpl is given.
16063         * modules/csharpcomp-script: New file.
16064         * modules/csharpcomp: Depend on it.
16065         * modules/javacomp-script: New file.
16066         * modules/javacomp: Depend on it.
16067         Suggested by Simon Josefsson.
16068
16069 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
16070
16071         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
16072         statement, to work around an HP-UX 10.20 compiler bug reported by
16073         Peter O'Gorman.
16074
16075 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16076
16077         * modules/savedir (Depends-on): Add openat.
16078
16079 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16080
16081         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
16082         (uintmax_t) [defined uintmax_t]: Do not declare.
16083         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
16084         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
16085         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
16086         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
16087         sake of portability to weird hosts that C allows (though we don't
16088         know of any practical examples).
16089
16090         * lib/savedir.h (fdsavedir): New decl.
16091         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
16092         contains most of the former guts of savedir.
16093         (savedir): Use savedirstream.
16094         Include "openat.h".
16095
16096 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
16097
16098         * modules/obstack (Files): Add m4/ulonglong.m4.
16099         Problem reported by Davide Angelocola.
16100
16101 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
16102
16103         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
16104         coreutils no longer futzes with rounding modes.
16105
16106 2005-11-14  Jim Meyering  <jim@meyering.net>
16107
16108         * lib/mkstemp-safer.c: Include <config.h>, required for possible
16109         replacement of mkstemp.
16110
16111 2005-11-10  Simon Josefsson  <jas@extundo.com>
16112
16113         * lib/readline.c: Remove EOL.
16114
16115 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16116
16117         * modules/gethrxtime (Depends-on): Add gettime.
16118
16119 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16120
16121         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
16122         or gettimeofday; no longer needed.
16123
16124 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16125
16126         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
16127         time business.
16128         (gethrxtime) [! (HAVE_NANOUPTIME
16129         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
16130         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
16131         our own approximation.
16132
16133 2005-11-08  Eric Blake  <ebb9@byu.net>
16134
16135         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16136
16137 2005-11-08  Eric Blake  <ebb9@byu.net>
16138
16139         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16140
16141 2005-11-04  Bruno Haible  <bruno@clisp.org>
16142
16143         * gnulib-tool: Implement --update mode.
16144
16145 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16146
16147         Fix porting problem reported by Theodoros V. Kalamatianos.
16148         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
16149         Don't assume that futimes failing means we must fail.
16150
16151 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16152
16153         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
16154         variables to suggest the intended function of the PATH_MAX check.
16155
16156 2005-10-30  Kean Johnston  <jkj@sco.com>
16157
16158         Trivial changes to support SCO systems.
16159         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
16160         as PATH_MAX.
16161         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
16162         where __ptr is null when no I/O is pending.
16163
16164 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
16165
16166         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
16167         leave errno alone.  Problem reported by Dmitry V. Levin.
16168
16169 2005-10-28  Simon Josefsson  <jas@extundo.com>
16170
16171         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
16172         Test more.
16173
16174         * tests/test-gc-md2.c, tests/test-md2.c: New files.
16175
16176         * modules/md2, modules/md2-tests: New files.
16177
16178 2005-10-28  Simon Josefsson  <jas@extundo.com>
16179
16180         * m4/inet_ntop.m4: More tests.
16181
16182         * m4/gc-md2.m4, md2.m4: New file.
16183
16184 2005-10-28  Simon Josefsson  <jas@extundo.com>
16185
16186         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
16187         "restrict" keywords, as per POSIX.  Protect the function
16188         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
16189         Don't use K&R prototypes.  Check the sprintf return values.
16190         Re-define EAFNOSUPPORT if not present.  Indent.
16191
16192         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
16193         suggested by Bruno Haible <bruno@clisp.org>.
16194
16195         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
16196
16197         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
16198
16199         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
16200         libgcrypt).
16201
16202         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
16203
16204         * lib/md2.h, lib/md2.c: New files.
16205
16206 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
16207
16208         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
16209         errno alone.  Problem reported by Frederic Jolliton.
16210
16211 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
16212
16213         * modules/verify (License): Change from GPL to LGPL.  This is a
16214         tiny module and there are apparently near-equivalents that are
16215         under the BSD license.
16216
16217 2005-10-24  Simon Josefsson  <jas@extundo.com>
16218
16219         * modules/sha1: Relicense to LGPL.
16220
16221 2005-10-24  Simon Josefsson  <jas@extundo.com>
16222
16223         * lib/md4.h: Shrink buffer size, now that we changed the type.
16224
16225 2005-10-23  Simon Josefsson  <jas@extundo.com>
16226
16227         * gnulib-tool (func_import): Fix --tests-base.
16228
16229 2005-10-22  Simon Josefsson  <jas@extundo.com>
16230
16231         * modules/arcfour (Depends-on): Need stdint.
16232
16233 2005-10-22  Simon Josefsson  <jas@extundo.com>
16234
16235         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
16236         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
16237
16238 2005-10-22  Simon Josefsson  <jas@extundo.com>
16239
16240         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
16241         suggested by Bruno Haible <bruno@clisp.org>.
16242
16243 2005-10-22  Simon Josefsson  <jas@extundo.com>
16244
16245         * lib/crc.h: Include stddef.h, for size_t.
16246
16247 2005-10-22  Simon Josefsson  <jas@extundo.com>
16248
16249         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
16250         arcfour_context struct (simplify test vector testing in GNU
16251         Shishi).
16252
16253 2005-10-21  Simon Josefsson  <jas@extundo.com>
16254
16255         * modules/des, modules/des-tests: New files.
16256
16257         * modules/gc-des, modules/gc-des-tests: New files.
16258
16259         * tests/test-des.c, tests/test-gc-des.c: New file.
16260
16261 2005-10-21  Simon Josefsson  <jas@extundo.com>
16262
16263         * modules/arctwo, modules/arctwo-tests: New files.
16264
16265         * tests/test-arctwo.c: New file.
16266
16267         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
16268
16269         * tests/test-gc-arctwo.c: New file.
16270
16271 2005-10-21  Simon Josefsson  <jas@extundo.com>
16272
16273         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
16274         Bruno Haible <bruno@clisp.org>.
16275
16276         * m4/gc-des.m4: New file.
16277
16278 2005-10-21  Simon Josefsson  <jas@extundo.com>
16279
16280         * m4/arctwo.m4: New file.
16281
16282         * m4/gc-arctwo.m4: New file.
16283
16284 2005-10-21  Simon Josefsson  <jas@extundo.com>
16285
16286         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
16287         block.
16288
16289 2005-10-21  Simon Josefsson  <jas@extundo.com>
16290
16291         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
16292         <bruno@clisp.org>.
16293
16294         * lib/hmac-sha1.c (hmac_sha1): Likewise.
16295
16296         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
16297         Bruno Haible <bruno@clisp.org>.
16298
16299         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
16300         <bruno@clisp.org>.
16301
16302 2005-10-21  Simon Josefsson  <jas@extundo.com>
16303
16304         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
16305
16306 2005-10-21  Simon Josefsson  <jas@extundo.com>
16307
16308         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
16309
16310 2005-10-21  Simon Josefsson  <jas@extundo.com>
16311
16312         * lib/des.h, lib/des.c: New files.
16313
16314         * lib/gc-gnulib.c: Support DES.c
16315
16316 2005-10-21  Simon Josefsson  <jas@extundo.com>
16317
16318         * lib/arctwo.h, lib/arctwo.c: New files.
16319
16320         * lib/gc-gnulib.c: Support ARCTWO.
16321
16322 2005-10-21  Simon Josefsson  <jas@extundo.com>
16323
16324         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
16325         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
16326
16327 2005-10-21  Simon Josefsson  <jas@extundo.com>
16328
16329         * gnulib-tool (func_import, func_create_testdir): Define automake
16330         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
16331         Makefile.am snippet),
16332         suggested by Bruno Haible <bruno@clisp.org>.
16333
16334         * modules/gc (Makefile.am): Use it.
16335
16336 2005-10-21  Bruno Haible  <bruno@clisp.org>
16337
16338         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
16339         patch.
16340
16341 2005-10-19  Simon Josefsson  <jas@extundo.com>
16342
16343         * tests/test-gc-rijndael.c: New file.
16344
16345         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
16346
16347 2005-10-19  Simon Josefsson  <jas@extundo.com>
16348
16349         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
16350         interface too.
16351
16352 2005-10-19  Simon Josefsson  <jas@extundo.com>
16353
16354         * tests/test-gc-arcfour.c: New file.
16355
16356         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
16357
16358 2005-10-19  Simon Josefsson  <jas@extundo.com>
16359
16360         * modules/gc-md4, modules/gc-md4-tests: New file.
16361
16362         * tests/test-gc-md4.c: New file.
16363
16364 2005-10-19  Simon Josefsson  <jas@extundo.com>
16365
16366         * m4/gc-md4.m4: New file.
16367
16368 2005-10-19  Simon Josefsson  <jas@extundo.com>
16369
16370         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
16371         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
16372         <kasal@ucw.cz>.
16373
16374 2005-10-19  Simon Josefsson  <jas@extundo.com>
16375
16376         * m4/gc-arcfour.m4: New file.
16377
16378         * m4/gc-rijndael.m4: New file.
16379
16380 2005-10-19  Simon Josefsson  <jas@extundo.com>
16381
16382         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
16383
16384 2005-10-19  Simon Josefsson  <jas@extundo.com>
16385
16386         * lib/gc-gnulib.c: Support ARCFOUR.
16387
16388 2005-10-19  Simon Josefsson  <jas@extundo.com>
16389
16390         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
16391         support.
16392
16393         * lib/gc.h: Add ECB enum type.
16394
16395         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
16396
16397 2005-10-18  Simon Josefsson  <jas@extundo.com>
16398
16399         * tests/test-md5.c: New file.
16400
16401         * modules/md5-tests: New file.
16402
16403 2005-10-18  Simon Josefsson  <jas@extundo.com>
16404
16405         * tests/test-md4.c: New file.
16406
16407         * modules/md4, modules/md4-tests: New files.
16408
16409 2005-10-18  Simon Josefsson  <jas@extundo.com>
16410
16411         * m4/md4.m4: New file.
16412
16413 2005-10-18  Simon Josefsson  <jas@extundo.com>
16414
16415         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16416
16417 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16418
16419         * gnulib-tool (func_create_testdir): Omit the second check whether
16420         BUILT_SOURCES in nonempty.
16421
16422 2005-10-17  Simon Josefsson  <jas@extundo.com>
16423
16424         * tests/test-rijndael.c: New file.
16425
16426 2005-10-17  Simon Josefsson  <jas@extundo.com>
16427
16428         * modules/sha1: Depend on stdint instead of md5.
16429
16430         * modules/md5: Depend on stdint, remove uint32_t.
16431
16432 2005-10-17  Simon Josefsson  <jas@extundo.com>
16433
16434         * modules/gc-sha1-tests: New file.
16435
16436         * tests/test-gc-sha1.c: New file.
16437
16438 2005-10-17  Simon Josefsson  <jas@extundo.com>
16439
16440         * m4/md5.m4: Remove call to uint32_t.m4.
16441
16442 2005-10-17  Simon Josefsson  <jas@extundo.com>
16443
16444         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16445
16446         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16447         md5.h.
16448
16449         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16450
16451         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16452
16453 2005-10-17  Simon Josefsson  <jas@extundo.com>
16454
16455         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16456
16457 2005-10-17  Simon Josefsson  <jas@extundo.com>
16458
16459         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16460
16461 2005-10-17  Simon Josefsson  <jas@extundo.com>
16462
16463         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16464
16465         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16466
16467 2005-10-17  Bruno Haible  <bruno@clisp.org>
16468
16469         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16470         that it can also be used in a test.
16471
16472 2005-10-16  Bruno Haible  <bruno@clisp.org>
16473
16474         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16475         TESTS_ENVIRONMENT, so that individual tests can augment it.
16476
16477         * gnulib-tool (func_create_testdir): Use an intermediate target for
16478         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16479         macros, like $(ALLOCA_H), which cannot be passed through the command
16480         line.
16481
16482 2005-10-15  Simon Josefsson  <jas@extundo.com>
16483
16484         * modules/rijndael-tests: New file.
16485
16486         * modules/rijndael: New file.
16487
16488 2005-10-15  Simon Josefsson  <jas@extundo.com>
16489
16490         * m4/rijndael.m4: New file.
16491
16492 2005-10-15  Simon Josefsson  <jas@extundo.com>
16493
16494         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16495
16496         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16497
16498 2005-10-14  Simon Josefsson  <jas@extundo.com>
16499
16500         * tests/test-arcfour.c: New file.
16501
16502         * modules/arcfour, modules/arcfour-tests: New files.
16503
16504 2005-10-14  Simon Josefsson  <jas@extundo.com>
16505
16506         * m4/arcfour.m4: New file.
16507
16508 2005-10-14  Simon Josefsson  <jas@extundo.com>
16509
16510         * lib/arcfour.h, lib/arcfour.c: New files.
16511
16512 2005-10-14  Roland McGrath  <roland@redhat.com>
16513
16514         Import from libc.  [BZ #1331]
16515         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16516         macro argument.
16517         Reported by Matej Vela <vela@debian.org>.
16518
16519 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16520
16521         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16522         include <wchar.h>; no longer needed.
16523
16524 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16525
16526         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16527
16528 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16529         and  Ulrich Drepper  <drepper@redhat.com>
16530
16531         Import from libc.
16532         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16533         instead of inline stream orientation test and two separate
16534         function calls.  Pay no attention to USE_IN_LIBIO.
16535
16536 2005-10-13  Simon Josefsson  <jas@extundo.com>
16537
16538         * modules/gc-hmac-md5-tests: New file.
16539
16540         * tests/test-gc-hmac-sha1.c: New file.
16541
16542         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16543
16544         * modules/gc-hmac-md5-tests: New file.
16545
16546         * tests/test-gc-md5.c: New file.
16547
16548         * modules/gc-md5-tests: New file.
16549
16550 2005-10-13  Simon Josefsson  <jas@extundo.com>
16551
16552         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16553         Move memory allocation outside of loop.
16554
16555 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16556
16557         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16558         intermediate directory is in a read-only file system.  Problem
16559         reported by Eric Blake.
16560
16561 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16562
16563         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16564
16565 2005-10-12  Simon Josefsson  <jas@extundo.com>
16566
16567         * tests/test-hmac-sha1.c: New file.
16568
16569         * modules/hmac-sha1-tests: New file.
16570
16571         * modules/hmac-sha1: New file.
16572
16573 2005-10-12  Simon Josefsson  <jas@extundo.com>
16574
16575         * modules/gc-sha1: New file.
16576
16577 2005-10-12  Simon Josefsson  <jas@extundo.com>
16578
16579         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16580
16581         * tests/test-gc-pbkdf2-sha1.c: New file.
16582
16583 2005-10-12  Simon Josefsson  <jas@extundo.com>
16584
16585         * modules/gc-md5, modules/gc-hmac-md5: New files.
16586
16587         * modules/gc (Files): Remove md5, memxor and hmac files.
16588
16589 2005-10-12  Simon Josefsson  <jas@extundo.com>
16590
16591         * m4/gc-pbkdf2-sha1.m4: New file.
16592
16593         * m4/gc-hmac-sha1.m4: New file.
16594
16595         * m4/gc-sha1: New file.
16596
16597         * m4/hmac-sha1.m4: New file.
16598
16599 2005-10-12  Simon Josefsson  <jas@extundo.com>
16600
16601         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
16602
16603         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
16604
16605 2005-10-12  Simon Josefsson  <jas@extundo.com>
16606
16607         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
16608         suggested by Bruno Haible <bruno@clisp.org>.
16609
16610 2005-10-12  Simon Josefsson  <jas@extundo.com>
16611
16612         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
16613
16614 2005-10-12  Simon Josefsson  <jas@extundo.com>
16615
16616         * lib/gc-pbkdf2-sha1.c: New file.
16617
16618         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
16619
16620 2005-10-12  Simon Josefsson  <jas@extundo.com>
16621
16622         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
16623
16624         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
16625
16626 2005-10-12  Simon Josefsson  <jas@extundo.com>
16627
16628         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
16629         GC_USE_HMAC_MD5, respectively.
16630
16631         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
16632         (gc_md5): Fix typo.
16633
16634         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
16635
16636         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
16637
16638         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
16639
16640 2005-10-12  Bruno Haible  <bruno@clisp.org>
16641
16642         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
16643         Reported by Stepan Kasal <kasal@ucw.cz>.
16644
16645 2005-10-11  Simon Josefsson  <jas@extundo.com>
16646
16647         * tests/test-crc.c: New file.
16648
16649         * modules/crc, modules/crc-tests: New files.
16650
16651 2005-10-11  Simon Josefsson  <jas@extundo.com>
16652
16653         * m4/crc.m4: New file.
16654
16655 2005-10-11  Simon Josefsson  <jas@extundo.com>
16656
16657         * lib/gc.h: Add gc_hash and gc_hash_buffer.
16658
16659         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
16660
16661         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
16662
16663 2005-10-11  Simon Josefsson  <jas@extundo.com>
16664
16665         * lib/crc.h, lib/crc.c: New files.
16666
16667         * lib/gc.h (gc_hash_buffer): Add doc.
16668
16669 2005-10-11  Bruno Haible  <bruno@clisp.org>
16670
16671         * modules/c-strcasestr: New file.
16672         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
16673
16674 2005-10-11  Bruno Haible  <bruno@clisp.org>
16675
16676         * modules/c-strcase: New file.
16677         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
16678
16679 2005-10-11  Bruno Haible  <bruno@clisp.org>
16680
16681         * lib/strcasecmp.c: Include limits.h.
16682         (strcasecmp): Avoid integer overflow on exotic platforms.
16683         * lib/strncasecmp.c: Include limits.h.
16684         (strncasecmp): Avoid integer overflow on exotic platforms.
16685         Reported by Paul Eggert.
16686
16687 2005-10-11  Bruno Haible  <bruno@clisp.org>
16688
16689         * lib/c-strcasestr.h: New file, from GNU gettext.
16690         * lib/c-strcasestr.c: New file, from GNU gettext.
16691
16692 2005-10-11  Bruno Haible  <bruno@clisp.org>
16693
16694         * lib/c-strcase.h: New file, from GNU gettext.
16695         * lib/c-strcasecmp.c: New file, from GNU gettext.
16696         * lib/c-strncasecmp.c: New file, from GNU gettext.
16697
16698 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
16699
16700         * modules/mempcpy (License): GPL -> LGPL.
16701         * modules/strchrnul (License): Likewise.
16702         * modules/sysexits (License): Likewise.
16703
16704 2005-10-08  Simon Josefsson  <jas@extundo.com>
16705
16706         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
16707
16708 2005-10-07  Simon Josefsson  <jas@extundo.com>
16709
16710         * m4/memxor.m4: Remove gl_C_RESTRICT call.
16711
16712 2005-10-06  Simon Josefsson  <jas@extundo.com>
16713
16714         * tests/test-hmac-md5.c: New file.
16715
16716         * modules/hmac-md5-tests: New file.
16717
16718         * modules/hmac-md5: New file.
16719
16720 2005-10-06  Simon Josefsson  <jas@extundo.com>
16721
16722         * m4/hmac-md5.m4: New file.
16723
16724         * m4/memxor.m4: Require gl_C_RESTRICT.
16725
16726 2005-10-06  Simon Josefsson  <jas@extundo.com>
16727
16728         * lib/memxor.c (memxor): Avoid casts and warnings.
16729
16730 2005-10-06  Simon Josefsson  <jas@extundo.com>
16731
16732         * lib/hmac-md5.c: New file.
16733
16734         * lib/hmac.h: New file.
16735
16736 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
16737
16738         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
16739         promotes to int, not unsigned int, to catch the AIX 5.3
16740         compiler bug.
16741
16742 2005-10-05  Simon Josefsson  <jas@extundo.com>
16743
16744         * modules/memxor: New file.
16745
16746         * modules/iconv (Files): Move config.rpath to havelib, it is used
16747         there.
16748
16749         * modules/havelib (Files): Add config.rpath.
16750
16751 2005-10-05  Simon Josefsson  <jas@extundo.com>
16752
16753         * m4/memxor.m4: New file.
16754
16755 2005-10-05  Simon Josefsson  <jas@extundo.com>
16756
16757         * lib/memxor.c (memxor): Fix compiler error.
16758
16759         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
16760         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
16761
16762         * lib/memxor.h, lib/memxor.c: New files.
16763
16764         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
16765         we assume all systems have it, suggested by Jim Meyering
16766         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
16767         any systems lack sys/socket.h; mingw32 is known to lack it, but we
16768         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
16769         same reasons.
16770
16771 2005-10-05  Simon Josefsson  <jas@extundo.com>
16772
16773         * config/srclist.txt: Add glibc bug 1423 for md5.h.
16774
16775 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
16776
16777         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
16778         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
16779         needed, since the source code now assumes these .h files.
16780
16781 2005-10-05  Derek Price  <derek@ximbiot.com>
16782
16783         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
16784
16785 2005-10-05  Bruno Haible  <bruno@clisp.org>
16786
16787         * modules/stdint (License): Change to LGPL.
16788
16789 2005-10-04  Simon Josefsson  <jas@extundo.com>
16790
16791         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
16792         D. Baushke" <mdb@gnu.org>.
16793
16794 2005-10-04  Bruno Haible  <bruno@clisp.org>
16795
16796         * lib/verify.h (verify_true): Provide alternative definition for C++.
16797
16798 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
16799
16800         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
16801         (SSIZE_MAX): New macro, if not already defined.
16802         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
16803         than 2 GiB.
16804
16805 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16806
16807         Sync from coreutils.
16808         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
16809         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
16810         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
16811         ULLONG_MAX doesn't work with 2.7.2.1.
16812
16813 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16814
16815         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
16816         From Ben Pfaff.
16817
16818         * modules/exclude (Depends-on): Depend on verify.
16819         * modules/strtoimax (Depends-on): Likewise.
16820         * modules/utimecmp (Depends-on): Likewise.
16821
16822 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16823
16824         * lib/exclude.c: Include verify.h.
16825         (verify): Remove.  All callers changed to use verify.h's version.
16826         * lib/strtoimax.c: Likewise.
16827         * lib/utimecmp.c: Likewis.e
16828
16829         Sync from coreutils.
16830         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
16831         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
16832         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
16833         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
16834         bother returning ENOSYS if settimeofday or stime fails; just let
16835         them return whatever errno they want to return.
16836         * lib/utimens.c: Include unistd.h, for dup2.
16837         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
16838         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
16839
16840 2005-10-02  Jim Meyering  <jim@meyering.net>
16841
16842         Sync from coreutils.
16843         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
16844         from glibc-2.2.5 that fails for read-only files.
16845
16846 2005-10-02  Jim Meyering  <jim@meyering.net>
16847
16848         Sync from coreutils.
16849         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
16850         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
16851         `#if HAVE_CONFIG_H'.
16852         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
16853         Remove AT_FDCWD test.
16854         Do not consume the fd unless successful.
16855         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
16856         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
16857         block, so that we don't even try to compile it if settimeofday is
16858         available.  This works around a compilation failure on OSF1 V5.1,
16859         due to stime requiring a `long int*' while tv_sec is `int'.
16860
16861 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
16862
16863         Sync from coreutils.
16864         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
16865         against `yes', rather than just testing for nonempty.
16866
16867 2005-10-01  Simon Josefsson  <jas@extundo.com>
16868
16869         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
16870         and Darwin.
16871
16872         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
16873         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
16874         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
16875         freeaddrinfo and gai_strerror are declared by the POSIX headers.
16876         Check if struct addrinfo is declared.
16877
16878 2005-10-01  Simon Josefsson  <jas@extundo.com>
16879
16880         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
16881         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
16882         AI_* and EAI_* definitions.  Protect function declarations.
16883
16884 2005-10-01  Jim Meyering  <jim@meyering.net>
16885
16886         Sync from coreutils.
16887
16888         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
16889         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
16890         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
16891         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16892         in the inet and nsl libraries.  Required on Solaris 5.7.
16893
16894 2005-10-01  Jim Meyering  <jim@meyering.net>
16895
16896         Sync from coreutils.
16897         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16898         in the inet and nsl libraries.  Required on Solaris 5.7.
16899
16900 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
16901
16902         * lib/getdelim.c (getdelim): Remove unused variables.
16903
16904 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
16905
16906         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
16907         so that the code works even with ancient cpp.  Portability problem
16908         with GCC 2.7.2.1 reported by Thomas M.Ott.
16909
16910 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
16911
16912         * modules/regex (Depends-on): Add strcase.
16913
16914         * modules/gethostname (Licence): Change from GPL to LGPL, since
16915         gethostname.c is a trivial implementation of a standard library
16916         function.
16917         * modules/poll (License): Change from GPL to LGPL, since it's
16918         derived from LGPL code.
16919
16920 2005-09-27  Jim Meyering  <jim@meyering.net>
16921
16922         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
16923         HAVE_CONFIG_H.
16924
16925         * lib/intprops.h (signed_type_or_expr__): Define.
16926         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
16927         for unsigned types.
16928
16929 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
16930
16931         * lib/verify.h (verify_expr): Remove, replacing with:
16932         (verify_true): New macro that returns true instead of void.
16933         (verify_type__): Remove.
16934         (verify): Use verify_true rather than verify_type__.
16935
16936 2005-09-26  Bruno Haible  <bruno@clisp.org>
16937
16938         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
16939         is necessary.
16940         (lib_SOURCES): Remove mbchar.c.
16941         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
16942         (Files): Add m4/mbrtowc.m4.
16943         * modules/mbiter: Likewise.
16944         * modules/mbuiter: Likewise.
16945
16946 2005-09-26  Bruno Haible  <bruno@clisp.org>
16947
16948         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
16949         compile mbchar.c if they are not both present.
16950         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
16951         * m4/mbiter.m4 (gl_MBITER): Likewise.
16952         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
16953         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
16954         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
16955
16956 2005-09-25  Jim Meyering  <jim@meyering.net>
16957
16958         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
16959         also uses socklen_t.
16960
16961 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
16962
16963         * lib/utimens.c (ENOSYS): Define if not already defined.
16964         (futimens): Support having a null PATH if the file descriptor
16965         is nonnegative.
16966
16967         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
16968         Remove.
16969         (__attribute): Define to empty unless GCC 3.1 or later.
16970         This works around a core dump on OpenBSD 3.4, which has GCC
16971         2.95.3, which dumps core when given __attribute__(()).  It also
16972         simplifies other tests, since we really don't want to bother with
16973         worrying about which ancient version of GCC supported what.
16974         Original problem reported by Yoann Vandoorselaere, with part of
16975         the fix suggested by Derek Price.
16976
16977 2005-09-24  Jim Meyering  <jim@meyering.net>
16978
16979         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
16980         so we can once again use a positive bitfield width of 1 -- now we
16981         don't have to explain why we were using a bitfield width of 2.
16982
16983 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16984
16985         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
16986         and similarly for the other external symbols.  Problem reported
16987         by James Gallager.
16988
16989         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
16990         bug reported by Jim Meyering.
16991
16992         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
16993         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
16994         not needed, since socklen is a prerequisite module.
16995
16996 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16997
16998         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
16999         Problem reported by Eric Blake.
17000         (getaddrinfo): Initialize se so that it's not garbage.
17001         Redo internal storage allocation so that it doesn't make unportable
17002         assumptions about alignment.
17003         Fix a memory leak.
17004
17005         * lib/utimens.c (futimens): Use futimesat if available.
17006         Prefer it to futimes since it doesn't have the futimes bug.
17007
17008         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
17009         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
17010         Instead, declare a function that returns a pointer to an array,
17011         and use verify_type__ to declare the size of the array.
17012         Problem and germ of a solution reported by Bruno Haible.
17013         (verify_type__): Use 2, not 1, for bitfield size, to avoid
17014         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
17015
17016 2005-09-23  Jim Meyering  <jim@meyering.net>
17017
17018         Sync from coreutils.
17019         Correct build failure (socklen_t not defined) on at least
17020         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
17021         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
17022
17023 2005-09-23  Jim Meyering  <jim@meyering.net>
17024
17025         * modules/getaddrinfo (Depends-on): Add socklen.
17026
17027 2005-09-23  Bruno Haible  <bruno@clisp.org>
17028
17029         * tests/test-verify.c: New file.
17030
17031 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17032
17033         Sync from coreutils.
17034
17035         * modules/argmatch (Depends-on): Add verify.
17036         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
17037         unistd-safer.
17038         * modules/save-cwd (Depends-on): Likewise.
17039
17040         * modules/openat (Files): Add lib/openat-die.c.
17041         (Depends-on): Remove error, exitfail.
17042         Add dirname.
17043
17044         * modules/verify: New file.
17045         * MODULES.html.sh (Diagnostics <assert.h>): New section,
17046         with "verify" module.
17047
17048 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17049
17050         Sync from coreutils.
17051
17052         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
17053         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
17054         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
17055         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
17056         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
17057         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
17058         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
17059         Don't bother checking for string.h, stdlib.h, unistd.h.
17060         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
17061         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
17062         module's job.
17063         * m4/jm-macros.m4 (gl_MACROS): Likewise.
17064         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
17065
17066         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
17067         (gl_GETDATE): Use it.
17068
17069         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
17070
17071 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17072
17073         Sync from coreutils.
17074
17075         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
17076         stat-time.h.
17077         * lib/argmatch.h: Include verify.h
17078         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
17079         (ARGMATCH_ASSERT): Remove; unused.
17080         * lib/canonicalize.c: Assume STDC_HEADERS.
17081         * lib/exclude.c: Include "strcase.h".
17082         * lib/regex_internal.h [!defined _LIBC]: Likewise.
17083         * lib/getusershell.c: Include stdio--.h rather than stdio.h
17084         and stdio-safer.h.
17085         (getusershell): Call fopen, not fopen_safer.
17086         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
17087         Do not include unistd-safer.h.
17088         (save_cwd): Don't call fd_safer; no longer needed
17089         now that we include fcntl--.h.
17090
17091         * lib/getdate.y (relative_time): New type.
17092         (RELATIVE_TIME_0): New constant.
17093         (parser_control): Use relative_time instead of doing it ourselves.
17094         (%union): Add new relative_time rel member.
17095         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
17096         Now typeless.
17097         (relunit, relunit_snumber): Now of type rel.
17098         (zone, rel, relunit, get_date): Adjust to above changes.
17099
17100         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
17101         Do not include unistd-safer.h.
17102         (getloadavg): Don't call fd_safer; no longer needed
17103         now that we include fcntl--.h.
17104
17105         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
17106         (make_dir_parents): Treat ENOSYS like EEXIST.
17107
17108         Improve quality of diagnostics on restore_cwd failure.
17109         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
17110         (make_dir_parents): Last arg is now int * (for errno), not bool *.
17111         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
17112         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
17113         each time through the loop.  Do not diagnose restore_cwd failure;
17114         that is the caller's job (and perhaps the caller does not care).
17115
17116         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
17117         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
17118         If the file already exists but is not a directory, don't bother
17119         to try to make its parents.
17120         Close potential file descriptor leak if we can't chdir("/") (!).
17121         Don't always return true if chdir($PWD) fails; return true only
17122         if the requested action was done successfully (except for the
17123         chdir($PWD)).
17124         Don't log final directory unless we actually made it.
17125         Refactor to avoid duplicate code to fix up permissions.
17126         Don't attempt to fix up parent permissions if chdir($PWD) fails.
17127
17128         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
17129         to make it a bit faster and (I hope) clearer.
17130         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
17131         Fix bug in formats like %2N.
17132
17133         * lib/verify.h: New file.
17134
17135 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17136
17137         Sync from coreutils.
17138         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
17139
17140 2005-09-22  Jim Meyering  <jim@meyering.net>
17141
17142         Sync from coreutils.
17143
17144         * m4/lstat.m4 (gl_FUNC_LSTAT):
17145         Use AC_LIBSOURCES to require lstat.c and lstat.h.
17146         Remove obsolete comment.
17147         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
17148         * m4/xstrtod.m4: Likewise.
17149
17150         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
17151
17152 2005-09-22  Jim Meyering  <jim@meyering.net>
17153
17154         Sync from coreutils.
17155
17156         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
17157
17158         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
17159         the .tm_year member, since otherwise gcc-4.0 would now warn about
17160         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
17161
17162         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
17163         order to avoid an unsuppressible warning from gcc on 64-bit systems.
17164
17165         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
17166         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
17167         when run in a time zone for which daylight savings time is in effect
17168         for the starting date.
17169
17170         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
17171         stop us from restricting permissions of just-created absolute-named
17172         directories.
17173         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
17174         to restore initial working directory.
17175         * lib/mkdir-p.c (make_dir_parents): New parameter:
17176         different_working_dir, to tell caller if/when we change the working
17177         directory and are unable to return to the initial one.
17178         * lib/mkdir-p.h (make_dir_parents): Update prototype.
17179         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
17180         `return false'.  This fixes a bug introduced on 2004-07-30.
17181
17182         * lib/openat.c (fdopendir): Be sure to close the supplied
17183         file descriptor before returning.  This makes our replacement
17184         implementation a little closer to Solaris's, where fdopendir
17185         ties the file descriptor to the returned DIR* pointer.
17186         * lib/openat.c (unlinkat): New function.
17187         * lib/openat.h (unlinkat): Add prototype.
17188         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
17189         (openat_restore_fail): Rename from openat_restore_die.
17190         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
17191
17192         Provide an alternative to exiting immediately upon save_cwd or
17193         restore_cwd failure.  Now, an application can arrange e.g.,
17194         to perform a longjump in that case.
17195         * lib/openat.c: Include dirname.h.
17196         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
17197         (rpl_openat, fdopendir, fstatat): Call openat_save_die
17198         and openat_restore_die rather than calling error directly.
17199         Don't include "error.h" or "exitfail.h"; they're no longer needed.
17200
17201         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
17202         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
17203         define.
17204
17205         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
17206         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
17207                             int utc, int nanoseconds);
17208         Background:
17209         date should not have to allocate a megabyte of virtual memory to
17210         handle a format argument like +%1048575T.  When implemented with
17211         strftime, it must allocate such a buffer, use strftime to fill it
17212         in, print it, then free it.
17213         With fprintftime, it simply prints everything and exits.
17214         With no need for memory allocation, that's one fewer way to fail.
17215         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
17216         optional field width, not before, so we accept %9:z, not %:9z.
17217         (my_strftime): Be sure to use L_('x') for literals.
17218
17219         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
17220         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
17221         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
17222         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
17223         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
17224         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
17225         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
17226         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
17227         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
17228         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
17229         * lib/xgethostname.c, lib/xreadlink.c:
17230         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
17231
17232         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
17233         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
17234         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
17235         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17236         and don't include <sys/file.h>).
17237
17238 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
17239
17240         Sync from coreutils.
17241
17242         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
17243         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
17244         [!LDAV_DONE]: Avoid unused variable warning.
17245
17246 2005-09-21  Bruno Haible  <bruno@clisp.org>
17247
17248         * lib/unicodeio.h (unicode_to_mb): New declaration.
17249
17250 2005-09-20  Derek Price  <derek@ximbiot.com>
17251
17252         * lib/getaddrinfo.c: Don't include <netdb.h> included from
17253         getaddrinfo.h.
17254
17255 2005-09-20  Bruno Haible  <bruno@clisp.org>
17256
17257         * gnulib-tool: Remove trailing slashes from the values specified for
17258         --source-base, --m4-base, --tests-base, --aux-dir.
17259         Suggested by Simon Josefsson <jas@extundo.com>.
17260
17261 2005-09-20  Bruno Haible  <bruno@clisp.org>
17262
17263         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
17264         func_modules_to_filelist, func_import, func_create_testdir): Make all
17265         sorting results locale-independent, so that gnulib-cache.m4 doesn't
17266         change when gnulib-tool is invoked in a different locale.
17267
17268 2005-09-19  Simon Josefsson  <jas@extundo.com>
17269
17270         * m4/socklen.m4: Fix typo.
17271
17272 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
17273
17274         Use a consistent style for including <config.h>.
17275         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
17276         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
17277         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
17278         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
17279         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
17280         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
17281         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
17282         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
17283         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
17284         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
17285         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
17286         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
17287         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
17288         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
17289         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
17290         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
17291         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
17292         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
17293         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
17294         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
17295         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
17296         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
17297         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
17298         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
17299         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
17300         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
17301         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
17302         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
17303         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
17304         lib/xstrtoumax.c, lib/yesno.c:
17305         Standardize inclusion of config.h.
17306         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
17307         lib/inttostr.h:  Removed inclusion of config.h from header files.
17308         * lib/inttostr.c:  Adjusted in-tree users.
17309         * lib/timespec.h: Remove superfluous warning to include config.h.
17310         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
17311         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
17312         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
17313         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
17314         config.h with HAVE_CONFIG_H.
17315
17316 2005-09-19  Jim Meyering  <jim@meyering.net>
17317
17318         * modules/pathmax (License): Change to LGPL.
17319
17320 2005-09-19  Derek Price  <derek@ximbiot.com>
17321
17322         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
17323
17324 2005-09-19  Bruno Haible  <bruno@clisp.org>
17325
17326         * gnulib-tool (import): Provide default for --tests-base.
17327
17328 2005-09-19  Bruno Haible  <bruno@clisp.org>
17329
17330         * doc/quote.texi: New file, extracted from gnulib.texi.
17331         * doc/ctime.texi: New file, extracted from gnulib.texi.
17332         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
17333         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
17334         * doc/gnulib.texi: Include them.
17335
17336 2005-09-18  Bruno Haible  <bruno@clisp.org>
17337
17338         Portability fix.
17339         * gnulib-tool (func_readlink): New function.
17340         (func_ln_if_changed): Use it.
17341
17342 2005-09-18  Bruno Haible  <bruno@clisp.org>
17343
17344         * gnulib-tool: Support --with-tests also with --import.
17345         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
17346         (func_import): Use variables $testsbase and $inctests. Emit a
17347         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
17348         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
17349         SUBDIRS += $testsdir.
17350         (func_create_testdir): Update.
17351
17352 2005-09-18  Bruno Haible  <bruno@clisp.org>
17353
17354         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
17355         instead of $dry_run.
17356         (func_cp_if_changed, func_mv_if_changed): Remove functions.
17357         (func_ln_if_changed): Don't handle dry-run here.
17358         (func_import): In dry-run mode, detect more precisely which actions
17359         would be performed, and don't use "...ing" verbs.
17360
17361 2005-09-18  Bruno Haible  <bruno@clisp.org>
17362
17363         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
17364         (func_import): Use join on two temporary files instead of three nested
17365         loops, in order to determine which files are new or old.
17366
17367 2005-09-18  Bruno Haible  <bruno@clisp.org>
17368
17369         * gnulib-tool (func_import): Comment out code that spits out the
17370         new files with --dry-run.
17371
17372 2005-09-18  Bruno Haible  <bruno@clisp.org>
17373
17374         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
17375
17376 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17377
17378         * lib/stat-time.h: New file.
17379         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
17380         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
17381         in a different way.
17382         (timespec_cmp): New function.
17383         * lib/utimecmp.c: Include stat-time.h.
17384         (SYSCALL_RESOLUTION): Depend on whether various struct stat
17385         members exist, not on the obsolescent ST_MTIM_NSEC.
17386         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
17387
17388 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17389
17390         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
17391
17392 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17393
17394         * MODULES.html.sh (File system functions): Add stat-time.
17395         * modules/stat-time: New file.
17396         * modules/timespec (Files): Remove m4/st_mtim.m4; this
17397         is now done in a different way, by the stat-time module.
17398         * modules/utimecmp (Depends-on): Add stat-time.
17399
17400 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
17401
17402         * m4/st_mtim.m4: Remove.  Superseded by...
17403         * m4/stat-time.m4: New file.
17404         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17405         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17406
17407 2005-09-15  Derek Price  <derek@ximbiot.com>
17408
17409         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17410
17411 2005-09-15  Derek Price  <derek@ximbiot.com>
17412
17413         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17414         * lib/regex_internal.c: Ditto, using this...
17415         (__GNUC_PREREQ): ...new macro.
17416         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17417         using...
17418         (__GNUC_PREREQ): ...this new macro.
17419
17420         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17421
17422 2005-09-15  Derek Price  <derek@ximbiot.com>
17423             Paul Eggert  <eggert@cs.ucla.edu>
17424
17425         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17426         changes, consolidating in...
17427         * lib/regex_internal.h: ...this file.
17428
17429 2005-09-13  Jim Meyering  <jim@meyering.net>
17430
17431         * lib/canon-host.c: Filter through gnu indent and reword comments
17432         slightly.
17433         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17434
17435 2005-09-13  Derek Price  <derek@ximbiot.com>
17436
17437         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17438         failure.
17439         Reported by Jim Meyering  <jim@meyering.net>.
17440
17441 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17442
17443         * lib/base64.c: Typo.
17444         (base64_encode): Put b64str in initialized data section.
17445
17446 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17447
17448         Merge glibc and coreutils changes into gnulib, plus a few
17449         extra fixes.
17450         * lib/md5.c: Use #error rather than a string.
17451         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17452         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17453         (__attribute__): Define to empty for non recent-GCC.
17454         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17455         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17456         Renamed from their non-__ counterparts, with new macros replacing
17457         them if not _LIBC.  Add __THROW attribute.
17458         (rol): Remove.
17459         (struct md5_ctx): Align buffer if using GCC.
17460         * lib/sha1.h (struct sha1_ctx): Likewise.
17461         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17462         The old name was backwards.
17463         (NOTSWAP): Remove; not used.
17464         (rol): New macro, moved here from md5.h.
17465         (sha1_process_block): Remove a FIXME that doesn't make sense.
17466
17467 2005-09-12  Derek Price  <derek@ximbiot.com>
17468
17469         Return usable errors from canon-host.
17470         * lib/canon-host.h: New file.
17471         * lib/canon-host.c (canon_host): Wrap...
17472         (canon_host_r): ...this new function, which now relies exclusively on
17473         getaddrinfo.
17474         (ch_strerror): New function.
17475         (last_cherror): New global.
17476         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17477         interface.
17478         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17479         void *.
17480         (freeaddrinfo): Free ai->ai_canonname when set.
17481
17482 2005-09-12  Derek Price  <derek@ximbiot.com>
17483
17484         Make canon-host require getaddrinfo.
17485         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17486         AC_LIBSOURCE canon-host.h.  Call...
17487         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17488         gl_GETADDRINFO.
17489         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17490
17491 2005-09-12  Derek Price  <derek@ximbiot.com>
17492
17493         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17494         LGPL.
17495         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17496
17497 2005-09-12  Derek Price  <derek@ximbiot.com>
17498
17499         * lib/gai_strerror.c: Include config.h when available.  Include
17500         getaddrinfo.h before other headers to test interface.
17501         Reported by Larry Jones <lawrence.jones@ugs.com>.
17502
17503 2005-09-12  Derek Price  <derek@ximbiot.com>
17504             Paul Eggert  <eggert@cs.ucla.edu>
17505
17506         * modules/glob (Files): Add glob-libc.h.
17507
17508 2005-09-12  Derek Price  <derek@ximbiot.com>
17509             Paul Eggert  <eggert@cs.ucla.edu>
17510
17511         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17512         glob_.h, glob-libc.h.
17513         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17514
17515 2005-09-12  Derek Price  <derek@ximbiot.com>
17516             Paul Eggert  <eggert@cs.ucla.edu>
17517
17518         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17519         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17520         protecting things that should be done only in gnulib contexts.
17521         * lib/glob_.h: New file, containing only the glob things needed for
17522         gnulib.
17523         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17524         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17525         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17526         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17527         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17528         and to respect the namespace rules better.
17529
17530 2005-09-08  Simon Josefsson  <jas@extundo.com>
17531
17532         * modules/socklen: New file.
17533
17534 2005-09-08  Simon Josefsson  <jas@extundo.com>
17535
17536         * m4/socklen.m4: New file.
17537
17538 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17539
17540         * modules/utimens (Files): Add m4/utimbuf.m4, since
17541         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17542         Reported by Sergey Poznyakoff.
17543
17544 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17545
17546         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17547         definitions, since that's the preferred style in glibc.
17548         Fix a minor spacing issue, and update copyright notice to match
17549         glibc's.
17550
17551 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17552
17553         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17554
17555 2005-09-06  Simon Josefsson  <jas@extundo.com>
17556
17557         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17558         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17559
17560 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17561
17562         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17563         warning.
17564
17565 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17566
17567         * config/srclist.txt: Add glibc bug 1302.
17568
17569 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17570
17571         Change bitset word type from unsigned int to unsigned long int,
17572         as this has better performance on typical 64-bit hosts.
17573         Port bitset code to hosts with unusual word sizes.
17574         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17575         (build_collating_symbol):
17576         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17577         argument is a bitset.  This is merely a style issue, but it makes
17578         it clearer that an entire array is expected.
17579         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17580         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17581         Port to the case where bitset_word is not the same as unsigned int.
17582         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17583         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17584         Likewise.
17585         * lib/regexec.c (check_dst_limits_calc_pos_1,
17586         check_subexp_matching_top):
17587         (build_trtable, group_nodes_into_DFAstates):
17588         Likewise.
17589         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
17590         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
17591         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
17592         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
17593         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
17594         * lib/regcomp.c (optimize_subexps, lower_subexp):
17595         Work even if bitset_word has holes in its bitwise representation.
17596         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
17597         * lib/regexec.c (check_dst_limits_calc_pos_1,
17598         check_subexp_matching_top):
17599         Likewise.
17600         * lib/regex_internal.c (re_string_reconstruct):
17601         Don't assume UCHAR_MAX == 255.
17602         * lib/regex_internal.h (bitset_set_all): Likewise.
17603         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
17604         All uses changed.
17605         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
17606         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
17607         All uses changed.
17608         (BITSET_WORD_MAX): New macro.
17609         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
17610         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
17611         (bitset_empty, bitset_copy):
17612         Prefer sizeof (bitset) to multiplying it out ourselves.
17613         (bitset_not_merge): Remove; unused.
17614         (bitset_contain): Return bool, not unsigned int with one bit on.
17615         All callers changed.
17616         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
17617         alignment than re_node_set; do this by defining a new internal
17618         type struct dests_alloc and using it to allocate memory.
17619
17620 2005-09-05  Bruno Haible  <bruno@clisp.org>
17621
17622         * gnulib-tool (func_import): Fix comparison in handling of symbolic
17623         links.
17624
17625 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
17626
17627         * modules/size_max (Makefile.am): Add size_max.h
17628
17629 2005-09-04  Derek Price  <derek@ximbiot.com>
17630
17631         * gnulib-tool (func_import): Fix reversed $symbolic logic.
17632
17633 2005-09-03  Simon Josefsson  <jas@extundo.com>
17634
17635         * gnulib-tool: Fix typo.
17636
17637 2005-09-03  Simon Josefsson  <jas@extundo.com>
17638
17639         * config/srclist.txt: Add glibc bug 1293.
17640
17641 2005-09-03  Derek Price  <derek@ximbiot.com>
17642
17643         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
17644         From Larry Jones <lawrence.jones@ugs.com>.
17645
17646 2005-09-02  Simon Josefsson  <jas@extundo.com>
17647
17648         * modules/socklen: New file.
17649
17650 2005-09-02  Simon Josefsson  <jas@extundo.com>
17651
17652         * modules/havelib: New module.
17653
17654         * modules/gettext, modules/iconv, modules/lock, modules/readline:
17655         Use havelib.
17656
17657 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17658
17659         Check for arithmetic overflow when calculating sizes, to prevent
17660         some buffer-overflow issues.  These patches are conservative, in the
17661         sense that when I couldn't determine whether an overflow was possible,
17662         I inserted a run-time check.
17663         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
17664         macros.
17665         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
17666         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
17667         (re_xnrealloc, re_x2nrealloc): New inline functions.
17668         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
17669         parse_bracket_exp):
17670         (build_equiv_class, build_charclass): Check for arithmetic overflow
17671         in size expression calculations.
17672         * lib/regex_internal.c (re_string_realloc_buffers):
17673         (build_wcs_upper_buffer, re_node_set_add_intersect):
17674         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
17675         (re_dfa_add_node, register_state): Likewise.
17676         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
17677         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
17678         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
17679         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
17680
17681 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17682
17683         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
17684         m4/ulonglong.m4.  Problem reported by Martin Lambers.
17685
17686 2005-09-02  Bruno Haible  <bruno@clisp.org>
17687
17688         Support for lib vs. lib64 distinction on biarch platforms.
17689         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
17690         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
17691         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
17692
17693 2005-09-02  Bruno Haible  <bruno@clisp.org>
17694
17695         * gnulib-tool (import): In the other first-use case, provide defaults
17696         as well.
17697
17698 2005-09-02  Bruno Haible  <bruno@clisp.org>
17699
17700         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
17701         patches not yet found in the latest gettext release.
17702
17703 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17704
17705         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
17706         to avoid a collision with bits/local_lim.h in glibc.
17707         All uses changed.  Problem reported by Dmitry V. Levin in
17708         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
17709
17710         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
17711         bugs in int versus size_t comparisons.
17712         (re_string_context_at): Fix bug where the code assumed that
17713         Idx is signed.
17714
17715         Use bool where appropriate.
17716         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
17717         All callers changed.
17718         (calc_eclosure_iter): Likewise, for ROOT arg.
17719         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
17720         (build_charclass_op): Likewise, for NON_MATCH arg.
17721         * lib/regex_internal.c (re_string_allocate, re_string_construct):
17722         (re_string_construct_common): Likewise, for ICASE arg.
17723         * lib/regexec.c (re_search_2_stub, re_search_stub):
17724         Likewise, for RET_LEN arg.
17725         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
17726         (set_regs): Likewise, for FL_BACKTRACK arg.
17727         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
17728         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
17729         (calc_eclosure_iter, parse_bracket_exp):
17730         Use bool for internal variables that are booleans.
17731         * lib/regexec.c (re_search_internal, check_matching,
17732         proceed_next_node):
17733         (set_regs, build_sifted_states, sift_states_bkref):
17734         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
17735         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
17736         (find_collation_sequence_value):
17737         Likewise.
17738         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
17739         (re_node_set_compare):
17740         Return bool, not int. All callers changed.
17741         * lib/regexec.c (check_halt_node_context, check_dst_limits):
17742         (build_trtable, check_node_accept): Likewise.
17743         * lib/regex_internal.h: Include stdbool.h.
17744
17745         Fix bugs uncovered when converting to bool.
17746         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
17747         failure instead of charging ahead blindly.
17748         * lib/regex_internal.c (register_state): Likewise.
17749         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
17750         for freeing internal storage.
17751         (group_nodes_into_DFA_states): Use unsigned int, not int, for
17752         bitset pieces used as boolean, to avoid undefined behavior
17753         on hosts that do int overflow checking.
17754
17755 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17756
17757         * config/srclist.txt: Add glibc bugs 1285-1287.
17758
17759 2005-09-01  Jim Meyering  <jim@meyering.net>
17760
17761         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
17762         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
17763         Require gl_STAT_MACROS, too.
17764
17765 2005-09-01  Bruno Haible  <bruno@clisp.org>
17766
17767         * gnulib-tool (import): In the first-use case, provide defaults.
17768
17769 2005-09-01  Bruno Haible  <bruno@clisp.org>
17770
17771         * gnulib-tool (func_import): Remove the .tmp files.
17772
17773 2005-09-01  Bruno Haible  <bruno@clisp.org>
17774
17775         * gnulib-tool (func_import): Fix handling of symbolic links.
17776
17777 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17778
17779         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
17780         old glibc regex code mishandles strings longer than 2**31 bytes.
17781         This patch fixes this when the regex code is used in gnulib
17782         (i.e., outside glibc).
17783
17784         This patch should not affect the use of the regex code inside
17785         glibc.  No doubt this problem also needs to be handled for glibc
17786         as well, but the result will be an incompatible change to the
17787         glibc ABI, and the old ABI will have to be supported too.  That
17788         can be the the subject for another patch.
17789
17790         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
17791         governing whether the rest of this patch is active.  By default,
17792         the macro is disabled and the patch has no effect.
17793         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
17794         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
17795         (struct re_pattern_buffer, re_search, re_search_2, re_match):
17796         (re_match_2, re_set_registers): Use the new types.
17797         * lib/regex_internal.h (Idx, re_hashval_t): New types.
17798         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
17799         New macros.
17800         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
17801         (re_string_context_at, bin_tree_t, re_dfastate_t):
17802         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
17803         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
17804         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
17805         (re_string_char_size_at, re_string_wchar_at):
17806         (re_string_elem_size_at):
17807         Use the new types and macros to port to 64-bit hosts.
17808         Use unsigned types for internal values, so that the code
17809         mostly works even for arrays larger than SSIZE_MAX.
17810         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
17811         (search_duplicated_node, calc_eclosure_iter, fetch_number):
17812         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
17813         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
17814         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
17815         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
17816         (calc_inveclosure, parse_dup_op, build_range_exp):
17817         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
17818         (fetch_number, create_token_tree, mark_opt_subexp):
17819         Likewise.
17820         * lib/regex_internal.c (re_string_construct_common,
17821         create_ci_newstate):
17822         (create_cd_newstate, re_string_allocate, re_string_construct):
17823         (re_string_realloc_buffers, build_wcs_upper_buffer):
17824         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
17825         (re_string_reconstruct, re_string_peek_byte_case):
17826         (re_string_fetch_byte_case, re_string_context_at):
17827         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
17828         (re_node_set_init_copy, re_node_set_add_intersect):
17829         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17830         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17831         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
17832         (re_acquire_state, re_acquire_state_context, register_state):
17833         Likewise.
17834         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
17835         search_cur_bkref_entry):
17836         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
17837         (re_search_internal, re_search_2_stub, re_search_stub)
17838         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
17839         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
17840         (update_cur_sifted_state, check_dst_limits):
17841         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17842         (check_subexp_limits, sift_states_bkref, merge_state_array):
17843         (check_subexp_matching_top, get_subexp, get_subexp_sub):
17844         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
17845         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
17846         (expand_bkref_cache, check_node_accept_bytes):
17847         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
17848         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
17849         (acquire_init_state_context, check_halt_node_context):
17850         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
17851         (sift_states_backward, clean_state_log_if_needed):
17852         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
17853         (find_recover_state, transit_state_sb, transit_state_mb):
17854         (transit_state_bkref, build_trtable, match_ctx_clean):
17855         Likewise.
17856         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
17857         to work around an assumption that REG_MISSING is negative.
17858
17859         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
17860         (seek_collating_symbol_entry) [defined _LIBC]:
17861         (lookup_collation_sequence_value) [defined _LIBC]:
17862         (build_range_exp, build_collating_symbol) [defined _LIBC]:
17863         Use prototypes rather than old-style function definitions.
17864         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
17865         (transit_state_sb) [0]:
17866         (find_collation_sequence_value) [defined _LIBC]: Likewise.
17867
17868         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
17869         rm_eo.
17870
17871         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
17872         (optimize_subexps, lower_subexp):
17873         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
17874         since the signed shift might overflow.  Use 1u<<31 instead.
17875         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17876         Likewise.
17877         * lib/regexec.c (check_dst_limits_calc_pos_1,
17878         check_subexp_matching_top): Likewise.
17879
17880         * lib/regcomp.c (optimize_subexps, lower_subexp):
17881         Use CHAR_BIT rather than 8, for clarity.
17882         * lib/regexec.c (check_dst_limits_calc_pos_1):
17883         (check_subexp_matching_top): Likewise.
17884         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
17885         have to worry about portability issues when shifting it left.
17886         Remove no-longer-needed test for table_size > 0.
17887         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
17888         in a word, as the resulting behavior is undefined.
17889         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
17890         in one case, a <= should have been an <, and in another case the
17891         whole test was missing.
17892         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
17893         the standard name CHAR_BIT.
17894         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
17895         this is not true on one's complement and signed-magnitude hosts.
17896
17897         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
17898         next_last_offset.
17899         (struct re_dfa_t): Remove unused member states_alloc.
17900         * lib/regcomp.c (init_dfa): Don't initialize unused members.
17901
17902 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17903
17904         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
17905         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
17906         and large-file glibc and in 32-bit large-file Solaris.
17907
17908 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17909
17910         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
17911         lengths fit in regoff_t; this isn't true if regoff_t is the same
17912         width as size_t.
17913         * lib/regex.c (re_search_internal): 5th arg is LAST_START
17914         (= START + RANGE) instead of RANGE.  This avoids overflow
17915         problems when regoff_t is the same width as size_t.
17916         All callers changed.
17917         (re_search_2_stub): Check for overflow when adding the
17918         sizes of the two strings.
17919         (re_search_stub): Check for overflow when adding START
17920         to RANGE; if it occurs, substitute the extreme value.
17921
17922 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17923
17924         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
17925
17926 2005-08-31  Jim Meyering  <jim@meyering.net>
17927
17928         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
17929         a pointer-to-const.
17930         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
17931         (register_state): Likewise.
17932         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
17933         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17934         (group_nodes_into_DFAstates): Likewise.
17935
17936 2005-08-31  Jim Meyering  <jim@meyering.net>
17937
17938         * check-module: Add a FIXME comment.
17939
17940 2005-08-31  Eric Blake  <ebb9@byu.net>
17941
17942         * modules/unistd-safer (Files): Add unistd--.h.
17943         * modules/stdio-safer (Files): Add stdio--.h.
17944
17945 2005-08-31  Derek Price  <derek@ximbiot.com>
17946
17947         * lib/getdelim.c (getdelim): Return EOF on EOF.
17948         Reported by Larry Jones <lawrence.jones@ugs.com>.
17949
17950 2005-08-31  Bruno Haible  <bruno@clisp.org>
17951
17952         Avoid unnecessary diffs in the generated lib/Makefile.am.
17953         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
17954         the generated files.
17955         (func_import): Don't set cmd.
17956
17957 2005-08-31  Bruno Haible  <bruno@clisp.org>
17958
17959         * lib/strstr.c: Include <stddef.h>, for NULL.
17960         * lib/strcasestr.c: Likewise.
17961         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17962
17963 2005-08-31  Bruno Haible  <bruno@clisp.org>
17964
17965         * gnulib-tool: New option --macro-prefix.
17966         (func_import): Use macro_prefix.
17967         (import): Handle option --macro-prefix.
17968
17969 2005-08-31  Bruno Haible  <bruno@clisp.org>
17970
17971         * gnulib-tool (import): Rename most ac_* variables to cached_*.
17972         Also use new variables cached_lgpl, cached_libtool.
17973
17974 2005-08-31  Bruno Haible  <bruno@clisp.org>
17975
17976         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
17977         always instantiating them.
17978
17979 2005-08-31  Bruno Haible  <bruno@clisp.org>
17980
17981         * gnulib-tool (func_import): Read the previous cached settings
17982         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
17983         earlier added by gnulib but are now dropped. Warn when a gnulib file
17984         overwrites a non-gnulib file.
17985
17986 2005-08-31  Bruno Haible  <bruno@clisp.org>
17987
17988         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
17989         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
17990         projects that don't keep autogenerated files in CVS. Put into
17991         actioncmd only the specified modules, not the transitive closure.
17992
17993 2005-08-31  Bruno Haible  <bruno@clisp.org>
17994
17995         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
17996         Create directories that shall be filled.
17997         (import): Don't look for gl_* macros in configure.ac. Recurse across
17998         all directories containing a gnulib-cache.m4 files, if meaningful.
17999
18000 2005-08-31  Bruno Haible  <bruno@clisp.org>
18001
18002         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
18003         (import): Set seen_libtool when we see gl_LIBTOOL.
18004
18005 2005-08-31  Bruno Haible  <bruno@clisp.org>
18006
18007         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
18008         declaration macro definitions from generated gnulib.m4.
18009
18010 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
18011
18012         * lib/iconvme.h: Add prototype for iconv_alloc.
18013
18014 2005-08-29  Simon Josefsson  <jas@extundo.com>
18015
18016         * lib/iconvme.c: Fix errno.
18017
18018 2005-08-29  Bruno Haible  <bruno@clisp.org>
18019
18020         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
18021         that it works when the directory contains spaces.
18022
18023 2005-08-29  Bruno Haible  <bruno@clisp.org>
18024
18025         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
18026
18027 2005-08-29  Bruno Haible  <bruno@clisp.org>
18028
18029         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
18030         Emit more advice.
18031
18032 2005-08-29  Bruno Haible  <bruno@clisp.org>
18033         and Stepan Kasal  <kasal@ucw.cz>
18034
18035         * check-module: If more parameters are given, check each of them
18036         separately; add more exceptions, as noted by Jim Meyering.
18037         (check_module): New procedure.
18038         (%exempt_header): Now contains all exceptions.
18039
18040 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
18041
18042         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
18043
18044 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18045
18046         * lib/iconvme.c: Split iconv_string into iconv_alloc.
18047
18048 2005-08-28  Bruno Haible  <bruno@clisp.org>
18049
18050         * m4/gnulib-tool.m4: New file.
18051
18052 2005-08-27  Jim Meyering  <jim@meyering.net>
18053
18054         * modules/unistd-safer (Files): Add pipe-safer.c.
18055         * modules/fcntl-safer (Files): Add creat-safer.c.
18056
18057 2005-08-27  Jim Meyering  <jim@meyering.net>
18058
18059         * m4/stdlib-safer.m4: New file.  From coreutils.
18060         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
18061         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
18062         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
18063         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
18064         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
18065
18066 2005-08-27  Jim Meyering  <jim@meyering.net>
18067
18068         * lib/fopen-safer.c: Merge minor changes from coreutils.
18069         * lib/dup-safer.c: Likewise.
18070         * lib/fd-safer.c: Likewise.
18071
18072         Merge from coreutils.
18073         * lib/stdio--.h: New file.
18074         * lib/stdlib--.h: New file.
18075         * lib/mkstemp-safer.c: New file.
18076
18077         GNU tar needs these.
18078         * lib/pipe-safer.c: New file.
18079         * lib/creat-safer.c: New file.
18080         * lib/fcntl--.h (creat): Define to creat_safer.
18081         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
18082         * lib/unistd--.h (pipe): Define to pipe_safer.
18083         * lib/unistd-safer.h: Declare pipe_safer.
18084
18085 2005-08-26  Simon Josefsson  <jas@extundo.com>
18086
18087         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
18088         Haible <bruno@clisp.org>.
18089
18090 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
18091
18092         * lib/regex_internal.h: Remove all references to
18093         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
18094         or better.
18095         (bitset_not, bitset_merge, bitset_not_merge):
18096         (bitset_mask, re_string_allocate, re_string_construct):
18097         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
18098         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
18099         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
18100         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
18101         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18102         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18103         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
18104         (re_acquire_state_context):
18105         Remove unnecessary forward decls.
18106         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
18107         Put __attribute at function definition,
18108         now that the function decl has been removed.
18109         * lib/regex_internal.c (re_string_peek_byte_case):
18110         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
18111         Likewise.
18112
18113 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
18114
18115         * m4/regex.m4: Add AC_PREREQ(2.50).
18116         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
18117
18118 2005-08-25  Simon Josefsson  <jas@extundo.com>
18119
18120         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
18121         __fsetlocking.
18122
18123 2005-08-25  Simon Josefsson  <jas@extundo.com>
18124
18125         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
18126         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
18127         GLIBC specific code.
18128
18129 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18130
18131         Make regex safe for g++.  This fixes one real bug (an "err"
18132         that should have been "*err").  g++ problem reported by
18133         Sam Steingold.
18134         * lib/regex_internal.h (re_calloc): New macro, consistent with
18135         re_malloc etc.  All callers of calloc changed to use re_calloc.
18136         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
18137         not int.  All callers changed.
18138         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
18139         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
18140         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
18141         (find_recover_state): Change "err" to "*err"; this fixes what
18142         appears to be a real bug.
18143         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
18144         versus int.
18145
18146 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18147
18148         * modules/regex (Depends-on): Add malloc, since the code
18149         assumes that !malloc(0) means failure.
18150
18151 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18152
18153         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
18154
18155         alloca modernization/simplification for regex.
18156         * lib/regex.c: Remove portability cruft for alloca.  This no longer
18157         needs to be at the start of the file, and can be moved into
18158         regex_internal.h and simplified.
18159         * lib/regex_internal.h: Include <alloca.h>.
18160         (__libc_use_alloca) [!defined _LIBC]: New macro.
18161         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
18162         now works outside glibc.
18163
18164 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18165
18166         * config/srclist.txt: Add glibc bugs 1241, 1245.
18167
18168 2005-08-25  Jim Meyering  <jim@meyering.net>
18169
18170         * lib/open-safer.c: Include <config.h>.
18171         Otherwise, we'd lose LARGEFILE support in any file using
18172         e.g. "fcntl--.h"
18173
18174 2005-08-25  Bruno Haible  <bruno@clisp.org>
18175
18176         * m4/minmax.m4: Require autoconf 2.52.
18177         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
18178         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
18179         alternatives of translit over the alphabet.
18180         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
18181
18182 2005-08-24  Simon Josefsson  <jas@extundo.com>
18183
18184         * tests/test-getpass.c: New file.
18185
18186 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18187
18188         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
18189         for GNU regex features.
18190
18191 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18192
18193         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
18194         * lib/regex.h (regerror): Likewise.
18195
18196         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
18197         requires this.  (The code never needed it.)
18198
18199         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
18200         All uses of recently-renamed identifiers changed to use the new,
18201         POSIX-compliant names.  The code will build and run just fine
18202         without these changes, but it's better to eat our own dog food
18203         and use the standard-conforming names.
18204
18205         * lib/regex.h: Fix a multitude of POSIX name space violations.
18206         These changes have an effect only for programs that define
18207         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
18208         do not change anything for programs compiled in the normal way.
18209         Also, there is no effect on the ABI.
18210
18211         (_REGEX_SOURCE): New macro.
18212         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
18213         defined and _GNU_SOURCE is not; this fixes a name space violation.
18214
18215         Rename the following macros to obey POSIX requirements.
18216         The old names are still visible as macros if _REGEX_SOURCE is defined.
18217         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
18218         RE_BACKSLASH_ESCAPE_IN_LISTS.
18219         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
18220         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
18221         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
18222         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
18223         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
18224         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
18225         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
18226         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
18227         (REG_INTERVALS): renamed from RE_INTERVALS.
18228         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
18229         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
18230         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
18231         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
18232         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
18233         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
18234         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
18235         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
18236         RE_UNMATCHED_RIGHT_PAREN_ORD.
18237         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
18238         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
18239         (REG_DEBUG): renamed from RE_DEBUG.
18240         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
18241         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
18242         unusual, since we can't clash with the POSIX REG_ICASE.
18243         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
18244         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
18245         (REG_NO_SUB): renamed from RE_NO_SUB.
18246         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
18247         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
18248         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
18249         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
18250         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
18251         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
18252         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
18253         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
18254         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
18255         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
18256         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
18257         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
18258         RE_SYNTAX_POSIX_MINIMAL_BASIC.
18259         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
18260         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
18261         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
18262         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
18263         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
18264         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
18265         (REG_FIXED): Renamed from REGS_FIXED.
18266         (REG_NREGS): Renamed from RE_NREGS.
18267
18268         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
18269         of other REG_* macros, since POSIX says the user is allowed to
18270         #undef these macros selectively.
18271
18272         (reg_errcode_t): Update comment stating what other tables need
18273         to be consistent.
18274
18275         Rename the following enum values to obey POSIX requirements.
18276         The old names are still visible as macros.
18277         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
18278         is not defined, since GNU is supposed to be a superset of POSIX as
18279         much as possible, and since we want reg_errcode_t to be a signed
18280         type for implementation consistency.
18281         (_REG_NOERROR): Renamed from REG_NOERROR.
18282         (_REG_NOMATCH): Renamed from REG_NOMATCH.
18283         (_REG_BADPAT): Renamed from REG_BADPAT.
18284         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
18285         (_REG_ECTYPE): Renamed from REG_ECTYPE.
18286         (_REG_EESCAPE): Renamed from REG_EESCAPE.
18287         (_REG_ESUBREG): Renamed from REG_ESUBREG.
18288         (_REG_EBRACK): Renamed from REG_EBRACK.
18289         (_REG_EPAREN): Renamed from REG_EPAREN.
18290         (_REG_EBRACE): Renamed from REG_EBRACE.
18291         (_REG_BADBR): Renamed from REG_BADBR.
18292         (_REG_ERANGE): Renamed from REG_ERANGE.
18293         (_REG_ESPACE): Renamed from REG_ESPACE.
18294         (_REG_BADRPT): Renamed from REG_BADRPT.
18295         (_REG_EEND): Renamed from REG_EEND.
18296         (_REG_ESIZE): Renamed from REG_ESIZE.
18297         (_REG_ERPAREN): Renamed from REG_ERPAREN.
18298         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
18299         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
18300         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
18301         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
18302
18303         (_REG_RE_NAME, _REG_RM_NAME): New macros.
18304         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
18305         changed.  But support the old name if the new one is not defined
18306         and if _REGEX_SOURCE.
18307
18308         Change the following member names in struct re_pattern_buffer.
18309         The old names are still supported if !_REGEX_SOURCE.
18310         The new names are always supported, regardless of _REGEX_SOURCE.
18311         (re_buffer): Renamed from buffer.
18312         (re_allocated): Renamed from allocated.
18313         (re_used): Renamed from used.
18314         (re_syntax): Renamed from syntax.
18315         (re_fastmap): Renamed from fastmap.
18316         (re_translate): Renamed from translate.
18317         (re_can_be_null): Renamed from can_be_null.
18318         (re_regs_allocated): Renamed from regs_allocated.
18319         (re_fastmap_accurate): Renamed from fastmap_accurate.
18320         (re_no_sub): Renamed from no_sub.
18321         (re_not_bol): Renamed from not_bol.
18322         (re_not_eol): Renamed from not_eol.
18323         (re_newline_anchor): Renamed from newline_anchor.
18324
18325         Change the following member names in struct re_registers.
18326         The old names are still supported if !_REGEX_SOURCE.
18327         The new names are always supported, regardless of _REGEX_SOURCE.
18328         (rm_num_regs): Renamed from num_regs.
18329         (rm_start): Renamed from start.
18330         (rm_end): Renamed from end.
18331
18332         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
18333         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
18334         Prepend __ to parameter names.
18335
18336         Undo yesterday's changes.
18337
18338 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18339
18340         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
18341         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
18342         lib/regex.c.
18343
18344 2005-08-24  Jim Meyering  <jim@meyering.net>
18345
18346         Sync from coreutils.
18347         * m4/fcntl-safer.m4: New file.
18348
18349         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
18350         and object files for this module.
18351
18352 2005-08-24  Jim Meyering  <jim@meyering.net>
18353
18354         Sync from coreutils.
18355         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
18356
18357 2005-08-24  Jim Meyering  <jim@meyering.net>
18358
18359         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
18360         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
18361
18362 2005-08-24  Jim Meyering  <jim@meyering.net>
18363
18364         * modules/fcntl-safer: New module.
18365         * modules/fts (Depends-on): Add fcntl-safer.
18366         * MODULES.html.sh (File descriptor based Input/Output):
18367         Add fcntl-safer.
18368
18369 2005-08-24  Bruno Haible  <bruno@clisp.org>
18370
18371         Support for unit test modules.
18372         * modules/README: Mention tests modules.
18373         * modules/TEMPLATE-TESTS: New file.
18374         * gnulib-tool: New options --extract-tests-module, --with-tests and
18375         --tests-base (unused for the moment).
18376         (testsbase, inctests): New variables.
18377         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
18378         (func_verify_module): Exclude TEMPLATE-TESTS.
18379         (func_verify_nontests_module, func_verify_tests_module): New functions.
18380         (func_get_dependencies): Add implicit dependency for tests modules.
18381         (func_get_tests_module): New function.
18382         (func_modules_transitive_closure): When --with-tests was specified,
18383         include the unit tests as well, unless explicitly avoided.
18384         (func_emit_lib_Makefile_am): Ignore the tests modules here.
18385         (func_emit_tests_Makefile_am): New function.
18386         (func_create_testdir): When --with-tests was specified, emit a
18387         tests/ directory.
18388         * MODULES.html.sh (Future developments): Update.
18389
18390 2005-08-24  Bruno Haible  <bruno@clisp.org>
18391
18392         * modules/tls-tests: New file.
18393         * tests/test-tls.c: New file, from GNU gettext.
18394
18395 2005-08-24  Bruno Haible  <bruno@clisp.org>
18396
18397         * modules/lock-tests: New file.
18398         * tests/test-lock.c: New file, from GNU gettext.
18399
18400 2005-08-24  Bruno Haible  <bruno@clisp.org>
18401
18402         * lib/lock.h: Add multiple inclusion guard.
18403         * lib/tls.h: Add multiple inclusion guard.
18404
18405 2005-08-24  Bruno Haible  <bruno@clisp.org>
18406
18407         * gnulib-tool: Add support for the --aux-dir option to
18408         --create-testdir, --create-megatestdir, --test, --megatest.
18409         (func_create_testdir, func_create_megatestdir): Optionally emit a
18410         AC_CONFIG_AUX_DIR directive.
18411         (create-testdir, create-megatestdir, test, megatest): Provide a
18412         default value for $auxdir.
18413
18414 2005-08-24  Bruno Haible  <bruno@clisp.org>
18415
18416         * gnulib-tool (import): Use compound statement instead of subshell
18417         where possible.
18418
18419 2005-08-24  Bruno Haible  <bruno@clisp.org>
18420
18421         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18422
18423 2005-08-24  Bruno Haible  <bruno@clisp.org>
18424
18425         * gnulib-tool (func_version): Update.
18426
18427 2005-08-24  Bruno Haible  <bruno@clisp.org>
18428
18429         * gnulib-tool (func_import, func_create_testdir,
18430         func_create_megatestdir): Quote all autoconf macro arguments.
18431
18432 2005-08-24  Bruno Haible  <bruno@clisp.org>
18433
18434         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18435         option --force, because --force causes the aclocal.m4 of each
18436         subdirectory to be newer than the corresponding config.h.in.
18437
18438 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18439
18440         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18441         All contents moved to gl_REGEX.
18442         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18443         assume that it does.
18444
18445 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18446
18447         * lib/regex.h (REG_NOSYS)
18448         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18449         Define, since POSIX requires it as of 2001.
18450         (_REG_ENOSYS)
18451         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18452         New private symbol, used to keep the enum signed in all cases.
18453         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18454         Youngman in
18455         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18456
18457         * lib/regex_internal.c (re_string_skip_chars, register_state):
18458         (calc_state_hash):
18459         Remove forward decls; no longer needed now that we use prototypes.
18460         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18461         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18462         (clean_state_log_if_needed): Likewise.
18463
18464 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18465
18466         * config/srclist.txt: Add glibc bugs 1231-1233.
18467
18468 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18469
18470         Fix problems reported by Sam Steingold in
18471         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18472         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18473         assumed that reg_errcode_t is a signed type, which is not
18474         necessarily true if _XOPEN_SOURCE is not defined.
18475         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18476         since some compilers warn about it otherwise.
18477
18478 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18479
18480         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18481         (init_word_char, create_initial_state, duplicate_node_closure):
18482         (fetch_token, peek_token_bracket, build_range_exp):
18483         (build_collating_symbol): Remove forward decls; no longer needed
18484         now that we use prototypes.
18485
18486         * lib/regcomp.c:
18487         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18488         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18489         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18490         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18491         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18492         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18493         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18494         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18495         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18496         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18497         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18498         (build_charclass, build_charclass_op, fetch_number, create_tree):
18499         (create_token_tree, mark_opt_subexp, duplicate_tree):
18500         Use prototypes rather than old-style definitions.
18501
18502         * lib/regex_internal.c:
18503         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18504         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18505         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18506         (re_string_reconstruct, re_string_peek_byte_case):
18507         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18508         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18509         (re_node_set_init_copy, re_node_set_add_intersect):
18510         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18511         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18512         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18513         (re_acquire_state, re_acquire_state_context, register_state):
18514         (create_ci_newstate, create_cd_newstate, free_state):
18515         Likewise.
18516         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18517         re_search_2):
18518         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18519         (re_search_internal, prune_impossible_nodes):
18520         (acquire_init_state_context, check_matching, static):
18521         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18522         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18523         (update_regs, sift_states_backward, build_sifted_states):
18524         (clean_state_log_if_needed, merge_state_array):
18525         (update_cur_sifted_state, add_epsilon_src_nodes):
18526         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18527         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18528         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18529         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18530         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18531         (check_arrival, check_arrival_add_next_nodes):
18532         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18533         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18534         (check_node_accept_bytes, check_node_accept, extend_buffers):
18535         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18536         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18537         (sift_ctx_init):
18538         Likewise.
18539
18540         * lib/regex_internal.h:
18541         (re_string_allocate, re_string_construct, re_string_reconstruct):
18542         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18543         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18544         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18545         (re_string_context_at, re_string_peek_byte_case):
18546         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18547         is defined, since we now use prototypes always.
18548
18549         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18550         C89 or better.  All uses removed.
18551
18552 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18553
18554         * config/srclist.txt: Add glibc bugs 1220-1227.
18555
18556 2005-08-20  Jim Meyering  <jim@meyering.net>
18557
18558         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18559         of unused local, dfa.
18560
18561 2005-08-20  Bruno Haible  <bruno@clisp.org>
18562
18563         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18564
18565 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18566
18567         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18568         (re_node_set_insert_last, re_dfa_add_node):
18569         Rename local variables to avoid GCC shadowing warnings.
18570
18571 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18572
18573         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18574         [defined lint]: Suppress bogus uninitialized-variable warnings.
18575
18576         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18577         and let the caller return REG_ESPACE if out of space.  This
18578         removes an uninitialied-variable warning with GCC 4.0.1, and also
18579         avoids taking the address of a local variable.  All callers
18580         changed.
18581
18582 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18583
18584         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
18585         $LIBCSRC/posix/regexec.c.
18586         Add glibc bug 1217 for regcomp.c.
18587
18588 2005-08-19  Jim Meyering  <jim@meyering.net>
18589
18590         * lib/regexec.c (proceed_next_node): Redo local variables to
18591         avoid GCC shadowing warnings.
18592
18593 2005-08-18  Bruno Haible  <bruno@clisp.org>
18594
18595         * lib/strstr.c (strstr): Fix return value in multibyte case.
18596         * lib/strcasestr.c (strcasestr): Likewise.
18597
18598 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18599
18600         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
18601
18602 2005-08-17  Jim Meyering  <jim@meyering.net>
18603
18604         Make the %s format (seconds since the epoch) work for a negative
18605         number and when used with a zero-padded field width, e.g. %015s.
18606
18607         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
18608         label so that it precedes the code to set `digits'.  Otherwise,
18609         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
18610         print `00-22'.  Now, it prints `-0022', as it should.
18611
18612 2005-08-17  Bruno Haible  <bruno@clisp.org>
18613
18614         * modules/strstr (Files): Add m4/mbrtowc.m4.
18615         (Depends-on): Add mbuiter.
18616
18617 2005-08-17  Bruno Haible  <bruno@clisp.org>
18618
18619         * modules/strcasestr: New file.
18620         * MODULES.html.sh (String handling, based on ANSI C 89): Add
18621         strcasestr.
18622
18623 2005-08-17  Bruno Haible  <bruno@clisp.org>
18624
18625         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
18626
18627 2005-08-17  Bruno Haible  <bruno@clisp.org>
18628
18629         * modules/mbuiter: New file.
18630         * MODULES.html.sh (Extended multibyte and wide character utilities):
18631         Add mbuiter.
18632
18633 2005-08-17  Bruno Haible  <bruno@clisp.org>
18634
18635         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
18636         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
18637
18638 2005-08-17  Bruno Haible  <bruno@clisp.org>
18639
18640         * m4/strcasestr.m4: New file.
18641
18642 2005-08-17  Bruno Haible  <bruno@clisp.org>
18643
18644         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
18645         * lib/strstr.c: Completely rewritten, with multibyte locale support.
18646
18647 2005-08-17  Bruno Haible  <bruno@clisp.org>
18648
18649         * lib/strcasestr.h: New file.
18650         * lib/strcasestr.c: New file.
18651
18652 2005-08-17  Bruno Haible  <bruno@clisp.org>
18653
18654         * lib/strcasecmp.c: Use mbuiter.h.
18655
18656 2005-08-17  Bruno Haible  <bruno@clisp.org>
18657
18658         * lib/mbuiter.h: New file.
18659
18660 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18661
18662         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
18663         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
18664         and gl_GETOPT are both invoked via different paths (as happens
18665         with GNU tar CVS because it uses both argp and getopt), the former
18666         wins.
18667
18668 2005-08-16  Bruno Haible  <bruno@clisp.org>
18669
18670         * modules/tls: New file.
18671         * MODULES.html.sh (Multithreading): Add tls.
18672
18673 2005-08-16  Bruno Haible  <bruno@clisp.org>
18674
18675         * modules/strnlen1: New file.
18676         * MODULES.html.sh (String handling): Add strnlen1.
18677
18678 2005-08-16  Bruno Haible  <bruno@clisp.org>
18679
18680         * modules/strcase (Files): Add m4/mbrtowc.m4.
18681         (Depends-on): Add strnlen1, mbchar.
18682
18683 2005-08-16  Bruno Haible  <bruno@clisp.org>
18684
18685         * modules/mbiter: New file.
18686         * MODULES.html.sh (Extended multibyte and wide character utilities):
18687         Add mbiter.
18688
18689 2005-08-16  Bruno Haible  <bruno@clisp.org>
18690
18691         * modules/mbfile: New file.
18692         * MODULES.html.sh (Extended multibyte and wide character utilities):
18693         Add mbfile.
18694
18695 2005-08-16  Bruno Haible  <bruno@clisp.org>
18696
18697         * modules/mbchar: New file.
18698         * MODULES.html.sh (Extended multibyte and wide character utilities):
18699         New section.
18700
18701 2005-08-16  Bruno Haible  <bruno@clisp.org>
18702
18703         * m4/tls.m4: New file, from GNU gettext.
18704
18705 2005-08-16  Bruno Haible  <bruno@clisp.org>
18706
18707         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
18708         always.
18709         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
18710
18711 2005-08-16  Bruno Haible  <bruno@clisp.org>
18712
18713         * m4/mbiter.m4: New file.
18714
18715 2005-08-16  Bruno Haible  <bruno@clisp.org>
18716
18717         * m4/mbfile.m4: New file.
18718
18719 2005-08-16  Bruno Haible  <bruno@clisp.org>
18720
18721         * m4/mbchar.m4: New file.
18722
18723 2005-08-16  Bruno Haible  <bruno@clisp.org>
18724
18725         * lib/tls.h: New file, from GNU gettext.
18726         * lib/tls.c: New file, from GNU gettext.
18727
18728 2005-08-16  Bruno Haible  <bruno@clisp.org>
18729
18730         * lib/strnlen1.h: New file.
18731         * lib/strnlen1.c: New file.
18732
18733 2005-08-16  Bruno Haible  <bruno@clisp.org>
18734
18735         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
18736         (mbi_init): Update.
18737         (mbi_avail, mbi_advance): Let the iteration end before the terminating
18738         NUL byte, not after it.
18739
18740 2005-08-16  Bruno Haible  <bruno@clisp.org>
18741
18742         * lib/strcase.h (strcasecmp): Add note in comments.
18743         * lib/strncasecmp.c: Use code from strcasecmp.c.
18744         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
18745         (strcasecmp): Work correctly in multibyte locales.
18746
18747 2005-08-16  Bruno Haible  <bruno@clisp.org>
18748
18749         * lib/mbiter.h: New file.
18750
18751 2005-08-16  Bruno Haible  <bruno@clisp.org>
18752
18753         * lib/mbfile.h: New file.
18754
18755 2005-08-16  Bruno Haible  <bruno@clisp.org>
18756
18757         * lib/mbchar.h: New file.
18758         * lib/mbchar.c: New file.
18759
18760 2005-08-16  Bruno Haible  <bruno@clisp.org>
18761
18762         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
18763         the valid ones. Makes the comparison operations transitive:
18764         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
18765         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
18766
18767 2005-08-15  Simon Josefsson  <jas@extundo.com>
18768
18769         * modules/ssize_t (License): Change to 'unlimited'.
18770
18771         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
18772
18773 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
18774
18775         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
18776         Add comments for each pending glibc patch.
18777
18778 2005-08-15  Bruno Haible  <bruno@clisp.org>
18779
18780         * lib/regex.h (__restrict_arr): Don't define to __restrict if
18781         __cplusplus is defined.
18782
18783 2005-08-14  Jim Meyering  <jim@meyering.net>
18784
18785         Sync from coreutils.
18786
18787         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
18788         Use the hash-table-based cycle-detection code not just when
18789         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
18790         Reported by James Youngman in
18791         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
18792         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
18793         FTS_TIGHT_CYCLE_CHECK.
18794         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
18795         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
18796         once again.
18797         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
18798         * lib/fts.c (fd_safer): Remove decl.
18799         Include fcntl--.h rather than unistd-safer.h
18800         (fts_safe_changedir): Don't call fd_safer; no longer needed
18801         now that we include fcntl--.h.
18802
18803 2005-08-12  Simon Josefsson  <jas@extundo.com>
18804
18805         * modules/getndelim2: Use ssize_t module.
18806         * modules/getnline: Likewise.
18807         * modules/safe-read: Likewise.
18808         * modules/xreadlink: Likewise.
18809
18810         * modules/ssize_t: New file.
18811
18812 2005-08-12  Simon Josefsson  <jas@extundo.com>
18813
18814         * m4/readline.m4: Look for termcap, curses or ncurses if required.
18815
18816 2005-08-12  Simon Josefsson  <jas@extundo.com>
18817
18818         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18819         ssize_t.
18820
18821 2005-08-12  Simon Josefsson  <jas@extundo.com>
18822
18823         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
18824         readline, getdelim and check_version.
18825         (Support for systems lacking ISO C 99: Sizes of integer types):
18826         Add size_max.
18827
18828 2005-08-12  Bruno Haible  <bruno@clisp.org>
18829
18830         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
18831
18832 2005-08-11  Simon Josefsson  <jas@extundo.com>
18833
18834         * modules/readline: New file.
18835
18836         * modules/strnlen (Files): Add strnlen.h.
18837
18838 2005-08-11  Simon Josefsson  <jas@extundo.com>
18839
18840         * m4/readline.m4: New file.
18841
18842 2005-08-11  Simon Josefsson  <jas@extundo.com>
18843
18844         * lib/readline.h, readline.c: New file.
18845
18846 2005-08-11  Simon Josefsson  <jas@extundo.com>
18847
18848         * doc/gnulib.texi (Initial import, Finishing touches): Mention
18849         gl_AVOID.
18850
18851 2005-08-11  Bruno Haible  <bruno@clisp.org>
18852
18853         * lib/strnlen.h (strnlen): Change parameter name to match comment.
18854
18855 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
18856
18857         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
18858
18859 2005-08-10  Simon Josefsson  <jas@extundo.com>
18860
18861         * tests/test-iconvme.c: New file.
18862
18863 2005-08-10  Simon Josefsson  <jas@extundo.com>
18864
18865         * m4/strnlen.m4: New file.
18866
18867         * m4/strndup.m4: Don't check for strnlen declaration, done in
18868         strnlen.m4.
18869
18870 2005-08-10  Simon Josefsson  <jas@extundo.com>
18871
18872         * lib/strndup.c: Use strnlen.h.
18873
18874         * lib/strnlen.h: New file.
18875
18876 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
18877
18878         * README: Typos.
18879
18880 2005-08-02  Simon Josefsson  <jas@extundo.com>
18881
18882         * modules/readline: New file.
18883
18884 2005-08-02  Simon Josefsson  <jas@extundo.com>
18885
18886         * modules/getdelim: New file.
18887
18888         * modules/getline: Rewrite, don't use getndelim2.
18889
18890 2005-08-02  Simon Josefsson  <jas@extundo.com>
18891
18892         * m4/getline.m4: Separate out getdelim stuff into separate module.
18893
18894         * m4/getdelim.m4: New file.
18895
18896 2005-08-02  Simon Josefsson  <jas@extundo.com>
18897
18898         * lib/getline.h, getline.c: Rewrite.
18899
18900         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
18901
18902 2005-07-31  Bruno Haible  <bruno@clisp.org>
18903
18904         * lib/lock.h (gl_lock_initializer): New macro.
18905         (gl_lock_define_initialized): Use it.
18906         (gl_rwlock_initializer): New macro.
18907         (gl_rwlock_define_initialized): Use it.
18908         (gl_recursive_lock_initializer): New macro.
18909         (gl_recursive_lock_define_initialized): Use it.
18910
18911 2005-07-30  Karl Berry  <karl@gnu.org>
18912
18913         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
18914         Report from Ben Pfaff, regarding getopt.
18915
18916 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
18917
18918         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
18919         normal way.
18920         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
18921         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
18922         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
18923         (gl_GETOPT): Use the new macros.  Most of the implementation
18924         is moved to the new macros.  This is for programs like Emacs
18925         that don't want all the functionality of gl_GETOPT.
18926
18927 2005-07-26  Bruno Haible  <bruno@clisp.org>
18928
18929         * m4/lock.m4: Update from GNU gettext.
18930
18931 2005-07-26  Bruno Haible  <bruno@clisp.org>
18932
18933         * lib/lock.h: Update from GNU gettext.
18934         * lib/lock.c: Update from GNU gettext.
18935
18936 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
18937
18938         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
18939         obsolescent AC_TRY_RUN.  Include the default includes files, for
18940         'exit'.
18941
18942 2005-07-24  Bruno Haible  <bruno@clisp.org>
18943
18944         * modules/visibility: New file.
18945         * MODULES.html.sh (Misc): Add visibility.
18946
18947 2005-07-24  Bruno Haible  <bruno@clisp.org>
18948
18949         * m4/visibility.m4: New file.
18950
18951 2005-07-24  Bruno Haible  <bruno@clisp.org>
18952
18953         * doc/visibility.texi: New file.
18954
18955 2005-07-22  Bruno Haible  <bruno@clisp.org>
18956
18957         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
18958         $(ALLOCA_H), redundant through BUILT_SOURCES.
18959         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
18960         redundant through BUILT_SOURCES.
18961         * modules/byteswap (Makefile.am): Remove explicit dependency on
18962         $(BYTESWAP_H), redundant through BUILT_SOURCES.
18963         * modules/fnmatch (Makefile.am): Remove explicit dependency on
18964         $(FNMATCH_H), redundant through BUILT_SOURCES.
18965         * modules/getopt (Makefile.am): Remove explicit dependency on
18966         $(GETOPT_H), redundant through BUILT_SOURCES.
18967         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
18968         redundant through BUILT_SOURCES.
18969         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
18970         redundant through BUILT_SOURCES.
18971         * modules/stdbool (Makefile.am): Remove explicit dependency on
18972         $(STDBOOL_H), redundant through BUILT_SOURCES.
18973         * modules/stdint (Makefile.am): Remove explicit dependency on
18974         $(STDINT_H), redundant through BUILT_SOURCES.
18975         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
18976         Remove explicit dependency on $(SYSEXITS_H).
18977         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
18978
18979 2005-07-18  Simon Josefsson  <jas@extundo.com>
18980
18981         * lib/check-version.c (check_version): Accept identical versions too.
18982
18983 2005-07-18  Bruno Haible  <bruno@clisp.org>
18984
18985         * modules/lock: New file.
18986         * MODULES.html.sh (Multithreading): New section.
18987
18988 2005-07-18  Bruno Haible  <bruno@clisp.org>
18989
18990         * m4/lock.m4: New file, from GNU gettext.
18991
18992 2005-07-18  Bruno Haible  <bruno@clisp.org>
18993
18994         * lib/lock.h: New file, from GNU gettext.
18995         * lib/lock.c: New file, from GNU gettext.
18996
18997 2005-07-18  Bruno Haible  <bruno@clisp.org>
18998
18999         * lib/lock.h (gl_once_t): New type.
19000         (gl_once_define, gl_once): New macros.
19001         * lib/lock.c (fresh_once): New variable.
19002         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
19003         functions.
19004
19005 2005-07-16  Simon Josefsson  <jas@extundo.com>
19006
19007         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
19008         workaround, suggested by Bruno.
19009
19010 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19011
19012         * modules/xalloc (Depends-on): Add xalloc-die.
19013         * modules/xvasprintf (Depends-on): Add xalloc-die.
19014
19015 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19016
19017         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
19018         with a minor change.
19019
19020 2005-07-15  Bruno Haible  <bruno@clisp.org>
19021
19022         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
19023         When using lib/poll.c, define poll as rpl_poll.
19024
19025 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
19026
19027         * modules/argp (Depends-on): Remove unlocked-io.
19028
19029 2005-07-14  Derek Price  <derek@ximbiot.com>
19030
19031         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
19032         for glob symlink bug.
19033
19034 2005-07-14  Bruno Haible  <bruno@clisp.org>
19035
19036         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
19037         Instead, test for *_unlocked function declarations directly.
19038
19039 2005-07-11  Simon Josefsson  <jas@extundo.com>
19040
19041         * modules/size_max: New file.
19042
19043         * modules/xsize: Depend on size_max module for size_max.m4.
19044
19045 2005-07-11  Simon Josefsson  <jas@extundo.com>
19046
19047         * lib/size_max.h: New file.
19048
19049 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
19050
19051         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
19052         copyright symbol and the year.
19053         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
19054         (version_etc_va): Use parameterized copyright notice.
19055         Reword to conform to the current GNU coding standards.
19056
19057 2005-07-11  Karl Berry  <karl@gnu.org>
19058
19059         * doc/gnulib.texi (Quoting): new node.
19060         (Initial import): more info, from Patrice.
19061
19062 2005-07-11  Bruno Haible  <bruno@clisp.org>
19063
19064         * gnulib-tool (func_usage): Document option --avoid.
19065         (Command line options): Handle --avoid.
19066         (func_acceptable): New function.
19067         (func_modules_transitive_closure): Use it.
19068
19069 2005-07-11  Bruno Haible  <bruno@clisp.org>
19070
19071         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
19072         Reported by Jim Meyering.
19073
19074 2005-07-10  Bruno Haible  <bruno@clisp.org>
19075
19076         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
19077         Needed when size_t is smaller than 'unsigned int'.
19078         Reported by Paul Eggert.
19079
19080 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19081
19082         * modules/argp (Depends-on): Add unlocked-io
19083
19084 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19085
19086         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
19087         block of defines.
19088
19089 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
19090
19091         * config/srclist.txt: Comment out regcomp.c, since we have a porting
19092         fix now.
19093
19094 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
19095         and Paul Eggert  <eggert@cs.ucla.edu>
19096
19097         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
19098         in wint_t, not wchar_t.  Remove now-unnecessary cast.
19099
19100 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19101
19102         * modules/regex (Files): Add lib/regex_internal.c,
19103         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
19104         (Depends-on): Add extensions.
19105         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
19106
19107 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19108
19109         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
19110         pathconf.
19111         * m4/same.m4 (gl_SAME): Likewise.
19112         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
19113
19114         * m4/regex.m4: Adjust to new libc regex implementation.
19115         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
19116         all the .c and .h parts of (the new) regex.
19117         Quote the m4 stuff better.
19118         Check for RE_ICASE bug of old gnulib.
19119         Check for REG_STARTEND of recent libc.
19120         Rename local variables from jm_* to gl_*.
19121         Quote operand of "test -f".
19122         Say "recent enough" version of libc, not "version 2".
19123         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
19124         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
19125         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
19126         Remove check for btowc, isascii.
19127         Require AM_LANGINFO_CODESET.
19128
19129 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19130
19131         * lib/regex.c, regex.h: Sync from libc.
19132         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
19133         * lib/regexec.c:
19134         New files, synced from libc, except that regex_internal.h
19135         currently has a small porting fix.
19136
19137 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19138
19139         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
19140         regex_internal.c, regexec.c.
19141         Add regex_internal.h too, but as a comment, since the libc version
19142         is currently broken in gnulib mode.
19143
19144 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
19145
19146         Support programs like Emacs that use gnulib but not gettext.
19147         * MODULES.html.sh (Internationalization functions): Add gettext-h.
19148         * modules/gettext-h: New file.
19149         * modules/gettext (Files): Remove lib/gettext.h.
19150         (Depends-on): Add gettext-h.
19151         (Makefile.am): Remove lib_SOURCES.
19152         * modules/argmatch, modules/c-stack, modules/closeout:
19153         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
19154         * modules/execute, modules/file-type, modules/getaddrinfo:
19155         * modules/getopt, modules/human, modules/javacomp:
19156         * modules/javaexec, modules/mkdir-p, modules/obstack:
19157         * modules/openat, modules/pagealign_alloc, modules/pipe:
19158         * modules/quotearg, modules/regex, modules/rpmatch:
19159         * modules/unicodeio, modules/userspec, modules/version-etc:
19160         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
19161         * modules/xsetenv:
19162         Depend on gettext-h, not gettext.
19163
19164 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
19165
19166         * gnulib-tool (func_import): Add support for 'public domain' license.
19167         * modules/alloca, modules/atexit, modules/memmove:
19168         Now public domain, not GPL.
19169         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
19170         * modules/realloc, modules/strerror, modules/strtod:
19171         Now LGPL, not GPL.
19172
19173 2005-07-05  Bruno Haible  <bruno@clisp.org>
19174
19175         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
19176         autoconf CVS. Needed for mingw.
19177
19178 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19179
19180         Remove the dependency of the strftime module on the tzset module.
19181         * modules/strftime (Depends-on): Remove dependency on tzset.
19182
19183 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19184
19185         Remove the dependency of the strftime module on the tzset module.
19186         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
19187         gl_FUNC_TZSET_CLOBBER.
19188
19189 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19190
19191         Remove the dependency of the strftime module on the tzset module.
19192         * lib/strftime.c (my_strftime)
19193         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
19194         Copy the input structure, to work around some of the bug with
19195         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
19196         Solaris releases, you should also use the tzset module, but we won't
19197         require it as a dependency any more since we don't want LGPLed code
19198         to depend on GPLed code.
19199
19200 2005-07-02  Jim Meyering  <jim@meyering.net>
19201
19202         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
19203         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
19204         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
19205         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
19206
19207 2005-07-02  Jim Meyering  <jim@meyering.net>
19208
19209         * lib/backupfile.c (backup_args): Change a `0' to NULL.
19210
19211 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
19212
19213         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
19214         declares only 'struct timespec;' (!).
19215
19216 2005-07-01  Jim Meyering  <jim@meyering.net>
19217
19218         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
19219         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
19220         * lib/save-cwd.c, tempname.c:
19221         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
19222         and don't include <sys/file.h>).
19223
19224 2005-06-29  Jim Meyering  <jim@meyering.net>
19225
19226         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
19227         type name.  Use the variable name instead.
19228         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
19229         Likewise.
19230
19231 2005-06-28  Simon Josefsson  <jas@extundo.com>
19232
19233         * modules/check-version (Files): Add check-version.m4.
19234
19235 2005-06-28  Simon Josefsson  <jas@extundo.com>
19236
19237         * m4/check-version.m4: New file, suggested by Jim Meyering
19238         <jim@meyering.net>.
19239
19240 2005-06-28  Simon Josefsson  <jas@extundo.com>
19241
19242         * lib/check-version.h, lib/check-version.c: New files.
19243
19244 2005-06-28  Simon Josefsson  <jas@extundo.com>
19245
19246         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
19247         collision with global variable.  Better indentation.  Don't
19248         increment buffer pointer beyond buffer end.  Based on comments
19249         from Paul Eggert <eggert@cs.ucla.edu>.
19250
19251         * lib/base64.h: Indent.
19252
19253 2005-06-28  Simon Josefsson  <jas@extundo.com>
19254
19255         * doc/gnulib.texi (Library version handling): New section.
19256
19257 2005-06-28  Jim Meyering  <jim@meyering.net>
19258
19259         * check-module (find_included_lib_files): Hard-code another
19260         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
19261         but modules/fts-lgpl (correctly) does not list those files.
19262
19263         * modules/canonicalize (Files): Add lib/pathmax.h.
19264
19265 2005-06-25  Simon Josefsson  <jas@extundo.com>
19266
19267         * modules/check-version: New file.
19268
19269 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
19270
19271         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
19272         initializer of struct addrinfo, as an indication that we don't
19273         care how many members the structure has.
19274
19275 2005-06-24  Derek Price  <derek@ximbiot.com>
19276         and Bruno Haible  <bruno@clisp.org>
19277
19278         Remove stat module & update lstat.
19279         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
19280         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
19281         * m4/stat.m4: Remove this file.
19282
19283 2005-06-24  Derek Price  <derek@ximbiot.com>
19284         and Bruno Haible  <bruno@clisp.org>
19285
19286         Remove stat module & update lstat.
19287         * lib/stat.c: Remove this file...
19288         (slash_aware_lstat): ...moving this content and its support...
19289         * lib/lstat.c (rpl_lstat): ...into here.
19290         * lib/lstat.h: New file.
19291
19292 2005-06-24  Derek Price  <derek@ximbiot.com>
19293         and Bruno Haible  <bruno@clisp.org>
19294
19295         Remove stat module & update lstat.
19296         * config/srclist.txt (libc sources): Remove stat.
19297
19298 2005-06-24  Derek Price  <derek@ximbiot.com>
19299         and Bruno Haible  <bruno@clisp.org>
19300
19301         Remove stat module & update lstat.
19302         * MODULES.html.sh (stat): Remove.
19303         * MODULES.html: Regenerated.
19304         * modules/lstat (Description): Correct function name.
19305         (Files): Add "lstat.h".
19306         (Depends-on): Remove stat, add xalloc, stat-macros.
19307         * modules/stat: Remove this file.
19308         (Include): Add "lstat.h", remove <sys/stat.h>.
19309
19310 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
19311
19312         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
19313         (ranged_convert): Don't save conversion in a temporary struct.
19314         This causes a warning with GCC 4.0.0, and anyway in the typical
19315         case it's not worth the extra 100 bytes or so of code.
19316         (ranged_convert, __mktime_internal): When calling a function via a
19317         pointer P, use P () rather than (*P) (), as we now assume C89 or
19318         better.
19319
19320 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19321
19322         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
19323         "who -r" failed to give output.  Problem reported by Tim Waugh.
19324
19325         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
19326         (xcalloc): Use it to avoid needless tests.
19327         Problem reported by Jim Meyering.
19328
19329 2005-06-20  Derek Price  <derek@ximbiot.com>
19330
19331         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
19332         unnecessary for Autoconfs > 2.59c.
19333
19334 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19335
19336         * lib/argp.h (__option_is_short): Check upper limit of
19337         __key. Isprint() requires its argument to have the value
19338         of an unsigned char or EOF.
19339
19340 2005-06-16  Jim Meyering  <jim@meyering.net>
19341
19342         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
19343         when either N or S is zero.
19344
19345 2005-06-16  Derek Price  <derek@ximbiot.com>
19346
19347         * m4/bison.m4: Declare YACC & YFLAGS precious.
19348
19349 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
19350
19351         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
19352         multibyte string or pattern, fall back on unibyte matching.
19353         Problem reported by James Youngman.
19354
19355 2005-06-08  Bruno Haible  <bruno@clisp.org>
19356
19357         * modules/csharpcomp: New file.
19358         * MODULES.html.sh (C#): Add csharpcomp.
19359
19360 2005-06-08  Bruno Haible  <bruno@clisp.org>
19361
19362         * m4/csharpcomp.m4: New file, from GNU gettext.
19363
19364 2005-06-08  Bruno Haible  <bruno@clisp.org>
19365
19366         * lib/csharpcomp.h: New file, from GNU gettext.
19367         * lib/csharpcomp.c: New file, from GNU gettext.
19368         * lib/csharpcomp.sh.in: New file, from GNU gettext.
19369
19370 2005-06-08  Bruno Haible  <bruno@clisp.org>
19371
19372         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
19373         warning on mingw.
19374
19375 2005-06-07  Derek Price  <derek@ximbiot.com>
19376
19377         Sync from CVS.
19378         * lib/glob_.h: Indent nested #ifdef.
19379
19380 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19381
19382         Sync from coreutils.
19383         Use "file name" when talking about file names, instead of "filename"
19384         or "path", as per the GNU coding standards.
19385         * lib/mkdir-p.c: Renamed from makepath.c.
19386         (make_dir_parents): Renamed from make_path.  All callers changed.
19387         * lib/mkdir-p.h: Likewise.  All includers changed.
19388         * lib/filenamecat.c: Renamed from path-concat.c.
19389         (file_name_concat): Renamed from path_concat.  All callers changed.
19390         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
19391         * lib/filenamecat.h: Likewise.  All includers changed.
19392         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
19393         in comments or local variable names.
19394         * lib/basename.c: Likewise.
19395         * lib/canonicalize.c, canonicalize.h: Likewise.
19396         * lib/dirname.c, dirname.h: Likewise.
19397         * lib/euidaccess.c: Likewise.
19398         * lib/exclude.c: Likewise
19399         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
19400         * lib/fsusage.c, fsuage.h: Likewise.
19401         * lib/fts.c, fts_.h: Likewise.
19402         * lib/getcwd.c: Likewise.
19403         * lib/getloadavg.c: Likewise.
19404         * lib/mkstemp.c: Likewise.
19405         * lib/mountlist.c, mountlist.h: Likewise.
19406         * lib/openat.c, openat.h: Likewise.
19407         * lib/readlink-stub.c: Likewise.
19408         * lib/readutmp.c, readutmp.h: Likewise.
19409         * lib/rename.c: Likewise.
19410         * lib/rmdir.c: Likewise.
19411         * lib/same.c: Likewise.
19412         * lib/savedir.c: Likewise.
19413         * lib/stripslash.c: Likewise.
19414         * lib/tempname.c: Likewise.
19415         * lib/xreadlink.c: Likewise.
19416         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19417         All uses changed.
19418         * lib/exclude.h: Likewise.
19419
19420         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19421         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19422         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19423         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19424         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19425         files have been getting away with it for years (MORE/BSD 4.3
19426         is extinct now).
19427         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19428         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19429
19430         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19431         Define to 256, not 255, as per modern POSIX.
19432
19433 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19434
19435         Sync from coreutils.
19436         Use "file name" when talking about file names, instead of "filename"
19437         or "path", as per the GNU coding standards.
19438         * MODULES.html.sh: mkdir-p renamed from makepath.
19439         filenamecat renamed from path-concat.
19440         * modules/filenamecat: Renamed from modules/path-concat.
19441         (Files): filenamecat.h and filenamecat.c renamed from
19442         path-concat.h and path-concat.c.
19443         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19444         (Include): filenamecat.h, not path-concat.h.
19445         * modules/mkdir-p: Renamed from modules/makepath.
19446         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19447         makepath.c.
19448         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19449         (Include): mkdir-p.h, not makepath.h.
19450
19451 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19452
19453         Sync from coreutils.
19454         * m4/mkdir-p.m4: Renamed from makepath.m4.
19455         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19456         Rename files from makepath.c to mkdir-p.c, and from
19457         makepath.h to mkdir-p.h.
19458         * m4/filenamecat.m4: Renamed from path-concat.m4.
19459         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19460         Rename files from path-concat.c to filenamecat.c,
19461         and from path-concat.h to filenamecat.h.
19462         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19463         "file name" in local variables or comments.
19464         * m4/rename.m4: Likewise.
19465
19466 2005-06-01  Bruno Haible  <bruno@clisp.org>
19467
19468         * modules/csharpexec: New file.
19469         * MODULES.html.sh (C#): New section.
19470
19471 2005-06-01  Bruno Haible  <bruno@clisp.org>
19472
19473         * m4/csharp.m4: New file, from GNU gettext.
19474         * m4/csharpexec.m4: New file, from GNU gettext.
19475
19476 2005-06-01  Bruno Haible  <bruno@clisp.org>
19477
19478         * lib/csharpexec.h: New file, from GNU gettext.
19479         * lib/csharpexec.c: New file, from GNU gettext.
19480         * lib/csharpexec.sh.in: New file, from GNU gettext.
19481
19482 2005-05-31  Derek Price  <derek@ximbiot.com>
19483             Paul Eggert  <eggert@cs.ucla.edu>
19484
19485         Sync from cvs.
19486         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19487
19488 2005-05-31  Derek Price  <derek@ximbiot.com>
19489             Paul Eggert  <eggert@cs.ucla.edu>
19490
19491         Sync from cvs.
19492         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19493
19494 2005-05-29  Derek Price  <derek@ximbiot.com>
19495
19496         * config/srclist.txt (glob_.h, glob.c): Add these files.
19497
19498 2005-05-29  Derek Price  <derek@ximbiot.com>
19499
19500         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19501         * modules/glob: New file.
19502         * modules/getlogin_r: Add link to POSIX spec in description.
19503
19504 2005-05-29  Derek Price  <derek@ximbiot.com>
19505             Paul Eggert  <eggert@cs.ucla.edu>
19506
19507         * m4/glob.m4: New file.
19508
19509 2005-05-29  Derek Price  <derek@ximbiot.com>
19510             Paul Eggert  <eggert@cs.ucla.edu>
19511
19512         * lib/glob_.h, lib/glob.c: New files.
19513
19514 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19515
19516         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19517         * modules/fts-lgpl (Depends-on): Remove gettext.
19518
19519 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19520
19521         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19522         and don't require gt_INTTYPES_PRI.
19523
19524 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19525
19526         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19527
19528         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19529         the configuration hassle isn't worth it.
19530         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19531         (LONGEST_MODIFIER, PRIuMAX): Remove.
19532
19533 2005-05-27  Bruno Haible  <bruno@clisp.org>
19534
19535         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19536
19537 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19538
19539         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19540         _POSIX_PTHREAD_SEMANTICS for Solaris.
19541
19542 2005-05-25  Derek Price  <derek@ximbiot.com>
19543
19544         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19545
19546 2005-05-25  Derek Price  <derek@ximbiot.com>
19547             Paul Eggert  <eggert@cs.ucla.edu>
19548
19549         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19550         * lib/getlogin_r.c, getlogin_r.h: New files.
19551
19552 2005-05-25  Bruno Haible  <bruno@clisp.org>
19553             Derek Price  <derek@ximbiot.com>
19554
19555         * lib/getlogin_r.h: Simplify API documentation.
19556
19557 2005-05-23  Derek Price  <derek@ximbiot.com>
19558
19559         * modules/minmax (Files): Add m4/minmax.m4.
19560         (configure.ac): Add gl_MINMAX.
19561
19562 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19563
19564         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19565         so that unistd-safer.h (GPL'ed code) need not be included.
19566
19567 2005-05-22  Bruno Haible  <bruno@clisp.org>
19568
19569         * m4/minmax.m4: New file.
19570         Based on a patch by Derek Price <derek@ximbiot.com>.
19571
19572 2005-05-22  Bruno Haible  <bruno@clisp.org>
19573
19574         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19575         (INT64_MIN): Fix definition.
19576         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19577
19578         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19579         NEED_SIGNED_INT_TYPES.
19580
19581         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19582         HAVE_SYSTEM_INTTYPES.
19583
19584 2005-05-22  Bruno Haible  <bruno@clisp.org>
19585
19586         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
19587         Also include <sys/param.h> if it defines MIN, MAX.
19588         Based on a patch by Derek Price <derek@ximbiot.com>.
19589
19590 2005-05-21  Jim Meyering  <jim@meyering.net>
19591
19592         * modules/fts (Files): Add m4/inttypes-pri.m4.
19593         (Depends-on): Add lstat and remove gettext.  Alphabetize.
19594
19595 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19596
19597         New fts module.
19598         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
19599         (setup_dir, free_dir): New functions.
19600         (enter_dir, leave_dir): Define trivial
19601         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
19602         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
19603         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
19604         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
19605         Move to fts-cycle.c.
19606         (fts_open): Use setup_dir.
19607         (fts_close): Use free_dir.
19608         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
19609         This adds a label and some gotos, but the alternatives were messier.
19610         Check for memory allocation failure when entering a dir.
19611         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
19612         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
19613         (FTS): New member fts_cycle, that is a union that contains the
19614         old active_dir_ht and cycle_state.  All uses changed to mention
19615         fts_cycle.ht and fts_cycle.state.
19616         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
19617         fts.c, with the following changes:
19618         (setup_dir, free_dir): New functions.
19619         (enter_dir): Now returns bool.  Return true if successful, false
19620         if memory exhausted.  All callers changed.
19621         Do not bother partly cleaning up on
19622         memory allocation failure; that is free_dir's job.
19623         However, free ad if hash_insert fails, to avoid memory leak.
19624         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
19625         fts->fts_options to see which union member to use.
19626
19627 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19628
19629         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
19630         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
19631
19632 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19633
19634         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
19635
19636 2005-05-20  Jim Meyering  <jim@meyering.net>
19637
19638         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
19639         Now a macro, to pacify GCC.
19640
19641 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19642
19643         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
19644         of -1.
19645
19646 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19647
19648         * lib/chown.c (rpl_chown): Return -1 on failure.
19649
19650 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19651
19652         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
19653         Don't check for stddef.h.
19654         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
19655         don't use its results.
19656         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
19657         since we include them unconditionally.  Don't require
19658         AM_STDBOOL_H, since stdbool is a prerequisite.
19659         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
19660         since we assume C89 or better.
19661         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
19662         as we don't use their results.
19663         Don't check for fchdir, memmove, memset, strrchr, as we use
19664         them unconditionally.
19665         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
19666         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
19667
19668 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19669
19670         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
19671         Include <stddef.h> unconditionally, since we assume C89 now.
19672         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
19673         * lib/fts.c: Include fts_.h first, to check interface.
19674         Do not include intprops.h; no longer needed.
19675         Include cycle-check.h and hash.h, since fts_.h no longer does.
19676         Remove unnecessary casts of closedir to void.
19677         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
19678         decide whether to decrement nlinks.
19679         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
19680         (FTS): Use struct hash_table * instead of Hash_table, so that
19681         we no longer need to include hash.h here.
19682
19683 2005-05-18  Jim Meyering  <jim@meyering.net>
19684
19685         * modules/dirfd (License): Change to LGPL.  Most of the code
19686         is already in the public domain.
19687
19688 2005-05-18  Jim Meyering  <jim@meyering.net>
19689
19690         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
19691         Reported by Yoann Vandoorselaere.
19692
19693 2005-05-17  Jim Meyering  <jim@meyering.net>
19694
19695         * m4/fts.m4: New file, from coreutils.
19696
19697 2005-05-17  Jim Meyering  <jim@meyering.net>
19698
19699         * lib/fts.c, lib/fts_.h: New files, from coreutils.
19700
19701 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19702
19703         Sync from coreutils.
19704         * m4/unlinkdir.m4: New file.
19705
19706 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19707
19708         Sync from coreutils.
19709         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
19710         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
19711         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
19712         White space changes only.
19713         * lib/makepath.c (make_path): Port to hosts where leading "//" is
19714         special.
19715         * lib/yesno.c: Include getline.h, not ctype.h.
19716         (yesno): Don't remove leading white space; POSIX doesn't allow it.
19717         Use getline to remove arbitrary restriction on response length.
19718
19719 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19720
19721         * config/srclist-update: Spell out "Street" in FSF postal
19722         mail address; this is the style the FSF seems to prefer.
19723
19724         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
19725         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
19726         this updates FSF postal mail address.
19727
19728         Sync from coreutils.
19729         * modules/unlinkdir: New file.
19730         * modules/yesno (Depends-on): Add getline.
19731         * MODULES.html.sh (File system functions): Add unlinkdir.
19732
19733 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19734
19735         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
19736         lib/strsep.h:
19737         Change the initial comment to refer to GPL, not LGPL.
19738         gnulib-tool will change it to LGPL as needed.
19739
19740         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
19741         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
19742         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
19743         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
19744         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
19745         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
19746         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
19747         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
19748         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
19749         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
19750         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
19751         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
19752         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
19753         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
19754         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
19755         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
19756         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
19757         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
19758         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
19759         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
19760         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
19761         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
19762         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
19763         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
19764         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
19765         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
19766         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
19767         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
19768         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
19769         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
19770         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
19771         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
19772         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
19773         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
19774         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
19775         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
19776         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
19777         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
19778         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
19779         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
19780         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
19781         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
19782         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
19783         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
19784         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
19785         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
19786         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
19787         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
19788         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
19789         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
19790         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19791         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
19792         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
19793         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
19794         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
19795         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
19796         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
19797         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
19798         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
19799         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
19800         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
19801         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
19802         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
19803         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
19804         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
19805         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
19806         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
19807         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
19808         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
19809         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
19810         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
19811         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
19812         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
19813         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
19814         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
19815         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
19816         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
19817         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
19818         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
19819         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
19820         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
19821         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
19822         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
19823         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
19824         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
19825         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
19826         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
19827         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
19828         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
19829         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
19830         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
19831         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
19832         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
19833         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
19834         lib/yesno.c, lib/yesno.h:
19835         Update FSF postal mail address.
19836
19837 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19838
19839         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
19840         tests/test-memmem.c, tests/test-stpncpy.c:
19841         Update FSF postal mail address.
19842
19843 2005-05-13  Bruno Haible  <bruno@clisp.org>
19844
19845         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
19846         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
19847         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
19848         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
19849         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
19850         Add support for 64-bit integers in the MSVC compiler.
19851
19852 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19853
19854         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
19855
19856 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
19857
19858         * gnulib-tool (func_import): Sort and uniquify recommended includes.
19859
19860 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
19861
19862         * doc/getdate.texi (General date syntax): Don't say that date
19863         date --iso-8601=ns generates acceptable dates; it doesn't yet.
19864         Problem reported by Nic Ferrier.
19865
19866 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19867
19868         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
19869         specified in ai_socktype. Fix invalid ai_protocol
19870         check. ai_protocol is usually set to 0 or depending on
19871         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
19872         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
19873         ai_socktype / ai_protocol in the returned addrinfo structure.
19874
19875 2005-05-10  Simon Josefsson  <jas@extundo.com>
19876
19877         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
19878         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
19879
19880 2005-05-10  Karl Berry  <karl@gnu.org>
19881
19882         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
19883         (from http://www.gnu.org/licenses).
19884         * doc/COPYING.LIB: also rename to COPYING.LESSER.
19885         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
19886         fdl.texi suffices.
19887
19888 2005-05-10  Karl Berry  <karl@gnu.org>
19889
19890         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
19891         (COPYING.DOC): remove.
19892
19893         * config/srclist-update: new FSF address.
19894
19895 2005-05-10  Derek Price  <derek@ximbiot.com>
19896
19897         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
19898         possible.
19899
19900 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19901             Bruno Haible  <bruno@clisp.org>
19902
19903         * modules/inet_ntop: New file.
19904         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19905         inet_ntop.
19906
19907 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19908             Bruno Haible  <bruno@clisp.org>
19909
19910         * m4/inet_ntop.m4: New file.
19911
19912 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19913             Bruno Haible  <bruno@clisp.org>
19914
19915         * lib/inet_ntop.h: New file.
19916         * lib/inet_ntop.c: New file, from glibc with modifications.
19917
19918 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
19919
19920         * modules/time_r (License): Change to LGPL.
19921         * modules/extensions (License): Change to LGPL.  Actually,
19922         the license is more permissive than that, but currently gnulib-tool
19923         doesn't know how to handle more-permissive licenses.
19924
19925         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
19926         Problem reported by Dave Love.
19927
19928 2005-05-08  Jim Meyering  <jim@meyering.net>
19929
19930         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
19931         blank.
19932
19933 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19934
19935         * modules/argmatch (Depends-on): Add stdbool.
19936         * modules/backupfile (Depends-on): Likewise.
19937         * modules/chdir-long (Depends-on): Likewise.
19938         * modules/closeout (Depends-on): Likewise.
19939         * modules/cycle-check (Depends-on): Likewise.
19940         * modules/dirname (Depends-on): Likewise.
19941         * modules/fnmatch (Depends-on): Likewise.
19942         * modules/fsusage (Depends-on): Likewise.
19943         * modules/fwriteerror (Depends-on): Likewise.
19944         * modules/getcwd (Depends-on): Likewise.
19945         * modules/getloadavg (Depends-on): Likewise.
19946         * modules/hard-locale (Depends-on): Likewise.
19947         * modules/makepath (Depends-on): Likewise.
19948         * modules/mountlist (Depends-on): Likewise.
19949         * modules/nanosleep (Depends-on): Likewise.
19950         * modules/posixtm (Depends-on): Likewise.
19951         * modules/quotearg (Depends-on): Likewise.
19952         * modules/readtokens (Depends-on): Likewise.
19953         * modules/readtokens0 (Depends-on): Likewise.
19954         * modules/readutmp (Depends-on): Likewise.
19955         * modules/save-cwd (Depends-on): Likewise.
19956         * modules/strftime (Depends-on): Likewise.
19957         * modules/userspec (Depends-on): Likewise.
19958         * modules/utimecmp (Depends-on): Likewise.
19959         * modules/xgetcwd (Depends-on): Likewise.
19960         * modules/xnanosleep (Depends-on): Likewise.
19961         * modules/xstrtod (Depends-on): Likewise.
19962         * modules/yesno (Depends-on): Likewise.
19963
19964 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
19965
19966         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
19967         needless checks.
19968
19969 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19970
19971         Merge from coreutils.  Among other things,
19972         add bulletproofing for cases where stdin, stdout, or stderr are closed.
19973         * lib/fd-safer.c: New file.
19974         * lib/fcntl-safer.h, open-safer.c: Remove.
19975         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
19976         * lib/dup-safer.c: Include unistd-safer.h first.
19977         Don't include errno.h.
19978         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
19979         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
19980         * lib/file-type.c: Rely on file-type.h change.
19981         * lib/getloadavg.c: Include unistd-safer.h.
19982         (getloadavg): Use safer open.
19983         * lib/getusershell.c: Include "stdio-safer.h".
19984         (getusershell): Use safer fopen.
19985         * lib/long-options.c (long_options): Use NULL rather than 0.
19986         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
19987         'free'.
19988         * lib/modechange.c: Likewise.
19989         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
19990         (MODE_DONE): New constant.
19991         (struct mode_change): Remove 'next' member.
19992         (make_node_op_equals): New function; like the old one of the
19993         same name, except it allocates an array.
19994         (mode_compile, mode_create_from_ref): Use it.
19995         (mode_compile): Allocate result as an array, not a linked list.
19996         Parse octal string ourself, so that we catch mistakes like "+0".
19997         (mode_adjust): Arg is an array, not a linked list.
19998         * lib/modechange.c: Include stat-macros.h, xalloc.h.
19999         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
20000         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
20001         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
20002         Remove.  This is now stat-macros.h's job.
20003         (talloc): Remove.  All callers replaced by xalloc, so that
20004         our invokers don't have to worry about reporting memory failures.
20005         (make_node_op_equals): Remove.
20006         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20007         New constants.
20008         (struct mode_change): Moved here from modechange.h.
20009         (mode_append_entry): Remove.
20010         (mode_compile): Remove MASKED_OPS arg, since it encouraged
20011         apps to have incorrect behavior.  Use simpler algorithm for head
20012         and tail.  Don't futz with umask; that's now the job of mode_adjust.
20013         Detect more invalid usages rather than having somewhat-random behavior.
20014         Don't insert an "a=" action, as that leads to incorrect behavior.
20015         (mode_compile, mode_create_from_ref): Return NULL on error instead
20016         of an enum, since now there's only one way to have an error.  All
20017         callers changed.
20018         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
20019         at the correct time.  Simplify calculation of "+u" and its ilk.
20020         Don't mishandle "+X".
20021         (mode_free): Remove "register" and localize decls.
20022         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20023         (struct mode_change): Move to modechange.c; callers don't
20024         need to see this stuff.
20025         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
20026         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
20027         (mode_change, mode_adjust): Reflect the new signatures noted above.
20028         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
20029         that might redefine system include files.
20030         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
20031         (my_usleep): Use NULL rather than (void *) 0.
20032         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
20033         Use siginterrupt to specify that system calls should be interrupted.
20034         (rpl_nanosleep): Move initialization of suspended closer to call of
20035         my_usleep.
20036         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
20037         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
20038         (desirable_utmp_entry): New function.
20039         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
20040         using x2nrealloc, to simplify logic.
20041         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
20042         size calculation.  Do not assume utmp file is a regular file.
20043         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
20044         (READ_UTMP_CHECK_PIDS): New constant.
20045         * lib/save-cwd.c: Include unistd-safer.h.
20046         (save_cwd): Use fd_safer.
20047         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
20048         [!_LIBC] Include "stat-macros.h" instead.
20049         * lib/unistd-safer.h (fd_safer): New decl.
20050
20051 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20052
20053         * modules/getloadavg (Depends-on): Add unistd-safer.
20054         * modules/getusershell (Depends-on): Add stdio-safer.
20055         * modules/lstat (Depends-on): Remove xalloc.
20056         * modules/mkstemp (Depends-on): Add stat-macros.
20057         * modules/modechange (Depends-on): Remove xstrtol.
20058         Add stat-macros, xalloc.
20059         * modules/save-cwd (Depends-on): Add unistd-safer.
20060         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
20061         * modules/unistd-safer (Files): Add lib/fd-safer.c
20062         (Makefile.am): Remove lib_SOURCES.
20063
20064         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
20065         Remove fcntl-safer; unistd-safer supersedes it.
20066
20067 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20068
20069         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
20070         AC_HEADER_STAT.
20071         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
20072         (gl_PREREQ_CHOWN): Remove.
20073         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
20074         it.  Don't require AC_HEADER_STAT.
20075         (gl_PREREQ_LSTAT): Remove.
20076         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
20077         Don't require AC_HEADER_STAT.
20078         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
20079         (gl_PREREQ_RMDIR): Remove.
20080         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
20081         mention stat-macros.h or AC_HEADER_STAT, since we'll make
20082         the stat-macros module a prerequisite.
20083         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
20084         * m4/filemode.m4 (gl_FILEMODE): Likewise.
20085         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
20086         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
20087         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
20088         variable names.
20089         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
20090         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
20091         variable prefixes.
20092         * m4/fcntl-safer.m4: Remove.
20093         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
20094         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
20095         Invoke gl_PREREQ_FD_SAFER.
20096         (gl_PREREQ_FD_SAFER): New macro.
20097         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
20098         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
20099         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
20100         Remove duplicate call to AC_LIBOBJ(readutmp).
20101         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
20102
20103         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
20104         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
20105
20106 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20107
20108         * MODULES.html.sh (Misc): Add byteswap.
20109
20110 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20111
20112         * modules/getcwd (Depends-on): Add extensions.
20113         * modules/openat (Depends-on): Likewise.
20114
20115 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20116
20117         * modules/byteswap: New file.
20118
20119 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20120
20121         * m4/byteswap.m4: New file.
20122
20123 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20124
20125         * lib/byteswap_.h: New file.
20126
20127 2005-04-25  Karl Berry  <karl@gnu.org>
20128
20129         * m4/gettext.m4: Update from GNU gettext 0.14.4.
20130
20131 2005-04-25  Albert Chin  <china@thewrittenword.com>
20132
20133         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
20134         Toolkit C bug.
20135
20136 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
20137
20138         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
20139         (func_ln_if_changed) Remove forcibly for no error message
20140         in case file does not exist.
20141
20142 2005-04-19  Simon Josefsson  <jas@extundo.com>
20143
20144         * gnulib-tool (Options): Make --symlink mean --symbolic.
20145
20146 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
20147
20148         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
20149
20150 2005-04-16  Simon Josefsson  <jas@extundo.com>
20151
20152         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
20153
20154 2005-04-15  Simon Josefsson  <jas@extundo.com>
20155
20156         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
20157
20158 2005-04-15  Simon Josefsson  <jas@extundo.com>
20159
20160         * gnulib-tool: Rename --symlink to --symbolic.
20161
20162 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
20163
20164         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
20165         symbolic links to files instead of copying/moving.  Add --aux-dir,
20166         specifying directory relative --dir where auxiliary build tools
20167         are placed.
20168
20169 2005-04-14  Bruno Haible  <bruno@clisp.org>
20170
20171         * modules/allocsa (License): Change to LGPL.
20172         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
20173
20174 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
20175
20176         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
20177         that "UTC +1 second" continues to work.  Problem reported
20178         by Dmitry V. Levin.
20179         (relunit_snumber): New rule.
20180         (relunit): Use it.
20181
20182 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
20183
20184         * lib/getdate.y (universal_time_zone_table): New constant.
20185         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
20186         universal_time_zone_table.
20187         (lookup_zone): Prefer universal_time_zone_table to
20188         local_time_zone_table, so that "GMT" time stamps are allowed in
20189         London during the summer.  Problem reported by Ian Abbott.
20190
20191 2005-04-12  Jim Meyering  <jim@meyering.net>
20192
20193         * lib/human.c (humblock): Set *options even when returning due to
20194         xstrtoumax conversion failure.  Thanks to a used-uninitialized
20195         warning from gcc-4.
20196
20197 2005-04-09  Jim Meyering  <jim@meyering.net>
20198
20199         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
20200         -Wuninitialized: initialize tm0.tm_year.
20201
20202 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
20203
20204         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
20205         count, since there's no maximum.  All uses changed.
20206         Add member dsts_seen.
20207         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
20208         not being INT_MAX.
20209         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
20210         Use pc_rels_seen to decide whther a date is absolute.
20211
20212         * lib/getdate.y (number): Don't overwrite year.
20213         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
20214         check.
20215
20216 2005-04-02  Simon Josefsson  <jas@extundo.com>
20217
20218         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
20219         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
20220
20221 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
20222
20223         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
20224         where no absolute path name can be longer than PATH_MAX.
20225
20226 2005-03-27  Jim Meyering  <jim@meyering.net>
20227
20228         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
20229
20230 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
20231
20232         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
20233         "one's complement" -> "ones' complement" in comment, as per Knuth.
20234         "value of type" -> "type or expression" in comment.
20235         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
20236
20237 2005-03-26  Jim Meyering  <jim@meyering.net>
20238
20239         Comment nits.
20240         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
20241         Correct typos: s/or/of/.
20242
20243 2005-03-26  Jim Meyering  <jim@meyering.net>
20244
20245         * modules/check-include-files: Move to ../ and rename to...
20246         * check-module: ...this.
20247
20248 2005-03-25  Jim Meyering  <jim@meyering.net>
20249
20250         * modules/xvasprintf (Files): Add xalloc.h.
20251
20252 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
20253
20254         * modules/gettext (Files): config/config.rpath ->
20255         build-aux/config.rpath
20256         * modules/iconv (Files): Likewise.
20257         Problem reported by Oskar Liljeblad.
20258
20259 2005-03-23  Jim Meyering  <jim@meyering.net>
20260
20261         * modules/check-include-files: New script to check for
20262         missing dependencies, multiple includes, etc.
20263
20264         * modules/c-strtold (Depends-on): Add xalloc.
20265         * modules/c-strtod (Depends-on): Add xalloc.
20266         * modules/hash (Depends-on): Add xalloc.
20267         (Files): Remove lib/xalloc.h.
20268
20269         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
20270         * modules/userspec (Files): Add lib/inttostr.h.
20271
20272 2005-03-23  Jim Meyering  <jim@meyering.net>
20273
20274         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
20275
20276 2005-03-22  Jim Meyering  <jim@meyering.net>
20277
20278         * modules/stat-macros: New module.
20279         * modules/canonicalize, modules/euidaccess, modules/file-type,
20280         * modules/filemode, modules/lchown, modules/makepath,
20281         * modules/rmdir, modules/stat: Depend on new stat-macros module
20282         rather than listing lib/stat-macros.h manually.
20283         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
20284
20285 2005-03-22  Jim Meyering  <jim@meyering.net>
20286
20287         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
20288
20289 2005-03-22  Bruno Haible  <bruno@clisp.org>
20290
20291         * config/srclist.txt: Replace target directory 'config' with
20292         'build-aux'.
20293         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
20294         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
20295         ../build-aux/.
20296
20297 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
20298
20299         * modules/chdir-long (Depends-on): Add mempcpy.
20300
20301         * modules/acl, modules/backupfile, modules/c-strtod,
20302         modules/c-strtold, modules/canon-host, modules/canonicalize,
20303         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
20304         modules/exclude, modules/exitfail, modules/file-type,
20305         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
20306         modules/getdate, modules/getline, modules/getpagesize,
20307         modules/getpass, modules/getugroups, modules/group-member,
20308         modules/hard-locale, modules/hash, modules/human, modules/idcache,
20309         modules/inttostr, modules/long-options, modules/makepath,
20310         modules/md5, modules/memcasecmp, modules/memcoll,
20311         modules/modechange, modules/mountlist, modules/path-concat,
20312         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
20313         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
20314         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
20315         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
20316         modules/strftime, modules/strndup, modules/strverscmp,
20317         modules/timespec, modules/unlocked-io, modules/userspec,
20318         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
20319         modules/yesno:
20320         Remove lib_SOURCES line from Makefile.am section, as this is now
20321         done automatically by the corresponding Autoconf macro.
20322
20323 2005-03-21  Jim Meyering  <jim@meyering.net>
20324
20325         Changes imported from coreutils.
20326
20327         * lib/cycle-check.c: Don't include xalloc.h.
20328
20329         * lib/path-concat.c: Don't include assert.h.
20330         (path_concat): Remove assertion that would have triggered
20331         for ABASE starting with more than one slash.
20332         Reported by Andreas Schwab.
20333
20334         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
20335         properly when ABASE is an absolute file name.
20336         Correct the description of this function.
20337         Include <assert.h>.
20338         Add an assertion and a test driver.
20339         This fixes a bug introduced on 2004-07-02.
20340         Andreas Schwab reported the resulting failure of cp --parents:
20341         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
20342
20343 2005-03-21  Jim Meyering  <jim@meyering.net>
20344
20345         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
20346         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
20347
20348 2005-03-21  Jim Meyering  <jim@meyering.net>
20349         and  Paul Eggert  <eggert@cs.ucla.edu>
20350
20351         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
20352         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
20353         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
20354         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
20355         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
20356         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
20357         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
20358         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
20359         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
20360         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
20361         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
20362         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
20363         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
20364         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
20365         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
20366         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
20367         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
20368         for these modules.
20369
20370 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
20371
20372         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
20373         (which shouldn't happen), generate nothing instead of returning 0
20374         immediately, so that nstrftime (NULL, ...) doesn't return 0.
20375
20376 2005-03-16  Bruno Haible  <bruno@clisp.org>
20377
20378         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
20379         HAVE_LONGLONG_64BIT.
20380
20381 2005-03-16  Bruno Haible  <bruno@clisp.org>
20382
20383         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
20384         HAVE_LONGLONG_64BIT.
20385
20386 2005-03-16  Bruno Haible  <bruno@clisp.org>
20387
20388         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
20389         HAVE_LONGLONG_64BIT.
20390
20391 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20392
20393         * lib/strftime.c (my_strftime): Prepend space to format so that we can
20394         reliably distinguish strftime failure from empty output on POSIX
20395         hosts.
20396
20397 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20398
20399         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
20400         (iconv_string): Don't guess a size-zero buffer, as that might cause
20401         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
20402         result would be 'too large', where 'too large' is (heuristically)
20403         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20404         overflow concerns.  This will prevent some unwanted malloc failures
20405         when the inputs are very large.
20406
20407 2005-03-15  Karl Berry  <karl@gnu.org>
20408
20409         * config/srclist.txt (config.rpath): from gettext.
20410         * config/config.rpath: update.
20411
20412 2005-03-15  Bruno Haible  <bruno@clisp.org>
20413
20414         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20415         to 'negate'.
20416
20417         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20418         variable.
20419
20420         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20421         results.
20422
20423 2005-03-14  Simon Josefsson  <jas@extundo.com>
20424
20425         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20426         <fx@gnu.org>.
20427
20428 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20429
20430         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20431         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20432         intprops.h.
20433         * lib/strtol.c: Likewise.
20434
20435 2005-03-14  Jim Meyering  <jim@meyering.net>
20436
20437         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20438         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20439         to be nonzero so that we (and caller) can detect the difference
20440         between a valid zero-length expansion and an error return, even
20441         when the underlying strftime fails before writing anything into
20442         that location.
20443
20444 2005-03-14  Bruno Haible  <bruno@clisp.org>
20445
20446         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20447         Update from GNU gettext 0.14.3.
20448
20449 2005-03-10  Jim Meyering  <jim@meyering.net>
20450
20451         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20452
20453 2005-03-10  Jim Meyering  <jim@meyering.net>
20454
20455         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20456         so that this module works on systems without fchdir.
20457
20458 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20459
20460         Factor int-properties macros into a single file, except for
20461         glibc-related files.
20462         * lib/intprops.h: New file.
20463         * lib/getloadavg.c: Include it instead of limits.h.
20464         (INT_STRLEN_BOUND): Remove.
20465         * lib/human.c: Include intprops.h.
20466         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20467         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20468         302/1000.
20469         * lib/inttostr.h: Include intprops.h instead of limits.h.
20470         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20471         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20472         for consistency with intprops.h.
20473         (time_t_is_integer, twos_complement_arithmetic): Use them.
20474         * lib/sig2str.h: Include <signal.h>, intprops.h.
20475         (INT_STRLEN_BOUND): Remove.
20476         * lib/strftime.c (TYPE_SIGNED): Remove.
20477         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20478         * lib/strtol.c: Adjust comments to match intprops.h.
20479         * lib/userspec.c: Include intprops.h.
20480         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20481         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20482         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20483         instead of rolling our own expressions.
20484         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20485
20486         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20487         instead of int.
20488         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20489         the right thing even if adding 1900 would overflow.  Similarly
20490         for tm_mon + 1 and tm_yday + 1.
20491         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20492         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20493         (DO_SIGNED_NUMBER): New macro.
20494         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20495
20496 2005-03-07  Bruno Haible  <bruno@clisp.org>
20497
20498         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20499
20500 2005-03-07  Bruno Haible  <bruno@clisp.org>
20501
20502         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20503
20504 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20505
20506         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20507         (func_import): Only replace files via --import when they have actually
20508         changed.
20509
20510 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20511
20512         * m4/mmap-anon.m4: New file.
20513         * m4/pagealign_alloc.m4: New file.
20514
20515 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20516             Bruno Haible  <bruno@clisp.org>
20517
20518         * modules/pagealign_alloc: New file.
20519         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20520
20521 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20522             Bruno Haible  <bruno@clisp.org>
20523
20524         * lib/pagealign_alloc.h: New file.
20525         * lib/pagealign_alloc.c: New file.
20526
20527 2005-03-03  Bruno Haible  <bruno@clisp.org>
20528
20529         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20530         Use an all-permissive copyright notice, recommended by RMS.
20531
20532 2005-03-02  Bruno Haible  <bruno@clisp.org>
20533
20534         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20535         of AIX, the replacement has to be done only after <string.h> is
20536         included, therefore not in config.h. stpncpy.h does the replacement,
20537         and stpncpy.c uses it.
20538
20539 2005-03-02  Bruno Haible  <bruno@clisp.org>
20540
20541         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20542         stpncpy.c uses it.
20543
20544 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20545
20546         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20547         The workaround isn't strictly needed for POSIX conformance, and
20548         it's too much of a pain to configure and maintain.  We'll ask
20549         people to fix their kernels instead.
20550         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20551         (NANOSLEEP_BUG_WORKAROUND): Remove.
20552         (xnanosleep): Remove the workaround.
20553
20554 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20555
20556         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20557         Reported by Derek Price.
20558         (Include): Add "timespec.h".
20559
20560         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20561
20562 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20563
20564         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20565         to detect nanosleep bug.
20566
20567 2005-03-01  Bruno Haible  <bruno@clisp.org>
20568
20569         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20570
20571 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20572
20573         * modules/gethrxtime: New file.
20574         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20575         (Depends-on): Add gethrxtime.
20576         (configure.ac): Add gl_XNANOSLEEP.
20577         (Makefile.am): Remove lib_SOURCES line.
20578
20579 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20580
20581         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20582         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20583
20584 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20585
20586         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
20587         * lib/timespec.h (gettime): Return void, since it always
20588         succeeds now.  All uses changed.
20589         * lib/gettime.c (gettime) Likewise.
20590         [HAVE_NANOTIME]: Prefer nanotime.
20591         Assume gettimeofday succeeds, as POSIX requires.
20592         Assime time () succeeds, since other code already does.
20593         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
20594         (timespec_subtract): Remove.
20595         (NANOSLEEP_BUG_WORKAROUND): New constant.
20596         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
20597         things considerably.  Use it only on GNU/Linux hosts, since the
20598         workaround shouldn't be needed elsewhere.
20599
20600 2005-02-24  Bruno Haible  <bruno@clisp.org>
20601
20602         * modules/gettext (Files): Add m4/glibc2.m4.
20603
20604 2005-02-24  Bruno Haible  <bruno@clisp.org>
20605
20606         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
20607         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
20608         * m4/progtest.m4:
20609         Update from GNU gettext 0.14.2.
20610         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
20611
20612 2005-02-24  Bruno Haible  <bruno@clisp.org>
20613
20614         * lib/localcharset.c: Update from GNU gettext 0.14.2.
20615         * lib/config.charset: Update from GNU gettext 0.14.2.
20616
20617 2005-02-24  Bruno Haible  <bruno@clisp.org>
20618
20619         * lib/gettext.h: Update from GNU gettext 0.14.2.
20620
20621 2005-02-23  Simon Josefsson  <jas@extundo.com>
20622
20623         * m4/iconvme.m4: New file.
20624
20625 2005-02-23  Jim Meyering  <jim@meyering.net>
20626
20627         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
20628         change.
20629         Thanks to Bruno Haible for catching it.
20630
20631 2005-02-22  Simon Josefsson  <jas@extundo.com>
20632
20633         * modules/iconvme: New file.
20634
20635         * MODULES.html.sh: Add iconvme.
20636
20637 2005-02-22  Simon Josefsson  <jas@extundo.com>
20638
20639         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
20640
20641 2005-02-22  Simon Josefsson  <jas@extundo.com>
20642
20643         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
20644
20645 2005-02-22  Jim Meyering  <jim@meyering.net>
20646
20647         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
20648         s/ifndef/ifdef/.
20649
20650 2005-02-20  Neil Conway  <neilc@samurai.com>
20651
20652         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
20653         returned by OSX/Darwin if the specified buffer is not large
20654         enough for the hostname.
20655
20656 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20657
20658         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
20659         pass it to _help, otherwise the latter coredumps trying to
20660         dereference state.root_argp.
20661
20662 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20663
20664         * modules/chdir-long (Depends-on): Add memrchr.
20665         * modules/memrchr (Files): Add lib/memrchr.h.
20666         (Include): "memrchr.h".
20667
20668 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20669
20670         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
20671
20672 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20673
20674         * lib/memrchr.h: New file.
20675         * lib/chdir-long.c: Include it.
20676         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
20677         Don't bother including stddef.h.
20678
20679 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
20680
20681         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
20682         inclusion.
20683         Include <sys/types.h>, for dev_t.
20684         (ME_DUMMY, ME_REMOTE): Move from here....
20685         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
20686         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
20687         Dmitry V. Levin.
20688         Include mountlist.h first, to test the interface.
20689
20690 2005-01-29  Bruno Haible  <bruno@clisp.org>
20691
20692         * lib/progname.c (program_name): Initialize.
20693         Needed when linking statically on MacOS X.
20694
20695 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20696
20697         Sync from coreutils.
20698         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
20699         (Depends-on): Add c-strtod.
20700         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
20701
20702 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20703
20704         Sync from coreutils.
20705         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
20706
20707         Remove files that are specific to coreutils.
20708         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
20709
20710 2005-01-28  Bruno Haible  <bruno@clisp.org>
20711
20712         * modules/javacomp: New file.
20713         * MODULES.html.sh (Java): Add javacomp.
20714
20715 2005-01-28  Bruno Haible  <bruno@clisp.org>
20716
20717         * m4/javacomp.m4: New file, from GNU gettext.
20718
20719 2005-01-28  Bruno Haible  <bruno@clisp.org>
20720
20721         * lib/javacomp.sh.in: New file, from GNU gettext.
20722         * lib/javacomp.h: New file, from GNU gettext.
20723         * lib/javacomp.c: New file, from GNU gettext.
20724
20725 2005-01-26  Simon Josefsson  <jas@extundo.com>
20726
20727         * lib/gai_strerror.c: Use GPL in header.
20728
20729 2005-01-26  Bruno Haible  <bruno@clisp.org>
20730
20731         * modules/javaexec: New file.
20732         * MODULES.html.sh (Java): Add javaexec.
20733
20734 2005-01-26  Bruno Haible  <bruno@clisp.org>
20735
20736         * m4/javaexec.m4: New file, from GNU gettext.
20737
20738 2005-01-26  Bruno Haible  <bruno@clisp.org>
20739
20740         * lib/javaexec.sh.in: New file, from GNU gettext.
20741         * lib/javaexec.h: New file, from GNU gettext.
20742         * lib/javaexec.c: New file, from GNU gettext.
20743
20744 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20745
20746         * modules/lchown (Depends-on): Remove lchown.h
20747
20748 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20749
20750         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
20751         must be defined if the header file was not found, in order
20752         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
20753
20754 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20755
20756         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
20757         initializers for struct pentry_state.
20758         (__argp_error): Check return value of __asprintf
20759         (__argp_failure): Translate error message
20760
20761         * lib/argp-parse.c: Removed braces around the expansion of N_()
20762
20763 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
20764
20765         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
20766         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
20767         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
20768         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
20769         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
20770         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
20771         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
20772         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
20773         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
20774         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
20775         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
20776         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
20777         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
20778         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
20779         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
20780         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
20781         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
20782         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
20783         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
20784         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
20785         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
20786         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
20787         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
20788         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
20789         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
20790         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
20791         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
20792         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
20793         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
20794         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
20795         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
20796         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
20797         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
20798         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
20799         xstrtol.m4, xstrtoumax.m4, yesno.m4:
20800         Use an all-permissive copyright notice, recommended by RMS.
20801
20802 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
20803
20804         * modules/chdir-long (Depends-on): Remove mempcpy.
20805
20806 2005-01-21  Jim Meyering  <jim@meyering.net>
20807
20808         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
20809         same value as for Solaris 9.
20810
20811         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
20812         component length.  This included changing the parameter to be
20813         of type `char *' rather than `char const *'.
20814         * lib/chdir-long.h (chdir_long): Update prototype.
20815
20816         * lib/openat.c (fdopendir, fstatat): New functions.
20817         * lib/openat.h: Include headers required for use of DIR and struct
20818         stat.
20819         [AT_SYMLINK_NOFOLLOW]: Define.
20820         (fdopendir, fstatat): Add prototypes.
20821
20822 2005-01-21  Bruno Haible  <bruno@clisp.org>
20823
20824         * modules/classpath: New file.
20825         * MODULES.html.sh (Java): Add classpath.
20826
20827 2005-01-21  Bruno Haible  <bruno@clisp.org>
20828
20829         * lib/classpath.h: New file, from GNU gettext.
20830         * lib/classpath.c: New file, from GNU gettext.
20831
20832 2005-01-20  Simon Josefsson  <jas@extundo.com>
20833
20834         * modules/version-etc-fsf: New file.
20835
20836 2005-01-20  Simon Josefsson  <jas@extundo.com>
20837
20838         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
20839         * lib/version-etc.c: Remove version_etc_copyright.
20840         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
20841         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
20842
20843 2005-01-20  Simon Josefsson  <jas@extundo.com>
20844
20845         * lib/base64.h (isbase64): Add.
20846
20847         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
20848         using a unsigned prototype, don't inline.
20849         (base64_decode): Use it.
20850
20851 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20852
20853         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
20854         it.
20855
20856 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20857
20858         * lib/save-cwd.c (save_cwd): Remove code to support the case
20859         where fchdir is missing or flaky.
20860
20861 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20862
20863         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
20864
20865 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
20866
20867         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
20868         AC_LIBSOURCES now does this.
20869         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
20870         with new ullong_max module.
20871
20872 2005-01-19  Bruno Haible  <bruno@clisp.org>
20873
20874         * modules/sh-quote: New file.
20875         * MODULES.html.sh (Executing programs): Add sh-quote.
20876
20877 2005-01-19  Bruno Haible  <bruno@clisp.org>
20878
20879         * lib/sh-quote.h: New file, from GNU gettext.
20880         * lib/sh-quote.c: New file, from GNU gettext.
20881
20882 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20883
20884         Merge from coreutils.
20885         * m4/ullong_max.m4: New file.
20886         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
20887         (gl_MACROS): Assume localeconv exists.
20888
20889 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20890
20891         Merge changes from coreutils, as described below in several
20892         changelogs dated today.
20893
20894         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
20895         (O_DIRECTORY): Remove; not needed here, since "." must be
20896         a directory.  All uses removed.
20897         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
20898         universal on Suns, and we also need to test for IRIX.
20899         Revamp code to use 'if' rather than '#if'.
20900         Avoid unnecessary comparison of cwd->desc to 0.
20901
20902         * lib/utimens.c (futimens): Robustify the previous patch, by checking
20903         for known valid error numbers rather than observed invalid ones.
20904
20905 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20906
20907         * modules/ullong_max: New file.
20908
20909         * modules/chdir-long, modules/openat: New files.
20910         * modules/save-cwd (Depends-on): Depend on chdir-long.
20911         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
20912
20913 2005-01-18  Jim Meyering  <jim@meyering.net>
20914
20915         Merge from coreutils.
20916         * m4/chdir-long.m4, m4/openat.m4: New files.
20917         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
20918         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
20919         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
20920         is sane and DOES follow symlinks.  Besides, testing 20 different
20921         systems found no broken chown implementations.
20922         Prompted by a change in rsync's copy of this macro.
20923         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
20924
20925         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
20926
20927         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
20928         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
20929         NULL-means-set-to-current-time semantics.
20930         Remove temporary file immediately, rather than waiting
20931         for configure's at-exit trap code to do it.
20932
20933 2005-01-18  Jim Meyering  <jim@meyering.net>
20934
20935         * lib/version-etc.c (version_etc_copyright): Update copyright date.
20936
20937         * lib/utimens.c (futimens): Account for the fact that futimes
20938         can also fail with errno == ENOSYS or errno == ENOENT.
20939         Patch from Dmitry V. Levin.
20940
20941         Change the name of the robust chdir function from chdir to chdir_long.
20942         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
20943         (restore_cwd): Use chdir_long, not chdir.
20944         * lib/chdir-long.c: Renamed from chdir.c.
20945         * lib/chdir-long.h: Renamed from chdir.h.
20946         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
20947         Hurd.
20948
20949 2005-01-18  Bruno Haible  <bruno@clisp.org>
20950
20951         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
20952         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
20953         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
20954         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
20955         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
20956         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
20957         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
20958         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
20959         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
20960         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
20961         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
20962         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
20963         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
20964         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
20965         Use an all-permissive copyright notice, recommended by RMS.
20966
20967 2005-01-18  Bob Proulx  <bob@proulx.com>
20968
20969         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
20970         simplify offsetof() macro construct to avoid compile failure with
20971         native HP-UX 11.0 ANSI C compiler.
20972
20973 2005-01-17  Bruno Haible  <bruno@clisp.org>
20974
20975         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
20976         redundant because stpncpy.m4 takes care of it.
20977
20978 2005-01-17  Bruno Haible  <bruno@clisp.org>
20979
20980         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
20981
20982 2005-01-17  Bruno Haible  <bruno@clisp.org>
20983
20984         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
20985         used.
20986
20987 2005-01-17  Bruno Haible  <bruno@clisp.org>
20988
20989         * lib/fwriteerror.h (fwriteerror): Change specification to include
20990         fclose.
20991         * lib/fwriteerror.c: Include <stdbool.h>.
20992         (fwriteerror): At the end, close the file stream. Record whether
20993         stdout was already closed.
20994
20995 2005-01-17  Bruno Haible  <bruno@clisp.org>
20996
20997         * lib/execute.c (environ): Declare if needed.
20998         * lib/pipe.c (environ): Likewise.
20999         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
21000
21001 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21002
21003         * modules/argp: Depend on vsnprintf
21004
21005 2005-01-10  Jim Meyering  <jim@meyering.net>
21006
21007         * modules/closeout (Depends-on): Add atexit.
21008
21009 2005-01-06  Bruno Haible  <bruno@clisp.org>
21010
21011         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
21012
21013 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
21014
21015         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
21016         definitions to be after all include files, to avoid collisions.
21017         Problem reported by Bob Proulx.
21018
21019 2005-01-04  Jim Meyering  <jim@meyering.net>
21020
21021         Changes imported from coreutils.
21022         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
21023         as the mkstemp template, use a temporary directory and an
21024         8.3-friendly template to avoid trouble on systems like DJGPP.
21025         Reported by Juan M. Guerrero via Stepan Kasal.
21026         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
21027         close. Remove the temporary directory right away, rather than waiting
21028         for configure's at-exit trap code to do it.
21029         Suggestion from Stepan Kasal.
21030
21031 2005-01-01  Simon Josefsson  <jas@extundo.com>
21032
21033         * gnulib-tool: Print #include directives when --import'ing.
21034
21035 2004-12-28  Simon Josefsson  <jas@extundo.com>
21036
21037         * tests/test-base64.c: Include required header files.  Remove
21038         unused variables.
21039
21040 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21041
21042         * modules/error (Depends-on): Remove gettext.
21043
21044 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21045
21046         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
21047         not needed.  This removes a dependency on the gettext module.
21048         [defined _LIBC]: Do not include <libintl.h>; not needed.
21049
21050 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21051
21052         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
21053         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
21054
21055 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21056
21057         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
21058         HAVE_DECL_STRTOLD.
21059
21060 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21061
21062         * modules/getdate (Depends-on): Remove alloca-opt.
21063
21064 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21065
21066         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
21067
21068 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21069
21070         * lib/argp-parse.c: Include <stddef.h>.
21071         (alignof, alignto): New macros.
21072         (parser_init): Don't assume that void * is aligned sufficiently
21073         for struct option.
21074
21075         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
21076         need to extend the stack.
21077         (YYINITDEPTH): New macro, so that the initial stack isn't overly
21078         large.
21079
21080 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21081
21082         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
21083
21084 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21085
21086         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
21087         (2004-10-24) change.  Apparently this was a false alarm.
21088
21089         * modules/getdate: Depend on alloca-opt, not alloca.
21090
21091 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21092
21093         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
21094         Remove now-obsolete comment about AIX.
21095         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
21096         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
21097         (YYMAXDEPTH): New macro.
21098
21099 2004-12-18  Simon Josefsson  <jas@extundo.com>
21100
21101         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
21102
21103 2004-12-18  Bruno Haible  <bruno@clisp.org>
21104
21105         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
21106
21107 2004-12-18  Bruno Haible  <bruno@clisp.org>
21108
21109         * lib/fatal-signal.c (fatal_signals): Make non-const.
21110         (init_fatal_signals): New function.
21111         (uninstall_handlers, install_handlers): Ignore signals that were set to
21112         SIG_IGN.
21113         (at_fatal_signal): Call init_fatal_signals.
21114         (init_fatal_signal_set): Likewise. Ignore signals that were set to
21115         SIG_IGN.
21116         Reported by Paul Eggert.
21117
21118 2004-12-18  Bruno Haible  <bruno@clisp.org>
21119
21120         * doc/alloca.texi: New file.
21121         * doc/alloca-opt.texi: New file.
21122
21123 2004-12-17  Jim Meyering  <jim@meyering.net>
21124
21125         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
21126         Otherwise, install-sh could exit with improper exit status when
21127         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
21128
21129 2004-12-16  Simon Josefsson  <jas@extundo.com>
21130
21131         * tests/test-base64.c: Add license.
21132
21133 2004-12-15  Stepan Kasal  <address@hidden>
21134
21135         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
21136
21137 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
21138
21139         * modules/getcwd (Files): Add m4/d-ino.m4.
21140         Suggested by Mark D. Baushke.
21141
21142 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21143
21144         * lib/getdate.y (textint): New member "negative".
21145         (time_zone_hhmm): New function.
21146         Expect 14 shift-reduce conflicts, not 13.
21147         (o_colon_minutes): New rule.
21148         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
21149         (yylex): Set the "negative" member of signed numbers.
21150
21151 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21152
21153         * doc/getdate.texi (Time of day items, Time zone items):
21154         Describe new formats +00:00, UTC+00:00.
21155
21156 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
21157
21158         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
21159         spurious "-l"s.  Problem reported by Stepan Kasal.
21160
21161 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
21162
21163         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
21164         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
21165
21166 2004-12-04  Simon Josefsson  <jas@extundo.com>
21167
21168         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
21169         Vandoorselaere <yoann@prelude-ids.org>.
21170
21171 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21172
21173         Changes imported from coreutils.
21174         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
21175         exist.
21176         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
21177
21178 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21179
21180         Changes imported from coreutils.
21181         * lib/hard-locale.c: Assume <locale.h> exists.
21182         Include "strdup.h".
21183         (GLIBC_VERSION): New macro.
21184         (hard_locale): Assume setlocale exists.
21185         Rewrite to avoid #ifdef.
21186         Use strdup rather than malloc + strcpy.
21187         * lib/human.c: Assume <locale.h> exists.
21188         (human_readable): Assume localeconv exists.
21189
21190 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21191
21192         * modules/hard-locale (Depends-on): Add strdup.
21193
21194 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
21195
21196         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
21197         convert T2, not T.  (Imported from libc.)
21198
21199 2004-11-30  Simon Josefsson  <jas@extundo.com>
21200
21201         * modules/restrict (License): Change to LGPL.
21202
21203 2004-11-30  Simon Josefsson  <jas@extundo.com>
21204
21205         * m4/restrict.m4: Add copyright and copying conditions.
21206
21207 2004-11-30  Simon Josefsson  <jas@extundo.com>
21208
21209         * m4/base64.m4: New file.
21210
21211 2004-11-30  Simon Josefsson  <jas@extundo.com>
21212
21213         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
21214         base64.
21215
21216         * tests/test-base64.c: New file.
21217
21218         * modules/base64: New file.
21219
21220 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21221
21222         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
21223         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
21224
21225         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
21226
21227 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21228
21229         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
21230         (__getcwd.c): Don't restore errno; glibc doesn't.
21231         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
21232         first, falling back to our code only if its results look suspicious.
21233         Ensure that the resulting buffer is only as large as necessary.
21234
21235         * lib/readutmp.c: Include readutmp.h first.
21236         Include <errno.h>, since readutmp.h no longer does that.
21237         * lib/readutmp.h: Don't include <errno.h>,
21238         <sys/param.h>, <time.h>; not needed to establish interface.
21239         (errno): Remove decl.
21240         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
21241         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
21242         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
21243
21244 2004-11-28  Simon Josefsson  <jas@extundo.com>
21245
21246         * lib/base64.h, base64.c: New file.
21247
21248 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
21249
21250         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
21251
21252 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
21253
21254         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
21255         (Depends-on): Remove pathmax, same.  Add mempcpy.
21256         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
21257         (Makefile.am): Append getcwd.h to lib_SOURCES.
21258         (Include): Add getcwd.h.
21259         (Maintainer): Change from Jim Meyering to "all, glibc",
21260         since getdate now uses intended-for-glibc code.
21261         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
21262         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
21263
21264 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21265
21266         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
21267         HP's ANSI C compiler.
21268         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
21269         Declaring int functions causes warnings on some modern systems and
21270         shouldn't be needed to compile on ancient ones.
21271         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
21272         defined.
21273
21274         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
21275         with the following changes.
21276         (__set_errno): Parenthesize properly.
21277         Include <stdbool.h>.
21278         (MIN, MAX, MATCHING_INO): New macros.
21279         (__getcwd): Define with prototype, not K&R form.
21280         Use heuristics to allocate default buffer on stack if possible.
21281         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
21282         behavior, and to avoid the PATH_MAX limit when computing
21283         ../../../../...
21284         Use MATCHING_INO to compare inode number to file.
21285         Check for arithmetic overflow in size calculations.
21286         Fix bug in reallocation of dot array that caused getcwd to fail
21287         on directories nested deeper than 75.
21288         Be more careful about saving errno on error.
21289         Do not use realloc; use only free+malloc, as this is a bit
21290         more flexible and avoids a needless copy operation.
21291         Do not inspect st_dev and st_ino for symbolic links; POSIX
21292         doesn't specify the latter.
21293         Check for closedir errors.
21294         Avoid needless casts.
21295         Use "#ifdef weak_alias" around weak_alias, to be like other
21296         glibc code.
21297         The following changes to getcwd.c have effect only when used in
21298         gnulib; they have no effect inside glibc proper.
21299         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
21300         as alloca isn't used.
21301         (alloca, __alloca): Likewise.
21302         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
21303         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21304         unconditionally, as gnulib assumes C89 or better.
21305         Do not include <sys/param.h>.
21306         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
21307         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
21308         better.
21309         (NULL) [!defined NULL]: Remove; we assume C89 or better.
21310         Include <dirent.h> in a way that is compatible with modern Autoconf.
21311         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
21312         New macros, if not already defined.
21313         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
21314         Use "_LIBC", not "defined _LIBC", for consistency.
21315         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
21316         a mempcpy module.
21317         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
21318         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
21319         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
21320         credit only to Jim Meyering and adjust the copyright dates.
21321         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
21322         <stdlib.h>, <unistd.h>, "pathmax.h".
21323         Instead, include "xgetcwd.h" (first) and "getcwd.h".
21324         (INITIAL_BUFFER_SIZE): Remove.
21325         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
21326
21327 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21328
21329         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
21330         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
21331         Use the _ONCE methods, for efficiency.
21332         Check for fcntl.h.  In test program, include <errno.h>
21333         and <fcntl.h> if available.  Remove old K&R cruft from
21334         test program.  Check for common errors in GNU/Linux,
21335         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
21336         don't do AC_LIBOBJ, as that's getcwd.m4's job.
21337         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
21338         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
21339         name accordingly.
21340         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
21341         accommodate new getcwd.c.
21342         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
21343         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
21344         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
21345         that's all we need now.
21346
21347 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21348
21349         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
21350         argp-parse.c depends on getopt internals, that means we should
21351         always use our getopt, to be on the safe side.
21352         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
21353         order not to spoil the result of an eventual previous invocation
21354         of gl_GETOPT_SUBSTITUTE.
21355
21356 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21357
21358         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
21359         redefinition warnings. To avoid them, include the defines
21360         in `#if !defined __need_getopt ... #endif'. The only place
21361         where __getopt_argv_const is used is in definitions
21362         of getopt_long and getopt_long_only below, which are as well
21363         protected by `#ifndef __need_getopt'.
21364         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
21365         __need_getopt after including <stdio.h> and <unistd.h> These
21366         headers might have defined it.
21367
21368 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21369
21370         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
21371
21372 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21373
21374         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
21375         (futimens): New function, which uses futimes if available.
21376         (futimens, utimens): Support timespec==NULL, with same semantics
21377         as utime and utimens.
21378         * lib/utimens.h (futimens): New decl.
21379
21380 2004-11-23  Jim Meyering  <jim@meyering.net>
21381
21382         * lib/getopt_.h: Remove trailing blanks.
21383
21384 2004-11-23  Jim Meyering  <jim@meyering.net>
21385
21386         * lib/__fpending.c: Add comment.
21387
21388 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
21389
21390         * modules/canonicalize (Depends-on): Add xreadlink.
21391         Problem reported by James Youngman.
21392
21393 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
21394
21395         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
21396         New macros.
21397         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
21398         optopt): Use them instead of invoking ## directly; otherwise, the
21399         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
21400
21401 2004-11-19  Bruno Haible  <bruno@clisp.org>
21402
21403         * lib/strtok_r.c: Move comments from here...
21404         * lib/strtok_r.h: ... to here.
21405
21406 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21407
21408         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21409         implementations that mishandle size_t overflow.
21410
21411 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21412
21413         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21414         might fail.  Problem reported by Yoann Vandoorselaere.
21415         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21416         implementations that mishandle size_t overflow.
21417
21418 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21419
21420         * modules/canon-host (Depends-on): Add strdup.
21421
21422 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21423
21424         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21425
21426 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21427
21428         * lib/canon-host.c: Include "strdup.h".
21429         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21430         Use strdup instead of malloc/strcpy to duplicate strings.
21431
21432         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21433         (human_space_before_unit): New constant.
21434         * lib/human.c (human_readable): Support it.
21435
21436         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21437         (xgetcwd): Set errno correctly when failing.
21438         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21439         the failure is actually due to a PATH_MAX problem.
21440
21441         Further getopt changes to make it more likely that glibc will
21442         buy the changes back.
21443         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21444         (getopt): Use it, so to preserve glibc semantic
21445         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21446         when compiling for libc.
21447         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21448         (getopt_long, getopt_long_only): Use it.
21449
21450         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21451         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21452         (getopt): Argv is now char * const *, as per standard.
21453         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21454         not char *__getopt_argv_const *.
21455         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21456         _getopt_long_only_r): Likewise.
21457         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21458         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21459         _getopt_long_r, _getopt_long_only_r): Likewise.
21460         * lib/getopt_.h (__getopt_argv_const): Remove.
21461         (getopt): Argv is now char * const *, as per standard.
21462
21463         * lib/getdate.y (tORDINAL): New token.
21464         (day, relunit): Allow it for relative times.
21465         (relative_time_table): Use tORDINAL for ordinals.
21466
21467 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21468
21469         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21470         Document that "second" isn't allowed as an ordinal number.
21471
21472 2004-11-16  Jim Meyering  <jim@meyering.net>
21473
21474         * modules/closeout (Depends-on): Add fpending.
21475
21476 2004-11-15  Jim Meyering  <jim@meyering.net>
21477
21478         * lib/closeout.c: Include "__fpending.h" once again.
21479         Include <stdbool.h>.
21480         (close_stdout): Don't fail just because stdout was closed initially,
21481         since some programs don't write to stdout in the normal course of
21482         operation (other than --version and --help), and we don't want this
21483         function to make e.g. `touch file >&-' fail.
21484         But do fail if it was closed and someone has tried to write to it.
21485         E.g., `printf foo >&-' must fail.
21486
21487 2004-11-13  Jim Meyering  <jim@meyering.net>
21488
21489         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21490
21491 2004-11-12  Simon Josefsson  <jas@extundo.com>
21492
21493         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21494         small doc fix is still pending.
21495
21496 2004-11-11  Simon Josefsson  <jas@extundo.com>
21497
21498         * modules/strtok_r: New file.
21499
21500         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21501         strtok_r.
21502
21503 2004-11-11  Simon Josefsson  <jas@extundo.com>
21504
21505         * m4/strtok_r.m4: New file.
21506
21507         * m4/getopt.m4: Replace opterr.
21508
21509 2004-11-11  Simon Josefsson  <jas@extundo.com>
21510
21511         * lib/strtok_r.h, strtok_r.c: New file.
21512
21513 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21514
21515         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21516         of replacing opterr, getopt, etc.  This should handle the
21517         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21518
21519 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21520
21521         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21522         we can stop lying to compilers about the constness of argv when we
21523         are compiled outside glibc.
21524         (getopt, getopt_long, getopt_long_only): Use it.
21525         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21526         _getopt_internal, getopt): Likewise.
21527         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21528         _getopt_long_only_r): Likewise.
21529         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21530         _getopt_long_r, _getopt_long_only_r): Likewise.
21531
21532         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21533         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21534         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21535         the other external symbols.
21536         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21537         declaration, since the above renaming now works around collisions.
21538
21539 2004-11-11  Jim Meyering  <jim@meyering.net>
21540
21541         * lib/linebreak.c: Remove trailing blanks.
21542         * lib/alloca_.h: Likewise.
21543         * lib/acosl.c: Likewise.
21544         * lib/euidaccess.c: Likewise.
21545         * lib/allocsa.h: Likewise.
21546
21547 2004-11-10  Simon Josefsson  <jas@extundo.com>
21548
21549         * m4/getaddrinfo.m4: New file.
21550
21551 2004-11-10  Simon Josefsson  <jas@extundo.com>
21552
21553         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21554
21555 2004-11-10  Simon Josefsson  <jas@extundo.com>
21556
21557         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21558         getaddrinfo.
21559
21560         * modules/getaddrinfo: New file.
21561
21562 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21563
21564         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21565
21566 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21567
21568         * lib/mktime.c (SHR): New macro, which is a portable
21569         substitute for >> that should work even on Crays.
21570         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21571         Problem reported by Mark D. Baushke in
21572         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21573         * lib/getdate.y (SHR): Likewise.
21574         (tm_diff): Use it.
21575         * lib/strftime.c (SHR): Likewise.
21576         (tm_diff): Use it.
21577         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21578         quote_these_too, so that right shifts are well defined.  All uses
21579         changed.
21580
21581 2004-11-10  Jim Meyering  <jim@meyering.net>
21582
21583         Ensure that no close failure goes unreported.
21584         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
21585         return early when it seems there's nothing to flush.
21586         Don't include __fpending.h.
21587
21588 2004-11-10  Jim Meyering  <jim@meyering.net>
21589
21590         * modules/closeout (Depends-on): Remove fpending.
21591
21592 2004-11-10  Jim Meyering  <jim@meyering.net>
21593
21594         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
21595
21596 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21597
21598         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
21599         gl_FUNC_STRFTIME.
21600         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
21601         and AC_REQUIRE when possible, to avoid duplicate checks.
21602         Check for <wchar.h>.
21603
21604 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21605
21606         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
21607
21608 2004-11-09  Bruno Haible  <bruno@clisp.org>
21609
21610         * m4/sockpfaf.m4: New file.
21611
21612 2004-11-05  Bruno Haible  <bruno@clisp.org>
21613
21614         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
21615         Reported by Mark D. Baushke <mdb@cvshome.org>.
21616
21617 2004-11-04  Bruno Haible  <bruno@clisp.org>
21618
21619         2004-09-11  Bruno Haible  <bruno@clisp.org>
21620                 * allocsa.valgrind: New file.
21621         2004-02-06  Bruno Haible  <bruno@clisp.org>
21622                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
21623                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
21624                 Reported by Christopher Seip <chris.seip@hp.com>.
21625
21626 2004-11-04  Bruno Haible  <bruno@clisp.org>
21627
21628         * modules/allocsa (Files): Add lib/allocsa.valgrind.
21629         (Makefile.am): Distribute it.
21630
21631 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
21632
21633         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
21634         with errno == ERANGE if the buffer is too small.
21635         Problem reported by Mark D. Baushke.
21636
21637 2004-11-03  Albert Chin  <china@thewrittenword.com>
21638             Paul Eggert  <eggert@cs.ucla.edu>
21639
21640         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
21641         equivalent, substitute $ac_type for equivalent type rather than
21642         blindly using uint32_t *always* which won't work if uint32_t is not
21643         available.  Define _UINT32_T to work around typedef of uint32_t if
21644         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
21645         2.5.1.
21646
21647 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21648
21649         * m4/jm-macros.m4: Sync from coreutils.
21650         (gl_MACROS): Check for mbrlen, for pathchk.
21651         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
21652
21653 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21654
21655         * lib/xreadlink.c (MAXSIZE): New macro.
21656         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
21657         size does not exceed MAXSIZE.  Avoid cast.
21658         As suggested by Mark D. Baushke in
21659         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
21660         if readlink fails with buffer size just under MAXSIZE, try again
21661         with MAXSIZE.
21662
21663 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21664
21665         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
21666
21667 2004-11-02  Derek R. Price  <derek@ximbiot.com>
21668         and  Paul Eggert  <eggert@cs.ucla.edu>
21669
21670         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
21671         (get_date): Overparenthesize to avoid GCC warning.
21672
21673 2004-11-02  Bruno Haible  <bruno@clisp.org>
21674
21675         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
21676         returns void.
21677
21678 2004-11-02  Bruno Haible  <bruno@clisp.org>
21679
21680         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
21681         function returns void.
21682
21683 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21684
21685         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
21686         fflush_unlocked, flockfile, funlockfile, funlockfile,
21687         fputs_unlocked, putc_unlocked.
21688
21689 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21690
21691         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21692         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
21693         already declared.
21694
21695 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21696
21697         * modules/getdate (Files): Add doc/getdate.texi.
21698         (Depends-on): Add setenv, xalloc.
21699
21700 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21701
21702         * lib/getdate.y: Add support for TZ="foo" within a date string.
21703         Fix some bugs near time_t boundaries.  Reject dates with
21704         out-of-range components, e.g., "Sept 31".
21705         Include <stdlib.h>, "setenv.h", "xalloc.h".
21706         (ISDIGIT_LOCALE): Remove; unused.
21707         Note that the TZ and time functions used here are not reentrant.
21708         (mktime_ok, get_tz): New functions.
21709         (TZBUFSIZE): New constant.
21710         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
21711         This requires that we sometimes generate our own TZ="XXX..." setting.
21712
21713 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21714
21715         * doc/getdate.texi: New file, from coreutils with modifications for
21716         the new TZ parsing.
21717
21718 2004-10-27  Derek R. Price  <derek@ximbiot.com>
21719
21720         * lib/mktime.c (not_equal_tm): Remove redundant check.
21721
21722 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21723
21724         * modules/regex (lib_SOURCES): Add regex.c.
21725         Reported by James Youngman in
21726         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
21727
21728 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21729
21730         * lib/getdate.y: Use Bison 1.875 features, and some minor
21731         code cleanups.  This change does not affect semantics.
21732         Don't include <stdlib.h>; no longer needed.
21733         Don't include unlocked-io.h; only the "#if TEST" code uses
21734         stdio, and performance isn't crucial there.
21735         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
21736         Bison 1.875 features as described below.
21737         All uses of "PC." replaced by "pc->".
21738         (YYSTYPE): Add a forward declaration.
21739         (yylex, yyerror): Use full prototypes in forward decls.
21740         Use "%pure-parser" rather than obsolescent "%pure_parser".
21741         Use %parse-param and %lex-param instead of obsolescent
21742         YYPARSE_PARAM and YYLEX_PARAM.
21743         (meridian_table, month_and_day_table, time_units_table,
21744         relative_time_table, time_zone_table, military_table,
21745         lookup_zone, lookup_word, get_date):
21746         Use NULL instead of 0 where appropriate.
21747         (to_hour): Avoid abort (), to avoid a dependency on
21748         stdlib.h.
21749         (yyerror, yylex): Now accepts parser_control * arg.
21750         (main) [TEST]: Use '\0' rather than 0 for char.
21751
21752 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21753
21754         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
21755
21756 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21757
21758         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
21759         It's now the caller's responsibility to handle the case where
21760         !HAVE_GETPAGESIZE && !defined getpagesize.
21761
21762         * lib/mktime.c (leapyear): Arg is long int, not int.
21763
21764 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
21765
21766         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
21767
21768 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
21769
21770         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
21771         missing.  Problem reported by James Youngman.
21772
21773 2004-10-16  Simon Josefsson  <jas@extundo.com>
21774
21775         * gnulib-tool: Fix comments.  Fix parse problem.
21776         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
21777
21778 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
21779
21780         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
21781         implementation of getopt_long.  Problem reported by Alexander Taler in:
21782         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
21783
21784 2004-10-15  Bruno Haible  <bruno@clisp.org>
21785
21786         * gnulib-tool: Untabify. Initialize supplied_libname.
21787         (func_usage): More homogenous output.
21788         (func_modules_transitive_closure, func_modules_to_filelist,
21789         func_emit_lib_Makefile_am): New functions.
21790         (func_import): New function, extracted from big case statement. Use
21791         func_get_license, func_modules_transitive_closure,
21792         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
21793         opt_lgpl. Don't use test -a, as it's not portable.
21794         (func_create_testdir): Use func_modules_transitive_closure,
21795         func_modules_to_filelist, func_emit_lib_Makefile_am.
21796
21797 2004-10-15  Bruno Haible  <bruno@clisp.org>
21798
21799         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
21800
21801 2004-10-15  Bruno Haible  <bruno@clisp.org>
21802
21803         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
21804         the portions belonging to each module.
21805         Suggested by Derek Robert Price <derek@ximbiot.com>.
21806
21807 2004-10-12  Simon Josefsson  <jas@extundo.com>
21808
21809         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21810         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
21811         to real functions.
21812
21813 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21814
21815         * modules/vsnprintf: New file.
21816
21817 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21818
21819         * m4/vsnprintf.m4: New file.
21820
21821 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21822
21823         * lib/vsnprintf.h: New file.
21824         * lib/vsnprintf.c: New file.
21825
21826 2004-10-11  Bruno Haible  <bruno@clisp.org>
21827
21828         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
21829         vsnprintf.
21830
21831 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
21832
21833         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
21834
21835 2004-10-07  Bruno Haible  <bruno@clisp.org>
21836
21837         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
21838         fits into the provided buffer.
21839
21840 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
21841
21842         * lib/diacrit.c, diacrit.h: Add GPL notice.
21843
21844         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
21845         notice.
21846         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
21847         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
21848         This avoids a potential constant-folding bug.
21849
21850 2004-10-05  Bruno Haible  <bruno@clisp.org>
21851
21852         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
21853         for the declaration of strsep.
21854
21855 2004-10-05  Bruno Haible  <bruno@clisp.org>
21856
21857         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
21858
21859 2004-10-04  Simon Josefsson  <jas@extundo.com>
21860
21861         * modules/memmem: New file.
21862         * tests/test-memmem.c: New file.
21863         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
21864
21865 2004-10-04  Simon Josefsson  <jas@extundo.com>
21866
21867         * m4/memmem.m4: New file.
21868
21869 2004-10-04  Simon Josefsson  <jas@extundo.com>
21870
21871         * lib/memmem.h: New file.
21872         * lib/memmem.c: New file, taken from glibc.
21873
21874 2004-10-04  Simon Josefsson  <jas@extundo.com>
21875
21876         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
21877         '#ifdef USE_UNLOCKED_IO'.
21878
21879 2004-10-04  Simon Josefsson  <jas@extundo.com>
21880
21881         * config/srclist.txt: Add memmem from glibc.
21882
21883 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21884
21885         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
21886
21887         * modules/argmatch, modules/argp, modules/closeout, modules/error,
21888         modules/exclude, modules/getdate, modules/getline,
21889         modules/getndelim2, modules/getpass, modules/getpass-gnu,
21890         modules/getusershell, modules/linebuffer, modules/md5,
21891         modules/mountlist, modules/posixtm, modules/readtokens,
21892         modules/readutmp, modules/regex, modules/sha1,
21893         modules/version-etc, modules/yesno:
21894         Remove dependency on unlocked-io.
21895
21896 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21897
21898         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
21899
21900         * m4/unlocked-io.m4: Add copyright notice.
21901         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
21902
21903 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21904
21905         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
21906         * lib/xmalloc.c (xmemdup): Likewise.
21907         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
21908         XFREE): Remove these long-obsolescent macros.
21909         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
21910         * lib/xstrdup.c: Remove.
21911
21912         * lib/regex.c (re_comp): Cast gettext return value to char *,
21913         Problem reported by Martin Neitzel via Mark D. Baushke.
21914
21915 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21916
21917         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
21918         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
21919         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
21920         regex.c, sha1.c, version-etc.c, yesno.c:
21921         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
21922         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
21923         the includer's responsibility.
21924
21925         Sync from coreutils.
21926
21927         * lib/modechange.c (mode_compile): Don't decrement a pointer that
21928         points to the start of a string, as the C Standard says the
21929         resulting behavior is undefined.
21930
21931         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
21932         simple -> simple_backups, numbered_existing ->
21933         numbered_existing_backups, numbered -> numbered_backups
21934         to avoid shadowing problems.  All uses changed.
21935         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
21936         * lib/backupfile.c (check_extension, numbered_backup):
21937         Rename locals to avoid shadowing 'basename'.
21938         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
21939         once.
21940
21941         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
21942         * lib/.cvsignore: Add getopt.h.
21943
21944 2004-10-04  Bruno Haible  <bruno@clisp.org>
21945
21946         * modules/README: New file.
21947         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
21948         not a module.
21949
21950 2004-10-02  Jim Meyering  <jim@meyering.net>
21951
21952         * lib/dirfd.h, getpagesize.h: Add copyright notice.
21953
21954 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21955
21956         * modules/strsep: New file.
21957
21958 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21959
21960         * m4/strsep.m4: New file.
21961
21962 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21963
21964         * lib/strsep.h: New file.
21965         * lib/strsep.c: New file.
21966
21967 2004-10-01  Simon Josefsson  <jas@extundo.com>
21968
21969         * lib/snprintf.c (snprintf): Handle size==0.
21970
21971 2004-10-01  Simon Josefsson  <jas@extundo.com>
21972             Bruno Haible  <bruno@clisp.org>
21973
21974         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
21975         (snprintf): Declare 'args'.
21976
21977 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
21978
21979         * lib/snprintf.c: Remove comments as to why each header is needed.
21980
21981 2004-10-01  Bruno Haible  <bruno@clisp.org>
21982
21983         * MODULES.html.sh: Add strsep.
21984
21985 2004-09-30  Simon Josefsson  <jas@extundo.com>
21986
21987         * modules/snprintf: New file.
21988
21989 2004-09-30  Simon Josefsson  <jas@extundo.com>
21990
21991         * m4/snprintf.m4: New file.
21992
21993 2004-09-30  Simon Josefsson  <jas@extundo.com>
21994
21995         * lib/snprintf.h, lib/snprintf.c: New files.
21996
21997 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21998
21999         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
22000         (hol_entry_help): Never translate an empty string.
22001         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
22002         * lib/argp.h (OPTION_NO_TRANS): New option.
22003
22004 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22005
22006         * modules/argp (Maintainer): Replace Simon Josefsson
22007         by Sergey Poznyakoff.
22008
22009 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22010
22011         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
22012         changes merged back into glibc.
22013
22014 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22015
22016         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
22017
22018 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
22019
22020         * lib/xvasprintf.c: Include xalloc.h.
22021         (xvasprintf): Use xalloc_die, not xmalloc_die.
22022
22023 2004-09-29  Bruno Haible  <bruno@clisp.org>
22024
22025         * modules/alloca-opt: New file, derived from modules/alloca.
22026         * modules/allocsa: Depend on alloca-opt instead of alloca.
22027         * modules/setenv: Likewise.
22028         * modules/vasnprintf: Likewise.
22029         * MODULES.html.sh: Add alloca-opt.
22030
22031 2004-09-28  Simon Josefsson  <jas@extundo.com>
22032
22033         * gnulib-tool: New parameter --lgpl, to asseert that modules are
22034         LGPL, and to replace license template from GPL to LGPL.
22035
22036 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22037
22038         * modules/dummy: Change license to LGPL.
22039
22040 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22041
22042         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
22043
22044 2004-09-24  Simon Josefsson  <jas@extundo.com>
22045
22046         * modules/minmax (License): Change from GPL to LGPL.
22047
22048 2004-09-23  Simon Josefsson  <jas@extundo.com>
22049
22050         * gnulib-tool (--import): Typo.
22051
22052 2004-09-23  Simon Josefsson  <jas@extundo.com>
22053
22054         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
22055
22056 2004-09-22  Bruno Haible  <bruno@clisp.org>
22057
22058         * modules/*: Add 'License' field.
22059         * gnulib-tool: Accept --extract-license option.
22060         (func_get_license): New function.
22061
22062 2004-09-21  Bruno Haible  <bruno@clisp.org>
22063
22064         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
22065         Reported by Simon Josefsson.
22066
22067 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22068
22069         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
22070         gl_AC_TYPE_LONG_LONG.
22071
22072 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22073
22074         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
22075
22076 2004-09-18  Simon Josefsson  <jas@extundo.com>
22077         and  Paul Eggert  <eggert@cs.ucla.edu>
22078
22079         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
22080         calls with autoreconf.  Define GL_LIB.
22081
22082 2004-09-14  Karl Berry  <karl@gnu.org>
22083
22084         * config/srclist.txt: unsync setenv.c, sigh.
22085
22086 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22087
22088         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
22089         Problem reported by Bruno Haible in:
22090         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
22091
22092 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22093
22094         * config/srclist.txt: Comment out argp-pvh.c.
22095
22096 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
22097
22098         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
22099         in case some system header has #define'd it.  Problem reported by
22100         Soeren D. Schulze in
22101         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
22102
22103 2004-09-09  Karl Berry  <karl@gnu.org>
22104
22105         * regex.[ch]: delete from the root.  These were supposed to be
22106                 synced with emacs cvs, but this has not happened for about
22107                 a year, and anyway nothing else uses emacs regex.[ch].
22108                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
22109                 lib/regex[.ch] is untouched.
22110
22111 2004-09-09  Bruno Haible  <bruno@clisp.org>
22112
22113         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
22114
22115 2004-09-09  Bruno Haible  <bruno@clisp.org>
22116
22117         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
22118         modifications.
22119         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
22120
22121 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22122
22123         * modules/xvasprintf: New file.
22124         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
22125
22126 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22127
22128         * lib/xvasprintf.h: New file.
22129         * lib/xvasprintf.c: New file.
22130         * lib/xasprintf.c: New file.
22131
22132 2004-09-08  Bruno Haible  <bruno@clisp.org>
22133
22134         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
22135
22136 2004-09-08  Bruno Haible  <bruno@clisp.org>
22137
22138         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
22139         length is > INT_MAX.
22140         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
22141         more.
22142
22143 2004-09-08  Bruno Haible  <bruno@clisp.org>
22144
22145         * lib/stdint_.h: New file, taken from GNU clisp.
22146
22147 2004-09-08  Bruno Haible  <bruno@clisp.org>
22148             Oskar Liljeblad  <oskar@osk.mine.nu>
22149
22150         * modules/stdint: New file.
22151         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
22152
22153 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22154
22155         Import from coreutils.
22156         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
22157         strings on unbounded length.  alloca's performance benefits aren't
22158         that important here.
22159         (V_STRDUP): Remove.
22160         (parse_with_separator): New function, with most of the internals
22161         of the old parse_user_spec.  Allow user to omit both user and group,
22162         for compatibility with FreeBSD.
22163         Clone only the user name, not the entire spec.
22164         Do not set *uid, *gid unless entirely successful.
22165         Avoid memory leak in some failing cases.
22166         Fix regression for USER.GROUP reported by Dmitry V. Levin in
22167         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
22168         (parse_user_spec): Rewrite to use parse_with_separator.
22169
22170 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22171
22172         * modules/userspec: Don't depend on alloca.
22173
22174 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22175
22176         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
22177
22178 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
22179
22180         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
22181         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
22182         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
22183
22184 2004-08-16  Simon Josefsson  <jas@extundo.com>
22185
22186         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
22187         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
22188         Add --dry-run for --import.
22189         Let user provided command line parameters override configure.ac
22190         settings.
22191
22192 2004-08-12  Simon Josefsson  <jas@extundo.com>
22193
22194         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
22195         as discussed with Paul Eggert in threads rooted at
22196         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
22197         and
22198         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
22199         Before, the test was empty, and relied on ELIDE_CODE in source
22200         code.)
22201         (gl_PREREQ_GETOPT): New macro.
22202         (gl_GETOPT): Use them.
22203
22204 2004-08-12  Simon Josefsson  <jas@extundo.com>
22205
22206         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
22207         * lib/getopt_.h: Renamed from getopt.h.
22208
22209 2004-08-12  Simon Josefsson  <jas@extundo.com>
22210
22211         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
22212         Change default library name from libfoo to libgnu.
22213         Now, if you have a configure.ac that says:
22214                 gl_SOURCE_BASE(gl)
22215                 gl_M4_BASE(gl/m4)
22216                 gl_MODULES(error getopt etcetera)
22217                 gl_INIT
22218         you can import all you need by running:
22219                 ../gnulib/gnulib-tool --import
22220
22221         * modules/getopt (Files): Rename getopt.h to getopt_.h.
22222         (Makefile.am): Rewrite, use logic from argz.
22223         (Include): Use <getopt.h> instead of "getopt.h".
22224
22225 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22226
22227         * modules/argp (Files): Add m4/unlocked-io.m4.
22228         (Depends-on): Add extensions.
22229
22230 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22231
22232         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
22233         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
22234         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
22235         Check for program_invocation_name, program_invocation_short_name,
22236         flockfile, funlockfile, features.h, _getopt_long_only_r.
22237
22238 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22239
22240         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
22241         its complicated substitute.
22242         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
22243         and program_invocation_name.
22244         (__argp_basename) [!_LIBC]: Remove; the only use was
22245         replaced by its body.
22246         (__argp_short_program_name): Change condition from
22247         !defined __argp_short_program_name to
22248         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
22249         to match argp-namefrob.h.
22250         (__argp_failure): Don't assume strerror_r returns char *.
22251         * lib/argp-parse.c (N_): Define unconditionally.
22252         (argp_default_options): Fill out initializers with 0 to avoid
22253         gcc warnings.
22254
22255 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22256
22257         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
22258         getopt1.c.
22259
22260 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22261
22262         Merge from coreutils.
22263
22264         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
22265
22266         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
22267         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
22268
22269 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22270
22271         Merge from coreutils.
22272
22273         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
22274         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
22275         for Reliant Unix 5.43.
22276
22277         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
22278         (union fooround): Use uintmax_t, not long int.
22279         The rest is a merge from libc:
22280         [defined _LIBC]: Include <shlib-compat.h>.
22281         (_obstack) [defined _LIBC]: Remove after 2.3.4.
22282
22283         * lib/settime.c (settime): Recode to avoid warning with
22284         Sun Forte C 6U2.
22285
22286         * lib/strverscmp.c: Convert to UTF-8.
22287
22288 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22289
22290         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
22291         m4/uintmax_t.m4.
22292
22293 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22294
22295         * modules/xalloc-die: New file.
22296         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
22297
22298         * modules/md5 (Files): Add m4/uint32_t.m4.
22299         * modules/sha1: Renamed from modules/sha.
22300         (Files):
22301         Rename lib/sha.h to lib/sha1.h.
22302         Rename lib/sha.c to lib/sha1.c.
22303         Rename m4/sha.m4 to m4/sha1.m4.
22304         (lib_SOURCES): Likewise.
22305         (configure.ac): Rename gl_SHA to gl_SHA1.
22306         (Include): sha.h -> sha1.h.
22307
22308 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22309
22310         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
22311         * m4/sha1.m4: Renamed from sha.m4.
22312         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
22313
22314 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22315
22316         * lib/obstack.h (obstack_empty_p):
22317         Don't assume that chunk->contents is suitably aligned.
22318         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
22319         Likewise. Problem reported by Benno in
22320         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
22321
22322         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
22323         readable.  This could be improved further but it'd take some work.
22324
22325 2004-08-08  Simon Josefsson  <jas@extundo.com>
22326
22327         * modules/xgethostname (Depends-on): Remove exit and error (not
22328         used).
22329
22330         * modules/getpass-gnu: Add getpass.h.
22331         (Depends-on): Add stdbool.
22332         * modules/getpass: Add getpass.h.
22333
22334 2004-08-08  Simon Josefsson  <jas@extundo.com>
22335
22336         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
22337         Check getpass declaration.
22338
22339 2004-08-08  Simon Josefsson  <jas@extundo.com>
22340
22341         * lib/xgethostname.c: Don't include error.h (not used).
22342
22343         * lib/getpass.h: Add.
22344         * lib/getpass.c: Include getpass.h first.
22345
22346 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
22347
22348         * lib/xalloc-die.c: New file.
22349         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
22350         All uses removed.
22351         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
22352         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
22353         xalloc-die.c.
22354         (_, N_, xalloc_die): Move to xalloc-die.c.
22355         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
22356         so that we needn't mess with xalloc_msg_memory_exhausted.
22357
22358         * lib/sha1.h: Renamed from sha.h.
22359         (SHA1_H): Renamed from _SHA_H.
22360         (sha1_ctx): Renamed from sha_ctx.
22361         (sha1_init_ctx): Renamed from sha_init_ctx.
22362         (sha1_process_block): Renamed from sha_process_block.
22363         (sha1_process_bytes): Renamed from sha_process_bytes.
22364         (sha1_finish_ctx): Renamed from sha_finish_ctx.
22365         (sha1_read_ctx): Renamed from sha_read_ctx.
22366         (sha1_stream): Renamed from sha_stream.
22367         (sha1_buffer): Renamed from sha_buffer.
22368         * lib/sha1.c: Likewise; renamed from sha.c.
22369         Do not include <sys/types.h>.
22370         Include <stddef.h> rather than <stdlib.h>.
22371
22372 2004-08-08  Bruno Haible  <bruno@clisp.org>
22373
22374         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
22375         FILESYSTEM_PREFIX_LEN.
22376         * lib/progreloc.c: Likewise.
22377         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
22378
22379 2004-08-06  Simon Josefsson  <jas@extundo.com>
22380
22381         * modules/progname (Depends-on): Don't depend on stdbool.
22382
22383 2004-08-06  Simon Josefsson  <jas@extundo.com>
22384
22385         * modules/getsubopt: New file.
22386         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
22387         getsubopt.
22388
22389 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22390
22391         More merge from coreutils.
22392
22393         * m4/utimens.m4, m4/utimecmp.m4: New files.
22394         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
22395         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
22396         prereq.m4, sha.m4: Import changes from coreutils.
22397
22398 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22399
22400         More merge from coreutils.
22401         * modules/raise, modules/readtokens0, modules/utimens:
22402         * modules/utimecmp, module/xnanosleep: New files.
22403         * modules/strftime: Add lib/strftime.h.
22404         Change include from <time.h> to "strftime.h".
22405         * modules/yesno: Add lib/yesno.h.
22406         * modules/backupfile: Remove lib/addext.c.
22407         * modules/euidaccess: Add stat-macros.h.
22408         * modules/canonicalize, modules/euidaccess,
22409         modules/filemode, modules/lchown, modules/makepath,
22410         modules/rmdir, modules/stat: Likewise.
22411
22412 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22413
22414         Merge from tar.
22415         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22416         SIZE_MAX is a valid preprocessor constant.
22417         (__argp_basename): Change from "#ifndef _LIBC"
22418         to "#ifndef __argp_short_program_name", so that
22419         we don't compile these functions for tar.
22420
22421         More merges from coreutils.
22422         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22423         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22424         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22425         * lib/addext.c: Remove; no longer needed.
22426         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22427         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22428         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22429         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22430         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22431         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22432         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22433         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22434         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22435         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22436         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22437         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22438         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22439         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22440         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22441         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22442         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22443         Import changes from coreutils.
22444
22445 2004-08-05  Simon Josefsson  <jas@extundo.com>
22446
22447         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22448
22449 2004-08-05  Simon Josefsson  <jas@extundo.com>
22450
22451         * m4/getsubopt.m4: New file.
22452
22453 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22454
22455         Merge from coreutils.
22456
22457         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22458         * m4/getcwd-path-max.m4: New files.
22459
22460         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22461         FILESYSTEM_PREFIX_LEN ->
22462         FILE_SYSTEM_PREFIX_LEN.
22463         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22464         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22465         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22466         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22467
22468         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22469         prerequisite modules now handle the DOS stuff.
22470         Don't check for unistd.h.
22471
22472 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22473
22474         Merge from coreutils.
22475
22476         * lib/.gdb-history: Remove; this doesn't belong here.
22477
22478         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22479         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22480         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22481         * lib/getcwd.c: New files.
22482
22483         * lib/dirname.h: Include <stdbool.h>.
22484         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22485         for consistency with POSIX terminology.  All uses changed.
22486         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22487         (strip_trailing_slashes): Use bool for booleans.
22488         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22489
22490         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22491         sometimes returns a positive errno value even when it succeeds.
22492         (print_errno_message) [!LIBC]: Fall back on strerror if
22493         __strerror_r fails.
22494
22495         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22496         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22497         (longest_relative_suffix): New function.
22498         (path_concat): Use it.  Assume first argument is not NULL.
22499         Port to DOS.  Omit redundant separators.
22500         Report an error instead of returning NULL.
22501         Use mempcpy instead of memcpy.
22502         (xpath_concat): Remove: not declared or used.
22503
22504         * lib/same.h: Include <stdbool.h>
22505         (same_name): Return bool, not int.
22506         * lib/same.c (same_name): Likewise.
22507         (errno): Don't declare; we assume C89 or better now.
22508
22509         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22510         if not already defined.
22511
22512         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22513         * lib/dup-safer.c (errno): Likewise.
22514
22515 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22516
22517         Merge from coreutils.
22518         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22519         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22520         * modules/path-concat: Don't depend on strdup.
22521
22522 2004-08-03  Simon Josefsson  <jas@extundo.com>
22523
22524         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22525         * lib/progname.h: Don't include stdbool.h.
22526
22527 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22528
22529         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22530         * MODULES.html.sh (func_all_modules): Remove fatal.
22531
22532 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22533
22534         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22535
22536 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22537
22538         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22539         working.
22540
22541 2004-08-02  Simon Josefsson  <jas@extundo.com>
22542
22543         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22544         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22545         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22546
22547 2004-08-01  Simon Josefsson  <jas@extundo.com>
22548
22549         * lib/xgetdomainname.c: Include stdlib.h, for free().
22550
22551 2004-07-19  Bruno Haible  <bruno@clisp.org>
22552
22553         * MODULES.html.sh (func_all_modules): Add dummy.
22554
22555 2004-07-16  Simon Josefsson  <jas@extundo.com>
22556
22557         * modules/dummy: New file.
22558
22559 2004-07-16  Simon Josefsson  <jas@extundo.com>
22560
22561         * lib/dummy.c: New file.
22562
22563 2004-07-16  Bruno Haible  <bruno@clisp.org>
22564
22565         * lib/backupfile.h: Add extern "C" for C++.
22566         * lib/closeout.h: Likewise.
22567         * lib/copy-file.h: Likewise.
22568         * lib/findprog.h: Likewise.
22569         * lib/full-write.h: Likewise.
22570         * lib/pathname.h: Likewise.
22571         * lib/progname.h: Likewise.
22572         * lib/stpcpy.h: Likewise.
22573         * lib/stpncpy.h: Likewise.
22574         * lib/strcase.h: Likewise.
22575         * lib/strstr.h: Likewise.
22576         * lib/xalloc.h: Likewise.
22577
22578         * lib/mbswidth.h: Add extern "C" for C++.
22579         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22580
22581 2004-07-13  Robert Millan  <robertmh@gnu.org>
22582
22583         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22584
22585 2004-07-09  Simon Josefsson  <jas@extundo.com>
22586
22587         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
22588         failed without this.)
22589
22590 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22591
22592         * modules/chown (Files): Add lib/fchown-stub.c, since
22593         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
22594
22595 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22596
22597         * lib/fchown-stub.c: New file.
22598
22599 2004-06-24  Jim Meyering  <jim@meyering.net>
22600
22601         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
22602
22603 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22604
22605         * modules/argz: Omit "#include".
22606
22607         * MODULES.html.sh (func_all_modules): Add calloc, to match
22608         2004-06-01 addition of calloc module.
22609
22610 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22611
22612         * m4/argz.m4: New file, which is autoupdated from libtool.
22613
22614 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22615
22616         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
22617         libtool.
22618
22619 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22620
22621         * config/srclist-update: Don't insist on "USA." before the
22622         close-comment, as libtool omits the period and puts the */ on a
22623         separate line.
22624         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
22625         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
22626
22627 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
22628
22629         * modules/argz: New file.
22630         * MODULES.html.sh (func_all_modules): Add argz.
22631
22632 2004-06-12  Jim Meyering  <jim@meyering.net>
22633         and  Paul Eggert  <eggert@cs.ucla.edu>
22634
22635         * modules/hash (Files): Add lib/xalloc.h.
22636         * modules/pipe (Depends-on): Add wait-process.
22637         * modules/stat (Depends-on): Add xalloc.
22638         * modules/userspec (Files): Add lib/userspec.h.
22639         * modules/xstrto
22640
22641         Upgrade from gettext-0.13.
22642         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
22643         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
22644         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
22645
22646 2004-06-10  Jim Meyering  <jim@meyering.net>
22647
22648         * lib/calloc.c: New file.
22649
22650 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
22651
22652         * lib/getdate.y (yylex): Allow space between sign and number.
22653         Problem reported by Dan Jacobson.
22654
22655 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22656
22657         Merge from coreutils CVS.
22658
22659         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
22660         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
22661         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
22662         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
22663         xstrtol.m4: Fix copyright date and/or serial number.
22664
22665         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
22666         See if we need an fchown replacement.
22667         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
22668         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
22669         and use the replacement function if we detect either defect.
22670
22671         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
22672         gl_UTIMECMP.
22673
22674 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22675         and  Jim Meyering  <jim@meyering.net>
22676
22677         Merge from coreutils CVS.
22678
22679         * lib/stat-macros.h: New file, with contents from file-type.h
22680         and coreutils' system.h.
22681         * lib/file-type.c: Include "stat-macros.h".
22682         * lib/file-type.h (file_type): Move all macro definitions to new file,
22683         stat-macros.h.
22684
22685         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
22686         Wrap old code with this conditional.
22687         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
22688         function that does not dereference symlinks.
22689         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
22690
22691         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
22692         dependency problems.
22693         (xreadlink): Accept new arg SIZE, for efficiency.
22694         All decls and uses changed.
22695         * lib/xreadlink.h: Include <stddef.h>, for size_t.
22696
22697         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
22698         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
22699
22700         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
22701         sysexits.h.
22702
22703 2004-06-01  Jim Meyering  <jim@meyering.net>
22704
22705         * m4/calloc.m4: New file.
22706
22707 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
22708
22709         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
22710         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
22711         Also, fix a typo in a diagnostic.
22712
22713 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22714
22715         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
22716         or AC_FUNC_REALLOC.
22717
22718 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22719
22720         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
22721         macros to be defined.
22722         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
22723         the allocator returns NULL because the requested size is zero.
22724
22725 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
22726
22727         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
22728         var.  Add comment explaining why libc still defines it.  This
22729         merges the following patch from glibc:
22730         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
22731
22732 2004-05-20  Andreas Schwab  <schwab@suse.de>
22733
22734         * m4/free.m4: Replace free if it not known to work, not the other
22735         way round.
22736
22737 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
22738
22739         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
22740         present in glibc since revision 1.1 of this file.
22741         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
22742         obstack_alignment_mask, obstack_alloc, obstack_base,
22743         obstack_blank, obstack_blank_fast, obstack_chunk_size,
22744         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
22745         obstack_grow0, obstack_init, obstack_int_grow,
22746         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
22747         obstack_next_free, obstack_object_size, obstack_ptr_grow,
22748         obstack_ptr_grow_fast, obstack_room): Remove declarations of
22749         nonexistent functions.
22750
22751 2004-05-18  Karl Berry  <karl@gnu.org>
22752
22753         * config/srclist.txt: break link for vasnprintf.c.
22754
22755 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22756
22757         Port obstack to the AS/400, where pointers are 16 bytes wide and
22758         you cannot cast an integer to a valid pointer.  This patch is
22759         currently waiting to be integrated into glibc; see
22760         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
22761
22762         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
22763         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
22764         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
22765         (struct obstack): temp member is now a union of a pointer and
22766         an integer, instead of an integer.  All integer uses changed.
22767         This does not affect the physical layout of struct obstack,
22768         except on hosts (like the AS/400) where the size or alignment of
22769         void * is greater than that of ptrdiff_t.
22770         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
22771         __STDC__)]: Store temporary in pointer member of union, not
22772         integer member.
22773         * lib/obstack.c: Include <stddef.h>, for offsetof.
22774         (struct fooalign): Remove; it doesn't need a name.
22775         (union fooround): Change double to long double, and add void *.
22776         (DEFAULT_ALIGNMENT): Use offsetof to compute.
22777         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
22778         not a macro.  Hence the values are always int; so remove all
22779         casts-to-int in uses.
22780
22781 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22782
22783         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
22784         we can get this patch merged into glibc.
22785
22786 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22787             Paul Eggert  <eggert@cs.ucla.edu>
22788
22789         * m4/argp: Depend on alloca.
22790
22791 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22792             Paul Eggert  <eggert@cs.ucla.edu>
22793
22794         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
22795         freecoding.
22796
22797 2004-05-17  Bruno Haible  <bruno@clisp.org>
22798
22799         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
22800         precision that consists of a '.' followed by an empty digit string.
22801         Patch by Tor Lillqvist <tml@iki.fi>.
22802
22803 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22804
22805         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
22806         for backward compatibility with older code.  We need our own
22807         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
22808         it under some other name, and our alloca.h will define it.
22809
22810 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22811             Derek Price  <derek@ximbiot.com>
22812
22813         * lib/alloca.c: Include <alloca.h>, to get our interface.
22814         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
22815         include <alloca.h> first.  Use C89 prototype for alloca; this
22816         requires including <stddef.h> for size_t.  Use extern "C" if C++.
22817         Use #elif for simplicity, since we can assume C89 now.
22818         Don't try to source the system alloca.h since it will not be found
22819         and to prevent recursively including its replacement.
22820         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
22821         * lib/regex.c: Likewise.
22822
22823 2004-05-16  Derek Price  <derek@ximbiot.com>
22824             Paul Eggert  <eggert@cs.ucla.edu>
22825
22826         getline cleanup.  This changes the getndelim2 API: both order of
22827         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
22828         no delimiter).
22829
22830         * lib/getline.c: Don't include stddef.h or stdio.h, since our
22831         interface does that.
22832         (getline): Always use getdelim, so that we don't have two
22833         copies of this code.
22834         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
22835         if available.
22836         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
22837         (GETNDELIM2_MAXIMUM): New macro.
22838         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
22839         instead of the old practice of delim2==0.  All callers changed.
22840         Return -1 on overflow, instead of returning junk.
22841         Do not set *linesize unless allocation succeeds.
22842         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
22843         that we include sys/types.h.
22844         * lib/getnline.h: Likewise.
22845         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
22846         (getndelim2): Reorder arguments.
22847         * lib/getnline.c (getnline, getndelim):
22848         Don't discard the NMAX argument.
22849         (getnline): Invoke getndelim, to avoid code duplication.
22850         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
22851         of (size_t) -1 by callers of the getnline family.
22852
22853 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22854
22855         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
22856         Check for gettimeofday.
22857         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
22858         Check for settimeofday, stime.
22859
22860 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22861
22862         * lib/nanosleep.c (suspended): Change its type from int to
22863         sig_atomic_t volatile.
22864         (first_call): Make it private to rpl_nanosleep, and have it
22865         be zero initially as that's a bit faster.
22866         (my_usleep): Round up fractional times instead of truncating them,
22867         as this is the usual meaning for 'sleep'.
22868
22869         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
22870         doesn't work.
22871         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
22872         (ENOSYS): Define if not defined.
22873         (settime): Fall back on stime if it exists and settimeofday fails.
22874         But don't bother with fallbacks if a method fails with errno == EPERM.
22875
22876 2004-05-11  Jim Meyering  <jim@meyering.net>
22877
22878         Prior to this change, the save_cwd caller required read access to the
22879         current directory on most systems (ones with the fchdir function).
22880
22881         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
22882         fails, try write-only, and finally, resort to using xgetcwd.
22883
22884 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
22885
22886         * lib/obstack.c, obstack.h: Import changes from libc.
22887
22888 2004-04-28  Bruno Haible  <bruno@clisp.org>
22889
22890         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
22891         also implicitly appends .exe to executables.
22892         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
22893         accepts Windows pathnames.
22894         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22895         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22896         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22897         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22898         Reported by Derek Robert Price <derek@ximbiot.com>.
22899
22900 2004-04-21  Karl Berry  <karl@gnu.org>
22901
22902         * config/srclist.txt (localcharset.c): break sync.
22903
22904 2004-04-20  Paul Eggert  <eggert@twinsun.com>
22905
22906         * m4/host-os.m4: Add a copyright notice.
22907
22908 2004-04-20  Jim Meyering  <jim@meyering.net>
22909
22910         Change UTILS_ to gl_ in AC_DEFINE'd names.
22911         Change utils_- and jm_-prefixed variables, too.
22912         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
22913         UTILS_FUNC_MKDIR_TRAILING_SLASH.
22914         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
22915
22916         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
22917         Don't emit trailing blanks.
22918         Also rename jm_-prefixed variables to have gl_ prefix.
22919
22920         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
22921         Also rename jm_-prefixed variables to have gl_ prefix.
22922
22923         * m4/jm-macros.m4: Reflect the renamings.
22924         * m4/prereq.m4: Likewise.
22925
22926 2004-04-20  Jim Meyering  <jim@meyering.net>
22927
22928         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
22929         memory.
22930
22931 2004-04-20  Jim Meyering  <jim@meyering.net>
22932             Bruno Haible  <bruno@clisp.org>
22933
22934         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
22935         memory when realloc fails.
22936
22937 2004-04-19  Jim Meyering  <jim@meyering.net>
22938
22939         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
22940         now that readutmp.c may call `free (0)'.
22941
22942 2004-04-19  Bruno Haible  <bruno@clisp.org>
22943
22944         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
22945         * m4/inttypes_h.m4: Likewise.
22946         * m4/stdint_h.m4: Likewise.
22947         * m4/intmax_t.m4: Likewise.
22948         * m4/uintmax_t.m4: Likewise.
22949
22950 2004-04-18  Jim Meyering  <jim@meyering.net>
22951
22952         * m4/prereq.m4: Don't forbid jm_ prefix.
22953
22954         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
22955         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
22956         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
22957         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
22958         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
22959         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
22960         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
22961         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
22962         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
22963         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
22964         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
22965         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
22966         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
22967         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
22968         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
22969         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
22970         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
22971         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
22972         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
22973
22974 2004-04-18  Jim Meyering  <jim@meyering.net>
22975
22976         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
22977         failure, don't leak memory and do call END_UTMP_ENT.
22978
22979 2004-04-16  Jim Meyering  <jim@meyering.net>
22980
22981         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
22982         coreutils' stat program.
22983         (gl_PREREQ): Don't require jm_PREREQ_STAT.
22984
22985 2004-04-11  Paul Eggert  <eggert@twinsun.com>
22986
22987         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
22988         C89.
22989         (CHAR_BIT): Remove, since we assume C89.
22990         Include <stdint.h> if available, as per current Autoconf CVS advice.
22991
22992 2004-03-31  Jim Meyering  <jim@meyering.net>
22993
22994         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
22995         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
22996         * m4/xalloc.m4: Likewise.
22997
22998 2004-03-30  Paul Eggert  <eggert@twinsun.com>
22999
23000         Merge from coreutils.
23001
23002         * m4/inttostr.m4: New file.
23003         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
23004         Require AM_STDBOOL_H and gl_TIMESPEC instead.
23005         Require gl_CLOCK_TIME.
23006         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
23007
23008 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23009
23010         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
23011         not bool, to be more consistent with Unix conventions.
23012         Suggested by Bruno Haible.
23013
23014         Merge from coreutils.
23015
23016         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
23017         * lib/umaxtostr.c: New files.
23018
23019         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
23020         the usual <time.h> dance.
23021         (get_date): Change signature to support fractional time stamps.
23022         All callers changed.
23023         * lib/getdate.y: Include "getdate.h" first, as we can now
23024         assume C89 and don't need to worry about 'const'.
23025         Similarly, include "unlocked-io.h" near start, not in middle.
23026         Include <limits.h>.
23027         (textint.value): Use long int rather than int.
23028         (textint.digits): Use size_t rather than int.
23029         (BILLION, LOG10_BILLION): New constants.
23030         (parser_control): New member rel_ns.  Members day_ordinal,
23031         time_zone, month, day, hour, minutes, rel_year, rel_month,
23032         rel_day, rel_hour, rel_minutes, rel_seconds
23033         are now long int, not int.  Member seconds is now struct timespec,
23034         not int.  New member timespec_seen.  Members dates_seen, days_seen,
23035         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
23036         not int.
23037         (%union.intval): Now long int, not int.
23038         New member timespec.
23039         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
23040         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
23041         (spec): Now is a timespec or an item list.
23042         (timespec, items): New nonterminals.
23043         (time, rel, relunit, number, get_date):
23044         Add support for fractional seconds.
23045         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
23046         (gmtime, localtime, mktime): Remove decls; not needed with C89.
23047         (to_hour): First arg is now long int, not int.
23048         (to_year): Returns long int, not int.
23049         Don't treat year -70 like 70.
23050         (tm_diff): Returns long int, not int.
23051         (lookup_word): Use bool instead of int when appropriate.
23052         (yylex): Use size_t for count, not int.
23053         Detect overflow when parsing large integer constants.
23054         Add support for fractions.
23055         (get_date): Make pointers 'const' if possible.
23056         Use more-portable code to detect integer overflow.
23057         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
23058         Don't use ctime; it's not reliable if the year has >4 digits.
23059
23060         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
23061         This is for compatibility with BSD.
23062
23063         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
23064         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
23065         From coreutils' system.h.
23066
23067         * lib/userspec.c: Don't include "posixver.h".
23068         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
23069         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
23070         compatible extension.  Simplify code by removing a boolean int
23071         that was always nonzero if a string was nonnull.
23072
23073 2004-03-30  Jim Meyering  <jim@meyering.net>
23074
23075         Merge from coreutils.
23076
23077         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
23078         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
23079         on some systems one must include <grp.h> before it.
23080         Reported by Christian Krackowizer.
23081
23082 2004-03-30  Jim Meyering  <jim@meyering.net>
23083
23084         Merge from coreutils.
23085
23086         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
23087
23088         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
23089         an empty input stream.
23090
23091         * lib/readtokens.c: Include <stdbool.h>.
23092         (readtoken): Use `size_t' rather than int/long.
23093         All callers adjusted.
23094         Use `bool' rather than `int' where appropriate.
23095         Use memset rather than an explicit loop.
23096         Use x2nrealloc rather than xrealloc.
23097         Allow the use of `\0' as a delimiter.
23098         (readtokens): Likewise.
23099         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
23100
23101 2004-03-30  Jim Meyering  <jim@meyering.net>
23102
23103         * m4/realloc.m4: Remove file, since now it does no more than
23104         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
23105         the `configure.ac' section of module/realloc.
23106         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
23107
23108 2004-03-30  Bruno Haible  <bruno@clisp.org>
23109
23110         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
23111         nonnull.
23112
23113 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23114
23115         Merge changes to getloadavg.c from coreutils and Emacs.
23116
23117         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
23118         Define to an expression, not to the empty string.
23119         Include cloexec.h and xalloc.h.
23120         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
23121         Use set_cloexec_flag rather than rolling our own.
23122         * lib/cloexec.c, lib/cloexec.h: New files.
23123
23124 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23125
23126         * m4/cloexec.m4: New file.
23127
23128 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23129
23130         * lib/getopt.h: Sync with libc CVS.
23131
23132 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23133             Bruno Haible  <bruno@clisp.org>
23134
23135         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
23136         mbswidth.
23137
23138 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23139             Bruno Haible  <bruno@clisp.org>
23140
23141         * lib/mbswidth.h: Include <wchar.h> only if
23142         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
23143         <wchar.h>.
23144         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
23145
23146 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23147
23148         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
23149         Sync with libc CVS.
23150         * lib/getopt_int.h: New file, also synced from libc.
23151
23152 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23153
23154         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
23155         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
23156         Bring back getopt.c, getopt.h, getopt1.c.
23157
23158 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23159
23160         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
23161         All uses changed.  Check for sa_sigaction member; this fixes
23162         a bug first reported by Jason Andrade in
23163         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23164
23165 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23166
23167         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
23168         '#if' expressions.  Unlike the code it replaces, it does not
23169         depend on (defined _SC_PAGESIZE).  However, it does depend on
23170         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
23171         first reported by Jason Andrade in
23172         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23173
23174 2004-02-25  Simon Josefsson  <jas@extundo.com>
23175
23176         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
23177
23178 2004-02-25  Simon Josefsson  <jas@extundo.com>
23179
23180         * lib/strdup.h: New file.
23181         * lib/strdup.c: Include it.
23182         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
23183         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
23184
23185 2004-02-23  Karl Berry  <karl@gnu.org>
23186
23187         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
23188         (from fencepost.gnu.org:/gd/gnuorg).
23189
23190 2004-02-23  Karl Berry  <karl@gnu.org>
23191
23192         * config/srclistvars.sh (GNUORG) [karl]: redefine.
23193         * config/srclist.txt: add maintain/standards documents.
23194
23195 2004-02-18  Bruno Haible  <bruno@clisp.org>
23196
23197         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
23198         Reported by Derek Robert Price <derek@ximbiot.com>.
23199
23200 2004-02-16  Karl Berry  <karl@gnu.org>
23201
23202         * config/mkinstalldirs, install-sh: update from automake.
23203
23204 2004-02-06  Karl Berry  <karl@gnu.org>
23205
23206         * m4/po.m4: update from gettext 0.14.1.
23207
23208 2004-02-06  Karl Berry  <karl@gnu.org>
23209
23210         * lib/config.charset: update from gettext 0.14.1.
23211
23212 2004-02-05  Paul Eggert  <eggert@twinsun.com>
23213
23214         Add comments and code, prompted by suggestions from Bruno Haible
23215         for sh-quote.
23216         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
23217         describing the enum quoting_style values.
23218         * lib/quotearg.c (quotearg_alloc): New function.
23219         (quotearg_buffer_restyled): Treat lone { and } as special.
23220         Treat = as special.  Work around bug with older shells
23221         that "see" a '\' that is really the 2nd byte of a multibyte char.
23222         Quote empty string with shell_quoting_style.
23223
23224 2004-02-03  Bruno Haible  <bruno@clisp.org>
23225
23226         * m4/pipe.m4: New file, from GNU gettext.
23227
23228 2004-02-03  Bruno Haible  <bruno@clisp.org>
23229
23230         * lib/pipe.h: New file, from GNU gettext.
23231         * lib/pipe.c: New file, from GNU gettext.
23232
23233 2004-01-27  Bruno Haible  <bruno@clisp.org>
23234
23235         * m4/execute.m4: New file, from GNU gettext.
23236
23237 2004-01-27  Bruno Haible  <bruno@clisp.org>
23238
23239         * lib/execute.h: New file, from GNU gettext.
23240         * lib/execute.c: New file, from GNU gettext.
23241         * lib/w32spawn.h: New file, from GNU gettext.
23242
23243 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23244
23245         Merge from diffutils.
23246
23247         * lib/file-type.c (file_type): Add typed memory objects.
23248         * lib/file-type.h (S_TYPEISTMO): New macro.
23249
23250         * lib/c-stack.h (c_stack_action): Remove argv argument.
23251         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
23252         (die): Don't calculate message unless segv_action returns.
23253         (get_stack_location, min_address_from_argv, max_address_from_argv,
23254         volatile stack_base, volatile_stack_size): Remove.
23255         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
23256         that every segmentation violation is a stack overflow.  (Ouch!)
23257         See Debian bug 136249 (still outstanding) for more info about why
23258         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
23259
23260 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23261
23262         Exit-status fix from coreutils.
23263
23264         Use exit_failure consistently in place of EXIT_FAILURE,
23265         so that program exit statuses are consistent on failure.
23266
23267         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
23268         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
23269         * lib/argmatch.h: Comment fix to match the above.
23270         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
23271         Now a macro referring to exit_failure, instead of a separate
23272         variable.  Include "exitfail.h" to get it.
23273         * lib/xstrtol.h: Include "exitfail.h".
23274         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
23275
23276         * lib/long-options.c (parse_long_options): Use prototype
23277         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
23278         for clarity.
23279
23280 2004-01-21  Jim Meyering  <jim@meyering.net>
23281
23282         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
23283         so as not to conflict with a different-sized __mktime_internal
23284         function in GNU libc.
23285         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
23286         Problem building statically-linked `ls' reported by Michael Brunnbauer.
23287
23288 2004-01-20  Karl Berry  <karl@gnu.org>
23289
23290         * config/config.guess: update from config.
23291
23292         * config/srclistvars.sh: GNUWWWLICENSES for karl.
23293
23294 2004-01-20  Bruno Haible  <bruno@clisp.org>
23295
23296         Safer stack allocation.
23297         * lib/setenv.c: Include allocsa.h.
23298         (alloca): Remove fallback definition.
23299         (freea): Remove macro.
23300         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
23301         instead of freea.
23302
23303 2004-01-20  Bruno Haible  <bruno@clisp.org>
23304
23305         * m4/eealloc.m4: New file, from GNU gettext.
23306
23307 2004-01-20  Bruno Haible  <bruno@clisp.org>
23308
23309         * m4/allocsa.m4: New file, from GNU gettext.
23310
23311 2004-01-20  Bruno Haible  <bruno@clisp.org>
23312
23313         * lib/xallocsa.h: New file, from GNU gettext.
23314         * lib/xallocsa.c: New file, from GNU gettext.
23315
23316 2004-01-20  Bruno Haible  <bruno@clisp.org>
23317
23318         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
23319
23320 2004-01-20  Bruno Haible  <bruno@clisp.org>
23321
23322         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
23323         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
23324         specially.
23325
23326 2004-01-20  Bruno Haible  <bruno@clisp.org>
23327
23328         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
23329         patch.
23330
23331 2004-01-20  Bruno Haible  <bruno@clisp.org>
23332
23333         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
23334
23335 2004-01-20  Bruno Haible  <bruno@clisp.org>
23336
23337         * lib/eealloc.h: New file.
23338
23339 2004-01-20  Bruno Haible  <bruno@clisp.org>
23340
23341         * lib/binary-io.h: Avoid warnings on Cygwin.
23342
23343 2004-01-20  Bruno Haible  <bruno@clisp.org>
23344
23345         * lib/allocsa.h: New file, from GNU gettext.
23346         * lib/allocsa.c: New file, from GNU gettext.
23347
23348 2004-01-18  Karl Berry  <karl@gnu.org>
23349
23350         * doc/gpl.texi, doc/lgpl.texi: new files.
23351
23352 2004-01-18  Karl Berry  <karl@gnu.org>
23353
23354         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
23355         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
23356
23357 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23358
23359         Merge from coreutils.
23360
23361         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
23362         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
23363         (gl_DEFAULT_POSIX2_VERSION): Move
23364         the documentation from 'configure' into 'config.hin',
23365         so that 'configure --help' isn't burdened by it and
23366         we don't have to worry about its formatting there.
23367         Reword the documentation so that it's more succinct
23368         and can be run together into a single paragraph.
23369         * m4/same.m4 (gl_SAME): Check for pathconf.
23370
23371 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23372
23373         Merge from coreutils.
23374
23375         * lib/posixver.c: Include posixver.h.
23376
23377         * lib/same.c: Include <stdbool.h>, <limits.h>.
23378         (_POSIX_NAME_MAX): Define if not defined.
23379         (MIN): New macro.
23380         (same_name): If file names are silently truncated, report
23381         that the file names are the same if they are the same after
23382         the silent truncation.
23383
23384         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
23385         conversion function.
23386         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
23387         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
23388         longer needed.
23389
23390 2004-01-15  Jim Meyering  <jim@meyering.net>
23391
23392         Merge from coreutils.
23393
23394         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
23395         if no library is required.
23396         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
23397         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
23398         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
23399         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
23400         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
23401         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
23402         value, $ac_cv_search_crypt, if it's "none required".
23403         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23404         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23405         not gl_FUNC_GETLOADAVG.
23406         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23407         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23408
23409 2004-01-15  Jim Meyering  <jim@meyering.net>
23410
23411         Merge from coreutils.
23412
23413         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23414         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23415         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23416
23417         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23418         optional configure-time default.
23419
23420         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23421
23422         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23423
23424 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23425
23426         Merge from coreutils.
23427
23428         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23429         value, $ac_cv_search_nanosleep, if it's "none required".
23430
23431 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23432
23433         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23434         with like-named macro in fnmatch.c.
23435         (EXT): Use an internal constant instead.
23436
23437         Merge fnmatch patches from glibc.
23438         * lib/fnmatch.c (mbsinit): Remove define.
23439         Add libc_hidden_ver (__fnmatch, fnmatch).
23440         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23441         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23442
23443 2004-01-14  Karl Berry  <karl@gnu.org>
23444
23445         * config/install-sh: update from automake.
23446
23447 2004-01-13  Karl Berry  <karl@gnu.org>
23448
23449         * config/install-sh: update from automake.
23450
23451 2004-01-09  Karl Berry  <karl@gnu.org>
23452
23453         * config/install-sh: update from automake.
23454
23455 2004-01-05  Karl Berry  <karl@gnu.org>
23456
23457         * config/config.{sub,guess}: update from config.
23458
23459 2003-12-31  Karl Berry  <karl@gnu.org>
23460
23461         * config/depcomp: update from automake.
23462
23463 2003-12-14  Karl Berry  <karl@gnu.org>
23464
23465         * lib/config.charset: update from gettext-runtime.
23466
23467 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23468
23469         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23470         Bug reported by Alfred M. Szmidt.
23471
23472 2003-12-03  Bruno Haible  <bruno@clisp.org>
23473
23474         * m4/gettext.m4: Upgrade from gettext-0.13.
23475         * m4/po.m4: Upgrade from gettext-0.13.
23476         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23477         * m4/intmax.m4: New file, from gettext-0.13.
23478         * m4/printf-posix.m4: New file, from gettext-0.13.
23479
23480 2003-11-29  Karl Berry  <karl@gnu.org>
23481
23482         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23483
23484 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23485             Bruno Haible  <bruno@clisp.org>
23486
23487         * lib/printf-parse.h: Don't include sys/types.h.
23488         (ARG_NONE): New macro.
23489         (char_directive): Change type of *arg_index fields to size_t.
23490         * lib/printf-parse.c: Don't include sys/types.h.
23491         (SSIZE_MAX): Remove macro.
23492         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23493         Remove unnecessary overflow check.
23494         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23495         fields.
23496
23497 2003-11-25  Bruno Haible  <bruno@clisp.org>
23498
23499         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23500
23501 2003-11-25  Bruno Haible  <bruno@clisp.org>
23502
23503         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23504         gt_TYPE_SSIZE_T.
23505
23506 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23507
23508         * modules/alloca: Remove dependency on xalloc.
23509
23510 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23511
23512         * lib/alloca.c: Remove dependency on xalloc module.
23513         (xalloc_die): Remove.
23514         (memory_full) [!defined emacs]: New macro.
23515         [!defined emacs]: Don't include xalloc.h.
23516         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23517         address arithmetic overflows.  Change datatypes a bit to avoid
23518         unnecessary casts.
23519
23520 2003-11-22  Jim Meyering  <jim@meyering.net>
23521
23522         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23523         s/size/size_t/.
23524
23525 2003-11-21  Karl Berry  <karl@gnu.org>
23526
23527         * config/config.{sub,guess}: update from config.
23528
23529 2003-11-18  Karl Berry  <karl@gnu.org>
23530
23531         * config/config.{sub,guess}: update from config.
23532
23533         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23534
23535 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23536
23537         * README: Mention that S+T cannot overflow if S is the size of
23538         an existing object and T is sufficiently small.
23539
23540 2003-11-17  Jim Meyering  <jim@meyering.net>
23541
23542         On systems without utime and without a utimes function capable of
23543         dealing with a NULL struct utimbuf* argument, this utime replacement
23544         could -- in unusual circumstances -- leak a file descriptor.
23545         * lib/utime.c: Include <unistd.h> and <errno.h>.
23546         (utime_null): Be sure to close `fd' and to preserve errno.
23547         Reported by Geoff Collyer via Arnold Robbins.
23548
23549 2003-11-17  Bruno Haible  <bruno@clisp.org>
23550
23551         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23552         (Depends-on): Add xsize.
23553
23554 2003-11-17  Bruno Haible  <bruno@clisp.org>
23555
23556         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23557
23558 2003-11-17  Bruno Haible  <bruno@clisp.org>
23559
23560         * lib/vasnprintf.c (alloca): Remove fallback definition.
23561         (freea): Remove definition.
23562         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23563         Reported by Paul Eggert.
23564
23565 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23566             Bruno Haible  <bruno@clisp.org>
23567
23568         Protect against address arithmetic overflow.
23569         * lib/printf-args.h: Include stddef.h.
23570         (arguments): Change type of field 'count' to size_t.
23571         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23572         'unsigned int' where appropriate.
23573         * lib/printf-parse.h: Include sys/types.h.
23574         (char_directive): Change type of *arg_index fields to ssize_t.
23575         (char_directives): Change type of fields 'count', max_*_length to
23576         size_t.
23577         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23578         (SSIZE_MAX): Define fallback value.
23579         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23580         instead of 'int' where appropriate. Check a_allocated, d_allocated
23581         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23582         * lib/vasnprintf.c: Include xsize.h.
23583         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23584         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
23585         overflow. Avoid wraparound when converting a width or precision from
23586         decimal to binary.
23587
23588 2003-11-16  Bruno Haible  <bruno@clisp.org>
23589
23590         Update from GNU gettext.
23591         * lib/printf-parse.c: Generalize to it can be compiled for wide
23592         strings.
23593         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
23594         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
23595         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
23596         SNPRINTF): New macros.
23597         Don't include <alloca.h> if the file is used inside libintl.
23598         (local_wcslen): New function, for Solaris 2.5.1.
23599         (VASNPRINTF): Use it instead of wcslen.
23600
23601 2003-11-16  Bruno Haible  <bruno@clisp.org>
23602
23603         * lib/xsize.h (xmax): New function.
23604         (xsum, xsum3, xsum4): Declare as "pure" functions.
23605
23606 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23607
23608         * modules/xalloc (Files): Undo latest change, since xalloc.h
23609         no longer needs SIZE_MAX or PTRDIFF_MAX.
23610
23611 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23612
23613         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
23614         gl_PTRDIFF_MAX.
23615
23616 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23617
23618         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
23619         "return", to pacify some unknown compiler.  Problem reported
23620         by Joerg Schilling.
23621
23622 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23623
23624         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
23625         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
23626         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
23627         heuristic is just as accurate as far as we know, and it removes a
23628         dependency on size_max.m4 and ptrdiff_max.m4.
23629
23630 2003-11-11  Bruno Haible  <bruno@clisp.org>
23631
23632         * modules/xsize (Files): Add m4/size_max.m4.
23633         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
23634
23635 2003-11-11  Bruno Haible  <bruno@clisp.org>
23636
23637         * m4/size_max.m4: New file.
23638         * m4/ptrdiff_max.m4: New file.
23639         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
23640         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
23641         (gl_XALLOC): Invoke it.
23642
23643 2003-11-11  Bruno Haible  <bruno@clisp.org>
23644
23645         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
23646         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
23647         defined.
23648
23649 2003-11-10  Paul Eggert  <eggert@twinsun.com>
23650
23651         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
23652         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
23653         rejected some allocations of exactly SIZE_MAX - 2 bytes.
23654         From Bruno Haible.
23655         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
23656         not (size_t) -1, since it's defined here.
23657
23658 2003-11-09  Karl Berry  <karl@gnu.org>
23659
23660         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
23661
23662 2003-11-06  Paul Eggert  <eggert@twinsun.com>
23663
23664         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
23665         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
23666         Reject sizes of exactly SIZE_MAX bytes.
23667         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
23668         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
23669
23670 2003-11-05  Bruno Haible  <bruno@clisp.org>
23671
23672         * lib/xsize.h: Include limits.h, to avoid a possible collision with
23673         SIZE_MAX defined in <limits.h> on Solaris.
23674
23675 2003-11-04  Jim Meyering  <jim@meyering.net>
23676
23677         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
23678         variable names, rather than @VAR@.
23679         * modules/poll: Likewise.
23680
23681 2003-11-04  Bruno Haible  <bruno@clisp.org>
23682
23683         * modules/xsize: New file.
23684         * modules/linebreak: Depend on xsize.
23685         * MODULES.html.sh (func_all_modules): Add xsize.
23686
23687 2003-11-04  Bruno Haible  <bruno@clisp.org>
23688
23689         * m4/xsize.m4: New file.
23690
23691 2003-11-04  Bruno Haible  <bruno@clisp.org>
23692
23693         * lib/xsize.h: New file.
23694         * lib/linebreak.c: Include xsize.h.
23695         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
23696         argument for overflow.
23697         Suggested by Paul Eggert.
23698
23699 2003-11-03  Karl Berry  <karl@gnu.org>
23700
23701         * config/config.{guess,sub}: update from config.
23702
23703 2003-11-03  Jim Meyering  <jim@meyering.net>
23704
23705         * modules/userspec (lib_SOURCES): Add userspec.h.
23706         (Include): Add "userspec.h".
23707         Improve description.
23708
23709 2003-11-03  Jim Meyering  <jim@meyering.net>
23710
23711         * lib/userspec.c: Include "userspec.h".
23712         * lib/userspec.h: New file.
23713
23714 2003-11-03  Bruno Haible  <bruno@clisp.org>
23715
23716         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
23717
23718 2003-11-03  Bruno Haible  <bruno@clisp.org>
23719
23720         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
23721         available, to avoid (extremely rare) race condition.
23722         Suggested by Paul Eggert.
23723
23724 2003-11-02  Karl Berry  <karl@gnu.org>
23725
23726         * config/srclist.txt (vasprintf.c): sync broken, sigh.
23727
23728 2003-10-31  Paul Eggert  <eggert@twinsun.com>
23729
23730         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
23731         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
23732         (read_filesystem_list): Set and use me_type_malloced.
23733         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
23734         whatever the type happens to be), for brevity and consistency.
23735         Check for size calculation overflow on Alphas running OSF/1.
23736
23737 2003-10-31  Jim Meyering  <jim@meyering.net>
23738
23739         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
23740
23741         * lib/linebuffer.c: Include <string.h> for declaration of memset.
23742
23743 2003-10-30  Paul Eggert  <eggert@twinsun.com>
23744             Bruno Haible  <bruno@clisp.org>
23745
23746         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
23747         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
23748
23749 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
23750
23751         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
23752         netbsd*-gnu*.  Suggested by Robert Millan.
23753
23754 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23755
23756         * modules/group-member: Depend on stdbool.
23757
23758 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23759
23760         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
23761
23762 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23763
23764         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
23765         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
23766         after the 'gnu' in these cases.  This fixes some bugs in the
23767         previous change, and is based on suggestions by Robert Millan.
23768
23769 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23770
23771         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
23772         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
23773         no longer needed.
23774         * lib/quotearg.c (quotearg_n_options): Use it.
23775         * lib/group-member.c: Include <stdbool.h>.
23776         (free_group_info): Arg is now const *; don't free arg.
23777         (get_group_info): Now returns bool and accepts struct group_info *,
23778         rather than returning a malloc'ed struct group_info *.
23779         All uses changed.  Check for overflow in internal size calculation.
23780
23781         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
23782         rather than xmalloc/xrealloc.
23783         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
23784         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
23785         conformance bug: the old code used a pointer after freeing the
23786         storage that it addressed.
23787         * lib/hash.c (hash_initialize): Simplify the code by using
23788         xalloc_oversized rather than doing it by hand.
23789         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
23790         the buffer preserved.  Use free and xmalloc instead.
23791         * lib/quotearg.c (quotearg_n_options): Likewise.
23792         Use a simpler test for size overflow.  Don't use xalloc_oversized
23793         because unsigned int might be wider than size_t (!); this suggests
23794         that we should switch from unsigned int to size_t for slot numbers.
23795
23796 2003-10-28  Paul Eggert  <eggert@twinsun.com>
23797
23798         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
23799         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
23800         NetBSD kernels.  Requested by Richard Stallman.
23801
23802 2003-10-27  Paul Eggert  <eggert@twinsun.com>
23803
23804         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
23805         to allocate the returned structure.  Do not allocate a subarray,
23806         as x2nrealloc will do that.
23807         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
23808         instead of xnrealloc.
23809         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
23810
23811 2003-10-27  Bruno Haible  <bruno@clisp.org>
23812
23813         * lib/stdbool_.h: Better support for BeOS.
23814
23815 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23816
23817         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
23818         now uses inline.
23819
23820 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23821
23822         * lib/xalloc.h (xalloc_oversized): New static inline function, for
23823         callers that want to do their own size-overflow checking.  Include
23824         <stdbool.h>, since xalloc_oversized returns bool.
23825         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
23826         to use xalloc_oversized.
23827
23828         Add two functions x2realloc, x2nrealloc, for programs that grow
23829         arrays dynamically by doubling their sizes.
23830         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
23831         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
23832         New functions.
23833
23834         Port to C99 semantics for 'inline' of external functions.
23835         Bug reported by Bruno Haible.
23836         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
23837         with the old contents of xnmalloc.
23838         (xnmalloc, xmalloc): Use it.
23839         (xnrealloc_inline): New static inline function,
23840         with the old contents of xnrealloc.
23841         (xnrealloc, xrealloc): Use it.
23842
23843         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
23844         that.
23845
23846 2003-10-26  Karl Berry  <karl@gnu.org>
23847
23848         * config/srclist.txt (COPYING.DOC): no longer available from
23849         /gd/gnuorg; don't know where the ultimate source is.
23850
23851 2003-10-25  Paul Eggert  <eggert@twinsun.com>
23852
23853         Fix several address-calculation bugs in the hash modules,
23854         plus some minor code cleanup.
23855
23856         * lib/hash.h: Include <stdbool.h>, for bool.
23857         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
23858         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
23859         hash_get_n_entries, hash_get_max_bucket_length,
23860         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
23861         hash_rehash): Use size_t rather than unsigned.
23862         * lib/hash.c (struct hash_table, hash_get_n_buckets,
23863         hash_get_n_buckets_used, hash_get_n_entries,
23864         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
23865         hash_get_entries, hash_do_for_each, hash_string, is_prime,
23866         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
23867         Likewise.
23868         (SIZE_MAX): Define if not defined.
23869         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
23870         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
23871         hash_print):
23872         Use const * when possible.
23873         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
23874         (check_tuning): Fix bug: if tuning parameters were very close to
23875         0 or 1, rounding errors could have caused subscript violations.
23876         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
23877         (hash_initialize): Add 'fail:' label
23878         to free table and return NULL, and use it to simplify code.
23879         Use calloc rather than clearing the storage ourself.
23880         (hash_initialize, hash_rehash): Check for arithmetic overflow in
23881         buffer size calculations.
23882         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
23883         Include <stddef.h>, for size_t.
23884         * lib/hash-pjw.c (hash_pjw): Likewise.
23885         Switch to method described by Bruno Haible.
23886         Include <limits.h>, for CHAR_BIT.
23887         (SIZE_BITS): New macro.
23888
23889 2003-10-23  Paul Eggert  <eggert@twinsun.com>
23890
23891         * m4/getline.m4 (AM_FUNC_GETLINE):
23892         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
23893         hosts.  Problem reported by Derek Robert Price in
23894         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
23895         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
23896         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
23897
23898 2003-10-21  Paul Eggert  <eggert@twinsun.com>
23899
23900         * lib/getndelim2.c (getndelim2): When size calculation overflows,
23901         ceiling the allocation at NMAX bytes rather than silently
23902         discarding input bytes before NMAX is reached.  This makes
23903         a difference only if NMAX exceeds SIZE_MAX / 2.
23904
23905         * lib/obstack.c: Merge from glibc.
23906         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
23907         Add libc_hidden_def (_obstack_newchunk).
23908         (_obstack_free) [! defined _LIBC]: Remove.
23909         [defined _LIBC]: Make a strong alias from obstack_free, rather than
23910         a clone of the function body.
23911         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
23912         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
23913
23914         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
23915         glibc.
23916         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
23917         arg to memcpy.
23918
23919         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
23920         (obstack_ptr_grow_fast, obstack_int_grow_fast):
23921         Don't use lvalue casts, as GCC plans to remove support for them
23922         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
23923         was also present in the non-GCC version, indicating that this
23924         code had always been buggy and had never been widely used.
23925         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
23926         Use the fast variant of each macro, rather than copying the
23927         definiens of the fast variant; that way, we'll be more likely to
23928         catch future bugs in the fast variants.
23929
23930 2003-10-20  Bruno Haible  <bruno@clisp.org>
23931
23932         * modules/wait-process: New file.
23933         * MODULES.html.sh (func_all_modules): Add wait-process.
23934
23935 2003-10-20  Bruno Haible  <bruno@clisp.org>
23936
23937         * m4/wait-process.m4: New file.
23938
23939 2003-10-20  Bruno Haible  <bruno@clisp.org>
23940
23941         * lib/wait-process.h: New file, from GNU gettext.
23942         * lib/wait-process.c: New file, from GNU gettext.
23943
23944 2003-10-19  Jim Meyering  <jim@meyering.net>
23945
23946         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
23947         HPUX 10.20.
23948
23949 2003-10-18  Karl Berry  <karl@gnu.org>
23950
23951         * config/config.guess: update from config.
23952
23953 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23954
23955         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
23956         (getgroups): First arg is int, not size_t.
23957         Don't let 'free' mangle errno.
23958
23959 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23960
23961         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
23962
23963 2003-10-16  Karl Berry  <karl@gnu.org>
23964
23965         * config/config.{guess,sub}: update from config.
23966
23967 2003-10-16  Jim Meyering  <jim@meyering.net>
23968
23969         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
23970         memcpy.
23971
23972 2003-10-15  Paul Eggert  <eggert@twinsun.com>
23973
23974         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
23975         (SIZE_MAX): Remove.
23976         (new_exclude, add_exclude_file): Initial size no longer needs to
23977         be a power of 2.
23978         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
23979         our own address arithmetic overflow checking.
23980
23981         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
23982         (fnmatch): Do not alloca more than 2000 wide characters;
23983         instead, use malloc for large buffers.
23984         Check for address arithmetic overflow, and return -1
23985         with errno set to ENOMEM in that case.
23986         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
23987         (NEW_PATTERN): Do not alloca more than 8000 bytes;
23988         instead, return -1.  Check for address arithmetic overflow.
23989
23990 2003-10-14  Paul Eggert  <eggert@twinsun.com>
23991
23992         Handle invalid suffixes and overflow independently, so that
23993         callers can treat them independently as needed.  Fix some bugs in
23994         suffix handling, e.g., "100k@" was not diagnosed as an invalid
23995         suffix for a human-readable blocksize.  The major caller-visible
23996         change is the addition of a new
23997         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
23998         that both overflow and suffix chars were found.
23999
24000         * lib/human.c (humblock): Don't check separately for invalid suffix
24001         char; that is xstrtoumax's job (now that its bug is fixed).
24002         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
24003         INTMAX_MAX]: New macros.
24004         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
24005         TYPE_MAXIMUM): New macros.
24006         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
24007         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
24008         if overflow occurs, as it's what __strtol does and it's more useful
24009         in practice.
24010         (__xstrtol): If __strtol reports some error other than ERANGE,
24011         reflect it to the caller as LONGINT_INVALID.  If it reports
24012         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
24013         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
24014         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
24015         value.
24016         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
24017         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
24018         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
24019         [defined UINTMAX_MAX]: New macros.
24020
24021 2003-10-14  Bruno Haible  <bruno@clisp.org>
24022
24023         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
24024
24025 2003-10-14  Bruno Haible  <bruno@clisp.org>
24026
24027         * m4/sig_atomic_t: New file, from GNU gettext.
24028         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
24029
24030 2003-10-14  Bruno Haible  <bruno@clisp.org>
24031
24032         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
24033         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
24034         Also use volatile where needed.
24035
24036 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24037
24038         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
24039         Change maintainer from Bruno Haible to 'all'.
24040
24041 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24042
24043         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
24044
24045 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24046
24047         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
24048         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
24049         and define in terms of the other primitives.
24050         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
24051         (SIZE_MAX): Define if not already defined.
24052         (array_size_overflow): New function.
24053         (xalloc_die): Abort instead of exiting if 'error' returns.
24054         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
24055         (xmalloc, xrealloc): Use them.
24056         (xcalloc): Check for address arithmetic overflow.
24057         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
24058         a bit faster than strcpy.
24059
24060 2003-10-10  Simon Josefsson  <jas@extundo.com>
24061
24062         * modules/argp (Depends-on): Add restrict and strcase.
24063
24064 2003-10-10  Simon Josefsson  <jas@extundo.com>
24065
24066         * m4/argp.m4: Add AC_C_INLINE.
24067
24068 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24069
24070         Merge getpass from libc, plus a few fixes.
24071
24072         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
24073         Include <stdbool.h>.
24074         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
24075         __fsetlocking to empty.
24076         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
24077         do include <bits/libc-lock.h>.
24078         Do not include <fcntl.h>; not needed.
24079         [_LIBC]: Include <wchar.h>.
24080         (NOTCANCEL_MODE): New macro.
24081         (flockfile, funlockfile) [_LIBC]: New macros.
24082         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
24083         [!_LIBC]: New macros.
24084         (call_fclose): New function.
24085         (getpass): Use it.  Save tty stream separately; this simplifies the
24086         code and makes it more reliable if stdin happens to equal stdout.
24087         Invoke __fsetlocking on tty.
24088         Handle thread cancellation if needed.
24089         Namespace cleanup (use __tcgetattr, __getline).
24090         Use bool for Booleans.
24091         [USE_IN_LIBIO]: Handle wide streams.
24092         [!_LIBC]: Unconditionally do the fseek, since we don't know what
24093         stream might go where.
24094
24095         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
24096         doesn't have to include <stdio.h> before us.
24097         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
24098         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
24099         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
24100         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
24101         if not declared, so that we can use getpass.c code from libc without
24102         rewriting it.
24103         (flockfile, ftrylockfile, funlockfile): New macros.
24104
24105 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24106
24107         * modules/getpass: Depend on stdbool.
24108
24109 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24110
24111         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
24112
24113 2003-10-07  Karl Berry  <karl@gnu.org>
24114
24115         * config/config.{guess,sub}: update from config.
24116
24117 2003-10-06  Jim Meyering  <jim@meyering.net>
24118             Bruno Haible  <bruno@clisp.org>
24119
24120         This lets translators provide better translations for the
24121         "Written by ..." part of --version output.
24122         * lib/version-etc.h: Include stdarg.h.
24123         (version_etc_copyright): Declare as readonly.
24124         (version_etc): Make this function variadic with a NULL-terminated list
24125         of author name strings.
24126         (version_etc_va): New declaration.
24127         * lib/version-etc.c: Include stdarg.h, stdlib.h.
24128         (version_etc_copyright): Declare as readonly.
24129         (version_etc_va): New function. Provide a different translatable string
24130         for each possible number of authors < 10. Abbreviate when there are 10
24131         authors or more.
24132         (version_etc): Make this function variadic. Call version_etc_va.
24133         Suggestion from Gary V. Vaughan.
24134
24135         * lib/long-options.h (parse_long_options): Change prototype: the
24136         authors string is moved to the end and becomes variadic.
24137         * lib/long-options.c: Include stdarg.h.
24138         (parse_long_options): Make this function variadic, too.
24139         Call version_etc_va, not version_etc.
24140
24141 2003-10-06  Bruno Haible  <bruno@clisp.org>
24142
24143         * modules/version-etc-2: Remove file.
24144         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
24145
24146 2003-10-06  Bruno Haible  <bruno@clisp.org>
24147
24148         * modules/fatal-signal: New file.
24149         * MODULES.html.sh (func_all_modules): Add fatal-signal.
24150
24151 2003-10-06  Bruno Haible  <bruno@clisp.org>
24152
24153         * m4/fatal-signal.m4: New file.
24154         * m4/signalblocking.m4: New file, from GNU gettext.
24155
24156 2003-10-06  Bruno Haible  <bruno@clisp.org>
24157
24158         * lib/version-etc-2.h: Remove file.
24159         * lib/version-etc-2.c: Remove file.
24160
24161 2003-10-06  Bruno Haible  <bruno@clisp.org>
24162
24163         * lib/fatal-signal.h: New file, from GNU gettext.
24164         * lib/fatal-signal.c: New file, from GNU gettext.
24165
24166 2003-10-05  Paul Eggert  <eggert@twinsun.com>
24167
24168         * README: Rework advice for preventing empty .o files.
24169         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
24170         not <sys/types.h>.
24171
24172 2003-10-04  Karl Berry  <karl@gnu.org>
24173
24174         * lib/argp*: update from libc.
24175
24176 2003-10-04  Karl Berry  <karl@gnu.org>
24177
24178         * config/config.{guess,sub}: update from config.
24179
24180 2003-10-02  Bruno Haible  <bruno@clisp.org>
24181
24182         * modules/lchown (Include): Add lchown.h.
24183         * modules/time_r (Include): Use "..." syntax.
24184         * modules/xgetdomainname (Include): Add xgetdomainname.h.
24185
24186 2003-10-01  Simon Josefsson  <jas@extundo.com>
24187
24188         * MODULES.html.sh (func_all_modules): Move gethostname from section
24189         'based on' to section 'lacking' POSIX:2001.
24190
24191 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
24192
24193         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
24194         to output mode on the same stream.
24195
24196 2003-09-29  Paul Eggert  <eggert@twinsun.com>
24197
24198         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
24199         Fix arg typo in previous patch.
24200
24201 2003-09-28  Jim Meyering  <jim@meyering.net>
24202
24203         * lib/error.c: Correct cpp indentation.
24204
24205 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24206
24207         * modules/free: New file.
24208
24209 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24210
24211         * m4/free.m4: New file.
24212
24213 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24214
24215         * lib/minmax.h (MIN, MAX)
24216         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
24217         Omit the special code that used __typeof__, since we worry that
24218         it could be more trouble than it's worth.  See:
24219         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
24220         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
24221
24222         * lib/free.c: New file.
24223
24224 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
24225
24226         Trivial fixes to Makefile.am parts of module listings.
24227         * modules/strstr: Append strstr.h to lib_SOURCES.
24228         * modules/strcase: Likewise, for strcase.h.
24229
24230 2003-09-27  Karl Berry  <karl@gnu.org>
24231
24232         * config/mkinstalldirs: update from automake.
24233
24234 2003-09-26  Paul Eggert  <eggert@twinsun.com>
24235
24236         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
24237         (error_tail): Do not loop, reallocating temporary buffer, since
24238         the output cannot contain more wide characters than the input
24239         contains bytes, the size must be big enough already.  This avoids
24240         one potential size overflow calculation.  Check for size overflow
24241         when calculating temporary buffer size.  Free temporary buffer
24242         when done, if it was allocated with malloc; this plugs a memory
24243         leak.  Remove casts from void * to pointers, that are no longer
24244         needed now that we're assuming C89 or better.
24245
24246         Merge error changes from glibc.
24247
24248         * lib/error.c, error.h: Update copyright notice header to match glibc.
24249         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
24250         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
24251         Disable cancellation while printing error.
24252         * lib/error.h: Prepend __ to parameter names.
24253
24254 2003-09-26  Jim Meyering  <jim@meyering.net>
24255
24256         * lib/error.c (error_tail): Move some declarations
24257         into inner scope where the local variables are used.
24258
24259 2003-09-26  Bruno Haible  <bruno@clisp.org>
24260
24261         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
24262         stpncpy().
24263         Don't define stpncpy through config.h; it's now done through stpncpy.h.
24264
24265 2003-09-26  Bruno Haible  <bruno@clisp.org>
24266
24267         * lib/stpncpy.h (gnu_stpncpy): New declaration.
24268         (stpncpy): Define as alias for gnu_stpncpy.
24269         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
24270
24271 2003-09-25  Simon Josefsson  <jas@extundo.com>
24272
24273         * lib/xgetdomainname.h: New file.
24274         * lib/xgetdomainname.c: New file.
24275
24276 2003-09-25  Simon Josefsson  <jas@extundo.com>
24277             Bruno Haible  <bruno@clisp.org>
24278
24279         * modules/getdomainname: New file.
24280         * modules/xgetdomainname: New file.
24281         * MODULES.html.sh (func_all_modules): Add getdomainname,
24282         xgetdomainname.
24283
24284 2003-09-25  Simon Josefsson  <jas@extundo.com>
24285             Bruno Haible  <bruno@clisp.org>
24286
24287         * m4/getdomainname.m4: New file.
24288
24289 2003-09-25  Simon Josefsson  <jas@extundo.com>
24290             Bruno Haible  <bruno@clisp.org>
24291
24292         * lib/getdomainname.h: New file.
24293         * lib/getdomainname.c: New file.
24294
24295 2003-09-25  Karl Berry  <karl@gnu.org>
24296
24297         * lib/argp-fmtstream.c, argp-help.c: update from libc.
24298
24299 2003-09-25  Karl Berry  <karl@gnu.org>
24300
24301         * config/install-sh: update from automake.
24302
24303 2003-09-25  Bruno Haible  <bruno@clisp.org>
24304
24305         * modules/version-etc-2: New file, from modules/version-etc with
24306         modifications.
24307         * MODULES.html.sh (func_all_modules): Add version-etc-2.
24308
24309 2003-09-25  Bruno Haible  <bruno@clisp.org>
24310
24311         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
24312         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
24313
24314 2003-09-24  Simon Josefsson  <jas@extundo.com>
24315
24316         * modules/xgethostname: Add xgethostname.h.
24317
24318 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24319
24320         * lib/linebuffer.c (freebuffer): Don't free the argument, just
24321         the buffer associated with the argument.  Bug reported by
24322         Simon Josefsson.
24323
24324 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24325
24326         * README: Document assumptions that 'int' is at least 32 bits
24327         wide, that integer arithmetic is 2's complement without overflow,
24328         that there are no holes in integer values, that adding sizes of
24329         two nonoverlapping objects can't overflow, and that all-bits-zero
24330         yields scalar zero.  Fix spelling and capitalization typos.
24331
24332 2003-09-19  Karl Berry  <karl@gnu.org>
24333
24334         * lib/argp.h: update from libc.
24335
24336 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24337
24338         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
24339         to avoid spurious warnings like "AC_RUN_IFELSE was called before
24340         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
24341
24342 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24343
24344         * gnulib-tool: Use "test -h", not "test -L", for portability
24345         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
24346         (tags_regexp): Remove, since \| doesn't conform to POSIX.
24347         (sed_extract_prog): Issue s commands one-by-one, rather than
24348         using \| in one s command.
24349
24350 2003-09-16  Paul Eggert  <eggert@twinsun.com>
24351
24352         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
24353         input error, instead of returning NULL the next time we are called
24354         (and therefore losing track of errno).
24355
24356 2003-09-16  Bruno Haible  <bruno@clisp.org>
24357
24358         * gnulib-tool (func_create_testdir): Warn about duplicated
24359         dependencies.
24360
24361 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24362
24363         * modules/argmatch, modules/fatal, modules/obstack,
24364         modules/xalloc, modules/xgethostname: Sort dependencies by
24365         importance, not alphabetically.
24366
24367 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24368
24369         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
24370         fails, so that the caller gets the proper errno.
24371
24372         * lib/readutmp.c (read_utmp): Likewise.
24373         Check for fstat error.  Close stream and free storage
24374         when failing.
24375
24376 2003-09-14  Karl Berry  <karl@gnu.org>
24377
24378         * config/srclist.txt (strdup.c): disable for c89 changes.
24379
24380 2003-09-14  Jim Meyering  <jim@meyering.net>
24381
24382         * lib/getloadavg.c: Correct cpp indentation.
24383         * lib/strdup.c: Likewise.
24384         * lib/vasnprintf.c: Likewise.
24385
24386 2003-09-14  Bruno Haible  <bruno@clisp.org>
24387
24388         * modules/fwriteerror: New file.
24389         * MODULES.html.sh (func_all_modules): Add fwriteerror.
24390
24391 2003-09-14  Bruno Haible  <bruno@clisp.org>
24392
24393         * lib/fwriteerror.h: New file.
24394         * lib/fwriteerror.c: New file.
24395
24396 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24397
24398         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
24399         modules/xgethostname, modules/xalloc: Depend on exit.
24400
24401 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24402
24403         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24404
24405         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24406         and AC_MINIX, too, so that their extensions are available.
24407
24408         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24409         This macro has been superseded by gl_BACKUPFILE.
24410
24411         More patches to assume C89 or better.
24412
24413         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24414
24415         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24416         unconditionally.
24417         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24418         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24419         Include <string.h>, <stdlib.h> unconditionally.
24420         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24421         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24422         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24423         headers or for string.h.
24424         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24425         or strtoul.
24426
24427         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24428         headers.
24429         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24430         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24431         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24432         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24433         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24434         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24435         memcpy, memset.
24436         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24437         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24438         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24439         strtol.
24440         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24441         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24442         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24443         strtoul.
24444
24445 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24446
24447         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24448         * lib/obstack.c [!defined _LIBC]: Likewise.
24449         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24450         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24451         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24452
24453         More changes to assume C89 or better.
24454
24455         * lib/error.c (error_tail): Assume vprintf.
24456
24457         * lib/argmatch.c (getenv): Remove decl.
24458         * lib/progreloc.c (get_full_program_name): Define via prototype.
24459         * lib/setenv.c (clearenv): Likewise.
24460         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24461         needed.
24462         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24463         (malloc, memcpy): Remove decls.
24464         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24465         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24466         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24467         (memcpy): Remove macro.
24468         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24469         (__P): Remove.  All uses removed.
24470         (PTR): Remove.  All uses changed to void *.
24471         (CHAR_BIT, NULL): Remove.
24472         (spaces, zeros, memset_space, memset_zero)
24473         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24474         Remove.
24475         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24476         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24477         Define with prototype.
24478         Remove now-unnecessary prototype decl.
24479         (extra_args_spec): Assume ANSI C.  All uses changed.
24480         (extra_args_spec_iso): Remove.
24481         (my_strftime, emacs_strftimeu): Define via prototype.
24482         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24483         unconditionally.
24484         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24485         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24486         (strtoul, strtol): Remove decls.
24487         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24488         LONG_MAX): Remove.
24489         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24490         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24491         (LOCALE_PARAM_PROTO): New macro.
24492         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24493         (INTERNAL (strtol), strtol): Define with a prototype.
24494         (PARAMS): Remove.  All uses removed.
24495         * lib/tempname.c: Include <string.h> unconditionally.
24496         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24497         * lib/xgethostname.c (main): Define with a prototype.
24498         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24499         Include <stdlib.h> unconditionally.
24500         (calloc, malloc, realloc, free): Remove decls.
24501         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24502         Include <stdlib.h> unconditionally.  Sort include file names.
24503         (strtod): Remove.
24504         (xstrtod): Define with a prototype.
24505         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24506         (strtol, strtoul): Remove decls.
24507
24508 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24509
24510         More patches to assume C89 or better.
24511         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24512         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24513         string.h, memchr, STDC_HEADERS.
24514
24515 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24516
24517         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24518         Include <stdlib.h>, <string.h> unconditionally.
24519         Remove now-unnecessary cast to char *.
24520         * lib/strnlen.c: Include <string.h> unconditionally.
24521         * lib/yesno.c (yesno): Define with a prototype.
24522
24523 2003-09-11  Bruno Haible  <bruno@clisp.org>
24524
24525         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24526
24527 2003-09-10  Jim Meyering  <jim@meyering.net>
24528
24529         * lib/error.c: Correct indentation of cpp directives.
24530
24531 2003-09-10  Bruno Haible  <bruno@clisp.org>
24532
24533         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24534         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24535         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24536         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24537         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24538         <stdlib.h> and <string.h> checks.
24539         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24540         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24541
24542 2003-09-10  Bruno Haible  <bruno@clisp.org>
24543
24544         * lib/strcspn.c: Include <string.h> unconditionally.
24545         * lib/strpbrk.c: Include <string.h> unconditionally.
24546         * lib/strstr.c: Include <string.h> unconditionally.
24547         * lib/unicodeio.c: Include <string.h> unconditionally.
24548         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24549         * lib/unsetenv.c: Likewise.
24550         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24551         * lib/yesno.c: Include <stdlib.h> unconditionally.
24552         (rpmatch): Add prototype.
24553
24554 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24555
24556         More patches to assume C89 or better.
24557         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24558         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24559         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24560         or for string.h.
24561         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24562         stdlib.h.
24563         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24564         C headers.
24565         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24566         string.h.
24567         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24568         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24569         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24570         or for string.h.
24571         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24572         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24573         C headers.
24574         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24575         memcpy.
24576         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24577         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24578         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24579         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24580         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24581         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24582         string.h, free.
24583         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24584         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
24585         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
24586         C headers, or for string.h.
24587         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
24588         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
24589         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
24590         headers, memory.h, stdlib.h, string.h, strings.h.
24591         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
24592         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
24593         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
24594         strchr.
24595         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
24596         headers, memory.h, string.h.
24597         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
24598         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
24599         free.
24600         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
24601         headers.
24602         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
24603         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
24604         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
24605         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
24606         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
24607
24608 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24609
24610         More K&R removal.
24611
24612         * lib/acosl.c (main): Use a prototype.
24613         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
24614         tanl.c: Likewise.
24615
24616         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
24617
24618         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
24619         (getopt, etopt_long, getopt_long_only, _getopt_internal)
24620         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
24621         with a prototype.
24622         * lib/getopt.c (const): Remove macro.
24623         Include <string.h> unconditionally.
24624         (my_index): Remove; all uses changed to strchr.
24625         (strlen): Remove decl.
24626         (exchange): Remove forward decl; no longer needed.
24627         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
24628         Define with prototype.
24629         * lib/getopt1.c (const): Remove macro.
24630         (getopt_long, getopt_long_only, main): Define with prototype.
24631
24632         * lib/getugroups.c: Include <string.h> unconditionally.
24633
24634         * lib/getusershell.c: Include <stdlib.h> unconditionally.
24635         (getusershell, setusershell, endusershell, readname, main):
24636         Define with prototypes.
24637
24638         * lib/group-member.c: Include group-member.h first.
24639         Include <stdlib.h> unconditionally.
24640
24641         * lib/hard-locale.c: Include hard-locale.h first.
24642         Include <stdlib.h>, <string.h> unconditionally.
24643
24644         * lib/hash.c (free, malloc): Remove decls.
24645         Include <stdlib.h> unconditionally.
24646
24647         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
24648         (getenv): Do not declare.
24649
24650         * lib/idcache.c: Include <string.h> unconditionally.
24651
24652         * lib/long-options.c: Include long-options.h first, to test interface.
24653         Include <stdlib.h> unconditionally.
24654
24655         * lib/makepath.c: Include makepath.h first, to test interface.
24656         Include <stdlib.h> and <string.h> unconditionally.
24657
24658         * lib/linebuffer.c: Include <stdlib.h>.
24659         (free): Remove decl.
24660
24661         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
24662         stddef.h. rpl_malloc returns void *, not char *.
24663         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
24664         prototype.
24665
24666         * lib/md5.h: Include <limits.h> unconditionally.
24667         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
24668         (__P): Remove; all uses removed.
24669         * lib/md5.c: Include "md5.h" first.
24670         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
24671         md5_buffer, md5_process_bytes, md5_process_block):
24672         Define with prototypes.
24673         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
24674         * lib/sha.c: Include "sha.h" first.
24675         Include <stdlib.h>, <string.h> unconditionally.
24676
24677         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
24678         * lib/memcmp.c (__ptr_t): Likewise.
24679         * lib/memrchr.c (__ptr_t): Likewise.
24680         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
24681         Include <string.h> unconditionally.
24682         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
24683         * lib/memchr.c: Include <stdlib.h> unconditionally.
24684         * lib/memchr.c (LONG_MAX): Remove.
24685         * lib/memrchr.c (LONG_MAX): Likewise.
24686         * lib/memchr.c (__memchr): Define via a prototype.
24687         * lib/memrchr.c (__memrchr): Likewise.
24688         * lib/memcmp.c (__P): Remove, and remove all uses.
24689         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
24690         Remove forward decls; no longer needed.
24691         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
24692         Use types required by C89 in prototype.
24693
24694         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
24695         * lib/savedir.c: Likewise.
24696         * lib/mkdir.c (free): Remove decl.
24697         * lib/rmdir.c (rmdir): Define with a prototype.
24698         * lib/savedir.c: Include savedir.h first, to test interface.
24699
24700         * lib/mktime.c (STDC_HEADERS): Remove.
24701         Include <stdlib.h>, <string.h> unconditionally.
24702
24703         * lib/modechange.c: Include <stdlib.h> unconditionally.
24704         (malloc): Remove decl.
24705
24706         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
24707         (free): Remove decl.
24708
24709         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
24710         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
24711         (This type really should be intptr_t, but that's a C99ism.)
24712         (_obstack_memcpy): Remove: all uses changed to memcpy.
24713         Include <string.h> unconditionally.
24714         (struct obstack): Assume __STDC__ for types of members
24715         chunkfun, freefun, extra_arg.
24716         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
24717         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
24718         obstack_begin, obstack_specify_allocation,
24719         obstack_specify_allocation_with_arg, obstack_chunkfun,
24720         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
24721         Remove unprototyped decls and the macros that use them.
24722         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
24723         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
24724         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
24725         (defined __STDC__ && __STDC__)]:
24726         Remove nonprototyped code.
24727         Include <stdlib.h> unconditionally.
24728         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
24729         _obstack_allocated_p, _obstack_free, obstack_free,
24730         _obstack_memory_used, print_and_abort):
24731         Define using prototypes.
24732         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
24733         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
24734         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
24735         obstack_next_free, obstack_object_size, obstack_room) [0]:
24736         Remove unused, unprototyped code.
24737
24738         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
24739
24740         * lib/physmem.c (physmem_total, physmem_available, main): Define
24741         with prototypes.
24742
24743         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
24744         (main): Define with a prototype.
24745
24746         * lib/posixver.c (getenv): Remove decl.
24747
24748         * lib/putenv.c (malloc): Returns void *, not char *.
24749         Include <string.h> unconditionally.
24750         (strchr, memcpy, NULL): Do not define.
24751
24752         * lib/readtokens.c: Include readtokens.h first, to test interface.
24753         Include <stdlib.h>, <string.h> unconditionally.
24754         (init_tokenbuffer): Define with a prototype.
24755
24756         * lib/regex.c (PARAMS): Remove.  All uses removed.
24757         All uses of _RE_ARGS removed, too.
24758         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
24759         unconditionally.
24760         (bzero): Assume memset exists.
24761         (memcmp, memcpy, NULL): Remove.
24762         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
24763         char, or assignments to local vars of type signed char.
24764         (init_syntax_once, PREFIX(extract_number_and_incr),
24765         PREFIX(print_partial_compiled_pattern),
24766         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
24767         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
24768         PREFIX(regex_grow_registers), PREFIX(regex_compile),
24769         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
24770         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
24771         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
24772         wcs_compile_range, byte_compile_range, truncate_wchar,
24773         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
24774         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
24775         count_mbs_length, wcs_re_match_2_internal,
24776         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
24777         PREFIX(alt_match_null_string_p),
24778         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
24779         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
24780         regfree, PREFIX(extract_number)): Define with prototype.  Remove
24781         now-unnecessary declaration, if any.
24782         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
24783         regcomp, regexec):
24784         Remove now-unnecessary casts among pointer types.
24785         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
24786
24787         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
24788         (free): Remove decl.
24789
24790         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
24791
24792         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
24793         (free): Remove decl.
24794
24795         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
24796         * lib/xgetcwd.c: Likewise.
24797
24798         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
24799         (free): Remove decl.
24800
24801         * lib/strchrnul.c (strchrnul): Define with a prototype.
24802         Fix bug: c_in was not converted to char before searching.
24803
24804         The following changes are not K&R related:
24805
24806         * lib/group-member.h: Include <sys/types.h>, so that this file is
24807         self-contained.
24808         * lib/makepath.h: Likewise.
24809
24810         * lib/getusershell.c (readname, default_index, line_size, readname):
24811         Use size_t, not int, for sizes.
24812         (readname): If the size overflows, report an error instead of
24813         looping forever.
24814
24815 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24816
24817         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
24818         libc.
24819
24820 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24821
24822         * README: New section: portability guidelines.
24823
24824 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24825
24826         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
24827         C89 spec.
24828
24829 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24830
24831         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
24832
24833 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24834
24835         Assume C89 or better; remove K&R cruft.
24836         A few of these changes were first proposed by Derek Robert Price
24837         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
24838
24839         * lib/addext.c: Include <string.h> unconditionally.
24840         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
24841         Don't declare getenv or malloc.
24842
24843         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
24844         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
24845         (NULL): Remove.
24846         (find_stack_direction, alloca): Use prototypes.
24847
24848         * lib/atexit.c (atexit): Define using a prototype.
24849
24850         * lib/basename.c, dirname.c, stripslash.c:
24851         Include <string.h> unconditionally.
24852
24853         * lib/bcopy.c: Include <stddef.h>.
24854         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
24855
24856         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
24857
24858         * lib/error.h (error, error_at_line, error_print_progname)
24859         [! (defined (__STDC__) && __STDC__)]: Remove decls.
24860         * lib/error.c: Include error.h first, to check interface.
24861         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24862         (VA_START): Remove; all uses changeed to va_start.
24863         (exit, strerror): Remove decls.
24864         (error_print_progname): Prototype uncondionally.
24865         Don't include <errno.h>; no longer needed.
24866         (private_strerror): Remove.
24867         (error_tail): Always define.
24868         (error, error_at_line): Assume C89 or better; always use prototypes.
24869         * lib/fatal.c: Include "fatal.h" first, to test interface.
24870         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24871         (VA_START): Remove; all uses changed to va_start.
24872         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
24873         this case.
24874         (exit): Remove decl.
24875         (fatal): Prototype unconditionally.  Assume va_start works.
24876         Abort at end, to pacify gcc.
24877
24878         * lib/euidaccess.c (main): Define with a prototype.
24879
24880         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
24881
24882         * lib/exitfail.c: Include <stdlib.h> unconditionally.
24883
24884         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
24885         prototypes.
24886         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
24887         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
24888         (getenv): Remove decl.
24889         (fnmatch): Define using a prototype.
24890         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
24891         (FCT): Define using a prototype.
24892
24893         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
24894
24895         * lib/gethostname.c: Include <stddef.h>.
24896         (gethostname): Define with prototype.  Length is size_t, not int.
24897
24898 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24899
24900         Assume C89 or better; remove K&R cruft.
24901         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
24902         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
24903         string.h, getenv, malloc.
24904         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
24905         headers.
24906         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
24907         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
24908         do not check for strerror.
24909         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
24910         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
24911         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
24912         do not check for doprnt or vprintf.
24913         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
24914         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
24915
24916 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24917
24918         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
24919         getversion.c should have been removed then, but was accidentally
24920         preserved.
24921
24922         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
24923         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
24924
24925 2003-09-08  Karl Berry  <karl@gnu.org>
24926
24927         * config/config.sub, config.guess, srclistvars.sh: update from savannah
24928                 config, forget about prep.
24929
24930         * config/depcomp, missing: update from automake.
24931
24932 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24933
24934         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
24935         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24936
24937 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24938
24939         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
24940         copy_tm_result.  Bug reported by Simon Josefsson in
24941         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24942
24943 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24944
24945         * m4/time_r.m4: New file.
24946         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
24947         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
24948         is. Check for timegm declaration.
24949         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
24950         Do not check for gmtime_r.
24951         Replace mktime if __mktime_internal does not exist and if mktime
24952         hasn't been replaced already.
24953
24954 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24955
24956         * lib/time_r.c, lib/time_r.h: New files.
24957
24958         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
24959         __localtime_r.
24960         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
24961         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
24962
24963         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
24964         __gmtime_r.
24965         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
24966         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
24967         Include <time_r.h>.
24968
24969         * lib/timegm.c: Switch to glibc implementation, with the following
24970         changes:
24971         [defined HAVE_CONFIG_H]: Include <config.h>.
24972         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
24973         (__mktime_internal) [!defined _LIBC]: New decl.
24974         (__gmtime_r) [!defined _LIBC]: New macro and function.
24975         (timegm): Use a prototype, since gnulib assumes C89.
24976         Do not bother declaring tmp to be const, as it's not really usefu.
24977         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
24978         (timegm): Declare only if HAVE_DECL_TIMEGM.
24979
24980 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24981
24982         * MODULES.html.sh (func_all_modules): Add time_r.
24983         * modules/time_r: New file.
24984         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
24985         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
24986
24987 2003-09-03  Paul Eggert  <eggert@twinsun.com>
24988
24989         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
24990         Bug reported by Lute Kamstra in
24991         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
24992
24993         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
24994         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
24995         course with correspondingly smaller numbers for tomorrow and
24996         yesterday.  From Tadayoshi Funaba.  Originally installed into
24997         sh-utils on 1999-08-07, but the patch got lost (I guess during the
24998         coreutils merge?).
24999
25000 2003-08-31  Simon Josefsson  <jas@extundo.com>
25001
25002         * modules/timegm: New file.
25003         * MODULES.html.sh (func_all_modules): Add timegm.
25004
25005 2003-08-31  Simon Josefsson  <jas@extundo.com>
25006
25007         * m4/timegm.m4: New file.
25008
25009 2003-08-31  Simon Josefsson  <jas@extundo.com>
25010
25011         * lib/timegm.h: New file.
25012         * lib/timegm.c: New file.  Based on
25013         wget-1.8.2/src/http.c:mktime_from_utc.
25014
25015 2003-08-31  Karl Berry  <karl@gnu.org>
25016
25017         * lib/argp.h: update from libc.
25018
25019 2003-08-28  Bruno Haible  <bruno@clisp.org>
25020
25021         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
25022         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
25023         followed by '#define fnmatch fnmatch_posix' gives an error.
25024
25025 2003-08-28  Bruno Haible  <bruno@clisp.org>
25026
25027         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
25028         warning on QNX, which defines O_BINARY to 000000.
25029
25030 2003-08-27  Jim Meyering  <jim@meyering.net>
25031
25032         * m4/mkstemp.m4: Require that the system mkstemp be able to create
25033         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
25034         would fail after 32.  Reported by Danny Levinson.  Details here:
25035         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
25036
25037 2003-08-24  Bruno Haible  <bruno@clisp.org>
25038
25039         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
25040         MSVC7 <stdio.h> is included later.
25041
25042 2003-08-22  Simon Josefsson  <jas@extundo.com>
25043
25044         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
25045
25046 2003-08-20  Karl Berry  <karl@gnu.org>
25047
25048         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
25049
25050 2003-08-20  Bruno Haible  <bruno@clisp.org>
25051
25052         * modules/progname: New file.
25053         * MODULES.html.sh (func_all_modules): Add progname.
25054
25055 2003-08-20  Bruno Haible  <bruno@clisp.org>
25056
25057         * lib/progname.h: New file, from GNU gettext.
25058         * lib/progname.c: New file, from GNU gettext.
25059         * lib/progreloc.c: New file, from GNU gettext.
25060
25061 2003-08-19  Jim Meyering  <jim@meyering.net>
25062
25063         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
25064         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
25065
25066 2003-08-19  Bruno Haible  <bruno@clisp.org>
25067
25068         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
25069         more.
25070
25071 2003-08-19  Bruno Haible  <bruno@clisp.org>
25072
25073         * lib/xstrdup.c: Assume <string.h> exists.
25074
25075 2003-08-18  Paul Eggert  <eggert@twinsun.com>
25076
25077         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
25078         in makefile rules.
25079
25080 2003-08-18  Jim Meyering  <jim@meyering.net>
25081
25082         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
25083         * m4/lib-ld.m4: Likewise.
25084
25085 2003-08-18  Jim Meyering  <jim@meyering.net>
25086
25087         * lib/setenv.h: Indent nested cpp directive.
25088         * lib/vasnprintf.c: Remove trailing blanks.
25089
25090 2003-08-17  Simon Josefsson  <jas@extundo.com>
25091
25092         * modules/xstrndup: New file.
25093         * MODULES.html.sh (func_all_modules): Add xstrndup.
25094
25095 2003-08-17  Simon Josefsson  <jas@extundo.com>
25096
25097         * modules/argp: Fix autoconf macro name. Add more dependencies.
25098
25099 2003-08-17  Simon Josefsson  <jas@extundo.com>
25100
25101         * m4/xstrndup.m4: New file.
25102
25103 2003-08-17  Simon Josefsson  <jas@extundo.com>
25104
25105         * m4/argp.m4: New file.
25106
25107 2003-08-17  Simon Josefsson  <jas@extundo.com>
25108             Bruno Haible  <bruno@clisp.org>
25109
25110         * lib/xstrndup.h: New file.
25111         * lib/xstrndup.c: New file.
25112
25113 2003-08-17  Bruno Haible  <bruno@clisp.org>
25114
25115         * modules/strndup (Files, Include): Add lib/strndup.h.
25116
25117 2003-08-17  Bruno Haible  <bruno@clisp.org>
25118
25119         * modules/euidaccess (Files): Add lib/euidaccess.h.
25120
25121 2003-08-17  Bruno Haible  <bruno@clisp.org>
25122
25123         * lib/strndup.h: New file.
25124
25125 2003-08-17  Bruno Haible  <bruno@clisp.org>
25126
25127         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
25128         like AC_GNU_SOURCE.
25129         * modules/extensions (configure.ac): Comment out the invocation of
25130         gl_USE_SYSTEM_EXTENSIONS.
25131
25132 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25133
25134         Merges from coreutils, etc.
25135         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
25136         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
25137         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
25138         fixing a typo.
25139         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
25140         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
25141
25142 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25143
25144         Document merge from coreutils.
25145         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
25146         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
25147         * modules/utime: Add m4/utimes-null.m4.
25148
25149 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25150
25151         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
25152         space, undoing this 2003-08-12 change:
25153         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25154
25155 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25156
25157         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
25158         strtoul.c from libc, undoing this 2003-08-12 change:
25159         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25160
25161 2003-08-16  Jim Meyering  <jim@meyering.net>
25162
25163         Merges from coreutils.
25164         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
25165         prefix.  Adjust cache variables similarly.  Create 500 rather than
25166         just 300 files, to exercise bug on Darwin6.5, too.
25167         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
25168         $missing_dir.
25169         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
25170         AM_SYS_POSIX_TERMIOS.
25171         Reported by mkc@mathdogs.com.
25172         Also change use of $am_cv_sys_posix_termios
25173         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
25174         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
25175         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
25176         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
25177         in /proc/mounts until it finds one with matching device number.  This
25178         is unnecessary when the FILE argument *is* a mount point.  No stat call
25179         is necessary in that case.  So, disable the statvfs-testing code on
25180         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
25181         as RedHat bug# 84846.
25182         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25183         to 1MB, so as not to render systems with no stack size limit (e.g.,
25184         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25185         Include <unistd.h>.  On some systems,
25186         it is required for the definition of _SC_PAGESIZE.
25187
25188 2003-08-16  Jim Meyering  <jim@meyering.net>
25189
25190         Merge from coreutils.
25191         * lib/xstrtoimax.c: #else #if -> #elif.
25192         * lib/xstrtoumax.c: Likewise.
25193
25194 2003-08-16  Jim Meyering  <jim@meyering.net>
25195
25196         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
25197         * m4/utimes.m4: Removed.
25198         * m4/utimes-null.m4: Renamed from utimes.m4.
25199
25200         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25201         to 1MB, so as not to render systems with no stack size limit (e.g.,
25202         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25203         Include <unistd.h>.  On some systems,
25204         it is required for the definition of _SC_PAGESIZE.
25205
25206 2003-08-16  Jim Meyering  <jim@meyering.net>
25207         and Paul Eggert  <eggert@cs.ucla.edu>
25208
25209         Merges from coreutils, etc.
25210
25211         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
25212         using the latest version from cvs.  This avoids problems with #line
25213         directives using a vendor (Sun) compiler.
25214         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
25215         Don't set GETGROUPS_LIB here; now it's
25216         done via getgroups.m4's wrapper function.
25217         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
25218         rather than just in sh-util/configure.in, so that the
25219         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
25220         same.
25221         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
25222         AC_FUNC_GETLOADAVG where to find getloadavg.c.
25223         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
25224         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
25225         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
25226         Remove code that is now done by the newly-required macros.
25227         Append $(EXEEXT) to DF_PROG.
25228         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
25229         Do not invoke or require the following here,
25230         since prereq.m4 or some gnulib .m4 now does this for us:
25231         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
25232         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
25233         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
25234         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
25235         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
25236         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
25237         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
25238         AC_FUNC_OBSTACK.
25239         Do not replace the following functions, as this is now the job
25240         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
25241         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
25242         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
25243         atexit getpass, strdup, getpagesize.
25244         Replace 'raise'.
25245         Do not check for the following functions, as this is now the job
25246         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
25247         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
25248         setregid.
25249         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
25250         Check for sys/sysctl.h.
25251         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
25252         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
25253         of checking for ssize_t ourselves.
25254
25255         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
25256         Require every macro that gnulib/modules/* suggests for us.
25257         (jm_PREREQ_ADDEXT): New macro.
25258         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
25259         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
25260
25261         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
25262         (gl_PHYSMEM): Use it.
25263         Also check for `table' function.
25264         Check for new headers and functions.
25265         Add check for sys/sysmp.h.
25266         With suggestions from Kaveh Ghazi.
25267         Ignore headers that are present but cannot be compiled.  This
25268         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
25269         C 5.4.
25270
25271 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25272
25273         Document merge from coreutils.
25274         * modules/userspec: Depend on posixver.
25275         * modules/strftime: Depend on tzset.
25276
25277 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25278
25279         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
25280         rather than tab, after '#' in shell-script copyright notices.
25281         Suggested by Bruno Haible.
25282
25283 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25284
25285         * config/srclist-update: Use three spaces, rather than tab, after '#'
25286         in shell-script copyright notices.  Suggested by Bruno Haible.
25287         Remove unnecessary parenthesization in regular expression.
25288
25289 2003-08-15  Jim Meyering  <jim@meyering.net>
25290
25291         Merge from coreutils.
25292         * lib/xgethostname.c: Include <stdlib.h>.
25293         (xghostname): Don't exit for anything other than memory-related
25294         failure; just return NULL.
25295         * lib/userspec.c: Include "posixver.h".
25296         (parse_user_spec): Accept `.' as a separator only
25297         in pre-POSIX-200112 mode.
25298         * lib/strtoimax.c: Use #elif rather than #else #if.
25299         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
25300         Remove function, now that we can rely on a working tzset function.
25301         [!_LIBC]: Ensure that the required autoconf test has been run.
25302         [!defined _NL_CURRENT && HAVE_STRFTIME]:
25303         Use underlying_strftime for %r.
25304         * lib/sha.c: Merge in some clean-up and optimization changes from
25305         glibc.
25306         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
25307         Ensure that it is a multiple of 64.
25308         Rearrange loop exit tests so as to avoid performing an
25309         additional fread after encountering an error or EOF.
25310         * lib/realloc.c: Update copyright date.
25311
25312 2003-08-15  Jim Meyering  <jim@meyering.net>
25313         and Paul Eggert  <eggert@twinsun.com>
25314
25315         Merge from coreutils.
25316         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
25317         member but strut utmpx does not.  Needed for AIX 4.3.3.
25318         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
25319
25320 2003-08-15  Jim Meyering  <jim@meyering.net>
25321         and Paul Eggert  <eggert@cs.ucla.edu>
25322
25323         Merges from coreutils, etc.
25324         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
25325         Require gl_FUNC_TZSET_CLOBBER.
25326         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
25327         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
25328         members.
25329
25330 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25331
25332         Help the merge from coreutils.
25333         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
25334         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
25335         * m4/tzset.m4: Use it too.
25336
25337 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25338
25339         * modules/tzset: New file.
25340
25341 2003-08-14  Jim Meyering  <jim@meyering.net>
25342
25343         Merges from coreutils.
25344         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
25345         variable names, rather than @FNMATCH_H@.
25346         * modules/alloca: Likewise for $(ALLOCA_H).
25347
25348         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
25349         the three copies of the literal target, `fnmatch.h'.
25350         * modules/alloca (alloca.h): Likewise.
25351
25352 2003-08-14  Jim Meyering  <jim@meyering.net>
25353
25354         Merge from coreutils.
25355         * m4/tzset.m4: New file.
25356         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
25357         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
25358         otherwise, AIX 5.1 systems would end up using the latter.
25359         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
25360         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
25361         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
25362         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
25363
25364 2003-08-14  Jim Meyering  <jim@meyering.net>
25365
25366         Merge from coreutils.
25367         * lib/obstack.h: Whitespace changes.
25368         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
25369         and xcalloc return values.
25370         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
25371         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
25372         hang on OSF/1 5.1 for DIR on both local and remote file systems.
25373         Reported by (and fix confirmed by) Nelson H. F. Beebe.
25374         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
25375         error from mntctl.
25376         Use mntctl's return value to drive the entry-processing loop, since
25377         we can't rely on the value of the vmt_length member in the last
25378         entry.  On some systems doing so could result in exhausting
25379         virtual memory.  Based in part on a patch from Mike Jetzer.
25380
25381 2003-08-14  Jim Meyering  <jim@meyering.net>
25382         and Paul Eggert  <eggert@twinsun.com>
25383
25384         Merges from coreutils, plus other fixes.
25385         * lib/physmem.c: Merge in portability changes from gcc/libiberty
25386         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
25387         for credits and details.  Thanks to Kaveh Ghazi for helping
25388         to keep these files in sync.
25389         (ARRAY_SIZE): Define it.
25390         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
25391         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
25392         (memcasecmp): Don't assume size_t fits in unsigned int.
25393         Remove casts and duplicate code.
25394         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
25395         (memcpy): Remove definition.
25396         Merge in some clean-up and optimization changes from glibc.
25397         [BLOCKSIZE]: Move definition to top of file.
25398         Ensure that it is a multiple of 64.
25399         Rearrange loop exit tests so as to avoid performing an
25400         additional fread after encountering an error or EOF.
25401         * lib/md5.h (md5_uintptr): Define.
25402         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
25403         return to the initial working directory.  Preserve errno
25404         for caller.
25405         * lib/idcache.c: Include "xalloc.h".
25406         (xmalloc, xrealloc): Remove decls.
25407         (getuser): Remove casts no longer required in C89.
25408         * lib/human.c: Include stdio.h, for sprintf.
25409         * lib/group-member.c: Include "xalloc.h".
25410         (xmalloc, xrealloc): Remove decls.
25411         (get_group_info): Remove casts no longer required in C89.
25412         * lib/getusershell.c (readname): Remove casts no longer required in
25413         C89.
25414         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25415         * lib/getline.c: Whitespace fix, from coreutils.
25416
25417 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25418
25419         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25420         Check for isascii.
25421
25422         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25423         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25424         Undo previous (whitespace-only) change.
25425
25426 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25427
25428         * lib/exclude.c: Include <ctype.h>
25429         (IN_CTYPE_DOMAIN): New macro.
25430         (is_space): New fn.
25431         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25432         and empty lines.
25433
25434         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25435         Undo previous (whitespace-only) change.
25436
25437 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25438
25439         * config/srclist-update: Change update back to the old behavior,
25440         leaving whitespace alone.  Use one 'sed' command rather than a
25441         pipeline.
25442         (fixlicense): Now a variable, not a function.
25443         (remove_trailing_blanks): Remove.
25444         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25445         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25446         Undo previous (whitespace-only) change.
25447
25448 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25449
25450         Merge from coreutils.
25451         * modules/euidaccess: Add lib_SOURCES, include for new
25452         file euidaccess.h
25453
25454 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25455
25456         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25457         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25458         Normalize leading white space and remove trailing white space.
25459
25460         Merge from coreutils
25461         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25462
25463         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25464         0.12.1.  These files are now being upgraded automatically by
25465         ../config/srclist-update.
25466
25467 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25468
25469         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25470         Normalize leading white space and remove trailing white space.
25471         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25472         notice, as per ../config/srclist-update.
25473
25474         Merge from coreutils.
25475         * lib/euidaccess.h: New file.
25476         * lib/euidaccess.c: Include it.
25477         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25478         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25479         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25480
25481 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25482
25483         * config/srclist-update: Add copyright notice.
25484         (remove_id_lines, remove_trailing_blanks): New constants.
25485         (fixfile): Use them to normalize spacing a bit in copied files.
25486         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25487         Normalize leading white space and remove trailing white space.
25488
25489         * config/texinfo.tex: Sync with texinfo.
25490
25491         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25492         strtoul.c from libc, to merge coreutils whitespace changes.
25493
25494         * config/srclist.txt: Get the following m4 files from gettext:
25495         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25496         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25497         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25498         wint_t.m4.
25499
25500 2003-08-12  Karl Berry  <karl@gnu.org>
25501
25502         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25503         been made.
25504
25505 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25506
25507         * modules/gnu-source, m4/gnu-source.m4:
25508         Remove; we're assuming Autoconf 2.54 or later now.
25509         Suggested by Bruno Haible.
25510         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25511
25512 2003-08-11  Bruno Haible  <bruno@clisp.org>
25513
25514         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25515
25516 2003-08-11  Bruno Haible  <bruno@clisp.org>
25517
25518         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25519         (vasnprintf): Use it instead of wcslen.
25520
25521 2003-08-11  Bruno Haible  <bruno@clisp.org>
25522
25523         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25524         value to ensure that _Bool promotes to int. Use #define for _Bool when
25525         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25526
25527 2003-08-10  Karl Berry  <karl@gnu.org>
25528
25529         * lib/regex.h: update from libc (whitespace fix).
25530
25531 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25532
25533         Merge some files from coreutils.  These changes were
25534         originally made by Jim Meyering.
25535         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25536         many older Unixes require this.
25537         * lib/alloca.c (alloca): Remove cast to argument of free;
25538         no longer needed in C89.
25539         * lib/alloca_.h, regex.h: Fix white space to match
25540         what GNU indent does.
25541
25542 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25543
25544         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25545         apparently Emacs's Unicode mode got confused before my 2003-08-05
25546         checkin.
25547
25548 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25549
25550         * m4/extensions.m4: New file.
25551         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25552         Require gl_USE_SYSTEM_EXTENSIONS.
25553         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25554         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25555
25556 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25557
25558         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25559         * modules/extensions, modules/gnu-source: New files.
25560         * modules/timespec, modules/unlocked-io: Depend on extensions.
25561
25562 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25563
25564         * modules/restrict: New file.
25565         * MODULES.html.sh (func_all_modules): Add restrict.
25566         * modules/regex: Depend on restrict.
25567
25568 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25569
25570         * m4/restrict.m4: New file.
25571         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25572
25573 2003-08-07  Bruno Haible  <bruno@clisp.org>
25574
25575         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25576         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25577
25578 2003-08-07  Bruno Haible  <bruno@clisp.org>
25579
25580         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25581         makes the module 'getndelim2' compatible with the module 'getline'.
25582
25583 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25584
25585         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
25586         byte with "\201" to avoid glitches when editing that source file
25587         with multi-gnome-terminal.
25588
25589 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25590
25591         * lib/bumpalloc.h: Remove.
25592
25593 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25594
25595         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
25596         * modules/bumpalloc: Remove.
25597
25598 2003-08-04  Paul Eggert  <eggert@twinsun.com>
25599
25600         * lib/getloadavg.c: Change copyright notice and spacing to conform to
25601         GNU coding style.
25602
25603         Merge from coreutils.
25604         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
25605         1. From glibc.
25606         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
25607         from Karl Berry, implemented by Jim Meyering.
25608         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
25609         from Dmitry V. Levin.
25610         Remove anachronistic cast of xrealloc.
25611         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
25612         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
25613         type. Otherwise, it wouldn't compile with at least /bin/cc on
25614         ymp-cray-unicos9.0.2.X.
25615         Combine two mostly-identical uses of alloca into one.
25616         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
25617
25618 2003-08-04  Dave Love  <d.love@dl.ac.uk>
25619
25620         [From Emacs.]
25621
25622         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
25623         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
25624         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
25625         obsolete NLIST_NAME_UNION.
25626         [__GNU__]: Undef BSD and FSCALE.
25627         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
25628
25629 2003-08-03  Paul Eggert  <eggert@twinsun.com>
25630
25631         * lib/stdbool_.h (_Bool): Make it signed char, instead of
25632         an enum type, so that it's guaranteed to promote to int.  See:
25633         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
25634
25635 2003-08-03  Karl Berry  <karl@gnu.org>
25636
25637         * config/depcomp: update from automake.
25638
25639 2003-07-31  Paul Eggert  <eggert@twinsun.com>
25640
25641         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
25642         (strerror): Don't assume that a printable int fits in 14 bytes.
25643
25644 2003-07-31  Bruno Haible  <bruno@clisp.org>
25645
25646         * modules/getpass-gnu: New file.
25647         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
25648
25649 2003-07-31  Bruno Haible  <bruno@clisp.org>
25650
25651         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
25652
25653 2003-07-24  Karl Berry  <karl@gnu.org>
25654
25655         * config/missing: update from automake.
25656
25657 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
25658             Bruno Haible  <bruno@clisp.org>
25659
25660         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
25661         * lib/getline.c (getline, getdelim): Likewise.
25662         Remove _GNU_SOURCE define; now it's defined in config.h through
25663         m4/getline.m4.
25664
25665 2003-07-23  Karl Berry  <karl@gnu.org>
25666
25667         * config/config.sub: update from prep.
25668
25669 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25670
25671         * modules/xalloc (Depends-on): Add exitfail.
25672         * modules/xmemcoll: Likewise.
25673
25674 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25675
25676         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
25677         over-parenthesization in macros.
25678
25679         Sync with coreutils.
25680
25681         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
25682         required by C99.
25683
25684         Use `exit_failure' for xalloc and xmemcoll instead of their own
25685         private exit-failure variables.
25686         * lib/xalloc.h (xalloc_exit_failure): Remove.
25687         * lib/xmalloc.c: Likewise.  Include exitfail.h.
25688         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
25689         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
25690         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
25691         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
25692
25693 2003-07-20  Jim Meyering  <jim@meyering.net>
25694
25695         * modules/closeout (Depends-on): Add exitfail.
25696         Suggestion from Bruno Haible.
25697
25698 2003-07-19  Karl Berry  <karl@gnu.org>
25699
25700         * config/config.sub: update from prep.
25701
25702 2003-07-18  Paul Eggert  <eggert@twinsun.com>
25703
25704         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
25705         Remove.
25706         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
25707         to test that it can stand by itself.  Include "exitfail.h".
25708         Clients should set exit_failure instead.
25709         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
25710
25711 2003-07-18  Bruno Haible  <bruno@clisp.org>
25712
25713         * modules/getndelim2: New file.
25714         * modules/getline: Share files with module getndelim2.
25715         * modules/getnline: Depend on getndelim2 instead of sharing files with
25716         it. Add getnline.c to lib_SOURCES.
25717         * MODULES.html.sh (func_all_modules): Add getndelim2.
25718
25719 2003-07-18  Bruno Haible  <bruno@clisp.org>
25720
25721         * m4/getndelim2.m4: New file.
25722         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
25723         invoke gl_PREREQ_GETNDELIM2.
25724         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
25725         gl_PREREQ_GETNDELIM2.
25726         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
25727         gl_GETNDELIM2.
25728
25729 2003-07-18  Bruno Haible  <bruno@clisp.org>
25730
25731         * lib/getndelim2.h: New file.
25732         * lib/getndelim2.c: Make into a module of its own. Include config.h,
25733         getndelim2.h.
25734         (getndelim2): Make non-static. Change return type to ssize_t.
25735         * lib/getline.h: Change argument names.
25736         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
25737         * lib/getnline.c: Include getndelim2.h.
25738
25739 2003-07-18  Andreas Schwab  <schwab@suse.de>
25740
25741         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
25742
25743 2003-07-17  Karl Berry  <karl@gnu.org>
25744
25745         * config/config.sub: update from prep.
25746
25747 2003-07-17  Bruno Haible  <bruno@clisp.org>
25748
25749         * modules/getnline: New file.
25750         * modules/getline: Add lib/getndelim2.c to source file list.
25751         * MODULES.html.sh (func_all_modules): Add getnline.
25752
25753 2003-07-17  Bruno Haible  <bruno@clisp.org>
25754
25755         * m4/getnline.m4: New file.
25756
25757 2003-07-17  Bruno Haible  <bruno@clisp.org>
25758
25759         * m4/Makefile.am.in: Remove file.
25760         * m4/Makefile.am: Remove file.
25761         * m4/Makefile.in: Remove file.
25762
25763 2003-07-17  Bruno Haible  <bruno@clisp.org>
25764
25765         * lib/getnline.h: New file.
25766         * lib/getnline.c: New file.
25767         * lib/getndelim2.c: New file, extracted from getline.c.
25768         (getndelim2): Renamed from getdelim2, with added nmax argument.
25769         * lib/getline.c: Include getndelim2.c.
25770         (getdelim2): Moved out to getndelim2.c.
25771         (getline, getdelim): Update.
25772
25773 2003-07-17  Bruno Haible  <bruno@clisp.org>
25774
25775         * lib/Makefile.am: Remove file.
25776         * lib/Makefile.in: Remove file.
25777
25778 2003-07-17  Bruno Haible  <bruno@clisp.org>
25779
25780         * configure.in: Remove file.
25781         * Makefile.in: Remove file.
25782
25783 2003-07-17  Bruno Haible  <bruno@clisp.org>
25784
25785         * MODULES.html.sh: Put the </BODY> right before </HTML>.
25786
25787 2003-07-16  Karl Berry  <karl@gnu.org>
25788
25789         * config/srclist-update: was running fixlicense twice, which caused
25790                 texinfo.tex to be nullified for some reason.  Simplify,
25791                 $gplsrc is no longer needed as far as I can see?
25792
25793 2003-07-16  Jim Meyering  <jim@meyering.net>
25794
25795         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
25796
25797 2003-07-15  Paul Eggert  <eggert@twinsun.com>
25798
25799         * config/srclist.txt: Get the following files from gettext-runtime/intl
25800         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
25801         ref-del.sin.  From Bruno Haible.
25802         * config/srclist-update (fixfile): Change grep pattern again, since the
25803         previous fix didn't work (there was another trailing $).  Use
25804         '[$]' to escape the $s.
25805
25806 2003-07-15  Karl Berry  <karl@gnu.org>
25807
25808         * lib/vasnprintf.c: update from gettext.
25809
25810 2003-07-15  Karl Berry  <karl@gnu.org>
25811
25812         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
25813         gets expanded when surrounded by '$'.
25814
25815 2003-07-15  Jim Meyering  <jim@meyering.net>
25816
25817         * modules/save-cwd: Don't depend on error.  From Derek Price.
25818
25819 2003-07-15  Jim Meyering  <jim@meyering.net>
25820
25821         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
25822
25823 2003-07-14  Simon Josefsson  <jas@extundo.com>
25824
25825         * modules/mempcpy: New file.
25826         * MODULES.html.sh (func_all_modules): Add mempcpy.
25827
25828 2003-07-14  Simon Josefsson  <jas@extundo.com>
25829
25830         * m4/mempcpy.m4: New file.
25831
25832 2003-07-14  Simon Josefsson  <jas@extundo.com>
25833
25834         * lib/mempcpy.h: New file.
25835         * lib/mempcpy.c: New file.
25836
25837 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25838
25839         * modules/getdate, modules/posixtm: Depend on mktime.
25840
25841 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25842
25843         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
25844         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
25845         unicodeio.c, unicodeio.h, unlocked-io.h:
25846         Switch from LGPL to GPL.
25847
25848 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25849
25850         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
25851         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
25852         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
25853         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
25854         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
25855         updated automatically by ../config/srclist-update.  This changes
25856         their license from LPGL to GPL.
25857
25858 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25859
25860         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
25861         assumed to refer to the root of the most recent stable gettext version.
25862         * config/srclistvars.sh: Add defaults for eggert.
25863         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
25864         Match "This program" as well as "The program".  This is needed
25865         for gettext.
25866
25867 2003-07-14  Jim Meyering  <jim@meyering.net>
25868
25869         Don't emit diagnostics.  Let callers do that.
25870         * lib/save-cwd.c: Don't include "error.h".
25871         (save_cwd): Don't call error.  Ensure that errno is valid
25872         when returning nonzero.
25873
25874         * lib/save-cwd.h (restore_cwd): Update prototype.
25875         * lib/save-cwd.c (restore_cwd): Remove two parameters.
25876         Simplify.  Don't call error upon failure.  Let callers do that.
25877         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
25878         when auditing is enabled.  But don't bother updating the #if.
25879
25880 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
25881
25882         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
25883         it breaks C++ compilation.
25884         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
25885
25886 2003-07-10  Simon Josefsson  <jas@extundo.com>
25887
25888         * modules/strchrnul (Makefile.am): Add strchrnul.h.
25889
25890 2003-07-10  Jim Meyering  <jim@meyering.net>
25891
25892         * m4/clock_time.m4: Remove trailing blank.
25893         * m4/intmax_t.m4: Likewise.
25894
25895 2003-07-10  Jim Meyering  <jim@meyering.net>
25896
25897         * lib/vasnprintf.c: Remove trailing blanks.
25898         Make cpp indentation consistent.
25899
25900 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25901
25902         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
25903         posixver.c, strftime.c, strnlen.c, strverscmp.c:
25904         Switch from LGPL to GPL.
25905
25906 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25907
25908         * config/srclist.txt: Sort sublists.  Add
25909         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
25910         that differ from gnulib for one reason or another; we'd like this list
25911         to be smaller but for now let's document what we have.
25912
25913 2003-07-08  Paul Eggert  <eggert@twinsun.com>
25914
25915         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
25916         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
25917         and sweeter "eval x=$x".
25918         * config/srclist.txt: Get lib/argp* from glibc.
25919
25920 2003-07-07  Paul Eggert  <eggert@twinsun.com>
25921
25922         * lib/mktime.c: Fix some boundary cases and remove need for floating
25923         point.
25924
25925         Issue a compile-time diagnostic if time_t is floating point, or if
25926         two's complement arithmetic is not in effect, or if arithmetic
25927         right shift does not propagate the sign.  These assumptions were
25928         all in the original code but they weren't checked.
25929
25930         (TIME_T_MIDPOINT, verify): New macros.
25931         (__isleap): Remove; it has integer overflow problems.
25932         (leapyear): New function, without those problems.
25933         (ydhms_tm_diff): Remove; splitting into two parts.
25934         (ydhms_diff): New function, containing the arithmetic part of
25935         the old ydhms_tm_diff function.  Issue a compile-time
25936         diagnostic if we are not using C99 integer division.
25937         Avoid casts when possible.
25938         (guess_time_tm): New function, containing the checking part of
25939         the old ydhms_tm_diff function.  Return the new value, rather than
25940         the difference between it and the old.  Accept a new argument T
25941         so that *T specifies the old value.  Check for overflow in the result.
25942
25943         (__mktime_internal): Use a time_t offset, not a long int offset.
25944         This undoes the 2003-06-04 change, which is no longer needed now
25945         that we have better overflow checking.
25946         (localtime_offset): Likewise.
25947
25948         (__mktime_internal): Avoid harmful overflow on hosts where time_t
25949         and long are 64-bit but int is only 32-bit.
25950         (ydhms_diff): Use long int to store year1 and yday1.
25951         Issue a compile-time diagnostic if long int is not wide enough.
25952
25953         (__mktime_internal): Use long int to store adjusted year and yday.
25954         Use plain C rather than preprocessor commands, if that doesn't
25955         affect efficiency.
25956         Check for overflow (and try to repair) after each probe
25957         rather than checking only at the very end.  This avoids some bugs
25958         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
25959         does not equal GMT offset at maximum time).
25960         Use integer to check for overflow rather than floating point; this
25961         is more portable to non-IEEE hosts, and is a tad faster.
25962         When we detect that we are oscillating between two values,
25963         don't check whether tm_isdst has the requested value, since
25964         we already know the answer.  When tm_isdst has the wrong value,
25965         use a different heuristic to find the right one, based on the
25966         extreme values actually observed in practice in tz2003a,
25967         rather than the (overly optimistic) "previous 3 calendar quarters".
25968
25969         (not_equal_tm, print_tm, check_result): Use "const T" rather than
25970         "T const" to accommodate glibc style.
25971         (check_result): Use less-confusing report format.  "long" -> "long int.
25972         (main): Likewise.
25973         Don't loop if the iteration overflows time_t.
25974         Allow a negative step in the iteration.
25975
25976 2003-07-06  Karl Berry  <karl@gnu.org>
25977
25978         * config/depcomp: update from automake.
25979         * config/config.sub: update from prep.
25980
25981 2003-07-03  Karl Berry  <karl@gnu.org>
25982
25983         * config/config.guess: update from prep.
25984
25985 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25986
25987         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
25988         xreadlink.c now includes it unconditionally.
25989
25990 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25991
25992         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
25993         having it depend on HAVE_SYS_TYPES_H.
25994
25995 2003-07-01  Bruno Haible  <bruno@clisp.org>
25996
25997         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
25998         <sys/types.h> should be sufficient.
25999         Reported by Paul Eggert.
26000
26001 2003-06-26  Karl Berry  <karl@gnu.org>
26002
26003         * config/depcomp: update from automake.
26004
26005 2003-06-26  Bruno Haible  <bruno@clisp.org>
26006
26007         * modules/human: Depend on module stdbool.
26008
26009 2003-06-25  Bruno Haible  <bruno@clisp.org>
26010
26011         * modules/readlink: New file.
26012         * modules/xreadlink: Depend on it.
26013         * MODULES.html.sh (func_all_modules): Add readlink.
26014
26015 2003-06-25  Bruno Haible  <bruno@clisp.org>
26016
26017         * m4/readlink.m4: New file.
26018
26019 2003-06-25  Bruno Haible  <bruno@clisp.org>
26020
26021         * lib/readlink.c: New file.
26022
26023 2003-06-22  Karl Berry  <karl@gnu.org>
26024
26025         * config/srclist.txt: update mkinstalldirs from automake.
26026         * config/mkinstalldirs: update.
26027
26028 2003-06-22  Bruno Haible  <bruno@clisp.org>
26029
26030         Portability to mingw32.
26031         * m4/ssize_t.m4: New file, from GNU gettext.
26032         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
26033         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
26034
26035 2003-06-22  Bruno Haible  <bruno@clisp.org>
26036
26037         * modules/safe-read: Add m4/ssize_t.m4.
26038         * modules/xreadlink: Add m4/ssize_t.m4.
26039
26040 2003-06-20  Bruno Haible  <bruno@clisp.org>
26041
26042         Assume C89, so PARAMS isn't needed.
26043         * lib/unicodeio.h (PARAMS): Remove.
26044         * lib/unicodeio.c: Don't use PARAMS.
26045
26046 2003-06-18  Karl Berry  <karl@gnu.org>
26047
26048         * config/config.{guess,sub}: update from prep.
26049
26050 2003-06-18  Jim Meyering  <jim@meyering.net>
26051
26052         Merge changes from coreutils.
26053         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
26054         Remove explicit declarations of xmalloc and realloc.
26055         Include xalloc.h.
26056         (read_utmp): Remove anachronistic cast of xmalloc.
26057
26058 2003-06-17  Paul Eggert  <eggert@twinsun.com>
26059
26060         Assume C89, so PARAMS isn't needed.
26061         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
26062         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
26063         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
26064         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
26065         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
26066         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
26067         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
26068         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
26069         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
26070         lib/xstrtod.h, lib/xstrtol.h: Likewise.
26071         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
26072         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
26073         no longer needed. Anyway, config.h should always be included before any
26074         other file.
26075
26076 2003-06-11  Simon Josefsson  <jas@extundo.com>
26077
26078         * modules/sysexits: New file.
26079         * MODULES.html.sh (func_all_modules): Add sysexits.
26080
26081 2003-06-11  Simon Josefsson  <jas@extundo.com>
26082
26083         * lib/sysexit_.h: New file.
26084
26085 2003-06-11  Derek Price  <derek@ximbiot.com>
26086
26087         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
26088         necessary.
26089
26090 2003-06-11  Bruno Haible  <bruno@clisp.org>
26091
26092         * m4/sysexits.m4: New file.
26093
26094 2003-06-10  Simon Josefsson  <jas@extundo.com>
26095
26096         * lib/argp.h: New file, from glibc.
26097         * lib/argp-ba.c: New file, from glibc.
26098         * lib/argp-eexst.c: New file, from glibc.
26099         * lib/argp-fmtstream.c: New file, from glibc.
26100         * lib/argp-fmtstream.h: New file, from glibc.
26101         * lib/argp-fs-xinl.c: New file, from glibc.
26102         * lib/argp-help.c: New file, from glibc.
26103         * lib/argp-namefrob.h: New file, from glibc.
26104         * lib/argp-parse.c: New file, from glibc.
26105         * lib/argp-pv.c: New file, from glibc.
26106         * lib/argp-pvh.c: New file, from glibc.
26107         * lib/argp-xinl.c: New file, from glibc.
26108
26109 2003-06-10  Simon Josefsson  <jas@extundo.com>
26110
26111         * modules/strchrnul: New file.
26112
26113 2003-06-10  Simon Josefsson  <jas@extundo.com>
26114
26115         * modules/argp: New file.
26116
26117 2003-06-10  Simon Josefsson  <jas@extundo.com>
26118
26119         * m4/strchrnul.m4: New file.
26120
26121 2003-06-10  Simon Josefsson  <jas@extundo.com>
26122
26123         * lib/strchrnul.h: New file.
26124         * lib/strchrnul.c: New file.
26125
26126 2003-06-10  Bruno Haible  <bruno@clisp.org>
26127
26128         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
26129
26130 2003-06-07  Karl Berry  <karl@gnu.org>
26131
26132         * config/config.{guess,sub}: update from prep.
26133
26134 2003-06-07  Jim Meyering  <jim@meyering.net>
26135
26136         * modules/strtod: Use $(...) notation, not @...@ for
26137         AC_REPLACE'd variables.
26138         * modules/localcharset: Likewise.
26139
26140 2003-06-07  Jim Meyering  <jim@meyering.net>
26141
26142         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
26143         in place of my name in the copyright comment.
26144         Remove definition and uses of __P.
26145
26146         From coreutils.
26147         * lib/stat.c: Don't declare xmalloc explicitly.
26148         Instead, include "xalloc.h".
26149         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
26150         xrealloc, and xcalloc return values.
26151         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
26152         Improve comment.
26153         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
26154
26155 2003-06-07  Bruno Haible  <bruno@clisp.org>
26156
26157         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
26158         avoid AC_CONFIG_LINKS.
26159         * modules/fnmatch (Makefile.am): Use explicit creation rule for
26160         fnmatch.h, to avoid AC_CONFIG_LINKS.
26161         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
26162
26163 2003-06-07  Bruno Haible  <bruno@clisp.org>
26164
26165         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
26166         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
26167         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26168         directory.
26169         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
26170         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26171         directory.
26172
26173 2003-06-06  Jim Meyering  <jim@meyering.net>
26174
26175         Merge from coreutils.
26176         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
26177         Consolidate declarations and initializations of *_base* locals.
26178
26179         Merge from coreutils.
26180         This avoids a core dump on systems without GNU putenv,
26181         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
26182         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
26183         (unsetenv): New static function, from GNU libc.
26184         (rpl_putenv): Use it.
26185
26186         * lib/modechange.c: Remove trailing blanks.
26187
26188         Merge from coreutils.
26189         * lib/fsusage.c: Remove declaration of statfs.
26190         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
26191
26192         * lib/posixtm.c: Include <stdbool.h> unconditionally.
26193
26194 2003-06-06  Jim Meyering  <jim@meyering.net>
26195
26196         * lib/stdbool_.h: Renamed from stdbool.h.in.
26197
26198 2003-06-06  Jim Meyering  <jim@meyering.net>
26199             Bruno Haible  <bruno@clisp.org>
26200
26201         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
26202         Adjust Makefile.am snippet not to redirect directly to target.
26203         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
26204
26205 2003-06-05  Paul Eggert  <eggert@twinsun.com>
26206
26207         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
26208         mismatch, look in future quarters as well as past.  This fixes a
26209         bug when processing fall-backwards gaps immediately after a long
26210         period of daylight-saving time.
26211
26212         * lib/mktime.c: Assume freestanding C89 or better.
26213         (HAVE_LIMITS_H): Remove.  Assume it's 1.
26214         (__P): Remove; not used.
26215         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
26216         (mktime, not_equal_tm, print_tm, check_result,
26217         main): Use prototypes.  Use const * where appropriate.
26218         (main): Fix typo in testing code that uncovered by above changes.
26219         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
26220
26221 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26222
26223         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
26224         locale.h, localeconv.  This merges changes from coreutils.
26225
26226         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
26227         It can be removed after the next Autoconf is released.
26228         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
26229         needed.
26230
26231 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26232
26233         * lib/mktime.c: Fix Debian bug 177940
26234         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
26235         (localtime_offset): Now long int, not time_t, because we want it
26236         to be guaranteed to be signed.  All uses changed.
26237         (__mktime_internal): If overflow would occur when adding offset,
26238         don't add it.
26239
26240         Merge 'human' changes from coreutils.  Rewrite to support
26241         locale-specific notations like thousands separators.
26242         * lib/human.c: Simplify authorship notice.
26243         Include human.h immediately after config.h.
26244         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
26245         <limits.h>: Do not include, since human.h does.
26246         (SIZE_MAX, UINTMAX_MAX): New macros.
26247         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
26248         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
26249         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
26250         (power_letter): Renamed from suffixes.
26251         (generate_suffix_backwards): Remove.
26252         (adjust_value): Now takes int style (because of human.h changes)
26253         and long double value (for greater precision on some platforms).
26254         (group_number): New function.
26255         (human_readable): Use it.  Use integer options, not enum.
26256         Put the options before the sizes in the arg list.
26257         Support all the new options.
26258         The old human_readable function has been removed;
26259         use inttostr.h instead.
26260         (human_readable, default_block_size, humblock):
26261         Use uintmax_t, not int, for block sizes.
26262         (human_readable_inexact, block_size_types): Remove.
26263         (block_size_opts): New constant.
26264         (human_options): Renamed from human_block_size, with new signature
26265         that allows block sizes up to UINTMAX_MAX.  All callers changed.
26266         * lib/human.h: Add copyright and authorship notice.
26267         Include <limits.h> and <stdbool.h> unconditionally.
26268         (PARAMS): Remove.  All uses removed.
26269         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
26270         (enum human_inexact_style): Remove tag; now a nameless enum.
26271         (human_floor, human_ceiling, human_round_to_even): Now have
26272         values 2, 0, 1 rather than -1, 1, 0.
26273         (human_group_digits, human_suppress_point_zero, human_autoscale,
26274         human_base_1024, human_SI, human_B): New constants.
26275         (human_readable_inexact, human_block_size): Remove.
26276         (human_readable): Size args are now uintmax_t, not int.
26277         (human_options): New decl.
26278
26279         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
26280         unnecessary now that we assume C89 or better.  This change
26281         imported from coreutils.
26282
26283         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26284         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
26285         in the 2003-05-30 sync from glibc.
26286
26287         .h files should stand alone, but we shouldn't include <sys/types.h>
26288         if we can get away with just <stddef.h>.
26289
26290         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
26291         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
26292         rather than <sys/types.h>, as we merely need size_t.
26293         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
26294         to get size_t.
26295         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
26296         Include <stdio.h>, to get FILE.
26297         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
26298         memcasecmp.h has included <stddef.h> and all we need is size_t.
26299         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
26300         our interface, instead of including <sys/types.h>
26301
26302 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26303
26304         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
26305         now, as glibc mktime is buggy on non-glibc systems.
26306
26307 2003-06-03  Karl Berry  <karl@gnu.org>
26308
26309         * config/config.sub: update from prep.
26310
26311 2003-06-02  Paul Eggert  <eggert@twinsun.com>
26312
26313         [from coreutils]
26314         Fix some minor time-related bugs with POSIX time arguments.
26315         Some valid time stamps were being rejected (notably -1, and
26316         time stamps before 1900 on 64-bit hosts).  And some invalid
26317         time stamps were being accepted, e.g. September 31.
26318
26319         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
26320         that we can return (time_t) -1 successfully.
26321         * lib/posixtm.c: Likewise.
26322         [HAVE_STDBOOL_H]: Include <stdbool.h>.
26323         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
26324         (t): Remove static var.
26325         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
26326         of static var.  All uses changed.
26327         (year): Do not reject years before 1900; they can occur with
26328         64-bit time_t.
26329         (posix_time_parse): Do not check for out-of-range components;
26330         that is now the caller's responsibility, since our checks were
26331         only approximations.
26332         (posixtime): Use mktime to check for out-of-range components,
26333         since it knows them exactly.
26334         If mktime returns (time_t) -1, check whether an error actually occurred
26335         by invoking localtime on -1.
26336         (main) [TEST_POSIXTIME]: Check for input data errors, and report
26337         posixtime failures better.
26338         Improve the test data (in comments only).
26339
26340 2003-06-02  Karl Berry  <karl@gnu.org>
26341
26342         * config/mkinstalldirs (version): new variable.
26343         (--version): new option.
26344         (usage): improve message.
26345
26346 2003-05-30  Karl Berry  <karl@gnu.org>
26347
26348         * lib/mktime.c: update from libc.
26349
26350 2003-05-30  Bruno Haible  <bruno@clisp.org>
26351
26352         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
26353         * config/config.rpath: Upgrade to gettext-0.12.1.
26354
26355 2003-05-30  Bruno Haible  <bruno@clisp.org>
26356
26357         * m4/gettext.m4: Upgrade to gettext-0.12.1.
26358         * m4/nls.m4: New file, from gettext-0.12.1.
26359         * m4/po.m4: New file, from gettext-0.12.1.
26360         * m4/progtest.m4: Upgrade to gettext-0.12.1.
26361
26362 2003-05-30  Bruno Haible  <bruno@clisp.org>
26363
26364         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
26365         * lib/localcharset.h: Likewise.
26366         * lib/localcharset.c: Likewise.
26367
26368 2003-05-29  Karl Berry  <karl@gnu.org>
26369
26370         * config/config.rpath: update from gettext.
26371
26372 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26373
26374         Assume the headers required for C89 freestanding compilers.
26375         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
26376         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
26377         * m4/human.m4 (gl_HUMAN): Likewise.
26378         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
26379         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
26380         * m4/userspec.m4 (gl_USERSPEC): Likewise.
26381         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
26382         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
26383         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
26384
26385 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26386
26387         Assume the headers required for C89 freestanding compilers.
26388         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
26389         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
26390         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
26391         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
26392         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
26393         define, since <limits.h> is guaranteed to do that.
26394         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
26395         * lib/exclude.c: Include <stdbool.h> unconditionally.
26396         * lib/tempname.c: Include <stddef.h> unconditionally.
26397         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
26398         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
26399         <stddef.h> does that.
26400         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
26401         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
26402         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
26403         needed.
26404         * lib/xstrtol.c: Likewise.
26405         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26406         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26407
26408         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26409         warnings on some platforms.
26410
26411         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26412         arbitrarily.
26413
26414 2003-05-26  Jim Meyering  <jim@meyering.net>
26415
26416         Merge in a change from coreutils:
26417         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26418         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26419         that condition, rather than `-1' which is slightly misleading.
26420         Change the name of the cache variable to have the gl_ prefix.
26421         Prompted by a patch from Richard Dawe for DJGPP.
26422
26423 2003-05-24  Karl Berry  <karl@gnu.org>
26424
26425         * config/config.guess: update from prep.
26426
26427 2003-05-22  Karl Berry  <karl@gnu.org>
26428
26429         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26430
26431 2003-05-20  Karl Berry  <karl@gnu.org>
26432
26433         * config/config.guess: update from prep.
26434
26435 2003-05-18  Karl Berry  <karl@gnu.org>
26436
26437         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26438         might actually be set by the user.
26439
26440         * config/depcomp, install-sh, mdate-sh: update from automake.
26441
26442 2003-05-17  Bruno Haible  <bruno@clisp.org>
26443
26444         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26445         invalid expansion for AC_EGREP_CPP.
26446         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26447         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26448         Suggested by Akim Demaille <akim@epita.fr> in
26449         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26450
26451 2003-05-12  Jim Meyering  <jim@meyering.net>
26452
26453         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26454         the space-padded-by-default conversion specifiers, %e, %k, %l.
26455
26456 2003-05-12  Bruno Haible  <bruno@clisp.org>
26457
26458         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26459         the string is longer than 4 KB.
26460
26461 2003-05-11  Karl Berry  <karl@gnu.org>
26462
26463         * config/config.{guess,sub}: update from prep.
26464
26465 2003-05-09  Bruno Haible  <bruno@clisp.org>
26466
26467         * modules/error: Add m4/strerror_r.m4 to file list.
26468
26469 2003-05-03  Bruno Haible  <bruno@clisp.org>
26470
26471         Upgrade to Unicode-4.0.
26472         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26473         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26474         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26475         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26476         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26477         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26478         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26479         Change width of U+E0100..U+E01EF from 1 to 0.
26480
26481 2003-04-25  Jim Meyering  <jim@meyering.net>
26482
26483         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26484         of type size_t, not int.
26485
26486 2003-04-25  Bruno Haible  <bruno@clisp.org>
26487
26488         * lib/copy-file.c: Include <stddef.h>, for size_t.
26489
26490 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26491
26492         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26493         code which expansion is under static control.  Patch imported from
26494         Akim Demaille's patch to Bison; see
26495         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26496
26497 2003-04-14  Bruno Haible  <bruno@clisp.org>
26498
26499         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26500
26501 2003-04-11  Jim Meyering  <jim@meyering.net>
26502
26503         Merge changes from Coreutils.
26504
26505         2003-03-22  Jim Meyering  <jim@meyering.net>
26506
26507         * lib/strftime.c (widen): Cast alloca return value to proper type.
26508
26509         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26510
26511         From GNU libc.
26512         * lib/strftime.c (my_strftime): Handle very large width
26513         specifications for numeric values correctly.  Improve checks for
26514         overflow.
26515
26516         2003-01-19  Jim Meyering  <jim@meyering.net>
26517
26518         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26519         definitions.
26520         (nl_get_alt_digit) [! defined my_strftime]: Define.
26521         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26522         _nl_get_alt_digit and _nl_get_walt_digit.
26523
26524         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26525         libc. These changes have no effect outside of _LIBC.
26526
26527 2003-04-10  Bruno Haible  <bruno@clisp.org>
26528
26529         * modules/findprog: New file.
26530         * MODULES.html.sh (func_all_modules): Add it.
26531
26532 2003-04-10  Bruno Haible  <bruno@clisp.org>
26533
26534         * m4/findprog.m4: New file.
26535         * m4/eaccess.m4: New file.
26536
26537 2003-04-10  Bruno Haible  <bruno@clisp.org>
26538
26539         * lib/findprog.h: New file, from GNU gettext.
26540         * lib/findprog.c: New file, from GNU gettext.
26541
26542 2003-04-05  Jim Meyering  <jim@meyering.net>
26543
26544         Merge changes from Coreutils.
26545
26546         * lib/exclude.h (PARAMS): Remove definition and uses.
26547         * lib/exclude.c: Remove uses of `PARAMS'.
26548
26549         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26550         Add test-cases for DOS filenames. Declare program_name.
26551         (main): Set up program_name.  Patch by Rich Dawe.
26552
26553         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26554         error from mntctl.
26555         Use mntctl's return value to drive the entry-processing loop, since
26556         we can't rely on the value of the vmt_length member in the last
26557         entry.  On some systems doing so could result in exhausting
26558         virtual memory.  Based in part on a patch from Mike Jetzer.
26559
26560 2003-04-04  Bruno Haible  <bruno@clisp.org>
26561
26562         * modules/linebreak: New file.
26563         * MODULES.html.sh (func_all_modules): Add it.
26564
26565 2003-04-04  Bruno Haible  <bruno@clisp.org>
26566
26567         * m4/linebreak.m4: New file.
26568
26569 2003-04-04  Bruno Haible  <bruno@clisp.org>
26570
26571         * lib/linebreak.h: New file, from GNU gettext.
26572         * lib/linebreak.c: New file, from GNU gettext with slight
26573         modifications.
26574         * lib/lbrkprop.h: New file, from GNU gettext.
26575
26576 2003-04-03  Bruno Haible  <bruno@clisp.org>
26577
26578         * modules/utf8-ucs4: New file.
26579         * modules/utf16-ucs4: New file.
26580         * modules/ucs4-utf8: New file.
26581         * modules/ucs4-utf16: New file.
26582         * MODULES.html.sh (func_all_modules): Add them.
26583
26584 2003-04-03  Bruno Haible  <bruno@clisp.org>
26585
26586         * m4/utf-ucs4.m4: New file.
26587         * m4/ucs4-utf.m4: New file.
26588
26589 2003-04-03  Bruno Haible  <bruno@clisp.org>
26590
26591         * lib/utf8-ucs4.h: New file, from GNU gettext.
26592         * lib/utf16-ucs4.h: New file, from GNU gettext.
26593         * lib/ucs4-utf8.h: New file, from GNU gettext.
26594         * lib/ucs4-utf16.h: New file, from GNU gettext.
26595
26596 2003-04-02  Bruno Haible  <bruno@clisp.org>
26597
26598         * modules/binary-io: New file.
26599         * MODULES.html.sh (func_all_modules): Add it.
26600
26601 2003-04-02  Bruno Haible  <bruno@clisp.org>
26602
26603         * lib/binary-io.h: New file, from GNU gettext.
26604
26605 2003-04-01  Bruno Haible  <bruno@clisp.org>
26606
26607         * modules/pathname: New file.
26608         * MODULES.html.sh (func_all_modules): Add it.
26609
26610 2003-04-01  Bruno Haible  <bruno@clisp.org>
26611
26612         * lib/pathname.h: New file, from GNU gettext.
26613         * lib/concatpath.c: New file, from GNU gettext.
26614
26615 2003-03-30  Bruno Haible  <bruno@clisp.org>
26616
26617         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
26618
26619 2003-03-30  Bruno Haible  <bruno@clisp.org>
26620
26621         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
26622         function chown() doesn't exist.
26623
26624 2003-03-28  Bruno Haible  <bruno@clisp.org>
26625
26626         * modules/copy-file: New file.
26627         * MODULES.html.sh (func_all_modules): Add it.
26628
26629 2003-03-28  Bruno Haible  <bruno@clisp.org>
26630
26631         * m4/copy-file.m4: New file.
26632
26633 2003-03-28  Bruno Haible  <bruno@clisp.org>
26634
26635         * lib/copy-file.h: New file, from GNU gettext.
26636         * lib/copy-file.c: New file, from GNU gettext.
26637
26638 2003-03-18  Jim Meyering  <jim@meyering.net>
26639
26640         * lib/quote.c (quote_n): Fix typo in comment.
26641
26642 2003-03-18  Bruno Haible  <bruno@clisp.org>
26643
26644         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
26645         checking.
26646         * m4/onceonly_2_57.m4: Likewise.
26647
26648 2003-03-17  Bruno Haible  <bruno@clisp.org>
26649
26650         * m4/onceonly.m4: Require autoconf 2.54 or newer.
26651         (m4_quote): Remove macro.
26652         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
26653
26654 2003-03-14  Jim Meyering  <jim@meyering.net>
26655
26656         Merge changes from Coreutils.
26657         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
26658         to be const, in order to avoid warnings.
26659         (obstack_room): Likewise.
26660         (obstack_empty_p): Likewise.
26661
26662 2003-03-14  Bruno Haible  <bruno@clisp.org>
26663
26664         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
26665         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
26666
26667 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26668
26669         Merge changes from Bison.
26670         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
26671         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
26672         when compiling Bison 1.875's `bitset bset = obstack_alloc
26673         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
26674         * lib/hash.c: Include <stdbool.h> unconditionally.
26675
26676 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26677
26678         * m4/onceonly.m4 (m4_quote): New macro.
26679         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
26680         Quote AC_FOREACH variable-expansions properly.
26681
26682 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26683
26684         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
26685
26686 2003-03-09  Paul Eggert  <eggert@twinsun.com>
26687
26688         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
26689         Reported by Bruce Becker; see:
26690         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
26691
26692 2003-03-03  Paul Eggert  <eggert@twinsun.com>
26693             Bruno Haible  <bruno@clisp.org>
26694
26695         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
26696         Reported by John Hughes, see
26697         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
26698
26699 2003-02-20  Bruno Haible  <bruno@clisp.org>
26700
26701         * MODULES.html.sh (func_all_modules): Add poll.
26702
26703 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26704
26705         * modules/poll: New file.
26706
26707 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26708
26709         * lib/poll_.h: New file.
26710         * lib/poll.c: New file.
26711
26712 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26713
26714         * m4/poll.m4: New file.
26715
26716 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26717
26718         * modules/mathl: New file.
26719
26720 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26721
26722         * lib/mathl.h: New file.
26723         * lib/acosl.c: New file.
26724         * lib/asinl.c: New file.
26725         * lib/atanl.c: New file.
26726         * lib/ceill.c: New file.
26727         * lib/cosl.c: New file.
26728         * lib/expl.c: New file.
26729         * lib/floorl.c: New file.
26730         * lib/frexpl.c: New file.
26731         * lib/ldexpl.c: New file.
26732         * lib/logl.c: New file.
26733         * lib/sincosl.c: New file.
26734         * lib/sinl.c: New file.
26735         * lib/sqrtl.c: New file.
26736         * lib/tanl.c: New file.
26737         * lib/trigl.c: New file.
26738         * lib/trigl.h: New file.
26739
26740 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26741
26742         * m4/mathl.m4: New file.
26743
26744 2003-02-18  Bruno Haible  <bruno@clisp.org>
26745
26746         * MODULES.html.sh (func_all_modules): Add mathl.
26747
26748 2003-02-17  Bruno Haible  <bruno@clisp.org>
26749
26750         * modules/mkdtemp: New module.
26751         * MODULES.html.sh (func_all_modules): Add it.
26752
26753 2003-02-17  Bruno Haible  <bruno@clisp.org>
26754
26755         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
26756
26757 2003-02-17  Bruno Haible  <bruno@clisp.org>
26758
26759         * lib/mkdtemp.h: New file, from GNU gettext.
26760         * lib/mkdtemp.c: New file, from GNU gettext.
26761
26762 2003-02-02  Jim Meyering  <jim@meyering.net>
26763
26764         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
26765         e.g. glibc-2.2.93.
26766
26767 2003-01-31  Bruno Haible  <bruno@clisp.org>
26768
26769         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
26770         'rpl_rename'.
26771         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
26772         'rpl_strnlen'.
26773         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
26774         'rpl_strtod'.
26775         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
26776         'rpl_utime'.
26777
26778 2003-01-31  Bruno Haible  <bruno@clisp.org>
26779
26780         * lib/rename.c: #undef rename before defining rpl_rename.
26781         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
26782
26783 2003-01-30  Bruno Haible  <bruno@clisp.org>
26784
26785         * modules/vasnprintf, modules/vasprintf: New modules.
26786         * MODULES.html.sh (func_all_modules): Add them.
26787
26788 2003-01-30  Bruno Haible  <bruno@clisp.org>
26789
26790         * m4/signed.m4: New file, from GNU gettext.
26791         * m4/longdouble.m4: New file, from GNU gettext.
26792         * m4/wchar_t.m4: New file, from GNU gettext.
26793         * m4/wint_t.m4: New file, from GNU gettext.
26794         * m4/vasnprintf.m4: New file.
26795         * m4/vasprintf.m4: New file.
26796
26797 2003-01-30  Bruno Haible  <bruno@clisp.org>
26798
26799         * lib/printf-args.h: New file, from GNU gettext.
26800         * lib/printf-args.c: New file, from GNU gettext.
26801         * lib/printf-parse.h: New file, from GNU gettext.
26802         * lib/printf-parse.c: New file, from GNU gettext.
26803         * lib/vasnprintf.h: New file, from GNU gettext.
26804         * lib/vasnprintf.c: New file, from GNU gettext.
26805         * lib/asnprintf.c: New file, from GNU gettext.
26806         * lib/vasprintf.h: New file, from GNU gettext with modifications.
26807         * lib/vasprintf.c: New file, from GNU gettext.
26808         * lib/asprintf.c: New file, from GNU gettext.
26809
26810 2003-01-29  Bruno Haible  <bruno@clisp.org>
26811
26812         * modules/stpncpy: New module.
26813         * MODULES.html.sh (func_all_modules): Add it.
26814
26815 2003-01-29  Bruno Haible  <bruno@clisp.org>
26816
26817         * m4/stpncpy.m4: New file.
26818
26819 2003-01-29  Bruno Haible  <bruno@clisp.org>
26820
26821         * lib/stpncpy.h: New file, from GNU gettext with modifications.
26822         * lib/stpncpy.c: New file, from GNU gettext with modifications.
26823
26824 2003-01-28  Bruno Haible  <bruno@clisp.org>
26825
26826         * modules/c-ctype: New module.
26827         * MODULES.html.sh (func_all_modules): Add it.
26828
26829 2003-01-28  Bruno Haible  <bruno@clisp.org>
26830
26831         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
26832         Paul Eggert.
26833         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
26834         Paul Eggert.
26835
26836 2003-01-27  Bruno Haible  <bruno@clisp.org>
26837
26838         * modules/xsetenv: New module.
26839         * MODULES.html.sh (func_all_modules): Add it.
26840
26841 2003-01-27  Bruno Haible  <bruno@clisp.org>
26842
26843         * lib/xsetenv.h: New file, from GNU gettext.
26844         * lib/xsetenv.c: New file, from GNU gettext.
26845
26846 2003-01-23  Jim Meyering  <jim@meyering.net>
26847
26848         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
26849         from working on systems without dirfd (at least Irix and OSF1/Tru64).
26850
26851 2003-01-23  Bruno Haible  <bruno@clisp.org>
26852
26853         * modules/minmax: New module.
26854         * MODULES.html.sh (func_all_modules): Add it.
26855
26856 2003-01-23  Bruno Haible  <bruno@clisp.org>
26857
26858         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
26859         Eggert.
26860
26861 2003-01-22  Bruno Haible  <bruno@clisp.org>
26862
26863         * modules/exit: New module.
26864         * MODULES.html.sh (func_all_modules): Add it.
26865
26866 2003-01-22  Bruno Haible  <bruno@clisp.org>
26867
26868         * lib/exit.h: New file, from GNU gettext.
26869
26870 2003-01-19  Bruno Haible  <bruno@clisp.org>
26871
26872         * gnulib-tool: Recognize option --extract-maintainer.
26873         (func_get_maintainer): New function.
26874         * modules/*: Add Maintainer entry.
26875
26876 2003-01-16  Jim Meyering  <jim@meyering.net>
26877
26878         * m4/regex.m4: The `regex' struct is both input and output.
26879         Initialize it before each use.  Patch by Tim Waugh.
26880
26881 2003-01-16  Bruno Haible  <bruno@clisp.org>
26882
26883         * MODULES.html.sh: Add a table of contents. Add the module name as
26884         leftmost column. Add hyperlinks.
26885
26886 2003-01-15  Bruno Haible  <bruno@clisp.org>
26887
26888         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
26889
26890 2003-01-15  Bruno Haible  <bruno@clisp.org>
26891
26892         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
26893         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
26894         suffix.
26895
26896 2003-01-15  Bruno Haible  <bruno@clisp.org>
26897
26898         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
26899
26900 2003-01-15  Bruno Haible  <bruno@clisp.org>
26901
26902         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
26903         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
26904
26905 2003-01-14  Jim Meyering  <jim@meyering.net>
26906
26907         * lib/same.c (same_name): Tweak a comment.
26908
26909 2003-01-14  Bruno Haible  <bruno@clisp.org>
26910
26911         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
26912         when a string comparison is sufficient.
26913
26914 2003-01-14  Bruno Haible  <bruno@clisp.org>
26915
26916         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
26917         'unsigned int'.
26918
26919 2003-01-14  Bruno Haible  <bruno@clisp.org>
26920
26921         * lib/hash-pjw.c: Add comment about low quality of this function.
26922
26923 2003-01-13  Bruno Haible  <bruno@clisp.org>
26924
26925         * modules/stpcpy: Distribute lib/stpcpy.h.
26926         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
26927
26928 2003-01-13  Bruno Haible  <bruno@clisp.org>
26929
26930         * modules/*: Add a description.
26931         * modules/strpbrk: Fix Makefile.am snippet.
26932         * modules/strtoimax: Fix dependencies.
26933         * modules/strtoumax: Likewise.
26934
26935 2003-01-13  Bruno Haible  <bruno@clisp.org>
26936
26937         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
26938         * modules/alloca (Makefile.am): All object files depend on alloca.h.
26939         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
26940
26941 2003-01-13  Bruno Haible  <bruno@clisp.org>
26942
26943         * gnulib-tool (func_create_testdir): Store config/* files in the main
26944         directory.
26945         * config.rpath: Move to ...
26946         * config/config.rpath: ... here.
26947         * modules/gettext: Contains config/config.rpath, not config.rpath.
26948         * modules/iconv: Likewise.
26949
26950 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26951
26952         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26953         to avoid collisions with libcurses and libreadline.
26954
26955         * m4/getstr.m4: Remove.
26956         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
26957
26958 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26959
26960         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26961         to avoid collisions with libcurses and libreadline.
26962
26963         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
26964         * lib/getstr.h, getstr.c: Remove.
26965         * lib/getline.c: Include "getline.h", to check interface.
26966         Move body of old getstr.c here: this defines MIN_CHUNK and
26967         declares getdelim2, which is renamed from getstr.
26968         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
26969
26970         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
26971         All uses changed.
26972         * lib/linebuffer.h: Likewise.
26973         (readline): Remove backward-compatibility macro.
26974
26975 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26976
26977         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26978         to avoid collisions with libcurses and libreadline.
26979         * getstr: Remove.
26980         * MODULES.html.sh: Remove getstr.
26981         * modules/getline: Depend on unlocked-io, not getstr.
26982
26983 2003-01-12  Jim Meyering  <jim@meyering.net>
26984
26985         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
26986
26987 2003-01-10  Bruno Haible  <bruno@clisp.org>
26988
26989         * modules/alloca: Change Makefile.am requirements. Simplify Include
26990         requirements. Add lib/alloca_.h to file list.
26991
26992 2003-01-10  Bruno Haible  <bruno@clisp.org>
26993
26994         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
26995
26996 2003-01-10  Bruno Haible  <bruno@clisp.org>
26997
26998         * lib/alloca_.h: New file.
26999         * lib/getdate.y: Unconditionally include alloca.h.
27000         * lib/makepath.c: Likewise.
27001         * lib/setenv.c: Likewise.
27002         * lib/userspec.c: Likewise.
27003
27004 2003-01-09  Karl Berry  <karl@gnu.org>
27005
27006         * MODULES.html.sh: include `dirname $0` in PATH, to find
27007         gnulib-tool.
27008
27009 2003-01-09  Bruno Haible  <bruno@clisp.org>
27010
27011         * modules/stdbool: Change configure.ac, Makefile.am requirements.
27012         Simplify Include requirements. Add lib/stdbool.h.in to file list.
27013
27014 2003-01-09  Bruno Haible  <bruno@clisp.org>
27015
27016         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
27017
27018 2003-01-09  Bruno Haible  <bruno@clisp.org>
27019
27020         * lib/stdbool.h.in: New file.
27021
27022 2003-01-09  Bruno Haible  <bruno@clisp.org>
27023
27024         * gnulib-tool (func_all_modules): Ignore files ending in ~.
27025         * MODULES.html.sh: Likewise.
27026
27027 2003-01-08  Jim Meyering  <jim@meyering.net>
27028
27029         * lib/full-write.c: Undefine and define-away `const' after inclusion
27030         of errno.h, not before.  Suggestion from Bruno Haible.
27031
27032 2003-01-08  Bruno Haible  <bruno@clisp.org>
27033
27034         * modules/full-read: Depend on full-write.
27035
27036 2003-01-08  Bruno Haible  <bruno@clisp.org>
27037
27038         * lib/safe-read.c: Include specification header first, to ensure its
27039         selfcontainedness.
27040         * lib/full-write.c: Likewise.
27041
27042 2003-01-07  Jim Meyering  <jim@meyering.net>
27043
27044         * lib/full-write.c: Rework so that it may serve to define full_read,
27045         too.
27046         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
27047
27048 2003-01-07  Bruno Haible  <bruno@clisp.org>
27049
27050         * lib/strtoimax.c: Include <stdint.h> as an alternative to
27051         <inttypes.h>.
27052         * lib/xstrtol.h: Likewise.
27053         * lib/xstrtoimax.c: Likewise.
27054         * lib/xstrtoumax.c: Likewise.
27055         * lib/human.h: Likewise.
27056
27057         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
27058         on systems that have <inttypes.h> but not <stdint.h>.
27059
27060 2003-01-07  Bruno Haible  <bruno@clisp.org>
27061
27062         * MODULES.html.sh: Add copyright notice.
27063         (missed_files): Omit CVS directory entries.
27064         (func_module): Make it work with sed-3.02.
27065         * MODULES.txt: Remove file.
27066
27067 2003-01-06  Jim Meyering  <jim@meyering.net>
27068
27069         * lib/version-etc.c: Update year in translatable copyright string.
27070
27071 2003-01-03  Karl Berry  <karl@gnu.org>
27072
27073         * config/config.{guess,sub}: update from prep.
27074
27075 2003-01-02  Karl Berry  <karl@gnu.org>
27076
27077         * doc/COPYING.DOC: belatedly updated to 1.2.
27078
27079 2003-01-01  Karl Berry  <karl@gnu.org>
27080
27081         * gnulib-tool (func_verify_module): report module name $module in
27082         error message, not $1.
27083         * gnulib-tool (create-testdir): don't complain if destdir couldn't
27084         be created, only if it doesn't exist.
27085         * gnulib-tool (last_checkin_date): don't expand the $Date here.
27086
27087 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27088
27089         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
27090
27091 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27092
27093         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
27094         memcmp if strcoll doesn't work.
27095
27096 2002-12-31  Bruno Haible  <bruno@clisp.org>
27097
27098         * lib/utime.c (utime_null): No need to call ftruncate if the file was
27099         nonempty.
27100
27101 2002-12-31  Bruno Haible  <bruno@clisp.org>
27102
27103         * lib/memcoll.c (STRCOLL): New macro.
27104         (memcoll): Use it.
27105
27106 2002-12-31  Bruno Haible  <bruno@clisp.org>
27107
27108         * lib/localcharset.h: New file.
27109         * lib/localcharset.c: Include it.
27110         * lib/unicodeio.c: Likewise.
27111
27112 2002-12-31  Bruno Haible  <bruno@clisp.org>
27113
27114         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
27115         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
27116
27117 2002-12-31  Bruno Haible  <bruno@clisp.org>
27118
27119         * lib/getline.h: Include <stddef.h>, for size_t.
27120
27121         * lib/unicodeio.h: Include <stddef.h>, for size_t.
27122         * lib/unicodeio.c: Don't include <stddef.h>.
27123
27124 2002-12-31  Bruno Haible  <bruno@clisp.org>
27125
27126         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
27127         HAVE_TM_ZONE.
27128
27129 2002-12-24  Karl Berry  <karl@gnu.org>
27130
27131         * config/config.guess: update from prep.
27132
27133 2002-12-24  Bruno Haible  <bruno@clisp.org>
27134
27135         General infrasructure.
27136         * m4/README: Rewritten.
27137         * m4/onceonly.m4: New file.
27138         * m4/onceonly_2_57.m4: New file.
27139
27140         Module atexit.
27141         * m4/atexit.m4: New file.
27142
27143         Module strtod.
27144         * m4/strtod.m4: New file.
27145
27146         Module strtol.
27147         * m4/strtol.m4: New file.
27148
27149         Module strtoul.
27150         * m4/strtoul.m4: New file.
27151
27152         Module memchr.
27153         * m4/memchr.m4: New file.
27154
27155         Module memcmp.
27156         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
27157         (jm_FUNC_MEMCMP): Invoke it.
27158
27159         Module memcpy.
27160         * m4/memcpy.m4: New file.
27161
27162         Module memmove.
27163         * m4/memmove.m4: New file.
27164
27165         Module memset.
27166         * m4/memset.m4: New file.
27167
27168         Module strcspn.
27169         * m4/strcspn.m4: New file.
27170
27171         Module strpbrk.
27172         * m4/strpbrk.m4: New file.
27173
27174         Module strstr.
27175         * m4/strstr.m4: New file.
27176
27177         Module strerror.
27178         * m4/strerror.m4: New file.
27179
27180         Module mktime.
27181         * m4/mktime.m4: Renamed from jm-mktime.m4.
27182         (gl_PREREQ_MKTIME): New macro.
27183         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
27184
27185         Module malloc.
27186         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
27187         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
27188         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
27189
27190         Module realloc.
27191         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
27192         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
27193         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
27194
27195         Module strftime.
27196         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
27197         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
27198         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
27199         gl_TM_GMTOFF.
27200         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
27201
27202         Module xalloc.
27203         * m4/xalloc.m4: New file.
27204
27205         Module alloca.
27206         * m4/alloca.m4: New file.
27207
27208         Module putenv.
27209         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
27210         (jm_FUNC_PUTENV): Invoke it.
27211
27212         Module setenv.
27213         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
27214         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
27215         when invoked twice.
27216         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
27217         gt_FUNC_SETENV.
27218
27219         Module memrchr.
27220         * m4/memrchr.m4: New file.
27221
27222         Module stpcpy.
27223         * m4/stpcpy.m4: New file.
27224
27225         Module strcase.
27226         * m4/strcase.m4: New file.
27227
27228         Module strdup.
27229         * m4/strdup.m4: New file.
27230
27231         Module strnlen.
27232         * m4/strnlen.m4: New file.
27233
27234         Module strndup.
27235         * m4/strndup.m4: New file.
27236
27237         Module xstrtod.
27238         * m4/xstrtod.m4: New file.
27239
27240         Module xstrtol.
27241         * m4/xstrtol.m4: New file.
27242
27243         Module getdate.
27244         * m4/getdate.m4: New file.
27245
27246         Module unlocked-io.
27247         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
27248         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
27249         * m4/jm-glibc-io.m4n: Remove file.
27250
27251         Module long-options.
27252         * m4/long-options.m4: New file.
27253
27254         Module md5.
27255         * m4/md5.m4: New file.
27256
27257         Module sha.
27258         * m4/sha.m4: New file.
27259
27260         Module getstr.
27261         * m4/getstr.m4: New file.
27262
27263         Module getline.
27264         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
27265         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
27266         <sys/types.h>, for size_t. Use the function name gnu_getline, not
27267         simply getline. Infoke gl_PREREQ_GETLINE.
27268
27269         Module obstack.
27270         * m4/obstack.m4: New file.
27271
27272         Module hash.
27273         * m4/hash.m4: New file.
27274
27275         Module readtokens.
27276         * m4/readtokens.m4: New file.
27277
27278         Module strverscmp.
27279         * m4/strverscmp.m4: New file.
27280
27281         Module stdbool.
27282         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
27283         OSF/1.
27284
27285         Module strtoll.
27286         * m4/strtoll.m4: New file.
27287
27288         Module strtoull.
27289         * m4/strtoull.m4: New file.
27290
27291         Module strtoimax.
27292         * m4/strtoimax.m4: New file.
27293
27294         Module strtoumax.
27295         * m4/strtoumax.m4: New file.
27296
27297         Module xstrtoimax.
27298         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
27299         jm_AC_PREREQ_XSTRTOIMAX.
27300         Moved the strtol prerequisites to strtol.m4.
27301         Moved the strtoll prerequisites to strtoll.m4.
27302         Moved the strtoimax prerequisites to strtoimax.m4.
27303
27304         Module xstrtoumax.
27305         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
27306         jm_AC_PREREQ_XSTRTOUMAX.
27307         Moved the strtoul prerequisites to strtoul.m4.
27308         Moved the strtoull prerequisites to strtoull.m4.
27309         Moved the strtoumax prerequisites to strtoumax.m4.
27310
27311         Module chown.
27312         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
27313         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
27314
27315         Module dup2.
27316         * m4/dup2.m4: New file.
27317
27318         Module ftruncate.
27319         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
27320         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
27321
27322         Module getgroups.
27323         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
27324         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
27325
27326         Module gettimeofday.
27327         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
27328         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
27329         gl_PREREQ_GETTIMEOFDAY.
27330
27331         Module mkdir.
27332         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
27333         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
27334
27335         Module mkstemp.
27336         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
27337         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
27338         jm_AC_TYPE_UINTMAX_T.
27339         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
27340
27341         Module stat.
27342         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
27343         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
27344
27345         Module lstat.
27346         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
27347         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
27348
27349         Module timespec.
27350         * m4/timespec.m4 (gl_TIMESPEC): New macro.
27351         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
27352         * m4/st_mtim.m4: Indentation.
27353
27354         Module nanosleep.
27355         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
27356         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
27357         gl_PREREQ_NANOSLEEP.
27358
27359         Module regex.
27360         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
27361         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
27362         (gl_REGEX): New macro.
27363
27364         Module rename.
27365         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
27366         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
27367
27368         Module rmdir.
27369         * m4/rmdir.m4: New file.
27370
27371         Module utime.
27372         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
27373         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
27374         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
27375
27376         Module dirname.
27377         * m4/dirname.m4: New file.
27378
27379         Module getopt.
27380         * m4/getopt.m4: New file.
27381
27382         Module unistd-safer.
27383         * m4/unistd-safer.m4: New file.
27384
27385         Module fnmatch.
27386         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
27387         declaration.
27388         (gl_PREREQ_FNMATCH_EXTRA): New macro.
27389         (gl_FUNC_FNMATCH_POSIX): New macro.
27390         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
27391         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
27392         simply fnmatch.
27393
27394         Module exclude.
27395         * m4/exclude.m4: New file.
27396
27397         Module human.
27398         * m4/human.m4: New file.
27399
27400         Module acl.
27401         * m4/acl.m4: Nop.
27402
27403         Module backupfile.
27404         * m4/backupfile.m4: New file.
27405         * m4/d-ino.m4: Indentation.
27406
27407         Module fsusage.
27408         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27409         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27410         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27411
27412         Module dirfd.
27413         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27414         requirements.
27415
27416         Module euidaccess.
27417         * m4/euidaccess.m4: New file.
27418
27419         Module file-type.
27420         * m4/file-type.m4: New file.
27421
27422         Module fileblocks.
27423         * m4/fileblocks.m4: New file.
27424
27425         Module filemode.
27426         * m4/filemode.m4: New file.
27427
27428         Module isdir.
27429         * m4/isdir.m4: New file.
27430
27431         Module lchown.
27432         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27433         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27434
27435         Module makepath.
27436         * m4/makepath.m4: New file.
27437
27438         Module modechange.
27439         * m4/modechange.m4: New file.
27440
27441         Module mountlist.
27442         * m4/mountlist.m4: New file.
27443         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27444         Indentation.
27445
27446         Module path-concat.
27447         * m4/path-concat.m4: New file.
27448
27449         Module pathmax.
27450         * m4/pathmax.m4: New file.
27451
27452         Module same.
27453         * m4/same.m4: New file.
27454
27455         Module save-cwd.
27456         * m4/save-cwd.m4: New file.
27457
27458         Module savedir.
27459         * m4/savedir.m4: New file.
27460
27461         Module xgetcwd.
27462         * m4/xgetcwd.m4: New file.
27463         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27464
27465         Module xreadlink.
27466         * m4/xreadlink.m4: New file.
27467
27468         Module safe-read.
27469         * m4/safe-read.m4: New file.
27470
27471         Module safe-write.
27472         * m4/safe-write.m4: New file.
27473
27474         Module closeout.
27475         * m4/closeout.m4: New file.
27476
27477         Module stdio-safer.
27478         * m4/stdio-safer.m4: New file.
27479
27480         Module getpass.
27481         * m4/getpass.m4: New file.
27482
27483         Module getugroups.
27484         * m4/getugroups.m4: New file.
27485
27486         Module group-member.
27487         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27488         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27489
27490         Module idcache.
27491         * m4/idcache.m4: New file.
27492
27493         Module userspec.
27494         * m4/userspec.m4: New file.
27495
27496         Module gettime.
27497         * m4/clock_time.m4: New file.
27498         * m4/gettime.m4: New file.
27499
27500         Module settime.
27501         * m4/settime.m4: New file.
27502
27503         Module posixtm.
27504         * m4/posixtm.m4: New file.
27505
27506         Module gethostname.
27507         * m4/gethostname.m4: New file.
27508
27509         Module canon-host.
27510         * m4/canon-host.m4: New file.
27511
27512         Module gettext.
27513         * m4/codeset.m4: New file, from gettext-0.11.5.
27514         * m4/gettext.m4: New file, from gettext-0.11.5.
27515         * m4/glibc21.m4: New file, from gettext-0.11.5.
27516         * m4/iconv.m4: New file, from gettext-0.11.5.
27517         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27518         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27519         * m4/inttypes.m4: New file, from gettext-0.11.5.
27520         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27521         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27522         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27523         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27524         * m4/lib-link.m4: New file, from gettext-0.11.5.
27525         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27526         * m4/progtest.m4: New file, from gettext-0.11.5.
27527         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27528         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27529         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27530
27531         Module localcharset.
27532         * m4/localcharset.m4: New file.
27533
27534         Module hard-locale.
27535         * m4/hard-locale.m4: New file.
27536
27537         Module mbswidth.
27538         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27539         onceonly macros.
27540         * m4/mbrtowc.m4: Add comment.
27541
27542         Module memcasecmp.
27543         * m4/memcasecmp.m4: New file.
27544
27545         Module memcoll.
27546         * m4/memcoll.m4: New file.
27547
27548         Module unicodeio.
27549         * m4/unicodeio.m4: New file.
27550
27551         Module rpmatch.
27552         * m4/rpmatch.m4: New file.
27553
27554         Module yesno.
27555         * m4/yesno.m4: New file.
27556
27557         Module exitfail.
27558         * m4/exitfail.m4: New file.
27559
27560         Module c-stack.
27561         * m4/c-stack.m4 (gl_C_STACK): New macro.
27562         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27563
27564         Module error.
27565         * m4/error.m4 (gl_ERROR): New macro.
27566         (jm_PREREQ_ERROR): Use onceonly macros.
27567
27568         Module fatal.
27569         * m4/fatal.m4: New file.
27570
27571         Module getloadavg.
27572         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27573         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27574
27575         Module getpagesize.
27576         * m4/getpagesize.m4: New file.
27577
27578         Module getusershell.
27579         * m4/getusershell.m4: New file.
27580
27581         Module physmem.
27582         * m4/physmem.m4: New file.
27583
27584         Module posixver.
27585         * m4/posixver.m4: New file.
27586
27587         Module quotearg.
27588         * m4/quotearg.m4: New file.
27589
27590         Module quote.
27591         * m4/quote.m4: New file.
27592
27593         Module readutmp.
27594         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
27595
27596         Module sig2str.
27597         * m4/sig2str.m4: New file.
27598
27599         Other.
27600         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
27601         ulonglong.m4.
27602         * m4/intmax_t.m4: New file.
27603         * m4/d-type.m4: Indentation.
27604         * m4/jm-macros.m4: Update.
27605         * m4/prereq.m4 (jm_PREREQ): Update.
27606         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
27607         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
27608         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
27609         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
27610         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
27611         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
27612         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
27613         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
27614         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
27615         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
27616         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
27617         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
27618         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
27619         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
27620         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
27621         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
27622         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
27623         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
27624         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
27625
27626 2002-12-24  Bruno Haible  <bruno@clisp.org>
27627
27628         * MODULES.txt: Update according to m4/ changes.
27629
27630         Module gettext.
27631         * config.rpath: New file, from gettext-0.11.5.
27632
27633         * modules/*: New module descriptions.
27634         * gnulib-tool: New file.
27635         * MODULES.html.sh: New file.
27636
27637 2002-12-21  Karl Berry  <karl@gnu.org>
27638
27639         * doc/fdl.texi: update to version 1.2.
27640
27641 2002-12-19  Karl Berry  <karl@gnu.org>
27642
27643         * config/config.guess: update from prep.
27644
27645 2002-12-18  Bruno Haible  <bruno@clisp.org>
27646
27647         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
27648         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
27649
27650 2002-12-17  Bruno Haible  <bruno@clisp.org>
27651
27652         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
27653         stdlib.h, string.h.
27654
27655 2002-12-17  Bruno Haible  <bruno@clisp.org>
27656
27657         * lib/canon-host.c (strdup): Remove unused declaration.
27658
27659         * lib/fsusage.c: Include full_read.h.
27660         (get_fs_usage): Use full_read instead of safe_read.
27661
27662         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
27663
27664 2002-12-12  Karl Berry  <karl@gnu.org>
27665
27666         * config/config.guess: update from prep.
27667
27668 2002-12-11  Bruno Haible  <bruno@clisp.org>
27669
27670         * m4/setenv.m4: New file, from gettext-0.11.5.
27671
27672 2002-12-11  Bruno Haible  <bruno@clisp.org>
27673
27674         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
27675         not unsetenv().
27676         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
27677         modifications:
27678
27679         2002-12-11  Bruno Haible  <bruno@clisp.org>
27680
27681                 * setenv.c (alloca): Fall back to malloc.
27682                 (freea): New macro.
27683                 (setenv): Use freea() to free memory allocated with alloca().
27684
27685         2002-11-13  Bruno Haible  <bruno@clisp.org>
27686
27687                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
27688                 function declarations.
27689                 * unsetenv.c (unsetenv): Likewise.
27690
27691         2002-03-04  Bruno Haible  <bruno@clisp.org>
27692
27693                 Portability to AIX 4.3.3.
27694                 * unsetenv.c: New file, extracted from setenv.c.
27695                 * setenv.c: Move the unsetenv() function to unsetenv.c.
27696
27697         2001-12-20  Bruno Haible  <bruno@clisp.org>
27698
27699                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
27700                 use malloc instead. For SunOS 4.
27701
27702         2001-12-11  Bruno Haible  <bruno@clisp.org>
27703
27704                 * setenv.c: Declare alloca.
27705                 (compar_fn_t): New typedef.
27706                 (KNOWN_VALUE, STORE_VALUE): Use it.
27707
27708         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
27709         setenv.h.
27710
27711 2002-12-10  Paul Eggert  <eggert@twinsun.com>
27712
27713         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
27714         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
27715         Choose values that are less likely to collide with system fnmatch
27716         options.
27717         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
27718         defined (e.g., a pure POSIX system).
27719         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
27720         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
27721
27722 2002-12-06  Paul Eggert  <eggert@twinsun.com>
27723
27724         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
27725         a pain in practice to deal with generated m4 files.  This change
27726         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
27727
27728         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
27729         and jm-glibc-io.m4, as they are no longer a special case.
27730         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
27731         kludge and the auto-generation stuff.  Check only whether the
27732         functions are declared, not whether they exist, since older hosts
27733         that don't declare the functions can't use the optimization anyway.
27734
27735 2002-12-06  Jim Meyering  <jim@meyering.net>
27736
27737         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
27738
27739         Merge in changes from libc's misc/error.c, in preparation
27740         for the merge of gnulib's changes back into libc.
27741
27742         * lib/error.c (_): Define only if not already defined.
27743         Move definition to follow all #include directives.
27744         Include unlocked-io.h only if !_LIBC.
27745         [_LIBC]: Include <libio/libioP.h>.
27746         [USE_IN_LIBIO]: Include <libio/iolibio.h>
27747         (fflush): Tweak definition to use INTUSE.
27748         (putc): Define.
27749
27750 2002-12-05  Paul Eggert  <eggert@twinsun.com>
27751
27752         * lib/alloca.c [defined emacs]: Include "lisp.h".
27753         (xalloc_die) [defined emacs]: New macro.
27754         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
27755         [! defined emacs]: Include <xalloc.h>.
27756         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
27757         (pointer): Typedef to POINTER_TYPE *.
27758         (malloc): Remove decl; we now always use xmalloc.
27759         (alloca): Use old-style definition, since Emacs needs this.
27760         Check for arithmetic overflow when computing combined size.
27761
27762 2002-12-04  Paul Eggert  <eggert@twinsun.com>
27763
27764         Do not generate unlocked-io.h automatically, since it's easier to
27765         maintain it by hand.
27766
27767         * lib/unlocked-io.h: New file, from GNU diffutils,
27768         but with proper copyright notice and attribution.
27769         * lib/gen-uio: Remove.
27770         * lib/Makefile.am: Add copyright notice.
27771         (libfetish_a_SOURCES): Add unlocked-io.h.
27772         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
27773         (DISTCLEANFILES, io_functions): Remove macros.
27774         (EXTRA_DIST): Remove gen_uio.
27775         (unlocked-io.h): Remove rule.
27776
27777 2002-12-04  Jim Meyering  <jim@meyering.net>
27778
27779         Reflect the fact that stat.c and lstat.c are no longer generated.
27780         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
27781         (DISTCLEANFILES): Likewise.
27782         (EXTRA_DIST): Likewise.
27783         (all_local): Don't depend on stat.c or lstat.c.
27784         (stat.c, lstat.c): Remove rules.
27785         (EXTRA_DIST): Remove xstat.in.
27786
27787         * lib/xstat.in: Remove file.  Contents moved into stat.c.
27788         * lib/stat.c: New file.  Contents mostly from xstat.in.
27789         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
27790         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
27791
27792         * lib/safe-read.c: Rework so that it may serve to define safe_write,
27793         too.
27794         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
27795
27796 2002-12-03  Jim Meyering  <jim@meyering.net>
27797
27798         * lib/safe-read.c, safe-write.c: Change variable names and comments,
27799         but not semantics, to minimize the differences between these two files.
27800         (safe_read): Change comment to mention SAFE_READ_ERROR.
27801
27802         * lib/safe-read.c (IS_EINTR): Define.
27803         (safe_read): Use IS_EINTR in place of in-function cpp directives.
27804
27805 2002-12-02  Jim Meyering  <jim@meyering.net>
27806
27807         * lib/safe-read.c (EINTR): Define.
27808         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27809         (INT_MAX): Provide fallback.
27810         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
27811
27812         * lib/safe-read.h (SAFE_READ_ERROR): Define.
27813
27814 2002-12-02  Bruno Haible  <bruno@clisp.org>
27815
27816         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
27817         Define, taken from safe-read.c.
27818         (INT_MAX): Provide fallback.
27819         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
27820         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
27821
27822         * lib/safe-read.c (EINTR): Remove definition.
27823         (safe_read): Don't use EINTR if it is absent.
27824
27825 2002-12-01  Jim Meyering  <jim@meyering.net>
27826
27827         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
27828         zero.
27829         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
27830
27831 2002-11-27  Paul Eggert  <eggert@twinsun.com>
27832
27833         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
27834         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
27835         with `if (! (value < limit)) abort ();', for readability.
27836
27837 2002-11-26  Karl Berry  <karl@gnu.org>
27838
27839         * lib/strdup.c: copy from libc again, with jim's ok.
27840         * lib/.cppi-disable: re-add strdup.c
27841
27842 2002-11-25  Karl Berry  <karl@gnu.org>
27843
27844         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
27845         instead of "strtol.c".
27846
27847 2002-11-25  Karl Berry  <karl@gnu.org>
27848
27849         * config/install-sh: update from automake for variable quoting, $0 in
27850         error msgs, etc.
27851
27852         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
27853         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
27854         entry.
27855
27856 2002-11-25  Jim Meyering  <jim@meyering.net>
27857
27858         * lib/mktime.c: Sync from libc, now that it has the latest fix.
27859
27860 2002-11-24  Karl Berry  <karl@gnu.org>
27861
27862         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
27863         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
27864
27865 2002-11-24  Jim Meyering  <jim@meyering.net>
27866
27867         Update from coreutils:
27868
27869         * lib/mktime.c: Merge in changes from libc.
27870
27871         Avoid a link-time failure on some Linux systems.
27872         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
27873         (otherwise).
27874         (__mon_yday): Declare with the STATIC attribute.
27875         (__mktime_internal): Likewise.
27876         Based on a report from Greg Schafer.
27877
27878 2002-11-23  Jim Meyering  <jim@meyering.net>
27879
27880         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
27881         Use `unsigned', not `int', as type of index.
27882
27883         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
27884
27885         * lib/fsusage.c: Remove unneeded parentheses around operands of
27886         `defined'.
27887
27888 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27889
27890         * lib/quotearg.h: Allow multiple inclusion by surrounding with
27891         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
27892         so that we can be included first.
27893         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
27894         * lib/quotearg.c: Include quotearg.h immediately after config.h.
27895         No need to include stddef.h or sys/types.h any more.
27896         Surround local include files with "", not "<>".
27897         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
27898         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
27899         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
27900         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
27901         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
27902         (ISPRINT): Remove; no longer needed now that we assume C89.
27903
27904         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
27905         Preserve errno.
27906
27907         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
27908         quotearg_char): Use SIZE_MAX rather than
27909         (size_t) -1 when we are talking about "infinity".
27910
27911         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
27912
27913 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27914
27915         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
27916         hint that one should use `if (! x) abort ();' rather than `assert
27917         (x);', and anyway it's one less thing to worry about configuring.
27918         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
27919         hash_rehash, hash_insert): Use abort rather than assert.
27920
27921 2002-11-22  Bruno Haible  <bruno@clisp.org>
27922
27923         * lib/safe-read.h: Assume C89. Add comments.
27924         (safe_read): Change return type to size_t.
27925         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
27926         byte counts > SSIZE_MAX correctly.
27927         * lib/safe-write.h: New file.
27928         * lib/safe-write.c: New file.
27929         * lib/full-read.h: New file.
27930         * lib/full-read.c: New file.
27931         * lib/full-write.h: Assume C89. Add comments.
27932         * lib/full-write.c: Include safe-write.h.
27933         (full_write): Rewritten to use safe_write.
27934         Suggested by Jim Meyering and Paul Eggert.
27935
27936 2002-11-21  Jim Meyering  <jim@meyering.net>
27937
27938         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
27939
27940         Merge in changes from the coreutils.
27941
27942         2002-09-25  Paul Eggert  <eggert@twinsun.com>
27943         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
27944         <stdint.h>.
27945         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
27946         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
27947         int.  Work more efficiently if X is the same width as uintmax_t.
27948         Do not compare X to -1, to avoid bogus compiler warning.
27949         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
27950         Don't assume that f_frsize and f_bsize are the same type.
27951
27952         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
27953         warning on FreeBSD.
27954
27955         * lib/makepath.c (make_path): Restore umask *before* creating the final
27956         component.
27957         (make_path): Minor reformatting.
27958
27959         * lib/xmalloc.c: Adjust to work with new autoconf macros,
27960         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
27961         HAVE_MALLOC/HAVE_REALLOC.
27962
27963         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
27964         dummy ones.  At least on GNU/Linux systems, `auto' means something
27965         else.
27966         From Michael Stone.
27967
27968 2002-11-21  Bruno Haible  <bruno@clisp.org>
27969
27970         Remove case insensitive option matching.
27971         * lib/argmatch.h (argcasematch): Remove declaration.
27972         (ARGCASEMATCH): Remove macro.
27973         (__xargmatch_internal): Remove case_sensitive argument.
27974         (XARGMATCH): Update.
27975         (XARGCASEMATCH): Remove macro.
27976         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
27977         case_sensitive argument.
27978         (argcasematch): Remove function.
27979         (__xargmatch_internal): Remove case_sensitive argument.
27980         (main): Use XARGMATCH instead of XARGCASEMATCH.
27981
27982         * lib/xmalloc.c: Change compile-time error message. Add comment about
27983         required autoconf version.
27984
27985 2002-11-20  Paul Eggert  <eggert@twinsun.com>
27986
27987         Merge argmatch cleanups from Bison.  Assume C89.
27988
27989         * lib/argmatch.c: Include config.h here, not in argmatch.h.
27990         Include stdlib.h, for EXIT_FAILURE.
27991         Always include <string.h>, since we assume C89.
27992         (EXIT_FAILURE): Remove pre-C89 bug workaround.
27993         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
27994         Include <stddef.h> instead, since it's all we need for size_t.
27995         (PARAMS): Remove.  All uses removed.
27996         (ARRAY_CARDINALITY): Do not bother to #undef.
27997         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
27998         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
27999         Remove unnecessary parentheses.
28000         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28001         Insert necessary parentheses.
28002         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
28003         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
28004
28005 2002-11-19  Bruno Haible  <bruno@clisp.org>
28006
28007         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
28008         * lib/mbswidth.h: Include <stddef.h>, for size_t.
28009
28010         * lib/mbswidth.h (PARAMS): Remove macro.
28011         (mbswidth, mbsnwidth): Use ANSI C function declarations.
28012         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
28013
28014         * lib/gcd.h (PARAMS): Remove macro.
28015         (gcd): Use ANSI C function declarations.
28016         * lib/gcd.c (gcd): Likewise.
28017
28018 2002-11-15  Bruno Haible  <bruno@clisp.org>
28019
28020         * lib/strcspn.c: Include <stddef.h>.
28021         (strcspn): Use ANSI C function declaration. Change return type to
28022         size_t. Use NULL.
28023         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
28024         (strpbrk): Use NULL.
28025         * lib/strpbrk.h (PARAMS): Remove macro.
28026         (strpbrk): Use ANSI C function declaration.
28027         * lib/strstr.c: Don't include <sys/types.h>.
28028         * lib/strstr.h (PARAMS): Remove macro.
28029         (strstr): Use ANSI C function declarations.
28030
28031 2002-11-14  Karl Berry  <karl@gnu.org>
28032
28033         * config/mkinstalldirs: `do' on separate line, instead of
28034         `for var; do'.
28035
28036 2002-11-06  Bruno Haible  <bruno@clisp.org>
28037
28038         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
28039         * lib/gcd.c (gcd): Likewise.
28040
28041 2002-11-05  Bruno Haible  <bruno@clisp.org>
28042
28043         * lib/gcd.h: New file, from gettext-0.11.5.
28044         * lib/gcd.c: New file, from gettext-0.11.5.
28045
28046 2002-11-05  Bruno Haible  <bruno@clisp.org>
28047
28048         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28049         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28050         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28051         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28052
28053         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
28054         <libintl.h>.
28055         * lib/makepath.c: Include gettext.h instead of <locale.h> and
28056         <libintl.h>.
28057
28058         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
28059         * lib/human.c: Include gettext.h instead of <libintl.h>.
28060         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
28061         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
28062         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
28063         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
28064         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
28065         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
28066         (textdomain): Remove definition.
28067         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
28068
28069         * lib/long-options.c: Remove include of <libintl.h> and definition of
28070         _.
28071         * lib/same.c: Remove include of <libintl.h> and definition of _.
28072
28073 2002-11-04  Owen Taylor  <otaylor@redhat.com>
28074
28075         * lib/config.charset: A few additions for Solaris.
28076
28077 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28078
28079         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
28080         * lib/localcharset.c (locale_charset): Declare as extern "C".
28081
28082 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28083
28084         * lib/config.charset: msdos in uk_UA uses CP1125.
28085
28086 2002-11-04  Bruno Haible  <bruno@clisp.org>
28087
28088         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
28089         * lib/strcase.h: New file, from GNU gettext-0.11.5.
28090         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
28091         * lib/strstr.h: New file, from GNU gettext-0.11.5.
28092         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
28093
28094 2002-11-04  Bruno Haible  <bruno@clisp.org>
28095
28096         * lib/localcharset.c (locale_charset): Don't return an empty string.
28097
28098 2002-11-04  Bruno Haible  <bruno@clisp.org>
28099
28100         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
28101         aliases.
28102
28103 2002-11-04  Bruno Haible  <bruno@clisp.org>
28104
28105         * lib/config.charset: Update for newest glibc. Add canonical names
28106         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
28107
28108 2002-11-04  Bruno Haible  <bruno@clisp.org>
28109
28110         * lib/config.charset: Add support for NetBSD.
28111
28112 2002-11-04  Bruno Haible  <bruno@clisp.org>
28113
28114         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
28115
28116 2002-11-01  Bruno Haible  <bruno@clisp.org>
28117
28118         * configure.in: Add AC_CONFIG_AUX_DIR call.
28119         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
28120         test/Makefile.
28121         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
28122
28123 2002-09-28  Karl Berry  <karl@gnu.org>
28124
28125         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
28126         installed automake until the next release, since changes have been
28127         made.
28128
28129 2002-09-25  Karl Berry  <karl@gnu.org>
28130
28131         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
28132         * lib/getopt*: copy from libc/posix.
28133         * lib/gettext.h: copy from gettext.
28134         * lib/.cppi-disable: add strdup.c, gettext.h.
28135
28136 2002-09-25  Karl Berry  <karl@gnu.org>
28137
28138         * config/srclist.txt: enable gettext.h check.
28139         * config/config.{guess,sub}: update from prep.
28140         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
28141                 from automake 1.6.3.
28142         See srclist*.
28143
28144 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
28145
28146         * regex.c (PATFETCH): Remove the translating fetch.
28147         (PATFETCH_RAW): Rename to PATFETCH.
28148         (set_image_of_range): New fun.
28149         (SET_RANGE_TABLE_WORK_AREA): Use it.
28150         (regex_compile): Don't translate the pattern chars so eagerly.
28151         Only do it when inserting an `exactn' bytecode or when handling
28152         a char-range.
28153         (mutually_exclusive_p): Avoid empty statement.
28154
28155 2002-07-06  Jim Meyering  <meyering@lucent.com>
28156
28157         * m4/README: Don't mention Makefile.am.in.
28158         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
28159
28160 2002-07-01  Jim Meyering  <meyering@lucent.com>
28161
28162         * lib/c-stack.c: Include sys/time.h.
28163         From Volker Borchert.
28164
28165 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28166
28167         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
28168
28169 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28170
28171         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
28172         New macro.  Use it uniformly instead of
28173         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
28174         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
28175         reported by Vin Shelton.
28176
28177 2002-06-22  Paul Eggert  <eggert@twinsun.com>
28178
28179         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
28180         Do not assume SA_SIGINFO behavior.
28181         Bug reported by Jim Meyering on NetBSD 1.5.2.
28182
28183 2002-06-22  Jim Meyering  <meyering@lucent.com>
28184
28185         * m4/c-stack.m4: New file, from diffutils-2.8.2.
28186         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
28187
28188         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
28189         now that configure.ac uses AC_GNU_SOURCE.
28190         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
28191         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
28192
28193         Update to latest tools.  Suggestions from Paul Eggert.
28194         * m4/stdbool.m4: New file, from diffutils-2.8.2.
28195         * m4/gnu-source.m4: Update from diffutils-2.8.2.
28196         * m4/fnmatch.m4: Likewise.
28197         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
28198         to AC_HEADER_STDBOOL
28199
28200 2002-06-22  Jim Meyering  <meyering@lucent.com>
28201
28202         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
28203         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
28204
28205 2002-06-22  Jim Meyering  <meyering@lucent.com>
28206
28207         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
28208
28209         * lib/exitfail.c, exitfail.h: Likewise.
28210         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
28211
28212         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
28213         of fnmatch.h.
28214         (EXTRA_DIST): Add fnmatch_loop.c.
28215         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
28216
28217         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
28218         * lib/fnmatch.c: Update from diffutils-2.8.2.
28219         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
28220         * lib/fnmatch.h: Remove file.
28221
28222 2002-06-21  Jim Meyering  <meyering@lucent.com>
28223
28224         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
28225         * m4/mbrtowc.m4: Likewise.
28226
28227         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
28228         * m4/mbswidth.m4: Reflect name change:
28229         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
28230         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
28231
28232         * m4/lib-link.m4: Update from gettext-0.11.2.
28233         * m4/gettext.m4: Likewise.
28234
28235         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
28236         From Alfred M. Szmidt.
28237
28238 2002-06-18  Paul Eggert  <eggert@twinsun.com>
28239
28240         * lib/file-type.h: Report an error if neither S_ISREG nor
28241         S_IFREG is defined, instead of using a test specific to glibc
28242         2.2.  This should be safe, since POSIX requires S_ISREG and
28243         Unix Version 7 had S_IFREG.  We don't need to check for
28244         <sys/types.h> since we don't use any symbols that it defines.
28245
28246 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
28247
28248         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
28249         $@-t, so that each temporary file name is unique and valid in the first
28250         8 characters, for operation under DOS.
28251
28252 2002-06-15  Paul Eggert  <eggert@twinsun.com>
28253
28254         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
28255
28256 2002-06-15  Jim Meyering  <meyering@lucent.com>
28257
28258         Work even with DJGPP 2.03, which lacks support for symlinks.
28259         From Richard Dawe.
28260         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
28261         is defined.
28262         * lib/lchown.c (S_ISLNK): Likewise.
28263
28264 2002-06-15  Jim Meyering  <meyering@lucent.com>
28265
28266         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
28267         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
28268         have been included before this file.
28269
28270 2002-06-14  Jim Meyering  <meyering@lucent.com>
28271
28272         * lib/file-type.h: Use the version from diffutils-2.8.2.
28273         * lib/file-type.c: Likewise.
28274
28275 2002-06-07  Jim Meyering  <meyering@lucent.com>
28276
28277         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
28278         They're needed at least for NetBSD 1.5.2.
28279         ($statxfs_includes): Include those same headers.
28280         ($statxfs_includes): Include sys/vfs.h if available.
28281         ($statxfs_includes): Likewise for sys/statvfs.h.
28282         Check for the following members in both structs statfs and statvfs:
28283         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
28284
28285 2002-06-01  Jim Meyering  <meyering@lucent.com>
28286
28287         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
28288         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
28289
28290 2002-05-28  Jim Meyering  <meyering@lucent.com>
28291
28292         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
28293         Reported by Volker Borchert.
28294
28295 2002-05-27  Jim Meyering  <meyering@lucent.com>
28296
28297         Fix a problem seen only on nonconforming systems whereby ls.c's
28298         use of localtime, and then of gettimeofday would cause trouble:
28299         the localtime call used to initialize rpl_gettimeofday's save
28300         mechanism would clobber ls's current local time information so
28301         that in any long listing the first file would always be listed
28302         with date 1970-01-01.  Analysis by Volker Borchert.
28303
28304         * lib/gettimeofday.c (localtime): Undefine.
28305         (rpl_localtime): New function.
28306
28307 2002-05-27  Jim Meyering  <meyering@lucent.com>
28308
28309         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
28310         localtime.
28311
28312         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
28313         use the replacement function; it wouldn't resolve at link time.
28314         Reported by Volker Borchert.
28315
28316 2002-05-22  Jim Meyering  <meyering@lucent.com>
28317
28318         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
28319         file-type.h.
28320         * lib/file-type.h: New file.
28321         * lib/file-type.c (file_type): New file/function.  Extracted from
28322         diffutils.
28323
28324 2002-04-30  Jim Meyering  <meyering@lucent.com>
28325
28326         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
28327
28328 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28329
28330         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
28331
28332 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28333
28334         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
28335         Do not check for alloca.h (no longer used) or stdbool.h (was never
28336         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
28337
28338 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28339
28340         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
28341
28342 2002-04-29  Jim Meyering  <meyering@lucent.com>
28343
28344         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
28345         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
28346         Use AC_FUNC_STRNLEN here instead.
28347
28348         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
28349         With autoconf-2.53a, it's part of AC_PROG_CC.
28350
28351 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28352
28353         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
28354         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
28355
28356 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28357
28358         * lib/sig2str.h, lib/sig2str.c: New files.
28359         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
28360
28361 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28362
28363         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
28364         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
28365         of 127, since 64 is the largest conceivable number for ancient
28366         nonstandard hosts.
28367         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
28368
28369 2002-04-28  Jim Meyering  <meyering@lucent.com>
28370
28371         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
28372
28373 2002-04-24  Jim Meyering  <meyering@lucent.com>
28374
28375         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
28376         (jm_PREREQ): Use it.
28377
28378         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
28379         mach/mach.h fcntl.h.
28380         Check for this function: setlocale.
28381
28382 2002-04-24  Jim Meyering  <meyering@lucent.com>
28383
28384         * lib/gettext.h: New file, from Gettext.
28385         * lib/Makefile.am (INCLUDES): Remove -I../intl.
28386         (libfetish_a_SOURCES): Add gettext.h.
28387
28388 2002-04-16  Jim Meyering  <meyering@lucent.com>
28389
28390         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
28391         ut_pid, ut_id, ut_exit.
28392
28393 2002-04-16  Jim Meyering  <meyering@lucent.com>
28394
28395         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
28396         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
28397         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
28398
28399 2002-04-12  Jim Meyering  <meyering@lucent.com>
28400
28401         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
28402         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
28403         existence of the getmntinfo function.  Needed for Darwin 5.3.
28404
28405         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28406         This is necessary at least on Darwin 5.3.
28407
28408         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28409         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28410         strnlen.o in the library, and that makes some versions of ranlib
28411         object.
28412
28413 2002-04-12  Jim Meyering  <meyering@lucent.com>
28414
28415         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28416
28417 2002-04-09  Jim Meyering  <meyering@lucent.com>
28418
28419         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28420         to be more precise.  Rather than saying we're checking whether the
28421         function `works', say what we're testing.
28422         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28423         Reported by Bruno Haible.
28424
28425 2002-03-10  Jim Meyering  <meyering@lucent.com>
28426
28427         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28428         Suggestion from Santiago Vila.
28429
28430 2002-03-08  Jim Meyering  <meyering@lucent.com>
28431
28432         * lib/rename.c: Mention that this wrapper is needed also on
28433         mips-dec-ultrix4.4 systems.
28434
28435 2002-03-02  Jim Meyering  <meyering@lucent.com>
28436
28437         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28438         not HAVE_CLOCK_SETTIME.
28439
28440 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28441
28442         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28443         Check for clock_settime.
28444
28445 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28446
28447         * lib/nanosleep.h: Rename to....
28448         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28449
28450         * lib/gettime.c: New file.
28451         * lib/settime.c: New file.
28452         * lib/stime.c: Remove.
28453
28454         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28455         timespec.h.  Remove nanosleep.h.
28456
28457 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28458
28459         * m4/acl.m4: New file.
28460         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28461         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28462
28463 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28464
28465         * lib/acl.c, lib/acl.h: New files.
28466         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28467
28468 2002-02-24  Jim Meyering  <meyering@lucent.com>
28469
28470         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28471         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28472         cause trouble.  Reported by Nelson Beebe.
28473
28474 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28475
28476         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28477         compilers that don't know that xalloc_die never returns.
28478
28479 2002-02-20  Jim Meyering  <meyering@lucent.com>
28480
28481         * lib/getdate.c: Regenerate using bison-1.33.
28482
28483 2002-02-17  Jim Meyering  <meyering@lucent.com>
28484
28485         * config/config.guess (main): Don't use `head -1'; it's no longer
28486         portable. Use `sed 1q' instead.
28487
28488 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28489
28490         * m4/codeset.m4: Upgrade to gettext-0.11.
28491         * m4/gettext.m4: Upgrade to gettext-0.11.
28492         * m4/glibc21.m4: Upgrade to gettext-0.11.
28493         * m4/iconv.m4: Upgrade to gettext-0.11.
28494         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28495         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28496         * m4/lib-ld.m4: New file, from gettext-0.11.
28497         * m4/lib-link.m4: New file, from gettext-0.11.
28498         * m4/lib-prefix.m4: New file, from gettext-0.11.
28499         * m4/progtest.m4: Upgrade to gettext-0.11.
28500
28501 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28502
28503         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28504         (jm_PREREQ): Use it.
28505
28506 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28507
28508         * lib/posixver.c, lib/posixver.h: New files.
28509         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28510
28511 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28512             Bruno Haible  <bruno@clisp.org>
28513
28514         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28515         (fwrite_success_callback): New declaration.
28516         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28517         print_unicode_char. Call failure callback instead of error.
28518         (fwrite_success_callback): New function.
28519         (exit_failure_callback): New function.
28520         (fallback_failure_callback): New function.
28521         (print_unicode_char): Call unicode_to_mb.
28522
28523 2002-01-26  Jim Meyering  <meyering@lucent.com>
28524
28525         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28526         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28527
28528 2002-01-26  Jim Meyering  <meyering@lucent.com>
28529
28530         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28531
28532 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28533
28534         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28535
28536 2002-01-22  Jim Meyering  <meyering@lucent.com>
28537
28538         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28539         Otherwise, some versions of automake would omit the rule that makes
28540         Makefile from Makefile.in.
28541
28542 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28543
28544         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28545         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28546         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28547         (memcoll): Set errno to zero if there is no error.
28548
28549         * lib/quotearg.c (quotearg_buffer_restyled):
28550         Fix bug with quoting buffers containing NUL when backslashing escapes.
28551         This bug was exposed by the other changes in this patch.
28552         (quotearg_n_options): New arg ARGSIZE.
28553         All callers changed.
28554         (quoting_options_from_style): New function.
28555         (quotearg_n_style): Use it.
28556         (quotearg_n_style_mem): New function.
28557
28558         * lib/quotearg.h (quotearg_n_style_mem): New function.
28559
28560 2002-01-19  Jim Meyering  <meyering@lucent.com>
28561
28562         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28563         Remove useless quotes: DF_PROG="df".
28564         * m4/strnlen.m4: New file.
28565
28566 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28567
28568         * lib/backupfile.c (ISDIGIT): Comment fix.
28569         * lib/getdate.y (ISDIGIT): Likewise.
28570         * lib/posixtm.c (ISDIGIT, year): Likewise.
28571         * lib/strverscmp.c (ISDIGIT): Likewise.
28572         * lib/userspec.c (ISDIGIT): Likewise.
28573
28574 2002-01-16  Jim Meyering  <meyering@lucent.com>
28575
28576         * lib/getdate.y: Add three semicolons, each just before a closing
28577         brace. Bison (as of version 1.31) no longer papers over that mistake.
28578
28579 2002-01-05  Jim Meyering  <meyering@lucent.com>
28580
28581         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28582
28583 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28584
28585         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
28586         not silently exit merely because the output buffer happens to
28587         have nothing pending.
28588
28589 2001-12-18  Paul Eggert  <eggert@twinsun.com>
28590
28591         See the big note in ../ChangeLog.
28592         * lib/human.c (suffixes): Prefer K to k for 1024.
28593         (generate_suffix_backwards): New function.
28594         (human_readable_inexact): Use it.
28595         * lib/xstrtol.c (__xstrtol): If there is no number but there
28596         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
28597         Accept 'K' as well as 'k'.
28598
28599 2001-12-15  Jim Meyering  <meyering@lucent.com>
28600
28601         * lib/regex.h (__restrict_arr): Update from libc.
28602
28603         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
28604         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
28605         (STREQ): Define.
28606
28607 2001-12-14  Jim Meyering  <meyering@lucent.com>
28608
28609         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
28610         Suggestion from Bruno Haible.
28611
28612 2001-12-10  Jim Meyering  <meyering@lucent.com>
28613
28614         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
28615         xrealloc, Instead, include "xalloc.h".
28616         (initbuffer): Don't cast xmalloc return value to char*.
28617         (readline): Reword comment.
28618         Don't cast xrealloc return value to char*
28619         Return NULL, not 0.
28620
28621 2001-12-09  Jim Meyering  <meyering@lucent.com>
28622
28623         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
28624         about `signed and unsigned type in conditional expression'.
28625         * lib/posixtm.c (posix_time_parse): Likewise.
28626
28627         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
28628
28629         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
28630         to avoid a pedantic warning.
28631
28632         * lib/getstr.c: Don't include assert.h.
28633         (getstr): Remove warning-evoking assertions.
28634         Return -1 if offset parameter is out of bounds.
28635         Change the type of a local from int to size_t.
28636
28637         * lib/strftime.c (my_strftime_localtime_r): Include this function
28638         definition in the `#if ! HAVE_TM_GMTOFF' block.
28639
28640         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
28641         Include xalloc.h instead.
28642
28643 2001-12-02  Jim Meyering  <meyering@lucent.com>
28644
28645         * lib/tempname.c: Don't declare getenv, thus reverting the change of
28646         2001-11-18.  It's no longer necessary, now that stdlib.h is always
28647         included.
28648
28649         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
28650         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
28651
28652 2001-11-30  Akim Demaille  <akim@epita.fr>
28653
28654         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
28655         before being defined.
28656
28657 2001-11-27  Paul Eggert  <eggert@twinsun.com>
28658
28659         * lib/quotearg.h (quotearg_n, quotearg_n_style):
28660         First arg is int, not unsigned.
28661         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
28662         (SIZE_MAX, UINT_MAX): New macros.
28663         (quotearg_n_options): Abort if N is negative.
28664         Avoid overflow check on hosts where size_t is 64 bits and int
28665         is 32 bits, as overflow is impossible there.
28666         Fix off-by-one typo that caused unnecessary reallocation.
28667
28668 2001-11-27  Jim Meyering  <meyering@lucent.com>
28669
28670         * lib/tempname.c: Merge with version from libc.
28671         * lib/regex.c: Likewise.
28672
28673         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
28674         systems for which STDC_HEADERS is 0, it was not included, resulting in
28675         a warning about an integer-to-pointer conversion problem with getenv.
28676         Reported by Volker Borchert.
28677
28678 2001-11-26  Jim Meyering  <meyering@lucent.com>
28679
28680         * lib/gtod.h: Remove file.
28681         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
28682         * lib/gettimeofday.c: Don't include gtod.h.
28683         (GTOD_init): Remove function.
28684         (rpl_gettimeofday): Do its job here instead, rather than aborting.
28685         Suggestion from Volker Borchert.
28686
28687 2001-11-23  Jim Meyering  <meyering@lucent.com>
28688
28689         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
28690         it.
28691         * lib/hash.c (struct hash_table): Define it here instead.
28692
28693 2001-11-22  Jim Meyering  <meyering@lucent.com>
28694
28695         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
28696
28697 2001-11-20  Jim Meyering  <meyering@lucent.com>
28698
28699         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
28700         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
28701
28702 2001-11-19  Jim Meyering  <meyering@lucent.com>
28703
28704         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
28705         directory.  Use "conftestXXXXXX" as the template.
28706         Suggestion from Paul Eggert.
28707
28708         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
28709         immediately, so the test doesn't mistakenly hit the max-open-files
28710         limit.
28711
28712 2001-11-18  Paul Eggert  <eggert@twinsun.com>
28713
28714         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
28715         (TEMPORARIES): New macro.
28716         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
28717         removes an artificial limitation (e.g. HP-UX 10.20, where
28718         TMP_MAX is 17576).
28719
28720 2001-11-18  Jim Meyering  <meyering@lucent.com>
28721
28722         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
28723
28724 2001-11-18  Jim Meyering  <meyering@lucent.com>
28725
28726         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
28727         on SunOS 4.
28728
28729         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
28730         files will be created before anything else.
28731
28732 2001-11-17  Paul Eggert  <eggert@twinsun.com>
28733
28734         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
28735         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
28736
28737 2001-11-17  Jim Meyering  <meyering@lucent.com>
28738
28739         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
28740         Prompted by a report from Bob Proulx.
28741
28742         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
28743         Instead, require UTILS_FUNC_MKSTEMP.
28744
28745 2001-11-17  Jim Meyering  <meyering@lucent.com>
28746
28747         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
28748         Now, that's done as part of AC_FUNC_STRTOD.
28749
28750 2001-11-17  Jim Meyering  <meyering@lucent.com>
28751
28752         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
28753         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
28754         rather than group writable.  Patch by Juan F. Codagnone.
28755
28756         * lib/readtokens.c: Remove explicit declarations of xmalloc and
28757         xrealloc, Instead, include "xalloc.h".
28758
28759         * lib/mountlist.c: Include unlocked-io.h after all system headers.
28760         Remove explicit declarations of xmalloc, xrealloc,
28761         and xstrdup.  Instead, include "xalloc.h".
28762
28763         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
28764         unlocked-io.h.
28765         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
28766         Likewise.
28767         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
28768
28769         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
28770         Reported by Padraig Brady.
28771
28772         * lib/mkstemp.c: #undef mkstemp.
28773         Include config.h.
28774         (rpl_mkstemp): Rename from mkstemp.
28775         Protoize.
28776
28777 2001-11-16  Jim Meyering  <meyering@lucent.com>
28778
28779         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
28780         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
28781         determine the amount of total physical memory, use pstat_getstatic.
28782         HPUX-11 doesn't define _SC_PHYS_PAGES.
28783         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
28784         If sysconf couldn't be used to determine the amount of available
28785         physical memory, use both pstat_getstatic and pstat_getdynamic.
28786         Based on a patch from Bob Proulx.
28787
28788 2001-11-10  Jim Meyering  <meyering@lucent.com>
28789
28790         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
28791         (jm_PREREQ): Use it.
28792
28793 2001-11-09  Jim Meyering  <meyering@lucent.com>
28794
28795         * m4/jm-macros.m4: Require autoconf-2.52f.
28796         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
28797         Use these AC_-prefixed names, not the AM_-prefixed ones.
28798
28799         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
28800
28801 2001-11-05  Jim Meyering  <meyering@lucent.com>
28802
28803         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
28804
28805 2001-11-04  Jim Meyering  <meyering@lucent.com>
28806
28807         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
28808         $DEFS.
28809
28810 2001-11-03  Jim Meyering  <meyering@lucent.com>
28811
28812         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
28813         of AC_DEFUN.
28814
28815         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
28816         know the name of the variable in the macro definition.
28817
28818 2001-11-03  Jim Meyering  <meyering@lucent.com>
28819
28820         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
28821         in argmatch_to_argument call.
28822
28823         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
28824         argument.
28825
28826         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
28827         e.g., a fault due to an attempt to free a NULL pointer.
28828
28829 2001-11-01  Jim Meyering  <meyering@lucent.com>
28830
28831         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
28832         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
28833
28834 2001-11-01  Jim Meyering  <meyering@lucent.com>
28835
28836         * lib/dirfd.c, lib/dirfd.h: New files.
28837         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
28838
28839         * lib/hash.c (hash_print) [TESTING]: Clean up.
28840
28841 2001-10-22  Paul Eggert  <eggert@twinsun.com>
28842
28843         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
28844         to avoid a warning if -Wall.
28845
28846 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
28847
28848         * README: New file
28849         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
28850         (per RMS's instructions, this is now the canonical source)
28851         * lgpl/, gpl/: New directories.
28852
28853 2001-10-21  Paul Eggert  <eggert@twinsun.com>
28854
28855         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
28856
28857 2001-10-21  Jim Meyering  <meyering@lucent.com>
28858
28859         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
28860         this code would end up calling gettext even in packages built
28861         with --disable-nls.
28862         * lib/getopt.c (_): Likewise.
28863         * lib/regex.c (_): Likewise.
28864
28865 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28866
28867         * m4/error.m4 (jm_PREREQ_ERROR):
28868         Do not invoke AC_CHECK_FUNCS with strerror_r, as
28869         AC_FUNC_STRERROR_R does that.
28870         Check for strerror declaration.
28871
28872         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
28873         are supposed to have them these days.
28874         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
28875         Merge changes from latest Autoconf CVS.
28876         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
28877         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
28878         POSIX decided to standardize on the int flavor of strerror_r.
28879
28880 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28881
28882         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
28883         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
28884         Use strerror_r that is only a macro, even if it is not a function.
28885         (strerror): Check for HAVE_DECL_STRERROR before declaring.
28886         (private_strerror): Use prototypes, not old-style function definition.
28887         (print_errno_message): New function.
28888         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
28889         char*-flavored one.
28890         (error_tail, error, error_at_line): Use it.
28891
28892 2001-10-11  Jim Meyering  <meyering@lucent.com>
28893
28894         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
28895         and quote_n (1, ... to avoid clobbering a buffer.
28896
28897 2001-10-05  Jim Meyering  <meyering@lucent.com>
28898
28899         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
28900         hash-pjw.h.
28901         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
28902         * lib/hash-pjw.h: New file.
28903
28904 2001-09-30  Jim Meyering  <meyering@lucent.com>
28905
28906         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
28907         `struct fsstat' has the `f_fstypename' member.
28908         Use that to define FS_TYPE, which is now used to make
28909         the getfsstat link test tighter.
28910
28911 2001-09-30  Jim Meyering  <meyering@lucent.com>
28912
28913         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
28914         Include <sys/ucred.h>, for Apple Darwin.
28915         Include sys/mount.h and sys/fs_types.h only if available.
28916         (FS_TYPE): Define.
28917         (read_filesystem_list): Use FS_TYPE.
28918
28919 2001-09-29  Paul Eggert  <eggert@twinsun.com>
28920
28921         * lib/exclude.c (excluded_filename): 0 -> false, since it's
28922         a boolean context.
28923
28924 2001-09-29  Jim Meyering  <meyering@lucent.com>
28925
28926         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28927         [one-argument getmntent function]): Include stdio.h before mntent.h.
28928         SunOS 4.1.x needs it for the declaration of `FILE'.
28929         Patch by Volker Borchert.
28930
28931         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28932         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
28933         sys/fs_types.h, and make the link-test for getfsstat guard #include
28934         directives with appropriate #if HAVE_*_H tests so that we can
28935         detect getfsstat on Apple Darwin1.3.7 systems.
28936         Reported by Nelson Beebe.
28937         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
28938
28939 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28940
28941         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28942         #defines strtoimax.  Also treat the other strto* functions
28943         like strtoimax.
28944
28945         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
28946         Check for strtoul and strtoumax,
28947         as those declarations are made even in the signed case.
28948         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
28949         Likewise, for strtol and strtoimax.
28950
28951 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28952
28953         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28954         #defines strtoimax.  Also treat the other strto* functions
28955         like strtoimax.
28956
28957         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
28958         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
28959         (strtoimax, strtoumax): Do not declare if already defined as a macro.
28960
28961 2001-09-26  Jim Meyering  <meyering@lucent.com>
28962
28963         Most macros in unlocked-io.h had the wrong number of arguments.
28964         * lib/gen-uio: New script.
28965         (USE_UNLOCKED_IO): Define to 1 if not already defined.
28966         * lib/unlocked-io.hin: Remove file.
28967         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
28968         rather than trying to embed it here.
28969         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
28970         Reported by Padraig Brady.
28971
28972 2001-09-25  Volker Borchert  <bt@teknon.de>
28973
28974         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
28975         `result'.
28976
28977 2001-09-24  Jim Meyering  <meyering@lucent.com>
28978
28979         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
28980
28981 2001-09-23  Jim Meyering  <meyering@lucent.com>
28982
28983         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
28984         instead of the mere test for existence of mntent.h.  The latter
28985         would get a false-positive on AIX 3.4 systems.
28986         In the outer getmntent if-block, don't die if neither of the getmntent
28987         tests succeeds.  Instead, just fall through and continue with the
28988         remaining tests.
28989
28990 2001-09-23  Jim Meyering  <meyering@lucent.com>
28991
28992         * lib/mountlist.c: Remove useless parentheses in #if directives.
28993         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
28994         the deprecated MOUNTED symbol is no longer defined in mntent.h.
28995
28996 2001-09-22  Jim Meyering  <meyering@lucent.com>
28997
28998         * m4/gettext.m4: New file.  From gettext.
28999         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
29000         * m4/progtest.m4: Likewise
29001         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
29002         * m4/glibc21.m4: Likewise.
29003
29004         * m4/libintl.m4: Remove.  No longer used.
29005
29006 2001-09-22  Jim Meyering  <meyering@lucent.com>
29007
29008         * lib/localcharset.c: Update from latest gettext.
29009         * lib/config.charset: Likewise.
29010
29011 2001-09-20  Jim Meyering  <meyering@lucent.com>
29012
29013         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
29014         strtoimax.
29015         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
29016         strtoumax.
29017
29018 2001-09-20  Jim Meyering  <meyering@lucent.com>
29019
29020         * lib/xstrtol.c (strtoimax): Guard declaration with
29021         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
29022         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
29023         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
29024         (strtoumax): Likewise, for completeness (it wasn't necessary).
29025
29026 2001-09-17  Paul Eggert  <eggert@twinsun.com>
29027
29028         * lib/strtoimax.c (HAVE_LONG_LONG):
29029         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
29030         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
29031         to work around bug in IBM C compiler.
29032
29033 2001-09-17  Jim Meyering  <meyering@lucent.com>
29034
29035         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
29036         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
29037         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
29038         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
29039         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
29040         whenever the right hand side need not be expanded by the shell.
29041
29042 2001-09-16  Paul Eggert  <eggert@twinsun.com>
29043
29044         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
29045         library.  It's not correct, as some older glibcs are buggy.
29046         fnmatch wasn't fixed until glibc 2.2.
29047
29048         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
29049         special shell magic here.
29050
29051 2001-09-16  Jim Meyering  <meyering@lucent.com>
29052
29053         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
29054         * m4/jm-macros.m4: Require it.
29055
29056 2001-09-16  Jim Meyering  <meyering@lucent.com>
29057
29058         * lib/mkdir.c: New file.
29059
29060 2001-09-15  Jim Meyering  <meyering@lucent.com>
29061
29062         * m4/jm-macros.m4: Check for help2man.
29063
29064 2001-09-11  Jim Meyering  <meyering@lucent.com>
29065
29066         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
29067         The body, by Paul Eggert, was moved here from configure.in.
29068         * m4/jm-macros.m4: Require UTILS_HOST_OS.
29069
29070 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29071
29072         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
29073         (jm_PREREQ): Use it.
29074
29075 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29076
29077         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
29078         Use ssize_t, not int, to store result of readlink.
29079         Check for ssize_t overflow as well as size_t overflow,
29080         as POSIX says the result of readlink is implementation-defined
29081         when ssize_t overflows.
29082         Remove unnecessary cast to char*.
29083         Use free+malloc instead of realloc, as the storage doesn't need
29084         to be preserved and it's clearer and can be more efficient that way.
29085         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
29086         * lib/xreadlink.h (xreadlink): Update prototype.
29087
29088 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29089
29090         * lib/xgetcwd.c: Revert some of the previous change; intead,
29091         fix the HAVE_GETCWD_NULL code to behave more like the
29092         !HAVE_GETCWD_NULL code used to.
29093
29094         Include "xalloc.h".
29095         (xgetcwd): Do not return NULL when memory is exhausted; instead,
29096         invoke xalloc_die.
29097
29098 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29099
29100         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
29101         sys/param.h, as pathmax.h includes them.
29102
29103 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29104
29105         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
29106         (jm_PREREQ_XGETCWD): New macro.
29107
29108         * m4/getcwd.m4: New file.
29109
29110 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29111
29112         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
29113         like the HAVE_GETCWD_NULL code.
29114         Include pathmax.h if not HAVE_GETCWD.
29115         Do not include xalloc.h.
29116         (INITIAL_BUFFER_SIZE): New symbol.
29117         Do not use xmalloc / xrealloc, since the caller is responsible for
29118         handling errors.  Preserve errno around `free' during failure.
29119         Do not overrun buffer when using getwd.
29120
29121 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29122
29123         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
29124         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
29125         getcwd (NULL, 0).
29126
29127 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29128
29129         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
29130         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
29131         spotted by Jim Meyering.
29132
29133 2001-09-03  Jim Meyering  <meyering@lucent.com>
29134
29135         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
29136         failure.
29137
29138 2001-09-02  Jim Meyering  <meyering@lucent.com>
29139
29140         * lib/error.c: Update from GNU libc.
29141
29142 2001-09-01  Jim Meyering  <meyering@lucent.com>
29143
29144         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
29145         Used by df.
29146
29147 2001-09-01  Jim Meyering  <meyering@lucent.com>
29148
29149         * lib/xreadlink.c: New file.
29150         * lib/xreadlink.h: New file.
29151         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
29152         xreadlink.h.
29153
29154         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
29155         doesn't conflict with sparc Solaris 7's definition in
29156         /usr/include/sys/int_types.h.
29157
29158         * lib/exclude.c: Use `""', not `<>' to #include non-system header
29159         files.
29160         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
29161         and strncasecmp as r-values.  Unixware didn't have declarations.
29162
29163 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29164
29165         * lib/xstrtol.h: Add copyright notice.
29166         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
29167         LONGINT_INVALID_SUFFIX_CHAR.
29168
29169 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29170
29171         * lib/xstrtol.c (strtoimax): New decl.
29172
29173 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29174
29175         * lib/xgetcwd.c: Don't include pathmax.h.
29176         Include stdlib.h and unistd.h if available.
29177         Include xalloc.h.
29178         (xmalloc, xstrdup, free): Remove decls.
29179         (xgetcwd): Don't assume sizes fit in unsigned.
29180         Check for overflow when computing sizes.
29181         Simplify reallocation code.
29182
29183 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29184
29185         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
29186         a directory's st_size can have an arbitrary value, so the old
29187         usage could waste an arbitrary amount of memory.  All uses
29188         changed.
29189         * lib/savedir.h: Update prototype.
29190
29191 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29192
29193         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
29194
29195         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
29196         old strtoimax.c.
29197
29198         Also, make the following further changes to make this file's
29199         configuration more similar to that of strtol.c:
29200         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
29201         (strtoumax, uintmax_t, strtoull, strtol): Remove.
29202         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
29203         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
29204         changed to signed values.
29205
29206         And make the following changes as well:
29207         Fix copyright notice, as 1999 was missing.
29208         (verify): New macro.
29209         (strtoimax): Check sizes at compile-time, not run-time.
29210         Prefer strtol to strtoll if both work.
29211         (main): Remove; it was not that useful and was a pain to maintain.
29212
29213         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
29214
29215 2001-08-31  Jim Meyering  <meyering@lucent.com>
29216
29217         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
29218         Use an initial, malloc'd, buffer of length 128 rather than
29219         a statically allocated one of length 1024.
29220
29221 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29222
29223         Simplify code, partly by assuming autoconf 2.52 semantics.
29224
29225         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
29226
29227         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
29228         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
29229         All uses removed.
29230         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
29231         Move AC_REQUIRE to next-to-top level, to avoid confusion.
29232         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
29233         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
29234         jm_AC_HEADER_INTTYPES_H.
29235         * m4/jm-macros.m4 (jm_MACROS): Likewise.
29236
29237         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
29238
29239         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29240         Quote first arg of AC_DEFUN.
29241         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
29242         since they are needed to parse the include file even if we need
29243         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
29244         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
29245         but with opposite signedness.
29246
29247 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29248
29249         Merge 'exclude' changes from tar 1.13.22.
29250         This fixes one or two unlikely storage allocation overflow bugs,
29251         but doesn't change user-visible behavior otherwise.
29252
29253 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29254
29255         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
29256         (jm_PREREQ_EXCLUDE): New macro.
29257
29258 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29259
29260         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
29261         tm to be declared.
29262
29263 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29264
29265         * lib/hash.c: Remove '2001' from copyright notice.
29266
29267 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29268
29269         * lib/full-write.h: New file.
29270         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
29271         * lib/full-write.c: Correct credits, as cccp.c no longer
29272         exists and anyway it was so heavily changed from the old cccp
29273         code as to be unrecognizable.  Include full-write.h.
29274         (full_write) Return size_t, with short writes meaning failure.
29275         All callers changed.  This fixes a bug with large buffers
29276         on 64-bit hosts.
29277         * lib/utime.c: Include full-write.h.
29278
29279 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29280
29281         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
29282         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
29283         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
29284         Include if available.
29285         (<xalloc.h>): Include
29286         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
29287         (verify): New macro.  Use it to verify that EXCLUDE macros do not
29288         collide with FNM macros.
29289         (struct patopts): New struct.
29290         (struct exclude): Use it, as exclude patterns now come with options.
29291         (new_exclude): Support above changes.
29292         (new_exclude, add_exclude_file):
29293         Initial size must now be a power of two to simplify overflow checking.
29294         (free_exclude, fnmatch_no_wildcards): New function.
29295         (excluded_filename): No longer requires options arg, as the options
29296         are determined by add_exclude.  Now returns bool, not int.
29297         (excluded_filename, add_exclude):
29298         Add support for the fancy new exclusion options.
29299         (add_exclude, add_exclude_file): Now takes int options arg.
29300         Check for arithmetic overflow when computing sizes.
29301         (add_exclude_file): xrealloc might modify errno, so don't
29302         realloc until after errno might be used.
29303
29304         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
29305         New macros.
29306         (free_exclude): New decl.
29307         (add_exclude, add_exclude_file): Now takes int options arg.
29308         (excluded_filename): No longer requires options arg, as the options
29309         are determined by add_exclude.  Now returns bool, not int.
29310
29311 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29312
29313         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
29314
29315 2001-08-27  Jim Meyering  <meyering@lucent.com>
29316
29317         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
29318
29319         * lib/version-etc.c (N_): Remove definition.
29320         Revert most of last change.
29321         Instead, simply don't mark the `Copyright...' string for translation.
29322         Based on advice from Paul Eggert.
29323
29324         * lib/strtoxmax.c: Tweak comment.
29325
29326 2001-08-26  Jim Meyering  <meyering@lucent.com>
29327
29328         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
29329
29330         * m4/xstrtoimax.m4: New file.
29331         * m4/xstrtoumax.m4: Add comments explaining why we
29332         AC_REPLACE_FUNCS(strtol).
29333
29334 2001-08-26  Jim Meyering  <meyering@lucent.com>
29335
29336         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
29337         of copyright with `%s' so translators don't get an untranslated
29338         message in 2002.
29339         (COPYRIGHT_YEAR): Define.
29340         (version_etc): Use fprintf rather than fputs.
29341         Suggestion from Ulrich Drepper.
29342
29343         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
29344
29345         * lib/strtoll.c: New file, from GNU libc.
29346         * lib/xstrtoimax.c: New file.
29347
29348         * lib/xstrtol.h: Add xstrtoimax.
29349         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
29350         * lib/strtoimax.c: New file.  Likewise, but first define
29351         STRTOUXMAX_SIGNED.
29352
29353         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
29354         ...
29355         * lib/strtoxmax.c: ... then renamed to this.
29356
29357 2001-08-18  Paul Eggert  <eggert@twinsun.com>
29358
29359         * m4/inttypes.m4: Add AC_PREREQ(2.13).
29360         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
29361         (jm_AC_TYPE_INTMAX_T): New macro.
29362         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
29363
29364         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
29365
29366         * m4/longlong.m4: Renamed from ulonglong.m4.
29367         * m4/inttypes.m4: Renamed from inttypes_h.m4.
29368         * m4/uintmax_t.m4: Removed.
29369
29370 2001-08-13  Paul Eggert  <eggert@twinsun.com>
29371
29372         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
29373         Port to Solaris 8, where 'sed' requires a space after the 'r'
29374         command, and where sh dislikes "$/".  Clean up the spacing a bit.
29375         Redirect output to $tmp just once.
29376
29377 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
29378
29379         * lib/addext.c (<errno.h>): Include.
29380         (errno): Declare if not defined.
29381         (addext): Work correctly when pathconf returns -1 and leaves
29382         errno alone because there is no limit.  Also, work even if
29383         pathconf returns a value greater than SIZE_MAX.
29384
29385 2001-08-12  Jim Meyering  <meyering@lucent.com>
29386
29387         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
29388         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
29389         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
29390         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
29391         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
29392         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
29393         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
29394         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
29395         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
29396         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
29397         utime.m4, utimes.m4, xstrtoumax.m4:
29398         Quote the first argument in each use of AC_DEFUN.
29399
29400 2001-08-12  Jim Meyering  <meyering@lucent.com>
29401
29402         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
29403         Simply `return getcwd (NULL, 0);'.
29404         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29405         Use 1300 as initial value for length, not PATH_MAX.
29406
29407         * lib/pathmax.h: Clean up cpp syntax.
29408
29409 2001-08-12  Jim Meyering  <meyering@lucent.com>
29410
29411         * lib/gettimeofday.c: New file.
29412         * lib/gtod.h: New file.
29413         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29414
29415 2001-08-05  Jim Meyering  <meyering@lucent.com>
29416
29417         * m4/jm-macros.m4: Require autoconf-2.52.
29418
29419 2001-08-04  Jim Meyering  <meyering@lucent.com>
29420
29421         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29422         stmt, to get in sync with glibc.
29423
29424 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29425
29426         The following changes are from gettext 0.10.39 as maintained by
29427         Bruno Haible.
29428
29429         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29430         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29431         with inverted sense.  All uses changed.
29432
29433         * lib/mbswidth.c: Don't include <limits.h>.
29434         Include <stdlib.h> and <string.h> unconditionally.
29435         (iswcntrl, mbsinit, ISCNTRL): New macros.
29436         (mbsnwidth): Use K&R style function declarations.
29437         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29438         can optimize it when MB_CUR_MAX == 1.
29439         The width of control characters is zero, not 1.
29440
29441 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29442
29443         The following changes are from gettext 0.10.39 as maintained by
29444         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29445
29446         * m4/codeset.m4: Upgrade to serial AM1.
29447         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29448         all uses changed.  Quote first arg of AC_DEFUN.
29449         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29450
29451         * m4/iconv.m4: Upgrade to serial AM2.
29452         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29453         Add --with-libconv-prefix.
29454         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29455         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29456         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29457         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29458         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29459
29460         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29461         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29462         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29463         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29464         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29465         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29466         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29467         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29468         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29469
29470         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29471         string.h any more.
29472
29473         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29474         not the default value.
29475
29476         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29477         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29478         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29479         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29480         Also check for iswcntrl, used for wcwidth fallback.
29481         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29482         to Autoconf 2.13.
29483
29484 2001-08-03  Jim Meyering  <meyering@lucent.com>
29485
29486         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29487         as it was in the original.  Reported by Paul Eggert.
29488
29489 2001-07-16  Jim Meyering  <meyering@lucent.com>
29490
29491         * m4/gettimeofday.m4: New file.
29492         Prompted by a report from Bernhard Baehr.
29493
29494 2001-07-15  Jim Meyering  <meyering@lucent.com>
29495
29496         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29497         stuff. Now it's in ../Makefile.cfg.
29498
29499 2001-07-15  Jim Meyering  <meyering@lucent.com>
29500
29501         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29502         (BUILT_SOURCES): Add unlocked-io.h.
29503         (io_functions): Define.
29504         (unlocked-io.h): New rule.
29505         (DISTCLEANFILES): Add unlocked-io.h.
29506         (all-local): Depend on unlocked-io.h, to ensure it is created.
29507
29508         * lib/unlocked-io.hin: New file
29509
29510         * lib/regex.c: Update from glibc.
29511
29512 2001-07-05  Jim Meyering  <meyering@lucent.com>
29513
29514         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29515         recommendation.
29516         (libfetish_a_SOURCES): Put all .h files here instead.
29517         Remove a thus-exposed (better checks in automake) duplicate and
29518         two unnecessary .h files.
29519
29520 2001-07-04  Jim Meyering  <meyering@lucent.com>
29521
29522         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29523         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29524         distcheck failure.
29525
29526 2001-07-02  Jim Meyering  <meyering@lucent.com>
29527
29528         The following changes were prompted by suggestions from Bruno Haible.
29529
29530         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29531         is now generated.
29532         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29533         definition of EXTRA_DIST.
29534         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29535         ensure that the generated file is created/updated whenever the list
29536         of $(unlocked_functions) is changed.
29537         (jm-glibc-io.m4): New rule.
29538         (unlocked-io.h): New rule -- currently unused.
29539
29540 2001-06-24  Jim Meyering  <meyering@lucent.com>
29541
29542         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29543         unmatched right bracket, rather than kludging it with an extra,
29544         falsely-matching quote in a comment.  Patch by Akim Demaille.
29545
29546 2001-06-11  Jim Meyering  <meyering@lucent.com>
29547
29548         * lib/regex.c: Update from GNU libc.
29549
29550 2001-05-27  Jim Meyering  <meyering@lucent.com>
29551
29552         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29553         Check for ut_type in struct utmp.
29554
29555 2001-05-27  Jim Meyering  <meyering@lucent.com>
29556
29557         * lib/readutmp.h (UT_TYPE): Define.
29558
29559 2001-05-24  Jim Meyering  <meyering@lucent.com>
29560
29561         * lib/argmatch.c: Include "quote.h".
29562         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29563         quote function.  Reported by Göran Uddeborg.
29564
29565 2001-05-22  Jim Meyering  <meyering@lucent.com>
29566
29567         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29568         now that we use the package-supplied version unconditionally.
29569         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29570
29571 2001-05-21  Jim Meyering  <meyering@lucent.com>
29572
29573         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29574         shell syntax errors.
29575
29576 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29577
29578         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29579
29580 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29581
29582         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29583         Don't bother to check library strftime, since
29584         we'll be using our own my_strftime function anyway.
29585         Define my_strftime instead of strftime.
29586
29587 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
29588
29589         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
29590         which is not yet declared.
29591
29592 2001-05-15  Jim Meyering  <meyering@lucent.com>
29593
29594         * m4/regex.m4: Use proper quoting so brackets appear in the test
29595         program.
29596         Reported by, and with help from, Bruno Haible.
29597
29598 2001-05-13  Jim Meyering  <meyering@lucent.com>
29599
29600         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
29601         undefined.
29602
29603 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29604
29605         dirname code cleanup.  base_name now behaves more compatibly
29606         with POSIX basename when given file names that have trailing
29607         slashes, and similarly for dir_name.  Add new primitives
29608         base_len and dir_len.  Put the directory-name-related decls
29609         into dirname.h.
29610
29611         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
29612         * lib/backupfile.c (base_name): Likewise.
29613         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
29614         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
29615         * lib/makepath.c (strip_trailing_slashes): Likewise.
29616         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
29617         ISSLASH): Likewise.
29618         * lib/rename.c (strip_trailing_slashes): Likewise.
29619         * lib/same.c (base_name): Likewise.
29620         * lib/stripslash.c (ISSLASH): Likewise.
29621
29622         * lib/addext.c: Include <dirname.h> after size_t is defined.
29623         * lib/backupfile.c: Likewise.
29624
29625         * lib/addext.c (addext): Use base_len to trim redundant
29626         trailing slashes instead of doing it ourselves.
29627         But do not trim the last slash if it is not redundant.
29628
29629         * lib/backupfile.c (find_backup_file_name,
29630         max_backup_version): Use base_len instead of rolling it ourselves.
29631         Handle the case of "" and (on DOS) "C:" correctly.
29632
29633         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
29634         needed. Include <string.h>, <dirname.h>.
29635         (base_name): Allow file names ending in slashes, other than names
29636         that are all slashes.  In this case, return the basename followed
29637         by the slashes.  This is more general, and can be used in places
29638         where the original base_name purposely had an assertion failure.
29639         (base_len): New function.
29640
29641         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
29642         Do not include <assert.h>; no longer needed.
29643         Include xalloc.h.
29644         (memrchr): Remove decl.
29645         (dir_name_r): Remove.
29646         (dir_len): Renamed from dirlen.  All callers changed.
29647         Rewrite in terms of base_name, for simplicity and consistency.
29648         (dir_name): Never return NULL.  All callers changed.
29649         Do not include <stdlib.h> in test program; no longer needed.
29650         return 0; is fine for test program.
29651
29652         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
29653         New macros.
29654         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
29655
29656         * lib/path-concat.c (path_concat): Use base_len to compute
29657         base length, not strlen; this means we cannot rely on memcpy
29658         to null-terminate.
29659
29660         * lib/same.c (STREQ): Remove.
29661         (same_name): Handle the case where the basename ends in trailing '/'.
29662
29663         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
29664         a slash was stripped.  Do not strip the last slash after a
29665         file system prefix.
29666
29667 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29668
29669         * lib/Makefile.am (libfetish_a_SOURCES):
29670         Add strftime.c, since we now compile it on all hosts.
29671
29672         * lib/strftime.c (my_strftime):
29673         Define to nstrftime if emacs, but only if my_strftime is not defined.
29674         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
29675         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
29676         Add one more extra argument: a nanoseconds value.
29677         All uses changed.
29678         (ns): New macro.
29679         (my_strftime function): Add %N format.
29680         (emacs_strftimeu): Renamed from emacs_strftime,
29681         with extra ut argument.
29682
29683 2001-05-09  Paul Eggert  <eggert@twinsun.com>
29684
29685         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
29686
29687 2001-04-21  Jim Meyering  <meyering@lucent.com>
29688
29689         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
29690         doesn't interfere.
29691
29692 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29693
29694         * m4/ftruncate.m4: Check for chsize.
29695         Link with ftruncate.o unconditionally if ftruncate is missing.
29696         This was required when cross-compiling to i586-mingw32msvc.
29697
29698 2001-04-08  Jim Meyering  <meyering@lucent.com>
29699
29700         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
29701         recomputed; that's necessary when the offset spans a DST transition.
29702         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
29703
29704 2001-04-02  Jim Meyering  <meyering@lucent.com>
29705
29706         * lib/regex.h, regex.c: Update from GNU libc.
29707
29708 2001-03-24  Jim Meyering  <meyering@lucent.com>
29709
29710         * m4/jm-macros.m4: Require autoconf-2.49d.
29711
29712 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
29713
29714         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
29715
29716 2001-03-19  Paul Eggert  <eggert@twinsun.com>
29717
29718         * lib/version-etc.c (version_etc_copyright): Update to 2001.
29719
29720 2001-03-17  Jim Meyering  <meyering@lucent.com>
29721
29722         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
29723         now that the version in autoconf is equivalent.
29724         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
29725
29726         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
29727         Suggestion from Akim Demaille.
29728
29729         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
29730         (jm_PREREQ_TEMPNAME): New function.
29731
29732 2001-03-16  Paul Eggert  <eggert@twinsun.com>
29733
29734         * lib/tempname.c (uint64_t): Define to uintmax_t if
29735         not defined, and if UINT64_MAX is not defined.
29736         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
29737         Reported by John David Anglin.
29738
29739 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
29740
29741         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
29742         resolve alias if codeset is empty.
29743         * lib/config.charset (BeOS): Use wildcard syntax.
29744
29745 2001-03-13  Jim Meyering  <meyering@lucent.com>
29746
29747         * lib/path-concat.c (path_concat)
29748         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
29749         concatenating e.g., `C:' and `foo'.
29750         From Bruno Haible.
29751
29752 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29753
29754         * lib/localcharset.c (locale_charset): Don't use
29755         setlocale(LC_CTYPE,NULL). Don't return NULL.
29756         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
29757
29758 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29759
29760         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
29761         support for DOS/DJGPP.
29762
29763 2001-03-01  Paul Eggert  <eggert@twinsun.com>
29764
29765         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
29766         lacks mkstemp.  Compile our own tempname.c if we compile our own
29767         mkstemp.c, as mkstemp relies on tempname.
29768
29769 2001-03-01  Jim Meyering  <meyering@lucent.com>
29770
29771         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
29772         AH_VERBATIM really does output its argument verbatim.
29773
29774 2001-02-28  Paul Eggert  <eggert@twinsun.com>
29775
29776         * lib/Makefile.am (libfetish_a_SOURCES):
29777         Add dup-safer.c, fopen-safer.c.
29778         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
29779
29780         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
29781         * lib/unistd-safer.h: New files.
29782
29783 2001-02-25  Paul Eggert  <eggert@twinsun.com>
29784
29785         The mkstemp replacement is taken from glibc 2.2.2, with some
29786         portability fixes for use outside glibc, as follows:
29787
29788         * lib/tempname.c (struct_stat64): New macro.
29789         (direxists, __gen_tempname): Use it.
29790         This avoids a portability problem with Solaris 8.
29791
29792         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
29793         (<stddef.h>, <stdint.h>, <string.h>):
29794         Include only if STDC_HEADERS || _LIBC.
29795         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
29796         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
29797         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
29798         (__set_errno): Define this macro if <errno.h> doesn't.
29799         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
29800         Define these macros if <stdio.h> doesn't.
29801         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
29802         Define these macros if <sys/stat.h>
29803         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
29804         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
29805         __xstat64): Define if not _LIBC.
29806         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
29807         (__gen_tempname): Invoke gettimeofday only if
29808         HAVE_GETTIMEOFDAY || _LIBC;
29809         otherwise, fall back on plain "time".
29810         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
29811
29812         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
29813
29814         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
29815
29816 2001-02-18  Paul Eggert  <eggert@twinsun.com>
29817
29818         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
29819
29820 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29821
29822         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
29823         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
29824         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
29825         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
29826
29827 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29828
29829         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
29830         Remove workaround macros for hosts that have mbrtowc but not
29831         mbstate_t, as we now insist on proper declarations for both
29832         before using mbrtowc.
29833
29834 2001-02-17  Jim Meyering  <meyering@lucent.com>
29835
29836         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
29837         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
29838         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
29839         UnixWare 7.1.1.
29840
29841         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
29842         rather than AC_CACHE_VAL.
29843
29844 2001-02-17  Jim Meyering  <meyering@lucent.com>
29845
29846         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
29847         around included file name.
29848
29849         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
29850
29851         * lib/strftime.c: Update from GNU libc (the only changes were to
29852         comments).
29853
29854 2001-02-17  Jim Meyering  <meyering@lucent.com>
29855
29856         * lib/regex.c: Update from libc.
29857
29858 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
29859
29860         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
29861         clash.
29862
29863 2001-02-16  Paul Eggert  <eggert@twinsun.com>
29864
29865         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
29866         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
29867         Reported by Mark Hounschell via Paul Eggert.
29868
29869 2001-02-07  Jim Meyering  <meyering@lucent.com>
29870
29871         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
29872
29873 2001-02-05  Jim Meyering  <meyering@lucent.com>
29874
29875         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
29876         it includes the patch required for `large file' support with at least
29877         HP-UX's 10.20 /bin/cc.
29878
29879 2001-02-03  Jim Meyering  <meyering@lucent.com>
29880
29881         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
29882         AS_IF, now that it works once again (mysteriously).
29883         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29884
29885 2001-01-30  Jim Meyering  <meyering@lucent.com>
29886
29887         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
29888         * m4/chown.m4: Rename conftestchown to conftest.chown.
29889         * m4/rename.m4: s/conftestdir/conftest.d1/ and
29890         s/conftestdir2/conftest.d2/.
29891         * m4/utimes.m4: s/conftestdata/conftest.data/
29892         Inspired by Pavel Roskin's change in autoconf.
29893
29894 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
29895
29896         * lib/config.charset: Update for FreeBSD 4.2.
29897
29898 2001-01-27  Jim Meyering  <meyering@lucent.com>
29899
29900         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
29901         a use of AS_IF.
29902         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29903
29904 2001-01-26  Jim Meyering  <meyering@lucent.com>
29905
29906         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
29907         quotearg.c includes it.
29908
29909 2001-01-26  Jim Meyering  <meyering@lucent.com>
29910
29911         * lib/quotearg.c: Include stddef.h.
29912         * lib/quote.c: Include stddef.h.
29913         Reported by Axel Kittenberger.
29914
29915         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
29916         line in double quotes so that it evokes a better diagnostic.
29917         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
29918         Reported by Axel Kittenberger.
29919
29920 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
29921
29922         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
29923         as if it was a `charset'.
29924
29925 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29926
29927         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
29928         has const.
29929
29930 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29931
29932         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
29933         to avoid a warning.  Add back 'const' to inptr.
29934
29935 2001-01-20  Jim Meyering  <meyering@lucent.com>
29936
29937         Be sure that headers are checked before used in code compiled
29938         for the type checks.
29939         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
29940         In place of that, invoke jm_CHECK_ALL_TYPES.
29941         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
29942         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
29943         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
29944         The check for ssize_t was mistakenly run before the test for unistd.h.
29945
29946         The configure-time check for stdbool.h was missing.
29947         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
29948         (jm_PREREQ_HASH): New function.
29949
29950 2001-01-17  Jim Meyering  <meyering@lucent.com>
29951
29952         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
29953         for autoconf-2.49c.
29954         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
29955
29956 2001-01-16  Jim Meyering  <meyering@lucent.com>
29957
29958         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
29959         From Bruno Haible.
29960
29961 2001-01-14  Jim Meyering  <meyering@lucent.com>
29962
29963         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
29964         foo and bar.  Create conftestdir/ in the script, not in the C code.
29965         Remove directories in the script, not in the C code.
29966         Remove conftestdir{,2} before trying to create the directory.
29967         Make the entire configure script fail if the mkdir fails.
29968
29969 2001-01-14  Jim Meyering  <meyering@lucent.com>
29970
29971         * lib/rename.c: New file.  From Volker Borchert.
29972         Include stdlib.h, string.h or strings.h, and xalloc.h.
29973         Use strip_trailing_slashes rather than open-coding it.
29974
29975 2001-01-03  Paul Eggert  <eggert@twinsun.com>
29976
29977         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
29978
29979 2001-01-03  Jim Meyering  <meyering@lucent.com>
29980
29981         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
29982         of local `inptr' to avoid warning with some system declarations of
29983         iconv.
29984
29985 2001-01-02  Volker Borchert  <bt@teknon.de>
29986
29987         * m4/rename.m4: New file.
29988         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
29989
29990 2001-01-01  Jim Meyering  <meyering@lucent.com>
29991
29992         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
29993         even on systems with utmpx.h.  It's necessary for the declaration of
29994         utmp's ut_user member.  Reported by Andreas Jaeger.
29995
29996         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
29997         available. They are required for the declarations of getgrgid and
29998         getpwuid resp.
29999         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
30000         Reported by Andreas Jaeger.
30001
30002 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
30003
30004         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
30005         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
30006         so `make install' also works in VPATH builds.
30007
30008 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
30009
30010         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
30011         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
30012         can be used in subdirectories.
30013
30014 2000-12-29  Paul Eggert  <eggert@twinsun.com>
30015
30016         * lib/modechange.c: Do not assume that mode_t uses the
30017         traditional octal encoding.  E.g. "chmod 1 FOO" should set
30018         the other-execute bit of FOO even if S_IXOTH != 1.
30019
30020         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
30021         WOTH, XOTH, ALLM): New macros.
30022         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
30023          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
30024         Use them.
30025         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
30026         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
30027         (mode_compile):
30028         No need to use uintmax_t; unsigned long is long enough.
30029         Don't bother to get suffix since we don't use it.
30030
30031 2000-12-26  Jim Meyering  <meyering@lucent.com>
30032
30033         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
30034         better with autoheader.
30035
30036 2000-12-24  Jim Meyering  <meyering@lucent.com>
30037
30038         * lib/hash.c (is_prime): Return explicit boolean values.
30039         (hash_get_first): Return NULL to appease Irix5.6's 89.
30040         Reported by Nelson Beebe.
30041
30042 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
30043
30044         * lib/localcharset.c (locale_charset): Add support for Win32.
30045
30046 2000-12-18  Paul Eggert  <eggert@twinsun.com>
30047
30048         * lib/physmem.h, lib/physmem.c: New files.
30049
30050         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
30051         (noinst_HEADERS): Add physmem.h.
30052
30053         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
30054         't' for compatibility with Solaris 8 sort.
30055
30056 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
30057
30058         * lib/config.charset: Add support for BeOS.
30059
30060 2000-12-17  Jim Meyering  <meyering@lucent.com>
30061
30062         * m4/dos.m4 (jm_AC_DOS): New file and macro.
30063         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
30064
30065 2000-12-16  Jim Meyering  <meyering@lucent.com>
30066
30067         This bug had a serious impact on chown: `chown N:M FILE' (for integer
30068         N and M) would have treated it like `chown N:N FILE'.
30069
30070         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
30071
30072 2000-12-16  Jim Meyering  <meyering@lucent.com>
30073
30074         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
30075         SHELLS_FILE to a file name that's useful on djgpp systems.
30076         Include stdlib.h.
30077         (ADDITIONAL_DEFAULT_SHELLS): Define.
30078         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
30079         Based mostly on a patch from Prashant TR.
30080
30081 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
30082
30083         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
30084         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
30085         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
30086
30087 2000-12-08  Andreas Schwab  <schwab@suse.de>
30088
30089         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
30090         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
30091
30092 2000-12-07  Jim Meyering  <meyering@lucent.com>
30093
30094         * lib/stripslash.c (ISSLASH): Define.
30095         (strip_trailing_slashes): Use ISSLASH rather than comparing against
30096         `/'.
30097         From Prashant TR.
30098
30099         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
30100         (dir_name_r): Declare this function as static.
30101         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
30102         manifest itself on a name containing a mix of slashes and
30103         backslashes.
30104         Make this function work with names starting with a DOS-style
30105         drive letter and colon prefix.
30106         (dir_name): Append `.' if necessary.
30107         Based mostly on patches from Prashant TR and Eli Zaretskii.
30108
30109         * lib/dirname.h (dir_name_r): Remove prototype.
30110
30111 2000-12-06  Paul Eggert  <eggert@twinsun.com>
30112
30113         * m4/off_t-format.m4: Remove this file.
30114         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
30115
30116 2000-12-06  Jim Meyering  <meyering@lucent.com>
30117
30118         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
30119         replacement strtoull, we may well need the replacement strtoul, too.
30120         Check for declarations of strtoul and strtoull.
30121         Check for strtol.  Mainly as a cue to cause automake to include
30122         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
30123         Check for limits.h -- strtol.c needs it.
30124
30125 2000-12-05  Jim Meyering  <meyering@lucent.com>
30126
30127         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
30128
30129 2000-12-04  Jim Meyering  <meyering@lucent.com>
30130
30131         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
30132         Also include memory.h, stdlib.h, unistd.h if appropriate.
30133         Reported by Andreas Jaeger (conflicting declaration of malloc).
30134
30135 2000-12-02  Jim Meyering  <meyering@lucent.com>
30136
30137         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
30138         * m4/jm-macros.m4 (jm_MACROS): require it.
30139
30140 2000-12-02  Jim Meyering  <meyering@lucent.com>
30141
30142         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
30143
30144 2000-12-01  Paul Eggert  <eggert@twinsun.com>
30145
30146         * lib/memrchr.c: Include <config.h> before any system include file.
30147
30148 2000-11-30  Jim Meyering  <meyering@lucent.com>
30149
30150         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
30151
30152 2000-11-30  Jim Meyering  <meyering@lucent.com>
30153
30154         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
30155
30156 2000-11-29  Paul Eggert  <eggert@twinsun.com>
30157
30158         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
30159
30160 2000-11-26  Jim Meyering  <meyering@lucent.com>
30161
30162         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
30163
30164 2000-11-22  Paul Eggert  <eggert@twinsun.com>
30165
30166         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
30167         size of (size_t) -1; it's not portable.
30168
30169 2000-11-17  Jim Meyering  <meyering@lucent.com>
30170
30171         * lib/strstr.c: Update from GNU libc.
30172
30173 2000-11-17  Akim Demaille  <akim@epita.fr>
30174
30175         * lib/obstack.h: Formatting changes.
30176         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
30177         prevent type checking.
30178         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
30179         cast the value to (void *): assigning a `foo *' to a `void *'
30180         variable is valid.
30181         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
30182
30183 2000-11-16  Jim Meyering  <meyering@lucent.com>
30184
30185         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
30186
30187 2000-11-11  Jim Meyering  <meyering@lucent.com>
30188
30189         * lib/error.c: Add a couple #includes, merging from GNU libc version.
30190
30191 2000-11-10  Jim Meyering  <meyering@lucent.com>
30192
30193         * lib/obstack.h: Update from GNU libc.
30194         * lib/obstack.c: Likewise.
30195
30196 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
30197
30198         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
30199
30200 2000-11-06  Paul Eggert  <eggert@twinsun.com>
30201
30202         * lib/getusershell.c (setusershell): Use rewind rather than
30203         fseek/fseeko, to avoid configuration hassles with fseeko.
30204         Don't bother opening SHELLS_FILE if shellstream is NULL;
30205         it's not necessary.
30206
30207 2000-11-05  Jim Meyering  <meyering@lucent.com>
30208
30209         * lib/makepath.h (make_dir): Declare.
30210         * lib/makepath.c (make_dir): Remove `static' attribute.
30211         Tweak a comment.
30212
30213 2000-11-04  Jim Meyering  <meyering@lucent.com>
30214
30215         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
30216
30217 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
30218
30219         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
30220         last one in a bucket, advance to the next bucket.
30221
30222 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
30223
30224         * lib/fnmatch.c: Do not comment out all the code if we are using
30225         the GNU C library, because in some cases we are replacing buggy
30226         code in the GNU C library itself.
30227
30228 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
30229
30230         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
30231         (regex_compile): Catch bogus \(\1\).
30232
30233 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30234
30235         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
30236         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
30237         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
30238
30239 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30240
30241         * lib/error.h, getline.h, modechange.h:
30242         Remove "2000" from Copyright line, as the file hasn't been
30243         changed this year other than in the copyright notice.
30244
30245         * lib/xalloc.h: Add "2000" to Copyright line, as this file
30246         was changed this year.
30247
30248 2000-10-29  Jim Meyering  <meyering@lucent.com>
30249
30250         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
30251         renaming.
30252         * m4/ls-mntd-fs.m4: Likewise
30253
30254 2000-10-29  Jim Meyering  <meyering@lucent.com>
30255
30256         * lib/xstat.in: Fix grammar in comment.
30257
30258 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
30259
30260         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
30261         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
30262         doesn't define __restrict_arr.
30263
30264 2000-10-28  Jim Meyering  <meyering@lucent.com>
30265
30266         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
30267         (jm_PREREQ_MEMCHR): New function.
30268
30269 2000-10-28  Jim Meyering  <meyering@lucent.com>
30270
30271         * lib/memchr.c: Update from libc.
30272         Adjust for portability:
30273         [HAVE_STDLIB_H]: Include stdlib.h.
30274         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
30275         Undef __memchr, too.
30276         [!weak_alias]: Define __memchr to memchr.
30277
30278         * lib/regex.c: Update from libc.
30279         * lib/regex.h: Likewise.
30280         * lib/getopt1.c: Likewise.
30281         * lib/memcmp.c: Likewise.
30282
30283         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
30284         Avoid using fseek, when possible -- it's broken by design.
30285         Patch by Ulrich Drepper.
30286
30287 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
30288
30289         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
30290         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
30291         Giving in to popular pressure to shut up the compiler with casts.
30292
30293 2000-10-26  Jim Meyering  <meyering@lucent.com>
30294
30295         * lib/strftime.c: Update from libc.
30296
30297 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
30298
30299         * regex.c: More `unsigned char' -> `re_char' changes.
30300         Also change several `int' into `re_wchar_t'.
30301         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
30302         (PUSH_FAILURE_POINTER): Don't cast any more.
30303         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
30304         We want GCC to complain, since this piece of code makes
30305         re_match non-reentrant, which *should* be fixed.
30306         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
30307         (EXTEND_BUFFER): Use RETALLOC.
30308         (SET_LIST_BIT): Don't cast.
30309         (re_wchar_t): New type.
30310         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
30311         that those two functions will always properly return.
30312         (IMMEDIATE_QUIT_CHECK): Cast to void.
30313         (analyse_first): Use recursion rather than an explicit stack.
30314         (re_compile_fastmap): Can't fail anymore.
30315         (re_search_2): Don't check re_compile_fastmap for failure.
30316         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
30317         Now also sets the new value (passed in a new argument).
30318         (re_match_2_internal): Use it.
30319         Also, use a new var `reg' of type size_t when looping through regs
30320         rather than reuse the inappropriate `mcnt'.
30321
30322 2000-10-25  Jim Meyering  <meyering@lucent.com>
30323
30324         * lib/obstack.c: Update from libc.
30325
30326 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
30327
30328         * regex.c (regex_compile): Change the way of handling a range from
30329         a char less than 256 to a char not less than 256.
30330
30331 2000-10-24  Andrew Innes  <andrewi@gnu.org>
30332
30333         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
30334         NT-Emacs only.
30335         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
30336         so that re_search functions only quit when callers expect them to.
30337
30338 2000-10-23  Jim Meyering  <meyering@lucent.com>
30339
30340         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
30341         wrong.  That set_locale call must not have any side effects.
30342         From Paul Eggert.
30343
30344 2000-10-22  Jim Meyering  <meyering@lucent.com>
30345
30346         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
30347         [CYCLIC]: Remove now-unused definition.
30348
30349         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
30350         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
30351         Suggestion from Ulrich Drepper.
30352
30353 2000-10-21  Jim Meyering  <meyering@lucent.com>
30354
30355         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
30356         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
30357         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
30358
30359 2000-10-21  Jim Meyering  <meyering@lucent.com>
30360
30361         * lib/dirname.c (memrchr): Declare if necessary.
30362         (dir_name): Remove the restriction that there be no
30363         trailing slashes.  Now, this code skips past them, effectively
30364         ignoring them.
30365         [TEST_DIRNAME] (main): New unit tests.
30366
30367         * lib/memrchr.c: New file from GNU libc.
30368         Undef __memrchr, too.
30369         [!weak_alias]: Define __memrchr to memrchr.
30370         Guard weak_alias use with `#ifdef weak_alias'.
30371
30372 2000-10-21  Jim Meyering  <meyering@lucent.com>
30373
30374         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
30375         (dir_name): Use dir_name_r.
30376         * lib/dirname.h (dir_name_r): Declare it.
30377
30378 2000-10-17  Jim Meyering  <meyering@lucent.com>
30379
30380         * lib/quote.h (PARAMS): Define and use.
30381         Reported by Akim Demaille.
30382
30383         * lib/getopt.c: Update from libc.
30384
30385 2000-10-16  Jim Meyering  <meyering@lucent.com>
30386
30387         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
30388         setlocale.
30389         From Jan Fedak.
30390
30391 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
30392
30393         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
30394
30395 2000-09-25  Jim Meyering  <meyering@lucent.com>
30396
30397         * lib/md5.h (rol): Define (from GnuPG).
30398
30399         * lib/sha.c: Give credit (GnuPG) where due.
30400         (M): Use rol rather than open-coding it.
30401         Add a FIXME comment.
30402
30403 2000-09-21  Jim Meyering  <meyering@lucent.com>
30404
30405         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30406         Reported by Michael Stone.
30407
30408 2000-09-20  Jim Meyering  <meyering@lucent.com>
30409
30410         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30411         (noinst_HEADERS): Add sha.h.
30412         Based on code from Scott G. Miller and from GnuPG.
30413
30414 2000-09-18  Jim Meyering  <meyering@lucent.com>
30415
30416         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30417         LIBS. Otherwise, everyone ends up linking with -lelf for some
30418         configurations.
30419         Reported by Mike Stone.
30420
30421 2000-09-15  Jim Meyering  <meyering@lucent.com>
30422
30423         * lib/regex.c: Update from libc.
30424
30425 2000-09-10  Jim Meyering  <meyering@lucent.com>
30426
30427         * lib/getopt.c (_getopt_internal): Update from glibc.
30428
30429 2000-09-09  Jim Meyering  <meyering@lucent.com>
30430
30431         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30432         think it should be used as a general replacement for isascii.
30433         * lib/fnmatch.c: Likewise.
30434         * lib/mbswidth.c: Likewise
30435         * lib/regex.c: Likewise.
30436
30437         Don't use atoi.
30438         * lib/userspec.c: Include sys/param.h and limits.h.
30439         Include xstrtol.h.
30440         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30441         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30442         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30443         UID, GID.  Check range.
30444
30445 2000-09-06  Jim Meyering  <meyering@lucent.com>
30446
30447         * lib/getopt.c (_getopt_internal): Update from glibc.
30448
30449 2000-08-30  Jim Meyering  <meyering@lucent.com>
30450
30451         * lib/strftime.c: Merge in changes from GNU libc.
30452
30453 2000-08-26  Jim Meyering  <meyering@lucent.com>
30454
30455         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30456         * m4/fpending.m4: New file.
30457
30458 2000-08-26  Jim Meyering  <meyering@lucent.com>
30459
30460         * lib/closeout.c: Include "__fpending.h".
30461         (close_stdout_status): Return right away if there's nothing to flush.
30462
30463         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30464         * lib/__fpending.c: New file.
30465         * lib/__fpending.h: New file.
30466
30467 2000-08-20  Jim Meyering  <meyering@lucent.com>
30468
30469         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30470         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30471         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30472
30473 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30474
30475         Improve fileutils installation on systems where running
30476         programs (like install) can't be unlinked.
30477         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30478         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30479
30480 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30481
30482         Standardize on "memory exhausted" instead of "Memory exhausted"
30483         or "virtual memory exhausted".
30484         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30485         "virtual memory exhausted".
30486         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30487         our own message.
30488         * lib/userspec.c (parse_user_spec): Likewise.
30489         * lib/bumpalloc.h: comment fix
30490         * lib/same.c, userspec.c: Include xalloc.h.
30491
30492         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30493         not char *const and pointing to a constant array.
30494         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30495         (xrealloc): Comment fix.
30496
30497         * lib/userspec.c (parse_user_spec):
30498         Don't translate a message until just before returning,
30499         to avoid unnecessary translation.
30500
30501 2000-08-07  Jim Meyering  <meyering@lucent.com>
30502
30503         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30504         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30505         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30506         getgroups.c, gethostname.c, getopt.h, group-member.c,
30507         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30508         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30509         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30510         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30511         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30512         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30513         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30514         yesno.c: Back out Copyright date changes for each file with no change
30515         this year.  This eases coordination with other programs using the same
30516         source code modules.  From Paul Eggert.
30517
30518 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30519
30520         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30521         not char, for compatibility with glibc 2.1.3 strftime.c.
30522
30523 2000-08-03  Greg McGary  <greg@mcgary.org>
30524
30525         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30526         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30527         (EXTEND_BUFFER): Use them.
30528
30529 2000-08-01  Jim Meyering  <meyering@lucent.com>
30530
30531         * lib/dirname.c (ISSLASH): Define.
30532         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30533         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30534         both `\' and `/' may be use as path separators.
30535         Based on a patch from Prashant TR.
30536
30537 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30538
30539         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30540         slot vector a constant, since it might get modified.
30541
30542 2000-07-31  Jim Meyering  <meyering@lucent.com>
30543
30544         * lib/xmalloc.c: Use `virtual memory exhausted', not
30545         `Memory exhausted'.
30546         * lib/obstack.c (print_and_abort): Likewise.
30547
30548 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30549
30550         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30551         buffer, so that the caller can always quote one small
30552         component of a "memory exhausted" message in slot 0.
30553         From a suggestion by Jim Meyering.
30554
30555 2000-07-30  Jim Meyering  <meyering@lucent.com>
30556
30557         * lib/makepath.c (make_path): Quote the other instance, too.
30558
30559         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30560         (STATIC_BUF_SIZE): Define.
30561         (quotearg_n_options): Use only statically allocated storage when
30562         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30563         than STATIC_BUF_SIZE.
30564
30565 2000-07-29  Jim Meyering  <meyering@lucent.com>
30566
30567         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30568         * lib/dirname.c (dir_name): Likewise.
30569
30570         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30571         `/'.
30572
30573         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30574         (dir_name): Assert that there are no trailing slashes.
30575
30576 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30577
30578         * lib/mbswidth.h (mbswidth): Add a flags argument.
30579         (mbswidth): New declaration.
30580         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30581         * lib/mbswidth.c (mbswidth): Add a flags argument.
30582         (mbsnwidth): New function.
30583
30584 2000-07-24  Jim Meyering  <meyering@lucent.com>
30585
30586         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
30587
30588 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30589
30590         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
30591
30592 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30593
30594         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
30595         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
30596         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
30597         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
30598         invoke multibyte primitives.
30599
30600 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30601
30602         * lib/quotearg.c:
30603         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
30604         so that mbstate_t is always defined.
30605
30606         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
30607         be 1 in at least one GCC installation, and this configuration
30608         error is likely to be common.  Ignoring MB_LEN_MAX hurts
30609         performance on hosts that have mbrtowc but have only unibyte
30610         locales, but I assume these hosts are rare.
30611
30612 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30613
30614         * lib/mbswidth.c (_XOPEN_SOURCE):
30615         Don't define; this causes problems on Solaris 7.
30616         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
30617
30618 2000-07-23  Jim Meyering  <meyering@lucent.com>
30619
30620         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
30621         too: getgrgid, getpwuid, getuid.
30622
30623 2000-07-23  Jim Meyering  <meyering@lucent.com>
30624
30625         * lib/basename.c (base_name): Add an assertion.
30626
30627 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
30628
30629         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
30630         shadow its mbsinit function.
30631
30632 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30633
30634         * lib/mbswidth.h: New file.
30635         * lib/mbswidth.c: New file.
30636         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
30637         (noinst_HEADERS): Add mbswidth.h.
30638
30639 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30640
30641         * lib/config.charset: Add support for FreeBSD. Improve support for
30642         HP-UX and IRIX 6.
30643
30644 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
30645
30646         * m4/mbswidth.m4: New file.
30647         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
30648
30649 2000-07-15  Jim Meyering  <meyering@lucent.com>
30650
30651         * lib/makepath.c: Include quote.h.
30652         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
30653         corresponding argument in a `quote (...)' call.
30654         Give better diagnostics.
30655
30656         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
30657         (noinst_HEADERS): Add quote.h.
30658
30659         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
30660         from tar's src/misc.c.
30661         * lib/quote.h: New file.  Prototypes for same.
30662
30663 2000-07-14  Paul Eggert  <eggert@twinsun.com>
30664
30665         From a suggestion by Bruno Haible.
30666         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
30667         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
30668         to decide whether to define the BeOS workaround macro;
30669         this adjusts to the change to AC_MBSTATE_T.
30670
30671 2000-07-14  Jim Meyering  <meyering@lucent.com>
30672
30673         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
30674         jm_AC_TYPE_UINTMAX_T.
30675
30676 2000-07-13  Paul Eggert  <eggert@twinsun.com>
30677
30678         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
30679
30680         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
30681         quotearg_buffer_restyled): Add support for
30682         clocale_quoting_style.  Undo previous change to
30683         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
30684         and "{RIGHT QUOTATION MARK}" msgids.
30685
30686 2000-07-10  Paul Eggert  <eggert@twinsun.com>
30687
30688         From a suggestion by Bruno Haible.
30689         * m4/mbstate_t.m4 (AC_MBSTATE_T):
30690         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
30691         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
30692         and mbstate_t, to a single-part test that simply defines mbstate_t.
30693         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
30694         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
30695
30696 2000-07-10  Jim Meyering  <meyering@lucent.com>
30697
30698         * m4/strerror_r.m4: Mirror the correction made in autoconf.
30699
30700         * m4/gnu-source.m4: Output to confdefs.h directly.
30701         Suggestion from Akim Demaille.
30702
30703 2000-07-09  Paul Eggert  <eggert@twinsun.com>
30704
30705         The old behavior of quoting `like this' doesn't look good with
30706         newer, ISO-style fonts.  See:
30707         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
30708
30709         Instead, quote "like this" by default.  Let the translator
30710         tailor the locale-specific quoting behavior by providing
30711         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
30712
30713         * lib/quotearg.c (N_): New macro.
30714         (gettext_default): New function.
30715         (quotearg_buffer_restyled): Use
30716         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
30717         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
30718
30719 2000-07-09  Jim Meyering  <meyering@lucent.com>
30720
30721         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
30722         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
30723
30724         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
30725         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
30726
30727 2000-07-09  Jim Meyering  <meyering@lucent.com>
30728
30729         * lib/Most files: Update copyright dates to include 2000.
30730
30731 2000-07-08  Jim Meyering  <meyering@lucent.com>
30732
30733         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
30734         if not defined.
30735         (xgethostname): Remove now-unnecessary #ifdef.
30736         Move declaration of `err' into loop where it's used.
30737
30738 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30739         and Bruno Haible  <haible@clisp.cons.org>
30740
30741         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
30742         only if the test for an object-type mbstate_t fails.  This
30743         prevents us from mistakenly reporting that mbstate_t is a
30744         system object type after we "#define mbstate_t int" to work
30745         around its lack.
30746
30747 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30748         and Bruno Haible  <haible@clisp.cons.org>
30749
30750         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
30751
30752 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30753
30754         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
30755         to strerror_r.
30756         Include <ctype.h> for use of isalpha.
30757
30758 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30759
30760         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
30761         by allocating a larger buffer. Test the gethostname return value for
30762         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
30763         returns an error and ENAMETOOLONG isn't defined.
30764
30765 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30766
30767         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
30768         dimension.
30769
30770 2000-07-04  Jim Meyering  <meyering@lucent.com>
30771
30772         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
30773         of the deprecated AC_CHECKING.
30774
30775 2000-07-04  Jim Meyering  <meyering@lucent.com>
30776
30777         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
30778         Reported by Bruno Haible.
30779
30780 2000-07-04  Jim Meyering  <meyering@lucent.com>
30781
30782         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
30783         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
30784         lacks mbrtowc.
30785
30786 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30787
30788         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
30789         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
30790
30791 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30792         and Bruno Haible  <haible@clisp.cons.org>
30793
30794         * lib/quotearg.c (mbrtowc):
30795         Assign to *pwc, and return 1 only if result is nonzero.
30796         (iswprint): Use ISPRINT when substituting our own mbrtowc.
30797
30798 2000-07-03  Jim Meyering  <meyering@lucent.com>
30799
30800         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
30801
30802 2000-07-03  Jim Meyering  <meyering@lucent.com>
30803
30804         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
30805         This is necessary to get a definition of e.g., UTMP_FILE on
30806         HP-UX 10.20.
30807         From Bob Proulx.
30808
30809 2000-07-02  Jim Meyering  <meyering@lucent.com>
30810
30811         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
30812
30813         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
30814         AC_LIBOBJ(function_name).
30815         * m4/chown.m4: Likewise.
30816         * m4/fnmatch.m4: Likewise.
30817         * m4/ftruncate.m4: Likewise.
30818         * m4/getgroups.m4: Likewise.
30819         * m4/getline.m4: Likewise.
30820         * m4/group-member.m4: Likewise.
30821         * m4/jm-macros.m4: Likewise.
30822         * m4/lstat.m4: Likewise.
30823         * m4/malloc.m4: Likewise.
30824         * m4/memcmp.m4: Likewise.
30825         * m4/nanosleep.m4: Likewise.
30826         * m4/putenv.m4: Likewise.
30827         * m4/realloc.m4: Likewise.
30828         * m4/regex.m4: Likewise.
30829         * m4/stat.m4: Likewise.
30830         * m4/strftime.m4: Likewise.
30831
30832 2000-07-02  Jim Meyering  <meyering@lucent.com>
30833
30834         * lib/quotearg.c (mbstate_t): Don't define here.
30835
30836 2000-07-02  Jim Meyering  <meyering@lucent.com>
30837
30838         * lib/nanosleep.c (SIGCONT): Define if not already defined.
30839
30840 2000-07-01  Jim Meyering  <meyering@lucent.com>
30841
30842         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
30843
30844 2000-07-01  Jim Meyering  <meyering@lucent.com>
30845
30846         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
30847         problem.
30848
30849 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30850
30851         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
30852         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
30853
30854 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30855
30856         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
30857         per change in ../m4/ls-mntd-fs.m4.
30858         (read_filesystem_list): Ignore symbolic links.
30859
30860 2000-06-29  Jim Meyering  <meyering@lucent.com>
30861
30862         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
30863         for declaration of strcmp.
30864
30865         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
30866
30867         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
30868         Avoid warning by casting result to `char *' to remove `const'.
30869
30870 2000-06-28  Jim Meyering  <meyering@lucent.com>
30871
30872         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
30873         included by quotearg.c, for which we perform this test.  From
30874         Bruno Haible.
30875
30876 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30877
30878         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
30879         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
30880         <utmpx.h> exists, put readutmp.o into LIBOBJS.
30881
30882 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30883
30884         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
30885
30886 2000-06-26  Paul Eggert  <eggert@twinsun.com>
30887
30888         savedir now sets errno on failure and invokes xmalloc to get memory.
30889         Fix a couple of other minor bugs while we're at it.
30890
30891         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
30892         (NAMLEN): Remove macro.
30893         (malloc, realloc): Remove decls.
30894         (stpcpy): Likewise.
30895         ("xalloc.h"): Include.
30896         (NAME_SIZE_DEFAULT): New macro.
30897         (savedir): Use xmalloc / xrealloc to allocate memory.
30898         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
30899         Skip "" directory entries.
30900         Use strlen to calculate directory entry length, since the old method
30901         is rarely used these days and isn't worth supporting.
30902         Don't use a pointer after freeing it.
30903         Check for integer overflow when calculating allocation size.
30904         Use memcpy to copy entries, instead of stpcpy.
30905         Set errno properly when returning NULL.
30906         Check for readdir error.
30907
30908 2000-06-26  Jim Meyering  <meyering@lucent.com>
30909
30910         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
30911
30912 2000-06-25  Jim Meyering  <meyering@lucent.com>
30913
30914         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
30915         Linux header bug when _XOPEN_SOURCE is defined to 500.
30916
30917 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30918
30919         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
30920         deficiency.
30921
30922 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30923
30924         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
30925         Include xalloc.h.
30926         Don't include <stdlib.h>.  Don't declare malloc, realloc.
30927
30928 2000-06-24  Jim Meyering  <meyering@lucent.com>
30929
30930         * m4/strerror_r.m4: Revive this file -- to try out an experimental
30931         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
30932         for which strerror does return char*, but which lacks a conveniently
30933         accessible declaration of the function.  If the compile-test says
30934         strerror_r doesn't work, then resort to a `run'-test that works on
30935         BeOS and segfaults on DEC Unix.
30936
30937 2000-06-24  Jim Meyering  <meyering@lucent.com>
30938
30939         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
30940
30941 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30942
30943         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
30944         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
30945
30946 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30947
30948         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
30949         (mbrtowc, mbstate_t): Define substitutes if
30950         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
30951         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
30952         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
30953
30954 2000-06-23  Jim Meyering  <meyering@lucent.com>
30955
30956         * m4/afs.m4: Add missing AC_MSG_RESULT.
30957         Reported by Bruno Haible.
30958
30959         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
30960         Suggestion from Bruno Haible.
30961
30962 2000-06-23  Jim Meyering  <meyering@lucent.com>
30963
30964         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
30965
30966 2000-06-21  Jim Meyering  <meyering@lucent.com>
30967
30968         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
30969
30970 2000-06-21  Jim Meyering  <meyering@lucent.com>
30971
30972         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
30973         (noinst_HEADERS): Add getstr.h.
30974
30975         * lib/getline.c (getstr): Move into a separate file.
30976         * lib/getstr.c (getstr): New file, extracted from getline.c, with
30977         the following changes: new parameter, delim2; both delim[12]
30978         parameters have type `int', not `char'.  The latter would lose
30979         with 8-bit delimiters.
30980         * lib/getstr.h: New file.
30981
30982 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30983
30984         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
30985         than 1024, return a memory chunk of least possible size, instead
30986         of size PATH_MAX + 2. In the loop, increment the size proportionally.
30987         Use free/xmalloc instead of xrealloc to avoid copying for very long
30988         paths.
30989
30990 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30991
30992         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
30993         the empty string.
30994
30995 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30996
30997         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
30998         address, not strdup.  Include <stdlib.h> and don't declare free().
30999
31000 2000-06-19  Jim Meyering  <meyering@lucent.com>
31001
31002         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
31003
31004 2000-06-18  Jim Meyering  <meyering@lucent.com>
31005
31006         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
31007
31008         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
31009         `checking whether...' message to be consistent with that of the
31010         lstat test.
31011
31012 2000-06-18  Jim Meyering  <meyering@lucent.com>
31013
31014         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
31015         Besides, these days every porting target provides a mkdir function.
31016
31017         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
31018         needed. (this snippet comes from src/system.h).
31019
31020 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
31021
31022         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
31023
31024 2000-06-15  Paul Eggert  <eggert@twinsun.com>
31025
31026         * lib/human.c (adjust_value): New function.
31027         (human_readable_inexact): Apply rounding style even when
31028         printing approximate values.
31029
31030 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31031
31032         * lib/human.c (human_readable_inexact): Allow an input block
31033         size that is not a multiple of the output block size, and vice versa.
31034         Reported by Piergiorgio Sartor.
31035
31036 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31037
31038         * lib/getdate.y (get_date): Apply relative times after time
31039         zone indicator, not before.  Reported by Todd A. Jacobs.
31040
31041 2000-06-13  Jim Meyering  <meyering@lucent.com>
31042
31043         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
31044
31045         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
31046
31047 2000-06-12  Paul Eggert  <eggert@twinsun.com>
31048
31049         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
31050
31051 2000-06-12  Jim Meyering  <meyering@lucent.com>
31052
31053         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
31054         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
31055         optional argument.
31056         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
31057         the optional argument, `lib'.
31058
31059 2000-06-08  Jim Meyering  <meyering@lucent.com>
31060
31061         * m4/largefile.m4: Remove file (now that it's part of autoconf).
31062
31063 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31064
31065         Rewrite largefile configuration so that we don't need to run
31066         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
31067         AC_CANONICAL_HOST in configure.in -- jmm]
31068
31069         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
31070         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
31071         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
31072         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
31073         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
31074         All uses changed.
31075         Instead of inspecting the output of getconf, try to compile the
31076         test program without and with the macro definition.
31077         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
31078         for getconf.  Instead, check for the needed flags by compiling
31079         test programs.
31080
31081 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31082
31083         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
31084
31085 2000-06-04  Jim Meyering  <meyering@lucent.com>
31086
31087         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
31088         SunOS 4.1.4 for which gid_t is an unsigned type.
31089
31090 2000-06-03  Jim Meyering  <meyering@lucent.com>
31091
31092         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
31093         now that autoconf requires that.
31094
31095         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
31096         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
31097         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
31098
31099 2000-06-03  Jim Meyering  <meyering@lucent.com>
31100
31101         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
31102
31103 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31104
31105         * m4/glibc21.m4: New file.
31106         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
31107
31108 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31109
31110         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
31111         newer, don't install charset.alias.
31112         * lib/config.charset: Change the Linux/glibc rules so they become empty
31113         on glibc-2.1 or newer.
31114
31115 2000-06-02  Jim Meyering  <meyering@lucent.com>
31116
31117         * lib/mountlist.c: Back out last change.  Instead, do this...
31118         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
31119         me_dummy member using the same `ignore'-testing code.
31120         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
31121         fs_type strings.
31122         From Mark D. Roth.
31123
31124 2000-05-29  Jim Meyering  <meyering@lucent.com>
31125
31126         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
31127         mounts with the `ignore' attribute.  Based on a patch from
31128         Mark D. Roth.
31129
31130 2000-05-28  Jim Meyering  <meyering@lucent.com>
31131
31132         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
31133         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31134         * m4/stat.m4: Likewise.
31135         * m4/lstat.m4: Likewise.
31136         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
31137
31138         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
31139         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
31140
31141 2000-05-26  Jim Meyering  <meyering@lucent.com>
31142
31143         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
31144
31145 2000-05-24  Jim Meyering  <meyering@lucent.com>
31146
31147         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
31148         autoconf requires that.
31149         * m4/lib-check.m4: Likewise.
31150         * m4/jm-macros.m4: Likewise.
31151         * m4/strftime.m4: Likewise.
31152
31153         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
31154         AC_CHECK_DECLS, now that autoconf requires that.
31155
31156 2000-05-22  Jim Meyering  <meyering@lucent.com>
31157
31158         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31159         * m4/lstat.m4: Likewise.
31160
31161 2000-05-22  Jim Meyering  <meyering@lucent.com>
31162
31163         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
31164
31165 2000-05-20  Jim Meyering  <meyering@lucent.com>
31166
31167         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
31168         (jm_PREREQ): Use it.
31169
31170 2000-05-18  Jim Meyering  <meyering@lucent.com>
31171
31172         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
31173         back, too, since it may have been modified by allocate_entry.
31174         (hash_delete): Rewrite to use neither the assignment operator
31175         nor the comma operator in an if-expression.
31176
31177 2000-05-15  Paul Eggert  <eggert@twinsun.com>
31178
31179         * lib/closeout.c:
31180         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
31181         Remove; no longer needed.
31182         "quotearg.h": Add include.
31183         (file_name): Do not bother to explicitly initialize to NULL; it's less
31184         efficient on some hosts.
31185         (close_stdout_status): Remove test as to whether stdout was already
31186         closed; it breaks for the case "echo x | sort >&-".
31187         Quote file name colons.
31188         Do not assume that _("write error") lacks format strings.
31189
31190 2000-05-15  Jim Meyering  <meyering@lucent.com>
31191
31192         * lib/version-etc.c (version_etc_copyright): Update the copyright
31193         string used in all --version output.
31194
31195 2000-05-14  Jim Meyering  <meyering@lucent.com>
31196
31197         * lib/closeout.c (close_stdout_set_file_name): New function.
31198         (close_stdout_status): Use new file-scoped global.
31199         Return right away if fstat says the stdout file descriptor is invalid.
31200         * lib/closeout.h (close_stdout_set_file_name): Declare.
31201
31202 2000-05-10  Jim Meyering  <meyering@lucent.com>
31203
31204         * lib/closeout.c [default_exit_status]: New file-scoped variable.
31205         (close_stdout_set_status): New function.
31206         * lib/closeout.h (close_stdout_set_status): Declare.
31207
31208 2000-05-09  Jim Meyering  <meyering@lucent.com>
31209
31210         * m4/gettext.m4: Rename this...
31211         * m4/libintl.m4: ...to this.
31212
31213 2000-05-08  Jim Meyering  <meyering@lucent.com>
31214
31215         * lib/long-options.c: Don't include closeout.h.
31216         (parse_long_options): Don't call close_stdout for --version.
31217
31218 2000-05-06  Paul Eggert  <eggert@twinsun.com>
31219
31220         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
31221         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
31222         2.1.3 bug.  This avoids a clash when files like regex.c define
31223         _GNU_SOURCE.
31224
31225 2000-05-06  Jim Meyering  <meyering@lucent.com>
31226
31227         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
31228         (AC_REPLACE_FUNCS): Add strnlen.
31229
31230         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
31231         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
31232
31233         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
31234         AC_SEARCH_LIBS call for nanosleep.
31235         (LIB_NANOSLEEP): Set and AC_SUBST.
31236
31237 2000-05-06  Jim Meyering  <meyering@lucent.com>
31238
31239         * lib/strnlen.c: Undefine __strnlen and strnlen.
31240         [!weak_alias]: Define __strnlen to strnlen.
31241
31242         * lib/atexit.c: New file, from libiberty.
31243
31244 2000-05-06  Jim Meyering  <meyering@lucent.com>
31245
31246         * lib/closeout.c (close_stdout_status): Also check for errors on the
31247         stderr stream.
31248
31249 2000-05-05  Jim Meyering  <meyering@lucent.com>
31250
31251         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
31252         AC_SEARCH_LIBS call for clock_gettime.
31253         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
31254
31255         * m4/search-libs.m4: Update from autoconf.
31256
31257         su doesn't work on Solaris 2.6.
31258         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
31259         <shadow.h>.  Reported by Dragos Harabor.
31260
31261 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
31262
31263         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
31264         memcpy instead of xmalloc, xrealloc, path_concat.
31265         (locale_charset): Treat empty environment variables as absent.
31266         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
31267
31268 2000-05-04  Jim Meyering  <meyering@lucent.com>
31269
31270         * lib/getopt.c: Update from glibc.
31271         * lib/obstack.c: Likewise.
31272         * lib/obstack.h: Likewise.
31273         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
31274         file
31275
31276         * lib/regex.h: Likewise.
31277         * lib/strndup.c: Likewise.
31278         * lib/strnlen.c: New file, from glibc.
31279
31280 2000-05-03  Jim Meyering  <meyering@lucent.com>
31281
31282         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
31283
31284 2000-05-02  Paul Eggert  <eggert@twinsun.com>
31285
31286         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
31287         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
31288         compile-time test, rather than inspecting host and OS, to
31289         decide whether to define _LARGEFILE_SOURCE.
31290
31291 2000-05-01  Jim Meyering  <meyering@lucent.com>
31292
31293         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
31294
31295         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
31296         Based on a patch from Bruno Haible.
31297
31298 2000-05-01  Jim Meyering  <meyering@lucent.com>
31299
31300         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
31301
31302 2000-04-29  Jim Meyering  <meyering@lucent.com>
31303
31304         * lib/path-concat.c: Declare strdup only if it's not defined.
31305         * lib/canon-host.c: Likewise.
31306
31307 2000-04-28  Jim Meyering  <meyering@lucent.com>
31308
31309         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
31310         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
31311         is included first, then limits.h is included by locale.h by libintl.h.
31312         From John David Anglin.
31313
31314 2000-04-25  Jim Meyering  <meyering@lucent.com>
31315
31316         * lib/makepath.c (S_IRWXUGO): Define.
31317         (make_path): Always perform explicit chmod if MODE specifies any
31318         of the `special' permission bits.  Prompted by a bug report against
31319         install from Mate Wierdl and Joost van Baal.
31320
31321 2000-04-18  Jim Meyering  <meyering@lucent.com>
31322
31323         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
31324         (jm_PREREQ): Use it.
31325
31326 2000-04-18  Jim Meyering  <meyering@lucent.com>
31327
31328         * lib/README: New file.
31329
31330         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
31331         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
31332
31333 2000-04-17  Jim Meyering  <meyering@lucent.com>
31334
31335         Get it right :-)
31336         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
31337         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
31338         Suggestion from Akim Demaille.
31339
31340 2000-04-17  Jim Meyering  <meyering@lucent.com>
31341
31342         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
31343         the definition of it to rpl_strftime also defined-away the system's
31344         declaration.
31345
31346 2000-04-15  Jim Meyering  <meyering@lucent.com>
31347
31348         Use `C' to denote so-called `contiguous' files, the same way
31349         that tar does.
31350         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
31351         (ftypelet): Use S_ISCTG.
31352         From Michael Deutschmann.
31353
31354 2000-04-14  Jim Meyering  <meyering@lucent.com>
31355
31356         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
31357         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
31358         clobbered.
31359
31360 2000-04-14  Jim Meyering  <meyering@lucent.com>
31361
31362         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
31363
31364 2000-04-13  Jim Meyering  <meyering@lucent.com>
31365
31366         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
31367         AH_VERBATIM to insert required #ifndef into config.h.in.
31368         Suggestion from Akim Demaille.
31369
31370 2000-04-12  Jim Meyering  <meyering@lucent.com>
31371
31372         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
31373         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
31374         Christian Krackowizer.
31375
31376         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
31377         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
31378         (AC_SYS_LARGEFILE): Require.
31379         (AM_C_PROTOTYPES): Require.
31380
31381 2000-04-08  Jim Meyering  <meyering@lucent.com>
31382
31383         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
31384         names don't conflict.  Reported by Eli Zaretskii.
31385
31386 2000-04-07  Jim Meyering  <meyering@lucent.com>
31387
31388         * lib/putenv.c: Move inclusion of errno.h so it follows that of
31389         sys/types.h, to work around system header problems on AIX 3.2.5.
31390         From Bruno Haible.
31391
31392 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
31393
31394         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
31395         bug.  Deal with the different error behavior of Irix iconv.
31396
31397 2000-04-05  Paul Eggert  <eggert@twinsun.com>
31398
31399         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
31400         IRIX if the installer said otherwise.
31401
31402 2000-04-05  Jim Meyering  <meyering@lucent.com>
31403
31404         Portability tweaks required for ultrix4.3.
31405         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31406         (jm_CHECK_DECLS): Add getutent to the list of functions.
31407         (_jm_DECL_HEADERS): Add utmpx.h.
31408         From John David Anglin.
31409
31410         * m4/strftime.m4: Back out the 2000-04-02 change.
31411         Instead of that change, simply undefine putenv in the test program.
31412
31413 2000-04-05  Jim Meyering  <meyering@lucent.com>
31414
31415         Portability tweaks required for ultrix4.3.
31416         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31417         getutent.
31418         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31419         * lib/canon-host.c: Declare strdup.
31420         * lib/path-concat.c: Likewise.
31421         From John David Anglin.
31422
31423 2000-04-04  Jim Meyering  <meyering@lucent.com>
31424
31425         Be more DOS 8.3-friendly.
31426         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31427         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31428         * lib/Makefile.am: Reflect renaming.
31429         Reported by Eli Zaretskii.
31430
31431         Use a temporary file name that won't clash with `charset.alias'
31432         in the DOS 8.3 name space.
31433         * lib/Makefile.am (charset_tmp): Define.
31434         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31435         (uninstall-local): Likewise.
31436         Reported by Eli Zaretskii.
31437
31438 2000-04-03  Jim Meyering  <meyering@lucent.com>
31439
31440         * m4/gettext.m4: Fix typo in comment.
31441
31442         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31443         textutils/configure.in).  Suggestion from Paul Eggert.
31444         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31445
31446 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31447
31448         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31449         variable in the shell rather than using putenv, which isn't
31450         portable.  This avoids the configure-time inter-test dependency
31451         on the potentially-renamed putenv function.
31452
31453 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31454
31455         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31456         before checking struct stat.st_blksize, so that
31457         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31458
31459 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31460
31461         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31462         since strftime.c uses HAVE_STRFTIME to decide whether to use
31463         the underlying strftime.
31464
31465 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31466
31467         * lib/time/strftime.c (my_strftime): Make sure we call the system
31468         strftime, not ourselves, when invoking the underlying strftime.
31469
31470 2000-03-24  Jim Meyering  <meyering@lucent.com>
31471
31472         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31473         (charset_alias): Define.
31474         (install-exec-local): Factor out common code.
31475         (uninstall-local): Split lines longer than 80.
31476         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31477         (SUFFIXES): Define.
31478         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31479         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31480
31481 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31482
31483         * lib/config.charset: Output a line containing "Packages using this
31484         file".
31485         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31486         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31487         ref-del.sed): New rules.
31488
31489 2000-03-17  Jim Meyering  <meyering@lucent.com>
31490
31491         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31492         Otherwise, include <strings.h>
31493
31494 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31495
31496         * lib/unicodeio.c (utf8_wctomb): New function.
31497         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31498         format instead of in UCS-4 with platform dependent endianness.
31499
31500 2000-03-10  Jim Meyering  <meyering@lucent.com>
31501
31502         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31503         From Marco Franzen.
31504
31505 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31506
31507         * lib/savedir.c (savedir): Work even if directory size is
31508         negative; this can happen with some screwy NFS configurations.
31509
31510 2000-03-06  Jim Meyering  <meyering@lucent.com>
31511
31512         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31513         if it's NULL (because we ran out of memory).  From Bruno Haible.
31514
31515 2000-03-05  Jim Meyering  <meyering@lucent.com>
31516
31517         * lib/localcharset.c ("path-concat.h"): Include.
31518         (get_charset_aliases): Use path_concat instead of ANSI string
31519         concatenation.
31520
31521         * lib/unicodeio.h (PARAMS): Define.
31522         Use it to guard prototype.
31523
31524 2000-03-04  Jim Meyering  <meyering@lucent.com>
31525
31526         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31527         for lib/localcharset.c.
31528
31529 2000-03-04  Jim Meyering  <meyering@lucent.com>
31530
31531         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31532         installing into it.
31533         (uninstall-local): Uncomment this rule so `make distcheck' works
31534         once again.
31535
31536         * lib/unicodeio.c (<errno.h>): Include it.
31537         (errno): Declare if not defined.
31538
31539         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31540
31541         * lib/config.charset: New version, incorporating remarks from a linux
31542         i18n mailing list.  From Bruno Haible.
31543
31544 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31545
31546         * m4/codeset.m4: New file.
31547         * m4/iconv.m4: New file.
31548         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31549
31550 2000-03-03  Jim Meyering  <meyering@lucent.com>
31551
31552         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31553
31554 2000-03-02  Jim Meyering  <meyering@lucent.com>
31555
31556         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31557         the messages come out on separate lines.
31558
31559         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31560         rather than jm_CHECK_DECLARATIONS.
31561         * m4/decl.m4: Remove now-unused file.
31562
31563         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31564         geteuid.
31565
31566 2000-03-02  Jim Meyering  <meyering@lucent.com>
31567
31568         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31569
31570 2000-03-01  Jim Meyering  <meyering@lucent.com>
31571
31572         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31573         * lib/unicodeio.c: Likewise.
31574
31575 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31576
31577         * lib/config.charset: New file.
31578         * lib/localcharset.c: New file.
31579         * lib/unicodeio.h, lib/unicodeio.c: New files.
31580         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31581         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31582         (noinst_HEADERS): Add unicodeio.h.
31583         (all-local, install-exec-local, charset.alias): New targets.
31584
31585 2000-02-28  Paul Eggert  <eggert@twinsun.com>
31586
31587         * lib/quotearg.c (ALERT_CHAR): New macro.
31588         (quotearg_buffer_restyled): Use it.
31589
31590 2000-02-27  Jim Meyering  <meyering@lucent.com>
31591
31592         * m4/check-decl.m4: Add getenv to the list.
31593
31594 2000-02-27  Jim Meyering  <meyering@lucent.com>
31595
31596         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
31597         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
31598
31599         * lib/backupfile.c: Guard inclusion of stdlib.h with
31600         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
31601         Declare malloc if needed.
31602
31603         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
31604         `#ifndef HAVE_DECL..'
31605         now that autoconf always defines the HAVE_DECL_ symbols.
31606         * lib/human.c: Likewise.
31607         * lib/same.c: Likewise.
31608         * lib/strtoumax.c: Likewise.
31609
31610         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
31611         declaration check was not run.
31612         * lib/hash.c: Likewise.
31613         * lib/human.c: Likewise.
31614         * lib/same.c: Likewise.
31615         * lib/strtoumax.c: Likewise.
31616
31617         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
31618         `.', then first look up the entire `.'-containing string as a login
31619         name.
31620
31621 2000-02-23  Jim Meyering  <meyering@lucent.com>
31622
31623         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
31624         in place of my hack.
31625
31626 2000-02-18  Paul Eggert  <eggert@twinsun.com>
31627
31628         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
31629         (textint): New typedef.
31630         (parser_control): Member year changed from int to textint.
31631         All uses changed.
31632         (YYSTYPE): Removed; replaced by %union with int and textint members.
31633         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
31634         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
31635         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
31636         (tSNUMBER, tUNUMBER): Now of type <textintval>.
31637         (date, number, to_year): Use width of number in digits, not its value,
31638         to determine whether it's a 2-digit year, or a 2-digit time.
31639         (yylex): Store number of digits of numeric tokens.
31640         Reported by John Kendall.
31641
31642         (parser_control): Changed from struct parser_control to typedef (for
31643         consistency).  All uses changed.
31644
31645         (tID): Removed; not used.
31646         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
31647
31648 2000-02-14  Paul Eggert  <eggert@twinsun.com>
31649
31650         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
31651         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
31652
31653 2000-02-12  Jim Meyering  <meyering@lucent.com>
31654
31655         * lib/userspec.c (ISDIGIT): Define it.
31656         (isdigit): Remove definition.
31657         (is_number): Use ISDIGIT, not isdigit.
31658         <libintl.h>: Include.
31659         (_ and N_): Define.
31660         (parse_user_spec): Mark translatable strings.
31661
31662 2000-02-10  Jim Meyering  <meyering@lucent.com>
31663
31664         With these changes, nanosleep.[ch] are finally enough like the other
31665         lib/* replacement files to compile on a few more losing systems.
31666
31667         * lib/nanosleep.h: Don't include config.h.
31668         Remove prototype from declaration of nanosleep.
31669         (PARAMS): Remove now-unneeded definition.
31670         * lib/nanosleep.c: #undef nanosleep.
31671         (rpl_nanosleep): Rename from nanosleep.
31672
31673 2000-02-10  Jim Meyering  <meyering@lucent.com>
31674
31675         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
31676         gnu_nanosleep to rpl_nanosleep.
31677
31678 2000-02-09  Jim Meyering  <meyering@lucent.com>
31679
31680         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
31681         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
31682
31683 2000-02-08  Akim Demaille  <akim@epita.fr>
31684
31685         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
31686         `[' and `]' and remove uses of `changequote'.
31687         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
31688         (AC_SYS_LARGEFILE): Likewise.
31689         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
31690         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
31691         of changequote.
31692         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
31693         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
31694         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
31695         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
31696
31697 2000-02-05  Jim Meyering  <meyering@lucent.com>
31698
31699         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
31700         Remove explicit use of AC_HEADER_TIME.  It is required by
31701         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
31702         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
31703         in autoconf whereby the expansion of the latter ended up preceding
31704         the expansion of its prerequisite, AC_HEADER_TIME.
31705         Reported by Volker Borchert.
31706
31707 2000-02-03  Jim Meyering  <meyering@lucent.com>
31708
31709         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
31710
31711 2000-02-03  Jim Meyering  <meyering@lucent.com>
31712
31713         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
31714         rather than with `#if HAVE_UTMPNAME'.
31715
31716 2000-02-02  Jim Meyering  <meyering@lucent.com>
31717
31718         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
31719         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
31720         Reported by Eli Zaretskii.
31721
31722 2000-02-01  Jim Meyering  <meyering@lucent.com>
31723
31724         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
31725
31726 2000-01-31  Jim Meyering  <meyering@lucent.com>
31727
31728         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
31729         functions.  Add the time.h and sys/time.h headers along with the
31730         AC_REQUIRE'ment of AC_HEADER_TIME.
31731
31732 2000-01-31  Jim Meyering  <meyering@lucent.com>
31733
31734         * lib/nanosleep.h (nanosleep): Guard declaration with
31735         `#if ! HAVE_DECL_NANOSLEEP'.
31736         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
31737         the declaration in that vendor's sys/timers.h.
31738         Reported by Christian Krackowizer.
31739
31740         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
31741         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
31742         (ISPRINT): Likewise.
31743         Reported by Tom Tromey.
31744
31745 2000-01-30  Jim Meyering  <meyering@lucent.com>
31746
31747         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
31748
31749         * m4/prereq.m4 (utmp_includes): Define.
31750         Check for ut_user and ut_name members in both struct utmpx
31751         and struct utmp.
31752
31753 2000-01-30  Jim Meyering  <meyering@lucent.com>
31754
31755         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
31756         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
31757         header files where only utmpx.ut_user is declared.
31758
31759         * lib/readutmp.h (UT_USER): Define.
31760
31761 2000-01-29  Jim Meyering  <meyering@lucent.com>
31762
31763         * m4/lib-check.m4: New file containing library-related checks from
31764         fileutils and sh-utils (textutils had none).
31765
31766 2000-01-28  Jim Meyering  <meyering@lucent.com>
31767
31768         * m4/perl.m4: Change format of warning message to look more like that
31769         from the missing script.  Suggestion from François Pinard.
31770
31771 2000-01-25  Jim Meyering  <meyering@lucent.com>
31772
31773         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
31774         well as time.h in the compile check.
31775         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
31776         Fix typo in cross-compiling case: s/yes/no/.
31777
31778 2000-01-23  Jim Meyering  <meyering@lucent.com>
31779
31780         * m4/jm-macros.m4: Move df-related tests here from
31781         fileutils/configure.in
31782
31783         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
31784         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
31785
31786         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
31787         s/space/ac_fsusage_space/.
31788         (jm_FILE_SYSTEM_USAGE): Take two parameters.
31789
31790         * m4/ftruncate.m4: New file (derived from part of
31791         fileutils/configure.in).
31792         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
31793         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
31794
31795         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
31796         AC_SUBST these here, rather than just in sh-util/configure.in, so
31797         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
31798         all the same.
31799         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
31800         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
31801         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
31802         (AC_SUBST(POW_LIBM)): Likewise.
31803         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
31804
31805 2000-01-23  Jim Meyering  <meyering@lucent.com>
31806
31807         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
31808         obstack.c.
31809
31810 2000-01-22  Jim Meyering  <meyering@lucent.com>
31811
31812         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
31813
31814         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
31815
31816         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
31817         configure.in
31818         (AC_CHECK_HEADERS): Likewise for sh-utils.
31819         (AC_CHECK_HEADERS): Likewise for textutils.
31820         Merge the three lists of headers.
31821
31822         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
31823         from fileutils' configure.in.
31824
31825         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
31826         code. Moved tests into their own function (_jm_DECL_HEADERS) in
31827         check-decl.m4.
31828
31829         * m4/check-decl.m4: Use #if rather than #ifdef.
31830         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
31831         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
31832         (_jm_DECL_HEADERS): Define new function.
31833         (jm_CHECK_DECLARATIONS): Require it.
31834
31835 2000-01-22  Jim Meyering  <meyering@lucent.com>
31836
31837         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
31838         [! HAVE_DECL_STRTOULL]: Declare strtoull.
31839         Required for some AIX systems.  Reported by Christian Krackowizer.
31840         [TESTING] (main): New function.
31841
31842         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
31843         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
31844         letters.
31845
31846         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
31847         iswprint.
31848
31849         * lib/strverscmp.c (ISDIGIT): Define.
31850         (strverscmp): Use ISDIGIT, not isdigit.
31851
31852 2000-01-19  Jim Meyering  <meyering@lucent.com>
31853
31854         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
31855         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
31856         defines `struct timespec' in <sys/time.h>
31857
31858         * m4/c-bs-a.m4: Remove uses of changequote altogether.
31859         Thanks to Akim for explaining.
31860
31861 2000-01-17  Paul Eggert  <eggert@twinsun.com>
31862
31863         * lib/nanosleep.c (nanosleep):
31864         Don't use SA_INTERRUPT to decide whether to call sigaction, as
31865         POSIX.1 doesn't require SA_INTERRUPT and some systems
31866         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
31867         it's been part of POSIX.1 since day 1 (in 1988).
31868
31869 2000-01-17  Jim Meyering  <meyering@lucent.com>
31870
31871         * lib/interlock: Remove unused file.  Reported by François Pinard.
31872
31873 2000-01-16  Paul Eggert  <eggert@twinsun.com>
31874
31875         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
31876         alert, backslash, formfeed, and vertical tab unnecessarily in
31877         shell quoting style.
31878
31879 2000-01-16  Jim Meyering  <meyering@lucent.com>
31880
31881         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
31882         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
31883         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
31884         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
31885
31886 2000-01-16  Jim Meyering  <meyering@lucent.com>
31887
31888         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
31889         because the latter didn't work.
31890
31891 2000-01-15  Jim Meyering  <meyering@lucent.com>
31892
31893         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
31894         (AC_REPLACE_FUNCS): Add memcpy and memset.
31895         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
31896         Add strpbrk.
31897         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
31898
31899 2000-01-12  Jim Meyering  <meyering@lucent.com>
31900
31901         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
31902         (jm_PREREQ): Use it.
31903         (jm_PREREQ_READUTMP): New macro.
31904         (jm_PREREQ): Use it.
31905
31906 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31907
31908         Quote multibyte characters correctly.
31909         * m4/c-bs-a.m4: New file.
31910         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
31911         (jm_PREREQ): Use it.
31912
31913 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31914
31915         * m4/uintmax_t.m4: Port to autoconf 2.13.
31916
31917 2000-01-08  Jim Meyering  <meyering@ascend.com>
31918
31919         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
31920         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
31921
31922 2000-01-04  Jim Meyering  <meyering@ascend.com>
31923
31924         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
31925         jm_STRUCT_DIRENT_D_TYPE.
31926         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
31927         jm_STRUCT_DIRENT_D_INO.
31928         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
31929         jm_STRUCT_UTIMBUF.
31930         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
31931         renamings.
31932         * m4/utime.m4: Likewise.
31933
31934         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
31935         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
31936
31937 2000-01-03  Paul Eggert  <eggert@twinsun.com>
31938
31939         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
31940         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
31941
31942 2000-01-02  Jim Meyering  <meyering@ascend.com>
31943
31944         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
31945         remember if this is necessary.
31946
31947 1999-12-26  Jim Meyering  <meyering@ascend.com>
31948
31949         * m4/jm-macros.m4: Use it here.
31950         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
31951
31952 1999-12-23  Jim Meyering  <meyering@ascend.com>
31953
31954         * m4/jm-macros.m4: Check for clock_gettime (moved from
31955         fileutils/configure.in)
31956         Check for gettimeofday.
31957
31958 1999-12-20  Jim Meyering  <meyering@ascend.com>
31959
31960         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
31961         autoconf-2.14a-1999-12-20.
31962
31963 1999-12-19  Jim Meyering  <meyering@ascend.com>
31964
31965         * m4/lstat-slash.m4: New file.
31966         * m4/jm-macros.m4: Use the new macro:
31967         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31968
31969 1999-12-07  Jim Meyering  <meyering@ascend.com>
31970
31971         * m4/perl.m4: Require that File::Compare be available, too.
31972         Too many systems seem to lack it.
31973
31974         * m4/strftime.m4: Add checks for most of the cpp macros tested in
31975         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
31976
31977 1999-11-18  Paul Eggert  <eggert@twinsun.com>
31978
31979         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
31980         problem with the QNX 4.25 shell, which doesn't propagate exit
31981         status of failed commands inside shell assignments.
31982
31983 1999-11-17  Jim Meyering  <meyering@ascend.com>
31984
31985         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
31986
31987 1999-11-07  Jim Meyering  <meyering@ascend.com>
31988
31989         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
31990
31991 1999-11-06  Jim Meyering  <meyering@ascend.com>
31992
31993         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
31994         * m4/jm-macros.m4 (jm_MACROS): Use it here.
31995
31996 1999-11-05  Jim Meyering  <meyering@ascend.com>
31997
31998         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
31999         configure.in of textutils, fileutils, and sh-utils into this one
32000         (shared between those packages) file.
32001         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
32002         AC_STRUCT_ST_BLKSIZE.
32003
32004 1999-11-03  Jim Meyering  <meyering@ascend.com>
32005
32006         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
32007         of AC_CHECK_TYPE checks includes unistd.h.
32008         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
32009         Suggestion from Akim Demaille.
32010
32011 1999-10-30  Jim Meyering  <meyering@ascend.com>
32012
32013         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
32014         m4-quoted string.
32015         * m4/ls-mntd-fs.m4: Likewise.
32016         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
32017         * m4/jm-winsz1.m4: Likewise.
32018
32019         * m4/const.m4: Remove file, since the fix made it into the experimental
32020         version of autoconf.
32021         * m4/mktime.m4: Likewise.
32022
32023         * m4/check-type.m4: Remove file, now that the latest version of
32024         AC_CHECK_TYPE takes a third arg to specify additional #includes.
32025
32026         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
32027         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
32028         AC_CHECK_TYPE.
32029
32030 1999-10-04  Jim Meyering  <meyering@ascend.com>
32031
32032         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
32033
32034 1999-09-22  Paul Eggert  <eggert@twinsun.com>
32035
32036         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
32037         2.95.1 bug with HP-UX 10.20.
32038
32039 1999-09-17  Jim Meyering  <meyering@ascend.com>
32040
32041         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
32042         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
32043         due to missing strdup (against sh-utils-2.0).
32044
32045 1999-08-29  Jim Meyering  <meyering@ascend.com>
32046
32047         * m4/jm-macros.m4: Require jm_BISON.
32048         * m4/bison.m4: New file.
32049
32050 1999-08-17  Paul Eggert  <eggert@twinsun.com>
32051
32052         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
32053         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
32054
32055 1999-08-05  Jim Meyering  <meyering@ascend.com>
32056
32057         * m4/getline.m4: Rename test file from conftestdata to conftest.data
32058         to avoid conflicts with `conftest' on 8+3 filesystems.
32059         Suggestion from Eli Zaretskii.
32060
32061 1999-08-04  Jim Meyering  <meyering@ascend.com>
32062
32063         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
32064         fileutils and sh-utils (textutils's getline test was inadequate).
32065         (AM_FUNC_GETLINE): Run this test.
32066         (AC_CHECK_FUNCS): Check for getdelim.
32067         Reported by Bob Proulx.
32068
32069 1999-08-02  Jim Meyering  <meyering@ascend.com>
32070
32071         * m4/jm-macros.m4: Add a comment.
32072
32073 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32074
32075         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
32076         <inttypes.h> defines strtoumax as a macro (and not as a
32077         function).
32078
32079 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32080
32081         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
32082         that we can shift, multiply and divide unsigned long long
32083         values; Ultrix cc can't do it.
32084
32085 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32086
32087         * m4/mktime.m4: New file, which is a preview of what should appear
32088         in the next public autoconf release.
32089
32090 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32091
32092         * m4/lfs.m4: Remove this file.
32093         * m4/largefile.m4: New file.  It contains the old contents of
32094         lfs.m4, except that all names with prefix AC_LFS have been
32095         changed to use the prefix AC_SYS_LARGEFILE instead, to be
32096         compatible with future autoconf versions.  Also, some minor m4
32097         quoting problems have been fixed.
32098
32099 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32100
32101         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
32102         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
32103         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
32104         and simplify the shell code.
32105
32106 1999-08-01  Jim Meyering  <meyering@ascend.com>
32107
32108         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
32109         m4.
32110
32111 1999-07-20  Jim Meyering  <meyering@ascend.com>
32112
32113         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
32114
32115 1999-07-15  Jim Meyering  <meyering@ascend.com>
32116
32117         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
32118
32119 1999-05-22  Jim Meyering  <meyering@ascend.com>
32120
32121         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
32122
32123 1999-05-20  Jim Meyering  <meyering@ascend.com>
32124
32125         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
32126         Add a colon after each `then' in case $4 is empty.
32127
32128 1999-05-16  Jim Meyering  <meyering@ascend.com>
32129
32130         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
32131
32132 1999-05-10  Jim Meyering  <meyering@ascend.com>
32133
32134         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
32135
32136         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
32137         AC_FUNC_MKTIME.
32138
32139 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
32140
32141         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
32142
32143 1999-05-04  Paul Eggert  <eggert@twinsun.com>
32144
32145         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
32146         not CPPFLAGS, so that linking works correctly in IRIX.
32147
32148 1999-04-30  Paul Eggert  <eggert@twinsun.com>
32149
32150         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
32151
32152 1999-04-20  Paul Eggert  <eggert@twinsun.com>
32153
32154         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
32155         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
32156         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
32157         jm_AC_TYPE_UNSIGNED_LONG_LONG.
32158         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
32159
32160         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
32161
32162 1999-04-20  Jim Meyering  <meyering@ascend.com>
32163
32164         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
32165         AC_REPLACE xstroull if necessary.  From Paul Eggert.
32166         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
32167
32168 1999-04-18  Jim Meyering  <meyering@ascend.com>
32169
32170         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
32171         * m4/jm-macros.m4: Use it.
32172
32173 1999-04-06  Jim Meyering  <meyering@ascend.com>
32174
32175         * m4/strftime.m4: Remove test for %f.
32176
32177 1999-03-29  Jim Meyering  <meyering@ascend.com>
32178
32179         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
32180         superset of the AC_TYPE_* checks in the textutils, fileutils,
32181         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
32182         AC_TYPE_PID_T.
32183
32184 1999-03-28  Jim Meyering  <meyering@ascend.com>
32185
32186         * m4/jm-macros.m4: Define GNU_PACKAGE here.
32187         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
32188         replaced e.g., in the *.sh files of the sh-utils.
32189
32190 1999-03-20  Jim Meyering  <meyering@ascend.com>
32191
32192         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
32193         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
32194         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
32195
32196 1999-03-19  Jim Meyering  <meyering@ascend.com>
32197
32198         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
32199
32200 1999-03-12  Jim Meyering  <meyering@ascend.com>
32201
32202         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
32203
32204 1999-03-07  Jim Meyering  <meyering@ascend.com>
32205
32206         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
32207         declared.
32208
32209 1999-02-17  Jim Meyering  <meyering@ascend.com>
32210
32211         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
32212         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
32213
32214 1999-02-07  Jim Meyering  <meyering@ascend.com>
32215
32216         * m4/group-member.m4: New file -- extracted from sh-utils'
32217         configure.in.
32218
32219         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
32220         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
32221
32222 1999-02-06  Jim Meyering  <meyering@ascend.com>
32223
32224         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
32225         * m4/fnmatch.m4: Likewise.
32226         * m4/getgroups.m4: Likewise.
32227         * m4/lstat.m4: Likewise.
32228         * m4/malloc.m4: Likewise.
32229         * m4/putenv.m4: Likewise.
32230         * m4/realloc.m4: Likewise.
32231         * m4/regex.m4: Likewise.
32232         * m4/stat.m4: Likewise.
32233         * m4/strftime.m4: Likewise.
32234         Suggestion from Alain Magloire.
32235
32236         * m4/chown.m4: Use `.$ac_objext', not `.o'.
32237         * m4/fnmatch.m4: Likewise.
32238         * m4/getgroups.m4: Likewise.
32239         * m4/getline.m4: Likewise.
32240         * m4/lstat.m4: Likewise.
32241         * m4/malloc.m4: Likewise.
32242         * m4/memcmp.m4: Likewise.
32243         * m4/putenv.m4: Likewise.
32244         * m4/realloc.m4: Likewise.
32245         * m4/regex.m4: Likewise.
32246         * m4/stat.m4: Likewise.
32247         * m4/strftime.m4: Likewise.
32248         Suggestion from Alain Magloire.
32249
32250         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
32251         an argument.
32252
32253         * m4/regex.m4: Add a run-time Test for proper operation of
32254         re_compile_pattern.
32255
32256 1999-01-31  Jim Meyering  <meyering@ascend.com>
32257
32258         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
32259
32260 1999-01-30  Jim Meyering  <meyering@ascend.com>
32261
32262         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
32263
32264         * m4/jm-mktime.m4: Make this a wrapper around the official
32265         AM_FUNC_MKTIME rather than my private copy, now that the official one
32266         is up to date.
32267         * m4/mktime.m4: Remove file.
32268
32269         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
32270         * m4/uptime.m4: Likewise.
32271         * m4/uintmax_t.m4: Likewise.
32272
32273 1999-01-28  Jim Meyering  <meyering@ascend.com>
32274
32275         * m4/jm-macros.m4: Use jm_AFS.
32276         * m4/afs.m4: New file (from fileutils' configure.in).
32277
32278         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
32279         * m4/chown.m4: Likewise.
32280         * m4/d-ino.m4: Likewise.
32281         * m4/d-type.m4: Likewise.
32282         * m4/fnmatch.m4: Likewise.
32283         * m4/getgroups.m4: Likewise.
32284         * m4/gettext.m4: Likewise.
32285         * m4/jm-mktime.m4: Likewise.
32286         * m4/jm-winsz2.m4: Likewise.
32287         * m4/lcmessage.m4: Likewise.
32288         * m4/ls-mntd-fs.m4: Likewise.
32289         * m4/malloc.m4: Likewise.
32290         * m4/memcmp.m4: Likewise.
32291         * m4/putenv.m4: Likewise.
32292         * m4/realloc.m4: Likewise.
32293         * m4/st_mtim.m4: Likewise.
32294         * m4/strftime.m4: Likewise.
32295
32296 1999-01-16  Jim Meyering  <meyering@ascend.com>
32297
32298         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
32299         (ARGMATCH_DIE_DECL): Define.
32300
32301 1999-01-12  Jim Meyering  <meyering@ascend.com>
32302
32303         * m4/Makefile.am.in: Rewrite to avoid using fmt.
32304         Reported by Lars Hecking.
32305
32306 1999-01-10  Jim Meyering  <meyering@ascend.com>
32307
32308         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
32309         gross kludge.
32310         * m4/inttypes_h.m4: Likewise.
32311         * m4/lstat.m4: Likewise.
32312         * m4/malloc.m4: Likewise.
32313         * m4/readdir.m4: Likewise.
32314         * m4/realloc.m4: Likewise.
32315         * m4/st_dm_mode.m4: Likewise.
32316         * m4/stat.m4: Likewise.
32317         * m4/utimbuf.m4: Likewise.
32318         * m4/utimes.m4: Likewise.
32319
32320         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
32321         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
32322         comments in config.h.in are meaningful.
32323
32324         * m4/jm-macros.m4: Require autoconf-2.13 here.
32325
32326         * m4/regex.m4: By default, don't use the included regex.c on systems
32327         with glibc 2.  Suggestion from Uli Drepper.
32328
32329 1999-01-02  Jim Meyering  <meyering@ascend.com>
32330
32331         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
32332
32333 1998-12-18  Jim Meyering  <meyering@ascend.com>
32334
32335         * m4/Makefile.am.in (Makefile.am): Simplify rule.
32336         Based on a suggestion from Lars Hecking.
32337
32338 1998-11-16  Paul Eggert  <eggert@twinsun.com>
32339
32340         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
32341
32342 1998-11-16  Jim Meyering  <meyering@ascend.com>
32343
32344         * m4/lfs.m4: Double-quote the `uname...` expression.
32345
32346 1998-11-14  Jim Meyering  <meyering@ascend.com>
32347
32348         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
32349         * m4/stat.m4: Likewise.
32350
32351 1998-11-03  Jim Meyering  <meyering@ascend.com>
32352
32353         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
32354         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
32355
32356 1998-10-18  Jim Meyering  <meyering@ascend.com>
32357
32358         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
32359
32360 1998-10-17  Jim Meyering  <meyering@ascend.com>
32361
32362         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
32363         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
32364         calls for those previously hard-coded headers.  Instead, take a new
32365         parameter.
32366         (jm_CHECK_DECLARATIONS): Reflect interface change.
32367         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
32368         (jm_CHECK_DECL_LOCALTIME_R): New macro.
32369
32370         * m4/mktime.m4: Test for spring-forward gap before long-running test.
32371
32372 1998-10-14  Jim Meyering  <meyering@ascend.com>
32373
32374         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
32375         instead of "TZ=America/Vancouver".  From Paul Eggert.
32376
32377 1998-10-11  Jim Meyering  <meyering@ascend.com>
32378
32379         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
32380         This adds a test for a recently added compatibility fix for mktime.c.
32381         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
32382
32383 1998-09-27  Jim Meyering  <meyering@ascend.com>
32384
32385         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
32386
32387         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
32388         ../configure.in, including a change from Gordon Matzigkeit to allow
32389         cross-compiling for the Hurd.
32390
32391         * m4/glibc.m4: New file/macro to test for the GNU C Library
32392         versions 1 and 2.  From Gordon Matzigkeit.
32393         Indent.
32394
32395 1998-09-21  Jim Meyering  <meyering@ascend.com>
32396
32397         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
32398
32399 1998-08-18  Paul Eggert  <eggert@twinsun.com>
32400
32401         Port nanosecond-resolution times to UnixWare 2.1.2 and
32402         pedantic Solaris 2.6.
32403
32404         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32405         AC_STRUCT_ST_MTIM.
32406         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32407         Generate name of ns member, instead of just 1 or undef.
32408         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32409
32410 1998-08-15  Jim Meyering  <meyering@ascend.com>
32411
32412         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32413         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32414         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32415         instead of jm_TYPE_SSIZE_T.
32416
32417 1998-08-12  Jim Meyering  <meyering@ascend.com>
32418
32419         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32420
32421 1998-08-02  Jim Meyering  <meyering@ascend.com>
32422
32423         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32424         in acconfig.h manually.
32425
32426 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32427
32428         * m4/st_mtim.m4: New file.
32429
32430 1998-07-28  Jim Meyering  <meyering@ascend.com>
32431
32432         * m4/utimes.m4: Undef stat.
32433
32434 1998-07-25  Jim Meyering  <meyering@ascend.com>
32435
32436         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32437         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32438
32439 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32440
32441         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32442         uid and gid actually remain unchanged.
32443
32444 1998-07-07  Jim Meyering  <meyering@ascend.com>
32445
32446         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32447
32448 1998-07-04  Jim Meyering  <meyering@ascend.com>
32449
32450         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32451         to prove that this macro can be used in packages without regex.c.
32452
32453 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32454
32455         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32456         is to be used.
32457
32458 1998-07-03  Jim Meyering  <meyering@ascend.com>
32459
32460         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32461
32462         * m4/gettext.m4: New file -- from gettext-0.10.35.
32463         * m4/lcmessage.m4: Likewise.
32464         * m4/progtest.m4: Likewise.
32465
32466         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32467         * m4/jm-macros.m4: Require the new macro.
32468
32469 1998-06-29  Jim Meyering  <meyering@ascend.com>
32470
32471         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32472         for the definition of NGROUPS (used in a system header included
32473         by sys/mount.h).
32474
32475 1998-06-28  Jim Meyering  <meyering@ascend.com>
32476
32477         * m4/ls-mntd-fs.m4: New file.
32478         * m4/fstypename.m4: New file.
32479
32480         * m4/jm-macros.m4: Require the new macro.
32481         * m4/jm-glibc-io.m4: New file.
32482
32483 1998-05-19  Jim Meyering  <meyering@ascend.com>
32484
32485         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32486         * m4/lchown.m4: New file.
32487
32488         * m4/Makefile.am.in: New file.
32489         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32490
32491 1998-05-14  Jim Meyering  <meyering@ascend.com>
32492
32493         * m4/Makefile.am (EXTRA_DIST): Add them.
32494         * m4/jm-macros.m4: New file.
32495         * m4/utimbuf.m4: New file.
32496
32497 1998-05-12  Jim Meyering  <meyering@ascend.com>
32498
32499         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32500
32501 1998-05-11  Jim Meyering  <meyering@ascend.com>
32502
32503         * m4/isc-posix.m4: New file.
32504
32505 1998-05-10  Jim Meyering  <meyering@ascend.com>